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