@camstack/addon-decoder-nodeav 1.1.18 → 1.2.0
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/index.js +193 -103
- package/dist/index.mjs +193 -103
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7084,6 +7084,17 @@ var ModelCatalogEntrySchema = object({
|
|
|
7084
7084
|
"imagenet",
|
|
7085
7085
|
"none"
|
|
7086
7086
|
]).optional(),
|
|
7087
|
+
/**
|
|
7088
|
+
* The model already applies softmax IN-GRAPH — its raw output is a
|
|
7089
|
+
* probability distribution, not logits. When set, the `softmax`
|
|
7090
|
+
* postprocessor must NOT re-apply softmax: re-softmaxing an already-normalised
|
|
7091
|
+
* probability vector collapses it toward uniform (top-1 score craters far
|
|
7092
|
+
* below its true value, making every confidence gate meaningless). Absent ⇒
|
|
7093
|
+
* the output is raw logits and the postprocessor applies softmax (the normal
|
|
7094
|
+
* case). Set on the Google AIY Birds `bird-classifier` (softmax baked into the
|
|
7095
|
+
* TF graph). Threaded to the Python pool via `PoolModelConfig.outputProbabilities`.
|
|
7096
|
+
*/
|
|
7097
|
+
outputProbabilities: boolean().optional(),
|
|
7087
7098
|
preprocessMode: _enum(["letterbox", "resize"]).optional(),
|
|
7088
7099
|
/**
|
|
7089
7100
|
* Per-MODEL postprocessor override. Absent ⇒ the step's own
|
|
@@ -11097,10 +11108,7 @@ var ConfigUISchemaNullableBridge = custom();
|
|
|
11097
11108
|
var InferenceCapabilitiesBridge = custom();
|
|
11098
11109
|
var ModelAvailabilityListBridge = custom();
|
|
11099
11110
|
var PipelineRunResultBridge = custom();
|
|
11100
|
-
method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngineChoiceSchema), method(PipelineEngineChoiceSchema, array(PipelineDefaultStepSchema)), method(_void(),
|
|
11101
|
-
kind: "mutation",
|
|
11102
|
-
auth: "admin"
|
|
11103
|
-
}), method(object({ nodeId: string() }), EngineProvisioningSchema), method(_void(), record(string(), object({
|
|
11111
|
+
method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngineChoiceSchema), method(PipelineEngineChoiceSchema, array(PipelineDefaultStepSchema)), method(object({ nodeId: string() }), EngineProvisioningSchema), method(_void(), record(string(), object({
|
|
11104
11112
|
modelId: string(),
|
|
11105
11113
|
settings: record(string(), unknown()).readonly()
|
|
11106
11114
|
}))), method(object({ steps: record(string(), object({
|
|
@@ -11160,13 +11168,33 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
|
|
|
11160
11168
|
* (inputClasses ≠ null) are skipped and served per-track via
|
|
11161
11169
|
* pipelineRunner.runDetailSubtree (two-plane design).
|
|
11162
11170
|
*/
|
|
11163
|
-
plane: _enum(["full", "frame"]).optional()
|
|
11171
|
+
plane: _enum(["full", "frame"]).optional(),
|
|
11172
|
+
/**
|
|
11173
|
+
* Inference-device selector (Phase 2 multi-device). Format
|
|
11174
|
+
* `<backend>:<device>` (e.g. `openvino:gpu`, `edgetpu:usb`, `cpu`).
|
|
11175
|
+
* Omitted ⇒ the runner's default device (current single-engine
|
|
11176
|
+
* behaviour). Selects WHICH device pool of the node runs the call.
|
|
11177
|
+
*/
|
|
11178
|
+
deviceKey: string().optional()
|
|
11164
11179
|
}), PipelineRunResultBridge, { kind: "mutation" }), method(object({
|
|
11165
11180
|
engine: PipelineEngineChoiceSchema.optional(),
|
|
11166
11181
|
steps: array(PipelineStepInputSchema).min(1),
|
|
11167
11182
|
frames: array(FrameInputSchema).min(1).max(255),
|
|
11168
11183
|
deviceId: number().optional(),
|
|
11169
|
-
sessionId: string().optional()
|
|
11184
|
+
sessionId: string().optional(),
|
|
11185
|
+
/**
|
|
11186
|
+
* Pure-inference benchmark hint. A NONZERO uint32 pins every frame in
|
|
11187
|
+
* the batch to the Python pool's bench preprocess cache
|
|
11188
|
+
* (`_bench_frame_id`) so a REPEATED benchmark frame is decoded +
|
|
11189
|
+
* preprocessed ONCE and every later inference is a pure-inference cache
|
|
11190
|
+
* hit — the sustained-throughput run measures inference, not
|
|
11191
|
+
* decode+preprocess+infer. Omitted/0 for live frames (all different →
|
|
11192
|
+
* full preprocess every call, correct). Fresh per sustained run;
|
|
11193
|
+
* released via `uncacheFrame`.
|
|
11194
|
+
*/
|
|
11195
|
+
frameId: number().int().nonnegative().optional(),
|
|
11196
|
+
/** Inference-device selector (Phase 2 multi-device); see runPipeline. */
|
|
11197
|
+
deviceKey: string().optional()
|
|
11170
11198
|
}), object({ results: array(PipelineRunResultBridge).readonly() }), { kind: "mutation" }), method(object({
|
|
11171
11199
|
data: _instanceof(Uint8Array),
|
|
11172
11200
|
width: number().int().positive(),
|
|
@@ -11198,8 +11226,18 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
|
|
|
11198
11226
|
* - `runtime` — main camera-serving engine (no idle TTL).
|
|
11199
11227
|
* - `warm-override` — benchmark/test override held in the warm
|
|
11200
11228
|
* cache; auto-disposed after the idle TTL.
|
|
11229
|
+
* - `device-pool` — a concurrent per-device pool (Phase 2
|
|
11230
|
+
* multi-device, keyed by `deviceKey`) resolved
|
|
11231
|
+
* via `resolveDeviceFactory`. Runs alongside the
|
|
11232
|
+
* `runtime` engine on a DIFFERENT accelerator
|
|
11233
|
+
* (NPU / iGPU / Coral) — this is how the
|
|
11234
|
+
* Engines tab shows all pools running at once.
|
|
11201
11235
|
*/
|
|
11202
|
-
kind: _enum([
|
|
11236
|
+
kind: _enum([
|
|
11237
|
+
"runtime",
|
|
11238
|
+
"warm-override",
|
|
11239
|
+
"device-pool"
|
|
11240
|
+
]),
|
|
11203
11241
|
/** Native pid of the underlying Python pool (null when no pool). */
|
|
11204
11242
|
poolPid: number().nullable(),
|
|
11205
11243
|
/** ms since this factory was last used (null when not warm-tracked). */
|
|
@@ -11541,7 +11579,14 @@ var RunnerCameraConfigSchema = object({
|
|
|
11541
11579
|
* camera's detect node differs from its source-owner (P2d, gated by the
|
|
11542
11580
|
* `remoteSourcingNodes` rollout setting).
|
|
11543
11581
|
*/
|
|
11544
|
-
frameSource: RunnerFrameSourceSchema.default({ kind: "local-broker" })
|
|
11582
|
+
frameSource: RunnerFrameSourceSchema.default({ kind: "local-broker" }),
|
|
11583
|
+
/**
|
|
11584
|
+
* Inference-device selector for this camera's sessions (Phase 2 multi-device).
|
|
11585
|
+
* Format `<backend>:<device>` (e.g. `openvino:gpu`, `edgetpu:usb`, `cpu`);
|
|
11586
|
+
* omitted ⇒ the runner's default device. The engine itself stays node-local —
|
|
11587
|
+
* this only selects WHICH device pool of that node runs the session.
|
|
11588
|
+
*/
|
|
11589
|
+
deviceKey: string().optional()
|
|
11545
11590
|
});
|
|
11546
11591
|
motionFpsField.min, motionFpsField.max, motionFpsField.step, motionFpsField.default, detectionFpsField.min, detectionFpsField.max, detectionFpsField.step, detectionFpsField.default, motionCooldownMsField.min, motionCooldownMsField.max, motionCooldownMsField.step, motionCooldownMsField.default, occupancyRecheckSecField.min, occupancyRecheckSecField.max, occupancyRecheckSecField.step, occupancyRecheckSecField.default, occupancyRecheckFramesField.min, occupancyRecheckFramesField.max, occupancyRecheckFramesField.step, occupancyRecheckFramesField.default;
|
|
11547
11592
|
/**
|
|
@@ -11562,6 +11607,19 @@ var RunnerLocalLoadSchema = object({
|
|
|
11562
11607
|
avgInferenceTimeMs: number(),
|
|
11563
11608
|
/** Total queue depth across motion + detection queues. */
|
|
11564
11609
|
queueDepthTotal: number(),
|
|
11610
|
+
/**
|
|
11611
|
+
* Per-inference-device live load (multi-device C4). One entry per deviceKey
|
|
11612
|
+
* this runner currently has attached cameras on, so the orchestrator's second
|
|
11613
|
+
* `balance()` pass (over a node's devices) weights on real per-pool session
|
|
11614
|
+
* counts. Empty on single-device / pre-multi-device runners. `queueDepthTotal`
|
|
11615
|
+
* per device is 0 until the pool backlog gets a public accessor (follow-up).
|
|
11616
|
+
*/
|
|
11617
|
+
devices: array(object({
|
|
11618
|
+
deviceKey: string(),
|
|
11619
|
+
backend: string(),
|
|
11620
|
+
attachedCameras: number(),
|
|
11621
|
+
queueDepthTotal: number()
|
|
11622
|
+
})).default([]),
|
|
11565
11623
|
/** Hardware capability flags reported by this node. */
|
|
11566
11624
|
hardware: object({
|
|
11567
11625
|
hasGpu: boolean(),
|
|
@@ -13037,6 +13095,8 @@ method(_void(), _void(), { kind: "mutation" }), method(_void(), _void(), { kind:
|
|
|
13037
13095
|
kind: "mutation",
|
|
13038
13096
|
auth: "admin"
|
|
13039
13097
|
});
|
|
13098
|
+
DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder;
|
|
13099
|
+
new Set(Object.values(DeviceType));
|
|
13040
13100
|
/**
|
|
13041
13101
|
* `addon-pages` — system-scoped singleton aggregator cap. Public-facing
|
|
13042
13102
|
* surface that admin-ui consumes through `useAddonPagesListPages()`.
|
|
@@ -16836,13 +16896,11 @@ var PipelineTemplateSchema = object({
|
|
|
16836
16896
|
createdAt: string(),
|
|
16837
16897
|
updatedAt: string()
|
|
16838
16898
|
});
|
|
16839
|
-
var
|
|
16840
|
-
enabled: boolean(),
|
|
16899
|
+
var DeviceStepConfigSchema = object({
|
|
16841
16900
|
modelId: string().optional(),
|
|
16842
|
-
settings: record(string(), unknown()).
|
|
16901
|
+
settings: record(string(), unknown()).optional()
|
|
16843
16902
|
});
|
|
16844
16903
|
var AgentPipelineSettingsSchema = object({
|
|
16845
|
-
addonDefaults: record(string(), AgentAddonConfigSchema).readonly(),
|
|
16846
16904
|
maxCameras: number().int().nonnegative().nullable().default(null),
|
|
16847
16905
|
/** Per-node detection weight (relative share for the quota balancer). */
|
|
16848
16906
|
detectWeight: number().positive().optional(),
|
|
@@ -16866,7 +16924,22 @@ var AgentPipelineSettingsSchema = object({
|
|
|
16866
16924
|
* it already uses to reach the hub). Set this only when the auto-detected
|
|
16867
16925
|
* address is wrong (multi-homed host, NAT, custom interface).
|
|
16868
16926
|
*/
|
|
16869
|
-
reachableHost: string().optional()
|
|
16927
|
+
reachableHost: string().optional(),
|
|
16928
|
+
/**
|
|
16929
|
+
* Multi-device inference opt-in (Phase 4). Per-node map deviceKey → {enabled,
|
|
16930
|
+
* weight, steps}. Absent / all-disabled ⇒ the node's single default
|
|
16931
|
+
* accelerator (safe default); two+ enabled ⇒ the dispatcher balances
|
|
16932
|
+
* detection sessions across them so they run CONCURRENTLY. `steps` is the
|
|
16933
|
+
* per-(node,device) BASE provisioning (`stepId → {modelId?, settings?}`) —
|
|
16934
|
+
* the default model/settings for every camera landing on that accelerator;
|
|
16935
|
+
* a stepId absent ⇒ the step uses that device's format default.
|
|
16936
|
+
*/
|
|
16937
|
+
inferenceDevices: record(string(), object({
|
|
16938
|
+
enabled: boolean(),
|
|
16939
|
+
weight: number().positive().optional(),
|
|
16940
|
+
maxSessions: number().int().positive().optional(),
|
|
16941
|
+
steps: record(string(), DeviceStepConfigSchema).optional()
|
|
16942
|
+
})).optional()
|
|
16870
16943
|
});
|
|
16871
16944
|
var CameraPipelineForAgentSchema = object({
|
|
16872
16945
|
steps: array(PipelineStepInputSchema).readonly(),
|
|
@@ -16876,14 +16949,13 @@ var CameraPipelineForAgentSchema = object({
|
|
|
16876
16949
|
}).nullable()
|
|
16877
16950
|
});
|
|
16878
16951
|
var CameraStepOverridePatchSchema = object({
|
|
16879
|
-
enabled: boolean().optional(),
|
|
16880
16952
|
modelId: string().optional(),
|
|
16881
16953
|
settings: record(string(), unknown()).readonly().optional()
|
|
16882
16954
|
});
|
|
16883
16955
|
var CameraPipelineSettingsSchema = object({
|
|
16884
16956
|
pinnedAgentNodeId: string().optional(),
|
|
16885
16957
|
stepToggles: record(string(), boolean()).optional(),
|
|
16886
|
-
|
|
16958
|
+
stepOverridesByDevice: record(string(), record(string(), record(string(), CameraStepOverridePatchSchema))).optional(),
|
|
16887
16959
|
pipelineByAgent: record(string(), CameraPipelineForAgentSchema).optional()
|
|
16888
16960
|
});
|
|
16889
16961
|
/**
|
|
@@ -17097,6 +17169,44 @@ var CameraStatusSchema = object({
|
|
|
17097
17169
|
/** Unix timestamp (ms) when this snapshot was composed server-side. */
|
|
17098
17170
|
fetchedAt: number()
|
|
17099
17171
|
});
|
|
17172
|
+
var NodeInferenceDeviceSchema = object({
|
|
17173
|
+
/** Stable per-node device key, e.g. `openvino:npu`, `edgetpu:usb`, `cpu`. */
|
|
17174
|
+
key: string(),
|
|
17175
|
+
backend: string(),
|
|
17176
|
+
device: string(),
|
|
17177
|
+
format: _enum(MODEL_FORMATS),
|
|
17178
|
+
/** Whether the node's live probe reports the device as usable right now. */
|
|
17179
|
+
available: boolean(),
|
|
17180
|
+
/**
|
|
17181
|
+
* Whether this device participates in dispatch. AUTO default (spec C2):
|
|
17182
|
+
* accelerators are opt-OUT (a discovered NPU/iGPU/Coral/ANE with no stored
|
|
17183
|
+
* entry is `true`); CPU is opt-IN (`false` by default — the fallback pool,
|
|
17184
|
+
* not a balanced target). An explicit stored value always wins; a stored-only
|
|
17185
|
+
* (unavailable) key keeps its stored value.
|
|
17186
|
+
*/
|
|
17187
|
+
enabled: boolean(),
|
|
17188
|
+
/** Relative balancer weight for the enabled device (default 1). */
|
|
17189
|
+
weight: number(),
|
|
17190
|
+
/** Per-device concurrent-session cap; null = unlimited (multi-device C4). */
|
|
17191
|
+
maxSessions: number().nullable(),
|
|
17192
|
+
/** Object-detection model the executor defaults to for this deviceKey. */
|
|
17193
|
+
defaultModelId: string(),
|
|
17194
|
+
/**
|
|
17195
|
+
* Per-(node,device) BASE provisioning (C7.2/C7.4) — the RAW stored
|
|
17196
|
+
* `stepId → {modelId?, settings?}` map from `inferenceDevices[key].steps`.
|
|
17197
|
+
* Absent/empty ⇒ no base (every step uses its device format default). The
|
|
17198
|
+
* UI cross-references `pipelineExecutor.getSchema` for the models actually
|
|
17199
|
+
* available per format; this is the stored selection that becomes the
|
|
17200
|
+
* default for EVERY camera landing on this accelerator.
|
|
17201
|
+
*/
|
|
17202
|
+
steps: record(string(), DeviceStepConfigSchema).optional()
|
|
17203
|
+
});
|
|
17204
|
+
var NodeInferenceDevicesSchema = object({
|
|
17205
|
+
nodeId: string(),
|
|
17206
|
+
/** False when the node's platform-probe was unreachable (no live device set). */
|
|
17207
|
+
reachable: boolean(),
|
|
17208
|
+
devices: array(NodeInferenceDeviceSchema).readonly()
|
|
17209
|
+
});
|
|
17100
17210
|
method(object({
|
|
17101
17211
|
deviceId: number(),
|
|
17102
17212
|
agentNodeId: string()
|
|
@@ -17106,7 +17216,13 @@ method(object({
|
|
|
17106
17216
|
}), method(object({ deviceId: number() }), object({ success: literal(true) }), {
|
|
17107
17217
|
kind: "mutation",
|
|
17108
17218
|
auth: "admin"
|
|
17109
|
-
}), method(
|
|
17219
|
+
}), method(object({
|
|
17220
|
+
deviceId: number(),
|
|
17221
|
+
deviceKey: string()
|
|
17222
|
+
}), object({ success: literal(true) }), {
|
|
17223
|
+
kind: "mutation",
|
|
17224
|
+
auth: "admin"
|
|
17225
|
+
}), method(object({ deviceId: number() }), object({ deviceKey: string().nullable() })), method(_void(), object({ migrated: number() }), {
|
|
17110
17226
|
kind: "mutation",
|
|
17111
17227
|
auth: "admin"
|
|
17112
17228
|
}), method(_void(), array(PipelineAssignmentSchema).readonly()), method(object({ deviceId: number() }), PipelineAssignmentSchema.nullable()), method(_void(), array(AgentLoadSummarySchema).readonly()), method(_void(), GlobalMetricsSchema), method(object({ deviceId: number() }), CameraMetricsSchema.nullable()), method(object({ nodeId: string() }), CapabilityBindingsSchema), method(object({
|
|
@@ -17140,13 +17256,7 @@ method(object({
|
|
|
17140
17256
|
}))), method(object({ agentNodeId: string() }), AgentPipelineSettingsSchema.nullable()), method(_void(), array(object({
|
|
17141
17257
|
nodeId: string(),
|
|
17142
17258
|
settings: AgentPipelineSettingsSchema
|
|
17143
|
-
})).readonly()), method(object({
|
|
17144
|
-
agentNodeId: string(),
|
|
17145
|
-
defaults: record(string(), AgentAddonConfigSchema)
|
|
17146
|
-
}), object({ success: literal(true) }), {
|
|
17147
|
-
kind: "mutation",
|
|
17148
|
-
auth: "admin"
|
|
17149
|
-
}), method(object({ agentNodeId: string() }), object({
|
|
17259
|
+
})).readonly()), method(object({ agentNodeId: string() }), object({
|
|
17150
17260
|
success: boolean(),
|
|
17151
17261
|
removed: boolean()
|
|
17152
17262
|
}), {
|
|
@@ -17178,7 +17288,18 @@ method(object({
|
|
|
17178
17288
|
}), object({ success: literal(true) }), {
|
|
17179
17289
|
kind: "mutation",
|
|
17180
17290
|
auth: "admin"
|
|
17181
|
-
}), method(object({
|
|
17291
|
+
}), method(object({
|
|
17292
|
+
agentNodeId: string(),
|
|
17293
|
+
inferenceDevices: record(string(), object({
|
|
17294
|
+
enabled: boolean(),
|
|
17295
|
+
weight: number().positive().optional(),
|
|
17296
|
+
maxSessions: number().int().positive().optional(),
|
|
17297
|
+
steps: record(string(), DeviceStepConfigSchema).optional()
|
|
17298
|
+
}))
|
|
17299
|
+
}), object({ success: literal(true) }), {
|
|
17300
|
+
kind: "mutation",
|
|
17301
|
+
auth: "admin"
|
|
17302
|
+
}), method(object({ nodeId: string() }), NodeInferenceDevicesSchema), method(object({ agentNodeId: string() }), object({
|
|
17182
17303
|
success: literal(true),
|
|
17183
17304
|
/** Hardware-aware default detection model now in effect on the node (null when unresolvable). */
|
|
17184
17305
|
effectiveModelId: string().nullable(),
|
|
@@ -17194,9 +17315,10 @@ method(object({
|
|
|
17194
17315
|
}), object({ success: literal(true) }), {
|
|
17195
17316
|
kind: "mutation",
|
|
17196
17317
|
auth: "admin"
|
|
17197
|
-
}), method(object({ deviceId: number() }), record(string(), record(string(), CameraStepOverridePatchSchema)).nullable()), method(object({
|
|
17318
|
+
}), method(object({ deviceId: number() }), record(string(), record(string(), record(string(), CameraStepOverridePatchSchema))).nullable()), method(object({
|
|
17198
17319
|
deviceId: number(),
|
|
17199
17320
|
agentNodeId: string(),
|
|
17321
|
+
deviceKey: string(),
|
|
17200
17322
|
addonId: string(),
|
|
17201
17323
|
patch: CameraStepOverridePatchSchema.nullable()
|
|
17202
17324
|
}), object({ success: literal(true) }), {
|
|
@@ -17233,14 +17355,13 @@ method(object({
|
|
|
17233
17355
|
});
|
|
17234
17356
|
/**
|
|
17235
17357
|
* server-management — per-NODE singleton capability for a node's ROOT
|
|
17236
|
-
* package lifecycle (runtime-updatable node packages
|
|
17237
|
-
* agents).
|
|
17358
|
+
* package lifecycle (runtime-updatable node packages).
|
|
17238
17359
|
*
|
|
17239
|
-
*
|
|
17240
|
-
*
|
|
17241
|
-
*
|
|
17242
|
-
*
|
|
17243
|
-
*
|
|
17360
|
+
* Every node role runs the SAME root package (`@camstack/server`), which
|
|
17361
|
+
* carries the whole software stack in its npm dep tree, so ONE version
|
|
17362
|
+
* describes the node. Updates stage into `<dataDir>/server-root/` and apply
|
|
17363
|
+
* on restart via the baked starter (single-copy in-place swap — no probation,
|
|
17364
|
+
* no auto-rollback).
|
|
17244
17365
|
*
|
|
17245
17366
|
* Providers:
|
|
17246
17367
|
* - HUB: `ServerUpdateService` behind the `server-provided` mount
|
|
@@ -17348,7 +17469,8 @@ method(_void(), ServerPackageStatusSchema, { auth: "admin" }), method(_void(), S
|
|
|
17348
17469
|
/** Explicit target version; omitted = latest from the registry. */
|
|
17349
17470
|
version: string().optional() }), ServerUpdateActionResultSchema, {
|
|
17350
17471
|
kind: "mutation",
|
|
17351
|
-
auth: "admin"
|
|
17472
|
+
auth: "admin",
|
|
17473
|
+
timeoutMs: 16 * 6e4
|
|
17352
17474
|
}), method(_void(), ServerUpdateActionResultSchema, {
|
|
17353
17475
|
kind: "mutation",
|
|
17354
17476
|
auth: "admin"
|
|
@@ -18392,22 +18514,6 @@ var AddonAutoUpdateSchema = ChannelWithInheritSchema;
|
|
|
18392
18514
|
var RestartAddonResultSchema = unknown();
|
|
18393
18515
|
var InstallPackageResultSchema = unknown();
|
|
18394
18516
|
var ReloadPackagesResultSchema = unknown();
|
|
18395
|
-
/**
|
|
18396
|
-
* Result of `updateFrameworkPackage`. The cap method returns BEFORE the
|
|
18397
|
-
* server restarts so the admin UI can react to the `restartingAt`
|
|
18398
|
-
* timestamp (shows reconnect overlay). The transition from
|
|
18399
|
-
* `fromVersion` to `toVersion` will be confirmed by a subsequent
|
|
18400
|
-
* `system.restart-completed` event after the new process boots.
|
|
18401
|
-
*
|
|
18402
|
-
* Spec: docs/superpowers/specs/2026-05-14-framework-live-update-design.md
|
|
18403
|
-
*/
|
|
18404
|
-
var UpdateFrameworkPackageResultSchema = object({
|
|
18405
|
-
packageName: string(),
|
|
18406
|
-
fromVersion: string(),
|
|
18407
|
-
toVersion: string(),
|
|
18408
|
-
/** Ms-epoch the server scheduled its self-restart. */
|
|
18409
|
-
restartingAt: number()
|
|
18410
|
-
});
|
|
18411
18517
|
var BulkUpdateItemStatusSchema = _enum([
|
|
18412
18518
|
"queued",
|
|
18413
18519
|
"updating",
|
|
@@ -18535,13 +18641,6 @@ method(_void(), array(AddonListItemSchema).readonly()), method(object({
|
|
|
18535
18641
|
}), object({ success: literal(true) }), {
|
|
18536
18642
|
kind: "mutation",
|
|
18537
18643
|
auth: "admin"
|
|
18538
|
-
}), method(object({
|
|
18539
|
-
packageName: string().min(1),
|
|
18540
|
-
version: string().optional(),
|
|
18541
|
-
deferRestart: boolean().optional()
|
|
18542
|
-
}), UpdateFrameworkPackageResultSchema, {
|
|
18543
|
-
kind: "mutation",
|
|
18544
|
-
auth: "admin"
|
|
18545
18644
|
}), method(object({ name: string() }), array(PackageVersionInfoSchema).readonly()), method(object({ addonId: string() }), RestartAddonResultSchema, {
|
|
18546
18645
|
kind: "mutation",
|
|
18547
18646
|
auth: "admin"
|
|
@@ -19407,10 +19506,10 @@ var TopologyCategorySchema = object({
|
|
|
19407
19506
|
addons: array(TopologyCategoryAddonSchema).readonly()
|
|
19408
19507
|
});
|
|
19409
19508
|
/**
|
|
19410
|
-
* The node's runtime-updatable ROOT package (`@camstack/server`
|
|
19411
|
-
*
|
|
19412
|
-
* version visibility for the Server management surface. Nullable:
|
|
19413
|
-
* rows and
|
|
19509
|
+
* The node's runtime-updatable ROOT package (`@camstack/server` — the single
|
|
19510
|
+
* root package for every node role) as reported by its `registerNode`
|
|
19511
|
+
* manifest — version visibility for the Server management surface. Nullable:
|
|
19512
|
+
* offline rows and nodes that never reported one.
|
|
19414
19513
|
*/
|
|
19415
19514
|
var TopologyRootPackageSchema = object({
|
|
19416
19515
|
name: string(),
|
|
@@ -19798,17 +19897,28 @@ var PlatformScoreSchema = object({
|
|
|
19798
19897
|
format: _enum([
|
|
19799
19898
|
"onnx",
|
|
19800
19899
|
"coreml",
|
|
19801
|
-
"openvino"
|
|
19900
|
+
"openvino",
|
|
19901
|
+
"tflite"
|
|
19802
19902
|
]),
|
|
19803
19903
|
score: number(),
|
|
19804
19904
|
reason: string(),
|
|
19805
19905
|
available: boolean()
|
|
19806
19906
|
});
|
|
19907
|
+
var InferenceDeviceDescriptorSchema = object({
|
|
19908
|
+
key: string(),
|
|
19909
|
+
backend: string(),
|
|
19910
|
+
device: string(),
|
|
19911
|
+
format: ModelFormatSchema,
|
|
19912
|
+
runtime: literal("python"),
|
|
19913
|
+
score: number(),
|
|
19914
|
+
available: boolean()
|
|
19915
|
+
});
|
|
19807
19916
|
var PlatformCapabilitiesSchema = object({
|
|
19808
19917
|
hardware: HardwareInfoSchema,
|
|
19809
19918
|
scores: array(PlatformScoreSchema).readonly(),
|
|
19810
19919
|
bestScore: PlatformScoreSchema,
|
|
19811
|
-
pythonPath: string().nullable()
|
|
19920
|
+
pythonPath: string().nullable(),
|
|
19921
|
+
devices: array(InferenceDeviceDescriptorSchema).readonly()
|
|
19812
19922
|
});
|
|
19813
19923
|
var ModelRequirementSchema = object({
|
|
19814
19924
|
modelId: string(),
|
|
@@ -20687,12 +20797,6 @@ Object.freeze({
|
|
|
20687
20797
|
addonId: null,
|
|
20688
20798
|
access: "delete"
|
|
20689
20799
|
},
|
|
20690
|
-
"addons.updateFrameworkPackage": {
|
|
20691
|
-
capName: "addons",
|
|
20692
|
-
capScope: "system",
|
|
20693
|
-
addonId: null,
|
|
20694
|
-
access: "create"
|
|
20695
|
-
},
|
|
20696
20800
|
"addons.updatePackage": {
|
|
20697
20801
|
capName: "addons",
|
|
20698
20802
|
capScope: "system",
|
|
@@ -23465,12 +23569,6 @@ Object.freeze({
|
|
|
23465
23569
|
addonId: null,
|
|
23466
23570
|
access: "view"
|
|
23467
23571
|
},
|
|
23468
|
-
"pipelineExecutor.reprobeEngine": {
|
|
23469
|
-
capName: "pipeline-executor",
|
|
23470
|
-
capScope: "system",
|
|
23471
|
-
addonId: null,
|
|
23472
|
-
access: "create"
|
|
23473
|
-
},
|
|
23474
23572
|
"pipelineExecutor.runAudioTest": {
|
|
23475
23573
|
capName: "pipeline-executor",
|
|
23476
23574
|
capScope: "system",
|
|
@@ -23621,6 +23719,12 @@ Object.freeze({
|
|
|
23621
23719
|
addonId: null,
|
|
23622
23720
|
access: "view"
|
|
23623
23721
|
},
|
|
23722
|
+
"pipelineOrchestrator.getNodeInferenceDevices": {
|
|
23723
|
+
capName: "pipeline-orchestrator",
|
|
23724
|
+
capScope: "system",
|
|
23725
|
+
addonId: null,
|
|
23726
|
+
access: "view"
|
|
23727
|
+
},
|
|
23624
23728
|
"pipelineOrchestrator.getPipelineAssignment": {
|
|
23625
23729
|
capName: "pipeline-orchestrator",
|
|
23626
23730
|
capScope: "system",
|
|
@@ -23633,6 +23737,12 @@ Object.freeze({
|
|
|
23633
23737
|
addonId: null,
|
|
23634
23738
|
access: "view"
|
|
23635
23739
|
},
|
|
23740
|
+
"pipelineOrchestrator.getPipelineDevicePin": {
|
|
23741
|
+
capName: "pipeline-orchestrator",
|
|
23742
|
+
capScope: "system",
|
|
23743
|
+
addonId: null,
|
|
23744
|
+
access: "view"
|
|
23745
|
+
},
|
|
23636
23746
|
"pipelineOrchestrator.listAgentSettings": {
|
|
23637
23747
|
capName: "pipeline-orchestrator",
|
|
23638
23748
|
capScope: "system",
|
|
@@ -23675,19 +23785,19 @@ Object.freeze({
|
|
|
23675
23785
|
addonId: null,
|
|
23676
23786
|
access: "create"
|
|
23677
23787
|
},
|
|
23678
|
-
"pipelineOrchestrator.
|
|
23788
|
+
"pipelineOrchestrator.setAgentCapabilities": {
|
|
23679
23789
|
capName: "pipeline-orchestrator",
|
|
23680
23790
|
capScope: "system",
|
|
23681
23791
|
addonId: null,
|
|
23682
23792
|
access: "create"
|
|
23683
23793
|
},
|
|
23684
|
-
"pipelineOrchestrator.
|
|
23794
|
+
"pipelineOrchestrator.setAgentDetectWeight": {
|
|
23685
23795
|
capName: "pipeline-orchestrator",
|
|
23686
23796
|
capScope: "system",
|
|
23687
23797
|
addonId: null,
|
|
23688
23798
|
access: "create"
|
|
23689
23799
|
},
|
|
23690
|
-
"pipelineOrchestrator.
|
|
23800
|
+
"pipelineOrchestrator.setAgentInferenceDevices": {
|
|
23691
23801
|
capName: "pipeline-orchestrator",
|
|
23692
23802
|
capScope: "system",
|
|
23693
23803
|
addonId: null,
|
|
@@ -23729,6 +23839,12 @@ Object.freeze({
|
|
|
23729
23839
|
addonId: null,
|
|
23730
23840
|
access: "create"
|
|
23731
23841
|
},
|
|
23842
|
+
"pipelineOrchestrator.setPipelineDevicePin": {
|
|
23843
|
+
capName: "pipeline-orchestrator",
|
|
23844
|
+
capScope: "system",
|
|
23845
|
+
addonId: null,
|
|
23846
|
+
access: "create"
|
|
23847
|
+
},
|
|
23732
23848
|
"pipelineOrchestrator.unassignAudio": {
|
|
23733
23849
|
capName: "pipeline-orchestrator",
|
|
23734
23850
|
capScope: "system",
|
|
@@ -25281,32 +25397,6 @@ Object.freeze({
|
|
|
25281
25397
|
"network-access": "ingress",
|
|
25282
25398
|
"smtp-provider": "email"
|
|
25283
25399
|
});
|
|
25284
|
-
var frameworkSwapPackageSchema = object({
|
|
25285
|
-
name: string(),
|
|
25286
|
-
stagedPath: string(),
|
|
25287
|
-
backupPath: string(),
|
|
25288
|
-
toVersion: string(),
|
|
25289
|
-
fromVersion: string().nullable()
|
|
25290
|
-
});
|
|
25291
|
-
object({
|
|
25292
|
-
jobId: string(),
|
|
25293
|
-
taskId: string(),
|
|
25294
|
-
packages: array(frameworkSwapPackageSchema),
|
|
25295
|
-
requestedAtMs: number(),
|
|
25296
|
-
schemaVersion: literal(1)
|
|
25297
|
-
});
|
|
25298
|
-
object({
|
|
25299
|
-
jobId: string(),
|
|
25300
|
-
taskId: string(),
|
|
25301
|
-
backups: array(object({
|
|
25302
|
-
name: string(),
|
|
25303
|
-
backupPath: string(),
|
|
25304
|
-
livePath: string()
|
|
25305
|
-
})),
|
|
25306
|
-
appliedAtMs: number(),
|
|
25307
|
-
bootAttempts: number(),
|
|
25308
|
-
schemaVersion: literal(1)
|
|
25309
|
-
});
|
|
25310
25400
|
/**
|
|
25311
25401
|
* Fixed-capacity ring buffer. When full, push() overwrites the oldest entry.
|
|
25312
25402
|
* drain() returns up to maxCount items in FIFO order and removes them.
|
package/dist/index.mjs
CHANGED
|
@@ -7080,6 +7080,17 @@ var ModelCatalogEntrySchema = object({
|
|
|
7080
7080
|
"imagenet",
|
|
7081
7081
|
"none"
|
|
7082
7082
|
]).optional(),
|
|
7083
|
+
/**
|
|
7084
|
+
* The model already applies softmax IN-GRAPH — its raw output is a
|
|
7085
|
+
* probability distribution, not logits. When set, the `softmax`
|
|
7086
|
+
* postprocessor must NOT re-apply softmax: re-softmaxing an already-normalised
|
|
7087
|
+
* probability vector collapses it toward uniform (top-1 score craters far
|
|
7088
|
+
* below its true value, making every confidence gate meaningless). Absent ⇒
|
|
7089
|
+
* the output is raw logits and the postprocessor applies softmax (the normal
|
|
7090
|
+
* case). Set on the Google AIY Birds `bird-classifier` (softmax baked into the
|
|
7091
|
+
* TF graph). Threaded to the Python pool via `PoolModelConfig.outputProbabilities`.
|
|
7092
|
+
*/
|
|
7093
|
+
outputProbabilities: boolean().optional(),
|
|
7083
7094
|
preprocessMode: _enum(["letterbox", "resize"]).optional(),
|
|
7084
7095
|
/**
|
|
7085
7096
|
* Per-MODEL postprocessor override. Absent ⇒ the step's own
|
|
@@ -11093,10 +11104,7 @@ var ConfigUISchemaNullableBridge = custom();
|
|
|
11093
11104
|
var InferenceCapabilitiesBridge = custom();
|
|
11094
11105
|
var ModelAvailabilityListBridge = custom();
|
|
11095
11106
|
var PipelineRunResultBridge = custom();
|
|
11096
|
-
method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngineChoiceSchema), method(PipelineEngineChoiceSchema, array(PipelineDefaultStepSchema)), method(_void(),
|
|
11097
|
-
kind: "mutation",
|
|
11098
|
-
auth: "admin"
|
|
11099
|
-
}), method(object({ nodeId: string() }), EngineProvisioningSchema), method(_void(), record(string(), object({
|
|
11107
|
+
method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngineChoiceSchema), method(PipelineEngineChoiceSchema, array(PipelineDefaultStepSchema)), method(object({ nodeId: string() }), EngineProvisioningSchema), method(_void(), record(string(), object({
|
|
11100
11108
|
modelId: string(),
|
|
11101
11109
|
settings: record(string(), unknown()).readonly()
|
|
11102
11110
|
}))), method(object({ steps: record(string(), object({
|
|
@@ -11156,13 +11164,33 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
|
|
|
11156
11164
|
* (inputClasses ≠ null) are skipped and served per-track via
|
|
11157
11165
|
* pipelineRunner.runDetailSubtree (two-plane design).
|
|
11158
11166
|
*/
|
|
11159
|
-
plane: _enum(["full", "frame"]).optional()
|
|
11167
|
+
plane: _enum(["full", "frame"]).optional(),
|
|
11168
|
+
/**
|
|
11169
|
+
* Inference-device selector (Phase 2 multi-device). Format
|
|
11170
|
+
* `<backend>:<device>` (e.g. `openvino:gpu`, `edgetpu:usb`, `cpu`).
|
|
11171
|
+
* Omitted ⇒ the runner's default device (current single-engine
|
|
11172
|
+
* behaviour). Selects WHICH device pool of the node runs the call.
|
|
11173
|
+
*/
|
|
11174
|
+
deviceKey: string().optional()
|
|
11160
11175
|
}), PipelineRunResultBridge, { kind: "mutation" }), method(object({
|
|
11161
11176
|
engine: PipelineEngineChoiceSchema.optional(),
|
|
11162
11177
|
steps: array(PipelineStepInputSchema).min(1),
|
|
11163
11178
|
frames: array(FrameInputSchema).min(1).max(255),
|
|
11164
11179
|
deviceId: number().optional(),
|
|
11165
|
-
sessionId: string().optional()
|
|
11180
|
+
sessionId: string().optional(),
|
|
11181
|
+
/**
|
|
11182
|
+
* Pure-inference benchmark hint. A NONZERO uint32 pins every frame in
|
|
11183
|
+
* the batch to the Python pool's bench preprocess cache
|
|
11184
|
+
* (`_bench_frame_id`) so a REPEATED benchmark frame is decoded +
|
|
11185
|
+
* preprocessed ONCE and every later inference is a pure-inference cache
|
|
11186
|
+
* hit — the sustained-throughput run measures inference, not
|
|
11187
|
+
* decode+preprocess+infer. Omitted/0 for live frames (all different →
|
|
11188
|
+
* full preprocess every call, correct). Fresh per sustained run;
|
|
11189
|
+
* released via `uncacheFrame`.
|
|
11190
|
+
*/
|
|
11191
|
+
frameId: number().int().nonnegative().optional(),
|
|
11192
|
+
/** Inference-device selector (Phase 2 multi-device); see runPipeline. */
|
|
11193
|
+
deviceKey: string().optional()
|
|
11166
11194
|
}), object({ results: array(PipelineRunResultBridge).readonly() }), { kind: "mutation" }), method(object({
|
|
11167
11195
|
data: _instanceof(Uint8Array),
|
|
11168
11196
|
width: number().int().positive(),
|
|
@@ -11194,8 +11222,18 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
|
|
|
11194
11222
|
* - `runtime` — main camera-serving engine (no idle TTL).
|
|
11195
11223
|
* - `warm-override` — benchmark/test override held in the warm
|
|
11196
11224
|
* cache; auto-disposed after the idle TTL.
|
|
11225
|
+
* - `device-pool` — a concurrent per-device pool (Phase 2
|
|
11226
|
+
* multi-device, keyed by `deviceKey`) resolved
|
|
11227
|
+
* via `resolveDeviceFactory`. Runs alongside the
|
|
11228
|
+
* `runtime` engine on a DIFFERENT accelerator
|
|
11229
|
+
* (NPU / iGPU / Coral) — this is how the
|
|
11230
|
+
* Engines tab shows all pools running at once.
|
|
11197
11231
|
*/
|
|
11198
|
-
kind: _enum([
|
|
11232
|
+
kind: _enum([
|
|
11233
|
+
"runtime",
|
|
11234
|
+
"warm-override",
|
|
11235
|
+
"device-pool"
|
|
11236
|
+
]),
|
|
11199
11237
|
/** Native pid of the underlying Python pool (null when no pool). */
|
|
11200
11238
|
poolPid: number().nullable(),
|
|
11201
11239
|
/** ms since this factory was last used (null when not warm-tracked). */
|
|
@@ -11537,7 +11575,14 @@ var RunnerCameraConfigSchema = object({
|
|
|
11537
11575
|
* camera's detect node differs from its source-owner (P2d, gated by the
|
|
11538
11576
|
* `remoteSourcingNodes` rollout setting).
|
|
11539
11577
|
*/
|
|
11540
|
-
frameSource: RunnerFrameSourceSchema.default({ kind: "local-broker" })
|
|
11578
|
+
frameSource: RunnerFrameSourceSchema.default({ kind: "local-broker" }),
|
|
11579
|
+
/**
|
|
11580
|
+
* Inference-device selector for this camera's sessions (Phase 2 multi-device).
|
|
11581
|
+
* Format `<backend>:<device>` (e.g. `openvino:gpu`, `edgetpu:usb`, `cpu`);
|
|
11582
|
+
* omitted ⇒ the runner's default device. The engine itself stays node-local —
|
|
11583
|
+
* this only selects WHICH device pool of that node runs the session.
|
|
11584
|
+
*/
|
|
11585
|
+
deviceKey: string().optional()
|
|
11541
11586
|
});
|
|
11542
11587
|
motionFpsField.min, motionFpsField.max, motionFpsField.step, motionFpsField.default, detectionFpsField.min, detectionFpsField.max, detectionFpsField.step, detectionFpsField.default, motionCooldownMsField.min, motionCooldownMsField.max, motionCooldownMsField.step, motionCooldownMsField.default, occupancyRecheckSecField.min, occupancyRecheckSecField.max, occupancyRecheckSecField.step, occupancyRecheckSecField.default, occupancyRecheckFramesField.min, occupancyRecheckFramesField.max, occupancyRecheckFramesField.step, occupancyRecheckFramesField.default;
|
|
11543
11588
|
/**
|
|
@@ -11558,6 +11603,19 @@ var RunnerLocalLoadSchema = object({
|
|
|
11558
11603
|
avgInferenceTimeMs: number(),
|
|
11559
11604
|
/** Total queue depth across motion + detection queues. */
|
|
11560
11605
|
queueDepthTotal: number(),
|
|
11606
|
+
/**
|
|
11607
|
+
* Per-inference-device live load (multi-device C4). One entry per deviceKey
|
|
11608
|
+
* this runner currently has attached cameras on, so the orchestrator's second
|
|
11609
|
+
* `balance()` pass (over a node's devices) weights on real per-pool session
|
|
11610
|
+
* counts. Empty on single-device / pre-multi-device runners. `queueDepthTotal`
|
|
11611
|
+
* per device is 0 until the pool backlog gets a public accessor (follow-up).
|
|
11612
|
+
*/
|
|
11613
|
+
devices: array(object({
|
|
11614
|
+
deviceKey: string(),
|
|
11615
|
+
backend: string(),
|
|
11616
|
+
attachedCameras: number(),
|
|
11617
|
+
queueDepthTotal: number()
|
|
11618
|
+
})).default([]),
|
|
11561
11619
|
/** Hardware capability flags reported by this node. */
|
|
11562
11620
|
hardware: object({
|
|
11563
11621
|
hasGpu: boolean(),
|
|
@@ -13033,6 +13091,8 @@ method(_void(), _void(), { kind: "mutation" }), method(_void(), _void(), { kind:
|
|
|
13033
13091
|
kind: "mutation",
|
|
13034
13092
|
auth: "admin"
|
|
13035
13093
|
});
|
|
13094
|
+
DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Camera, DeviceType.Hub, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder;
|
|
13095
|
+
new Set(Object.values(DeviceType));
|
|
13036
13096
|
/**
|
|
13037
13097
|
* `addon-pages` — system-scoped singleton aggregator cap. Public-facing
|
|
13038
13098
|
* surface that admin-ui consumes through `useAddonPagesListPages()`.
|
|
@@ -16832,13 +16892,11 @@ var PipelineTemplateSchema = object({
|
|
|
16832
16892
|
createdAt: string(),
|
|
16833
16893
|
updatedAt: string()
|
|
16834
16894
|
});
|
|
16835
|
-
var
|
|
16836
|
-
enabled: boolean(),
|
|
16895
|
+
var DeviceStepConfigSchema = object({
|
|
16837
16896
|
modelId: string().optional(),
|
|
16838
|
-
settings: record(string(), unknown()).
|
|
16897
|
+
settings: record(string(), unknown()).optional()
|
|
16839
16898
|
});
|
|
16840
16899
|
var AgentPipelineSettingsSchema = object({
|
|
16841
|
-
addonDefaults: record(string(), AgentAddonConfigSchema).readonly(),
|
|
16842
16900
|
maxCameras: number().int().nonnegative().nullable().default(null),
|
|
16843
16901
|
/** Per-node detection weight (relative share for the quota balancer). */
|
|
16844
16902
|
detectWeight: number().positive().optional(),
|
|
@@ -16862,7 +16920,22 @@ var AgentPipelineSettingsSchema = object({
|
|
|
16862
16920
|
* it already uses to reach the hub). Set this only when the auto-detected
|
|
16863
16921
|
* address is wrong (multi-homed host, NAT, custom interface).
|
|
16864
16922
|
*/
|
|
16865
|
-
reachableHost: string().optional()
|
|
16923
|
+
reachableHost: string().optional(),
|
|
16924
|
+
/**
|
|
16925
|
+
* Multi-device inference opt-in (Phase 4). Per-node map deviceKey → {enabled,
|
|
16926
|
+
* weight, steps}. Absent / all-disabled ⇒ the node's single default
|
|
16927
|
+
* accelerator (safe default); two+ enabled ⇒ the dispatcher balances
|
|
16928
|
+
* detection sessions across them so they run CONCURRENTLY. `steps` is the
|
|
16929
|
+
* per-(node,device) BASE provisioning (`stepId → {modelId?, settings?}`) —
|
|
16930
|
+
* the default model/settings for every camera landing on that accelerator;
|
|
16931
|
+
* a stepId absent ⇒ the step uses that device's format default.
|
|
16932
|
+
*/
|
|
16933
|
+
inferenceDevices: record(string(), object({
|
|
16934
|
+
enabled: boolean(),
|
|
16935
|
+
weight: number().positive().optional(),
|
|
16936
|
+
maxSessions: number().int().positive().optional(),
|
|
16937
|
+
steps: record(string(), DeviceStepConfigSchema).optional()
|
|
16938
|
+
})).optional()
|
|
16866
16939
|
});
|
|
16867
16940
|
var CameraPipelineForAgentSchema = object({
|
|
16868
16941
|
steps: array(PipelineStepInputSchema).readonly(),
|
|
@@ -16872,14 +16945,13 @@ var CameraPipelineForAgentSchema = object({
|
|
|
16872
16945
|
}).nullable()
|
|
16873
16946
|
});
|
|
16874
16947
|
var CameraStepOverridePatchSchema = object({
|
|
16875
|
-
enabled: boolean().optional(),
|
|
16876
16948
|
modelId: string().optional(),
|
|
16877
16949
|
settings: record(string(), unknown()).readonly().optional()
|
|
16878
16950
|
});
|
|
16879
16951
|
var CameraPipelineSettingsSchema = object({
|
|
16880
16952
|
pinnedAgentNodeId: string().optional(),
|
|
16881
16953
|
stepToggles: record(string(), boolean()).optional(),
|
|
16882
|
-
|
|
16954
|
+
stepOverridesByDevice: record(string(), record(string(), record(string(), CameraStepOverridePatchSchema))).optional(),
|
|
16883
16955
|
pipelineByAgent: record(string(), CameraPipelineForAgentSchema).optional()
|
|
16884
16956
|
});
|
|
16885
16957
|
/**
|
|
@@ -17093,6 +17165,44 @@ var CameraStatusSchema = object({
|
|
|
17093
17165
|
/** Unix timestamp (ms) when this snapshot was composed server-side. */
|
|
17094
17166
|
fetchedAt: number()
|
|
17095
17167
|
});
|
|
17168
|
+
var NodeInferenceDeviceSchema = object({
|
|
17169
|
+
/** Stable per-node device key, e.g. `openvino:npu`, `edgetpu:usb`, `cpu`. */
|
|
17170
|
+
key: string(),
|
|
17171
|
+
backend: string(),
|
|
17172
|
+
device: string(),
|
|
17173
|
+
format: _enum(MODEL_FORMATS),
|
|
17174
|
+
/** Whether the node's live probe reports the device as usable right now. */
|
|
17175
|
+
available: boolean(),
|
|
17176
|
+
/**
|
|
17177
|
+
* Whether this device participates in dispatch. AUTO default (spec C2):
|
|
17178
|
+
* accelerators are opt-OUT (a discovered NPU/iGPU/Coral/ANE with no stored
|
|
17179
|
+
* entry is `true`); CPU is opt-IN (`false` by default — the fallback pool,
|
|
17180
|
+
* not a balanced target). An explicit stored value always wins; a stored-only
|
|
17181
|
+
* (unavailable) key keeps its stored value.
|
|
17182
|
+
*/
|
|
17183
|
+
enabled: boolean(),
|
|
17184
|
+
/** Relative balancer weight for the enabled device (default 1). */
|
|
17185
|
+
weight: number(),
|
|
17186
|
+
/** Per-device concurrent-session cap; null = unlimited (multi-device C4). */
|
|
17187
|
+
maxSessions: number().nullable(),
|
|
17188
|
+
/** Object-detection model the executor defaults to for this deviceKey. */
|
|
17189
|
+
defaultModelId: string(),
|
|
17190
|
+
/**
|
|
17191
|
+
* Per-(node,device) BASE provisioning (C7.2/C7.4) — the RAW stored
|
|
17192
|
+
* `stepId → {modelId?, settings?}` map from `inferenceDevices[key].steps`.
|
|
17193
|
+
* Absent/empty ⇒ no base (every step uses its device format default). The
|
|
17194
|
+
* UI cross-references `pipelineExecutor.getSchema` for the models actually
|
|
17195
|
+
* available per format; this is the stored selection that becomes the
|
|
17196
|
+
* default for EVERY camera landing on this accelerator.
|
|
17197
|
+
*/
|
|
17198
|
+
steps: record(string(), DeviceStepConfigSchema).optional()
|
|
17199
|
+
});
|
|
17200
|
+
var NodeInferenceDevicesSchema = object({
|
|
17201
|
+
nodeId: string(),
|
|
17202
|
+
/** False when the node's platform-probe was unreachable (no live device set). */
|
|
17203
|
+
reachable: boolean(),
|
|
17204
|
+
devices: array(NodeInferenceDeviceSchema).readonly()
|
|
17205
|
+
});
|
|
17096
17206
|
method(object({
|
|
17097
17207
|
deviceId: number(),
|
|
17098
17208
|
agentNodeId: string()
|
|
@@ -17102,7 +17212,13 @@ method(object({
|
|
|
17102
17212
|
}), method(object({ deviceId: number() }), object({ success: literal(true) }), {
|
|
17103
17213
|
kind: "mutation",
|
|
17104
17214
|
auth: "admin"
|
|
17105
|
-
}), method(
|
|
17215
|
+
}), method(object({
|
|
17216
|
+
deviceId: number(),
|
|
17217
|
+
deviceKey: string()
|
|
17218
|
+
}), object({ success: literal(true) }), {
|
|
17219
|
+
kind: "mutation",
|
|
17220
|
+
auth: "admin"
|
|
17221
|
+
}), method(object({ deviceId: number() }), object({ deviceKey: string().nullable() })), method(_void(), object({ migrated: number() }), {
|
|
17106
17222
|
kind: "mutation",
|
|
17107
17223
|
auth: "admin"
|
|
17108
17224
|
}), method(_void(), array(PipelineAssignmentSchema).readonly()), method(object({ deviceId: number() }), PipelineAssignmentSchema.nullable()), method(_void(), array(AgentLoadSummarySchema).readonly()), method(_void(), GlobalMetricsSchema), method(object({ deviceId: number() }), CameraMetricsSchema.nullable()), method(object({ nodeId: string() }), CapabilityBindingsSchema), method(object({
|
|
@@ -17136,13 +17252,7 @@ method(object({
|
|
|
17136
17252
|
}))), method(object({ agentNodeId: string() }), AgentPipelineSettingsSchema.nullable()), method(_void(), array(object({
|
|
17137
17253
|
nodeId: string(),
|
|
17138
17254
|
settings: AgentPipelineSettingsSchema
|
|
17139
|
-
})).readonly()), method(object({
|
|
17140
|
-
agentNodeId: string(),
|
|
17141
|
-
defaults: record(string(), AgentAddonConfigSchema)
|
|
17142
|
-
}), object({ success: literal(true) }), {
|
|
17143
|
-
kind: "mutation",
|
|
17144
|
-
auth: "admin"
|
|
17145
|
-
}), method(object({ agentNodeId: string() }), object({
|
|
17255
|
+
})).readonly()), method(object({ agentNodeId: string() }), object({
|
|
17146
17256
|
success: boolean(),
|
|
17147
17257
|
removed: boolean()
|
|
17148
17258
|
}), {
|
|
@@ -17174,7 +17284,18 @@ method(object({
|
|
|
17174
17284
|
}), object({ success: literal(true) }), {
|
|
17175
17285
|
kind: "mutation",
|
|
17176
17286
|
auth: "admin"
|
|
17177
|
-
}), method(object({
|
|
17287
|
+
}), method(object({
|
|
17288
|
+
agentNodeId: string(),
|
|
17289
|
+
inferenceDevices: record(string(), object({
|
|
17290
|
+
enabled: boolean(),
|
|
17291
|
+
weight: number().positive().optional(),
|
|
17292
|
+
maxSessions: number().int().positive().optional(),
|
|
17293
|
+
steps: record(string(), DeviceStepConfigSchema).optional()
|
|
17294
|
+
}))
|
|
17295
|
+
}), object({ success: literal(true) }), {
|
|
17296
|
+
kind: "mutation",
|
|
17297
|
+
auth: "admin"
|
|
17298
|
+
}), method(object({ nodeId: string() }), NodeInferenceDevicesSchema), method(object({ agentNodeId: string() }), object({
|
|
17178
17299
|
success: literal(true),
|
|
17179
17300
|
/** Hardware-aware default detection model now in effect on the node (null when unresolvable). */
|
|
17180
17301
|
effectiveModelId: string().nullable(),
|
|
@@ -17190,9 +17311,10 @@ method(object({
|
|
|
17190
17311
|
}), object({ success: literal(true) }), {
|
|
17191
17312
|
kind: "mutation",
|
|
17192
17313
|
auth: "admin"
|
|
17193
|
-
}), method(object({ deviceId: number() }), record(string(), record(string(), CameraStepOverridePatchSchema)).nullable()), method(object({
|
|
17314
|
+
}), method(object({ deviceId: number() }), record(string(), record(string(), record(string(), CameraStepOverridePatchSchema))).nullable()), method(object({
|
|
17194
17315
|
deviceId: number(),
|
|
17195
17316
|
agentNodeId: string(),
|
|
17317
|
+
deviceKey: string(),
|
|
17196
17318
|
addonId: string(),
|
|
17197
17319
|
patch: CameraStepOverridePatchSchema.nullable()
|
|
17198
17320
|
}), object({ success: literal(true) }), {
|
|
@@ -17229,14 +17351,13 @@ method(object({
|
|
|
17229
17351
|
});
|
|
17230
17352
|
/**
|
|
17231
17353
|
* server-management — per-NODE singleton capability for a node's ROOT
|
|
17232
|
-
* package lifecycle (runtime-updatable node packages
|
|
17233
|
-
* agents).
|
|
17354
|
+
* package lifecycle (runtime-updatable node packages).
|
|
17234
17355
|
*
|
|
17235
|
-
*
|
|
17236
|
-
*
|
|
17237
|
-
*
|
|
17238
|
-
*
|
|
17239
|
-
*
|
|
17356
|
+
* Every node role runs the SAME root package (`@camstack/server`), which
|
|
17357
|
+
* carries the whole software stack in its npm dep tree, so ONE version
|
|
17358
|
+
* describes the node. Updates stage into `<dataDir>/server-root/` and apply
|
|
17359
|
+
* on restart via the baked starter (single-copy in-place swap — no probation,
|
|
17360
|
+
* no auto-rollback).
|
|
17240
17361
|
*
|
|
17241
17362
|
* Providers:
|
|
17242
17363
|
* - HUB: `ServerUpdateService` behind the `server-provided` mount
|
|
@@ -17344,7 +17465,8 @@ method(_void(), ServerPackageStatusSchema, { auth: "admin" }), method(_void(), S
|
|
|
17344
17465
|
/** Explicit target version; omitted = latest from the registry. */
|
|
17345
17466
|
version: string().optional() }), ServerUpdateActionResultSchema, {
|
|
17346
17467
|
kind: "mutation",
|
|
17347
|
-
auth: "admin"
|
|
17468
|
+
auth: "admin",
|
|
17469
|
+
timeoutMs: 16 * 6e4
|
|
17348
17470
|
}), method(_void(), ServerUpdateActionResultSchema, {
|
|
17349
17471
|
kind: "mutation",
|
|
17350
17472
|
auth: "admin"
|
|
@@ -18388,22 +18510,6 @@ var AddonAutoUpdateSchema = ChannelWithInheritSchema;
|
|
|
18388
18510
|
var RestartAddonResultSchema = unknown();
|
|
18389
18511
|
var InstallPackageResultSchema = unknown();
|
|
18390
18512
|
var ReloadPackagesResultSchema = unknown();
|
|
18391
|
-
/**
|
|
18392
|
-
* Result of `updateFrameworkPackage`. The cap method returns BEFORE the
|
|
18393
|
-
* server restarts so the admin UI can react to the `restartingAt`
|
|
18394
|
-
* timestamp (shows reconnect overlay). The transition from
|
|
18395
|
-
* `fromVersion` to `toVersion` will be confirmed by a subsequent
|
|
18396
|
-
* `system.restart-completed` event after the new process boots.
|
|
18397
|
-
*
|
|
18398
|
-
* Spec: docs/superpowers/specs/2026-05-14-framework-live-update-design.md
|
|
18399
|
-
*/
|
|
18400
|
-
var UpdateFrameworkPackageResultSchema = object({
|
|
18401
|
-
packageName: string(),
|
|
18402
|
-
fromVersion: string(),
|
|
18403
|
-
toVersion: string(),
|
|
18404
|
-
/** Ms-epoch the server scheduled its self-restart. */
|
|
18405
|
-
restartingAt: number()
|
|
18406
|
-
});
|
|
18407
18513
|
var BulkUpdateItemStatusSchema = _enum([
|
|
18408
18514
|
"queued",
|
|
18409
18515
|
"updating",
|
|
@@ -18531,13 +18637,6 @@ method(_void(), array(AddonListItemSchema).readonly()), method(object({
|
|
|
18531
18637
|
}), object({ success: literal(true) }), {
|
|
18532
18638
|
kind: "mutation",
|
|
18533
18639
|
auth: "admin"
|
|
18534
|
-
}), method(object({
|
|
18535
|
-
packageName: string().min(1),
|
|
18536
|
-
version: string().optional(),
|
|
18537
|
-
deferRestart: boolean().optional()
|
|
18538
|
-
}), UpdateFrameworkPackageResultSchema, {
|
|
18539
|
-
kind: "mutation",
|
|
18540
|
-
auth: "admin"
|
|
18541
18640
|
}), method(object({ name: string() }), array(PackageVersionInfoSchema).readonly()), method(object({ addonId: string() }), RestartAddonResultSchema, {
|
|
18542
18641
|
kind: "mutation",
|
|
18543
18642
|
auth: "admin"
|
|
@@ -19403,10 +19502,10 @@ var TopologyCategorySchema = object({
|
|
|
19403
19502
|
addons: array(TopologyCategoryAddonSchema).readonly()
|
|
19404
19503
|
});
|
|
19405
19504
|
/**
|
|
19406
|
-
* The node's runtime-updatable ROOT package (`@camstack/server`
|
|
19407
|
-
*
|
|
19408
|
-
* version visibility for the Server management surface. Nullable:
|
|
19409
|
-
* rows and
|
|
19505
|
+
* The node's runtime-updatable ROOT package (`@camstack/server` — the single
|
|
19506
|
+
* root package for every node role) as reported by its `registerNode`
|
|
19507
|
+
* manifest — version visibility for the Server management surface. Nullable:
|
|
19508
|
+
* offline rows and nodes that never reported one.
|
|
19410
19509
|
*/
|
|
19411
19510
|
var TopologyRootPackageSchema = object({
|
|
19412
19511
|
name: string(),
|
|
@@ -19794,17 +19893,28 @@ var PlatformScoreSchema = object({
|
|
|
19794
19893
|
format: _enum([
|
|
19795
19894
|
"onnx",
|
|
19796
19895
|
"coreml",
|
|
19797
|
-
"openvino"
|
|
19896
|
+
"openvino",
|
|
19897
|
+
"tflite"
|
|
19798
19898
|
]),
|
|
19799
19899
|
score: number(),
|
|
19800
19900
|
reason: string(),
|
|
19801
19901
|
available: boolean()
|
|
19802
19902
|
});
|
|
19903
|
+
var InferenceDeviceDescriptorSchema = object({
|
|
19904
|
+
key: string(),
|
|
19905
|
+
backend: string(),
|
|
19906
|
+
device: string(),
|
|
19907
|
+
format: ModelFormatSchema,
|
|
19908
|
+
runtime: literal("python"),
|
|
19909
|
+
score: number(),
|
|
19910
|
+
available: boolean()
|
|
19911
|
+
});
|
|
19803
19912
|
var PlatformCapabilitiesSchema = object({
|
|
19804
19913
|
hardware: HardwareInfoSchema,
|
|
19805
19914
|
scores: array(PlatformScoreSchema).readonly(),
|
|
19806
19915
|
bestScore: PlatformScoreSchema,
|
|
19807
|
-
pythonPath: string().nullable()
|
|
19916
|
+
pythonPath: string().nullable(),
|
|
19917
|
+
devices: array(InferenceDeviceDescriptorSchema).readonly()
|
|
19808
19918
|
});
|
|
19809
19919
|
var ModelRequirementSchema = object({
|
|
19810
19920
|
modelId: string(),
|
|
@@ -20683,12 +20793,6 @@ Object.freeze({
|
|
|
20683
20793
|
addonId: null,
|
|
20684
20794
|
access: "delete"
|
|
20685
20795
|
},
|
|
20686
|
-
"addons.updateFrameworkPackage": {
|
|
20687
|
-
capName: "addons",
|
|
20688
|
-
capScope: "system",
|
|
20689
|
-
addonId: null,
|
|
20690
|
-
access: "create"
|
|
20691
|
-
},
|
|
20692
20796
|
"addons.updatePackage": {
|
|
20693
20797
|
capName: "addons",
|
|
20694
20798
|
capScope: "system",
|
|
@@ -23461,12 +23565,6 @@ Object.freeze({
|
|
|
23461
23565
|
addonId: null,
|
|
23462
23566
|
access: "view"
|
|
23463
23567
|
},
|
|
23464
|
-
"pipelineExecutor.reprobeEngine": {
|
|
23465
|
-
capName: "pipeline-executor",
|
|
23466
|
-
capScope: "system",
|
|
23467
|
-
addonId: null,
|
|
23468
|
-
access: "create"
|
|
23469
|
-
},
|
|
23470
23568
|
"pipelineExecutor.runAudioTest": {
|
|
23471
23569
|
capName: "pipeline-executor",
|
|
23472
23570
|
capScope: "system",
|
|
@@ -23617,6 +23715,12 @@ Object.freeze({
|
|
|
23617
23715
|
addonId: null,
|
|
23618
23716
|
access: "view"
|
|
23619
23717
|
},
|
|
23718
|
+
"pipelineOrchestrator.getNodeInferenceDevices": {
|
|
23719
|
+
capName: "pipeline-orchestrator",
|
|
23720
|
+
capScope: "system",
|
|
23721
|
+
addonId: null,
|
|
23722
|
+
access: "view"
|
|
23723
|
+
},
|
|
23620
23724
|
"pipelineOrchestrator.getPipelineAssignment": {
|
|
23621
23725
|
capName: "pipeline-orchestrator",
|
|
23622
23726
|
capScope: "system",
|
|
@@ -23629,6 +23733,12 @@ Object.freeze({
|
|
|
23629
23733
|
addonId: null,
|
|
23630
23734
|
access: "view"
|
|
23631
23735
|
},
|
|
23736
|
+
"pipelineOrchestrator.getPipelineDevicePin": {
|
|
23737
|
+
capName: "pipeline-orchestrator",
|
|
23738
|
+
capScope: "system",
|
|
23739
|
+
addonId: null,
|
|
23740
|
+
access: "view"
|
|
23741
|
+
},
|
|
23632
23742
|
"pipelineOrchestrator.listAgentSettings": {
|
|
23633
23743
|
capName: "pipeline-orchestrator",
|
|
23634
23744
|
capScope: "system",
|
|
@@ -23671,19 +23781,19 @@ Object.freeze({
|
|
|
23671
23781
|
addonId: null,
|
|
23672
23782
|
access: "create"
|
|
23673
23783
|
},
|
|
23674
|
-
"pipelineOrchestrator.
|
|
23784
|
+
"pipelineOrchestrator.setAgentCapabilities": {
|
|
23675
23785
|
capName: "pipeline-orchestrator",
|
|
23676
23786
|
capScope: "system",
|
|
23677
23787
|
addonId: null,
|
|
23678
23788
|
access: "create"
|
|
23679
23789
|
},
|
|
23680
|
-
"pipelineOrchestrator.
|
|
23790
|
+
"pipelineOrchestrator.setAgentDetectWeight": {
|
|
23681
23791
|
capName: "pipeline-orchestrator",
|
|
23682
23792
|
capScope: "system",
|
|
23683
23793
|
addonId: null,
|
|
23684
23794
|
access: "create"
|
|
23685
23795
|
},
|
|
23686
|
-
"pipelineOrchestrator.
|
|
23796
|
+
"pipelineOrchestrator.setAgentInferenceDevices": {
|
|
23687
23797
|
capName: "pipeline-orchestrator",
|
|
23688
23798
|
capScope: "system",
|
|
23689
23799
|
addonId: null,
|
|
@@ -23725,6 +23835,12 @@ Object.freeze({
|
|
|
23725
23835
|
addonId: null,
|
|
23726
23836
|
access: "create"
|
|
23727
23837
|
},
|
|
23838
|
+
"pipelineOrchestrator.setPipelineDevicePin": {
|
|
23839
|
+
capName: "pipeline-orchestrator",
|
|
23840
|
+
capScope: "system",
|
|
23841
|
+
addonId: null,
|
|
23842
|
+
access: "create"
|
|
23843
|
+
},
|
|
23728
23844
|
"pipelineOrchestrator.unassignAudio": {
|
|
23729
23845
|
capName: "pipeline-orchestrator",
|
|
23730
23846
|
capScope: "system",
|
|
@@ -25277,32 +25393,6 @@ Object.freeze({
|
|
|
25277
25393
|
"network-access": "ingress",
|
|
25278
25394
|
"smtp-provider": "email"
|
|
25279
25395
|
});
|
|
25280
|
-
var frameworkSwapPackageSchema = object({
|
|
25281
|
-
name: string(),
|
|
25282
|
-
stagedPath: string(),
|
|
25283
|
-
backupPath: string(),
|
|
25284
|
-
toVersion: string(),
|
|
25285
|
-
fromVersion: string().nullable()
|
|
25286
|
-
});
|
|
25287
|
-
object({
|
|
25288
|
-
jobId: string(),
|
|
25289
|
-
taskId: string(),
|
|
25290
|
-
packages: array(frameworkSwapPackageSchema),
|
|
25291
|
-
requestedAtMs: number(),
|
|
25292
|
-
schemaVersion: literal(1)
|
|
25293
|
-
});
|
|
25294
|
-
object({
|
|
25295
|
-
jobId: string(),
|
|
25296
|
-
taskId: string(),
|
|
25297
|
-
backups: array(object({
|
|
25298
|
-
name: string(),
|
|
25299
|
-
backupPath: string(),
|
|
25300
|
-
livePath: string()
|
|
25301
|
-
})),
|
|
25302
|
-
appliedAtMs: number(),
|
|
25303
|
-
bootAttempts: number(),
|
|
25304
|
-
schemaVersion: literal(1)
|
|
25305
|
-
});
|
|
25306
25396
|
/**
|
|
25307
25397
|
* Fixed-capacity ring buffer. When full, push() overwrites the oldest entry.
|
|
25308
25398
|
* drain() returns up to maxCount items in FIFO order and removes them.
|