@camstack/addon-export-google 0.1.86 → 0.1.88

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.
@@ -77,7 +77,7 @@ function createApiDeviceGateway(deps) {
77
77
  };
78
78
  }
79
79
  //#endregion
80
- //#region ../types/dist/event-category-BGmz_oxW.mjs
80
+ //#region ../types/dist/event-category-B_0XEcLF.mjs
81
81
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
82
82
  EventCategory["SystemBoot"] = "system.boot";
83
83
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -578,15 +578,6 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
578
578
  EventCategory["AgentWsDisconnected"] = "agent.ws.disconnected";
579
579
  EventCategory["AgentBackupActivated"] = "agent.backup.activated";
580
580
  EventCategory["OrchestrationSettingsUpdated"] = "orchestration.settings-updated";
581
- /**
582
- * Per-agent hwaccel preference changed (user override set, cleared, or
583
- * re-probed). Observability event — decoders pull the current pref at
584
- * `createSession`, so running sessions keep their current backend until
585
- * they rotate naturally (camera add/remove, stream restart). Future
586
- * work can wire a listener in stream-broker that force-rotates live
587
- * sessions; for now this event powers logs + admin-UI toast feedback.
588
- */
589
- EventCategory["PipelineAgentHwaccelChanged"] = "pipeline.agent-hwaccel-changed";
590
581
  EventCategory["MotionAnalysis"] = "detection.motion-analysis";
591
582
  /** All raw motion zones from CCL before minArea filter — for UI debug overlay. */
592
583
  EventCategory["MotionZonesRaw"] = "detection.motion-zones-raw";
