@camstack/addon-decoder-ffmpeg 1.2.16 → 1.2.18

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.
Files changed (3) hide show
  1. package/dist/index.js +2690 -85
  2. package/dist/index.mjs +2690 -85
  3. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@ Object.defineProperties(exports, {
4
4
  });
5
5
  let node_crypto = require("node:crypto");
6
6
  let node_child_process = require("node:child_process");
7
- //#region ../types/dist/event-category-Cv9dO26A.mjs
7
+ //#region ../types/dist/event-category-Bxo5yJjt.mjs
8
8
  var EventCategory = /* @__PURE__ */ function(EventCategory) {
9
9
  EventCategory["SystemBoot"] = "system.boot";
10
10
  EventCategory["SystemAddonsReady"] = "system.addons-ready";
@@ -211,6 +211,33 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
211
211
  EventCategory["PipelineCameraAssigned"] = "pipeline.camera-assigned";
212
212
  EventCategory["PipelineCameraUnassigned"] = "pipeline.camera-unassigned";
213
213
  /**
214
+ * A node the orchestrator would otherwise place cameras on has NO usable
215
+ * inference device: the operator enabled one or more accelerators there and
216
+ * the live probe reports every one of them unavailable. Emitted once per
217
+ * TRANSITION into that state (never per dispatch), and the node is dropped
218
+ * from the placement candidate set for as long as it holds.
219
+ *
220
+ * This exists because the state was previously invisible: little-unraid
221
+ * absorbed 283k inference errors in a day while still being handed cameras,
222
+ * and nothing in the system said so.
223
+ *
224
+ * A node with no accelerators configured at all is NOT this — its devices
225
+ * are `disabled`, not `unavailable`, and the runner's default CPU pool
226
+ * serves it exactly as before.
227
+ */
228
+ EventCategory["PipelineNodeInferenceUnavailable"] = "pipeline.node-inference-unavailable";
229
+ /**
230
+ * A camera has an OPEN detection session and has produced no detection at
231
+ * all for longer than the blind threshold — the camera is being decoded and
232
+ * inferred and is returning nothing. Emitted once per transition into blind,
233
+ * per camera.
234
+ *
235
+ * The failure it reports: a 1h43 detection blackout on the entrance camera
236
+ * that nobody noticed, because "a camera that detects nothing" and "a quiet
237
+ * camera" produce byte-identical silence.
238
+ */
239
+ EventCategory["PipelineDetectionBlind"] = "pipeline.detection-blind";
240
+ /**
214
241
  * Per-camera pipeline config was mutated by the orchestrator
215
242
  * (3-level settings change via `setAgentAddonDefaults` /
216
243
  * `setCameraStepToggle` / `setCameraPipelineForAgent` or a
@@ -3002,6 +3029,9 @@ function handlePipeResult(left, next, ctx) {
3002
3029
  fallback: left.fallback
3003
3030
  }, ctx);
3004
3031
  }
3032
+ var $ZodPreprocess = /*@__PURE__*/ $constructor("$ZodPreprocess", (inst, def) => {
3033
+ $ZodPipe.init(inst, def);
3034
+ });
3005
3035
  var $ZodReadonly = /*@__PURE__*/ $constructor("$ZodReadonly", (inst, def) => {
3006
3036
  $ZodType.init(inst, def);
3007
3037
  defineLazy(inst._zod, "propValues", () => def.innerType._zod.propValues);
@@ -5187,6 +5217,10 @@ function pipe(in_, out) {
5187
5217
  out
5188
5218
  });
5189
5219
  }
5220
+ var ZodPreprocess = /*@__PURE__*/ $constructor("ZodPreprocess", (inst, def) => {
5221
+ ZodPipe.init(inst, def);
5222
+ $ZodPreprocess.init(inst, def);
5223
+ });
5190
5224
  var ZodReadonly = /*@__PURE__*/ $constructor("ZodReadonly", (inst, def) => {
5191
5225
  $ZodReadonly.init(inst, def);
5192
5226
  ZodType.init(inst, def);
@@ -5245,6 +5279,13 @@ function _instanceof(cls, params = {}) {
5245
5279
  };
5246
5280
  return inst;
5247
5281
  }
5282
+ function preprocess(fn, schema) {
5283
+ return new ZodPreprocess({
5284
+ type: "pipe",
5285
+ in: transform(fn),
5286
+ out: schema
5287
+ });
5288
+ }
5248
5289
  //#endregion
5249
5290
  //#region ../../node_modules/zod/v4/classic/compat.js
5250
5291
  /** @deprecated Use the raw string literal codes instead, e.g. "invalid_type". */
@@ -10812,6 +10853,8 @@ var QueryFilterSchema = object({
10812
10853
  where: record(string(), unknown()).optional(),
10813
10854
  whereIn: record(string(), array(unknown())).optional(),
10814
10855
  whereBetween: record(string(), tuple([unknown(), unknown()])).optional(),
10856
+ /** NULL-safe exclusion: matches rows whose field is NULL OR != the value. */
10857
+ whereNot: record(string(), unknown()).optional(),
10815
10858
  orderBy: object({
10816
10859
  field: string(),
10817
10860
  direction: _enum(["asc", "desc"])
@@ -10831,7 +10874,8 @@ var QueryFilterSchema = object({
10831
10874
  var MutationFilterSchema = object({
10832
10875
  where: record(string(), unknown()).optional(),
10833
10876
  whereIn: record(string(), array(unknown())).optional(),
10834
- whereBetween: record(string(), tuple([unknown(), unknown()])).optional()
10877
+ whereBetween: record(string(), tuple([unknown(), unknown()])).optional(),
10878
+ whereNot: record(string(), unknown()).optional()
10835
10879
  });
10836
10880
  /** A single stored record: `{ id, data }`. */
10837
10881
  var SettingsRecordSchema = object({
@@ -12281,6 +12325,17 @@ var LlmImageSchema = object({
12281
12325
  bytes: _instanceof(Uint8Array),
12282
12326
  mimeType: string()
12283
12327
  });
12328
+ /**
12329
+ * Retry policy. `enabled: false` is NOT the same as `maxAttempts: 1` in intent —
12330
+ * the flag is what a consumer table flips, the count is what the operator tunes.
12331
+ * A retry doubles the wall time of a call, so the two gates that run inside a
12332
+ * notification's budget keep it off (see `CONSUMER_RETRY_POLICY` in addon-ai).
12333
+ */
12334
+ var LlmRetryPolicySchema = object({
12335
+ enabled: boolean().default(false),
12336
+ /** Total attempts INCLUDING the first. 1 = no retry. */
12337
+ maxAttempts: number().int().min(1).max(5).default(1)
12338
+ });
12284
12339
  var LlmGenerateBaseInputSchema = object({
12285
12340
  /** Collection routing (the notification-output posture). */
12286
12341
  addonId: string().optional(),
@@ -12295,7 +12350,28 @@ var LlmGenerateBaseInputSchema = object({
12295
12350
  jsonSchema: record(string(), unknown()).optional(),
12296
12351
  /** Per-call override of the profile default. */
12297
12352
  maxTokens: number().int().positive().optional(),
12298
- temperature: number().optional()
12353
+ temperature: number().optional(),
12354
+ /** Per-call override of the profile default (nucleus sampling). */
12355
+ topP: number().min(0).max(1).optional(),
12356
+ /** Per-call override of the profile default (top-k sampling). */
12357
+ topK: number().int().positive().optional(),
12358
+ /** Per-call override of `profile.timeoutMs` — the total generation bound. */
12359
+ timeoutMs: number().int().positive().optional(),
12360
+ /** Per-call override; beats both the consumer table and the profile. */
12361
+ retry: LlmRetryPolicySchema.optional(),
12362
+ /**
12363
+ * Caller-minted id that makes this generation CANCELLABLE.
12364
+ *
12365
+ * Without it a caller that stops waiting cannot stop the work: the gates race
12366
+ * the call against 8 s and free their own slot when the timer wins, while the
12367
+ * generation upstream keeps running to `profile.timeoutMs` — 60 s by default,
12368
+ * on a single-threaded local model. The per-camera bound then counts WAITS,
12369
+ * not generations, and the real load is unbounded.
12370
+ *
12371
+ * `AbortSignal` cannot cross a process boundary; an id can. Pass one here and
12372
+ * `llm.cancel({ requestId })` tears the socket down.
12373
+ */
12374
+ requestId: string().optional()
12299
12375
  });
12300
12376
  /**
12301
12377
  * `llm-runtime` — node-side managed llama.cpp executor (spec §4). Registered
@@ -12308,6 +12384,18 @@ var LlmGenerateBaseInputSchema = object({
12308
12384
  * Resource ceiling = llama-server flags + idleStopMinutes ONLY (no RSS
12309
12385
  * watchdog — operator decision #3).
12310
12386
  */
12387
+ /**
12388
+ * A companion artifact that MUST land beside the main GGUF: the `mmproj`
12389
+ * projector of a vision model, or shards 2..N of a split GGUF. Carried on the
12390
+ * REF rather than looked up at install time, so what the operator approved in
12391
+ * the preview is exactly what the node downloads.
12392
+ */
12393
+ var ManagedModelExtraFileSchema = object({
12394
+ url: string(),
12395
+ filename: string(),
12396
+ sizeBytes: number(),
12397
+ sha256: string().optional()
12398
+ });
12311
12399
  var ManagedModelRefSchema = discriminatedUnion("kind", [
12312
12400
  object({
12313
12401
  kind: literal("catalog"),
@@ -12316,7 +12404,11 @@ var ManagedModelRefSchema = discriminatedUnion("kind", [
12316
12404
  object({
12317
12405
  kind: literal("url"),
12318
12406
  url: string(),
12319
- sha256: string().optional()
12407
+ sha256: string().optional(),
12408
+ /** Picker/status label; the file basename when absent. */
12409
+ label: string().optional(),
12410
+ sizeBytes: number().optional(),
12411
+ extraFiles: array(ManagedModelExtraFileSchema).optional()
12320
12412
  }),
12321
12413
  object({
12322
12414
  kind: literal("path"),
@@ -12334,13 +12426,82 @@ var ManagedRuntimeConfigSchema = object({
12334
12426
  gpuLayers: number().int().default(0),
12335
12427
  /** Default: cpus-2, clamped ≥1 (resolved node-side). */
12336
12428
  threads: number().int().optional(),
12337
- /** Concurrent slots. */
12429
+ /** Concurrent slots (`--parallel`). */
12338
12430
  parallel: number().int().default(1),
12431
+ /** Logical batch size (`-b`). Larger = faster prompt ingest, more RAM. */
12432
+ batchSize: number().int().positive().optional(),
12433
+ /** Physical batch / micro-batch (`-ub`). */
12434
+ ubatchSize: number().int().positive().optional(),
12435
+ /**
12436
+ * `--flash-attn`. Cuts KV-cache memory on the backends that implement it and
12437
+ * is a no-op elsewhere, so it is offered rather than assumed.
12438
+ */
12439
+ flashAttention: boolean().default(false),
12440
+ /**
12441
+ * `--mlock`. Pins the weights in RAM so the OS cannot page them out mid
12442
+ * inference. Costs the full model size in resident memory — which is exactly
12443
+ * what the RAM budget is counting.
12444
+ */
12445
+ mlock: boolean().default(false),
12446
+ /**
12447
+ * `--no-mmap`. Reads the whole GGUF up front instead of mapping it. Slower to
12448
+ * start, but avoids the page-fault stalls a network or spinning-disk model
12449
+ * store produces on every first token.
12450
+ */
12451
+ noMmap: boolean().default(false),
12452
+ /** `--cache-type-k` / `--cache-type-v` — quantising the KV cache is the
12453
+ * cheapest way to fit a longer context in the same RAM. */
12454
+ cacheTypeK: _enum([
12455
+ "f32",
12456
+ "f16",
12457
+ "q8_0",
12458
+ "q5_1",
12459
+ "q5_0",
12460
+ "q4_1",
12461
+ "q4_0"
12462
+ ]).optional(),
12463
+ cacheTypeV: _enum([
12464
+ "f32",
12465
+ "f16",
12466
+ "q8_0",
12467
+ "q5_1",
12468
+ "q5_0",
12469
+ "q4_1",
12470
+ "q4_0"
12471
+ ]).optional(),
12472
+ /**
12473
+ * Escape hatch for llama-server flags this schema does NOT model — `--jinja`
12474
+ * (which most vision chat templates need and some language-only models
12475
+ * dislike), `--cont-batching`, `--rope-scaling`, …
12476
+ *
12477
+ * It is NOT a second place to set the flags above. A token that collides
12478
+ * with a typed field is REJECTED at start, naming the field that owns it
12479
+ * (`assertNoOwnedFlags`), because two knobs writing the same argv is exactly
12480
+ * the "two switches that disagree" failure this repo has already shipped
12481
+ * twice (D62).
12482
+ */
12483
+ extraArgs: array(string()).default([]),
12339
12484
  /** Else lazy: first generate boots it. */
12340
12485
  autoStart: boolean().default(false),
12341
12486
  /** 0 = never; frees RAM after quiet periods. */
12342
12487
  idleStopMinutes: number().int().default(30)
12343
12488
  });
12489
+ /**
12490
+ * Where a multi-GB install currently is. A single 0..1 fraction cannot answer
12491
+ * "is it stuck?" for an install that is three files (shards + mmproj) followed
12492
+ * by a sha256 pass over 22 GB — during which the fraction sat at 1.0 and the
12493
+ * node looked hung. Phase + file + bytes is the smallest shape that does.
12494
+ */
12495
+ var LlmDownloadProgressSchema = object({
12496
+ phase: _enum(["downloading", "verifying"]),
12497
+ /** The artifact currently moving, e.g. `mmproj-F16.gguf`. */
12498
+ file: string(),
12499
+ fileIndex: number().int(),
12500
+ fileCount: number().int(),
12501
+ /** Across the WHOLE install, not the current file. */
12502
+ downloadedBytes: number(),
12503
+ totalBytes: number().optional()
12504
+ });
12344
12505
  var LlmRuntimeStatusSchema = object({
12345
12506
  /** Status is ALWAYS node-qualified. */
12346
12507
  nodeId: string(),
@@ -12357,6 +12518,8 @@ var LlmRuntimeStatusSchema = object({
12357
12518
  modelPath: string().optional(),
12358
12519
  modelId: string().optional(),
12359
12520
  downloadProgress: number().min(0).max(1).optional(),
12521
+ /** Detail behind `downloadProgress`; present for the same lifetime. */
12522
+ download: LlmDownloadProgressSchema.optional(),
12360
12523
  lastError: string().optional(),
12361
12524
  crashesInWindow: number(),
12362
12525
  /** Child RSS (sampled best-effort). */
@@ -12367,7 +12530,14 @@ var LlmNodeModelSchema = object({
12367
12530
  file: string(),
12368
12531
  sizeBytes: number(),
12369
12532
  catalogId: string().optional(),
12370
- installedAt: number().optional()
12533
+ installedAt: number().optional(),
12534
+ /**
12535
+ * Absolute path on the node. Present so a file that is on disk but matches
12536
+ * no catalog entry — a custom Hugging Face install, or a GGUF the operator
12537
+ * copied in by hand — is still SELECTABLE, as a `{kind:'path'}` ref. Without
12538
+ * it the picker could list such a file and do nothing with it.
12539
+ */
12540
+ path: string().optional()
12371
12541
  });
12372
12542
  var LlmRuntimeDiskUsageSchema = object({
12373
12543
  nodeId: string(),
@@ -12423,10 +12593,47 @@ var LlmProfileSchema = object({
12423
12593
  baseUrl: string().optional(),
12424
12594
  /** ConfigUISchema type:'password' — never round-trips (spec §5). */
12425
12595
  apiKey: string().optional(),
12596
+ /** Vision on/off. A vision call against a `false` profile is REFUSED, never
12597
+ * degraded to text — that shipped once and produced a confident answer to a
12598
+ * question about a picture nobody sent. */
12426
12599
  supportsVision: boolean(),
12427
12600
  temperature: number().min(0).max(2).optional(),
12601
+ /** Nucleus sampling. Every wire we speak has it. */
12602
+ topP: number().min(0).max(1).optional(),
12603
+ /** Top-k sampling. Carried only by the wires that have it — NEITHER OpenAI
12604
+ * wire does, and the client drops it there (measured: the request body gets
12605
+ * `top_p` and no `top_k`). The profile editor hides the field wherever it
12606
+ * would change nothing; `KINDS_WITH_TOP_K` is the single owner of that list. */
12607
+ topK: number().int().positive().optional(),
12428
12608
  maxTokens: number().int().positive().optional(),
12609
+ /** Prompt context window. Advisory for cloud kinds (they enforce their own);
12610
+ * for `managed-local` it is the llama.cpp `--ctx-size` the runtime starts
12611
+ * the model with, so it is the one field that changes a PROCESS. */
12612
+ contextLength: number().int().positive().optional(),
12613
+ /** Default system prompt. A caller's `system` REPLACES it (never appends —
12614
+ * two system prompts fighting is worse than either alone). */
12615
+ systemPrompt: string().optional(),
12616
+ /** Total generation bound — the only one a unary call has. */
12429
12617
  timeoutMs: number().int().positive().default(6e4),
12618
+ /** The TCP handshake only — "is the port even open". NOT the wait for
12619
+ * response headers: on the LM Studio / llama-server wire those are written
12620
+ * once the model has finished loading, so they belong to the bound below. */
12621
+ connectTimeoutMs: number().int().positive().default(1e4),
12622
+ /** Accepted, but no output yet — response headers included, because a cold
12623
+ * GPU load is exactly what happens before them. */
12624
+ firstTokenTimeoutMs: number().int().positive().default(12e4),
12625
+ /** Output started then stopped. */
12626
+ idleTimeoutMs: number().int().positive().default(6e4),
12627
+ /** Profile-level default. The per-consumer table and a per-call override
12628
+ * both beat it — see `resolveRetryPolicy`. */
12629
+ retry: LlmRetryPolicySchema.default({
12630
+ enabled: false,
12631
+ maxAttempts: 1
12632
+ }),
12633
+ /** Whether this profile may use tools. The tool-call plumbing rides the
12634
+ * library; the REGISTRY of callable tools is ours and is empty in v1, so a
12635
+ * `true` here buys the wiring, not behaviour, until tools are registered. */
12636
+ toolsEnabled: boolean().default(false),
12430
12637
  extraHeaders: record(string(), string()).optional(),
12431
12638
  /** kind === 'managed-local' only (spec §4). */
12432
12639
  runtime: ManagedRuntimeConfigSchema.optional()
@@ -12476,6 +12683,36 @@ var ManagedModelCatalogEntrySchema = object({
12476
12683
  /** Vision models: companion projector file. */
12477
12684
  mmprojUrl: string().optional()
12478
12685
  });
12686
+ /**
12687
+ * The outcome of turning one operator-typed Hugging Face reference into a
12688
+ * download plan. A RESULT, never a throw: "this repo has 24 quantizations and
12689
+ * I will not pick for you" is a normal answer the UI has to render, not an
12690
+ * exception.
12691
+ *
12692
+ * `candidates` is the whole reason the refusal is usable — every string in it
12693
+ * is a tag that resolves when pasted back as `<org>/<repo>:<TAG>`.
12694
+ */
12695
+ var HfModelResolutionSchema = discriminatedUnion("ok", [object({
12696
+ ok: literal(true),
12697
+ /** Ready to hand to `installModel` unchanged. */
12698
+ model: ManagedModelRefSchema,
12699
+ label: string(),
12700
+ repo: string(),
12701
+ quantization: string(),
12702
+ purpose: _enum(["text", "vision"]),
12703
+ totalBytes: number(),
12704
+ /** mmproj + shards, for the preview: an operator approving 23 GB should
12705
+ * see that 0.9 GB of it is a projector they did not name. */
12706
+ extraFilenames: array(string())
12707
+ }), object({
12708
+ ok: literal(false),
12709
+ code: string(),
12710
+ message: string(),
12711
+ candidates: array(string()).optional(),
12712
+ /** Set when the refusal was only the ceiling: re-calling with
12713
+ * `maxBytes: requiredBytes` is the operator's explicit override. */
12714
+ requiredBytes: number().optional()
12715
+ })]);
12479
12716
  var LlmRuntimeNodeSchema = object({
12480
12717
  nodeId: string(),
12481
12718
  reachable: boolean(),
@@ -12488,7 +12725,10 @@ var ProfileRefInputSchema = object({
12488
12725
  addonId: string(),
12489
12726
  profileId: string()
12490
12727
  });
12491
- method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, { kind: "mutation" }), method(GenerateVisionInputSchema, LlmGenerateResultSchema, { kind: "mutation" }), method(object({}), array(LlmProfileKindDescriptorSchema)), method(object({}), array(LlmProfileSchema)), method(object({ profile: LlmProfileSchema }), LlmProfileSchema, {
12728
+ method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, { kind: "mutation" }), method(GenerateVisionInputSchema, LlmGenerateResultSchema, { kind: "mutation" }), method(object({
12729
+ addonId: string().optional(),
12730
+ requestId: string()
12731
+ }), _void(), { kind: "mutation" }), method(object({}), array(LlmProfileKindDescriptorSchema)), method(object({}), array(LlmProfileSchema)), method(object({ profile: LlmProfileSchema }), LlmProfileSchema, {
12492
12732
  kind: "mutation",
12493
12733
  auth: "admin"
12494
12734
  }), method(ProfileRefInputSchema, _void(), {
@@ -12509,6 +12749,15 @@ method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, { kind: "mutation" }
12509
12749
  consumer: string().optional(),
12510
12750
  profileId: string().optional()
12511
12751
  }), array(LlmUsageRollupSchema)), method(object({}), array(ManagedModelCatalogEntrySchema)), method(object({}), array(LlmRuntimeNodeSchema)), method(object({ nodeId: string() }), array(LlmNodeModelSchema)), method(object({
12752
+ /** `https://huggingface.co/<org>/<repo>/resolve/main/<f>.gguf`,
12753
+ * `<org>/<repo>/<f>.gguf`, `<org>/<repo>` or `<org>/<repo>:<QUANT>`. */
12754
+ ref: string(),
12755
+ /** Explicit ceiling override, in bytes. Absent = the built-in ceiling. */
12756
+ maxBytes: number().positive().optional()
12757
+ }), HfModelResolutionSchema, {
12758
+ kind: "mutation",
12759
+ auth: "admin"
12760
+ }), method(object({
12512
12761
  nodeId: string(),
12513
12762
  model: ManagedModelRefSchema
12514
12763
  }), _void(), {
@@ -14118,6 +14367,8 @@ var NcSystemEventKindSchema = _enum([
14118
14367
  "stream-offline",
14119
14368
  "node-online",
14120
14369
  "node-offline",
14370
+ "node-inference-unavailable",
14371
+ "detection-blind",
14121
14372
  "addon-update-available",
14122
14373
  "server-update-available",
14123
14374
  "alarm-triggered",
@@ -14179,7 +14430,16 @@ var NcScheduleSchema = object({
14179
14430
  });
14180
14431
  /** Fuzzy plate matcher — OCR noise makes exact match useless (spec row 12/13). */
14181
14432
  var NcPlateMatcherSchema = object({
14182
- values: array(string().min(1)).min(1),
14433
+ /**
14434
+ * Plate texts (or gallery vehicle names) to match. EMPTY = **any plate the
14435
+ * pipeline could read** — the plate half of "no selection = no narrowing",
14436
+ * and the switch that says this rule is about vehicles that were IDENTIFIED
14437
+ * rather than merely seen. A subject carrying no plate still fails.
14438
+ *
14439
+ * The `.min(1)` this used to carry made that state unauthorable; nothing has
14440
+ * ever persisted an empty list, so widening it cannot change an existing rule.
14441
+ */
14442
+ values: array(string().min(1)),
14183
14443
  /** Max Levenshtein distance after normalization (uppercase alphanumeric). */
14184
14444
  maxDistance: number().int().min(0).max(3).default(1)
14185
14445
  });
@@ -14213,28 +14473,36 @@ var NcOccupancyConditionSchema = object({
14213
14473
  /**
14214
14474
  * Audio condition (IMMEDIATE trigger) — a rule on SOUND, not on a picture.
14215
14475
  *
14216
- * Operator-approved vocabulary (2026-08-12, option A — the same one the
14217
- * reference notifier uses, so an operator moving between them re-uses what
14218
- * they already know): a rule matches when, over a sampling window of
14219
- * `samplingSeconds`, at least `hitPercent`% of the audio samples in that
14220
- * window are HITS. A sample is a hit when it satisfies BOTH present filters:
14221
- *
14222
- * - `dbThreshold` its level is at or above this many dBFS (see
14223
- * {@link NC_AUDIO_DBFS_FLOOR}: negative-going, `0` = full scale);
14224
- * - `labels` the classifier put at least one of these labels on it.
14225
- *
14226
- * Both are OPTIONAL and independent, which is the point of the shape: a
14227
- * loudness rule ("something loud at 3am") needs no model to be right, and a
14228
- * label rule ("a dog barked") needs no threshold. **Fail-closed when NEITHER
14229
- * is given** a window in which every sample is trivially a hit would fire on
14230
- * silence, so the engine refuses such a condition rather than notifying on
14231
- * nothing (the schema cannot express "at least one of" without becoming a
14232
- * ZodEffects the cap path would have to special-case).
14233
- *
14234
- * `hitPercent` is over the samples the window actually HOLDS, and the window
14235
- * must be FULL before it can match a window that has been open for two
14236
- * seconds of its ten is 100% of nothing, and firing on it would make
14237
- * `samplingSeconds` decorative.
14476
+ * **TWO EXCLUSIVE MODES** (operator decision 2026-08-14, D157). Which one a
14477
+ * rule is in is not a stored field it is WHICH FILTER the rule carries, so
14478
+ * there is no second switch that can disagree with the first and every rule
14479
+ * authored before the decision migrates for free (`audioModeOf`):
14480
+ *
14481
+ * - **LABEL mode — `labels` present.** The rule fires on the FIRST frame the
14482
+ * classifier labels with one of them. No window, no percentage:
14483
+ * `hitPercent` and `samplingSeconds` are ignored, and the rule's own
14484
+ * `throttle` cooldown is the only brake. The per-label confidence floor is
14485
+ * the analyzer's (`classificationMinScore`, per device) — a label only
14486
+ * reaches this condition if the classifier was already confident enough.
14487
+ * - **LEVEL mode `dbThreshold` present, no labels.** The sampling window IS
14488
+ * the condition: at least `hitPercent`% of the samples over
14489
+ * `samplingSeconds` must be at or above `dbThreshold` dBFS (see
14490
+ * {@link NC_AUDIO_DBFS_FLOOR}: negative-going, `0` = full scale). The window
14491
+ * must be FULL before it can match a window open for two of its ten
14492
+ * seconds is 100% of nothing.
14493
+ *
14494
+ * **Why label mode has no window.** It had one, and it never fired: the
14495
+ * analyzer emits ~1 audio frame per second but YAMNet only LABELS one to three
14496
+ * of them per episode, even through continuous crying. The measured maximum
14497
+ * `hitPercent` over the whole live history was 40 — under the shipped default
14498
+ * of 60, so a label rule could not fire at all, ever. A percentage of frames is
14499
+ * the wrong question to ask of a sparse classifier.
14500
+ *
14501
+ * **Fail-closed when NEITHER is given** — every sample would be a trivial hit
14502
+ * and the rule would fire on silence. The schema cannot express "exactly one
14503
+ * of" without becoming a ZodEffects the cap path would have to special-case, so
14504
+ * the exclusivity is enforced where every editor writes (`patchAudio`) and a
14505
+ * legacy rule carrying both resolves to LABEL (the mode that fires).
14238
14506
  *
14239
14507
  * Labels are the audio macro classes (`AUDIO_MACRO_LABELS` / the NC taxonomy's
14240
14508
  * `audio-*` ids). Both spellings are accepted — the matcher normalizes the
@@ -14242,13 +14510,13 @@ var NcOccupancyConditionSchema = object({
14242
14510
  * an operator who typed `dog` mean the same thing.
14243
14511
  */
14244
14512
  var NcAudioConditionSchema = object({
14245
- /** Audio macro labels; absent = any sound (level-only rule). */
14513
+ /** LABEL MODE: audio macro labels. Present fires on the first labelled frame. */
14246
14514
  labels: array(string().min(1)).min(1).optional(),
14247
- /** Level floor in dBFS (negative-going, `0` = full scale); absent = any level. */
14515
+ /** LEVEL MODE: floor in dBFS (negative-going, `0` = full scale). */
14248
14516
  dbThreshold: number().min(-96).max(0).optional(),
14249
- /** Percentage of the window's samples that must be hits (1–100). */
14517
+ /** LEVEL MODE ONLY: percentage of the window's samples that must be hits (1–100). */
14250
14518
  hitPercent: number().int().min(1).max(100).default(60),
14251
- /** Length of the sampling window in seconds. */
14519
+ /** LEVEL MODE ONLY: length of the sampling window in seconds. */
14252
14520
  samplingSeconds: number().int().min(1).max(300).default(10)
14253
14521
  });
14254
14522
  /**
@@ -14386,13 +14654,81 @@ var NcRuleActionsSchema = object({
14386
14654
  */
14387
14655
  buttons: array(NcRuleNotificationButtonSchema).max(8).optional()
14388
14656
  });
14657
+ /**
14658
+ * "This rule applies only while `deviceId` is in one of `states`."
14659
+ *
14660
+ * The states are the DEVICE's own vocabulary — `AlarmState` for a panel,
14661
+ * `on`/`off` for a switch — not a normalised set, because normalising would
14662
+ * make the condition lie about devices whose states have no equivalent.
14663
+ *
14664
+ * An unreadable state does NOT match: see the engine's fail-closed gate. A
14665
+ * condition that fired on "I could not read it" would be worse than no gate.
14666
+ */
14667
+ var NcDeviceStateConditionSchema = object({
14668
+ deviceId: number().int(),
14669
+ /** Any of these matches. */
14670
+ states: array(string().min(1)).min(1)
14671
+ });
14672
+ /**
14673
+ * "This rule applies only while scene `sceneId` is `matched` / `diverged`."
14674
+ *
14675
+ * A GATE, not a trigger. `occupancy` and `audio` each DISCRIMINATE their rule —
14676
+ * carrying one makes the rule fire on that subject and nothing else. Scene is
14677
+ * the other shape entirely, the `deviceState` shape: it narrows a rule that
14678
+ * already has a trigger ("tell me about a person at the front door, but only
14679
+ * while the bin is still out"). That is why it composes with every delivery
14680
+ * instead of owning one, and why no new `NcDelivery` member and no new subject
14681
+ * kind exist for it — see D159.
14682
+ *
14683
+ * ── Identity ───────────────────────────────────────────────────────────────
14684
+ * `sceneId` is `SceneMonitor.id`, a `randomUUID()` minted by `createScene` —
14685
+ * globally unique, so it needs no device to disambiguate it. `deviceId` is
14686
+ * carried as a HINT for the editor and for the log line, never as part of the
14687
+ * lookup key: a rule whose hint drifted must still gate correctly.
14688
+ *
14689
+ * ── Which boolean ──────────────────────────────────────────────────────────
14690
+ * `latched` ABSENT means "whatever the scene itself says" — `SceneMonitor.emit`
14691
+ * already declares which boolean drives notification rules, and a second knob
14692
+ * that could disagree with it is exactly the D62 failure. Set it only to
14693
+ * override one rule against the scene's own default.
14694
+ *
14695
+ * - LIVE reading (`emit`/`latched` resolve to live): passes iff
14696
+ * `verdict === requiredState`. `unknown` — no reference for this light, view
14697
+ * shifted, no snapshot — passes NEITHER. A scene that cannot judge is not
14698
+ * evidence, in either direction.
14699
+ * - LATCHED reading: passes iff `latched === (requiredState === 'diverged')`.
14700
+ * The latch is a durable fact about the past ("it has diverged since I armed
14701
+ * it"), so a camera that has gone dark does not clear it — that is the whole
14702
+ * reason the operator asked for a latch.
14703
+ *
14704
+ * The gate reads an in-memory mirror (`NcSceneStateCache`) refreshed OFF the
14705
+ * event path, never the cap: D49. A mirror that has never loaded, or a scene it
14706
+ * does not carry, reads absent and the rule does NOT fire — fail closed, and
14707
+ * said out loud in the log rather than dropped in silence.
14708
+ */
14709
+ var NcSceneConditionSchema = object({
14710
+ /** `SceneMonitor.id` — the uuid the cap mints. The whole lookup key. */
14711
+ sceneId: string().min(1),
14712
+ /** The camera the scene lives on. A hint for the editor and the log line. */
14713
+ deviceId: number().int().optional(),
14714
+ /** The state the scene must be in for the rule to fire. */
14715
+ requiredState: _enum(["matched", "diverged"]),
14716
+ /**
14717
+ * Read the LATCH (`true`) or the LIVE verdict (`false`). Absent = follow the
14718
+ * scene's own `emit` field, which is the only place that decision belongs.
14719
+ */
14720
+ latched: boolean().optional()
14721
+ });
14389
14722
  var NcConditionsSchema = object({
14390
14723
  /** Gate on ANOTHER device's current state (the alarm armed, a switch on). */
14391
- deviceState: object({
14392
- deviceId: number().int(),
14393
- /** Any of these matches. */
14394
- states: array(string().min(1)).min(1)
14395
- }).optional(),
14724
+ deviceState: NcDeviceStateConditionSchema.optional(),
14725
+ /**
14726
+ * Gate on a SCENE's state — "only while the bin is still out". Composes with
14727
+ * every trigger (detection, occupancy, audio, sensor, package, track-end);
14728
+ * unlike `occupancy`/`audio` it discriminates nothing. See
14729
+ * {@link NcSceneCondition} and D159.
14730
+ */
14731
+ scene: NcSceneConditionSchema.optional(),
14396
14732
  /** Device scope — absent = all devices. */
14397
14733
  devices: array(number()).optional(),
14398
14734
  /** Detector class names (any overlap with the record's class set). */
@@ -14418,18 +14754,47 @@ var NcConditionsSchema = object({
14418
14754
  */
14419
14755
  labelEquals: array(string().min(1)).optional(),
14420
14756
  /**
14421
- * Identity matcher. P1 boundary: matched against the record's collapsed
14422
- * `label` (the identity display name propagated by the face pipeline) —
14423
- * identity-ID matching rides in P2 when identity ids reach the record.
14757
+ * KNOWN FACES the rule's identity scope, and the switch that says the rule
14758
+ * is about recognised people at all.
14759
+ *
14760
+ * Three states, and the empty one is the point:
14761
+ *
14762
+ * | value | meaning |
14763
+ * | --- | --- |
14764
+ * | absent | the rule does not care who it is; an unrecognised person matches |
14765
+ * | `[]` | **only known faces** — any identity in the gallery, nobody in particular |
14766
+ * | a list | only these identities |
14767
+ *
14768
+ * `[]` is the repo-wide "no selection = no narrowing" reading (an absent
14769
+ * `devices` list is every device), applied one level down: the operator has
14770
+ * turned the face scope ON and narrowed it to nothing, which is every known
14771
+ * face. No second field states the same thing — a switch that can disagree
14772
+ * with the list under it is worse than no switch (D62).
14773
+ *
14774
+ * MEMBERS ARE FACE-GALLERY `Identity.id`s (uuid), not display names. A name is
14775
+ * renameable, and a rule authored on "Gianluca" went silently dark the moment
14776
+ * the operator fixed the spelling. The id reaches the record on
14777
+ * `LabelAttribution.identityId`; the name is what the editor shows and what
14778
+ * `{{label}}` renders.
14779
+ *
14780
+ * Rules written before this carry NAMES, and are resolved to ids lazily at
14781
+ * load (`NcRuleStore.load`) against the live gallery — a name nothing answers
14782
+ * for is left as it stands and reported, never dropped. The engine also
14783
+ * accepts a display-name hit as a compatibility leg, so a rule whose
14784
+ * migration could not resolve keeps matching exactly what it matched before.
14424
14785
  */
14425
14786
  identities: array(string().min(1)).optional(),
14426
- /** Fuzzy plate matcher against the record's `label` (plate text). */
14787
+ /**
14788
+ * KNOWN PLATES / VEHICLES — the plate mirror of {@link identities}, including
14789
+ * the empty-list reading: `values: []` is "any plate the OCR could read",
14790
+ * a non-empty list is those plates (fuzzily). See {@link NcPlateMatcherSchema}.
14791
+ */
14427
14792
  plates: NcPlateMatcherSchema.optional(),
14428
14793
  /**
14429
- * Identity EXCLUDE — mirror of {@link identities} with `notIn` semantics.
14430
- * Same P1 boundary: matched against the record's collapsed `label` (the
14431
- * identity display name). A record with NO label passes (nothing to
14432
- * exclude), unlike the include variant which fails on an absent label.
14794
+ * Identity EXCLUDE — mirror of {@link identities} with `notIn` semantics, and
14795
+ * the same id members and the same lazy name→id migration. A record with NO
14796
+ * identity passes (nothing to exclude), unlike the include variant which
14797
+ * fails on an unrecognised subject. An EMPTY list excludes nobody.
14433
14798
  */
14434
14799
  identitiesExclude: array(string().min(1)).optional(),
14435
14800
  /**
@@ -14821,7 +15186,80 @@ var NcRuleInputSchema = object({
14821
15186
  * a rule that predates the gate must keep delivering byte-for-byte as it
14822
15187
  * did, and absent is the only way to say that without a migration.
14823
15188
  */
14824
- confirm: NcConfirmSchema.optional()
15189
+ confirm: NcConfirmSchema.optional(),
15190
+ /**
15191
+ * WAIT for face/plate recognition before saying anything.
15192
+ *
15193
+ * A notification's TEXT is frozen at enqueue and its media is re-resolved at
15194
+ * send; the identity is neither. A face is confirmed after `confirmFrames`
15195
+ * agreeing observations — p50 **11.4 s** after the track was first seen,
15196
+ * measured on this hub — and an `immediate` rule enqueues on the first object
15197
+ * event, seconds before that. So "Gianluca è arrivato" is unsayable on the
15198
+ * immediate path, and no amount of media re-resolution fixes a sentence.
15199
+ *
15200
+ * Only two honest answers exist, and this flag picks between them. It has
15201
+ * effect ONLY on a rule that declares a recognition scope
15202
+ * ({@link NcConditions.identities} or {@link NcConditions.plates}) — on any
15203
+ * other rule there is nothing to wait for and the flag is inert.
15204
+ *
15205
+ * | value | what happens |
15206
+ * | --- | --- |
15207
+ * | `true` | the rule stops firing on the object event and fires at TRACK CLOSE instead, once, with the name — later, and complete |
15208
+ * | absent / `false` | it fires at once WITHOUT the name, and if recognition lands before the track closes a SECOND, "…is Gianluca" notification follows (one per track, per rule, per target) |
15209
+ *
15210
+ * `.optional()` and deliberately NOT `.default()`: a Zod default does not run
15211
+ * on the addon cap path, and absent has to keep meaning exactly what every
15212
+ * rule authored before this field meant.
15213
+ *
15214
+ * The cost of `true` is stated here because the editor states it too: a rule
15215
+ * that waits also inherits track-close SEMANTICS — its `zones` condition
15216
+ * tests every zone the track visited and a `crossing` condition can no longer
15217
+ * be satisfied, because a closed track carries no crossing.
15218
+ */
15219
+ waitForEnhancement: boolean().optional(),
15220
+ /**
15221
+ * GROUP a burst of subjects into ONE notification that grows.
15222
+ *
15223
+ * Seconds of quiet after the last matching subject before the burst is
15224
+ * considered over. While it is open, the first subject enqueues immediately —
15225
+ * **exactly as today, with no added latency** — and every real growth (a new
15226
+ * subject, or a name confirmed on one already in it) REPLACES that
15227
+ * notification with an updated one naming everybody. The push carries the
15228
+ * group's own coalescing tag, so the phone replaces rather than stacks.
15229
+ *
15230
+ * `0` / absent = off, and off is today's behaviour byte for byte.
15231
+ *
15232
+ * ### Why an idle cutoff and not a window
15233
+ *
15234
+ * The measured seven-person arrival on device 590 spans 110 s with every
15235
+ * internal gap under 30 s. A 12 s fixed window cuts it into three groups; an
15236
+ * idle cutoff holds it as one and ends it when the arrival actually ends.
15237
+ * 30 is Frigate's shipped value for the same decision.
15238
+ *
15239
+ * ### What it replaces
15240
+ *
15241
+ * The blind cooldown, which collapses a burst by DISCARDING it. Measured on
15242
+ * device 615 / *Persona su Uscio* over six days: 116 qualifying tracks → 74
15243
+ * notifications, **44 (37.9%) suppressed outright**, 23 of them overlapping a
15244
+ * track that did fire and 7 carrying a confirmed identity nobody heard about.
15245
+ * A group collapses the same volume by MERGING, so the cooldown becomes a
15246
+ * budget over GROUPS — which is what it always meant — and a growth is never
15247
+ * throttled by the window its own first member spent.
15248
+ *
15249
+ * ### Interaction with {@link waitForEnhancement}
15250
+ *
15251
+ * They compose, and the order matters. `waitForEnhancement` defers the rule to
15252
+ * TRACK CLOSE, so with both set the group is opened by the first member to
15253
+ * CLOSE — already carrying its name — and grows as later members close. That
15254
+ * is later, and complete. With grouping alone the group opens on the first
15255
+ * object event and picks up names as they are confirmed, through the growth
15256
+ * path. Neither combination fires twice for one subject.
15257
+ *
15258
+ * `.optional()` and deliberately NOT `.default()`: a Zod default does not run
15259
+ * on the addon cap path, so absent must keep meaning what it meant before this
15260
+ * field existed.
15261
+ */
15262
+ groupIdleSec: number().int().min(0).max(600).optional()
14825
15263
  });
14826
15264
  /**
14827
15265
  * Partial patch for `updateRule` — any subset of the input fields, plus the
@@ -14928,6 +15366,7 @@ var NcConditionDescriptorSchema = object({
14928
15366
  "occupancy",
14929
15367
  "audio",
14930
15368
  "deviceState",
15369
+ "scene",
14931
15370
  "systemEvent"
14932
15371
  ]),
14933
15372
  operator: _enum([
@@ -15333,7 +15772,87 @@ var MethodAccessSchema = _enum([
15333
15772
  var AllowedProviderSchema = union([literal("*"), array(string())]);
15334
15773
  var AllowedDevicesSchema = record(string(), union([literal("*"), array(string())]));
15335
15774
  var CapScopeSchema = _enum(["device", "system"]);
15336
- var TokenScopeSchema = discriminatedUnion("type", [
15775
+ /**
15776
+ * DeviceSelector (scope model v3 — 2026-08-12).
15777
+ *
15778
+ * A `device` grant no longer carries a frozen list of deviceIds. It carries
15779
+ * a SELECTOR the matcher resolves against the live fleet, so the grant can be
15780
+ * DYNAMIC: a `types:['camera']` selector automatically covers a camera added
15781
+ * AFTER the grant was minted — no re-grant, no re-login.
15782
+ *
15783
+ * - `all` — every device in the deployment. The broad viewer/operator
15784
+ * lever without a `category` grant (a `category` grant also covers device
15785
+ * caps that carry no deviceId; `all` is specifically the device set).
15786
+ * - `ids` — an explicit deviceId list. This is what a v2 `device:[…]`
15787
+ * grant migrates to (see {@link TokenScopeSchema}); STATIC — a new camera
15788
+ * is NOT covered until the grant is edited.
15789
+ * - `types` — every device of a `DeviceType` (e.g. every `camera`).
15790
+ * DYNAMIC. A device that changes type, or a new device of the type,
15791
+ * re-resolves on the next request.
15792
+ * - `locations` — every device whose operator-assigned `location` label is
15793
+ * in the set (e.g. "Garden", "Front door"). DYNAMIC. A device with a
15794
+ * null/unset location matches NO `locations` selector.
15795
+ */
15796
+ var DeviceSelectorSchema = discriminatedUnion("kind", [
15797
+ object({ kind: literal("all") }),
15798
+ object({
15799
+ kind: literal("ids"),
15800
+ ids: array(number().int()).min(1)
15801
+ }),
15802
+ object({
15803
+ kind: literal("types"),
15804
+ types: array(_enum(DeviceType)).min(1)
15805
+ }),
15806
+ object({
15807
+ kind: literal("locations"),
15808
+ locations: array(string().min(1)).min(1)
15809
+ })
15810
+ ]);
15811
+ var DeviceTokenScopeSchema = object({
15812
+ type: literal("device"),
15813
+ /** The device SET this grant covers — resolved against the live fleet. */
15814
+ selector: DeviceSelectorSchema,
15815
+ access: array(MethodAccessSchema).min(1),
15816
+ /**
15817
+ * Whether a grant on a PARENT device transparently covers its accessory
15818
+ * CHILDREN (siren / floodlight / PIR) via the persisted-parentage walk.
15819
+ * Direction is parent → children ONLY.
15820
+ *
15821
+ * Absent → the matcher DERIVES it from the access flavour: `view`
15822
+ * inherits (a camera viewer sees the camera's accessories), `create` /
15823
+ * `delete` do NOT (actuating/removing a child is an explicit act the
15824
+ * operator must grant on the child, not inherit from the parent). Set it
15825
+ * explicitly to override that default per grant.
15826
+ */
15827
+ includeLinked: boolean().optional()
15828
+ });
15829
+ /**
15830
+ * v2 → v3 lazy migration. A pre-v3 `device` grant carried
15831
+ * `targets: string[]` (stringified deviceIds); it rewrites to the equivalent
15832
+ * `selector: {kind:'ids', ids}`. Applied as a `preprocess` so it runs on
15833
+ * EVERY parse path — stored records AND the JWT-carried scope arrays
15834
+ * normalised at the request boundary ({@link normalizeTokenScopes} in
15835
+ * `device-selector.ts`). Chosen over a one-time DB migration because a
15836
+ * migration cannot reach a JWT already in a client's hands; parse-time
15837
+ * migration covers both without a flag day. No cast — the raw object is read
15838
+ * through `Reflect.get` (its static type is `unknown`).
15839
+ */
15840
+ function migrateLegacyTokenScope(raw) {
15841
+ if (raw === null || typeof raw !== "object" || Array.isArray(raw)) return raw;
15842
+ if (Reflect.get(raw, "type") !== "device") return raw;
15843
+ if (Reflect.get(raw, "selector") !== void 0) return raw;
15844
+ const targets = Reflect.get(raw, "targets");
15845
+ if (!Array.isArray(targets)) return raw;
15846
+ return {
15847
+ type: "device",
15848
+ selector: {
15849
+ kind: "ids",
15850
+ ids: targets.map((t) => typeof t === "string" ? Number(t) : t).filter((n) => typeof n === "number" && Number.isInteger(n))
15851
+ },
15852
+ access: Reflect.get(raw, "access")
15853
+ };
15854
+ }
15855
+ var TokenScopeSchema = preprocess(migrateLegacyTokenScope, discriminatedUnion("type", [
15337
15856
  object({
15338
15857
  type: literal("category"),
15339
15858
  target: CapScopeSchema,
@@ -15349,18 +15868,8 @@ var TokenScopeSchema = discriminatedUnion("type", [
15349
15868
  target: string(),
15350
15869
  access: array(MethodAccessSchema).min(1)
15351
15870
  }),
15352
- object({
15353
- type: literal("device"),
15354
- /**
15355
- * One or more deviceIds (serialised as strings for wire-format
15356
- * consistency with the rest of the union). Matcher accepts if
15357
- * `input.deviceId` ∈ `targets`. Array shape avoids the row-explosion
15358
- * of one scope-per-device when granting access to a set of cameras.
15359
- */
15360
- targets: array(string()).min(1),
15361
- access: array(MethodAccessSchema).min(1)
15362
- })
15363
- ]);
15871
+ DeviceTokenScopeSchema
15872
+ ]));
15364
15873
  object({
15365
15874
  id: string(),
15366
15875
  username: string(),
@@ -15677,7 +16186,7 @@ var TrackEnvelopeSchema = object({
15677
16186
  * `snapshots[]` references — megabytes across a page of tracks. `slim`
15678
16187
  * keeps every scalar the list surfaces actually render (ids, class(es),
15679
16188
  * label / audioLabels / importance enrichment, firstSeen/lastSeen, state,
15680
- * zonesVisited, bestEventId, envelope, hasFace) and returns `positions` /
16189
+ * zonesVisited, bestEventId, envelope, hasFace, hasRider) and returns `positions` /
15681
16190
  * `snapshots` as EMPTY arrays — detail views re-fetch the full row via
15682
16191
  * `getTrack`. Mirrors the event-store `projection` convention
15683
16192
  * (`getObjectEvents` et al.).
@@ -15813,7 +16322,21 @@ union([literal(1), literal(2)]);
15813
16322
  var LabelAttributionSchema = object({
15814
16323
  stepId: string(),
15815
16324
  modelId: string().optional(),
15816
- decidedAt: number()
16325
+ decidedAt: number(),
16326
+ /**
16327
+ * The GALLERY id behind a recognised tier-2 label — a face-gallery
16328
+ * `Identity.id` or a plate-gallery `Vehicle.id` (both `randomUUID`).
16329
+ *
16330
+ * The text alone is a DISPLAY NAME, and a display name is renameable: a
16331
+ * notification rule authored on "Gianluca" stopped matching the moment the
16332
+ * operator fixed the spelling in the gallery, and nothing said so. The id is
16333
+ * the thing that does not move, so it is what a rule matches on
16334
+ * (`NcConditions.identities`) and the text is what a human is shown.
16335
+ *
16336
+ * Absent when the label names no gallery row — a plate the OCR read but no
16337
+ * vehicle claims, a sub-class, a species, any tier-1 value.
16338
+ */
16339
+ identityId: string().optional()
15817
16340
  });
15818
16341
  /**
15819
16342
  * The TIERED label model (roadmap 4g), spread into `TrackSchema` and
@@ -15950,6 +16473,28 @@ var TrackSchema = object({
15950
16473
  * `=== true` and render nothing otherwise, never infer "no face".
15951
16474
  */
15952
16475
  hasFace: boolean().optional(),
16476
+ /**
16477
+ * This subject CONTAINS a folded rider — a person the rider-pairing step
16478
+ * ([D34](../decisions/adr-0034.md)) removed from the frame BEFORE the tracker,
16479
+ * so the passage is tracked once and as a VEHICLE.
16480
+ *
16481
+ * It exists because the fold's record was dishonest. D34 and the code both
16482
+ * said "the person is not lost — it is reported so both entities stay on the
16483
+ * record"; in fact the pair went into a per-processor RAM field behind an
16484
+ * accessor nobody called, and every durable surface said `vehicle`, full
16485
+ * stop. This is the composition note that makes the row true.
16486
+ *
16487
+ * A COMPOSITION, never a class and never a label. "This vehicle contains a
16488
+ * person" is not an answer to "what is this" — both label tiers would refuse
16489
+ * a macro token anyway (D89), and correctly. Nothing here changes what the
16490
+ * subject IS: a cyclist stays one vehicle track, occupancy still counts one,
16491
+ * and a `person` rule still does not fire for someone cycling past.
16492
+ *
16493
+ * **Absent ≠ false**, exactly like {@link hasFace}: every row written before
16494
+ * the column, and every hub that predates the field, omits it. Test
16495
+ * `=== true` and render nothing otherwise — never infer "no rider".
16496
+ */
16497
+ hasRider: boolean().optional(),
15953
16498
  ...TrackFlagFields,
15954
16499
  ...TrackRetrainFields
15955
16500
  });
@@ -16299,7 +16844,10 @@ var RecentTracksQueryInput = object({
16299
16844
  * Encodes the (lastSeen, trackId) sort position — treat as opaque. */
16300
16845
  cursor: string().optional(),
16301
16846
  /** See {@link TrackProjectionSchema}. Default `full`. */
16302
- projection: TrackProjectionSchema.optional()
16847
+ projection: TrackProjectionSchema.optional(),
16848
+ /** Include stationary-promoted rows (parked objects). Default false: the
16849
+ * feed lists passages; parking records live on the stationary registry. */
16850
+ includeStationary: boolean().optional()
16303
16851
  });
16304
16852
  var RecentTracksPageSchema = object({
16305
16853
  /** Merged page, ordered by (`lastSeen` DESC, `trackId` DESC). */
@@ -16517,7 +17065,11 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
16517
17065
  zone: TrackZoneFilterSchema.optional(),
16518
17066
  /** See {@link TrackProjectionSchema}. Default `full` (backward
16519
17067
  * compatible — omitting the field keeps today's exact behaviour). */
16520
- projection: TrackProjectionSchema.optional()
17068
+ projection: TrackProjectionSchema.optional(),
17069
+ /** Include stationary-promoted rows (parked objects handed to the
17070
+ * stationary registry). Default false: the timeline lists passages,
17071
+ * not parking records (operator decision, 2026-08-15). */
17072
+ includeStationary: boolean().optional()
16521
17073
  }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(object({ deviceId: number() }), _void(), {
16522
17074
  kind: "mutation",
16523
17075
  auth: "admin"
@@ -16681,11 +17233,16 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
16681
17233
  auth: "admin"
16682
17234
  }), method(object({
16683
17235
  eventId: string(),
16684
- kind: MediaFileKindEnum.optional()
17236
+ kind: MediaFileKindEnum.optional(),
17237
+ deviceId: number()
16685
17238
  }), array(MediaFileSchema).readonly()), method(object({
16686
17239
  trackId: string(),
16687
- kinds: array(MediaFileKindEnum).optional()
16688
- }), array(MediaFileSchema).readonly()), method(object({ trackId: string() }), array(MediaFileInfoSchema).readonly()), method(SearchObjectEventsInput, array(ScoredObjectEventSchema).readonly()), method(object({}), WipeObjectEmbeddingsResultSchema, {
17240
+ kinds: array(MediaFileKindEnum).optional(),
17241
+ deviceId: number()
17242
+ }), array(MediaFileSchema).readonly()), method(object({
17243
+ trackId: string(),
17244
+ deviceId: number()
17245
+ }), array(MediaFileInfoSchema).readonly()), method(SearchObjectEventsInput, array(ScoredObjectEventSchema).readonly()), method(object({}), WipeObjectEmbeddingsResultSchema, {
16689
17246
  kind: "mutation",
16690
17247
  auth: "admin"
16691
17248
  }), method(RebuildObjectEmbeddingsInput, RebuildObjectEmbeddingsResultSchema, {
@@ -17345,6 +17902,17 @@ var maxSessionHoldMsField = {
17345
17902
  default: 12e4,
17346
17903
  step: 5e3
17347
17904
  };
17905
+ /**
17906
+ * Quiet period that closes an `audioMode: 'on-motion'` audio window. Floor of
17907
+ * 5s so a rearm can never degenerate into per-event stream churn; default 90s
17908
+ * comfortably outlives the gap between two PIR wakes on a battery camera.
17909
+ */
17910
+ var audioMotionWindowMsField = {
17911
+ min: 5e3,
17912
+ max: 6e5,
17913
+ default: 9e4,
17914
+ step: 5e3
17915
+ };
17348
17916
  var motionFpsField = {
17349
17917
  min: 1,
17350
17918
  max: 30,
@@ -17376,7 +17944,7 @@ var detectionFpsField = {
17376
17944
  var occupancyRecheckSecField = {
17377
17945
  min: 0,
17378
17946
  max: 300,
17379
- default: 30,
17947
+ default: 300,
17380
17948
  step: 5
17381
17949
  };
17382
17950
  var occupancyRecheckFramesField = {
@@ -17521,6 +18089,27 @@ var RunnerCameraConfigSchema = object({
17521
18089
  * resolved `CameraDetectionConfig`.
17522
18090
  */
17523
18091
  maxSessionHoldMs: number().min(maxSessionHoldMsField.min).max(maxSessionHoldMsField.max).optional(),
18092
+ /**
18093
+ * Orchestrator-side quiet period (ms) that closes an `audioMode:
18094
+ * 'on-motion'` audio window, measured from the LAST motion event.
18095
+ *
18096
+ * This exists because the falling edge cannot be relied on. Camera-native
18097
+ * providers emit motion as a RISING EDGE ONLY (Reolink's Baichuan push and
18098
+ * its email-push SMTP path both emit `detected: true` and never the
18099
+ * counterpart); only the frame-diff analyzer emits falls. So on an
18100
+ * onboard-only camera a window that closed only on `detected: false` never
18101
+ * closed at all, and `on-motion` silently behaved as `always-on` — on a
18102
+ * battery camera, the one failure mode the mode exists to prevent.
18103
+ *
18104
+ * Every motion event rearms this timer WITHOUT restarting the stream, so a
18105
+ * burst of re-fires costs nothing. A falling edge, when one does arrive,
18106
+ * still closes earlier via `motionCooldownMs` — whichever comes first wins.
18107
+ *
18108
+ * Not consumed by the runner: carried here so it shares the per-camera
18109
+ * device-settings surface with `motionCooldownMs`, exactly like
18110
+ * `maxSessionHoldMs`.
18111
+ */
18112
+ audioMotionWindowMs: number().min(audioMotionWindowMsField.min).max(audioMotionWindowMsField.max).optional(),
17524
18113
  motionFps: number().min(motionFpsField.min).max(motionFpsField.max).default(motionFpsField.default),
17525
18114
  detectionFps: number().min(detectionFpsField.min).max(detectionFpsField.max).default(detectionFpsField.default),
17526
18115
  motionStreamId: string(),
@@ -17616,7 +18205,7 @@ var RunnerCameraConfigSchema = object({
17616
18205
  */
17617
18206
  inferenceDevices: array(RunnerInferenceDeviceSchema).readonly().optional()
17618
18207
  });
17619
- motionFpsField.min, motionFpsField.max, motionFpsField.step, motionFpsField.default, detectionFpsField.min, detectionFpsField.max, detectionFpsField.step, detectionFpsField.default, motionCooldownMsField.min, motionCooldownMsField.max, motionCooldownMsField.step, motionCooldownMsField.default, maxSessionHoldMsField.min, maxSessionHoldMsField.max, maxSessionHoldMsField.step, maxSessionHoldMsField.default, occupancyRecheckSecField.min, occupancyRecheckSecField.max, occupancyRecheckSecField.step, occupancyRecheckSecField.default, occupancyRecheckFramesField.min, occupancyRecheckFramesField.max, occupancyRecheckFramesField.step, occupancyRecheckFramesField.default;
18208
+ motionFpsField.min, motionFpsField.max, motionFpsField.step, motionFpsField.default, detectionFpsField.min, detectionFpsField.max, detectionFpsField.step, detectionFpsField.default, motionCooldownMsField.min, motionCooldownMsField.max, motionCooldownMsField.step, motionCooldownMsField.default, maxSessionHoldMsField.min, maxSessionHoldMsField.max, maxSessionHoldMsField.step, maxSessionHoldMsField.default, audioMotionWindowMsField.min, audioMotionWindowMsField.max, audioMotionWindowMsField.step, audioMotionWindowMsField.default, occupancyRecheckSecField.min, occupancyRecheckSecField.max, occupancyRecheckSecField.step, occupancyRecheckSecField.default, occupancyRecheckFramesField.min, occupancyRecheckFramesField.max, occupancyRecheckFramesField.step, occupancyRecheckFramesField.default;
17620
18209
  /**
17621
18210
  * Runtime load summary returned by `getLocalLoad`. Used by the orchestrator's
17622
18211
  * load-balancing levels (L2 capacity-based, L3 hardware-aware) to decide
@@ -18602,7 +19191,31 @@ DeviceType.Camera, method(object({
18602
19191
  lastCapturedAt: number().nullable(),
18603
19192
  cacheAgeMs: number().nullable(),
18604
19193
  etag: string().nullable()
18605
- }))), systemMethod(object({
19194
+ }))), systemMethod(object({ deviceId: number() }), object({
19195
+ /** The battery slice as read, or null when the device has none. */
19196
+ battery: object({
19197
+ sleeping: boolean(),
19198
+ lastUpdated: number(),
19199
+ lastContactAt: number().optional()
19200
+ }).nullable(),
19201
+ /** The resolved snapshot state (what the overlay decision used). */
19202
+ state: object({
19203
+ isBattery: boolean(),
19204
+ reason: _enum([
19205
+ "disabled",
19206
+ "sleeping",
19207
+ "unreachable",
19208
+ "waking"
19209
+ ]).nullable()
19210
+ }),
19211
+ /** The cached frame behind the next paint. */
19212
+ frame: object({
19213
+ capturedAt: number().nullable(),
19214
+ ageMs: number().nullable()
19215
+ }),
19216
+ /** A wake window is currently open (the Waking overlay's source). */
19217
+ waking: boolean()
19218
+ })), systemMethod(object({
18606
19219
  /** The tiles a surface is actually rendering. One entry per (device,
18607
19220
  * width) the caller will paint — the width is snapped to the server's
18608
19221
  * ladder and becomes part of the link's SIGNED identity. */
@@ -18632,7 +19245,16 @@ targets: array(object({
18632
19245
  /** A sleeping battery camera: the frame is deliberately stale and will
18633
19246
  * NOT refresh in the background. A surface should say so rather than
18634
19247
  * present it as current. */
18635
- sleeping: boolean()
19248
+ sleeping: boolean(),
19249
+ /** Current device state rendered over the cached frame. State images
19250
+ * remain authoritative even when their photographic background is
19251
+ * old; null means the link must carry a current camera frame. */
19252
+ stateReason: _enum([
19253
+ "disabled",
19254
+ "sleeping",
19255
+ "unreachable",
19256
+ "waking"
19257
+ ]).nullable()
18636
19258
  })));
18637
19259
  /**
18638
19260
  * `sso-bridge` — internal hub-only cap that lets SSO-style auth
@@ -20154,6 +20776,25 @@ var BatteryStatusSchema = object({
20154
20776
  /** Ms epoch of the last observation. Lets consumers reason about freshness. */
20155
20777
  lastUpdated: number(),
20156
20778
  /**
20779
+ * Ms epoch of the last time the device PROVED it was reachable — a
20780
+ * completed firmware round-trip, an observed wake, or an inbound push
20781
+ * (firmware event, email). `0`/absent = never since this slice was born.
20782
+ *
20783
+ * This is the ONLY input that separates "asleep" from "gone", and it is
20784
+ * fed exclusively by PASSIVE signals: nothing may write it by reaching
20785
+ * for the radio, because a poll that confirms reachability is the same
20786
+ * poll that drains the battery. See {@link deriveBatteryPresence} — the
20787
+ * single derivation every consumer must use; no surface computes its own.
20788
+ *
20789
+ * It is deliberately NOT a clock in the
20790
+ * `scripts/check-runtime-state-durability.ts` sense: it is the
20791
+ * observation itself, and it is the only thing a 30-hour silence is
20792
+ * visible in. Writers quantise it (see `CONTACT_WRITE_QUANTUM_MS` in the
20793
+ * Reolink provider) so a value that means "recently" cannot cost a
20794
+ * SQLite commit per round-trip.
20795
+ */
20796
+ lastContactAt: number().optional(),
20797
+ /**
20157
20798
  * True when the source is a BINARY low-battery indicator (HA
20158
20799
  * `binary_sensor` device_class=battery / `LOW_BAT`) that has no real
20159
20800
  * charge level — `percentage` is then a coarse stand-in (100 = normal,
@@ -23691,7 +24332,7 @@ method(object({
23691
24332
  toMs: number()
23692
24333
  }), RecordingAvailabilitySchema, {
23693
24334
  kind: "query",
23694
- auth: "admin"
24335
+ auth: "protected"
23695
24336
  }), method(object({
23696
24337
  deviceId: number(),
23697
24338
  fromMs: number(),
@@ -23699,14 +24340,14 @@ method(object({
23699
24340
  tzOffsetMinutes: number()
23700
24341
  }), RecordingDaysSchema, {
23701
24342
  kind: "query",
23702
- auth: "admin"
24343
+ auth: "protected"
23703
24344
  }), method(object({
23704
24345
  deviceId: number(),
23705
24346
  fromMs: number(),
23706
24347
  toMs: number()
23707
24348
  }), RecordingManifestSchema, {
23708
24349
  kind: "query",
23709
- auth: "admin"
24350
+ auth: "protected"
23710
24351
  }), method(object({}), RecordingStorageUsageSchema, {
23711
24352
  kind: "query",
23712
24353
  auth: "admin"
@@ -23996,14 +24637,77 @@ method(object({
23996
24637
  * thing except the comparator: `similarity` (CLIP cosine at the same ROI coords
23997
24638
  * vs condition-tagged references) and `llm` (vision-LLM judgment over the crop).
23998
24639
  *
23999
- * D14 device-config archetype (`deviceConfig.ui.kind:'widget'`) the framework
24000
- * derives the device-detail contribution; the provider carries NO hand-written
24001
- * settings-contribution methods. `status.kind:'push'` the engine pushes on
24002
- * every hysteresis flip / availability change; consumers never poll.
24003
- */
24004
- /** Extensible condition tag. Seeded 'day' | 'night'; open by design so more can
24005
- * be added without a wire break (matching falls back to any-condition refs). */
24640
+ * **No `deviceConfig`, deliberately.** This shipped as the D14 widget archetype,
24641
+ * which put a "Scenes" tab on one camera's detail page. That is the wrong shape
24642
+ * for the thing: a scene is a standing question about the property ("is the bin
24643
+ * still out"), and the operator's question is "which of my scenes have tripped",
24644
+ * across every camera at once — not "what does camera 617 think". Buried one
24645
+ * camera deep it also could not be found. The surface is now a top-level admin
24646
+ * page (`/scenes`, `pages/Scenes.tsx`) that lists every scene on every camera and
24647
+ * picks the camera inside the create flow, the same shape Events and Faces have.
24648
+ *
24649
+ * The consequence to keep in mind: `host/scene-monitor-editor` is gone from
24650
+ * `HOST_WIDGETS` too. `scripts/check-host-widget-resolves.ts` asserts BOTH
24651
+ * directions, so a registration nobody declares fails exactly as loudly as a
24652
+ * declaration nobody registers. The editor is imported directly by the page.
24653
+ *
24654
+ * `status.kind:'push'` — the engine pushes on every hysteresis flip /
24655
+ * availability change; consumers never poll.
24656
+ */
24657
+ /** Extensible condition tag. Seeded 'day' | 'ir' (the two variants the operator
24658
+ * captures) plus 'night' | 'dawn' | 'dusk' from the resolver's sun-times band.
24659
+ * Open by design so more can be added without a wire break.
24660
+ *
24661
+ * Matching does NOT fall back across conditions: cross-condition cosines are
24662
+ * not comparable, so "I have never seen this scene in this light" is reported
24663
+ * as `unknown`, never guessed. A day reference scored against an IR frame
24664
+ * collapses the cosine and would latch a false alarm every single night. */
24006
24665
  var SceneConditionSchema = string();
24666
+ /**
24667
+ * What a scene does when the CURRENT light has no reference of its own.
24668
+ *
24669
+ * The lighting variants are not equally likely to exist. Almost every operator
24670
+ * captures daylight and then never stands outside at 22:00 to capture IR, and a
24671
+ * scene that is only ever going to be asked about a daytime question ("is the
24672
+ * bin still on the kerb at 08:00") does not need a night reference at all. The
24673
+ * night half must therefore be OPTIONAL, and optional means the scene keeps
24674
+ * working without it rather than degrading into a permanent complaint.
24675
+ *
24676
+ * - `skip` (default) — the check in that light is not made. Not a verdict, not
24677
+ * an alarm, not even an `unknown`: the live state simply stays whatever the
24678
+ * last covered light left it at, the latch is untouched, and the hysteresis
24679
+ * run is neither spent nor cleared. The scene resumes by itself at first
24680
+ * light. This is the only behaviour under which "I never captured IR" is a
24681
+ * configuration choice instead of a nightly fault.
24682
+ * - `judge-anyway` — score against the OTHER conditions' references. Available
24683
+ * for cameras whose IR frame is close enough to daylight (a floodlit
24684
+ * driveway, an always-white-light doorbell), and wrong for everything else:
24685
+ * cross-condition cosines are not comparable, so a day reference against a
24686
+ * true IR frame collapses and the scene reports a theft at 21:40.
24687
+ *
24688
+ * Never applies when the scene has NO comparable reference at all — that is
24689
+ * "not armed yet", it is reported as `no-reference-for-condition`, and silence
24690
+ * there would hide a scene the operator never finished setting up.
24691
+ */
24692
+ var SceneUncoveredPolicySchema = _enum(["skip", "judge-anyway"]);
24693
+ /** `matched` = the baseline is what we see; `diverged` = it demonstrably is not;
24694
+ * `unknown` = we cannot judge (no reference for this condition, encoder model
24695
+ * changed, view shifted, no snapshot). `unknown` is a real value, not a null,
24696
+ * and never counts toward hysteresis in either direction. */
24697
+ var SceneVerdictSchema = _enum([
24698
+ "matched",
24699
+ "diverged",
24700
+ "unknown"
24701
+ ]);
24702
+ /** Why a scene cannot judge. Named, because this feature's failure mode is
24703
+ * silence that reads as "nothing has happened". */
24704
+ var SceneUnavailableSchema = _enum([
24705
+ "no-reference-for-condition",
24706
+ "view-shifted",
24707
+ "no-vision-profile",
24708
+ "encoder-model-changed",
24709
+ "no-snapshot"
24710
+ ]);
24007
24711
  /** One captured reference — condition-tagged, model-version-gated. `embedding`
24008
24712
  * is `number[]` (Float32Array does NOT survive MsgPack/UDS). */
24009
24713
  var SceneReferenceSchema = object({
@@ -24011,7 +24715,14 @@ var SceneReferenceSchema = object({
24011
24715
  modelId: string(),
24012
24716
  condition: SceneConditionSchema,
24013
24717
  capturedAt: number(),
24014
- thumbnailMediaId: string().optional()
24718
+ thumbnailMediaId: string().optional(),
24719
+ /** Whole-frame (downscaled) embedding captured alongside the ROI crop. The
24720
+ * anti-view-shift anchor: a bumped camera, a PTZ preset or a re-aim makes the
24721
+ * normalized rect frame a different piece of world, and the scene would
24722
+ * diverge forever with a perfectly plausible cosine. Checked LAZILY, only
24723
+ * when hysteresis is about to flip — one extra encode per candidate
24724
+ * transition, not per poll. */
24725
+ anchorEmbedding: array(number()).optional()
24015
24726
  });
24016
24727
  var SceneMonitorStateSchema = object({
24017
24728
  id: string(),
@@ -24033,6 +24744,28 @@ var SceneCheckSchema = discriminatedUnion("mode", [object({
24033
24744
  profileId: string().optional(),
24034
24745
  hysteresisCount: number().int().positive()
24035
24746
  })]);
24747
+ var SCENE_DEFAULT_ANCHOR_THRESHOLD = .85;
24748
+ /** Night is OPTIONAL. A scene with only a daylight reference sits the IR hours
24749
+ * out in silence rather than reporting a fault every night. */
24750
+ var SCENE_DEFAULT_UNCOVERED_POLICY = "skip";
24751
+ /**
24752
+ * Vision-model adjudication of a candidate flip. Field names deliberately
24753
+ * mirror `NcConfirmSchema` so an operator meets one vocabulary, not two.
24754
+ *
24755
+ * `onTimeout` defaults to **'hold'**, the OPPOSITE of `NcConfirmGate`'s
24756
+ * fail-open: a notification suppressed is the worse error there, but a vision
24757
+ * model that timed out has not told us the bin is gone, and a latch is a
24758
+ * stateful claim that costs the operator a trip to reset.
24759
+ */
24760
+ var SceneConfirmSchema = object({
24761
+ enabled: boolean().default(false),
24762
+ prompt: string().min(1).max(1e3),
24763
+ profileId: string().optional(),
24764
+ timeoutMs: number().int().min(1e3).max(2e4).default(8e3),
24765
+ maxImagePx: number().int().min(64).max(2048).default(448),
24766
+ /** What a timeout / unavailable model means for the PENDING flip. */
24767
+ onTimeout: _enum(["flip", "hold"]).default("hold")
24768
+ });
24036
24769
  var SceneMonitorSchema = object({
24037
24770
  id: string(),
24038
24771
  label: string(),
@@ -24051,7 +24784,56 @@ var SceneMonitorSchema = object({
24051
24784
  lastConfidence: number().nullable(),
24052
24785
  currentCondition: SceneConditionSchema.nullable(),
24053
24786
  availability: _enum(["ok", "unavailable"]),
24054
- unavailableReason: string().nullable()
24787
+ unavailableReason: string().nullable(),
24788
+ /** Which state is "the initial screen". `null` until the first capture. */
24789
+ baselineStateId: string().nullable(),
24790
+ /** Which boolean drives notification rules and any export. */
24791
+ emit: _enum(["latched", "live"]).default("latched"),
24792
+ /** Live: does the region match the baseline RIGHT NOW. */
24793
+ verdict: SceneVerdictSchema,
24794
+ /** Has it been `diverged` at least once since `armedAt` — the operator's boolean. */
24795
+ latched: boolean(),
24796
+ /** Last reset (or creation). */
24797
+ armedAt: number(),
24798
+ divergedAt: number().nullable(),
24799
+ restoredAt: number().nullable(),
24800
+ /** A check is only COUNTED when the device has been quiet this long. Motion
24801
+ * during the window DISCARDS the observation — a car pulling up in front of
24802
+ * the bin must not be able to spend hysteresis credit. */
24803
+ quietSeconds: number().int().min(0).max(3600).default(60),
24804
+ /** An observation only advances the pending count when it is at least this
24805
+ * far from the previously counted one, so N agreeing checks span real time
24806
+ * rather than N adjacent polls inside one occlusion. */
24807
+ minObservationSpacingSec: number().int().min(0).max(3600).default(120),
24808
+ /** Vision-model adjudication of a candidate flip. Similarity primary only. */
24809
+ confirm: SceneConfirmSchema.optional(),
24810
+ /** Whole-frame anchor cosine below which a flip is REFUSED as `view-shifted`. */
24811
+ anchorThreshold: number().min(0).max(1).default(SCENE_DEFAULT_ANCHOR_THRESHOLD),
24812
+ /** Clear the latch on its own when the scene matches again? Default false —
24813
+ * `restoredAt` and the `scene-restored` edge are recorded regardless, so an
24814
+ * automation can react to the bin coming back without the operator's own
24815
+ * alarm silently clearing itself. */
24816
+ autoRestore: boolean().default(false),
24817
+ /** What to do when the current light has no reference of its own. See
24818
+ * {@link SceneUncoveredPolicySchema} — the default makes night OPTIONAL. */
24819
+ onUncoveredCondition: SceneUncoveredPolicySchema.default(SCENE_DEFAULT_UNCOVERED_POLICY),
24820
+ /**
24821
+ * The light whose checks are currently being SAT OUT under
24822
+ * `onUncoveredCondition: 'skip'` — `null` when the scene is checking normally.
24823
+ *
24824
+ * Engine-reported and advisory only: it moves no verdict, no latch and no
24825
+ * hysteresis. It exists so the card can say *"night (IR) — checks paused,
24826
+ * nothing captured in this light"* in the same calm voice as the coverage
24827
+ * line, because the alternative is a scene that silently stops answering
24828
+ * after sunset with nothing anywhere saying why. A skipped check must never
24829
+ * read as a broken one.
24830
+ */
24831
+ suspendedCondition: SceneConditionSchema.nullable().default(null),
24832
+ /** Named cause when `verdict === 'unknown'`. */
24833
+ unavailable: SceneUnavailableSchema.nullable(),
24834
+ /** Conditions that have at least one comparable reference — the coverage line
24835
+ * ("day ✓ · ir ✓ · dusk ✗") that turns a silent fallback into a visible fact. */
24836
+ coveredConditions: array(SceneConditionSchema)
24055
24837
  });
24056
24838
  var SceneMonitorStatusSchema = object({
24057
24839
  monitors: array(SceneMonitorSchema),
@@ -24084,7 +24866,15 @@ DeviceType.Camera, method(object({ deviceId: number() }), SceneMonitorStatusSche
24084
24866
  "both"
24085
24867
  ]).optional(),
24086
24868
  checkIntervalSec: number().optional(),
24087
- check: SceneCheckSchema.optional()
24869
+ check: SceneCheckSchema.optional(),
24870
+ emit: _enum(["latched", "live"]).optional(),
24871
+ quietSeconds: number().int().min(0).max(3600).optional(),
24872
+ minObservationSpacingSec: number().int().min(0).max(3600).optional(),
24873
+ anchorThreshold: number().min(0).max(1).optional(),
24874
+ autoRestore: boolean().optional(),
24875
+ onUncoveredCondition: SceneUncoveredPolicySchema.optional(),
24876
+ /** `null` clears the vision-model adjudicator. */
24877
+ confirm: SceneConfirmSchema.nullable().optional()
24088
24878
  })
24089
24879
  }), _void(), {
24090
24880
  kind: "mutation",
@@ -24121,6 +24911,14 @@ DeviceType.Camera, method(object({ deviceId: number() }), SceneMonitorStatusSche
24121
24911
  }), _void(), {
24122
24912
  kind: "mutation",
24123
24913
  auth: "admin"
24914
+ }), method(object({
24915
+ deviceId: number(),
24916
+ monitorId: string(),
24917
+ /** Defaults to TRUE at the provider seam — see `SCENE_RESET_RECAPTURES`. */
24918
+ recapture: boolean().optional()
24919
+ }), _void(), {
24920
+ kind: "mutation",
24921
+ auth: "admin"
24124
24922
  });
24125
24923
  /**
24126
24924
  * Per-stage gating mode applied to the zones a rule references.
@@ -24274,6 +25072,16 @@ var CamStreamDescriptorSchema = object({
24274
25072
  /** Transport-specific opaque metadata (e.g. rfc4571 SDP). */
24275
25073
  metadata: record(string(), unknown()).optional()
24276
25074
  });
25075
+ object({
25076
+ /** The descriptors as last built from a real camera response. Never a guess:
25077
+ * a failed or refused build writes NOTHING, so a restored catalog is always
25078
+ * one the camera itself once produced. */
25079
+ descriptors: array(CamStreamDescriptorSchema),
25080
+ /** Ms epoch of the build that produced {@link descriptors}. Lets the wake
25081
+ * path decide whether the camera's own awake window is worth spending on a
25082
+ * re-read. */
25083
+ lastFetchedAt: number()
25084
+ });
24277
25085
  DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), array(CamStreamDescriptorSchema).readonly());
24278
25086
  /** One of the camera's stream profiles. */
24279
25087
  var StreamProfileSchema = _enum([
@@ -24429,12 +25237,64 @@ var NetworkAddressSchema = object({
24429
25237
  family: string(),
24430
25238
  internal: boolean()
24431
25239
  });
25240
+ /**
25241
+ * Provenance of the site coordinates, and the whole reason this is not just two
25242
+ * numbers.
25243
+ *
25244
+ * - `operator-set` — a human typed it, or accepted a detection. Authoritative;
25245
+ * nothing overwrites it.
25246
+ * - `derived-from-ip` — the hub geolocated its own public IP once, because a
25247
+ * default that is right to a few kilometres beats the coarse UTC clock split
25248
+ * the sun-times consumers otherwise fall back to.
25249
+ *
25250
+ * The UI shows which one it is. An operator who cannot tell a guess from their
25251
+ * own input will eventually trust the guess.
25252
+ */
25253
+ var SiteLocationSourceSchema = _enum(["operator-set", "derived-from-ip"]);
25254
+ /**
25255
+ * The read shape: the location plus the honest state of the one-shot derivation.
25256
+ *
25257
+ * `derivationAttemptedAt` is what makes the "one call, ever" contract
25258
+ * inspectable. When it is set and `location` is null, the geo-IP lookup ran and
25259
+ * failed; the hub will NOT try again on its own — the fallback is declared
25260
+ * (consumers degrade to their own last resort) and the operator either types the
25261
+ * coordinates or presses detect.
25262
+ */
25263
+ var SiteLocationStatusSchema = object({
25264
+ location: object({
25265
+ /** WGS84 decimal degrees. */
25266
+ latitude: number().min(-90).max(90),
25267
+ longitude: number().min(-180).max(180),
25268
+ source: SiteLocationSourceSchema,
25269
+ /** Epoch ms the value was last written. */
25270
+ updatedAt: number(),
25271
+ /**
25272
+ * Human-readable place the geo-IP service reported ("Napoli, IT"). Display
25273
+ * only — never parsed, never matched on. Absent for an operator-typed value.
25274
+ */
25275
+ label: string().optional()
25276
+ }).nullable(),
25277
+ derivationAttemptedAt: number().nullable(),
25278
+ /** Why the last derivation failed, for the UI to show instead of a shrug. */
25279
+ derivationError: string().nullable()
25280
+ });
25281
+ /** `null` clears the location and re-arms nothing — the derivation stays spent. */
25282
+ var SetSiteLocationInputSchema = object({
25283
+ latitude: number().min(-90).max(90),
25284
+ longitude: number().min(-180).max(180)
25285
+ }).nullable();
24432
25286
  method(_void(), FeatureManifestSchema), method(_void(), HealthStatusSchema), method(_void(), FeatureManifestSchema), method(_void(), array(NetworkAddressSchema).readonly()), method(_void(), unknown().nullable(), { auth: "admin" }), method(record(string(), unknown()), _null(), {
24433
25287
  kind: "mutation",
24434
25288
  auth: "admin"
24435
25289
  }), method(_void(), _void(), {
24436
25290
  kind: "mutation",
24437
25291
  auth: "admin"
25292
+ }), method(_void(), SiteLocationStatusSchema), method(SetSiteLocationInputSchema, SiteLocationStatusSchema, {
25293
+ kind: "mutation",
25294
+ auth: "admin"
25295
+ }), method(_void(), SiteLocationStatusSchema, {
25296
+ kind: "mutation",
25297
+ auth: "admin"
24438
25298
  });
24439
25299
  object({
24440
25300
  /** True when the device's tamper switch / case-open contact is
@@ -27164,6 +28024,12 @@ Object.freeze({
27164
28024
  addonId: null,
27165
28025
  access: "create"
27166
28026
  },
28027
+ "llm.cancel": {
28028
+ capName: "llm",
28029
+ capScope: "system",
28030
+ addonId: null,
28031
+ access: "create"
28032
+ },
27167
28033
  "llm.deleteModel": {
27168
28034
  capName: "llm",
27169
28035
  capScope: "system",
@@ -27248,6 +28114,12 @@ Object.freeze({
27248
28114
  addonId: null,
27249
28115
  access: "view"
27250
28116
  },
28117
+ "llm.resolveModelRef": {
28118
+ capName: "llm",
28119
+ capScope: "system",
28120
+ addonId: null,
28121
+ access: "create"
28122
+ },
27251
28123
  "llm.setDefault": {
27252
28124
  capName: "llm",
27253
28125
  capScope: "system",
@@ -29414,6 +30286,12 @@ Object.freeze({
29414
30286
  addonId: null,
29415
30287
  access: "create"
29416
30288
  },
30289
+ "sceneMonitor.resetScene": {
30290
+ capName: "scene-monitor",
30291
+ capScope: "device",
30292
+ addonId: null,
30293
+ access: "delete"
30294
+ },
29417
30295
  "sceneMonitor.updateScene": {
29418
30296
  capName: "scene-monitor",
29419
30297
  capScope: "device",
@@ -29552,6 +30430,12 @@ Object.freeze({
29552
30430
  addonId: null,
29553
30431
  access: "view"
29554
30432
  },
30433
+ "snapshot.getDebugState": {
30434
+ capName: "snapshot",
30435
+ capScope: "device",
30436
+ addonId: null,
30437
+ access: "view"
30438
+ },
29555
30439
  "snapshot.getSnapshot": {
29556
30440
  capName: "snapshot",
29557
30441
  capScope: "device",
@@ -30092,6 +30976,12 @@ Object.freeze({
30092
30976
  addonId: null,
30093
30977
  access: "create"
30094
30978
  },
30979
+ "system.detectSiteLocation": {
30980
+ capName: "system",
30981
+ capScope: "system",
30982
+ addonId: null,
30983
+ access: "create"
30984
+ },
30095
30985
  "system.featureFlags": {
30096
30986
  capName: "system",
30097
30987
  capScope: "system",
@@ -30110,6 +31000,12 @@ Object.freeze({
30110
31000
  addonId: null,
30111
31001
  access: "view"
30112
31002
  },
31003
+ "system.getSiteLocation": {
31004
+ capName: "system",
31005
+ capScope: "system",
31006
+ addonId: null,
31007
+ access: "view"
31008
+ },
30113
31009
  "system.health": {
30114
31010
  capName: "system",
30115
31011
  capScope: "system",
@@ -30134,6 +31030,12 @@ Object.freeze({
30134
31030
  addonId: null,
30135
31031
  access: "create"
30136
31032
  },
31033
+ "system.setSiteLocation": {
31034
+ capName: "system",
31035
+ capScope: "system",
31036
+ addonId: null,
31037
+ access: "create"
31038
+ },
30137
31039
  "terminalSession.adoptLegacyMonitor": {
30138
31040
  capName: "terminal-session",
30139
31041
  capScope: "system",
@@ -30705,6 +31607,1709 @@ Object.freeze({
30705
31607
  access: "create"
30706
31608
  }
30707
31609
  });
31610
+ Object.freeze({
31611
+ "accessories.setChildHidden": [{
31612
+ name: "childDeviceId",
31613
+ form: "single",
31614
+ optional: false
31615
+ }, {
31616
+ name: "deviceId",
31617
+ form: "single",
31618
+ optional: false
31619
+ }],
31620
+ "addonSettings.getDeviceSettings": [{
31621
+ name: "deviceId",
31622
+ form: "single",
31623
+ optional: false
31624
+ }],
31625
+ "addonSettings.updateDeviceSettings": [{
31626
+ name: "deviceId",
31627
+ form: "single",
31628
+ optional: false
31629
+ }],
31630
+ "alarmPanel.arm": [{
31631
+ name: "deviceId",
31632
+ form: "single",
31633
+ optional: false
31634
+ }],
31635
+ "alarmPanel.disarm": [{
31636
+ name: "deviceId",
31637
+ form: "single",
31638
+ optional: false
31639
+ }],
31640
+ "alarmPanel.trigger": [{
31641
+ name: "deviceId",
31642
+ form: "single",
31643
+ optional: false
31644
+ }],
31645
+ "audioAnalysis.resolveDeviceSettings": [{
31646
+ name: "deviceId",
31647
+ form: "single",
31648
+ optional: false
31649
+ }],
31650
+ "audioAnalyzer.classify": [{
31651
+ name: "deviceId",
31652
+ form: "single",
31653
+ optional: true
31654
+ }],
31655
+ "audioMetrics.getCurrentSnapshot": [{
31656
+ name: "deviceId",
31657
+ form: "single",
31658
+ optional: false
31659
+ }],
31660
+ "audioMetrics.getHistory": [{
31661
+ name: "deviceId",
31662
+ form: "single",
31663
+ optional: false
31664
+ }],
31665
+ "automationControl.disable": [{
31666
+ name: "deviceId",
31667
+ form: "single",
31668
+ optional: false
31669
+ }],
31670
+ "automationControl.enable": [{
31671
+ name: "deviceId",
31672
+ form: "single",
31673
+ optional: false
31674
+ }],
31675
+ "automationControl.trigger": [{
31676
+ name: "deviceId",
31677
+ form: "single",
31678
+ optional: false
31679
+ }],
31680
+ "battery.wakeForStream": [{
31681
+ name: "deviceId",
31682
+ form: "single",
31683
+ optional: false
31684
+ }],
31685
+ "brightness.setBrightness": [{
31686
+ name: "deviceId",
31687
+ form: "single",
31688
+ optional: false
31689
+ }],
31690
+ "button.press": [{
31691
+ name: "deviceId",
31692
+ form: "single",
31693
+ optional: false
31694
+ }],
31695
+ "cameraCredentials.getCredentials": [{
31696
+ name: "deviceId",
31697
+ form: "single",
31698
+ optional: false
31699
+ }],
31700
+ "cameraStreams.getBrokerStreams": [{
31701
+ name: "deviceId",
31702
+ form: "single",
31703
+ optional: false
31704
+ }],
31705
+ "cameraStreams.getCameraStreams": [{
31706
+ name: "deviceId",
31707
+ form: "single",
31708
+ optional: false
31709
+ }],
31710
+ "cameraStreams.getProfileRtspEntries": [{
31711
+ name: "deviceId",
31712
+ form: "single",
31713
+ optional: false
31714
+ }],
31715
+ "cameraStreams.getRtspEntries": [{
31716
+ name: "deviceId",
31717
+ form: "single",
31718
+ optional: false
31719
+ }],
31720
+ "cameraStreams.pickStream": [{
31721
+ name: "deviceId",
31722
+ form: "single",
31723
+ optional: false
31724
+ }],
31725
+ "climateControl.setFanMode": [{
31726
+ name: "deviceId",
31727
+ form: "single",
31728
+ optional: false
31729
+ }],
31730
+ "climateControl.setMode": [{
31731
+ name: "deviceId",
31732
+ form: "single",
31733
+ optional: false
31734
+ }],
31735
+ "climateControl.setPreset": [{
31736
+ name: "deviceId",
31737
+ form: "single",
31738
+ optional: false
31739
+ }],
31740
+ "climateControl.setSwingHorizontal": [{
31741
+ name: "deviceId",
31742
+ form: "single",
31743
+ optional: false
31744
+ }],
31745
+ "climateControl.setSwingVertical": [{
31746
+ name: "deviceId",
31747
+ form: "single",
31748
+ optional: false
31749
+ }],
31750
+ "climateControl.setTarget": [{
31751
+ name: "deviceId",
31752
+ form: "single",
31753
+ optional: false
31754
+ }],
31755
+ "climateControl.setTargetHumidity": [{
31756
+ name: "deviceId",
31757
+ form: "single",
31758
+ optional: false
31759
+ }],
31760
+ "climateControl.setTargetRange": [{
31761
+ name: "deviceId",
31762
+ form: "single",
31763
+ optional: false
31764
+ }],
31765
+ "color.setColor": [{
31766
+ name: "deviceId",
31767
+ form: "single",
31768
+ optional: false
31769
+ }],
31770
+ "consumables.reset": [{
31771
+ name: "deviceId",
31772
+ form: "single",
31773
+ optional: false
31774
+ }],
31775
+ "control.setValue": [{
31776
+ name: "deviceId",
31777
+ form: "single",
31778
+ optional: false
31779
+ }],
31780
+ "cover.close": [{
31781
+ name: "deviceId",
31782
+ form: "single",
31783
+ optional: false
31784
+ }],
31785
+ "cover.open": [{
31786
+ name: "deviceId",
31787
+ form: "single",
31788
+ optional: false
31789
+ }],
31790
+ "cover.setPosition": [{
31791
+ name: "deviceId",
31792
+ form: "single",
31793
+ optional: false
31794
+ }],
31795
+ "cover.setTiltPosition": [{
31796
+ name: "deviceId",
31797
+ form: "single",
31798
+ optional: false
31799
+ }],
31800
+ "cover.stop": [{
31801
+ name: "deviceId",
31802
+ form: "single",
31803
+ optional: false
31804
+ }],
31805
+ "dayNight.getOptions": [{
31806
+ name: "deviceId",
31807
+ form: "single",
31808
+ optional: false
31809
+ }],
31810
+ "dayNight.setSettings": [{
31811
+ name: "deviceId",
31812
+ form: "single",
31813
+ optional: false
31814
+ }],
31815
+ "decoder.createSession": [{
31816
+ name: "deviceId",
31817
+ form: "single",
31818
+ optional: true
31819
+ }],
31820
+ "deviceAdoption.release": [{
31821
+ name: "camDeviceId",
31822
+ form: "single",
31823
+ optional: false
31824
+ }],
31825
+ "deviceAdoption.resync": [{
31826
+ name: "camDeviceId",
31827
+ form: "single",
31828
+ optional: false
31829
+ }],
31830
+ "deviceDiscovery.adoptDevice": [{
31831
+ name: "deviceId",
31832
+ form: "single",
31833
+ optional: false
31834
+ }],
31835
+ "deviceDiscovery.listDiscovered": [{
31836
+ name: "deviceId",
31837
+ form: "single",
31838
+ optional: false
31839
+ }],
31840
+ "deviceDiscovery.refreshDiscovery": [{
31841
+ name: "deviceId",
31842
+ form: "single",
31843
+ optional: false
31844
+ }],
31845
+ "deviceDiscovery.releaseDevice": [{
31846
+ name: "childDeviceId",
31847
+ form: "single",
31848
+ optional: false
31849
+ }, {
31850
+ name: "deviceId",
31851
+ form: "single",
31852
+ optional: false
31853
+ }],
31854
+ "deviceManager.adoptionRelease": [{
31855
+ name: "camDeviceId",
31856
+ form: "single",
31857
+ optional: false
31858
+ }],
31859
+ "deviceManager.adoptionResync": [{
31860
+ name: "camDeviceId",
31861
+ form: "single",
31862
+ optional: false
31863
+ }],
31864
+ "deviceManager.applyInitialMeta": [{
31865
+ name: "deviceId",
31866
+ form: "single",
31867
+ optional: false
31868
+ }, {
31869
+ name: "linkDeviceId",
31870
+ form: "single",
31871
+ optional: true
31872
+ }],
31873
+ "deviceManager.disable": [{
31874
+ name: "deviceId",
31875
+ form: "single",
31876
+ optional: false
31877
+ }],
31878
+ "deviceManager.enable": [{
31879
+ name: "deviceId",
31880
+ form: "single",
31881
+ optional: false
31882
+ }],
31883
+ "deviceManager.getBindings": [{
31884
+ name: "deviceId",
31885
+ form: "single",
31886
+ optional: false
31887
+ }],
31888
+ "deviceManager.getChildren": [{
31889
+ name: "parentDeviceId",
31890
+ form: "single",
31891
+ optional: false
31892
+ }],
31893
+ "deviceManager.getConfigSchema": [{
31894
+ name: "deviceId",
31895
+ form: "single",
31896
+ optional: false
31897
+ }],
31898
+ "deviceManager.getDevice": [{
31899
+ name: "deviceId",
31900
+ form: "single",
31901
+ optional: false
31902
+ }],
31903
+ "deviceManager.getDeviceAggregate": [{
31904
+ name: "deviceId",
31905
+ form: "single",
31906
+ optional: false
31907
+ }],
31908
+ "deviceManager.getDeviceLiveInfoAggregate": [{
31909
+ name: "deviceId",
31910
+ form: "single",
31911
+ optional: false
31912
+ }],
31913
+ "deviceManager.getDeviceSettingsAggregate": [{
31914
+ name: "deviceId",
31915
+ form: "single",
31916
+ optional: false
31917
+ }],
31918
+ "deviceManager.getDeviceStatusAggregate": [{
31919
+ name: "deviceId",
31920
+ form: "single",
31921
+ optional: false
31922
+ }],
31923
+ "deviceManager.getDeviceStatusAggregateBatch": [{
31924
+ name: "deviceIds",
31925
+ form: "array",
31926
+ optional: false
31927
+ }],
31928
+ "deviceManager.getLinkedDevices": [{
31929
+ name: "deviceId",
31930
+ form: "single",
31931
+ optional: false
31932
+ }],
31933
+ "deviceManager.getSettingsSchema": [{
31934
+ name: "deviceId",
31935
+ form: "single",
31936
+ optional: false
31937
+ }],
31938
+ "deviceManager.getStreamProfileMap": [{
31939
+ name: "deviceId",
31940
+ form: "single",
31941
+ optional: false
31942
+ }],
31943
+ "deviceManager.getStreamSources": [{
31944
+ name: "deviceId",
31945
+ form: "single",
31946
+ optional: false
31947
+ }],
31948
+ "deviceManager.getWireableFields": [{
31949
+ name: "deviceId",
31950
+ form: "single",
31951
+ optional: false
31952
+ }],
31953
+ "deviceManager.loadConfig": [{
31954
+ name: "deviceId",
31955
+ form: "single",
31956
+ optional: false
31957
+ }],
31958
+ "deviceManager.loadMeta": [{
31959
+ name: "deviceId",
31960
+ form: "single",
31961
+ optional: false
31962
+ }],
31963
+ "deviceManager.loadRuntimeState": [{
31964
+ name: "deviceId",
31965
+ form: "single",
31966
+ optional: false
31967
+ }],
31968
+ "deviceManager.persistConfig": [{
31969
+ name: "deviceId",
31970
+ form: "single",
31971
+ optional: false
31972
+ }],
31973
+ "deviceManager.probeStreams": [{
31974
+ name: "deviceId",
31975
+ form: "single",
31976
+ optional: false
31977
+ }],
31978
+ "deviceManager.registerDevice": [{
31979
+ name: "parentDeviceId",
31980
+ form: "single",
31981
+ optional: true
31982
+ }],
31983
+ "deviceManager.remove": [{
31984
+ name: "deviceId",
31985
+ form: "single",
31986
+ optional: false
31987
+ }],
31988
+ "deviceManager.removeDevice": [{
31989
+ name: "deviceId",
31990
+ form: "single",
31991
+ optional: false
31992
+ }],
31993
+ "deviceManager.runDeviceAction": [{
31994
+ name: "deviceId",
31995
+ form: "single",
31996
+ optional: false
31997
+ }],
31998
+ "deviceManager.setChildLayout": [{
31999
+ name: "deviceId",
32000
+ form: "single",
32001
+ optional: false
32002
+ }],
32003
+ "deviceManager.setDisabled": [{
32004
+ name: "deviceId",
32005
+ form: "single",
32006
+ optional: false
32007
+ }],
32008
+ "deviceManager.setDisplay": [{
32009
+ name: "deviceId",
32010
+ form: "single",
32011
+ optional: false
32012
+ }],
32013
+ "deviceManager.setIntegrationId": [{
32014
+ name: "deviceId",
32015
+ form: "single",
32016
+ optional: false
32017
+ }],
32018
+ "deviceManager.setLinkDeviceId": [{
32019
+ name: "deviceId",
32020
+ form: "single",
32021
+ optional: false
32022
+ }, {
32023
+ name: "linkDeviceId",
32024
+ form: "single",
32025
+ optional: true
32026
+ }],
32027
+ "deviceManager.setLocation": [{
32028
+ name: "deviceId",
32029
+ form: "single",
32030
+ optional: false
32031
+ }],
32032
+ "deviceManager.setMetadata": [{
32033
+ name: "deviceId",
32034
+ form: "single",
32035
+ optional: false
32036
+ }],
32037
+ "deviceManager.setName": [{
32038
+ name: "deviceId",
32039
+ form: "single",
32040
+ optional: false
32041
+ }],
32042
+ "deviceManager.setPrimaryChildEntityId": [{
32043
+ name: "deviceId",
32044
+ form: "single",
32045
+ optional: false
32046
+ }],
32047
+ "deviceManager.setRole": [{
32048
+ name: "deviceId",
32049
+ form: "single",
32050
+ optional: false
32051
+ }],
32052
+ "deviceManager.setStreamProfileMap": [{
32053
+ name: "deviceId",
32054
+ form: "single",
32055
+ optional: false
32056
+ }],
32057
+ "deviceManager.setType": [{
32058
+ name: "deviceId",
32059
+ form: "single",
32060
+ optional: false
32061
+ }],
32062
+ "deviceManager.setWrapperActive": [{
32063
+ name: "deviceId",
32064
+ form: "single",
32065
+ optional: false
32066
+ }],
32067
+ "deviceManager.testField": [{
32068
+ name: "deviceId",
32069
+ form: "single",
32070
+ optional: false
32071
+ }],
32072
+ "deviceManager.updateConfig": [{
32073
+ name: "deviceId",
32074
+ form: "single",
32075
+ optional: false
32076
+ }],
32077
+ "deviceManager.updateDeviceField": [{
32078
+ name: "deviceId",
32079
+ form: "single",
32080
+ optional: false
32081
+ }],
32082
+ "deviceManager.updateDeviceFieldsBatch": [{
32083
+ name: "deviceId",
32084
+ form: "single",
32085
+ optional: false
32086
+ }],
32087
+ "deviceOps.getConfigEntries": [{
32088
+ name: "deviceId",
32089
+ form: "single",
32090
+ optional: false
32091
+ }],
32092
+ "deviceOps.getRawState": [{
32093
+ name: "deviceId",
32094
+ form: "single",
32095
+ optional: false
32096
+ }],
32097
+ "deviceOps.getSettingsSchema": [{
32098
+ name: "deviceId",
32099
+ form: "single",
32100
+ optional: false
32101
+ }],
32102
+ "deviceOps.getStreamSources": [{
32103
+ name: "deviceId",
32104
+ form: "single",
32105
+ optional: false
32106
+ }],
32107
+ "deviceOps.removeDevice": [{
32108
+ name: "deviceId",
32109
+ form: "single",
32110
+ optional: false
32111
+ }],
32112
+ "deviceOps.runAction": [{
32113
+ name: "deviceId",
32114
+ form: "single",
32115
+ optional: false
32116
+ }],
32117
+ "deviceOps.setConfig": [{
32118
+ name: "deviceId",
32119
+ form: "single",
32120
+ optional: false
32121
+ }],
32122
+ "deviceState.getCapSlice": [{
32123
+ name: "deviceId",
32124
+ form: "single",
32125
+ optional: false
32126
+ }],
32127
+ "deviceState.getSnapshot": [{
32128
+ name: "deviceId",
32129
+ form: "single",
32130
+ optional: false
32131
+ }],
32132
+ "deviceState.setCapSlice": [{
32133
+ name: "deviceId",
32134
+ form: "single",
32135
+ optional: false
32136
+ }],
32137
+ "events.getEventClipUrl": [{
32138
+ name: "deviceId",
32139
+ form: "single",
32140
+ optional: false
32141
+ }],
32142
+ "events.getEvents": [{
32143
+ name: "deviceId",
32144
+ form: "single",
32145
+ optional: false
32146
+ }],
32147
+ "events.getEventThumbnail": [{
32148
+ name: "deviceId",
32149
+ form: "single",
32150
+ optional: false
32151
+ }],
32152
+ "faceGallery.getFaceByTrack": [{
32153
+ name: "deviceId",
32154
+ form: "single",
32155
+ optional: false
32156
+ }],
32157
+ "faceGallery.listRecentFaces": [{
32158
+ name: "deviceId",
32159
+ form: "single",
32160
+ optional: true
32161
+ }],
32162
+ "fanControl.setDirection": [{
32163
+ name: "deviceId",
32164
+ form: "single",
32165
+ optional: false
32166
+ }],
32167
+ "fanControl.setOscillating": [{
32168
+ name: "deviceId",
32169
+ form: "single",
32170
+ optional: false
32171
+ }],
32172
+ "fanControl.setPercentage": [{
32173
+ name: "deviceId",
32174
+ form: "single",
32175
+ optional: false
32176
+ }],
32177
+ "fanControl.setPreset": [{
32178
+ name: "deviceId",
32179
+ form: "single",
32180
+ optional: false
32181
+ }],
32182
+ "humidifier.setMode": [{
32183
+ name: "deviceId",
32184
+ form: "single",
32185
+ optional: false
32186
+ }],
32187
+ "humidifier.setOn": [{
32188
+ name: "deviceId",
32189
+ form: "single",
32190
+ optional: false
32191
+ }],
32192
+ "humidifier.setTargetHumidity": [{
32193
+ name: "deviceId",
32194
+ form: "single",
32195
+ optional: false
32196
+ }],
32197
+ "imageSettings.getOptions": [{
32198
+ name: "deviceId",
32199
+ form: "single",
32200
+ optional: false
32201
+ }],
32202
+ "imageSettings.setSettings": [{
32203
+ name: "deviceId",
32204
+ form: "single",
32205
+ optional: false
32206
+ }],
32207
+ "intercom.endTalkSession": [{
32208
+ name: "deviceId",
32209
+ form: "single",
32210
+ optional: false
32211
+ }],
32212
+ "intercom.handleAnswer": [{
32213
+ name: "deviceId",
32214
+ form: "single",
32215
+ optional: false
32216
+ }],
32217
+ "intercom.pushTalkAudio": [{
32218
+ name: "deviceId",
32219
+ form: "single",
32220
+ optional: false
32221
+ }],
32222
+ "intercom.startSession": [{
32223
+ name: "deviceId",
32224
+ form: "single",
32225
+ optional: false
32226
+ }],
32227
+ "intercom.startTalkSession": [{
32228
+ name: "deviceId",
32229
+ form: "single",
32230
+ optional: false
32231
+ }],
32232
+ "intercom.stopSession": [{
32233
+ name: "deviceId",
32234
+ form: "single",
32235
+ optional: false
32236
+ }],
32237
+ "lawnMowerControl.dock": [{
32238
+ name: "deviceId",
32239
+ form: "single",
32240
+ optional: false
32241
+ }],
32242
+ "lawnMowerControl.pause": [{
32243
+ name: "deviceId",
32244
+ form: "single",
32245
+ optional: false
32246
+ }],
32247
+ "lawnMowerControl.startMowing": [{
32248
+ name: "deviceId",
32249
+ form: "single",
32250
+ optional: false
32251
+ }],
32252
+ "lockControl.lock": [{
32253
+ name: "deviceId",
32254
+ form: "single",
32255
+ optional: false
32256
+ }],
32257
+ "lockControl.open": [{
32258
+ name: "deviceId",
32259
+ form: "single",
32260
+ optional: false
32261
+ }],
32262
+ "lockControl.unlock": [{
32263
+ name: "deviceId",
32264
+ form: "single",
32265
+ optional: false
32266
+ }],
32267
+ "mediaPlayer.next": [{
32268
+ name: "deviceId",
32269
+ form: "single",
32270
+ optional: false
32271
+ }],
32272
+ "mediaPlayer.pause": [{
32273
+ name: "deviceId",
32274
+ form: "single",
32275
+ optional: false
32276
+ }],
32277
+ "mediaPlayer.play": [{
32278
+ name: "deviceId",
32279
+ form: "single",
32280
+ optional: false
32281
+ }],
32282
+ "mediaPlayer.playMedia": [{
32283
+ name: "deviceId",
32284
+ form: "single",
32285
+ optional: false
32286
+ }],
32287
+ "mediaPlayer.previous": [{
32288
+ name: "deviceId",
32289
+ form: "single",
32290
+ optional: false
32291
+ }],
32292
+ "mediaPlayer.seek": [{
32293
+ name: "deviceId",
32294
+ form: "single",
32295
+ optional: false
32296
+ }],
32297
+ "mediaPlayer.selectSource": [{
32298
+ name: "deviceId",
32299
+ form: "single",
32300
+ optional: false
32301
+ }],
32302
+ "mediaPlayer.setMute": [{
32303
+ name: "deviceId",
32304
+ form: "single",
32305
+ optional: false
32306
+ }],
32307
+ "mediaPlayer.setRepeat": [{
32308
+ name: "deviceId",
32309
+ form: "single",
32310
+ optional: false
32311
+ }],
32312
+ "mediaPlayer.setShuffle": [{
32313
+ name: "deviceId",
32314
+ form: "single",
32315
+ optional: false
32316
+ }],
32317
+ "mediaPlayer.setVolume": [{
32318
+ name: "deviceId",
32319
+ form: "single",
32320
+ optional: false
32321
+ }],
32322
+ "mediaPlayer.stop": [{
32323
+ name: "deviceId",
32324
+ form: "single",
32325
+ optional: false
32326
+ }],
32327
+ "motion.isDetected": [{
32328
+ name: "deviceId",
32329
+ form: "single",
32330
+ optional: false
32331
+ }],
32332
+ "motionDetection.analyze": [{
32333
+ name: "deviceId",
32334
+ form: "single",
32335
+ optional: false
32336
+ }],
32337
+ "motionDetection.removeCamera": [{
32338
+ name: "deviceId",
32339
+ form: "single",
32340
+ optional: false
32341
+ }],
32342
+ "motionTrigger.setMotionTrigger": [{
32343
+ name: "deviceId",
32344
+ form: "single",
32345
+ optional: false
32346
+ }],
32347
+ "motionZones.getOptions": [{
32348
+ name: "deviceId",
32349
+ form: "single",
32350
+ optional: false
32351
+ }],
32352
+ "motionZones.setZone": [{
32353
+ name: "deviceId",
32354
+ form: "single",
32355
+ optional: false
32356
+ }],
32357
+ "nativeObjectDetection.setEnabled": [{
32358
+ name: "deviceId",
32359
+ form: "single",
32360
+ optional: false
32361
+ }],
32362
+ "networkQuality.getDeviceStats": [{
32363
+ name: "deviceId",
32364
+ form: "single",
32365
+ optional: false
32366
+ }],
32367
+ "networkQuality.reportClientStats": [{
32368
+ name: "deviceId",
32369
+ form: "single",
32370
+ optional: false
32371
+ }],
32372
+ "notificationRules.setDeviceMuted": [{
32373
+ name: "deviceId",
32374
+ form: "single",
32375
+ optional: false
32376
+ }],
32377
+ "notifier.cancel": [{
32378
+ name: "deviceId",
32379
+ form: "single",
32380
+ optional: false
32381
+ }],
32382
+ "notifier.send": [{
32383
+ name: "deviceId",
32384
+ form: "single",
32385
+ optional: false
32386
+ }],
32387
+ "osd.setOverlay": [{
32388
+ name: "deviceId",
32389
+ form: "single",
32390
+ optional: false
32391
+ }],
32392
+ "osdManager.clearSlotBinding": [{
32393
+ name: "deviceId",
32394
+ form: "single",
32395
+ optional: false
32396
+ }],
32397
+ "osdManager.copyDeviceConfiguration": [{
32398
+ name: "sourceDeviceId",
32399
+ form: "single",
32400
+ optional: false
32401
+ }, {
32402
+ name: "targetDeviceId",
32403
+ form: "single",
32404
+ optional: false
32405
+ }],
32406
+ "osdManager.getDeviceOsd": [{
32407
+ name: "deviceId",
32408
+ form: "single",
32409
+ optional: false
32410
+ }],
32411
+ "osdManager.getSourceCatalog": [{
32412
+ name: "deviceId",
32413
+ form: "single",
32414
+ optional: false
32415
+ }],
32416
+ "osdManager.previewSlot": [{
32417
+ name: "deviceId",
32418
+ form: "single",
32419
+ optional: false
32420
+ }],
32421
+ "osdManager.renderDevice": [{
32422
+ name: "deviceId",
32423
+ form: "single",
32424
+ optional: false
32425
+ }],
32426
+ "osdManager.setSlotBinding": [{
32427
+ name: "deviceId",
32428
+ form: "single",
32429
+ optional: false
32430
+ }],
32431
+ "petFeeder.callPet": [{
32432
+ name: "deviceId",
32433
+ form: "single",
32434
+ optional: false
32435
+ }],
32436
+ "petFeeder.cancelFeed": [{
32437
+ name: "deviceId",
32438
+ form: "single",
32439
+ optional: false
32440
+ }],
32441
+ "petFeeder.feed": [{
32442
+ name: "deviceId",
32443
+ form: "single",
32444
+ optional: false
32445
+ }],
32446
+ "petFeeder.markFoodReplenished": [{
32447
+ name: "deviceId",
32448
+ form: "single",
32449
+ optional: false
32450
+ }],
32451
+ "petFeeder.playSound": [{
32452
+ name: "deviceId",
32453
+ form: "single",
32454
+ optional: false
32455
+ }],
32456
+ "petFeeder.resetDesiccant": [{
32457
+ name: "deviceId",
32458
+ form: "single",
32459
+ optional: false
32460
+ }],
32461
+ "petFeeder.setChildLock": [{
32462
+ name: "deviceId",
32463
+ form: "single",
32464
+ optional: false
32465
+ }],
32466
+ "petFeeder.setFeedSound": [{
32467
+ name: "deviceId",
32468
+ form: "single",
32469
+ optional: false
32470
+ }],
32471
+ "petFeeder.setIndicatorLight": [{
32472
+ name: "deviceId",
32473
+ form: "single",
32474
+ optional: false
32475
+ }],
32476
+ "petFeeder.setVolume": [{
32477
+ name: "deviceId",
32478
+ form: "single",
32479
+ optional: false
32480
+ }],
32481
+ "pipelineAnalytics.clearTracks": [{
32482
+ name: "deviceId",
32483
+ form: "single",
32484
+ optional: false
32485
+ }],
32486
+ "pipelineAnalytics.completeRetrainTrack": [{
32487
+ name: "deviceId",
32488
+ form: "single",
32489
+ optional: false
32490
+ }],
32491
+ "pipelineAnalytics.deleteDeviceEvents": [{
32492
+ name: "deviceId",
32493
+ form: "single",
32494
+ optional: false
32495
+ }],
32496
+ "pipelineAnalytics.deleteTracks": [{
32497
+ name: "deviceId",
32498
+ form: "single",
32499
+ optional: false
32500
+ }],
32501
+ "pipelineAnalytics.deselectRetrainFrame": [{
32502
+ name: "deviceId",
32503
+ form: "single",
32504
+ optional: false
32505
+ }],
32506
+ "pipelineAnalytics.getActiveTracks": [{
32507
+ name: "deviceId",
32508
+ form: "single",
32509
+ optional: false
32510
+ }],
32511
+ "pipelineAnalytics.getAudioEvents": [{
32512
+ name: "deviceId",
32513
+ form: "single",
32514
+ optional: false
32515
+ }],
32516
+ "pipelineAnalytics.getEventDensity": [{
32517
+ name: "deviceId",
32518
+ form: "single",
32519
+ optional: false
32520
+ }],
32521
+ "pipelineAnalytics.getEventMedia": [{
32522
+ name: "deviceId",
32523
+ form: "single",
32524
+ optional: false
32525
+ }],
32526
+ "pipelineAnalytics.getKeyEvents": [{
32527
+ name: "deviceId",
32528
+ form: "single",
32529
+ optional: false
32530
+ }],
32531
+ "pipelineAnalytics.getMotionEvents": [{
32532
+ name: "deviceId",
32533
+ form: "single",
32534
+ optional: false
32535
+ }],
32536
+ "pipelineAnalytics.getObjectEvents": [{
32537
+ name: "deviceId",
32538
+ form: "single",
32539
+ optional: false
32540
+ }],
32541
+ "pipelineAnalytics.getRetrainExportUrl": [{
32542
+ name: "deviceIds",
32543
+ form: "array",
32544
+ optional: true
32545
+ }],
32546
+ "pipelineAnalytics.getSensorEvents": [{
32547
+ name: "deviceId",
32548
+ form: "single",
32549
+ optional: false
32550
+ }],
32551
+ "pipelineAnalytics.getTrack": [{
32552
+ name: "deviceId",
32553
+ form: "single",
32554
+ optional: false
32555
+ }],
32556
+ "pipelineAnalytics.getTrackMedia": [{
32557
+ name: "deviceId",
32558
+ form: "single",
32559
+ optional: false
32560
+ }],
32561
+ "pipelineAnalytics.getTrainingExportSummary": [{
32562
+ name: "deviceIds",
32563
+ form: "array",
32564
+ optional: true
32565
+ }],
32566
+ "pipelineAnalytics.getTrainingExportUrl": [{
32567
+ name: "deviceIds",
32568
+ form: "array",
32569
+ optional: true
32570
+ }],
32571
+ "pipelineAnalytics.listEventKinds": [{
32572
+ name: "deviceId",
32573
+ form: "single",
32574
+ optional: false
32575
+ }],
32576
+ "pipelineAnalytics.listEventKindsBatch": [{
32577
+ name: "deviceIds",
32578
+ form: "array",
32579
+ optional: false
32580
+ }],
32581
+ "pipelineAnalytics.listOpsLog": [{
32582
+ name: "deviceId",
32583
+ form: "single",
32584
+ optional: true
32585
+ }],
32586
+ "pipelineAnalytics.listRecentTracks": [{
32587
+ name: "deviceIds",
32588
+ form: "array",
32589
+ optional: false
32590
+ }],
32591
+ "pipelineAnalytics.listRetrainStaging": [{
32592
+ name: "deviceIds",
32593
+ form: "array",
32594
+ optional: true
32595
+ }],
32596
+ "pipelineAnalytics.listTrackMedia": [{
32597
+ name: "deviceId",
32598
+ form: "single",
32599
+ optional: false
32600
+ }],
32601
+ "pipelineAnalytics.listTracks": [{
32602
+ name: "deviceId",
32603
+ form: "single",
32604
+ optional: false
32605
+ }],
32606
+ "pipelineAnalytics.proposeRetrainAnnotations": [{
32607
+ name: "deviceId",
32608
+ form: "single",
32609
+ optional: false
32610
+ }],
32611
+ "pipelineAnalytics.pruneEventsBefore": [{
32612
+ name: "deviceId",
32613
+ form: "single",
32614
+ optional: false
32615
+ }],
32616
+ "pipelineAnalytics.pruneTracksBefore": [{
32617
+ name: "deviceId",
32618
+ form: "single",
32619
+ optional: false
32620
+ }],
32621
+ "pipelineAnalytics.rebuildObjectEmbeddings": [{
32622
+ name: "deviceId",
32623
+ form: "single",
32624
+ optional: true
32625
+ }],
32626
+ "pipelineAnalytics.restageRetrainTrack": [{
32627
+ name: "deviceId",
32628
+ form: "single",
32629
+ optional: false
32630
+ }],
32631
+ "pipelineAnalytics.saveRetrainAnnotations": [{
32632
+ name: "deviceId",
32633
+ form: "single",
32634
+ optional: false
32635
+ }],
32636
+ "pipelineAnalytics.searchObjectEvents": [{
32637
+ name: "deviceId",
32638
+ form: "single",
32639
+ optional: true
32640
+ }],
32641
+ "pipelineAnalytics.selectRetrainFrames": [{
32642
+ name: "deviceId",
32643
+ form: "single",
32644
+ optional: false
32645
+ }],
32646
+ "pipelineAnalytics.setTrackFlags": [{
32647
+ name: "deviceId",
32648
+ form: "single",
32649
+ optional: false
32650
+ }],
32651
+ "pipelineAnalytics.wipeAllAnalytics": [{
32652
+ name: "deviceId",
32653
+ form: "single",
32654
+ optional: false
32655
+ }],
32656
+ "pipelineExecutor.runPipeline": [{
32657
+ name: "deviceId",
32658
+ form: "single",
32659
+ optional: true
32660
+ }],
32661
+ "pipelineExecutor.runPipelineBatch": [{
32662
+ name: "deviceId",
32663
+ form: "single",
32664
+ optional: true
32665
+ }],
32666
+ "pipelineOrchestrator.assignAudio": [{
32667
+ name: "deviceId",
32668
+ form: "single",
32669
+ optional: false
32670
+ }],
32671
+ "pipelineOrchestrator.assignPipeline": [{
32672
+ name: "deviceId",
32673
+ form: "single",
32674
+ optional: false
32675
+ }],
32676
+ "pipelineOrchestrator.getAudioAssignment": [{
32677
+ name: "deviceId",
32678
+ form: "single",
32679
+ optional: false
32680
+ }],
32681
+ "pipelineOrchestrator.getCameraMetrics": [{
32682
+ name: "deviceId",
32683
+ form: "single",
32684
+ optional: false
32685
+ }],
32686
+ "pipelineOrchestrator.getCameraSettings": [{
32687
+ name: "deviceId",
32688
+ form: "single",
32689
+ optional: false
32690
+ }],
32691
+ "pipelineOrchestrator.getCameraStatus": [{
32692
+ name: "deviceId",
32693
+ form: "single",
32694
+ optional: false
32695
+ }],
32696
+ "pipelineOrchestrator.getCameraStatuses": [{
32697
+ name: "deviceIds",
32698
+ form: "array",
32699
+ optional: true
32700
+ }],
32701
+ "pipelineOrchestrator.getCameraStepOverrides": [{
32702
+ name: "deviceId",
32703
+ form: "single",
32704
+ optional: false
32705
+ }],
32706
+ "pipelineOrchestrator.getCameraSwitches": [{
32707
+ name: "deviceId",
32708
+ form: "single",
32709
+ optional: false
32710
+ }],
32711
+ "pipelineOrchestrator.getPipelineAssignment": [{
32712
+ name: "deviceId",
32713
+ form: "single",
32714
+ optional: false
32715
+ }],
32716
+ "pipelineOrchestrator.getPipelineDevicePin": [{
32717
+ name: "deviceId",
32718
+ form: "single",
32719
+ optional: false
32720
+ }],
32721
+ "pipelineOrchestrator.resolvePipeline": [{
32722
+ name: "deviceId",
32723
+ form: "single",
32724
+ optional: false
32725
+ }],
32726
+ "pipelineOrchestrator.setCameraPipelineForAgent": [{
32727
+ name: "deviceId",
32728
+ form: "single",
32729
+ optional: false
32730
+ }],
32731
+ "pipelineOrchestrator.setCameraStepOverride": [{
32732
+ name: "deviceId",
32733
+ form: "single",
32734
+ optional: false
32735
+ }],
32736
+ "pipelineOrchestrator.setCameraStepToggle": [{
32737
+ name: "deviceId",
32738
+ form: "single",
32739
+ optional: false
32740
+ }],
32741
+ "pipelineOrchestrator.setCameraSwitch": [{
32742
+ name: "deviceId",
32743
+ form: "single",
32744
+ optional: false
32745
+ }],
32746
+ "pipelineOrchestrator.setPipelineDevicePin": [{
32747
+ name: "deviceId",
32748
+ form: "single",
32749
+ optional: false
32750
+ }],
32751
+ "pipelineOrchestrator.unassignAudio": [{
32752
+ name: "deviceId",
32753
+ form: "single",
32754
+ optional: false
32755
+ }],
32756
+ "pipelineOrchestrator.unassignPipeline": [{
32757
+ name: "deviceId",
32758
+ form: "single",
32759
+ optional: false
32760
+ }],
32761
+ "pipelineRunner.attachCamera": [{
32762
+ name: "deviceId",
32763
+ form: "single",
32764
+ optional: false
32765
+ }],
32766
+ "pipelineRunner.detachCamera": [{
32767
+ name: "deviceId",
32768
+ form: "single",
32769
+ optional: false
32770
+ }],
32771
+ "pipelineRunner.getCameraMetrics": [{
32772
+ name: "deviceId",
32773
+ form: "single",
32774
+ optional: false
32775
+ }],
32776
+ "pipelineRunner.reportMotion": [{
32777
+ name: "deviceId",
32778
+ form: "single",
32779
+ optional: false
32780
+ }],
32781
+ "pipelineRunner.runDetailSubtree": [{
32782
+ name: "deviceId",
32783
+ form: "single",
32784
+ optional: false
32785
+ }],
32786
+ "pipelineRunner.runStatelessStep": [{
32787
+ name: "sourceDeviceId",
32788
+ form: "single",
32789
+ optional: false
32790
+ }],
32791
+ "plateGallery.getPlateByTrack": [{
32792
+ name: "deviceId",
32793
+ form: "single",
32794
+ optional: false
32795
+ }],
32796
+ "plateGallery.listPlates": [{
32797
+ name: "deviceId",
32798
+ form: "single",
32799
+ optional: true
32800
+ }],
32801
+ "privacyMask.getOptions": [{
32802
+ name: "deviceId",
32803
+ form: "single",
32804
+ optional: false
32805
+ }],
32806
+ "privacyMask.setAudioEnabled": [{
32807
+ name: "deviceId",
32808
+ form: "single",
32809
+ optional: false
32810
+ }],
32811
+ "privacyMask.setMask": [{
32812
+ name: "deviceId",
32813
+ form: "single",
32814
+ optional: false
32815
+ }],
32816
+ "ptz.continuousMove": [{
32817
+ name: "deviceId",
32818
+ form: "single",
32819
+ optional: false
32820
+ }],
32821
+ "ptz.deletePreset": [{
32822
+ name: "deviceId",
32823
+ form: "single",
32824
+ optional: false
32825
+ }],
32826
+ "ptz.getOptions": [{
32827
+ name: "deviceId",
32828
+ form: "single",
32829
+ optional: false
32830
+ }],
32831
+ "ptz.getPosition": [{
32832
+ name: "deviceId",
32833
+ form: "single",
32834
+ optional: false
32835
+ }],
32836
+ "ptz.getPresets": [{
32837
+ name: "deviceId",
32838
+ form: "single",
32839
+ optional: false
32840
+ }],
32841
+ "ptz.goHome": [{
32842
+ name: "deviceId",
32843
+ form: "single",
32844
+ optional: false
32845
+ }],
32846
+ "ptz.goToPreset": [{
32847
+ name: "deviceId",
32848
+ form: "single",
32849
+ optional: false
32850
+ }],
32851
+ "ptz.move": [{
32852
+ name: "deviceId",
32853
+ form: "single",
32854
+ optional: false
32855
+ }],
32856
+ "ptz.savePreset": [{
32857
+ name: "deviceId",
32858
+ form: "single",
32859
+ optional: false
32860
+ }],
32861
+ "ptz.setAutofocus": [{
32862
+ name: "deviceId",
32863
+ form: "single",
32864
+ optional: false
32865
+ }],
32866
+ "ptz.stop": [{
32867
+ name: "deviceId",
32868
+ form: "single",
32869
+ optional: false
32870
+ }],
32871
+ "ptzAutotrack.getSettings": [{
32872
+ name: "deviceId",
32873
+ form: "single",
32874
+ optional: false
32875
+ }],
32876
+ "ptzAutotrack.getStatus": [{
32877
+ name: "deviceId",
32878
+ form: "single",
32879
+ optional: false
32880
+ }],
32881
+ "ptzAutotrack.setEnabled": [{
32882
+ name: "deviceId",
32883
+ form: "single",
32884
+ optional: false
32885
+ }],
32886
+ "ptzAutotrack.setSettings": [{
32887
+ name: "deviceId",
32888
+ form: "single",
32889
+ optional: false
32890
+ }],
32891
+ "reboot.reboot": [{
32892
+ name: "deviceId",
32893
+ form: "single",
32894
+ optional: false
32895
+ }],
32896
+ "recording.deleteFootprint": [{
32897
+ name: "deviceId",
32898
+ form: "single",
32899
+ optional: false
32900
+ }],
32901
+ "recording.getAvailability": [{
32902
+ name: "deviceId",
32903
+ form: "single",
32904
+ optional: false
32905
+ }],
32906
+ "recording.getDaysWithRecordings": [{
32907
+ name: "deviceId",
32908
+ form: "single",
32909
+ optional: false
32910
+ }],
32911
+ "recording.getDeviceConfig": [{
32912
+ name: "deviceId",
32913
+ form: "single",
32914
+ optional: false
32915
+ }],
32916
+ "recording.getPlaybackManifest": [{
32917
+ name: "deviceId",
32918
+ form: "single",
32919
+ optional: false
32920
+ }],
32921
+ "recording.listOpsLog": [{
32922
+ name: "deviceId",
32923
+ form: "single",
32924
+ optional: true
32925
+ }],
32926
+ "recording.locateSegment": [{
32927
+ name: "deviceId",
32928
+ form: "single",
32929
+ optional: false
32930
+ }],
32931
+ "recording.pruneFootage": [{
32932
+ name: "deviceId",
32933
+ form: "single",
32934
+ optional: false
32935
+ }],
32936
+ "recording.readGopBytes": [{
32937
+ name: "deviceId",
32938
+ form: "single",
32939
+ optional: false
32940
+ }],
32941
+ "recording.readSegmentBytes": [{
32942
+ name: "deviceId",
32943
+ form: "single",
32944
+ optional: false
32945
+ }],
32946
+ "recording.relocateFootage": [{
32947
+ name: "deviceId",
32948
+ form: "single",
32949
+ optional: true
32950
+ }],
32951
+ "recording.renderClip": [{
32952
+ name: "deviceId",
32953
+ form: "single",
32954
+ optional: false
32955
+ }],
32956
+ "recording.renderGif": [{
32957
+ name: "deviceId",
32958
+ form: "single",
32959
+ optional: false
32960
+ }],
32961
+ "recording.rescanStorage": [{
32962
+ name: "deviceId",
32963
+ form: "single",
32964
+ optional: false
32965
+ }],
32966
+ "recording.setDeviceConfig": [{
32967
+ name: "deviceId",
32968
+ form: "single",
32969
+ optional: false
32970
+ }],
32971
+ "recording.startStorageMigrationMove": [{
32972
+ name: "deviceId",
32973
+ form: "single",
32974
+ optional: true
32975
+ }],
32976
+ "recordingExport.createExport": [{
32977
+ name: "deviceId",
32978
+ form: "single",
32979
+ optional: false
32980
+ }],
32981
+ "recordingExport.listExports": [{
32982
+ name: "deviceId",
32983
+ form: "single",
32984
+ optional: true
32985
+ }],
32986
+ "sceneMonitor.captureReference": [{
32987
+ name: "deviceId",
32988
+ form: "single",
32989
+ optional: false
32990
+ }],
32991
+ "sceneMonitor.createScene": [{
32992
+ name: "deviceId",
32993
+ form: "single",
32994
+ optional: false
32995
+ }],
32996
+ "sceneMonitor.deleteReference": [{
32997
+ name: "deviceId",
32998
+ form: "single",
32999
+ optional: false
33000
+ }],
33001
+ "sceneMonitor.deleteScene": [{
33002
+ name: "deviceId",
33003
+ form: "single",
33004
+ optional: false
33005
+ }],
33006
+ "sceneMonitor.listScenes": [{
33007
+ name: "deviceId",
33008
+ form: "single",
33009
+ optional: false
33010
+ }],
33011
+ "sceneMonitor.recheckNow": [{
33012
+ name: "deviceId",
33013
+ form: "single",
33014
+ optional: false
33015
+ }],
33016
+ "sceneMonitor.resetScene": [{
33017
+ name: "deviceId",
33018
+ form: "single",
33019
+ optional: false
33020
+ }],
33021
+ "sceneMonitor.updateScene": [{
33022
+ name: "deviceId",
33023
+ form: "single",
33024
+ optional: false
33025
+ }],
33026
+ "scriptRunner.run": [{
33027
+ name: "deviceId",
33028
+ form: "single",
33029
+ optional: false
33030
+ }],
33031
+ "scriptRunner.stop": [{
33032
+ name: "deviceId",
33033
+ form: "single",
33034
+ optional: false
33035
+ }],
33036
+ "snapshot.getDebugState": [{
33037
+ name: "deviceId",
33038
+ form: "single",
33039
+ optional: false
33040
+ }],
33041
+ "snapshot.getSnapshot": [{
33042
+ name: "deviceId",
33043
+ form: "single",
33044
+ optional: false
33045
+ }],
33046
+ "snapshot.getSnapshotLinks": [{
33047
+ name: "targets",
33048
+ form: "object-array",
33049
+ optional: false,
33050
+ itemField: "deviceId"
33051
+ }],
33052
+ "snapshot.getSnapshotOverview": [{
33053
+ name: "deviceIds",
33054
+ form: "array",
33055
+ optional: false
33056
+ }],
33057
+ "snapshot.invalidateCache": [{
33058
+ name: "deviceId",
33059
+ form: "single",
33060
+ optional: false
33061
+ }],
33062
+ "streamBroker.acquireEgressTranscode": [{
33063
+ name: "deviceId",
33064
+ form: "single",
33065
+ optional: false
33066
+ }],
33067
+ "streamBroker.assignProfile": [{
33068
+ name: "deviceId",
33069
+ form: "single",
33070
+ optional: false
33071
+ }],
33072
+ "streamBroker.getDeviceAudioMute": [{
33073
+ name: "deviceId",
33074
+ form: "single",
33075
+ optional: false
33076
+ }],
33077
+ "streamBroker.getStreamWithCodec": [{
33078
+ name: "deviceId",
33079
+ form: "single",
33080
+ optional: false
33081
+ }],
33082
+ "streamBroker.produceEventMedia": [{
33083
+ name: "deviceId",
33084
+ form: "single",
33085
+ optional: false
33086
+ }],
33087
+ "streamBroker.publishCameraStream": [{
33088
+ name: "deviceId",
33089
+ form: "single",
33090
+ optional: false
33091
+ }],
33092
+ "streamBroker.renderPreBufferClip": [{
33093
+ name: "deviceId",
33094
+ form: "single",
33095
+ optional: false
33096
+ }],
33097
+ "streamBroker.restartProfile": [{
33098
+ name: "deviceId",
33099
+ form: "single",
33100
+ optional: false
33101
+ }],
33102
+ "streamBroker.retractCameraStream": [{
33103
+ name: "deviceId",
33104
+ form: "single",
33105
+ optional: false
33106
+ }],
33107
+ "streamBroker.setDeviceAudioMute": [{
33108
+ name: "deviceId",
33109
+ form: "single",
33110
+ optional: false
33111
+ }],
33112
+ "streamBroker.unassignProfile": [{
33113
+ name: "deviceId",
33114
+ form: "single",
33115
+ optional: false
33116
+ }],
33117
+ "streamCatalog.getCatalog": [{
33118
+ name: "deviceId",
33119
+ form: "single",
33120
+ optional: false
33121
+ }],
33122
+ "streamParams.getConfigSchema": [{
33123
+ name: "deviceId",
33124
+ form: "single",
33125
+ optional: false
33126
+ }],
33127
+ "streamParams.getOptions": [{
33128
+ name: "deviceId",
33129
+ form: "single",
33130
+ optional: false
33131
+ }],
33132
+ "streamParams.setProfile": [{
33133
+ name: "deviceId",
33134
+ form: "single",
33135
+ optional: false
33136
+ }],
33137
+ "switch.setState": [{
33138
+ name: "deviceId",
33139
+ form: "single",
33140
+ optional: false
33141
+ }],
33142
+ "vacuumControl.locate": [{
33143
+ name: "deviceId",
33144
+ form: "single",
33145
+ optional: false
33146
+ }],
33147
+ "vacuumControl.pause": [{
33148
+ name: "deviceId",
33149
+ form: "single",
33150
+ optional: false
33151
+ }],
33152
+ "vacuumControl.returnToBase": [{
33153
+ name: "deviceId",
33154
+ form: "single",
33155
+ optional: false
33156
+ }],
33157
+ "vacuumControl.setFanSpeed": [{
33158
+ name: "deviceId",
33159
+ form: "single",
33160
+ optional: false
33161
+ }],
33162
+ "vacuumControl.start": [{
33163
+ name: "deviceId",
33164
+ form: "single",
33165
+ optional: false
33166
+ }],
33167
+ "vacuumControl.stop": [{
33168
+ name: "deviceId",
33169
+ form: "single",
33170
+ optional: false
33171
+ }],
33172
+ "valve.close": [{
33173
+ name: "deviceId",
33174
+ form: "single",
33175
+ optional: false
33176
+ }],
33177
+ "valve.open": [{
33178
+ name: "deviceId",
33179
+ form: "single",
33180
+ optional: false
33181
+ }],
33182
+ "valve.setPosition": [{
33183
+ name: "deviceId",
33184
+ form: "single",
33185
+ optional: false
33186
+ }],
33187
+ "valve.stop": [{
33188
+ name: "deviceId",
33189
+ form: "single",
33190
+ optional: false
33191
+ }],
33192
+ "videoclips.getClipPlayback": [{
33193
+ name: "deviceId",
33194
+ form: "single",
33195
+ optional: false
33196
+ }],
33197
+ "videoclips.listClips": [{
33198
+ name: "deviceId",
33199
+ form: "single",
33200
+ optional: false
33201
+ }],
33202
+ "waterHeater.setAway": [{
33203
+ name: "deviceId",
33204
+ form: "single",
33205
+ optional: false
33206
+ }],
33207
+ "waterHeater.setOperationMode": [{
33208
+ name: "deviceId",
33209
+ form: "single",
33210
+ optional: false
33211
+ }],
33212
+ "waterHeater.setTargetTemp": [{
33213
+ name: "deviceId",
33214
+ form: "single",
33215
+ optional: false
33216
+ }],
33217
+ "webrtcSession.addIceCandidate": [{
33218
+ name: "deviceId",
33219
+ form: "single",
33220
+ optional: false
33221
+ }],
33222
+ "webrtcSession.closeSession": [{
33223
+ name: "deviceId",
33224
+ form: "single",
33225
+ optional: false
33226
+ }],
33227
+ "webrtcSession.createSession": [{
33228
+ name: "deviceId",
33229
+ form: "single",
33230
+ optional: false
33231
+ }],
33232
+ "webrtcSession.getIceCandidates": [{
33233
+ name: "deviceId",
33234
+ form: "single",
33235
+ optional: false
33236
+ }],
33237
+ "webrtcSession.getSessionState": [{
33238
+ name: "deviceId",
33239
+ form: "single",
33240
+ optional: false
33241
+ }],
33242
+ "webrtcSession.handleAnswer": [{
33243
+ name: "deviceId",
33244
+ form: "single",
33245
+ optional: false
33246
+ }],
33247
+ "webrtcSession.handleOffer": [{
33248
+ name: "deviceId",
33249
+ form: "single",
33250
+ optional: false
33251
+ }],
33252
+ "webrtcSession.hasAdaptiveBitrate": [{
33253
+ name: "deviceId",
33254
+ form: "single",
33255
+ optional: false
33256
+ }],
33257
+ "webrtcSession.listStreams": [{
33258
+ name: "deviceId",
33259
+ form: "single",
33260
+ optional: false
33261
+ }],
33262
+ "zoneAnalytics.getCameraHistory": [{
33263
+ name: "deviceId",
33264
+ form: "single",
33265
+ optional: false
33266
+ }],
33267
+ "zoneAnalytics.getCurrentSnapshot": [{
33268
+ name: "deviceId",
33269
+ form: "single",
33270
+ optional: false
33271
+ }],
33272
+ "zoneAnalytics.getUnzonedHistory": [{
33273
+ name: "deviceId",
33274
+ form: "single",
33275
+ optional: false
33276
+ }],
33277
+ "zoneAnalytics.getZoneHistory": [{
33278
+ name: "deviceId",
33279
+ form: "single",
33280
+ optional: false
33281
+ }],
33282
+ "zoneRules.listRules": [{
33283
+ name: "deviceId",
33284
+ form: "single",
33285
+ optional: false
33286
+ }],
33287
+ "zoneRules.setRules": [{
33288
+ name: "deviceId",
33289
+ form: "single",
33290
+ optional: false
33291
+ }],
33292
+ "zones.addZone": [{
33293
+ name: "deviceId",
33294
+ form: "single",
33295
+ optional: false
33296
+ }],
33297
+ "zones.listZones": [{
33298
+ name: "deviceId",
33299
+ form: "single",
33300
+ optional: false
33301
+ }],
33302
+ "zones.removeZone": [{
33303
+ name: "deviceId",
33304
+ form: "single",
33305
+ optional: false
33306
+ }],
33307
+ "zones.updateZone": [{
33308
+ name: "deviceId",
33309
+ form: "single",
33310
+ optional: false
33311
+ }]
33312
+ });
30708
33313
  Object.freeze({
30709
33314
  "broker": "broker",
30710
33315
  "device-export": "device-export",