@camstack/addon-agent-ui 1.2.181 → 1.2.182
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/addon.js +293 -10
- package/package.json +1 -1
package/dist/addon.js
CHANGED
|
@@ -10518,7 +10518,53 @@ var ModelFormatEntrySchema = object({
|
|
|
10518
10518
|
/** Multi-file payload (directory members or sibling files). */
|
|
10519
10519
|
files: array(string()).readonly().optional(),
|
|
10520
10520
|
/** Runtime(s) that can use this format. If omitted, inferred from ModelFormat key */
|
|
10521
|
-
runtimes: array(_enum(["python"])).readonly().optional()
|
|
10521
|
+
runtimes: array(_enum(["python"])).readonly().optional(),
|
|
10522
|
+
/**
|
|
10523
|
+
* Content revision of the artefact, for one hosted OFF the CamStack mirror.
|
|
10524
|
+
* A format on the mirror leaves it unset: its revision (the sha256 of its
|
|
10525
|
+
* weight file) comes from the downloader's generated table, kept in step
|
|
10526
|
+
* with the mirror by `scripts/check-hosted-model-revisions.ts` (D744). A
|
|
10527
|
+
* node records the revision it downloaded next to the file
|
|
10528
|
+
* (`<file>.revision`); a copy with no record or a different one is stale
|
|
10529
|
+
* unless its weight file hashes to the revision, and a stale copy is
|
|
10530
|
+
* downloaded again, the old one serving until the new one is complete. No
|
|
10531
|
+
* revision at all ⇒ a file on disk is current, whatever it holds (D743).
|
|
10532
|
+
*/
|
|
10533
|
+
revision: string().min(1).optional()
|
|
10534
|
+
});
|
|
10535
|
+
/**
|
|
10536
|
+
* What a node holds for one (model, format) (D746). `current` is a complete
|
|
10537
|
+
* copy at its catalog revision — exactly what `downloaded: true` means.
|
|
10538
|
+
* `stale` is bytes on disk that are not (yet) proven current under D743/D744:
|
|
10539
|
+
* no or a different revision record, or a missing sibling. `missing` is no
|
|
10540
|
+
* copy. `downloaded` alone folds `stale` into "not downloaded", which hid
|
|
10541
|
+
* reclaimable bytes and a copy about to be replaced.
|
|
10542
|
+
*/
|
|
10543
|
+
var ModelOnDiskStateSchema = _enum([
|
|
10544
|
+
"current",
|
|
10545
|
+
"stale",
|
|
10546
|
+
"missing"
|
|
10547
|
+
]);
|
|
10548
|
+
/**
|
|
10549
|
+
* The numeric precision of one format's BUILD (D746) — reported only when the
|
|
10550
|
+
* build states it (file-name token, an INT8 variant, an EdgeTPU compile, a
|
|
10551
|
+
* CamStack Core ML export). Absent means "not stated", never "fp32".
|
|
10552
|
+
*/
|
|
10553
|
+
var ModelFormatPrecisionSchema = _enum([
|
|
10554
|
+
"fp32",
|
|
10555
|
+
"fp16",
|
|
10556
|
+
"int8"
|
|
10557
|
+
]);
|
|
10558
|
+
/**
|
|
10559
|
+
* One format of one model as a node's `pipelineExecutor.getSchema` reports it.
|
|
10560
|
+
* `onDisk` / `precision` are optional for version skew: a runner that predates
|
|
10561
|
+
* them omits them, and a reader falls back to `downloaded`.
|
|
10562
|
+
*/
|
|
10563
|
+
var PipelineModelFormatStatusSchema = object({
|
|
10564
|
+
downloaded: boolean(),
|
|
10565
|
+
sizeMB: number(),
|
|
10566
|
+
onDisk: ModelOnDiskStateSchema.optional(),
|
|
10567
|
+
precision: ModelFormatPrecisionSchema.optional()
|
|
10522
10568
|
});
|
|
10523
10569
|
/**
|
|
10524
10570
|
* Extra file that must be downloaded alongside the model (e.g., labels JSON, dict.txt).
|
|
@@ -23157,7 +23203,7 @@ var FrameRefSchema = object({
|
|
|
23157
23203
|
timestamp: number(),
|
|
23158
23204
|
capturedAt: number().optional()
|
|
23159
23205
|
});
|
|
23160
|
-
var ModelFormatSchema$
|
|
23206
|
+
var ModelFormatSchema$2 = _enum([
|
|
23161
23207
|
"onnx",
|
|
23162
23208
|
"coreml",
|
|
23163
23209
|
"openvino",
|
|
@@ -23175,7 +23221,7 @@ var PipelineSlotSchema = _enum([
|
|
|
23175
23221
|
var PipelineEngineChoiceSchema = object({
|
|
23176
23222
|
runtime: literal("python"),
|
|
23177
23223
|
backend: string(),
|
|
23178
|
-
format: ModelFormatSchema$
|
|
23224
|
+
format: ModelFormatSchema$2,
|
|
23179
23225
|
device: string().optional()
|
|
23180
23226
|
});
|
|
23181
23227
|
/**
|
|
@@ -23232,10 +23278,7 @@ var PipelineTemplateSchema$1 = object({
|
|
|
23232
23278
|
var PipelineModelOptionSchema = object({
|
|
23233
23279
|
id: string(),
|
|
23234
23280
|
name: string(),
|
|
23235
|
-
formats: record(string(),
|
|
23236
|
-
downloaded: boolean(),
|
|
23237
|
-
sizeMB: number()
|
|
23238
|
-
})),
|
|
23281
|
+
formats: record(string(), PipelineModelFormatStatusSchema),
|
|
23239
23282
|
group: ModelVariantGroupSchema.optional(),
|
|
23240
23283
|
legacy: boolean().optional(),
|
|
23241
23284
|
provider: ModelProviderIdSchema.optional(),
|
|
@@ -23402,6 +23445,22 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
|
|
|
23402
23445
|
}), {
|
|
23403
23446
|
kind: "mutation",
|
|
23404
23447
|
auth: "admin"
|
|
23448
|
+
}), method(object({
|
|
23449
|
+
nodeId: string(),
|
|
23450
|
+
deviceIds: array(number()).readonly().optional(),
|
|
23451
|
+
dryRun: boolean()
|
|
23452
|
+
}), object({
|
|
23453
|
+
entries: array(object({
|
|
23454
|
+
deviceId: number(),
|
|
23455
|
+
keys: array(string()).readonly()
|
|
23456
|
+
})).readonly(),
|
|
23457
|
+
refused: array(object({
|
|
23458
|
+
deviceId: number(),
|
|
23459
|
+
reason: string()
|
|
23460
|
+
})).readonly()
|
|
23461
|
+
}), {
|
|
23462
|
+
kind: "mutation",
|
|
23463
|
+
auth: "admin"
|
|
23405
23464
|
}), method(object({ nodeId: string() }), object({ unhealthy: array(object({
|
|
23406
23465
|
/** `<backend>:<device>`, e.g. `openvino:gpu`. */
|
|
23407
23466
|
deviceKey: string(),
|
|
@@ -23438,11 +23497,11 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
|
|
|
23438
23497
|
}), PipelineTemplateSchema$1, { kind: "mutation" }), method(object({ id: string() }), _void(), { kind: "mutation" }), method(_void(), InferenceCapabilitiesBridge), method(object({ addonId: string() }), ModelAvailabilityListBridge), method(object({
|
|
23439
23498
|
addonId: string(),
|
|
23440
23499
|
modelId: string(),
|
|
23441
|
-
format: ModelFormatSchema$
|
|
23500
|
+
format: ModelFormatSchema$2
|
|
23442
23501
|
}), DownloadModelResultSchema, { kind: "mutation" }), method(object({
|
|
23443
23502
|
addonId: string(),
|
|
23444
23503
|
modelId: string(),
|
|
23445
|
-
format: ModelFormatSchema$
|
|
23504
|
+
format: ModelFormatSchema$2
|
|
23446
23505
|
}), object({ success: literal(true) }), { kind: "mutation" }), method(object({
|
|
23447
23506
|
steps: array(PipelineStepInputSchema).min(1),
|
|
23448
23507
|
frame: FrameInputSchema.optional(),
|
|
@@ -23599,6 +23658,204 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
|
|
|
23599
23658
|
filename: string().optional(),
|
|
23600
23659
|
settings: record(string(), unknown()).optional()
|
|
23601
23660
|
}), AudioTestResultSchema, { kind: "mutation" }), method(_void(), ConfigUISchemaNullableBridge);
|
|
23661
|
+
/**
|
|
23662
|
+
* The wire shapes of the Best settings plan and apply (D745), used by the
|
|
23663
|
+
* `pipeline-orchestrator` cap. The recommender's own types
|
|
23664
|
+
* (`recommend.ts`, `demand.ts`) are the TS face of the same data; these
|
|
23665
|
+
* schemas are what crosses the cap boundary.
|
|
23666
|
+
*/
|
|
23667
|
+
var ModelFormatSchema$1 = _enum(MODEL_FORMATS);
|
|
23668
|
+
var HardwareClassIdSchema = _enum([
|
|
23669
|
+
"intel-core-ultra",
|
|
23670
|
+
"intel-n-series",
|
|
23671
|
+
"apple-m-base",
|
|
23672
|
+
"apple-m-pro",
|
|
23673
|
+
"unknown"
|
|
23674
|
+
]);
|
|
23675
|
+
var AcceleratorKindSchema = _enum([
|
|
23676
|
+
"intel-npu",
|
|
23677
|
+
"intel-igpu",
|
|
23678
|
+
"x86-cpu",
|
|
23679
|
+
"arm-cpu",
|
|
23680
|
+
"apple-ane",
|
|
23681
|
+
"coral"
|
|
23682
|
+
]);
|
|
23683
|
+
var RecommendationReasonSchema = discriminatedUnion("kind", [
|
|
23684
|
+
object({
|
|
23685
|
+
kind: literal("fits"),
|
|
23686
|
+
utilisation: number()
|
|
23687
|
+
}),
|
|
23688
|
+
object({
|
|
23689
|
+
kind: literal("tie-faster"),
|
|
23690
|
+
over: string(),
|
|
23691
|
+
recallDelta: number()
|
|
23692
|
+
}),
|
|
23693
|
+
object({
|
|
23694
|
+
kind: literal("stepped-down"),
|
|
23695
|
+
from: string(),
|
|
23696
|
+
to: string(),
|
|
23697
|
+
limitedBy: string()
|
|
23698
|
+
}),
|
|
23699
|
+
object({
|
|
23700
|
+
kind: literal("no-fit-lightest"),
|
|
23701
|
+
utilisation: number()
|
|
23702
|
+
}),
|
|
23703
|
+
object({
|
|
23704
|
+
kind: literal("derived-latency"),
|
|
23705
|
+
modelId: string()
|
|
23706
|
+
}),
|
|
23707
|
+
object({
|
|
23708
|
+
kind: literal("estimated-load"),
|
|
23709
|
+
observedForMs: number().nullable()
|
|
23710
|
+
}),
|
|
23711
|
+
object({ kind: literal("cpu-device") }),
|
|
23712
|
+
object({ kind: literal("coral-untouched") }),
|
|
23713
|
+
object({ kind: literal("device-disabled") }),
|
|
23714
|
+
object({ kind: literal("device-unavailable") }),
|
|
23715
|
+
object({ kind: literal("node-offline") }),
|
|
23716
|
+
object({ kind: literal("no-hardware-facts") }),
|
|
23717
|
+
object({
|
|
23718
|
+
kind: literal("no-measured-data"),
|
|
23719
|
+
hardwareClass: HardwareClassIdSchema
|
|
23720
|
+
}),
|
|
23721
|
+
object({
|
|
23722
|
+
kind: literal("no-family-build"),
|
|
23723
|
+
format: ModelFormatSchema$1
|
|
23724
|
+
})
|
|
23725
|
+
]);
|
|
23726
|
+
var DeviceDemandSchema = object({
|
|
23727
|
+
nodeId: string(),
|
|
23728
|
+
deviceKey: string(),
|
|
23729
|
+
demandFps: number(),
|
|
23730
|
+
maxCameraFps: number(),
|
|
23731
|
+
alwaysOnCameras: number(),
|
|
23732
|
+
onMotionSessions: number(),
|
|
23733
|
+
onMotionSource: _enum([
|
|
23734
|
+
"observed-24h",
|
|
23735
|
+
"estimate",
|
|
23736
|
+
"none"
|
|
23737
|
+
]),
|
|
23738
|
+
observedForMs: number().nullable()
|
|
23739
|
+
});
|
|
23740
|
+
var DeviceModelChoiceSchema = object({
|
|
23741
|
+
modelId: string(),
|
|
23742
|
+
p50Ms: number(),
|
|
23743
|
+
fps: number(),
|
|
23744
|
+
measured: boolean(),
|
|
23745
|
+
utilisation: number(),
|
|
23746
|
+
personRecall: number()
|
|
23747
|
+
});
|
|
23748
|
+
var DeviceRecommendationSchema = object({
|
|
23749
|
+
deviceKey: string(),
|
|
23750
|
+
accelerator: AcceleratorKindSchema.nullable(),
|
|
23751
|
+
enabled: boolean(),
|
|
23752
|
+
available: boolean(),
|
|
23753
|
+
demand: DeviceDemandSchema.nullable(),
|
|
23754
|
+
chosen: DeviceModelChoiceSchema.nullable(),
|
|
23755
|
+
reasons: array(RecommendationReasonSchema).readonly()
|
|
23756
|
+
});
|
|
23757
|
+
var NodeRecommendationSchema = object({
|
|
23758
|
+
nodeId: string(),
|
|
23759
|
+
reachable: boolean(),
|
|
23760
|
+
hardwareClass: HardwareClassIdSchema.nullable(),
|
|
23761
|
+
cpuModel: string().nullable(),
|
|
23762
|
+
skipped: boolean(),
|
|
23763
|
+
acceleratorModelId: string().nullable(),
|
|
23764
|
+
devices: array(DeviceRecommendationSchema).readonly(),
|
|
23765
|
+
reasons: array(RecommendationReasonSchema).readonly()
|
|
23766
|
+
});
|
|
23767
|
+
var ModelPinChangeSchema = object({
|
|
23768
|
+
stepId: string(),
|
|
23769
|
+
before: string().nullable(),
|
|
23770
|
+
after: string().nullable()
|
|
23771
|
+
});
|
|
23772
|
+
var NodeDeviceChangeSchema = object({
|
|
23773
|
+
nodeId: string(),
|
|
23774
|
+
deviceKey: string(),
|
|
23775
|
+
madeExplicit: boolean(),
|
|
23776
|
+
modelPins: array(ModelPinChangeSchema).readonly(),
|
|
23777
|
+
thresholds: array(object({
|
|
23778
|
+
stepId: string(),
|
|
23779
|
+
keys: array(string()).readonly()
|
|
23780
|
+
})).readonly()
|
|
23781
|
+
});
|
|
23782
|
+
var CameraOverrideClearSchema = object({
|
|
23783
|
+
deviceId: number(),
|
|
23784
|
+
source: _enum(["step-override", "wholesale"]),
|
|
23785
|
+
nodeId: string(),
|
|
23786
|
+
deviceKey: string().nullable(),
|
|
23787
|
+
stepId: string(),
|
|
23788
|
+
modelIdBefore: string().nullable(),
|
|
23789
|
+
keys: array(string()).readonly()
|
|
23790
|
+
});
|
|
23791
|
+
var DetectorStoreClearSchema = object({
|
|
23792
|
+
deviceId: number(),
|
|
23793
|
+
keys: array(string()).readonly()
|
|
23794
|
+
});
|
|
23795
|
+
var BestSettingsWarningSchema = discriminatedUnion("kind", [
|
|
23796
|
+
object({
|
|
23797
|
+
kind: literal("detector-store-cluster-wide"),
|
|
23798
|
+
skippedNodes: array(string()).readonly()
|
|
23799
|
+
}),
|
|
23800
|
+
object({
|
|
23801
|
+
kind: literal("detector-store-unreadable"),
|
|
23802
|
+
error: string()
|
|
23803
|
+
}),
|
|
23804
|
+
object({
|
|
23805
|
+
kind: literal("coral-enabled"),
|
|
23806
|
+
nodeId: string(),
|
|
23807
|
+
deviceKey: string()
|
|
23808
|
+
})
|
|
23809
|
+
]);
|
|
23810
|
+
var BestSettingsOptionsSchema = object({
|
|
23811
|
+
/** Share of each accelerator's throughput kept free (0.3–0.5). */
|
|
23812
|
+
headroom: number().min(.3).max(.5).default(.4) });
|
|
23813
|
+
var BestSettingsPlanSchema = object({
|
|
23814
|
+
/** Hash of everything the apply will write — the apply refuses a different one. */
|
|
23815
|
+
planHash: string(),
|
|
23816
|
+
family: literal("yolov9"),
|
|
23817
|
+
headroom: number(),
|
|
23818
|
+
generatedAt: number(),
|
|
23819
|
+
nodes: array(NodeRecommendationSchema).readonly(),
|
|
23820
|
+
nodeChanges: array(NodeDeviceChangeSchema).readonly(),
|
|
23821
|
+
cameraClears: array(CameraOverrideClearSchema).readonly(),
|
|
23822
|
+
detectorStoreClears: array(DetectorStoreClearSchema).readonly(),
|
|
23823
|
+
warnings: array(BestSettingsWarningSchema).readonly()
|
|
23824
|
+
});
|
|
23825
|
+
var BestSettingsApplyInputSchema = object({
|
|
23826
|
+
planHash: string(),
|
|
23827
|
+
headroom: number().min(.3).max(.5).default(.4)
|
|
23828
|
+
});
|
|
23829
|
+
var BestSettingsPhaseResultSchema = object({
|
|
23830
|
+
phase: _enum([
|
|
23831
|
+
"download",
|
|
23832
|
+
"camera-overrides",
|
|
23833
|
+
"detector-thresholds",
|
|
23834
|
+
"node-models",
|
|
23835
|
+
"redispatch"
|
|
23836
|
+
]),
|
|
23837
|
+
ok: boolean(),
|
|
23838
|
+
detail: string()
|
|
23839
|
+
});
|
|
23840
|
+
var BestSettingsApplyResultSchema = discriminatedUnion("kind", [
|
|
23841
|
+
object({
|
|
23842
|
+
kind: literal("applied"),
|
|
23843
|
+
planHash: string(),
|
|
23844
|
+
phases: array(BestSettingsPhaseResultSchema).readonly()
|
|
23845
|
+
}),
|
|
23846
|
+
object({
|
|
23847
|
+
kind: literal("aborted"),
|
|
23848
|
+
phases: array(BestSettingsPhaseResultSchema).readonly()
|
|
23849
|
+
}),
|
|
23850
|
+
object({
|
|
23851
|
+
kind: literal("stale"),
|
|
23852
|
+
plan: BestSettingsPlanSchema
|
|
23853
|
+
}),
|
|
23854
|
+
object({
|
|
23855
|
+
kind: literal("refused"),
|
|
23856
|
+
reason: _enum(["apply-in-progress"])
|
|
23857
|
+
})
|
|
23858
|
+
]);
|
|
23602
23859
|
object({
|
|
23603
23860
|
activeCameras: number(),
|
|
23604
23861
|
throttledCameras: number(),
|
|
@@ -25325,6 +25582,9 @@ method(object({
|
|
|
25325
25582
|
}), {
|
|
25326
25583
|
kind: "mutation",
|
|
25327
25584
|
auth: "admin"
|
|
25585
|
+
}), method(BestSettingsOptionsSchema, BestSettingsPlanSchema, { auth: "admin" }), method(BestSettingsApplyInputSchema, BestSettingsApplyResultSchema, {
|
|
25586
|
+
kind: "mutation",
|
|
25587
|
+
auth: "admin"
|
|
25328
25588
|
}), method(object({ deviceId: number() }), CameraPipelineSettingsSchema.nullable()), method(object({
|
|
25329
25589
|
deviceId: number(),
|
|
25330
25590
|
addonId: string(),
|
|
@@ -40900,6 +41160,12 @@ Object.freeze({
|
|
|
40900
41160
|
addonId: null,
|
|
40901
41161
|
access: "delete"
|
|
40902
41162
|
},
|
|
41163
|
+
"pipelineExecutor.clearModelBoundDeviceOverrides": {
|
|
41164
|
+
capName: "pipeline-executor",
|
|
41165
|
+
capScope: "system",
|
|
41166
|
+
addonId: null,
|
|
41167
|
+
access: "delete"
|
|
41168
|
+
},
|
|
40903
41169
|
"pipelineExecutor.deleteModel": {
|
|
40904
41170
|
capName: "pipeline-executor",
|
|
40905
41171
|
capScope: "system",
|
|
@@ -41116,6 +41382,12 @@ Object.freeze({
|
|
|
41116
41382
|
addonId: null,
|
|
41117
41383
|
access: "view"
|
|
41118
41384
|
},
|
|
41385
|
+
"pipelineOrchestrator.applyBestSettings": {
|
|
41386
|
+
capName: "pipeline-orchestrator",
|
|
41387
|
+
capScope: "system",
|
|
41388
|
+
addonId: null,
|
|
41389
|
+
access: "create"
|
|
41390
|
+
},
|
|
41119
41391
|
"pipelineOrchestrator.applyDeviceSettingsPatch": {
|
|
41120
41392
|
capName: "pipeline-orchestrator",
|
|
41121
41393
|
capScope: "system",
|
|
@@ -41290,6 +41562,12 @@ Object.freeze({
|
|
|
41290
41562
|
addonId: null,
|
|
41291
41563
|
access: "create"
|
|
41292
41564
|
},
|
|
41565
|
+
"pipelineOrchestrator.planBestSettings": {
|
|
41566
|
+
capName: "pipeline-orchestrator",
|
|
41567
|
+
capScope: "system",
|
|
41568
|
+
addonId: null,
|
|
41569
|
+
access: "view"
|
|
41570
|
+
},
|
|
41293
41571
|
"pipelineOrchestrator.rebalance": {
|
|
41294
41572
|
capName: "pipeline-orchestrator",
|
|
41295
41573
|
capScope: "system",
|
|
@@ -46712,6 +46990,11 @@ Object.freeze({
|
|
|
46712
46990
|
form: "single",
|
|
46713
46991
|
optional: false
|
|
46714
46992
|
}],
|
|
46993
|
+
"pipelineExecutor.clearModelBoundDeviceOverrides": [{
|
|
46994
|
+
name: "deviceIds",
|
|
46995
|
+
form: "array",
|
|
46996
|
+
optional: true
|
|
46997
|
+
}],
|
|
46715
46998
|
"pipelineExecutor.runPipeline": [{
|
|
46716
46999
|
name: "deviceId",
|
|
46717
47000
|
form: "single",
|
|
@@ -48753,7 +49036,7 @@ var AgentUIAddon = class extends BaseAddon {
|
|
|
48753
49036
|
capability: adminUiCapability,
|
|
48754
49037
|
provider: {
|
|
48755
49038
|
getStaticDir: async () => ({ staticDir: path.resolve(__dirname) }),
|
|
48756
|
-
getVersion: async () => ({ version: "1.2.
|
|
49039
|
+
getVersion: async () => ({ version: "1.2.182" })
|
|
48757
49040
|
}
|
|
48758
49041
|
}];
|
|
48759
49042
|
}
|