@@ -5457,7 +5448,7 @@ var ZodIssueCode = {
5457
5448
  var ZodFirstPartyTypeKind;
5458
5449
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5459
5450
  //#endregion
5460
- //#region ../types/dist/sleep-DXKLNFvA.mjs
5451
+ //#region ../types/dist/sleep-B0JG7-_F.mjs
5461
5452
  /**
5462
5453
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5463
5454
  * window to float samples (D455).
@@ -6823,32 +6814,12 @@ object({
6823
6814
  audioCodec: string().optional(),
6824
6815
  metadata: record(string(), unknown()).readonly().optional()
6825
6816
  });
6826
- var EncodedPacketSchema = object({
6827
- type: _enum(["video", "audio"]),
6828
- data: _instanceof(Uint8Array),
6829
- pts: number(),
6830
- dts: number(),
6831
- keyframe: boolean(),
6832
- codec: string()
6833
- });
6834
- var DecodedFrameSchema = object({
6835
- data: _instanceof(Uint8Array),
6836
- width: number(),
6837
- height: number(),
6838
- format: _enum([
6839
- "jpeg",
6840
- "rgb",
6841
- "bgr",
6842
- "yuv420",
6843
- "gray"
6844
- ]),
6845
- timestamp: number()
6846
- });
6847
6817
  /**
6848
6818
  * Wire schema for `FrameHandle` — a zero-pixel, serialisable reference to a
6849
6819
  * frame in a shared-memory ring (Phase 5 / D9). Mirrors the `FrameHandle` TS
6850
- * interface in `interfaces/frame-handle.ts` field-for-field so a decoder cap
6851
- * method (`pullHandles`) can carry handles over tRPC / Moleculer.
6820
+ * interface in `interfaces/frame-handle.ts` field-for-field so a cap method
6821
+ * (the runner's native-crop and pipeline-executor inputs) can carry handles
6822
+ * over tRPC / Moleculer.
6852
6823
  *
6853
6824
  * The `satisfies` assertion below pins this schema to the interface: if a
6854
6825
  * field is added to / removed from `FrameHandle` without a matching schema
@@ -6874,50 +6845,6 @@ var FrameHandleSchema = object({
6874
6845
  slotCount: number().int().positive()
6875
6846
  });
6876
6847
  /**
6877
- * Pixel format a frame-handle subscriber can request from the broker
6878
- * (Phase 5 / D9). The packed, raster subset of `FrameFormat` — the formats a
6879
- * `frameSink: 'shm'` decoder session can write into a `FrameRing` slot.
6880
- * `jpeg` is excluded: a variable-length stream is not a fixed-stride ring
6881
- * payload, and no decoded-frame consumer requests it over the shm plane.
6882
- */
6883
- var FrameHandleFormatSchema = _enum([
6884
- "rgb",
6885
- "bgr",
6886
- "yuv420",
6887
- "gray"
6888
- ]);
6889
- /**
6890
- * Input for `stream-broker.subscribeFrames` (Phase 5 / D9). A consumer asks the
6891
- * broker for a `FrameHandle` stream of one `format`; the broker maintains one
6892
- * shared-memory ring per `(brokerId, format)` actually requested, so a `gray`
6893
- * subscriber (motion) and an `rgb` subscriber (detection) each read the format
6894
- * they asked for with no broker-side conversion.
6895
- */
6896
- var SubscribeFramesInputSchema = object({
6897
- brokerId: string(),
6898
- format: FrameHandleFormatSchema,
6899
- /**
6900
- * Optional reader-side cadence hint in frames per second. The broker does
6901
- * NOT throttle — latest-wins ring reads drop frames implicitly for a slow
6902
- * consumer. The value is echoed back in `SubscribeFramesResult.maxFps` so
6903
- * the consumer can pace its own `pullFrameHandles` polling.
6904
- */
6905
- maxFps: number().positive().optional(),
6906
- /** Short caller-identity tag (`motion`, `detection`, …) for diagnostics. */
6907
- tag: string().optional()
6908
- });
6909
- /**
6910
- * Result of `stream-broker.subscribeFrames`. The consumer then polls
6911
- * `pullFrameHandles({ subscriptionId, maxCount })` and feeds each returned
6912
- * `FrameHandle` to a `FrameRingReader`.
6913
- */
6914
- var SubscribeFramesResultSchema = object({
6915
- /** Opaque id the consumer passes to `pullFrameHandles` / `unsubscribeFrames`. */
6916
- subscriptionId: string(),
6917
- /** Reader-side cadence hint (frames/s) — echoes `SubscribeFramesInput.maxFps`. */
6918
- maxFps: number().nonnegative()
6919
- });
6920
- /**
6921
6848
  * Wire schema for a decoded audio chunk (Phase 5 / D9). Mirrors the
6922
6849
  * `DecodedAudioChunk` TS interface in `interfaces/stream-broker.ts`: PCM
6923
6850
  * sample bytes plus the track parameters a consumer needs to interpret them.
@@ -6925,8 +6852,8 @@ var SubscribeFramesResultSchema = object({
6925
6852
  * Audio chunks are tiny (a ~500ms AudioCodecSession window is a few KB of
6926
6853
  * Float32 PCM), so unlike video frames they ship their bytes INLINE over
6927
6854
  * tRPC / Moleculer — no shared-memory plane. `data` is typed `Uint8Array`
6928
- * (the wire-serialisable supertype of `Buffer`) to match `DecodedFrameSchema`
6929
- * / `EncodedPacketSchema`'s precedent; a `Buffer` is assignable to it.
6855
+ * (the wire-serialisable supertype of `Buffer`); a `Buffer` is assignable to
6856
+ * it.
6930
6857
  */
6931
6858
  var AudioChunkFormatSchema = _enum(AUDIO_CHUNK_FORMATS);
6932
6859
  var DecodedAudioChunkSchema = object({
@@ -6944,11 +6871,10 @@ var DecodedAudioChunkSchema = object({
6944
6871
  format: AudioChunkFormatSchema.optional()
6945
6872
  });
6946
6873
  /**
6947
- * Input for `stream-broker.subscribeAudioChunks` (Phase 5 / D9). The
6948
- * handle-free, ship-bytes-inline analogue of `subscribeFrames`: a consumer
6949
- * asks the broker for the decoded audio-chunk stream of one broker; the
6950
- * broker keeps a per-subscription bounded FIFO queue the consumer drains via
6951
- * `pullAudioChunks`.
6874
+ * Input for `stream-broker.subscribeAudioChunks` (Phase 5 / D9). Audio ships
6875
+ * its bytes inline: a consumer asks the broker for the decoded audio-chunk
6876
+ * stream of one broker; the broker keeps a per-subscription bounded FIFO queue
6877
+ * the consumer drains via `pullAudioChunks`.
6952
6878
  */
6953
6879
  var SubscribeAudioChunksInputSchema = object({
6954
6880
  brokerId: string(),
@@ -6979,9 +6905,7 @@ var BrokerStatsSchema = object({
6979
6905
  "stopped"
6980
6906
  ]),
6981
6907
  inputFps: number(),
6982
- decodeFps: number(),
6983
6908
  encodedSubscribers: number(),
6984
- decodedSubscribers: number(),
6985
6909
  uptimeMs: number(),
6986
6910
  bitrateKbps: number(),
6987
6911
  idrIntervalMs: number(),
@@ -6994,14 +6918,6 @@ var BrokerStatsSchema = object({
6994
6918
  preBufferMs: number(),
6995
6919
  preBufferPackets: number(),
6996
6920
  /**
6997
- * Moleculer node id of the decoder provider currently servicing this
6998
- * stream's decoded subscribers. `null` until the deferred decoder is
6999
- * created (no decoded clients yet, or codec not detected). Surfaces the
7000
- * runtime decoder placement so the UI can show "Decoder: <agent>" without
7001
- * a separate cap call per broker.
7002
- */
7003
- decoderNodeId: string().nullable(),
7004
- /**
7005
6921
  * Detected audio track parameters from the RTSP DESCRIBE / SDP. `null`
7006
6922
  * when the stream has no audio track or the broker is in cold start.
7007
6923
  * `supported = false` means the codec was detected but the local
@@ -8489,8 +8405,8 @@ function buildAddonRouteProvider(id, routes) {
8489
8405
  const reply = buildCapturingReply(envelope);
8490
8406
  const request = {
8491
8407
  params: {
8492
- ...input.params,
8493
- ...match.params
8408
+ ...match.params,
8409
+ ...input.params
8494
8410
  },
8495
8411
  query: input.query,
8496
8412
  body: input.body,
@@ -10472,70 +10388,6 @@ var StorageLocationDeclarationSchema = object({
10472
10388
  "backup"
10473
10389
  ]).optional()
10474
10390
  });
10475
- var DecoderStatsSchema = object({
10476
- inputFps: number(),
10477
- outputFps: number(),
10478
- avgDecodeTimeMs: number(),
10479
- droppedFrames: number(),
10480
- /**
10481
- * Pull-mode adaptive-fps telemetry (optional — only pull sessions run the
10482
- * lag-driven controller; push sessions omit these). `lagMs` is the EWMA of
10483
- * the decoder's real-time drift (rising = falling behind live); `adaptiveFps`
10484
- * is the current lag-throttled emit rate (≤ `effectiveFps` ceiling).
10485
- */
10486
- lagMs: number().optional(),
10487
- effectiveFps: number().optional(),
10488
- adaptiveFps: number().optional()
10489
- });
10490
- var DecoderSessionConfigSchema = object({
10491
- codec: string(),
10492
- maxFps: number().default(0),
10493
- outputFormat: _enum([
10494
- "jpeg",
10495
- "rgb",
10496
- "bgr",
10497
- "yuv420",
10498
- "gray"
10499
- ]).default("jpeg"),
10500
- scale: number().default(1),
10501
- width: number().optional(),
10502
- height: number().optional(),
10503
- /**
10504
- * Identifier of the camera this decoder session serves. Optional
10505
- * because the cap is generic (any caller could request decode), but
10506
- * stream-broker passes it so decoder logs include `deviceId` for
10507
- * per-camera filtering when diagnosing failures (e.g. node-av
10508
- * sendPacket errors on a single hung camera).
10509
- */
10510
- deviceId: number().int().nonnegative().optional(),
10511
- /**
10512
- * Free-form tag for log scoping. Stream-broker uses
10513
- * `broker:<deviceId>/<profile>`. Decoder session logger surfaces it
10514
- * on every line so `grep tag=broker:5/high` filters one camera
10515
- * profile cleanly.
10516
- */
10517
- tag: string().optional(),
10518
- /**
10519
- * Where the session delivers decoded frames (Phase 5 / D9):
10520
- *
10521
- * - `'callback'` (default) — the legacy pixel path: decoded frames are
10522
- * buffered as `DecodedFrame`s and drained via `pullFrames`.
10523
- * - `'shm'` — the shared-memory frame plane: decoded frames are written
10524
- * into an OS shared-memory ring and drained as zero-pixel
10525
- * `FrameHandle`s via `pullHandles`. A session is one mode or the
10526
- * other — `pullFrames` returns nothing for an `'shm'` session and
10527
- * `pullHandles` returns nothing for a `'callback'` session.
10528
- */
10529
- frameSink: _enum(["callback", "shm"]).default("callback"),
10530
- /**
10531
- * Per-camera decoder DEBUG facility. When `true`, a pull-mode session emits
10532
- * a throttled (~1Hz) structured `decoder debug` line (effective/adaptive fps,
10533
- * real-time lag, dropped-frame delta, avg decode time, hwaccel). Mirrors the
10534
- * stream-broker's `streamingDebug` gate — off by default so production logs
10535
- * stay quiet and the emit path pays zero per-frame cost when disabled.
10536
- */
10537
- debug: boolean().optional()
10538
- });
10539
10391
  /**
10540
10392
  * Per-component log CHANNELS — the gate a hot path consults, and the registry
10541
10393
  * an addon declares its channels in.
@@ -10686,7 +10538,18 @@ var LABEL_SUPPLY_STEP_IDS = [
10686
10538
  ];
10687
10539
  /** Steps whose box a root detection can BE. */
10688
10540
  var CROP_SUPPLY_STEP_IDS = ["plate-detection", "face-detection"];
10689
- [...LABEL_SUPPLY_STEP_IDS, ...CROP_SUPPLY_STEP_IDS];
10541
+ /**
10542
+ * Steps whose per-detection MASK a root detection can carry (D737). The live
10543
+ * mask step is `segmentation` — a frame-plane refiner that runs its own model
10544
+ * once per detection crop. (`instance-segmentation` is a dormant step id that
10545
+ * no camera tree carries.)
10546
+ */
10547
+ var MASK_SUPPLY_STEP_IDS = ["segmentation"];
10548
+ [
10549
+ ...LABEL_SUPPLY_STEP_IDS,
10550
+ ...CROP_SUPPLY_STEP_IDS,
10551
+ ...MASK_SUPPLY_STEP_IDS
10552
+ ];
10690
10553
  var MODEL_FORMATS = [
10691
10554
  "onnx",
10692
10555
  "coreml",
@@ -10715,7 +10578,53 @@ var ModelFormatEntrySchema = object({
10715
10578
  /** Multi-file payload (directory members or sibling files). */
10716
10579
  files: array(string()).readonly().optional(),
10717
10580
  /** Runtime(s) that can use this format. If omitted, inferred from ModelFormat key */
10718
- runtimes: array(_enum(["python"])).readonly().optional()
10581
+ runtimes: array(_enum(["python"])).readonly().optional(),
10582
+ /**
10583
+ * Content revision of the artefact, for one hosted OFF the CamStack mirror.
10584
+ * A format on the mirror leaves it unset: its revision (the sha256 of its
10585
+ * weight file) comes from the downloader's generated table, kept in step
10586
+ * with the mirror by `scripts/check-hosted-model-revisions.ts` (D744). A
10587
+ * node records the revision it downloaded next to the file
10588
+ * (`<file>.revision`); a copy with no record or a different one is stale
10589
+ * unless its weight file hashes to the revision, and a stale copy is
10590
+ * downloaded again, the old one serving until the new one is complete. No
10591
+ * revision at all ⇒ a file on disk is current, whatever it holds (D743).
10592
+ */
10593
+ revision: string().min(1).optional()
10594
+ });
10595
+ /**
10596
+ * What a node holds for one (model, format) (D746). `current` is a complete
10597
+ * copy at its catalog revision — exactly what `downloaded: true` means.
10598
+ * `stale` is bytes on disk that are not (yet) proven current under D743/D744:
10599
+ * no or a different revision record, or a missing sibling. `missing` is no
10600
+ * copy. `downloaded` alone folds `stale` into "not downloaded", which hid
10601
+ * reclaimable bytes and a copy about to be replaced.
10602
+ */
10603
+ var ModelOnDiskStateSchema = _enum([
10604
+ "current",
10605
+ "stale",
10606
+ "missing"
10607
+ ]);
10608
+ /**
10609
+ * The numeric precision of one format's BUILD (D746) — reported only when the
10610
+ * build states it (file-name token, an INT8 variant, an EdgeTPU compile, a
10611
+ * CamStack Core ML export). Absent means "not stated", never "fp32".
10612
+ */
10613
+ var ModelFormatPrecisionSchema = _enum([
10614
+ "fp32",
10615
+ "fp16",
10616
+ "int8"
10617
+ ]);
10618
+ /**
10619
+ * One format of one model as a node's `pipelineExecutor.getSchema` reports it.
10620
+ * `onDisk` / `precision` are optional for version skew: a runner that predates
10621
+ * them omits them, and a reader falls back to `downloaded`.
10622
+ */
10623
+ var PipelineModelFormatStatusSchema = object({
10624
+ downloaded: boolean(),
10625
+ sizeMB: number(),
10626
+ onDisk: ModelOnDiskStateSchema.optional(),
10627
+ precision: ModelFormatPrecisionSchema.optional()
10719
10628
  });
10720
10629
  /**
10721
10630
  * Extra file that must be downloaded alongside the model (e.g., labels JSON, dict.txt).
@@ -10829,25 +10738,36 @@ var ModelLicenseSchema = preprocess((value) => typeof value === "string" ? { wei
10829
10738
  * - `crop`: the root draws the box the step would have found (`license_plate`
10830
10739
  * for plate-detection, `face` for face-detection). The box becomes a detail
10831
10740
  * child of the `parentMacro` detection that contains it — never a track.
10741
+ * - `mask`: the root's decode emits an instance mask with every detection (a
10742
+ * YOLO26-seg root, D737) — the `segmentation` step's result, carried on the
10743
+ * detection in the shape that step produces. Derived from the model's
10744
+ * postprocessor on read, never stored by an import.
10832
10745
  */
10833
- var RootStepSupplySchema = discriminatedUnion("kind", [object({
10834
- kind: literal("label"),
10835
- stepId: _enum(LABEL_SUPPLY_STEP_IDS),
10836
- labelToEffect: record(string(), string()),
10837
- uncovered: array(string()).readonly()
10838
- }), object({
10839
- kind: literal("crop"),
10840
- stepId: _enum(CROP_SUPPLY_STEP_IDS),
10841
- rootLabels: array(string()).readonly(),
10842
- parentMacro: _enum(["vehicle", "person"]),
10843
- childClass: _enum(["plate", "face"]),
10844
- /**
10845
- * The root's smaller input side, stamped on read by `rootSuppliesOf` from
10846
- * the model entry — what a step's `minRootInputPx` gate judges. Never
10847
- * stored by an import.
10848
- */
10849
- rootInputPx: number().int().positive().optional()
10850
- })]);
10746
+ var RootStepSupplySchema = discriminatedUnion("kind", [
10747
+ object({
10748
+ kind: literal("label"),
10749
+ stepId: _enum(LABEL_SUPPLY_STEP_IDS),
10750
+ labelToEffect: record(string(), string()),
10751
+ uncovered: array(string()).readonly()
10752
+ }),
10753
+ object({
10754
+ kind: literal("crop"),
10755
+ stepId: _enum(CROP_SUPPLY_STEP_IDS),
10756
+ rootLabels: array(string()).readonly(),
10757
+ parentMacro: _enum(["vehicle", "person"]),
10758
+ childClass: _enum(["plate", "face"]),
10759
+ /**
10760
+ * The root's smaller input side, stamped on read by `rootSuppliesOf` from
10761
+ * the model entry — what a step's `minRootInputPx` gate judges. Never
10762
+ * stored by an import.
10763
+ */
10764
+ rootInputPx: number().int().positive().optional()
10765
+ }),
10766
+ object({
10767
+ kind: literal("mask"),
10768
+ stepId: _enum(MASK_SUPPLY_STEP_IDS)
10769
+ })
10770
+ ]);
10851
10771
  var ModelCatalogEntrySchema = object({
10852
10772
  id: string(),
10853
10773
  name: string(),
@@ -10913,6 +10833,35 @@ var ModelCatalogEntrySchema = object({
10913
10833
  */
10914
10834
  defaultConfidence: number().min(0).max(1).optional(),
10915
10835
  /**
10836
+ * Per-MODEL default of the per-class confidence floors (`minConfidence<Macro>`
10837
+ * on a detector step), keyed by macro class: `{ person: 0.45 }`. A class
10838
+ * absent here runs at the step slider's global default. The same row shape
10839
+ * the floor measurement produces (`model-floors.json`: modelId → floors), so
10840
+ * a measured table is copied in as-is. An operator override is bound to the
10841
+ * model it was made for and does not survive a model change (D738). A custom
10842
+ * / imported model may declare it; without it, the global defaults apply.
10843
+ */
10844
+ defaultClassFloors: record(string(), number().min(0).max(1)).optional(),
10845
+ /**
10846
+ * The inference precision this model's OpenVINO IR needs on an Intel GPU.
10847
+ * Absent ⇒ the device default (f16 on a GPU). Set to `'f32'` for an FP32 IR
10848
+ * that produces invalid output at f16 — measured 2026-10-07 for YOLO26
10849
+ * base IRs (`yolo26s`: 0 true / 146 false positives; `yolo26m*`: NaN
10850
+ * scores) on the Core Ultra iGPU and the N100. Threaded to the pool as
10851
+ * `PoolModelConfig.gpuInferencePrecision`; the pool sets
10852
+ * INFERENCE_PRECISION_HINT on a GPU only. Costs ~60% latency on the GPU.
10853
+ */
10854
+ gpuInferencePrecision: _enum(["f32", "f16"]).optional(),
10855
+ /**
10856
+ * ROOT detectors only: per supplied step (`animal-classifier`, …), the
10857
+ * minimum DETECTION score from which this root's own fine label (species,
10858
+ * vehicle type — D736 root supply) is taken (D741). Below it the detection
10859
+ * keeps its macro class without the fine label. `1` = never take it from
10860
+ * this root. Absent ⇒ no floor beyond the macro floor. The supplied step's
10861
+ * `minConfidence` slider, bound to the ROOT model, overrides it.
10862
+ */
10863
+ suppliedLabelFloors: record(string(), number().min(0).max(1)).optional(),
10864
+ /**
10916
10865
  * When true, the executor produces a landmark-aligned crop (similarity warp
10917
10866
  * onto the canonical template) before this step runs, instead of a plain
10918
10867
  * axis-aligned bbox crop. Required for face-recognition embedders (ArcFace):
@@ -12611,13 +12560,6 @@ var BrokerRtspClientSchema = object({
12611
12560
  lastRtpAt: number(),
12612
12561
  bytesSent: number()
12613
12562
  });
12614
- var BrokerDecodedClientSchema = object({
12615
- tag: string(),
12616
- subscribedAt: number(),
12617
- maxFps: number(),
12618
- framesDelivered: number(),
12619
- framesDropped: number()
12620
- });
12621
12563
  var BrokerAudioClientSchema = object({
12622
12564
  tag: string(),
12623
12565
  subscribedAt: number(),
@@ -12709,7 +12651,6 @@ var BrokerEncodedClientSchema = object({
12709
12651
  });
12710
12652
  var BrokerClientsSchema = object({
12711
12653
  rtsp: array(BrokerRtspClientSchema).readonly(),
12712
- decoded: array(BrokerDecodedClientSchema).readonly(),
12713
12654
  audio: array(BrokerAudioClientSchema).readonly(),
12714
12655
  encoded: array(BrokerEncodedClientSchema).readonly(),
12715
12656
  pipeClients: number(),
@@ -13078,11 +13019,7 @@ method(object({
13078
13019
  auth: "admin"
13079
13020
  }), method(object({ brokerId: string() }), BrokerClientsSchema), method(object({
13080
13021
  brokerId: string(),
13081
- channel: _enum([
13082
- "rtsp",
13083
- "decoded",
13084
- "audio"
13085
- ]),
13022
+ channel: _enum(["rtsp", "audio"]),
13086
13023
  handle: string()
13087
13024
  }), object({ killed: boolean() }), {
13088
13025
  kind: "mutation",
@@ -13117,10 +13054,7 @@ method(object({
13117
13054
  }), method(SubscribeAudioChunksInputSchema, SubscribeAudioChunksResultSchema, { kind: "mutation" }), method(object({
13118
13055
  subscriptionId: string(),
13119
13056
  maxCount: number().int().positive().default(8)
13120
- }), array(DecodedAudioChunkSchema).readonly()), method(object({ subscriptionId: string() }), object({ released: boolean() }), { kind: "mutation" }), method(SubscribeFramesInputSchema, SubscribeFramesResultSchema, { kind: "mutation" }), method(object({
13121
- subscriptionId: string(),
13122
- maxCount: number().int().positive().default(4)
13123
- }), array(FrameHandleSchema).readonly()), method(object({ subscriptionId: string() }), object({ released: boolean() }), { kind: "mutation" }), method(object({
13057
+ }), array(DecodedAudioChunkSchema).readonly()), method(object({ subscriptionId: string() }), object({ released: boolean() }), { kind: "mutation" }), method(object({
13124
13058
  brokerId: string(),
13125
13059
  seconds: number().min(0).max(30)
13126
13060
  }), _void(), {
@@ -14277,54 +14211,12 @@ id: union([string(), number()]) }), {
14277
14211
  kind: "mutation",
14278
14212
  auth: "admin"
14279
14213
  });
14280
- /**
14281
- * shm ring usage stats for a `frameSink: 'shm'` decoder session —
14282
- * exposed via `decoder.getShmStats` so downstream consumers can
14283
- * observe ring pressure (slot count, byte budget, hit/miss ratio).
14284
- */
14285
- var ShmRingStatsSchema = object({
14286
- sessionId: string(),
14287
- slotCount: number().int(),
14288
- slotByteLength: number().int(),
14289
- segmentBytes: number().int(),
14290
- budgetMb: number().int(),
14291
- framesWritten: number().int(),
14292
- getFrameHits: number().int(),
14293
- getFrameMisses: number().int()
14294
- });
14295
- method(object({ codec: string() }), boolean()), method(_void(), object({
14214
+ method(_void(), object({
14296
14215
  id: string(),
14297
14216
  name: string(),
14298
- isPullMode: boolean().optional(),
14299
- priority: number().optional(),
14300
14217
  hwaccel: string().optional(),
14301
14218
  probedBestHwaccel: string().optional()
14302
- })), method(DecoderSessionConfigSchema, object({
14303
- sessionId: string(),
14304
- nodeId: string()
14305
- })), method(object({ sessionId: string() }), _void()), method(object({
14306
- sessionId: string(),
14307
- packet: EncodedPacketSchema
14308
- }), _void()), method(object({
14309
- sessionId: string(),
14310
- url: string()
14311
- }), _void()), method(object({
14312
- sessionId: string(),
14313
- maxCount: number().default(1),
14314
- waitMs: number().optional()
14315
- }), array(DecodedFrameSchema)), method(object({
14316
- sessionId: string(),
14317
- maxCount: number().default(1),
14318
- waitMs: number().optional()
14319
- }), array(FrameHandleSchema)), method(object({ handle: FrameHandleSchema }), DecodedFrameSchema.nullable()), method(object({ sessionId: string() }), ShmRingStatsSchema.nullable()), method(object({
14320
- sessionId: string(),
14321
- config: DecoderSessionConfigSchema.partial()
14322
- }), _void()), method(object({ sessionId: string() }), DecoderStatsSchema), method(_void(), array(object({
14323
- sessionId: string(),
14324
- codec: string(),
14325
- outputFormat: string(),
14326
- createdAtMs: number()
14327
- })).readonly()), method(_void(), object({ backend: string() }), {
14219
+ })), method(_void(), object({ backend: string() }), {
14328
14220
  kind: "mutation",
14329
14221
  auth: "admin"
14330
14222
  });
@@ -15161,6 +15053,10 @@ var DeviceInfoSchema = object({
15161
15053
  isCamera: boolean(),
15162
15054
  /** Current config values — serializable snapshot */
15163
15055
  config: record(string(), unknown()),
15056
+ /** Paths inside `config` the device's schema declares secret (D783) —
15057
+ * what the non-admin redaction withholds. Paths, never values. Absent
15058
+ * when the owning runner has not reported them. */
15059
+ secretConfigPaths: array(string()).optional(),
15164
15060
  /** Hardware + identity blob (manufacturer / model / firmware / sn /
15165
15061
  * uid / mac / …). Populated by drivers; editable via setMetadata. */
15166
15062
  metadata: record(string(), unknown()).nullable().optional(),
@@ -15366,7 +15262,13 @@ var DeviceRegisterPayloadSchema = object({
15366
15262
  * call (workers re-register on init), so probe-driven updates
15367
15263
  * (e.g. PTZ flag flipping after the abilities probe) propagate. */
15368
15264
  features: array(string()).optional(),
15369
- config: record(string(), unknown())
15265
+ config: record(string(), unknown()),
15266
+ /** Config paths the device's own schema DECLARES secret
15267
+ * (`.meta({ secret: true })` — dotted, `[]` for array items, e.g.
15268
+ * `connection.password`). Re-published on every register; the non-admin
15269
+ * redaction withholds them at any depth (D783). Optional: an older runner
15270
+ * omits it and the keyword backstop applies. */
15271
+ secretConfigPaths: array(string()).optional()
15370
15272
  });
15371
15273
  var DeviceRemovePayloadSchema = object({ deviceId: number() });
15372
15274
  var DevicePersistConfigPayloadSchema = object({
@@ -16193,6 +16095,12 @@ method(_void(), array(string()).readonly(), { auth: "admin" }), method(object({
16193
16095
  kind: "mutation",
16194
16096
  auth: "admin"
16195
16097
  });
16098
+ var HUB_ADDRESS_ROLES = [
16099
+ "appConnections",
16100
+ "notificationTaps",
16101
+ "internal",
16102
+ "publicEndpoint"
16103
+ ];
16196
16104
  /**
16197
16105
  * Transport bounds for AI capability methods.
16198
16106
  *
@@ -17019,7 +16927,14 @@ var LoginMethodContributionSchema = discriminatedUnion("kind", [
17019
16927
  icon: string().optional(),
17020
16928
  /** Addon-owned HTTP route the button navigates to (GET). */
17021
16929
  startUrl: string(),
17022
- stage: LoginStageEnum
16930
+ stage: LoginStageEnum,
16931
+ /**
16932
+ * The provider names an external identity a signed-in user can link to
16933
+ * their own account (D782): `auth.listLinkableProviders` /
16934
+ * `beginExternalLink` offer exactly the redirect methods that set this,
16935
+ * whatever their id. Absent / false — a login button only (magic-link).
16936
+ */
16937
+ linkable: boolean().optional()
17023
16938
  }),
17024
16939
  object({
17025
16940
  kind: literal("widget"),
@@ -20364,7 +20279,13 @@ var NcAlarmModeDelaysListSchema = array(object({
20364
20279
  * Absent = false (logged, not sent). Even when true it is not sent when that same sensor
20365
20280
  * is the one that starts the entry delay — the entry-delay notification already names it.
20366
20281
  */
20367
- notifySensorRewatched: boolean().optional()
20282
+ notifySensorRewatched: boolean().optional(),
20283
+ /**
20284
+ * D735: notify "ignored" when a sensor this arm bypassed really MOVED while armed (its own
20285
+ * change time is after the arm) and set nothing off. Absent = false (logged, not sent). A
20286
+ * re-sync, a recovery from `unavailable` or a duplicate is never announced, switch or not.
20287
+ */
20288
+ notifySensorIgnored: boolean().optional()
20368
20289
  })).max(8).refine(uniqueModes, { message: "modeDelays: at most one entry per arm mode" });
20369
20290
  var NcAlarmModeDelaysEditListSchema = array(object({
20370
20291
  mode: AlarmArmModeSchema,
@@ -20377,7 +20298,9 @@ var NcAlarmModeDelaysEditListSchema = array(object({
20377
20298
  /** D706: set the switch, or `null` to clear it (back to the default, false). */
20378
20299
  notifyDuringEntryDelay: boolean().nullable().optional(),
20379
20300
  /** D706: set the switch, or `null` to clear it (back to the default, false). */
20380
- notifySensorRewatched: boolean().nullable().optional()
20301
+ notifySensorRewatched: boolean().nullable().optional(),
20302
+ /** D735: set the switch, or `null` to clear it (back to the default, false). */
20303
+ notifySensorIgnored: boolean().nullable().optional()
20381
20304
  })).max(8).refine(uniqueModes, { message: "modeDelays: at most one edit per arm mode" });
20382
20305
  /** One switch of the alarm table: put ONE device on, or take it off, ONE mode's list. */
20383
20306
  var NcAlarmNonBlockingEditSchema = object({
@@ -21371,8 +21294,8 @@ Object.freeze(Object.fromEntries([{
21371
21294
  var CLUSTER_STEP_SETTING_FIELDS = [{
21372
21295
  stepId: "face-embedding",
21373
21296
  key: "minLandmarkFaceSize",
21374
- label: "Min face size for recognition (detection px)",
21375
- description: "Refuse to embed a face smaller than this IN THE DETECTION FRAME. Applies to every node — the enrolled gallery is one index, and two admission floors would fill it from two policies. 0 disables the gate.",
21297
+ label: "Min face size to embed (detection-frame px)",
21298
+ description: "Faces smaller than this in the small frame the detector sees are not embedded, so they can never be recognised. Below it the face cannot be aligned reliably and a bad embedding matches everyone. Same value on every node. 0 = no limit.",
21376
21299
  type: "slider",
21377
21300
  min: 0,
21378
21301
  max: 64,
@@ -22424,7 +22347,13 @@ var RetrainFrameSchema = object({
22424
22347
  sizeBytes: number().int(),
22425
22348
  width: number().int(),
22426
22349
  height: number().int(),
22427
- copiedAt: number()
22350
+ copiedAt: number(),
22351
+ /** When the CAMERA captured the frame. Absent on a copy taken before D785. */
22352
+ capturedAt: number().optional(),
22353
+ /** The operator's "every subject in this frame is boxed". Detector
22354
+ * evaluation keeps only complete frames: an unboxed subject would count as
22355
+ * a false positive. */
22356
+ complete: boolean()
22428
22357
  });
22429
22358
  /** Why a copy-on-select could not be honoured — named, never a silent skip. */
22430
22359
  var RetrainCopyRefusalSchema = _enum([
@@ -22445,6 +22374,51 @@ var RetrainFrameListSchema = object({
22445
22374
  /** What the page pre-selects — the native key frame when one survives. */
22446
22375
  autoPickMediaId: number().int().optional()
22447
22376
  });
22377
+ /**
22378
+ * Which frames an annotated export carries. Every field narrows; an empty
22379
+ * filter is every annotated copy. A dataset VERSION is a frozen `frameIds`
22380
+ * list owned by whoever trains (the training orchestrator), so `frameIds` is
22381
+ * the primitive a version export uses; `batchId` re-selects what an earlier
22382
+ * export carried (`exportedInBatch`).
22383
+ */
22384
+ var RetrainExportFilterSchema = object({
22385
+ deviceIds: array(number()).optional(),
22386
+ frameIds: array(string()).max(2e4).optional(),
22387
+ batchId: string().optional(),
22388
+ /** Only frames the operator marked complete (all subjects boxed). */
22389
+ completeOnly: boolean().optional()
22390
+ });
22391
+ /**
22392
+ * `frames`: the full frame copies, boxes in `annotations.json`.
22393
+ * `crops`: additionally one JPEG per subject, cut with the runtime detail-crop
22394
+ * convention — the classifier layout.
22395
+ */
22396
+ var RetrainExportLayoutSchema = _enum(["frames", "crops"]);
22397
+ /**
22398
+ * Where `writeRetrainArchive` streams the tar: one HTTP request whose body is
22399
+ * the archive, sent chunk by chunk. Covers a presigned PUT and a provider
22400
+ * addon's data-plane upload route alike. Headers are sent verbatim and never
22401
+ * logged.
22402
+ */
22403
+ var RetrainArchiveTargetSchema = object({
22404
+ kind: literal("http"),
22405
+ method: _enum(["PUT", "POST"]),
22406
+ url: string().url(),
22407
+ headers: record(string(), string()).optional()
22408
+ });
22409
+ var RetrainArchiveResultSchema = object({
22410
+ batchId: string(),
22411
+ frames: number().int(),
22412
+ crops: number().int(),
22413
+ annotations: number().int(),
22414
+ /** Frames planned but not shipped (unreadable copy, path too long). */
22415
+ missing: number().int(),
22416
+ bytes: number().int(),
22417
+ /** sha256 of the exact bytes sent. */
22418
+ sha256: string(),
22419
+ /** The target's HTTP status. */
22420
+ status: number().int()
22421
+ });
22448
22422
  /** What the operator asked the assist to look for. */
22449
22423
  var RetrainAssistSubjectSchema = discriminatedUnion("kind", [object({
22450
22424
  kind: literal("package"),
@@ -23239,9 +23213,25 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
23239
23213
  }), RetrainTransitionResultSchema, {
23240
23214
  kind: "mutation",
23241
23215
  auth: "admin"
23242
- }), method(object({ deviceIds: array(number()).optional() }), object({ url: string() }), {
23216
+ }), method(RetrainExportFilterSchema.extend({ layout: RetrainExportLayoutSchema.optional() }), object({ url: string() }), {
23243
23217
  kind: "query",
23244
23218
  auth: "admin"
23219
+ }), method(object({
23220
+ deviceId: number(),
23221
+ trackId: string(),
23222
+ frameId: string(),
23223
+ complete: boolean()
23224
+ }), RetrainFrameSchema, {
23225
+ kind: "mutation",
23226
+ auth: "admin"
23227
+ }), method(object({
23228
+ filter: RetrainExportFilterSchema,
23229
+ layout: RetrainExportLayoutSchema,
23230
+ target: RetrainArchiveTargetSchema
23231
+ }), RetrainArchiveResultSchema, {
23232
+ kind: "mutation",
23233
+ auth: "admin",
23234
+ timeoutMs: 60 * 6e4
23245
23235
  }), method(object({
23246
23236
  /** Which of the three event tables owns the row. */
23247
23237
  ownerType: EventOwnerTypeSchema,
@@ -23367,7 +23357,7 @@ var FrameRefSchema = object({
23367
23357
  timestamp: number(),
23368
23358
  capturedAt: number().optional()
23369
23359
  });
23370
- var ModelFormatSchema$1 = _enum([
23360
+ var ModelFormatSchema$2 = _enum([
23371
23361
  "onnx",
23372
23362
  "coreml",
23373
23363
  "openvino",
@@ -23385,7 +23375,7 @@ var PipelineSlotSchema = _enum([
23385
23375
  var PipelineEngineChoiceSchema = object({
23386
23376
  runtime: literal("python"),
23387
23377
  backend: string(),
23388
- format: ModelFormatSchema$1,
23378
+ format: ModelFormatSchema$2,
23389
23379
  device: string().optional()
23390
23380
  });
23391
23381
  /**
@@ -23424,28 +23414,10 @@ var PipelineDefaultStepSchema = lazy(() => object({
23424
23414
  group: string().optional(),
23425
23415
  settings: record(string(), unknown()).optional()
23426
23416
  }));
23427
- var PipelineTemplateStepSchema = lazy(() => object({
23428
- addonId: string(),
23429
- enabled: boolean(),
23430
- modelId: string(),
23431
- children: array(PipelineTemplateStepSchema).readonly(),
23432
- settings: record(string(), unknown()).optional()
23433
- }));
23434
- var PipelineTemplateSchema$1 = object({
23435
- id: string(),
23436
- name: string(),
23437
- createdAt: string(),
23438
- updatedAt: string(),
23439
- engine: PipelineEngineChoiceSchema,
23440
- steps: array(PipelineTemplateStepSchema).readonly()
23441
- });
23442
23417
  var PipelineModelOptionSchema = object({
23443
23418
  id: string(),
23444
23419
  name: string(),
23445
- formats: record(string(), object({
23446
- downloaded: boolean(),
23447
- sizeMB: number()
23448
- })),
23420
+ formats: record(string(), PipelineModelFormatStatusSchema),
23449
23421
  group: ModelVariantGroupSchema.optional(),
23450
23422
  legacy: boolean().optional(),
23451
23423
  provider: ModelProviderIdSchema.optional(),
@@ -23612,6 +23584,22 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
23612
23584
  }), {
23613
23585
  kind: "mutation",
23614
23586
  auth: "admin"
23587
+ }), method(object({
23588
+ nodeId: string(),
23589
+ deviceIds: array(number()).readonly().optional(),
23590
+ dryRun: boolean()
23591
+ }), object({
23592
+ entries: array(object({
23593
+ deviceId: number(),
23594
+ keys: array(string()).readonly()
23595
+ })).readonly(),
23596
+ refused: array(object({
23597
+ deviceId: number(),
23598
+ reason: string()
23599
+ })).readonly()
23600
+ }), {
23601
+ kind: "mutation",
23602
+ auth: "admin"
23615
23603
  }), method(object({ nodeId: string() }), object({ unhealthy: array(object({
23616
23604
  /** `<backend>:<device>`, e.g. `openvino:gpu`. */
23617
23605
  deviceKey: string(),
@@ -23637,22 +23625,14 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
23637
23625
  }), method(_void(), PipelineSchemaSchema), method(_void(), array(PipelineDefaultStepSchema).readonly().nullable()), method(_void(), PipelineConfigBridge), method(_void(), ConfigUISchemaBridge), method(object({
23638
23626
  steps: array(PipelineStepInputSchema),
23639
23627
  deviceKey: string().optional()
23640
- }), PipelineValidationResultSchema), method(_void(), array(PipelineTemplateSchema$1).readonly()), method(object({
23641
- name: string(),
23642
- steps: array(PipelineTemplateStepSchema).readonly(),
23643
- engine: PipelineEngineChoiceSchema
23644
- }), PipelineTemplateSchema$1, { kind: "mutation" }), method(object({
23645
- id: string(),
23646
- name: string().optional(),
23647
- steps: array(PipelineTemplateStepSchema).readonly().optional()
23648
- }), PipelineTemplateSchema$1, { kind: "mutation" }), method(object({ id: string() }), _void(), { kind: "mutation" }), method(_void(), InferenceCapabilitiesBridge), method(object({ addonId: string() }), ModelAvailabilityListBridge), method(object({
23628
+ }), PipelineValidationResultSchema), method(_void(), InferenceCapabilitiesBridge), method(object({ addonId: string() }), ModelAvailabilityListBridge), method(object({
23649
23629
  addonId: string(),
23650
23630
  modelId: string(),
23651
- format: ModelFormatSchema$1
23631
+ format: ModelFormatSchema$2
23652
23632
  }), DownloadModelResultSchema, { kind: "mutation" }), method(object({
23653
23633
  addonId: string(),
23654
23634
  modelId: string(),
23655
- format: ModelFormatSchema$1
23635
+ format: ModelFormatSchema$2
23656
23636
  }), object({ success: literal(true) }), { kind: "mutation" }), method(object({
23657
23637
  steps: array(PipelineStepInputSchema).min(1),
23658
23638
  frame: FrameInputSchema.optional(),
@@ -23809,6 +23789,375 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
23809
23789
  filename: string().optional(),
23810
23790
  settings: record(string(), unknown()).optional()
23811
23791
  }), AudioTestResultSchema, { kind: "mutation" }), method(_void(), ConfigUISchemaNullableBridge);
23792
+ /**
23793
+ * The wire shapes of the Auto tune plan and apply (D745), used by the
23794
+ * `pipeline-orchestrator` cap. The recommender's own types
23795
+ * (`recommend.ts`) are the TS face of the same data; these
23796
+ * schemas are what crosses the cap boundary.
23797
+ */
23798
+ var ModelFormatSchema$1 = _enum(MODEL_FORMATS);
23799
+ /** The operator's range for it. */
23800
+ var MIN_SESSIONS_PER_DEVICE_RANGE = {
23801
+ min: 1,
23802
+ max: 8
23803
+ };
23804
+ var HardwareClassIdSchema = _enum([
23805
+ "intel-core-ultra",
23806
+ "intel-n-series",
23807
+ "apple-m-base",
23808
+ "apple-m-pro",
23809
+ "unknown"
23810
+ ]);
23811
+ var AcceleratorKindSchema = _enum([
23812
+ "intel-npu",
23813
+ "intel-igpu",
23814
+ "x86-cpu",
23815
+ "arm-cpu",
23816
+ "apple-ane",
23817
+ "coral"
23818
+ ]);
23819
+ var RecommendationReasonSchema = discriminatedUnion("kind", [
23820
+ object({
23821
+ kind: literal("capacity"),
23822
+ sessions: number(),
23823
+ minSessions: number()
23824
+ }),
23825
+ object({
23826
+ kind: literal("tie-faster"),
23827
+ over: string(),
23828
+ recallDelta: number()
23829
+ }),
23830
+ object({
23831
+ kind: literal("stepped-down"),
23832
+ from: string(),
23833
+ to: string(),
23834
+ limitedBy: string()
23835
+ }),
23836
+ object({
23837
+ kind: literal("no-fit-lightest"),
23838
+ sessions: number(),
23839
+ minSessions: number()
23840
+ }),
23841
+ object({
23842
+ kind: literal("derived-latency"),
23843
+ modelId: string()
23844
+ }),
23845
+ object({ kind: literal("cpu-device") }),
23846
+ object({ kind: literal("coral-untouched") }),
23847
+ object({ kind: literal("device-disabled") }),
23848
+ object({ kind: literal("device-unavailable") }),
23849
+ object({ kind: literal("node-offline") }),
23850
+ object({ kind: literal("no-hardware-facts") }),
23851
+ object({
23852
+ kind: literal("no-measured-data"),
23853
+ hardwareClass: HardwareClassIdSchema
23854
+ }),
23855
+ object({
23856
+ kind: literal("no-family-build"),
23857
+ format: ModelFormatSchema$1
23858
+ })
23859
+ ]);
23860
+ var DeviceModelChoiceSchema = object({
23861
+ modelId: string(),
23862
+ p50Ms: number(),
23863
+ fps: number(),
23864
+ measured: boolean(),
23865
+ /** Parallel sessions at the camera rate with the headroom kept free: ⌊fps × (1 − headroom) / camera fps⌋. */
23866
+ capacitySessions: number(),
23867
+ personRecall: number()
23868
+ });
23869
+ var DeviceRecommendationSchema = object({
23870
+ deviceKey: string(),
23871
+ accelerator: AcceleratorKindSchema.nullable(),
23872
+ enabled: boolean(),
23873
+ available: boolean(),
23874
+ chosen: DeviceModelChoiceSchema.nullable(),
23875
+ reasons: array(RecommendationReasonSchema).readonly()
23876
+ });
23877
+ var NodeRecommendationSchema = object({
23878
+ nodeId: string(),
23879
+ reachable: boolean(),
23880
+ hardwareClass: HardwareClassIdSchema.nullable(),
23881
+ cpuModel: string().nullable(),
23882
+ skipped: boolean(),
23883
+ acceleratorModelId: string().nullable(),
23884
+ devices: array(DeviceRecommendationSchema).readonly(),
23885
+ reasons: array(RecommendationReasonSchema).readonly()
23886
+ });
23887
+ var ModelPinChangeSchema = object({
23888
+ stepId: string(),
23889
+ before: string().nullable(),
23890
+ after: string().nullable()
23891
+ });
23892
+ var NodeDeviceChangeSchema = object({
23893
+ nodeId: string(),
23894
+ deviceKey: string(),
23895
+ madeExplicit: boolean(),
23896
+ modelPins: array(ModelPinChangeSchema).readonly(),
23897
+ thresholds: array(object({
23898
+ stepId: string(),
23899
+ keys: array(string()).readonly()
23900
+ })).readonly()
23901
+ });
23902
+ var CameraOverrideClearSchema = object({
23903
+ deviceId: number(),
23904
+ source: _enum(["step-override", "wholesale"]),
23905
+ nodeId: string(),
23906
+ deviceKey: string().nullable(),
23907
+ stepId: string(),
23908
+ modelIdBefore: string().nullable(),
23909
+ keys: array(string()).readonly()
23910
+ });
23911
+ var DetectorStoreClearSchema = object({
23912
+ deviceId: number(),
23913
+ keys: array(string()).readonly()
23914
+ });
23915
+ var AutoTuneWarningSchema = discriminatedUnion("kind", [
23916
+ object({
23917
+ kind: literal("detector-store-cluster-wide"),
23918
+ skippedNodes: array(string()).readonly()
23919
+ }),
23920
+ object({
23921
+ kind: literal("detector-store-unreadable"),
23922
+ error: string()
23923
+ }),
23924
+ object({
23925
+ kind: literal("coral-enabled"),
23926
+ nodeId: string(),
23927
+ deviceKey: string()
23928
+ })
23929
+ ]);
23930
+ var AutoTuneOptionsSchema = object({
23931
+ /** Share of each accelerator's throughput kept free (0.3–0.5). */
23932
+ headroom: number().min(.3).max(.5).default(.4),
23933
+ /**
23934
+ * The least number of parallel sessions every device must sustain at the
23935
+ * camera rate with the headroom kept free (D755). The most accurate model
23936
+ * that reaches it wins.
23937
+ */
23938
+ minSessionsPerDevice: number().int().min(MIN_SESSIONS_PER_DEVICE_RANGE.min).max(MIN_SESSIONS_PER_DEVICE_RANGE.max).default(2)
23939
+ });
23940
+ var AutoTunePlanSchema = object({
23941
+ /** Hash of everything the apply will write — the apply refuses a different one. */
23942
+ planHash: string(),
23943
+ family: literal("yolov9"),
23944
+ headroom: number(),
23945
+ minSessionsPerDevice: number(),
23946
+ /** The detection rate a session is counted at (the fastest camera running the pipeline root). */
23947
+ cameraFps: number(),
23948
+ generatedAt: number(),
23949
+ nodes: array(NodeRecommendationSchema).readonly(),
23950
+ nodeChanges: array(NodeDeviceChangeSchema).readonly(),
23951
+ cameraClears: array(CameraOverrideClearSchema).readonly(),
23952
+ detectorStoreClears: array(DetectorStoreClearSchema).readonly(),
23953
+ warnings: array(AutoTuneWarningSchema).readonly()
23954
+ });
23955
+ var AutoTuneApplyInputSchema = object({
23956
+ planHash: string(),
23957
+ headroom: number().min(.3).max(.5).default(.4),
23958
+ minSessionsPerDevice: number().int().min(MIN_SESSIONS_PER_DEVICE_RANGE.min).max(MIN_SESSIONS_PER_DEVICE_RANGE.max).default(2)
23959
+ });
23960
+ var AutoTunePhaseResultSchema = object({
23961
+ phase: _enum([
23962
+ "download",
23963
+ "camera-overrides",
23964
+ "detector-thresholds",
23965
+ "node-models",
23966
+ "redispatch"
23967
+ ]),
23968
+ ok: boolean(),
23969
+ detail: string()
23970
+ });
23971
+ var AutoTuneApplyResultSchema = discriminatedUnion("kind", [
23972
+ object({
23973
+ kind: literal("applied"),
23974
+ planHash: string(),
23975
+ phases: array(AutoTunePhaseResultSchema).readonly()
23976
+ }),
23977
+ object({
23978
+ kind: literal("aborted"),
23979
+ phases: array(AutoTunePhaseResultSchema).readonly()
23980
+ }),
23981
+ object({
23982
+ kind: literal("stale"),
23983
+ plan: AutoTunePlanSchema
23984
+ }),
23985
+ object({
23986
+ kind: literal("refused"),
23987
+ reason: _enum(["apply-in-progress"])
23988
+ })
23989
+ ]);
23990
+ /**
23991
+ * Wire shapes of the Load balancing surface (D748): the session placement
23992
+ * policy, the atomic share write, the observed placement statistics, the
23993
+ * hardware share suggestion and the stale device pins.
23994
+ */
23995
+ /**
23996
+ * How a new detection session picks its node and device.
23997
+ * - `least-loaded` — the historical rule: lowest `attached / weight`, a
23998
+ * constant node order at a tie (D37). An idle node always ties at 0, so a
23999
+ * weight only bites once a node already holds a session.
24000
+ * - `share` — the share of PARALLEL sessions is held to the weights, and a
24001
+ * full or drowning node yields to a free one (D748).
24002
+ */
24003
+ var SessionPlacementPolicySchema = _enum(["least-loaded", "share"]);
24004
+ var LoadBalancingSharesInputSchema = object({
24005
+ /** nodeId → share (> 0). A node left out keeps its weight. */
24006
+ nodes: record(string(), number().positive()).default({}),
24007
+ /** nodeId → deviceKey → share (> 0). A device left out keeps its weight. */
24008
+ devices: record(string(), record(string(), number().positive())).default({})
24009
+ });
24010
+ var PlacementStatsInputSchema = object({
24011
+ /** Window the observed shares are averaged over (default 1 h, max 24 h). */
24012
+ windowMs: number().int().min(6e4).max(1440 * 60 * 1e3).default(3600 * 1e3) });
24013
+ var PlacementDeviceStatsSchema = object({
24014
+ deviceKey: string(),
24015
+ /** Sessions running on this device now. */
24016
+ sessionsNow: number(),
24017
+ /** Sessions started on this device inside the window. */
24018
+ sessionsStarted: number(),
24019
+ /** Time-weighted share of the node's parallel sessions over the window (0–1); null = no session ran. */
24020
+ observedShare: number().nullable()
24021
+ });
24022
+ var PlacementNodeStatsSchema = object({
24023
+ nodeId: string(),
24024
+ sessionsNow: number(),
24025
+ sessionsStarted: number(),
24026
+ /** Time-weighted share of the cluster's parallel sessions over the window (0–1); null = none ran. */
24027
+ observedShare: number().nullable(),
24028
+ /** Most sessions this node ran at once inside the window. */
24029
+ peakSessions: number(),
24030
+ /** Sessions a share election handed elsewhere because this node was full or drowning. */
24031
+ yieldsAway: number(),
24032
+ devices: array(PlacementDeviceStatsSchema).readonly()
24033
+ });
24034
+ /** A camera's device pin that the session path cannot honour. */
24035
+ var StaleDevicePinSchema = object({
24036
+ deviceId: number(),
24037
+ deviceKey: string(),
24038
+ /** `disabled` — the key exists on some node but is not enabled anywhere; `absent` — no node has it. */
24039
+ reason: _enum(["disabled", "absent"])
24040
+ });
24041
+ var PlacementStatsSchema = object({
24042
+ policy: SessionPlacementPolicySchema,
24043
+ windowMs: number(),
24044
+ /** How much of the window was actually observed (the hub keeps it in memory). */
24045
+ observedForMs: number(),
24046
+ sessionsNow: number(),
24047
+ /** Most parallel sessions across the cluster inside the window. */
24048
+ clusterPeakSessions: number(),
24049
+ nodes: array(PlacementNodeStatsSchema).readonly(),
24050
+ stalePins: array(StaleDevicePinSchema).readonly()
24051
+ });
24052
+ /**
24053
+ * Where an automatic share's capacity comes from (D755).
24054
+ * - `hardware` — the static capacity of each device at its Auto tune model:
24055
+ * the measured latency table for the node's hardware class.
24056
+ * - `benchmark` — the node's own measured capacity (node benchmark results).
24057
+ * A node with no results falls back to `hardware`, and says so.
24058
+ */
24059
+ var CapacitySourceSchema = _enum(["hardware", "benchmark"]);
24060
+ /** Why a node under the `benchmark` source was sized from hardware instead. */
24061
+ var CapacityFallbackSchema = _enum(["no-benchmark-results", "partial-benchmark-results"]);
24062
+ var SuggestSharesInputSchema = object({
24063
+ headroom: number().min(.3).max(.5).default(.4),
24064
+ /** Default `hardware`. */
24065
+ source: CapacitySourceSchema.default("hardware")
24066
+ });
24067
+ var SuggestedDeviceShareSchema = object({
24068
+ deviceKey: string(),
24069
+ /** Share of the node (0–100, rounded). */
24070
+ share: number(),
24071
+ modelId: string().nullable(),
24072
+ /** Inferences per second at that model, from the measured table; null when sized by a benchmark. */
24073
+ fps: number().nullable(),
24074
+ /** False for a table cell derived from another chip; true for a measured cell or a benchmark. */
24075
+ measured: boolean(),
24076
+ /**
24077
+ * Advisory session cap: ⌊fps × (1 − headroom) / camera fps⌋ from the table,
24078
+ * or the benchmark's measured max sessions. Never enforced.
24079
+ */
24080
+ suggestedMaxSessions: number().nullable()
24081
+ });
24082
+ var SuggestedNodeShareSchema = object({
24083
+ nodeId: string(),
24084
+ /** Share of the cluster (0–100, rounded); null = node skipped (offline, unknown hardware). */
24085
+ share: number().nullable(),
24086
+ /** Parallel sessions the node sustains at the suggested models with the headroom kept free. */
24087
+ capacitySessions: number(),
24088
+ devices: array(SuggestedDeviceShareSchema).readonly(),
24089
+ skippedReason: string().nullable(),
24090
+ /** What this node's capacity was read from; null when the node is skipped. */
24091
+ capacitySource: CapacitySourceSchema.nullable(),
24092
+ /** Set when the `benchmark` source was asked for and this node used `hardware`. */
24093
+ capacityFallback: CapacityFallbackSchema.nullable()
24094
+ });
24095
+ var SuggestSharesResultSchema = object({
24096
+ headroom: number(),
24097
+ /** The source asked for; each node says what it actually used. */
24098
+ source: CapacitySourceSchema,
24099
+ /** Camera detection rate the capacity is counted in (the fastest camera's fps). */
24100
+ cameraFps: number(),
24101
+ /** The Auto tune capacity floor the models were picked at. */
24102
+ minSessionsPerDevice: number(),
24103
+ nodes: array(SuggestedNodeShareSchema).readonly()
24104
+ });
24105
+ /**
24106
+ * Where the node and device shares come from (D750, D755).
24107
+ * - `hardware` (default) — computed by the system from each node's static
24108
+ * capacity (its accelerators at their Auto tune models, from the measured
24109
+ * latency table), recomputed whenever a node or device joins, leaves, is
24110
+ * switched on or off, or changes model. No load input.
24111
+ * - `benchmark` — the same, from each node's measured capacity (node
24112
+ * benchmark results); a node without results falls back to `hardware`.
24113
+ * - `manual` — the operator's stored sliders.
24114
+ * Either way a node or device that cannot take sessions gives its share to
24115
+ * the others in proportion; the stored values are never rewritten for that.
24116
+ */
24117
+ var ShareSourceSchema = _enum([
24118
+ "hardware",
24119
+ "benchmark",
24120
+ "manual"
24121
+ ]);
24122
+ var SetShareSourceInputSchema = object({ source: ShareSourceSchema });
24123
+ object({
24124
+ nodes: record(string(), number()),
24125
+ devices: record(string(), record(string(), number()))
24126
+ });
24127
+ var EffectiveDeviceShareSchema = object({
24128
+ deviceKey: string(),
24129
+ /** Can take sessions now (enabled, available, can run the root). */
24130
+ eligible: boolean(),
24131
+ /** The share the source assigns, as a percentage of the node's devices. */
24132
+ configuredPct: number(),
24133
+ /** The share actually used, after an ineligible device's share went to the others. */
24134
+ effectivePct: number()
24135
+ });
24136
+ var EffectiveNodeShareSchema = object({
24137
+ nodeId: string(),
24138
+ eligible: boolean(),
24139
+ configuredPct: number(),
24140
+ effectivePct: number(),
24141
+ /** Automatic sources: what this node's share was computed from; null under `manual` or before the first answer. */
24142
+ capacitySource: CapacitySourceSchema.nullable(),
24143
+ /** Automatic `benchmark`: why this node used `hardware` instead. */
24144
+ capacityFallback: CapacityFallbackSchema.nullable(),
24145
+ devices: array(EffectiveDeviceShareSchema).readonly()
24146
+ });
24147
+ var EffectiveSharesSchema = object({
24148
+ source: ShareSourceSchema,
24149
+ policy: SessionPlacementPolicySchema,
24150
+ /** An automatic source with no computed answer yet: the stored sliders are used meanwhile. */
24151
+ autoPending: boolean(),
24152
+ /** When the automatic shares were last computed (ms epoch); null = never. */
24153
+ computedAt: number().nullable(),
24154
+ /** What made the system recompute them last. */
24155
+ trigger: string().nullable(),
24156
+ nodes: array(EffectiveNodeShareSchema).readonly(),
24157
+ /** The relative weights the election reads (before eligibility). */
24158
+ nodeWeights: record(string(), number()),
24159
+ deviceWeights: record(string(), record(string(), number()))
24160
+ });
23812
24161
  object({
23813
24162
  activeCameras: number(),
23814
24163
  throttledCameras: number(),
@@ -24686,14 +25035,15 @@ var RunnerLocalLoadSchema = object({
24686
25035
  * Per-inference-device live load (multi-device C4). One entry per deviceKey
24687
25036
  * this runner currently has attached cameras on, so the orchestrator's second
24688
25037
  * `balance()` pass (over a node's devices) weights on real per-pool session
24689
- * counts. Empty on single-device / pre-multi-device runners. `queueDepthTotal`
24690
- * per device is 0 until the pool backlog gets a public accessor (follow-up).
25038
+ * counts. Empty on single-device / pre-multi-device runners. There is no
25039
+ * per-device queue depth: the inference pool's backlog has no accessor, and
25040
+ * a field that always read 0 was removed rather than shown as a measurement
25041
+ * (D762).
24691
25042
  */
24692
25043
  devices: array(object({
24693
25044
  deviceKey: string(),
24694
25045
  backend: string(),
24695
- attachedCameras: number(),
24696
- queueDepthTotal: number()
25046
+ attachedCameras: number()
24697
25047
  })).default([]),
24698
25048
  /** Hardware capability flags reported by this node. */
24699
25049
  hardware: object({
@@ -24907,14 +25257,6 @@ var CameraPipelineConfigSchema = object({
24907
25257
  settings: record(string(), unknown()).readonly().optional()
24908
25258
  }).nullable().optional()
24909
25259
  });
24910
- var PipelineTemplateSchema = object({
24911
- id: string(),
24912
- name: string(),
24913
- description: string().optional(),
24914
- config: CameraPipelineConfigSchema,
24915
- createdAt: string(),
24916
- updatedAt: string()
24917
- });
24918
25260
  var DeviceStepConfigSchema = object({
24919
25261
  modelId: string().optional(),
24920
25262
  settings: record(string(), unknown()).optional(),
@@ -24988,9 +25330,10 @@ var CameraStepOverridePatchSchema = object({
24988
25330
  modelId: string().optional(),
24989
25331
  settings: record(string(), unknown()).readonly().optional()
24990
25332
  });
25333
+ var CameraStepSettingsSchema = record(string(), record(string(), unknown()).readonly());
24991
25334
  var CameraPipelineSettingsSchema = object({
24992
- pinnedAgentNodeId: string().optional(),
24993
25335
  stepToggles: record(string(), boolean()).optional(),
25336
+ stepSettings: CameraStepSettingsSchema.optional(),
24994
25337
  stepOverridesByDevice: record(string(), record(string(), record(string(), CameraStepOverridePatchSchema))).optional(),
24995
25338
  pipelineByAgent: record(string(), CameraPipelineForAgentSchema).optional()
24996
25339
  });
@@ -25023,7 +25366,10 @@ var PipelineAssignmentSchema = object({
25023
25366
  });
25024
25367
  /**
25025
25368
  * Per-agent load summary surfaced to the load balancer + dashboards.
25026
- * Aggregated from each runner's `getLocalLoad` cap call.
25369
+ * Aggregated from each runner's `getLocalLoad` cap call. In the
25370
+ * `getAgentLoad` report, a single-device node's default-pool sessions (no
25371
+ * `deviceKey`) are credited to its one eligible device in `load.devices` —
25372
+ * the default pool IS that device (D745); the balancer's census stays raw.
25027
25373
  */
25028
25374
  var AgentLoadSummarySchema = object({
25029
25375
  nodeId: string(),
@@ -25112,26 +25458,27 @@ var CameraBrokerStatusSchema = object({
25112
25458
  width: number(),
25113
25459
  height: number(),
25114
25460
  subscribers: number(),
25115
- inFps: number(),
25116
- outFps: number()
25461
+ /**
25462
+ * Encoded packets/s the broker receives from the camera. null when the
25463
+ * broker's stats read failed — unknown, never 0 (a 0 here reads as a stall).
25464
+ * There is no output rate: decoding runs in the session decode workers, not
25465
+ * in the broker, so the broker's own decoded-frame rate is 0 on every live
25466
+ * camera and is not served (D758).
25467
+ */
25468
+ inFps: number().nullable()
25117
25469
  })).readonly(),
25118
25470
  webrtcSessions: number(),
25119
25471
  rtspRestream: boolean()
25120
25472
  });
25121
- /** Shared-memory ring statistics within the decoder block. */
25122
- var CameraDecoderShmSchema = object({
25123
- framesWritten: number(),
25124
- getFrameHits: number(),
25125
- getFrameMisses: number(),
25126
- budgetMb: number()
25127
- });
25128
- /** Decoder block — null when the decoder stage is unreachable or inactive. */
25129
- var CameraDecoderStatusSchema = object({
25130
- nodeId: string(),
25131
- formats: array(string()).readonly(),
25132
- sessionCount: number(),
25133
- shm: CameraDecoderShmSchema
25134
- });
25473
+ /**
25474
+ * Decoder block — WHERE decode runs (co-located with the detection node by
25475
+ * construction); null when the camera has no detection node. It carries no
25476
+ * frame counter: the shared-memory plane whose counters it used to serve is
25477
+ * gone, and those fields read 0 forever. Whether frames actually flow is read
25478
+ * from `detection.actualFps` (frames delivered to and processed by the
25479
+ * detector), never from a counter nothing feeds.
25480
+ */
25481
+ var CameraDecoderStatusSchema = object({ nodeId: string() });
25135
25482
  /** Motion block — null when motion detection is not active for this device. */
25136
25483
  var CameraMotionStatusSchema = object({
25137
25484
  enabled: boolean(),
@@ -25488,12 +25835,6 @@ method(object({
25488
25835
  }), object({ success: literal(true) }), {
25489
25836
  kind: "mutation",
25490
25837
  auth: "admin"
25491
- }), method(object({
25492
- agentNodeId: string(),
25493
- detectWeight: number().positive().nullable()
25494
- }), object({ success: literal(true) }), {
25495
- kind: "mutation",
25496
- auth: "admin"
25497
25838
  }), method(object({
25498
25839
  agentNodeId: string(),
25499
25840
  detect: boolean().nullable().optional(),
@@ -25535,6 +25876,15 @@ method(object({
25535
25876
  }), {
25536
25877
  kind: "mutation",
25537
25878
  auth: "admin"
25879
+ }), method(AutoTuneOptionsSchema, AutoTunePlanSchema, { auth: "admin" }), method(AutoTuneApplyInputSchema, AutoTuneApplyResultSchema, {
25880
+ kind: "mutation",
25881
+ auth: "admin"
25882
+ }), method(LoadBalancingSharesInputSchema, object({ success: literal(true) }), {
25883
+ kind: "mutation",
25884
+ auth: "admin"
25885
+ }), method(PlacementStatsInputSchema, PlacementStatsSchema, { auth: "admin" }), method(SuggestSharesInputSchema, SuggestSharesResultSchema, { auth: "admin" }), method(_void(), EffectiveSharesSchema, { auth: "admin" }), method(SetShareSourceInputSchema, object({ success: literal(true) }), {
25886
+ kind: "mutation",
25887
+ auth: "admin"
25538
25888
  }), method(object({ deviceId: number() }), CameraPipelineSettingsSchema.nullable()), method(object({
25539
25889
  deviceId: number(),
25540
25890
  addonId: string(),
@@ -25551,6 +25901,13 @@ method(object({
25551
25901
  }), object({ success: literal(true) }), {
25552
25902
  kind: "mutation",
25553
25903
  auth: "admin"
25904
+ }), method(object({
25905
+ deviceId: number(),
25906
+ addonId: string(),
25907
+ settings: record(string(), unknown()).nullable()
25908
+ }), object({ success: literal(true) }), {
25909
+ kind: "mutation",
25910
+ auth: "admin"
25554
25911
  }), method(object({
25555
25912
  deviceId: number(),
25556
25913
  agentNodeId: string(),
@@ -25574,25 +25931,7 @@ method(object({
25574
25931
  }), method(_void(), DiskReconcileJobSchema, {
25575
25932
  kind: "mutation",
25576
25933
  auth: "admin"
25577
- }), method(_void(), DiskReconcileJobSchema, { auth: "admin" }), method(_void(), array(PipelineTemplateSchema).readonly()), method(object({
25578
- name: string(),
25579
- description: string().optional(),
25580
- config: CameraPipelineConfigSchema
25581
- }), PipelineTemplateSchema, {
25582
- kind: "mutation",
25583
- auth: "admin"
25584
- }), method(object({
25585
- id: string(),
25586
- name: string().optional(),
25587
- description: string().optional(),
25588
- config: CameraPipelineConfigSchema.optional()
25589
- }), PipelineTemplateSchema, {
25590
- kind: "mutation",
25591
- auth: "admin"
25592
- }), method(object({ id: string() }), object({ success: literal(true) }), {
25593
- kind: "mutation",
25594
- auth: "admin"
25595
- });
25934
+ }), method(_void(), DiskReconcileJobSchema, { auth: "admin" });
25596
25935
  /**
25597
25936
  * Cap → event-kind mapping for the SENSOR / CONTROL cap families — the table
25598
25937
  * `pipeline-analytics.listEventKinds` uses to turn a linked device's bound
@@ -26182,7 +26521,19 @@ var SsoBridgeClaimsSchema = object({
26182
26521
  * editing a descriptor must not retroactively extend or shorten a link the
26183
26522
  * operator already consented to.
26184
26523
  */
26185
- refreshTtl: union([number().int().positive(), literal("never")]).optional()
26524
+ refreshTtl: union([number().int().positive(), literal("never")]).optional(),
26525
+ /**
26526
+ * Opaque handle of a hub-side LINK intent (D782). Set by an OIDC callback
26527
+ * that was started from a signed-in user's "Link" button: the finish then
26528
+ * links this identity to the intent's user instead of signing anyone in.
26529
+ * The handle carries no user id — the hub resolves it, single-use.
26530
+ */
26531
+ linkIntent: string().optional(),
26532
+ /**
26533
+ * Verified `iss` of the id_token behind an OIDC login bridge (D782). A
26534
+ * subject is unique only per issuer, so a link is bound to it.
26535
+ */
26536
+ issuer: string().optional()
26186
26537
  });
26187
26538
  method(object({
26188
26539
  claims: SsoBridgeClaimsSchema,
@@ -27812,8 +28163,6 @@ var WebrtcStreamChoiceSchema = object({
27812
28163
  ]).nullable(),
27813
28164
  /** Input FPS from the camera (null for adaptive). */
27814
28165
  inputFps: number().nullable(),
27815
- /** Decoded FPS (null for adaptive). */
27816
- decodeFps: number().nullable(),
27817
28166
  /** Bitrate in kbps (null for adaptive). */
27818
28167
  bitrateKbps: number().nullable()
27819
28168
  });
@@ -28090,7 +28439,22 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
28090
28439
  * field their hints were silently stripped by the schema and the
28091
28440
  * adaptive ladder started blind on the client's display size.
28092
28441
  */
28093
- hints: webrtcClientHintsSchema.optional()
28442
+ hints: webrtcClientHintsSchema.optional(),
28443
+ /**
28444
+ * Talk-back (D771): relay the PEER's audio to the device's speaker
28445
+ * through the `intercom` cap's push-talk triple. When `true` and the
28446
+ * offer lets the peer send audio, the answer's audio is `sendrecv`
28447
+ * and every inbound frame goes to `intercom.pushTalkAudio` for this
28448
+ * `deviceId`; absent/false answers `sendonly`, as for every viewer.
28449
+ *
28450
+ * TRUSTED-CALLER ONLY. Set by the Alexa export for an Echo on a camera
28451
+ * with `intercom`, when the linked user may control that camera. The
28452
+ * hub STRIPS it from every request-bound call (a browser), exactly as
28453
+ * it overwrites `relayOnly` — a viewer's talk permission is the
28454
+ * intercom cap's own surface (share tokens gate it there), and this
28455
+ * flag must not become a second door to the camera's speaker.
28456
+ */
28457
+ talkback: boolean().optional()
28094
28458
  }), object({
28095
28459
  sessionId: string(),
28096
28460
  sdpAnswer: string()
@@ -28145,6 +28509,14 @@ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), ar
28145
28509
  */
28146
28510
  alive: boolean()
28147
28511
  })), method(object({
28512
+ deviceId: number().int().nonnegative(),
28513
+ sessionId: string(),
28514
+ downlinkMbps: number().nonnegative()
28515
+ }), object({
28516
+ outcome: _enum(["switching", "held"]),
28517
+ tier: CamProfileSchema.nullable(),
28518
+ reason: string()
28519
+ }), { kind: "mutation" }), method(object({
28148
28520
  deviceId: number().int().nonnegative(),
28149
28521
  sessionId: string()
28150
28522
  }), WebrtcSessionDebugSchema, { kind: "query" });
@@ -28384,6 +28756,59 @@ var AddonAutoUpdateSchema = ChannelWithInheritSchema;
28384
28756
  var RestartAddonResultSchema = unknown();
28385
28757
  var InstallPackageResultSchema = unknown();
28386
28758
  var ReloadPackagesResultSchema = unknown();
28759
+ /**
28760
+ * What an uninstall did on ONE node.
28761
+ * - `uninstalled` — removed: runner(s) stopped, caps gone, code deleted.
28762
+ * - `not-installed` — the node did not have it (nothing to do).
28763
+ * - `refused` — protected / bootstrap package; nothing touched.
28764
+ * - `failed` — attempted and did not complete; `error` says why.
28765
+ * - `pending-reconnect` — the node is OFFLINE: its record was pruned so the
28766
+ * back-fill never returns the package, and the stale-addon sweep removes the
28767
+ * copy when the node registers again (only once the hub no longer has it).
28768
+ */
28769
+ var UninstallNodeOutcomeSchema = _enum([
28770
+ "uninstalled",
28771
+ "not-installed",
28772
+ "refused",
28773
+ "failed",
28774
+ "pending-reconnect"
28775
+ ]);
28776
+ var UninstallNodeResultSchema = object({
28777
+ nodeId: string(),
28778
+ outcome: UninstallNodeOutcomeSchema,
28779
+ error: string().optional(),
28780
+ addonIds: array(string()).readonly(),
28781
+ runnersStopped: array(string()).readonly(),
28782
+ warnings: array(string()).readonly()
28783
+ });
28784
+ var UninstallPackageResultSchema = object({
28785
+ /** Every targeted node ended `uninstalled`, `not-installed` or `pending-reconnect`. */
28786
+ success: boolean(),
28787
+ packageName: string(),
28788
+ results: array(UninstallNodeResultSchema).readonly()
28789
+ });
28790
+ /**
28791
+ * `unreachable` lists online agents whose status read FAILED — absence from
28792
+ * `installations` is only "not installed" for a node that answered (D315).
28793
+ */
28794
+ var PackageInstallationsSchema = object({
28795
+ installations: array(object({
28796
+ packageName: string(),
28797
+ nodeId: string(),
28798
+ nodeName: string(),
28799
+ isHub: boolean(),
28800
+ isOnline: boolean(),
28801
+ version: string().nullable(),
28802
+ addonIds: array(string()).readonly(),
28803
+ source: _enum(["live", "recorded"]),
28804
+ /** The hub installs this package too. `false` on an agent row = an orphan. */
28805
+ onHub: boolean()
28806
+ })).readonly(),
28807
+ unreachable: array(object({
28808
+ nodeId: string(),
28809
+ error: string()
28810
+ })).readonly()
28811
+ });
28387
28812
  var BulkUpdateItemStatusSchema = _enum([
28388
28813
  "queued",
28389
28814
  "updating",
@@ -28466,10 +28891,14 @@ method(_void(), array(AddonListItemSchema).readonly()), method(object({
28466
28891
  }), method(object({ packageName: string() }), InstallPackageResultSchema, {
28467
28892
  kind: "mutation",
28468
28893
  auth: "admin"
28469
- }), method(_void(), boolean()), method(_void(), array(unknown()).readonly()), method(object({ packageName: string() }), unknown(), {
28894
+ }), method(_void(), boolean()), method(_void(), array(unknown()).readonly()), method(object({
28895
+ packageName: string().min(1),
28896
+ nodeId: string().optional(),
28897
+ everywhere: boolean().optional()
28898
+ }), UninstallPackageResultSchema, {
28470
28899
  kind: "mutation",
28471
28900
  auth: "admin"
28472
- }), method(_void(), ReloadPackagesResultSchema, {
28901
+ }), method(object({ packageName: string().optional() }), PackageInstallationsSchema, { auth: "admin" }), method(_void(), ReloadPackagesResultSchema, {
28473
28902
  kind: "mutation",
28474
28903
  auth: "admin"
28475
28904
  }), method(object({ query: string().optional() }), array(SearchResultSchema)), method(object({ nodeId: string().optional() }), array(PackageUpdateSchema).readonly(), { auth: "admin" }), method(object({
@@ -30832,7 +31261,8 @@ var ConnectionEndpointSchema = object({
30832
31261
  "lan-ipv6",
30833
31262
  "public",
30834
31263
  "loopback",
30835
- "app-link"
31264
+ "app-link",
31265
+ "custom"
30836
31266
  ]),
30837
31267
  /**
30838
31268
  * Originating-interface kind — `lan`/`wifi`/`docker`/`vpn`/`other`/
@@ -30901,7 +31331,7 @@ var GetConnectionEndpointsResultSchema = object({
30901
31331
  localPort: AdvertisedLocalPortSchema
30902
31332
  });
30903
31333
  /**
30904
- * The address flagged for notification links. `baseUrl: null` = AUTO, which
31334
+ * The address flagged for notification taps (`notificationTaps`). `baseUrl: null` = AUTO, which
30905
31335
  * since D709 is the CamStack app link; `resolved` reports the effective value,
30906
31336
  * so the UI can show it either way.
30907
31337
  */
@@ -30935,13 +31365,12 @@ var ViewerEndpointsSchema = object({
30935
31365
  resolved: array(string()).readonly()
30936
31366
  });
30937
31367
  /**
30938
- * One audience's hub address (see `hub-address.ts`): the operator's stored
30939
- * override, the address in use, and where it came from.
31368
+ * DEPRECATED compatibility shape of `getHubAddresses` (D729 amendment, kept
31369
+ * for addons built against it): `cluster` is the `internal` role, `browser`
31370
+ * the `publicEndpoint` role; `override` is the flagged address.
30940
31371
  */
30941
31372
  var HubAddressSnapshotSchema = object({
30942
- /** The operator's override, or null for automatic. */
30943
31373
  override: string().nullable(),
30944
- /** The address in use, or null when nothing qualifies (never loopback). */
30945
31374
  resolved: string().nullable(),
30946
31375
  source: _enum([
30947
31376
  "override",
@@ -30950,11 +31379,57 @@ var HubAddressSnapshotSchema = object({
30950
31379
  ])
30951
31380
  });
30952
31381
  var HubAddressesSchema = object({
30953
- /** "Hub address for agents" — agents' bundle/model pulls, LAN devices. */
30954
31382
  cluster: HubAddressSnapshotSchema,
30955
- /** "Public address for sign-in links" — e-mail links, OIDC, WebAuthn, OAuth2. */
30956
31383
  browser: HubAddressSnapshotSchema
30957
31384
  });
31385
+ /**
31386
+ * What an address is used for (`hub-address.ts`, D734). `appConnections` is
31387
+ * many-valued; `notificationTaps`, `publicEndpoint` and `internal` are carried
31388
+ * by at most one address.
31389
+ */
31390
+ var HubAddressRoleSchema = _enum(HUB_ADDRESS_ROLES);
31391
+ var RoleSourceSchema = _enum([
31392
+ "flagged",
31393
+ "auto",
31394
+ "none"
31395
+ ]);
31396
+ /** One single-valued role: the flagged address, the one in use, and why. */
31397
+ var HubAddressRoleResolutionSchema = object({
31398
+ /** The address carrying the flag, or null = automatic. */
31399
+ flagged: string().nullable(),
31400
+ /** The address in use, or null when nothing qualifies (never loopback). */
31401
+ resolved: string().nullable(),
31402
+ source: RoleSourceSchema
31403
+ });
31404
+ var HubAppConnectionsResolutionSchema = object({
31405
+ /** The addresses flagged `appConnections`, or empty = automatic. */
31406
+ flagged: array(string()).readonly(),
31407
+ /** What the apps race right now. */
31408
+ resolved: array(string()).readonly(),
31409
+ source: RoleSourceSchema
31410
+ });
31411
+ var HubAddressBookSchema = object({
31412
+ rows: array(ConnectionEndpointSchema.extend({
31413
+ /** In the hub's detected palette right now. */
31414
+ detected: boolean(),
31415
+ /** Entered by the operator (removable). */
31416
+ custom: boolean(),
31417
+ /** The roles explicitly flagged on this address. */
31418
+ flags: array(HubAddressRoleSchema).readonly(),
31419
+ /** The roles this address serves right now — flagged or automatic. */
31420
+ inUse: array(HubAddressRoleSchema).readonly(),
31421
+ /** The roles this address may be flagged with. */
31422
+ eligible: array(HubAddressRoleSchema).readonly()
31423
+ })).readonly(),
31424
+ roles: object({
31425
+ appConnections: HubAppConnectionsResolutionSchema,
31426
+ notificationTaps: HubAddressRoleResolutionSchema,
31427
+ internal: HubAddressRoleResolutionSchema,
31428
+ publicEndpoint: HubAddressRoleResolutionSchema
31429
+ }),
31430
+ /** The `hub=` an app link carries (D709), or null. */
31431
+ appLinkHub: string().nullable()
31432
+ });
30958
31433
  var AllowedAddressesSchema = object({
30959
31434
  /**
30960
31435
  * Allowlist of interface addresses operators have explicitly opted
@@ -30998,16 +31473,27 @@ method(_void(), ListResultSchema), method(_void(), PreferredSchema), method(obje
30998
31473
  * tunnel always emits `https://` regardless. */
30999
31474
  scheme: _enum(["http", "https"]).optional(),
31000
31475
  /** Append the CamStack app link entry (`kind: 'app-link'`, D709) —
31001
- * an address notification links can be flagged with, not a hub
31476
+ * an address notification taps can be flagged with, not a hub
31002
31477
  * route. Default `false`: racers and rankers never see it. */
31003
31478
  includeAppLink: boolean().optional()
31004
- }), GetConnectionEndpointsResultSchema), method(_void(), NotificationEndpointSchema), method(object({ baseUrl: string().nullable() }), NotificationEndpointSchema, { kind: "mutation" }), method(_void(), ViewerEndpointsSchema), method(object({ baseUrls: array(string()).readonly() }), ViewerEndpointsSchema, { kind: "mutation" }), method(_void(), HubAddressesSchema), method(object({
31005
- audience: _enum(["cluster", "browser"]),
31006
- baseUrl: string().nullable()
31007
- }), HubAddressesSchema, {
31479
+ }), GetConnectionEndpointsResultSchema), method(_void(), NotificationEndpointSchema), method(object({ baseUrl: string().nullable() }), NotificationEndpointSchema, { kind: "mutation" }), method(_void(), ViewerEndpointsSchema), method(object({ baseUrls: array(string()).readonly() }), ViewerEndpointsSchema, { kind: "mutation" }), method(object({ scheme: _enum(["http", "https"]).optional() }).optional(), HubAddressBookSchema), method(object({
31480
+ baseUrl: string(),
31481
+ label: string().max(80)
31482
+ }), HubAddressBookSchema, {
31008
31483
  kind: "mutation",
31009
31484
  auth: "admin"
31010
- }), method(_void(), AllowedAddressesSchema), method(AllowedAddressesSchema, object({ success: literal(true) }), { kind: "mutation" }), method(_void(), AllowedAddressesSchema, { kind: "mutation" }), method(_void(), TlsStatusSchema), method(object({ reason: string().optional() }), TlsStatusSchema, {
31485
+ }), method(object({ baseUrl: string() }), HubAddressBookSchema, {
31486
+ kind: "mutation",
31487
+ auth: "admin"
31488
+ }), method(object({
31489
+ role: HubAddressRoleSchema,
31490
+ baseUrl: string().nullable(),
31491
+ enabled: boolean(),
31492
+ acceptInsecureHttp: boolean().optional()
31493
+ }), HubAddressBookSchema, {
31494
+ kind: "mutation",
31495
+ auth: "admin"
31496
+ }), method(_void(), HubAddressesSchema), method(_void(), AllowedAddressesSchema), method(AllowedAddressesSchema, object({ success: literal(true) }), { kind: "mutation" }), method(_void(), AllowedAddressesSchema, { kind: "mutation" }), method(_void(), TlsStatusSchema), method(object({ reason: string().optional() }), TlsStatusSchema, {
31011
31497
  kind: "mutation",
31012
31498
  auth: "admin"
31013
31499
  }), method(object({
@@ -36031,6 +36517,32 @@ var TotpStatusSchema = object({
36031
36517
  /** Null when no row exists OR the row is still pending confirmation. */
36032
36518
  confirmedAt: number().nullable()
36033
36519
  });
36520
+ /**
36521
+ * user-management — singleton capability for user accounts, API keys,
36522
+ * and scoped tokens.
36523
+ *
36524
+ * v2 model: every method gated by `auth: 'admin'`. Admin-only delegation
36525
+ * — the subset check on `setUserScopes` / `createScopedToken` is moot
36526
+ * because non-admins never reach these. If/when we open non-admin
36527
+ * delegation, structural caller-scope subset check goes inside the
36528
+ * provider.
36529
+ */
36530
+ var ExternalIdentitySchema = object({
36531
+ /** Login-method id of the provider instance, e.g. `auth-oidc/authentik`. */
36532
+ provider: string(),
36533
+ /** The IdP's stable subject (`sub`) for this account. */
36534
+ subject: string(),
36535
+ /** The verified `iss` of the IdP the identity was linked under — `sub` is unique only per issuer. */
36536
+ issuer: string(),
36537
+ userId: string(),
36538
+ /** What the IdP called the account at link time (username / email) — display only. */
36539
+ label: string().optional(),
36540
+ linkedAt: number()
36541
+ });
36542
+ var ExternalIdentityKeySchema = object({
36543
+ provider: string().min(1),
36544
+ subject: string().min(1)
36545
+ });
36034
36546
  method(_void(), array(UserSummarySchema), { auth: "admin" }), method(CreateUserInputSchema, UserSummarySchema, {
36035
36547
  kind: "mutation",
36036
36548
  auth: "admin",
@@ -36144,7 +36656,22 @@ method(_void(), array(UserSummarySchema), { auth: "admin" }), method(CreateUserI
36144
36656
  userId: string(),
36145
36657
  username: string(),
36146
36658
  scopes: array(TokenScopeSchema)
36147
- }).nullable(), { access: "view" }), method(_void(), array(OauthSessionSummarySchema), { auth: "admin" }), method(object({ id: string() }), object({ success: boolean() }), {
36659
+ }).nullable(), { access: "view" }), method(object({ userId: string() }), array(ExternalIdentitySchema), { auth: "admin" }), method(ExternalIdentityKeySchema, object({
36660
+ userId: string(),
36661
+ issuer: string()
36662
+ }).nullable(), { auth: "admin" }), method(ExternalIdentityKeySchema.extend({
36663
+ userId: string(),
36664
+ issuer: string().min(1),
36665
+ label: string().optional()
36666
+ }), object({ success: literal(true) }), {
36667
+ kind: "mutation",
36668
+ auth: "admin",
36669
+ access: "create"
36670
+ }), method(ExternalIdentityKeySchema.extend({ userId: string() }), object({ success: boolean() }), {
36671
+ kind: "mutation",
36672
+ auth: "admin",
36673
+ access: "delete"
36674
+ }), method(_void(), array(OauthSessionSummarySchema), { auth: "admin" }), method(object({ id: string() }), object({ success: boolean() }), {
36148
36675
  kind: "mutation",
36149
36676
  auth: "admin",
36150
36677
  access: "delete"
@@ -36536,6 +37063,16 @@ DeviceType.Camera, method(object({
36536
37063
  package: array(ZoneRuleSchema).readonly()
36537
37064
  });
36538
37065
  SOURCE_CAPS.filter((cap) => cap !== "switch" && cap !== "motion");
37066
+ Object.freeze({
37067
+ person: .5,
37068
+ vehicle: .5,
37069
+ animal: .5
37070
+ });
37071
+ Object.freeze({
37072
+ person: .65,
37073
+ vehicle: .65,
37074
+ animal: .65
37075
+ });
36539
37076
  /**
36540
37077
  * Accessory device helpers — shared across drivers.
36541
37078
  *
@@ -36710,6 +37247,12 @@ Object.freeze({
36710
37247
  addonId: null,
36711
37248
  access: "view"
36712
37249
  },
37250
+ "addons.listInstallations": {
37251
+ capName: "addons",
37252
+ capScope: "system",
37253
+ addonId: null,
37254
+ access: "view"
37255
+ },
36713
37256
  "addons.listJobs": {
36714
37257
  capName: "addons",
36715
37258
  capScope: "system",
@@ -37892,90 +38435,18 @@ Object.freeze({
37892
38435
  addonId: null,
37893
38436
  access: "create"
37894
38437
  },
37895
- "decoder.createSession": {
37896
- capName: "decoder",
37897
- capScope: "system",
37898
- addonId: null,
37899
- access: "view"
37900
- },
37901
- "decoder.destroySession": {
37902
- capName: "decoder",
37903
- capScope: "system",
37904
- addonId: null,
37905
- access: "delete"
37906
- },
37907
- "decoder.getFrame": {
37908
- capName: "decoder",
37909
- capScope: "system",
37910
- addonId: null,
37911
- access: "view"
37912
- },
37913
38438
  "decoder.getInfo": {
37914
38439
  capName: "decoder",
37915
38440
  capScope: "system",
37916
38441
  addonId: null,
37917
38442
  access: "view"
37918
38443
  },
37919
- "decoder.getShmStats": {
37920
- capName: "decoder",
37921
- capScope: "system",
37922
- addonId: null,
37923
- access: "view"
37924
- },
37925
- "decoder.getStats": {
37926
- capName: "decoder",
37927
- capScope: "system",
37928
- addonId: null,
37929
- access: "view"
37930
- },
37931
- "decoder.listActiveSessions": {
37932
- capName: "decoder",
37933
- capScope: "system",
37934
- addonId: null,
37935
- access: "view"
37936
- },
37937
- "decoder.openStream": {
37938
- capName: "decoder",
37939
- capScope: "system",
37940
- addonId: null,
37941
- access: "view"
37942
- },
37943
- "decoder.pullFrames": {
37944
- capName: "decoder",
37945
- capScope: "system",
37946
- addonId: null,
37947
- access: "view"
37948
- },
37949
- "decoder.pullHandles": {
37950
- capName: "decoder",
37951
- capScope: "system",
37952
- addonId: null,
37953
- access: "view"
37954
- },
37955
- "decoder.pushPacket": {
37956
- capName: "decoder",
37957
- capScope: "system",
37958
- addonId: null,
37959
- access: "view"
37960
- },
37961
38444
  "decoder.reprobeHwaccel": {
37962
38445
  capName: "decoder",
37963
38446
  capScope: "system",
37964
38447
  addonId: null,
37965
38448
  access: "create"
37966
38449
  },
37967
- "decoder.supportsCodec": {
37968
- capName: "decoder",
37969
- capScope: "system",
37970
- addonId: null,
37971
- access: "view"
37972
- },
37973
- "decoder.updateConfig": {
37974
- capName: "decoder",
37975
- capScope: "system",
37976
- addonId: null,
37977
- access: "view"
37978
- },
37979
38450
  "detectionPipeline.applyDeviceSettingsPatch": {
37980
38451
  capName: "detection-pipeline",
37981
38452
  capScope: "device",
@@ -39464,12 +39935,24 @@ Object.freeze({
39464
39935
  addonId: null,
39465
39936
  access: "view"
39466
39937
  },
39938
+ "localNetwork.addCustomAddress": {
39939
+ capName: "local-network",
39940
+ capScope: "system",
39941
+ addonId: null,
39942
+ access: "create"
39943
+ },
39467
39944
  "localNetwork.downloadCa": {
39468
39945
  capName: "local-network",
39469
39946
  capScope: "system",
39470
39947
  addonId: null,
39471
39948
  access: "view"
39472
39949
  },
39950
+ "localNetwork.getAddresses": {
39951
+ capName: "local-network",
39952
+ capScope: "system",
39953
+ addonId: null,
39954
+ access: "view"
39955
+ },
39473
39956
  "localNetwork.getAllowedAddresses": {
39474
39957
  capName: "local-network",
39475
39958
  capScope: "system",
@@ -39524,6 +40007,12 @@ Object.freeze({
39524
40007
  addonId: null,
39525
40008
  access: "create"
39526
40009
  },
40010
+ "localNetwork.removeCustomAddress": {
40011
+ capName: "local-network",
40012
+ capScope: "system",
40013
+ addonId: null,
40014
+ access: "delete"
40015
+ },
39527
40016
  "localNetwork.resetAllowlistToBestMatch": {
39528
40017
  capName: "local-network",
39529
40018
  capScope: "system",
@@ -39536,13 +40025,13 @@ Object.freeze({
39536
40025
  addonId: null,
39537
40026
  access: "create"
39538
40027
  },
39539
- "localNetwork.setAllowedAddresses": {
40028
+ "localNetwork.setAddressRole": {
39540
40029
  capName: "local-network",
39541
40030
  capScope: "system",
39542
40031
  addonId: null,
39543
40032
  access: "create"
39544
40033
  },
39545
- "localNetwork.setHubAddress": {
40034
+ "localNetwork.setAllowedAddresses": {
39546
40035
  capName: "local-network",
39547
40036
  capScope: "system",
39548
40037
  addonId: null,
@@ -40988,6 +41477,12 @@ Object.freeze({
40988
41477
  addonId: null,
40989
41478
  access: "create"
40990
41479
  },
41480
+ "pipelineAnalytics.setRetrainFrameComplete": {
41481
+ capName: "pipeline-analytics",
41482
+ capScope: "device",
41483
+ addonId: null,
41484
+ access: "create"
41485
+ },
40991
41486
  "pipelineAnalytics.setTrackFlags": {
40992
41487
  capName: "pipeline-analytics",
40993
41488
  capScope: "device",
@@ -41024,6 +41519,12 @@ Object.freeze({
41024
41519
  addonId: null,
41025
41520
  access: "delete"
41026
41521
  },
41522
+ "pipelineAnalytics.writeRetrainArchive": {
41523
+ capName: "pipeline-analytics",
41524
+ capScope: "device",
41525
+ addonId: null,
41526
+ access: "create"
41527
+ },
41027
41528
  "pipelineExecutor.cacheFrameInPool": {
41028
41529
  capName: "pipeline-executor",
41029
41530
  capScope: "system",
@@ -41036,13 +41537,13 @@ Object.freeze({
41036
41537
  addonId: null,
41037
41538
  access: "delete"
41038
41539
  },
41039
- "pipelineExecutor.deleteModel": {
41540
+ "pipelineExecutor.clearModelBoundDeviceOverrides": {
41040
41541
  capName: "pipeline-executor",
41041
41542
  capScope: "system",
41042
41543
  addonId: null,
41043
41544
  access: "delete"
41044
41545
  },
41045
- "pipelineExecutor.deleteTemplate": {
41546
+ "pipelineExecutor.deleteModel": {
41046
41547
  capName: "pipeline-executor",
41047
41548
  capScope: "system",
41048
41549
  addonId: null,
@@ -41186,12 +41687,6 @@ Object.freeze({
41186
41687
  addonId: null,
41187
41688
  access: "view"
41188
41689
  },
41189
- "pipelineExecutor.listTemplates": {
41190
- capName: "pipeline-executor",
41191
- capScope: "system",
41192
- addonId: null,
41193
- access: "view"
41194
- },
41195
41690
  "pipelineExecutor.rearmInferenceDevice": {
41196
41691
  capName: "pipeline-executor",
41197
41692
  capScope: "system",
@@ -41216,12 +41711,6 @@ Object.freeze({
41216
41711
  addonId: null,
41217
41712
  access: "create"
41218
41713
  },
41219
- "pipelineExecutor.saveTemplate": {
41220
- capName: "pipeline-executor",
41221
- capScope: "system",
41222
- addonId: null,
41223
- access: "create"
41224
- },
41225
41714
  "pipelineExecutor.setVideoPipelineSteps": {
41226
41715
  capName: "pipeline-executor",
41227
41716
  capScope: "system",
@@ -41240,41 +41729,35 @@ Object.freeze({
41240
41729
  addonId: null,
41241
41730
  access: "create"
41242
41731
  },
41243
- "pipelineExecutor.updateTemplate": {
41244
- capName: "pipeline-executor",
41245
- capScope: "system",
41246
- addonId: null,
41247
- access: "create"
41248
- },
41249
41732
  "pipelineExecutor.validatePipeline": {
41250
41733
  capName: "pipeline-executor",
41251
41734
  capScope: "system",
41252
41735
  addonId: null,
41253
41736
  access: "view"
41254
41737
  },
41255
- "pipelineOrchestrator.applyDeviceSettingsPatch": {
41738
+ "pipelineOrchestrator.applyAutoTune": {
41256
41739
  capName: "pipeline-orchestrator",
41257
41740
  capScope: "system",
41258
41741
  addonId: null,
41259
41742
  access: "create"
41260
41743
  },
41261
- "pipelineOrchestrator.assignAudio": {
41744
+ "pipelineOrchestrator.applyDeviceSettingsPatch": {
41262
41745
  capName: "pipeline-orchestrator",
41263
41746
  capScope: "system",
41264
41747
  addonId: null,
41265
41748
  access: "create"
41266
41749
  },
41267
- "pipelineOrchestrator.assignPipeline": {
41750
+ "pipelineOrchestrator.assignAudio": {
41268
41751
  capName: "pipeline-orchestrator",
41269
41752
  capScope: "system",
41270
41753
  addonId: null,
41271
41754
  access: "create"
41272
41755
  },
41273
- "pipelineOrchestrator.deleteTemplate": {
41756
+ "pipelineOrchestrator.assignPipeline": {
41274
41757
  capName: "pipeline-orchestrator",
41275
41758
  capScope: "system",
41276
41759
  addonId: null,
41277
- access: "delete"
41760
+ access: "create"
41278
41761
  },
41279
41762
  "pipelineOrchestrator.getAgentLoad": {
41280
41763
  capName: "pipeline-orchestrator",
@@ -41366,6 +41849,12 @@ Object.freeze({
41366
41849
  addonId: null,
41367
41850
  access: "view"
41368
41851
  },
41852
+ "pipelineOrchestrator.getEffectiveShares": {
41853
+ capName: "pipeline-orchestrator",
41854
+ capScope: "system",
41855
+ addonId: null,
41856
+ access: "view"
41857
+ },
41369
41858
  "pipelineOrchestrator.getGlobalMetrics": {
41370
41859
  capName: "pipeline-orchestrator",
41371
41860
  capScope: "system",
@@ -41402,19 +41891,19 @@ Object.freeze({
41402
41891
  addonId: null,
41403
41892
  access: "view"
41404
41893
  },
41405
- "pipelineOrchestrator.getReconcileFromDiskStatus": {
41894
+ "pipelineOrchestrator.getPlacementStats": {
41406
41895
  capName: "pipeline-orchestrator",
41407
41896
  capScope: "system",
41408
41897
  addonId: null,
41409
41898
  access: "view"
41410
41899
  },
41411
- "pipelineOrchestrator.listAgentSettings": {
41900
+ "pipelineOrchestrator.getReconcileFromDiskStatus": {
41412
41901
  capName: "pipeline-orchestrator",
41413
41902
  capScope: "system",
41414
41903
  addonId: null,
41415
41904
  access: "view"
41416
41905
  },
41417
- "pipelineOrchestrator.listTemplates": {
41906
+ "pipelineOrchestrator.listAgentSettings": {
41418
41907
  capName: "pipeline-orchestrator",
41419
41908
  capScope: "system",
41420
41909
  addonId: null,
@@ -41426,6 +41915,12 @@ Object.freeze({
41426
41915
  addonId: null,
41427
41916
  access: "create"
41428
41917
  },
41918
+ "pipelineOrchestrator.planAutoTune": {
41919
+ capName: "pipeline-orchestrator",
41920
+ capScope: "system",
41921
+ addonId: null,
41922
+ access: "view"
41923
+ },
41429
41924
  "pipelineOrchestrator.rebalance": {
41430
41925
  capName: "pipeline-orchestrator",
41431
41926
  capScope: "system",
@@ -41468,12 +41963,6 @@ Object.freeze({
41468
41963
  addonId: null,
41469
41964
  access: "create"
41470
41965
  },
41471
- "pipelineOrchestrator.saveTemplate": {
41472
- capName: "pipeline-orchestrator",
41473
- capScope: "system",
41474
- addonId: null,
41475
- access: "create"
41476
- },
41477
41966
  "pipelineOrchestrator.setAgentCapabilities": {
41478
41967
  capName: "pipeline-orchestrator",
41479
41968
  capScope: "system",
@@ -41486,12 +41975,6 @@ Object.freeze({
41486
41975
  addonId: null,
41487
41976
  access: "create"
41488
41977
  },
41489
- "pipelineOrchestrator.setAgentDetectWeight": {
41490
- capName: "pipeline-orchestrator",
41491
- capScope: "system",
41492
- addonId: null,
41493
- access: "create"
41494
- },
41495
41978
  "pipelineOrchestrator.setAgentInferenceDevices": {
41496
41979
  capName: "pipeline-orchestrator",
41497
41980
  capScope: "system",
@@ -41528,6 +42011,12 @@ Object.freeze({
41528
42011
  addonId: null,
41529
42012
  access: "create"
41530
42013
  },
42014
+ "pipelineOrchestrator.setCameraStepSettings": {
42015
+ capName: "pipeline-orchestrator",
42016
+ capScope: "system",
42017
+ addonId: null,
42018
+ access: "create"
42019
+ },
41531
42020
  "pipelineOrchestrator.setCameraStepToggle": {
41532
42021
  capName: "pipeline-orchestrator",
41533
42022
  capScope: "system",
@@ -41546,25 +42035,37 @@ Object.freeze({
41546
42035
  addonId: null,
41547
42036
  access: "create"
41548
42037
  },
42038
+ "pipelineOrchestrator.setLoadBalancingShares": {
42039
+ capName: "pipeline-orchestrator",
42040
+ capScope: "system",
42041
+ addonId: null,
42042
+ access: "create"
42043
+ },
41549
42044
  "pipelineOrchestrator.setPipelineDevicePin": {
41550
42045
  capName: "pipeline-orchestrator",
41551
42046
  capScope: "system",
41552
42047
  addonId: null,
41553
42048
  access: "create"
41554
42049
  },
41555
- "pipelineOrchestrator.unassignAudio": {
42050
+ "pipelineOrchestrator.setShareSource": {
41556
42051
  capName: "pipeline-orchestrator",
41557
42052
  capScope: "system",
41558
42053
  addonId: null,
41559
42054
  access: "create"
41560
42055
  },
41561
- "pipelineOrchestrator.unassignPipeline": {
42056
+ "pipelineOrchestrator.suggestShares": {
42057
+ capName: "pipeline-orchestrator",
42058
+ capScope: "system",
42059
+ addonId: null,
42060
+ access: "view"
42061
+ },
42062
+ "pipelineOrchestrator.unassignAudio": {
41562
42063
  capName: "pipeline-orchestrator",
41563
42064
  capScope: "system",
41564
42065
  addonId: null,
41565
42066
  access: "create"
41566
42067
  },
41567
- "pipelineOrchestrator.updateTemplate": {
42068
+ "pipelineOrchestrator.unassignPipeline": {
41568
42069
  capName: "pipeline-orchestrator",
41569
42070
  capScope: "system",
41570
42071
  addonId: null,
@@ -43004,12 +43505,6 @@ Object.freeze({
43004
43505
  addonId: null,
43005
43506
  access: "view"
43006
43507
  },
43007
- "streamBroker.pullFrameHandles": {
43008
- capName: "stream-broker",
43009
- capScope: "system",
43010
- addonId: null,
43011
- access: "view"
43012
- },
43013
43508
  "streamBroker.regenerateRtspToken": {
43014
43509
  capName: "stream-broker",
43015
43510
  capScope: "system",
@@ -43076,12 +43571,6 @@ Object.freeze({
43076
43571
  addonId: null,
43077
43572
  access: "create"
43078
43573
  },
43079
- "streamBroker.subscribeFrames": {
43080
- capName: "stream-broker",
43081
- capScope: "system",
43082
- addonId: null,
43083
- access: "create"
43084
- },
43085
43574
  "streamBroker.unassignProfile": {
43086
43575
  capName: "stream-broker",
43087
43576
  capScope: "system",
@@ -43094,12 +43583,6 @@ Object.freeze({
43094
43583
  addonId: null,
43095
43584
  access: "create"
43096
43585
  },
43097
- "streamBroker.unsubscribeFrames": {
43098
- capName: "stream-broker",
43099
- capScope: "system",
43100
- addonId: null,
43101
- access: "create"
43102
- },
43103
43586
  "streamCatalog.getCatalog": {
43104
43587
  capName: "stream-catalog",
43105
43588
  capScope: "device",
@@ -43394,18 +43877,36 @@ Object.freeze({
43394
43877
  addonId: null,
43395
43878
  access: "delete"
43396
43879
  },
43880
+ "userManagement.findUserByExternalIdentity": {
43881
+ capName: "user-management",
43882
+ capScope: "system",
43883
+ addonId: null,
43884
+ access: "view"
43885
+ },
43397
43886
  "userManagement.getTotpStatus": {
43398
43887
  capName: "user-management",
43399
43888
  capScope: "system",
43400
43889
  addonId: null,
43401
43890
  access: "view"
43402
43891
  },
43892
+ "userManagement.linkExternalIdentity": {
43893
+ capName: "user-management",
43894
+ capScope: "system",
43895
+ addonId: null,
43896
+ access: "create"
43897
+ },
43403
43898
  "userManagement.listApiKeys": {
43404
43899
  capName: "user-management",
43405
43900
  capScope: "system",
43406
43901
  addonId: null,
43407
43902
  access: "view"
43408
43903
  },
43904
+ "userManagement.listExternalIdentities": {
43905
+ capName: "user-management",
43906
+ capScope: "system",
43907
+ addonId: null,
43908
+ access: "view"
43909
+ },
43409
43910
  "userManagement.listOauthSessions": {
43410
43911
  capName: "user-management",
43411
43912
  capScope: "system",
@@ -43484,6 +43985,12 @@ Object.freeze({
43484
43985
  addonId: null,
43485
43986
  access: "create"
43486
43987
  },
43988
+ "userManagement.unlinkExternalIdentity": {
43989
+ capName: "user-management",
43990
+ capScope: "system",
43991
+ addonId: null,
43992
+ access: "delete"
43993
+ },
43487
43994
  "userManagement.updateUser": {
43488
43995
  capName: "user-management",
43489
43996
  capScope: "system",
@@ -43796,6 +44303,12 @@ Object.freeze({
43796
44303
  addonId: null,
43797
44304
  access: "create"
43798
44305
  },
44306
+ "webrtcSession.applyDownlinkProbe": {
44307
+ capName: "webrtc-session",
44308
+ capScope: "device",
44309
+ addonId: null,
44310
+ access: "create"
44311
+ },
43799
44312
  "webrtcSession.closeSession": {
43800
44313
  capName: "webrtc-session",
43801
44314
  capScope: "device",
@@ -45607,11 +46120,6 @@ Object.freeze({
45607
46120
  form: "single",
45608
46121
  optional: false
45609
46122
  }],
45610
- "decoder.createSession": [{
45611
- name: "deviceId",
45612
- form: "single",
45613
- optional: true
45614
- }],
45615
46123
  "detectionPipeline.applyDeviceSettingsPatch": [{
45616
46124
  name: "deviceId",
45617
46125
  form: "single",
@@ -46822,6 +47330,11 @@ Object.freeze({
46822
47330
  form: "single",
46823
47331
  optional: false
46824
47332
  }],
47333
+ "pipelineAnalytics.setRetrainFrameComplete": [{
47334
+ name: "deviceId",
47335
+ form: "single",
47336
+ optional: false
47337
+ }],
46825
47338
  "pipelineAnalytics.setTrackFlags": [{
46826
47339
  name: "deviceId",
46827
47340
  form: "single",
@@ -46842,6 +47355,11 @@ Object.freeze({
46842
47355
  form: "single",
46843
47356
  optional: false
46844
47357
  }],
47358
+ "pipelineExecutor.clearModelBoundDeviceOverrides": [{
47359
+ name: "deviceIds",
47360
+ form: "array",
47361
+ optional: true
47362
+ }],
46845
47363
  "pipelineExecutor.runPipeline": [{
46846
47364
  name: "deviceId",
46847
47365
  form: "single",
@@ -46947,6 +47465,11 @@ Object.freeze({
46947
47465
  form: "single",
46948
47466
  optional: false
46949
47467
  }],
47468
+ "pipelineOrchestrator.setCameraStepSettings": [{
47469
+ name: "deviceId",
47470
+ form: "single",
47471
+ optional: false
47472
+ }],
46950
47473
  "pipelineOrchestrator.setCameraStepToggle": [{
46951
47474
  name: "deviceId",
46952
47475
  form: "single",
@@ -47718,6 +48241,11 @@ Object.freeze({
47718
48241
  form: "single",
47719
48242
  optional: false
47720
48243
  }],
48244
+ "webrtcSession.applyDownlinkProbe": [{
48245
+ name: "deviceId",
48246
+ form: "single",
48247
+ optional: false
48248
+ }],
47721
48249
  "webrtcSession.closeSession": [{
47722
48250
  name: "deviceId",
47723
48251
  form: "single",
@@ -48862,10 +49390,11 @@ var MB = 1024 * 1024;
48862
49390
  /**
48863
49391
  * Google Home export — customActions catalog.
48864
49392
  *
48865
- * One entry. The settings form's `type: 'button'` field dispatches through the
48866
- * generic `api.addons.custom.mutate({ addonId, action, input })` channel, so a
48867
- * button here costs no capability, no codegen and no framework publish train —
48868
- * the catalog travels inside this addon's own bundle.
49393
+ * One entry. The settings form's `addon-action-button` dispatches through the
49394
+ * generic `api.addons.custom.mutate({ addonId, action, input })` channel and
49395
+ * shows the result under the button, so a button here costs no capability, no
49396
+ * codegen and no framework publish train — the catalog travels inside this
49397
+ * addon's own bundle. Admin-only: it writes this addon's settings.
48869
49398
  */
48870
49399
  var exportGoogleActions = defineCustomActions({
48871
49400
  /**
@@ -48881,8 +49410,13 @@ var exportGoogleActions = defineCustomActions({
48881
49410
  detectPublicHubUrl: customAction(object({}).optional(), object({
48882
49411
  publicHubUrl: string(),
48883
49412
  detectedPublicHubUrl: string(),
48884
- filled: boolean()
48885
- }), { kind: "mutation" }) });
49413
+ filled: boolean(),
49414
+ /** One sentence saying what happened, for the button. */
49415
+ summary: string()
49416
+ }), {
49417
+ kind: "mutation",
49418
+ auth: "admin"
49419
+ }) });
48886
49420
  //#endregion
48887
49421
  //#region src/google-home/trait-catalog.ts
48888
49422
  /**
@@ -49679,7 +50213,7 @@ function buildGoogleOauthIntegration() {
49679
50213
  * cross-process through `ctx.api` — unlike the `addons` core router, which a
49680
50214
  * forked addon calling `ctx.api.addons.*` would wait on forever.
49681
50215
  *
49682
- * **Not** the hub's own address from `local-network` (`pickHubBaseUrl`). That
50216
+ * **Not** the hub's own address from `local-network` (`getAddresses().roles`). That
49683
50217
  * answers a different question — which address an agent or a browser on the
49684
50218
  * LAN reaches — and it is routinely a LAN address; the backend's
49685
50219
  * `publicHubUrl()` fallback is localhost in dev. Google calls from its own
@@ -49911,6 +50445,14 @@ var refreshPublicHubUrl = async (deps) => {
49911
50445
  else if (resolution.publicHubUrl.length === 0) deps.logger.warn("export-google: public hub URL still unset after detection — the Google console URLs cannot be rendered until one is available", { meta: { detectedCount: detected.length } });
49912
50446
  return resolution;
49913
50447
  };
50448
+ /** What "Detect external address" did, in one sentence for the button. */
50449
+ function describeDetectResult(result) {
50450
+ const { publicHubUrl, detectedPublicHubUrl, filled } = result;
50451
+ if (filled) return `Filled in ${publicHubUrl}.`;
50452
+ if (detectedPublicHubUrl.length === 0) return publicHubUrl.length > 0 ? `No public HTTPS address detected; your value ${publicHubUrl} was kept.` : "No public HTTPS address detected. Set up remote access first.";
50453
+ if (detectedPublicHubUrl === publicHubUrl) return `Detected ${publicHubUrl}, already in use.`;
50454
+ return `Detected ${detectedPublicHubUrl}; your value ${publicHubUrl} was kept.`;
50455
+ }
49914
50456
  //#endregion
49915
50457
  //#region src/types.ts
49916
50458
  var DEFAULT_SETTINGS = {
@@ -50093,11 +50635,15 @@ var ExportGoogleAddon = class extends BaseAddon {
50093
50635
  persist: (patch) => this.updateGlobalSettings(patch),
50094
50636
  logger: this.ctx.logger
50095
50637
  });
50096
- return {
50638
+ const result = {
50097
50639
  publicHubUrl: resolution.publicHubUrl,
50098
50640
  detectedPublicHubUrl: resolution.detectedPublicHubUrl,
50099
50641
  filled: resolution.defaulted
50100
50642
  };
50643
+ return {
50644
+ ...result,
50645
+ summary: describeDetectResult(result)
50646
+ };
50101
50647
  }
50102
50648
  async onShutdown() {
50103
50649
  this.gateway = null;
@@ -50176,7 +50722,7 @@ var ExportGoogleAddon = class extends BaseAddon {
50176
50722
  globalSettingsSchema() {
50177
50723
  return this.schema({ sections: [{
50178
50724
  id: ADDON_ID,
50179
- title: "Google Home export",
50725
+ title: "Connection",
50180
50726
  description: "Publishes switches, dimmable lights, locks and covers to Google Home. The hub answers Google directly — no cloud function, and no Google credential is stored here.",
50181
50727
  columns: 1,
50182
50728
  fields: [
@@ -50206,13 +50752,15 @@ var ExportGoogleAddon = class extends BaseAddon {
50206
50752
  ...buildPublicHubUrlNotice(this.publicHubUrlState())
50207
50753
  },
50208
50754
  {
50209
- type: "button",
50755
+ type: "addon-action-button",
50756
+ addonId: ADDON_ID,
50210
50757
  key: "__detect-public-hub-url",
50211
50758
  label: "External address",
50212
50759
  description: "Re-scan the connected remote-access providers. Fills the field above when it is empty; a value you set is left exactly as it is.",
50213
50760
  buttonLabel: "Detect external address",
50214
50761
  action: "detectPublicHubUrl",
50215
- variant: "default"
50762
+ variant: "default",
50763
+ successMessage: "{summary}"
50216
50764
  }
50217
50765
  ]
50218
50766
  }] });