@camstack/types 1.1.20 → 1.1.22

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 (49) hide show
  1. package/dist/addon/base-addon.d.ts +30 -4
  2. package/dist/addon/per-node-store.d.ts +68 -0
  3. package/dist/addon.js +1 -1
  4. package/dist/addon.mjs +1 -1
  5. package/dist/capabilities/camera-streams.cap.d.ts +5 -5
  6. package/dist/capabilities/decoder.cap.d.ts +2 -0
  7. package/dist/capabilities/device-manager.cap.d.ts +269 -6
  8. package/dist/capabilities/index.d.ts +3 -1
  9. package/dist/capabilities/metrics-provider.cap.d.ts +2 -2
  10. package/dist/capabilities/motion-detection.cap.d.ts +20 -2
  11. package/dist/capabilities/pet-feeder.cap.d.ts +185 -0
  12. package/dist/capabilities/pipeline-executor.cap.d.ts +29 -2
  13. package/dist/capabilities/pipeline-orchestrator.cap.d.ts +7 -3
  14. package/dist/capabilities/platform-probe.cap.d.ts +1 -1
  15. package/dist/capabilities/schemas/streaming-shared.d.ts +2 -2
  16. package/dist/capabilities/stream-broker.cap.d.ts +1 -1
  17. package/dist/device/device-management.d.ts +61 -2
  18. package/dist/device/device-type.d.ts +8 -1
  19. package/dist/device/index.d.ts +1 -1
  20. package/dist/expression/ast.d.ts +56 -0
  21. package/dist/expression/builtins.d.ts +19 -0
  22. package/dist/expression/compile.d.ts +17 -0
  23. package/dist/expression/errors.d.ts +16 -0
  24. package/dist/expression/evaluator.d.ts +14 -0
  25. package/dist/expression/index.d.ts +25 -0
  26. package/dist/expression/limits.d.ts +30 -0
  27. package/dist/expression/link-expression.d.ts +44 -0
  28. package/dist/expression/parser.d.ts +12 -0
  29. package/dist/expression/tokenizer.d.ts +38 -0
  30. package/dist/generated/addon-api.d.ts +616 -12
  31. package/dist/generated/cap-status-types.d.ts +3 -1
  32. package/dist/generated/capability-router-map.d.ts +5 -2
  33. package/dist/generated/device-local-state.d.ts +3 -0
  34. package/dist/generated/device-proxy.d.ts +4 -1
  35. package/dist/generated/method-access-map.d.ts +1 -1
  36. package/dist/generated/system-proxy.d.ts +1 -1
  37. package/dist/index.d.ts +4 -1
  38. package/dist/index.js +1555 -37
  39. package/dist/index.mjs +1523 -38
  40. package/dist/interfaces/addon.d.ts +15 -2
  41. package/dist/interfaces/agent.d.ts +14 -0
  42. package/dist/interfaces/config-ui.d.ts +19 -1
  43. package/dist/interfaces/pipeline-executor-capability.d.ts +10 -0
  44. package/dist/{sleep-BabrCASa.js → sleep-B8cp-HUn.js} +193 -7
  45. package/dist/{sleep-MHm--th-.mjs → sleep-BiDFW0E7.mjs} +193 -7
  46. package/dist/units/convert.d.ts +49 -0
  47. package/dist/units/index.d.ts +8 -0
  48. package/dist/units/unit-table.d.ts +270 -0
  49. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { $ as SubscribeAudioChunksResultSchema, A as ReadinessRegistry, B as CamStreamResolutionSchema, C as asJsonObject, D as parseJsonObject, E as parseJsonArray, F as BrokerStatsSchema, G as FrameHandleFormatSchema, H as DecodedAudioChunkSchema, I as BrokerStatusSchema, J as ProfileSlotSchema, K as FrameHandleSchema, L as CAM_PROFILE_ORDER, M as emitDownForOwnedCaps, N as readinessKey, O as parseJsonUnknown, P as scopeKey, Q as SubscribeAudioChunksInputSchema, R as CamProfileSchema, S as asJsonArray, T as asString, U as DecodedFrameSchema, V as CameraStreamSchema, W as EncodedPacketSchema, X as StreamSourceEntrySchema, Y as ProfileSlotStatusSchema, Z as StreamSourceSchema, _ as ChargingStatus, a as adminUiCapability, at as selectAssignedProfileSlots, b as DeviceType, c as createMirrorSource, ct as createDurableState, d as DEVICE_STATUS_METHOD, dt as isEvent, et as SubscribeFramesInputSchema, f as event, ft as WELL_KNOWN_TABS, g as resolveCapMount, gt as DisposerChain, h as method, ht as EventCategory, i as deviceOpsCapability, it as parseProfileBrokerId, j as ReadinessTimeoutError, k as DATAPLANE_SECRET_HEADER, l as createSliceHandle, lt as createEvent, m as isDeviceConfigCap, mt as hydrateSchema, n as sleepCancellable, nt as makeProfileBrokerId, o as createDeviceProxy, ot as BaseAddon, p as expandCapMethods, pt as WELL_KNOWN_TAB_MAP, q as ProfileRtspEntrySchema, r as RawStateResultSchema, rt as makeSourceBrokerId, s as createLazyTrpcSource, st as normalizeAddonInitResult, t as sleep, tt as SubscribeFramesResultSchema, u as DEVICE_SETTINGS_CONTRIBUTION_METHODS, ut as emitReadiness, v as DeviceFeature, w as asNumber, x as asBoolean, y as DeviceRole, z as CamStreamKindSchema } from "./sleep-MHm--th-.mjs";
1
+ import { $ as SubscribeAudioChunksResultSchema, A as ReadinessRegistry, B as CamStreamResolutionSchema, C as asJsonObject, D as parseJsonObject, E as parseJsonArray, F as BrokerStatsSchema, G as FrameHandleFormatSchema, H as DecodedAudioChunkSchema, I as BrokerStatusSchema, J as ProfileSlotSchema, K as FrameHandleSchema, L as CAM_PROFILE_ORDER, M as emitDownForOwnedCaps, N as readinessKey, O as parseJsonUnknown, P as scopeKey, Q as SubscribeAudioChunksInputSchema, R as CamProfileSchema, S as asJsonArray, T as asString, U as DecodedFrameSchema, V as CameraStreamSchema, W as EncodedPacketSchema, X as StreamSourceEntrySchema, Y as ProfileSlotStatusSchema, Z as StreamSourceSchema, _ as ChargingStatus, a as adminUiCapability, at as selectAssignedProfileSlots, b as DeviceType, c as createMirrorSource, ct as createDurableState, d as DEVICE_STATUS_METHOD, dt as isEvent, et as SubscribeFramesInputSchema, f as event, ft as WELL_KNOWN_TABS, g as resolveCapMount, gt as DisposerChain, h as method, ht as EventCategory, i as deviceOpsCapability, it as parseProfileBrokerId, j as ReadinessTimeoutError, k as DATAPLANE_SECRET_HEADER, l as createSliceHandle, lt as createEvent, m as isDeviceConfigCap, mt as hydrateSchema, n as sleepCancellable, nt as makeProfileBrokerId, o as createDeviceProxy, ot as BaseAddon, p as expandCapMethods, pt as WELL_KNOWN_TAB_MAP, q as ProfileRtspEntrySchema, r as RawStateResultSchema, rt as makeSourceBrokerId, s as createLazyTrpcSource, st as normalizeAddonInitResult, t as sleep, tt as SubscribeFramesResultSchema, u as DEVICE_SETTINGS_CONTRIBUTION_METHODS, ut as emitReadiness, v as DeviceFeature, w as asNumber, x as asBoolean, y as DeviceRole, z as CamStreamKindSchema } from "./sleep-BiDFW0E7.mjs";
2
2
  import { t as errMsg } from "./err-msg-IQTHeDzc.mjs";
3
3
  import { z } from "zod";
4
4
  //#region src/health/wiring-health.ts
@@ -2393,6 +2393,787 @@ var DEVICE_TYPE_INFO = { ["camera"]: {
2393
2393
  icon: "camera"
2394
2394
  } };
2395
2395
  //#endregion
2396
+ //#region src/expression/errors.ts
2397
+ /**
2398
+ * Error types for the safe expression engine. Two distinct classes so callers
2399
+ * can tell a compile-time (grammar) failure from a runtime (evaluation)
2400
+ * failure — both are non-fatal to the host: read paths degrade to "skip link".
2401
+ */
2402
+ /** Thrown by the tokenizer / parser. Carries a 0-based source `position` when
2403
+ * the failure is anchored to a character (author-facing inline feedback). */
2404
+ var ExpressionParseError = class extends Error {
2405
+ position;
2406
+ constructor(message, position) {
2407
+ super(message);
2408
+ this.name = "ExpressionParseError";
2409
+ this.position = position;
2410
+ }
2411
+ };
2412
+ /** Thrown by the evaluator (unknown identifier, type mismatch, non-finite
2413
+ * result, unknown builtin, step-budget exceeded). */
2414
+ var ExpressionEvalError = class extends Error {
2415
+ constructor(message) {
2416
+ super(message);
2417
+ this.name = "ExpressionEvalError";
2418
+ }
2419
+ };
2420
+ //#endregion
2421
+ //#region src/expression/limits.ts
2422
+ /**
2423
+ * Resource-bound constants for the safe expression engine.
2424
+ *
2425
+ * Every bound is defense-in-depth: the grammar is non-Turing-complete (no
2426
+ * loops, recursion, lambdas or member access — see `ast.ts`), so evaluation is
2427
+ * O(nodeCount) by construction. These caps merely put a hard ceiling on the
2428
+ * work a single author-supplied expression can request, so a hostile or
2429
+ * accidental pathological string can never spend unbounded CPU/memory.
2430
+ */
2431
+ /** Max source length (chars) — checked BEFORE tokenizing so a huge string is
2432
+ * rejected without allocation. */
2433
+ var MAX_EXPRESSION_SOURCE_LENGTH = 2048;
2434
+ /** Max AST nodes — checked during parse; a deeply nested grouping that exceeds
2435
+ * this is rejected as "expression too complex". */
2436
+ var MAX_EXPRESSION_AST_NODES = 256;
2437
+ /** Defense-in-depth walker step budget — one increment per node visit during
2438
+ * evaluation. The grammar guarantees O(nodeCount) walks, so this can only trip
2439
+ * on a crafted maximum-size AST. */
2440
+ var MAX_EXPRESSION_EVAL_STEPS = 4096;
2441
+ /** Max named bindings on one `DeviceLinkExpressionSource`. */
2442
+ var MAX_EXPRESSION_BINDINGS = 32;
2443
+ /** Max positional arguments to any builtin call. */
2444
+ var MAX_EXPRESSION_CALL_ARGS = 16;
2445
+ /** LRU compile-cache capacity (parsed ASTs keyed by raw source string). */
2446
+ var EXPRESSION_COMPILE_CACHE_CAPACITY = 256;
2447
+ /** A legal binding / identifier name. */
2448
+ var EXPRESSION_IDENTIFIER_RE = /^[A-Za-z_][A-Za-z0-9_]*$/;
2449
+ /** Binding names an author may NOT use: `now` is auto-injected; the literal
2450
+ * keywords lex as values, not identifiers, so binding to them is meaningless. */
2451
+ var RESERVED_BINDING_NAMES = new Set([
2452
+ "now",
2453
+ "true",
2454
+ "false",
2455
+ "null"
2456
+ ]);
2457
+ //#endregion
2458
+ //#region src/expression/tokenizer.ts
2459
+ /**
2460
+ * Tokenizer for the safe expression mini-language. Hand-rolled, single-pass,
2461
+ * zero-dependency. The grammar is deliberately boring: decimal numbers,
2462
+ * single/double-quoted strings with a tiny escape set, identifiers, the three
2463
+ * value keywords (`true`/`false`/`null`) and a fixed punctuator set. Anything
2464
+ * outside that — a bare `.`, `=`, `[`, `]`, `{`, `}`, `;`, backtick, `&`, `|` —
2465
+ * is a parse error with a source position, so member access / assignment /
2466
+ * template literals are lexically impossible.
2467
+ */
2468
+ var KEYWORDS = new Set([
2469
+ "true",
2470
+ "false",
2471
+ "null"
2472
+ ]);
2473
+ function isDigit(ch) {
2474
+ return ch >= "0" && ch <= "9";
2475
+ }
2476
+ function isIdentStart(ch) {
2477
+ return ch >= "A" && ch <= "Z" || ch >= "a" && ch <= "z" || ch === "_";
2478
+ }
2479
+ function isIdentPart(ch) {
2480
+ return isIdentStart(ch) || isDigit(ch);
2481
+ }
2482
+ function isWhitespace(ch) {
2483
+ return ch === " " || ch === " " || ch === "\n" || ch === "\r" || ch === "\f" || ch === "\v";
2484
+ }
2485
+ /** Tokenize `source` into a flat token list ending with a single `eof` token.
2486
+ * Throws `ExpressionParseError` on any illegal character or unterminated
2487
+ * string. */
2488
+ function tokenize(source) {
2489
+ if (source.length > 2048) throw new ExpressionParseError(`expression too long (${source.length} > ${MAX_EXPRESSION_SOURCE_LENGTH} chars)`, 0);
2490
+ const tokens = [];
2491
+ let i = 0;
2492
+ const n = source.length;
2493
+ while (i < n) {
2494
+ const ch = source[i];
2495
+ if (isWhitespace(ch)) {
2496
+ i += 1;
2497
+ continue;
2498
+ }
2499
+ if (isDigit(ch)) {
2500
+ const start = i;
2501
+ while (i < n && isDigit(source[i])) i += 1;
2502
+ if (i < n && source[i] === ".") {
2503
+ if (i + 1 >= n || !isDigit(source[i + 1])) throw new ExpressionParseError("malformed number: decimal point needs a digit", i);
2504
+ i += 1;
2505
+ while (i < n && isDigit(source[i])) i += 1;
2506
+ }
2507
+ const text = source.slice(start, i);
2508
+ const value = Number(text);
2509
+ if (!Number.isFinite(value)) throw new ExpressionParseError(`malformed number: '${text}'`, start);
2510
+ tokens.push({
2511
+ type: "number",
2512
+ value,
2513
+ pos: start
2514
+ });
2515
+ continue;
2516
+ }
2517
+ if (ch === "'" || ch === "\"") {
2518
+ const quote = ch;
2519
+ const start = i;
2520
+ i += 1;
2521
+ let out = "";
2522
+ let closed = false;
2523
+ while (i < n) {
2524
+ const c = source[i];
2525
+ if (c === "\\") {
2526
+ const next = i + 1 < n ? source[i + 1] : "";
2527
+ if (next === "\\" || next === "'" || next === "\"") {
2528
+ out += next;
2529
+ i += 2;
2530
+ continue;
2531
+ }
2532
+ throw new ExpressionParseError(`invalid string escape: '\\${next}'`, i);
2533
+ }
2534
+ if (c === quote) {
2535
+ closed = true;
2536
+ i += 1;
2537
+ break;
2538
+ }
2539
+ out += c;
2540
+ i += 1;
2541
+ }
2542
+ if (!closed) throw new ExpressionParseError("unterminated string literal", start);
2543
+ tokens.push({
2544
+ type: "string",
2545
+ value: out,
2546
+ pos: start
2547
+ });
2548
+ continue;
2549
+ }
2550
+ if (isIdentStart(ch)) {
2551
+ const start = i;
2552
+ while (i < n && isIdentPart(source[i])) i += 1;
2553
+ const text = source.slice(start, i);
2554
+ if (KEYWORDS.has(text)) tokens.push({
2555
+ type: "keyword",
2556
+ keyword: keywordOf(text),
2557
+ pos: start
2558
+ });
2559
+ else tokens.push({
2560
+ type: "identifier",
2561
+ name: text,
2562
+ pos: start
2563
+ });
2564
+ continue;
2565
+ }
2566
+ const two = i + 1 < n ? source.slice(i, i + 2) : "";
2567
+ if (two === "<=" || two === ">=" || two === "==" || two === "!=" || two === "&&" || two === "||") {
2568
+ tokens.push({
2569
+ type: "punct",
2570
+ punct: two,
2571
+ pos: i
2572
+ });
2573
+ i += 2;
2574
+ continue;
2575
+ }
2576
+ if (isSinglePunct(ch)) {
2577
+ tokens.push({
2578
+ type: "punct",
2579
+ punct: ch,
2580
+ pos: i
2581
+ });
2582
+ i += 1;
2583
+ continue;
2584
+ }
2585
+ throw new ExpressionParseError(`unexpected character '${ch}'`, i);
2586
+ }
2587
+ tokens.push({
2588
+ type: "eof",
2589
+ pos: n
2590
+ });
2591
+ return tokens;
2592
+ }
2593
+ function keywordOf(text) {
2594
+ if (text === "true") return "true";
2595
+ if (text === "false") return "false";
2596
+ return "null";
2597
+ }
2598
+ function isSinglePunct(ch) {
2599
+ return ch === "(" || ch === ")" || ch === "," || ch === "?" || ch === ":" || ch === "+" || ch === "-" || ch === "*" || ch === "/" || ch === "%" || ch === "!" || ch === "<" || ch === ">";
2600
+ }
2601
+ //#endregion
2602
+ //#region src/expression/builtins.ts
2603
+ /**
2604
+ * Frozen, null-prototype builtin function table for the expression engine
2605
+ * (spec §4 rule 4). The table is the SOLE surface of callable functions: the
2606
+ * parser rejects any callee not in it, and the evaluator gates each call on an
2607
+ * own-property check against it.
2608
+ *
2609
+ * Because the object has a NULL prototype AND is `Object.freeze`d:
2610
+ * - it cannot be polluted (no `__proto__` / `constructor` write reaches it);
2611
+ * - a lookup for `toString` / `hasOwnProperty` / `constructor` finds NOTHING
2612
+ * (there is no `Object.prototype` in the chain), so those names are not
2613
+ * callable — they are simply "unknown function" at parse time.
2614
+ *
2615
+ * Every numeric argument is validated as a finite number and every numeric
2616
+ * RESULT is re-checked finite, so `/0`, `sqrt(-1)` (→ NaN) and overflow
2617
+ * (`pow(10,400)` → Infinity) all raise `ExpressionEvalError` and fail the link
2618
+ * closed rather than emitting a garbage value.
2619
+ */
2620
+ function asFiniteNumber(value, name, index) {
2621
+ if (typeof value !== "number" || !Number.isFinite(value)) throw new ExpressionEvalError(`${name}: argument ${index + 1} must be a finite number`);
2622
+ return value;
2623
+ }
2624
+ function asString$1(value, name, index) {
2625
+ if (typeof value !== "string") throw new ExpressionEvalError(`${name}: argument ${index + 1} must be a string`);
2626
+ return value;
2627
+ }
2628
+ function finiteResult(value, name) {
2629
+ if (!Number.isFinite(value)) throw new ExpressionEvalError(`${name}: produced a non-finite result`);
2630
+ return value;
2631
+ }
2632
+ function allFiniteNumbers(args, name) {
2633
+ return args.map((a, idx) => asFiniteNumber(a, name, idx));
2634
+ }
2635
+ var INF = Number.POSITIVE_INFINITY;
2636
+ var table = {
2637
+ min: {
2638
+ minArgs: 1,
2639
+ maxArgs: INF,
2640
+ apply: (args) => finiteResult(Math.min(...allFiniteNumbers(args, "min")), "min")
2641
+ },
2642
+ max: {
2643
+ minArgs: 1,
2644
+ maxArgs: INF,
2645
+ apply: (args) => finiteResult(Math.max(...allFiniteNumbers(args, "max")), "max")
2646
+ },
2647
+ abs: {
2648
+ minArgs: 1,
2649
+ maxArgs: 1,
2650
+ apply: (args) => finiteResult(Math.abs(asFiniteNumber(args[0], "abs", 0)), "abs")
2651
+ },
2652
+ floor: {
2653
+ minArgs: 1,
2654
+ maxArgs: 1,
2655
+ apply: (args) => finiteResult(Math.floor(asFiniteNumber(args[0], "floor", 0)), "floor")
2656
+ },
2657
+ ceil: {
2658
+ minArgs: 1,
2659
+ maxArgs: 1,
2660
+ apply: (args) => finiteResult(Math.ceil(asFiniteNumber(args[0], "ceil", 0)), "ceil")
2661
+ },
2662
+ sqrt: {
2663
+ minArgs: 1,
2664
+ maxArgs: 1,
2665
+ apply: (args) => finiteResult(Math.sqrt(asFiniteNumber(args[0], "sqrt", 0)), "sqrt")
2666
+ },
2667
+ round: {
2668
+ minArgs: 1,
2669
+ maxArgs: 2,
2670
+ apply: (args) => {
2671
+ const x = asFiniteNumber(args[0], "round", 0);
2672
+ const digits = args.length > 1 ? Math.trunc(asFiniteNumber(args[1], "round", 1)) : 0;
2673
+ if (digits < 0 || digits > 100) throw new ExpressionEvalError("round: digits must be between 0 and 100");
2674
+ const factor = 10 ** digits;
2675
+ return finiteResult(Math.round(x * factor) / factor, "round");
2676
+ }
2677
+ },
2678
+ pow: {
2679
+ minArgs: 2,
2680
+ maxArgs: 2,
2681
+ apply: (args) => finiteResult(asFiniteNumber(args[0], "pow", 0) ** asFiniteNumber(args[1], "pow", 1), "pow")
2682
+ },
2683
+ clamp: {
2684
+ minArgs: 3,
2685
+ maxArgs: 3,
2686
+ apply: (args) => {
2687
+ const x = asFiniteNumber(args[0], "clamp", 0);
2688
+ const lo = asFiniteNumber(args[1], "clamp", 1);
2689
+ const hi = asFiniteNumber(args[2], "clamp", 2);
2690
+ if (lo > hi) throw new ExpressionEvalError("clamp: lower bound is greater than upper bound");
2691
+ return finiteResult(Math.min(hi, Math.max(lo, x)), "clamp");
2692
+ }
2693
+ },
2694
+ avg: {
2695
+ minArgs: 1,
2696
+ maxArgs: INF,
2697
+ apply: (args) => {
2698
+ const nums = allFiniteNumbers(args, "avg");
2699
+ return finiteResult(nums.reduce((acc, v) => acc + v, 0) / nums.length, "avg");
2700
+ }
2701
+ },
2702
+ sum: {
2703
+ minArgs: 1,
2704
+ maxArgs: INF,
2705
+ apply: (args) => finiteResult(allFiniteNumbers(args, "sum").reduce((acc, v) => acc + v, 0), "sum")
2706
+ },
2707
+ coalesce: {
2708
+ minArgs: 1,
2709
+ maxArgs: INF,
2710
+ apply: (args) => {
2711
+ for (const a of args) if (a !== null) return a;
2712
+ return null;
2713
+ }
2714
+ },
2715
+ age: {
2716
+ minArgs: 2,
2717
+ maxArgs: 2,
2718
+ apply: (args) => finiteResult(asFiniteNumber(args[0], "age", 0) - asFiniteNumber(args[1], "age", 1), "age")
2719
+ },
2720
+ convert: {
2721
+ minArgs: 3,
2722
+ maxArgs: 3,
2723
+ apply: (args, hooks) => {
2724
+ const x = asFiniteNumber(args[0], "convert", 0);
2725
+ const from = asString$1(args[1], "convert", 1).trim();
2726
+ const to = asString$1(args[2], "convert", 2).trim();
2727
+ if (hooks.convert) {
2728
+ const out = hooks.convert(x, from, to);
2729
+ if (out === null) throw new ExpressionEvalError(`convert: cannot convert '${from}' to '${to}'`);
2730
+ return finiteResult(out, "convert");
2731
+ }
2732
+ if (from === to) return x;
2733
+ throw new ExpressionEvalError("convert: unit conversion table not installed");
2734
+ }
2735
+ }
2736
+ };
2737
+ /** Frozen, null-prototype builtin table. */
2738
+ var EXPRESSION_BUILTINS = Object.freeze(Object.assign(Object.create(null), table));
2739
+ /** The set of valid builtin names — used by the parser to reject unknown
2740
+ * callees at parse time (immediate author feedback). */
2741
+ var EXPRESSION_BUILTIN_NAMES = new Set(Object.keys(table));
2742
+ //#endregion
2743
+ //#region src/expression/parser.ts
2744
+ /**
2745
+ * Pratt (precedence-climbing) parser for the safe expression mini-language.
2746
+ *
2747
+ * Precedence (low → high): ternary `?:` (right-assoc) → `||` → `&&` → equality
2748
+ * → relational → additive → multiplicative → unary `! -` → call / primary.
2749
+ * Calls are ONLY `IDENT '(' args? ')'` at primary position — the callee is a
2750
+ * string validated against the builtin table at parse time, so an unknown
2751
+ * function is rejected immediately (author feedback) and a persisted expression
2752
+ * that references a since-removed builtin degrades at read.
2753
+ *
2754
+ * A node counter caps total AST size (`MAX_EXPRESSION_AST_NODES`) and call
2755
+ * arity is capped (`MAX_EXPRESSION_CALL_ARGS`) — both raise `ExpressionParseError`.
2756
+ */
2757
+ /** Binary/logical operator precedence (higher binds tighter). */
2758
+ var BINARY_PRECEDENCE = {
2759
+ "||": 1,
2760
+ "&&": 2,
2761
+ "==": 3,
2762
+ "!=": 3,
2763
+ "<": 4,
2764
+ "<=": 4,
2765
+ ">": 4,
2766
+ ">=": 4,
2767
+ "+": 5,
2768
+ "-": 5,
2769
+ "*": 6,
2770
+ "/": 6,
2771
+ "%": 6
2772
+ };
2773
+ function isLogicalOp(op) {
2774
+ return op === "&&" || op === "||";
2775
+ }
2776
+ function isBinaryOp(op) {
2777
+ return op === "+" || op === "-" || op === "*" || op === "/" || op === "%" || op === "==" || op === "!=" || op === "<" || op === "<=" || op === ">" || op === ">=";
2778
+ }
2779
+ var Parser = class {
2780
+ tokens;
2781
+ pos = 0;
2782
+ nodeCount = 0;
2783
+ identifiers = /* @__PURE__ */ new Set();
2784
+ callees = /* @__PURE__ */ new Set();
2785
+ constructor(tokens) {
2786
+ this.tokens = tokens;
2787
+ }
2788
+ parse() {
2789
+ const ast = this.parseTernary();
2790
+ const tok = this.peek();
2791
+ if (tok.type !== "eof") throw new ExpressionParseError("unexpected trailing input", tok.pos);
2792
+ return {
2793
+ ast,
2794
+ identifiers: this.identifiers,
2795
+ callees: this.callees,
2796
+ nodeCount: this.nodeCount
2797
+ };
2798
+ }
2799
+ peek() {
2800
+ return this.tokens[this.pos];
2801
+ }
2802
+ next() {
2803
+ return this.tokens[this.pos++];
2804
+ }
2805
+ /** Consume a punctuator token, erroring if the next token isn't it. */
2806
+ expectPunct(punct) {
2807
+ const tok = this.peek();
2808
+ if (tok.type !== "punct" || tok.punct !== punct) throw new ExpressionParseError(`expected '${punct}'`, tok.pos);
2809
+ this.pos += 1;
2810
+ }
2811
+ matchPunct(punct) {
2812
+ const tok = this.peek();
2813
+ if (tok.type === "punct" && tok.punct === punct) {
2814
+ this.pos += 1;
2815
+ return true;
2816
+ }
2817
+ return false;
2818
+ }
2819
+ countNode() {
2820
+ this.nodeCount += 1;
2821
+ if (this.nodeCount > 256) throw new ExpressionParseError("expression too complex", this.peek().pos);
2822
+ }
2823
+ parseTernary() {
2824
+ const test = this.parseBinary(1);
2825
+ if (this.matchPunct("?")) {
2826
+ const consequent = this.parseTernary();
2827
+ this.expectPunct(":");
2828
+ const alternate = this.parseTernary();
2829
+ this.countNode();
2830
+ return {
2831
+ kind: "conditional",
2832
+ test,
2833
+ consequent,
2834
+ alternate
2835
+ };
2836
+ }
2837
+ return test;
2838
+ }
2839
+ parseBinary(minPrec) {
2840
+ let left = this.parseUnary();
2841
+ for (;;) {
2842
+ const tok = this.peek();
2843
+ if (tok.type !== "punct") break;
2844
+ const prec = BINARY_PRECEDENCE[tok.punct];
2845
+ if (prec === void 0 || prec < minPrec) break;
2846
+ const op = tok.punct;
2847
+ this.pos += 1;
2848
+ const right = this.parseBinary(prec + 1);
2849
+ this.countNode();
2850
+ if (isLogicalOp(op)) left = {
2851
+ kind: "logical",
2852
+ op,
2853
+ left,
2854
+ right
2855
+ };
2856
+ else if (isBinaryOp(op)) left = {
2857
+ kind: "binary",
2858
+ op,
2859
+ left,
2860
+ right
2861
+ };
2862
+ else throw new ExpressionParseError(`unexpected operator '${op}'`, tok.pos);
2863
+ }
2864
+ return left;
2865
+ }
2866
+ parseUnary() {
2867
+ const tok = this.peek();
2868
+ if (tok.type === "punct" && (tok.punct === "!" || tok.punct === "-")) {
2869
+ const op = tok.punct;
2870
+ this.pos += 1;
2871
+ const operand = this.parseUnary();
2872
+ this.countNode();
2873
+ return {
2874
+ kind: "unary",
2875
+ op,
2876
+ operand
2877
+ };
2878
+ }
2879
+ return this.parsePrimary();
2880
+ }
2881
+ parsePrimary() {
2882
+ const tok = this.next();
2883
+ switch (tok.type) {
2884
+ case "number":
2885
+ this.countNode();
2886
+ return {
2887
+ kind: "literal",
2888
+ value: tok.value
2889
+ };
2890
+ case "string":
2891
+ this.countNode();
2892
+ return {
2893
+ kind: "literal",
2894
+ value: tok.value
2895
+ };
2896
+ case "keyword":
2897
+ this.countNode();
2898
+ return {
2899
+ kind: "literal",
2900
+ value: tok.keyword === "null" ? null : tok.keyword === "true"
2901
+ };
2902
+ case "identifier": {
2903
+ const nextTok = this.peek();
2904
+ if (nextTok.type === "punct" && nextTok.punct === "(") return this.parseCall(tok.name, tok.pos);
2905
+ this.identifiers.add(tok.name);
2906
+ this.countNode();
2907
+ return {
2908
+ kind: "identifier",
2909
+ name: tok.name
2910
+ };
2911
+ }
2912
+ case "punct":
2913
+ if (tok.punct === "(") {
2914
+ const inner = this.parseTernary();
2915
+ this.expectPunct(")");
2916
+ return inner;
2917
+ }
2918
+ throw new ExpressionParseError(`unexpected token '${tok.punct}'`, tok.pos);
2919
+ case "eof": throw new ExpressionParseError("unexpected end of expression", tok.pos);
2920
+ }
2921
+ }
2922
+ parseCall(callee, pos) {
2923
+ if (!EXPRESSION_BUILTIN_NAMES.has(callee)) throw new ExpressionParseError(`unknown function '${callee}'`, pos);
2924
+ this.expectPunct("(");
2925
+ const args = [];
2926
+ if (!this.matchPunct(")")) for (;;) {
2927
+ args.push(this.parseTernary());
2928
+ if (args.length > 16) throw new ExpressionParseError(`too many arguments to '${callee}'`, pos);
2929
+ if (this.matchPunct(",")) continue;
2930
+ this.expectPunct(")");
2931
+ break;
2932
+ }
2933
+ this.callees.add(callee);
2934
+ this.countNode();
2935
+ return {
2936
+ kind: "call",
2937
+ callee,
2938
+ args
2939
+ };
2940
+ }
2941
+ };
2942
+ /** Tokenize + parse `source` into a validated `ParsedExpression`. Throws
2943
+ * `ExpressionParseError` on any lexical or grammatical failure. */
2944
+ function parseExpression(source) {
2945
+ return new Parser(tokenize(source)).parse();
2946
+ }
2947
+ //#endregion
2948
+ //#region src/expression/evaluator.ts
2949
+ /**
2950
+ * Tree-walking evaluator for the safe expression mini-language.
2951
+ *
2952
+ * SECURITY (spec §4 rule 2/5):
2953
+ * - The scope is an `Object.create(null)` copy of ONLY the caller's own
2954
+ * enumerable binding entries, so `name in scope` is a pure own-key check and
2955
+ * `constructor` / `__proto__` / `toString` are plain unknown identifiers.
2956
+ * - Performs ZERO I/O and never touches `globalThis` / `Date` / `Math`
2957
+ * directly — the only external calls are into the frozen builtin table.
2958
+ * - The grammar has no loops/recursion/lambdas, so a walk is O(nodeCount) by
2959
+ * construction; the step counter is defense-in-depth for a crafted max-size
2960
+ * AST. Nothing blocks: there are no timers, awaits or unbounded loops.
2961
+ */
2962
+ var EMPTY_HOOKS = Object.freeze({});
2963
+ /** Build a null-prototype scope from own-enumerable binding entries. Inherited
2964
+ * keys of the input (e.g. from a `{__proto__: {...}}` payload) are NOT copied,
2965
+ * so nothing smuggles in via the prototype chain. */
2966
+ function createExpressionScope(bindings) {
2967
+ const scope = Object.create(null);
2968
+ for (const key of Object.keys(bindings)) if (Object.prototype.hasOwnProperty.call(bindings, key)) scope[key] = bindings[key];
2969
+ return scope;
2970
+ }
2971
+ function isFiniteNumber(value) {
2972
+ return typeof value === "number" && Number.isFinite(value);
2973
+ }
2974
+ /** JS truthiness of a primitive value. */
2975
+ function truthy(value) {
2976
+ return Boolean(value);
2977
+ }
2978
+ function requireFinite(value, context) {
2979
+ if (!Number.isFinite(value)) throw new ExpressionEvalError(`${context} produced a non-finite result`);
2980
+ return value;
2981
+ }
2982
+ function step(ctx) {
2983
+ ctx.steps += 1;
2984
+ if (ctx.steps > ctx.maxSteps) throw new ExpressionEvalError("expression evaluation step budget exceeded");
2985
+ }
2986
+ function evalNode(node, ctx) {
2987
+ step(ctx);
2988
+ switch (node.kind) {
2989
+ case "literal": return node.value;
2990
+ case "identifier":
2991
+ if (!(node.name in ctx.scope)) throw new ExpressionEvalError(`unknown identifier: ${node.name}`);
2992
+ return ctx.scope[node.name];
2993
+ case "unary": return evalUnary(node.op, evalNode(node.operand, ctx));
2994
+ case "binary": return evalBinary(node.op, evalNode(node.left, ctx), evalNode(node.right, ctx));
2995
+ case "logical": {
2996
+ const left = evalNode(node.left, ctx);
2997
+ if (node.op === "&&") return truthy(left) ? evalNode(node.right, ctx) : left;
2998
+ return truthy(left) ? left : evalNode(node.right, ctx);
2999
+ }
3000
+ case "conditional": return truthy(evalNode(node.test, ctx)) ? evalNode(node.consequent, ctx) : evalNode(node.alternate, ctx);
3001
+ case "call": return evalCall(node.callee, node.args.map((a) => evalNode(a, ctx)), ctx.hooks);
3002
+ }
3003
+ }
3004
+ function evalUnary(op, operand) {
3005
+ if (op === "!") return !truthy(operand);
3006
+ if (!isFiniteNumber(operand)) throw new ExpressionEvalError("unary \"-\" requires a finite number");
3007
+ return requireFinite(-operand, "unary \"-\"");
3008
+ }
3009
+ function evalBinary(op, left, right) {
3010
+ switch (op) {
3011
+ case "==": return left === right;
3012
+ case "!=": return left !== right;
3013
+ case "+":
3014
+ if (typeof left === "string" && typeof right === "string") return left + right;
3015
+ if (isFiniteNumber(left) && isFiniteNumber(right)) return requireFinite(left + right, "\"+\"");
3016
+ throw new ExpressionEvalError("\"+\" requires two numbers or two strings");
3017
+ case "-":
3018
+ case "*":
3019
+ case "/":
3020
+ case "%":
3021
+ if (!isFiniteNumber(left) || !isFiniteNumber(right)) throw new ExpressionEvalError(`"${op}" requires two finite numbers`);
3022
+ return requireFinite(op === "-" ? left - right : op === "*" ? left * right : op === "/" ? left / right : left % right, `"${op}"`);
3023
+ case "<":
3024
+ case "<=":
3025
+ case ">":
3026
+ case ">=":
3027
+ if (isFiniteNumber(left) && isFiniteNumber(right)) return op === "<" ? left < right : op === "<=" ? left <= right : op === ">" ? left > right : left >= right;
3028
+ if (typeof left === "string" && typeof right === "string") return op === "<" ? left < right : op === "<=" ? left <= right : op === ">" ? left > right : left >= right;
3029
+ throw new ExpressionEvalError(`"${op}" requires two numbers or two strings`);
3030
+ }
3031
+ }
3032
+ function evalCall(callee, args, hooks) {
3033
+ if (!Object.prototype.hasOwnProperty.call(EXPRESSION_BUILTINS, callee)) throw new ExpressionEvalError(`unknown function: ${callee}`);
3034
+ const builtin = EXPRESSION_BUILTINS[callee];
3035
+ if (args.length < builtin.minArgs || args.length > builtin.maxArgs) throw new ExpressionEvalError(`${callee}: wrong number of arguments (${args.length})`);
3036
+ return builtin.apply(args, hooks);
3037
+ }
3038
+ /** Evaluate an AST node against a scope. Throws `ExpressionEvalError` on any
3039
+ * runtime failure (unknown identifier, type mismatch, non-finite result,
3040
+ * step-budget exhaustion). */
3041
+ function evaluateAst(node, scope, opts) {
3042
+ return evalNode(node, {
3043
+ scope,
3044
+ hooks: opts?.hooks ?? EMPTY_HOOKS,
3045
+ maxSteps: opts?.maxSteps ?? 4096,
3046
+ steps: 0
3047
+ });
3048
+ }
3049
+ //#endregion
3050
+ //#region src/expression/compile.ts
3051
+ /**
3052
+ * LRU compile cache for parsed expressions (spec §2.4 "parse once … LRU keyed
3053
+ * by expr"). The cache stores BOTH successes and failures (negative caching),
3054
+ * so a corrupt persisted string costs exactly one tokenize+parse total — not
3055
+ * one per read on a hot resolve path.
3056
+ *
3057
+ * The cache is a module-level singleton: entries are pure, content-addressed
3058
+ * ASTs keyed by the raw source string, so sharing one instance across all
3059
+ * callers is safe and maximises hit rate.
3060
+ */
3061
+ var cache = /* @__PURE__ */ new Map();
3062
+ function getCached(source) {
3063
+ const hit = cache.get(source);
3064
+ if (hit !== void 0) {
3065
+ cache.delete(source);
3066
+ cache.set(source, hit);
3067
+ return hit;
3068
+ }
3069
+ let result;
3070
+ try {
3071
+ result = {
3072
+ ok: true,
3073
+ parsed: parseExpression(source)
3074
+ };
3075
+ } catch (err) {
3076
+ result = {
3077
+ ok: false,
3078
+ error: err instanceof ExpressionParseError ? err.message : String(err)
3079
+ };
3080
+ }
3081
+ cache.set(source, result);
3082
+ if (cache.size > 256) {
3083
+ const oldest = cache.keys().next().value;
3084
+ if (oldest !== void 0) cache.delete(oldest);
3085
+ }
3086
+ return result;
3087
+ }
3088
+ /** Compile `source` to a `ParsedExpression`, throwing `ExpressionParseError`
3089
+ * on failure. LRU/negative-cached. */
3090
+ function compileExpression(source) {
3091
+ const result = getCached(source);
3092
+ if (result.ok) return result.parsed;
3093
+ throw new ExpressionParseError(result.error);
3094
+ }
3095
+ /** Compile `source`, returning a discriminated result instead of throwing.
3096
+ * Used by read paths that must degrade rather than raise. LRU/negative-cached. */
3097
+ function compileExpressionSafe(source) {
3098
+ return getCached(source);
3099
+ }
3100
+ //#endregion
3101
+ //#region src/expression/link-expression.ts
3102
+ /**
3103
+ * DeviceLink-facing helpers for the expression engine — the single seam both
3104
+ * resolver channels (async provider-read + sync mirror) and the wire-schema
3105
+ * `superRefine` share, so validation and evaluation semantics stay identical
3106
+ * everywhere.
3107
+ */
3108
+ /** The `now` epoch-ms binding is auto-injected into every evaluation and is a
3109
+ * reserved binding name (authors may not rebind it). */
3110
+ var EXPRESSION_INJECTED_NOW = "now";
3111
+ /**
3112
+ * Coerce an untrusted `getByPath` / mirror read to an `ExpressionValue`.
3113
+ * Non-primitive values (objects, arrays, `undefined`, functions, bigint,
3114
+ * symbol) and non-finite numbers become `undefined` so the caller can apply
3115
+ * its binding-miss policy (→ `null`). `null` itself is a valid value.
3116
+ */
3117
+ function toExpressionValue(raw) {
3118
+ if (raw === null) return null;
3119
+ if (typeof raw === "string") return raw;
3120
+ if (typeof raw === "boolean") return raw;
3121
+ if (typeof raw === "number") return Number.isFinite(raw) ? raw : void 0;
3122
+ }
3123
+ /**
3124
+ * Author-time validation. Returns `null` when the source is valid, else a
3125
+ * human-readable error message. Checks: the expression compiles; binding count
3126
+ * is within `MAX_EXPRESSION_BINDINGS`; every binding name is a legal identifier,
3127
+ * is not reserved (`now`/keywords) and does not shadow a builtin; and every
3128
+ * FREE identifier of the AST is covered by a binding or the injected `now`.
3129
+ */
3130
+ function validateExpressionSource(src) {
3131
+ const names = Object.keys(src.bindings);
3132
+ if (names.length > 32) return `too many bindings (${names.length} > 32)`;
3133
+ for (const name of names) {
3134
+ if (!EXPRESSION_IDENTIFIER_RE.test(name)) return `invalid binding name '${name}'`;
3135
+ if (RESERVED_BINDING_NAMES.has(name)) return `binding name '${name}' is reserved`;
3136
+ if (EXPRESSION_BUILTIN_NAMES.has(name)) return `binding name '${name}' shadows a builtin function`;
3137
+ }
3138
+ const compiled = compileExpressionSafe(src.expr);
3139
+ if (!compiled.ok) return compiled.error;
3140
+ const bound = new Set(names);
3141
+ for (const id of compiled.parsed.identifiers) {
3142
+ if (id === "now") continue;
3143
+ if (!bound.has(id)) return `expression references unbound identifier '${id}'`;
3144
+ }
3145
+ return null;
3146
+ }
3147
+ /**
3148
+ * Shared read-path evaluation for BOTH resolver channels. Builds a null-proto
3149
+ * scope from `bindingValues` plus the injected `now` (supplied by the caller
3150
+ * for determinism/testability), compiles via the LRU, and evaluates. Any
3151
+ * failure (parse or eval) returns `{ ok: false }` — the caller treats that as
3152
+ * "skip this link".
3153
+ */
3154
+ function evaluateLinkExpression(expr, bindingValues, now, opts) {
3155
+ const compiled = compileExpressionSafe(expr);
3156
+ if (!compiled.ok) return {
3157
+ ok: false,
3158
+ error: compiled.error
3159
+ };
3160
+ const scope = createExpressionScope({
3161
+ ...bindingValues,
3162
+ ["now"]: now
3163
+ });
3164
+ try {
3165
+ return {
3166
+ ok: true,
3167
+ value: evaluateAst(compiled.parsed.ast, scope, opts)
3168
+ };
3169
+ } catch (err) {
3170
+ return {
3171
+ ok: false,
3172
+ error: err instanceof ExpressionEvalError ? err.message : String(err)
3173
+ };
3174
+ }
3175
+ }
3176
+ //#endregion
2396
3177
  //#region src/device/accessory.ts
2397
3178
  /**
2398
3179
  * Accessory device helpers — shared across drivers.
@@ -6177,7 +6958,8 @@ var motionDetectionCapability = {
6177
6958
  methods: {
6178
6959
  analyze: method(z.object({
6179
6960
  deviceId: z.number(),
6180
- frame: FrameInputSchema
6961
+ frame: FrameInputSchema.optional(),
6962
+ frameHandle: FrameHandleSchema.optional()
6181
6963
  }), MotionAnalysisResultSchema, { kind: "mutation" }),
6182
6964
  removeCamera: method(z.object({ deviceId: z.number() }), z.void(), { kind: "mutation" }),
6183
6965
  reset: method(z.void(), z.void(), { kind: "mutation" })
@@ -6495,11 +7277,20 @@ var pipelineExecutorCapability = {
6495
7277
  * legacy call shape used by existing benchmark code; once all
6496
7278
  * callers pass it explicitly we make it required.
6497
7279
  *
6498
- * Exactly one of `frame`, `imageBase64`, `referenceImage` must be
6499
- * provided:
7280
+ * Exactly one of `frame`, `frameHandle`, `imageBase64`,
7281
+ * `referenceImage` must be provided:
6500
7282
  * - `frame`: runtime dispatch path (runner → decoded broker frame).
6501
7283
  * Carries the raw buffer, dimensions, and format; the executor
6502
7284
  * uses it directly without base64 round-tripping.
7285
+ * - `frameHandle` (CB5): a zero-pixel shm `FrameHandle` for the SAME
7286
+ * decoded frame. Both runner and executor are hub-local processes
7287
+ * sharing `/dev/shm`, so the executor maps the named segment and
7288
+ * reads the pixels back zero-copy — eliminating the ~1.2MB
7289
+ * re-serialisation over UDS/MsgPack the `frame` path pays per call.
7290
+ * High-risk: the FrameRing is a latest-wins seqlock with no
7291
+ * refcount, so a recycled slot yields a null read; the executor
7292
+ * then degrades to an empty result and the runner ships pixels via
7293
+ * `frame` as the fallback (queue-depth gated on the runner side).
6503
7294
  * - `imageBase64`: one-shot test path (benchmark ImageTab).
6504
7295
  * - `referenceImage`: named file from the reference-image store.
6505
7296
  */
@@ -6507,6 +7298,12 @@ var pipelineExecutorCapability = {
6507
7298
  engine: PipelineEngineChoiceSchema.optional(),
6508
7299
  steps: z.array(PipelineStepInputSchema).min(1),
6509
7300
  frame: FrameInputSchema.optional(),
7301
+ /**
7302
+ * CB5 shm passthrough — a `FrameHandle` naming the same ring slot
7303
+ * the decoded pixels live in. One more member of the one-of
7304
+ * frame/frameHandle/image/imageBase64/referenceImage group.
7305
+ */
7306
+ frameHandle: FrameHandleSchema.optional(),
6510
7307
  imageBase64: z.string().optional(),
6511
7308
  /**
6512
7309
  * Binary JPEG bytes — preferred over `imageBase64` on internal
@@ -7670,6 +8467,191 @@ var numericSensorCapability = {
7670
8467
  runtimeState: NumericSensorStatusSchema
7671
8468
  };
7672
8469
  //#endregion
8470
+ //#region src/capabilities/pet-feeder.cap.ts
8471
+ /**
8472
+ * PetKit pet-feeder cap. Models the control + telemetry surface of a
8473
+ * cloud-connected smart feeder (Fresh Element / Mini / D3 / D4 / D4S
8474
+ * Gemini / D4H / D4SH) as a single coherent slice — bowl food level,
8475
+ * battery, desiccant life, feeding state + the four persisted settings
8476
+ * (child-lock / indicator-light / feed-sound / volume).
8477
+ *
8478
+ * Sources: native PetKit (`nodepetkit` `FeederDevice`). Reusable by any
8479
+ * feeder integration that speaks the same food/desiccant/hopper surface.
8480
+ *
8481
+ * `kind: 'poll'` — PetKit exposes only a cloud REST API (no push
8482
+ * channel), so the provider refreshes the slice on a poll interval and
8483
+ * eagerly after every command.
8484
+ *
8485
+ * Dual-hopper feeders (D4S/D4SH) split the bowl into two independent
8486
+ * hoppers. `isDualHopper` gates the two-hopper UI; `food1`/`food2` carry
8487
+ * the per-hopper levels (both `null` on single-hopper models, where
8488
+ * `foodLevel` is the single reading). The manual-feed portion honours the
8489
+ * PetKit hardware range 4–200 g in 1 g steps.
8490
+ *
8491
+ * Device status is exposed both raw and decoded, mirroring PetKit's HA
8492
+ * integration (RobertD502/py-petkit-api). `status` is the connectivity /
8493
+ * power enum (`normal` / `offline` / `on_batteries`); `error` is the
8494
+ * decoded human-readable fault message (null / `no_error` = healthy);
8495
+ * `errorCode` keeps the raw device integer (0 / null = no error) so a
8496
+ * provider that only has the numeric code stays lossless. A provider maps
8497
+ * the library's fields onto these; any it cannot determine stays `null`.
8498
+ */
8499
+ /** PetKit manual-feed portion bounds (grams). Mirrors the HA `manual_feed`
8500
+ * number entity (min 4, max 200, step 1, device_class weight). */
8501
+ var PET_FEEDER_MANUAL_FEED_MIN = 4;
8502
+ var PET_FEEDER_MANUAL_FEED_MAX = 200;
8503
+ /**
8504
+ * Feeder connectivity / power status — mirrors the HA petkit device-status
8505
+ * enum: `normal` (online, mains), `offline` (not reaching PetKit cloud),
8506
+ * `on_batteries` (running on battery backup). `null` until first reported.
8507
+ */
8508
+ var PetFeederDeviceStatusSchema = z.enum([
8509
+ "normal",
8510
+ "offline",
8511
+ "on_batteries"
8512
+ ]);
8513
+ var gramsPortion = z.number().int().min(4).max(200);
8514
+ var PetFeederStatusSchema = z.object({
8515
+ /** Food currently in the bowl (grams). Null when the device has not
8516
+ * reported a reading yet. On dual-hopper models this is the combined
8517
+ * bowl reading; per-hopper levels live in `food1`/`food2`. */
8518
+ foodLevel: z.number().nullable(),
8519
+ /** Hopper-1 food level (grams) on dual-hopper feeders; null on
8520
+ * single-hopper models. */
8521
+ food1: z.number().nullable(),
8522
+ /** Hopper-2 food level (grams) on dual-hopper feeders; null on
8523
+ * single-hopper models. */
8524
+ food2: z.number().nullable(),
8525
+ /** Derived low-food flag — mirrors the HA `food_level` binary_sensor
8526
+ * (`device_class: problem`, on = low). True when the bowl is empty /
8527
+ * below the feeder's low threshold. */
8528
+ lowFood: z.boolean(),
8529
+ /** Battery charge 0..100 (%). Null on mains-powered models or when the
8530
+ * device has no battery reading. */
8531
+ batteryPower: z.number().min(0).max(100).nullable(),
8532
+ /** Days of desiccant life remaining. Null when the model has no
8533
+ * desiccant sensor. */
8534
+ desiccantLeftDays: z.number().nullable(),
8535
+ /** True while a feed is in progress. */
8536
+ feeding: z.boolean(),
8537
+ /** Decoded connectivity / power status (HA petkit device-status enum).
8538
+ * Null until the device has reported a status. */
8539
+ status: PetFeederDeviceStatusSchema.nullable(),
8540
+ /** Decoded human-readable fault message. Null (or the device's `no_error`
8541
+ * sentinel) means healthy; a non-null string is an active fault. Pairs
8542
+ * with `errorCode` for consumers that want the raw integer. */
8543
+ error: z.string().nullable(),
8544
+ /** Raw device error code (0 / null = no error). */
8545
+ errorCode: z.number().nullable(),
8546
+ /** True for D4S/D4SH dual-hopper hardware — gates the per-hopper UI. */
8547
+ isDualHopper: z.boolean(),
8548
+ /** Child-lock (manual-lock) setting — buttons on the unit are disabled. */
8549
+ childLock: z.boolean(),
8550
+ /** Front indicator-light setting. */
8551
+ indicatorLight: z.boolean(),
8552
+ /** Play a chime when dispensing. */
8553
+ feedSound: z.boolean(),
8554
+ /** Speaker / prompt volume level (device-scaled integer). */
8555
+ volume: z.number(),
8556
+ /** Ms epoch when the slice was last refreshed from the cloud. */
8557
+ lastFetchedAt: z.number()
8558
+ });
8559
+ var petFeederCapability = {
8560
+ name: "pet-feeder",
8561
+ scope: "device",
8562
+ deviceNative: true,
8563
+ mode: "singleton",
8564
+ deviceTypes: [DeviceType.PetFeeder],
8565
+ methods: {
8566
+ /**
8567
+ * Dispense food now. Single-hopper feeders take `grams`; dual-hopper
8568
+ * feeders (D4S/D4SH) accept `hopper1`/`hopper2` to target one or both
8569
+ * hoppers. All portions honour the 4–200 g hardware range. At least
8570
+ * one of the three must be present — the provider rejects an empty
8571
+ * request.
8572
+ */
8573
+ feed: method(z.object({
8574
+ deviceId: z.number().int().nonnegative(),
8575
+ grams: gramsPortion.optional(),
8576
+ hopper1: gramsPortion.optional(),
8577
+ hopper2: gramsPortion.optional()
8578
+ }), z.void(), {
8579
+ kind: "mutation",
8580
+ auth: "admin"
8581
+ }),
8582
+ /** Cancel an in-progress manual feed. */
8583
+ cancelFeed: method(z.object({ deviceId: z.number().int().nonnegative() }), z.void(), {
8584
+ kind: "mutation",
8585
+ auth: "admin"
8586
+ }),
8587
+ /** Reset the desiccant "days remaining" counter after replacing it. */
8588
+ resetDesiccant: method(z.object({ deviceId: z.number().int().nonnegative() }), z.void(), {
8589
+ kind: "mutation",
8590
+ auth: "admin"
8591
+ }),
8592
+ /** Mark a hopper as refilled (D4H/D4S/D4SH). */
8593
+ markFoodReplenished: method(z.object({ deviceId: z.number().int().nonnegative() }), z.void(), {
8594
+ kind: "mutation",
8595
+ auth: "admin"
8596
+ }),
8597
+ /** Call the pet with the recorded prompt (D3). */
8598
+ callPet: method(z.object({ deviceId: z.number().int().nonnegative() }), z.void(), {
8599
+ kind: "mutation",
8600
+ auth: "admin"
8601
+ }),
8602
+ /** Play a stored sound by id (D3 / D4H / D4SH). */
8603
+ playSound: method(z.object({
8604
+ deviceId: z.number().int().nonnegative(),
8605
+ soundId: z.number().int().nonnegative()
8606
+ }), z.void(), {
8607
+ kind: "mutation",
8608
+ auth: "admin"
8609
+ }),
8610
+ /** Toggle the child-lock (manual-lock) setting. */
8611
+ setChildLock: method(z.object({
8612
+ deviceId: z.number().int().nonnegative(),
8613
+ on: z.boolean()
8614
+ }), z.void(), {
8615
+ kind: "mutation",
8616
+ auth: "admin"
8617
+ }),
8618
+ /** Toggle the front indicator light. */
8619
+ setIndicatorLight: method(z.object({
8620
+ deviceId: z.number().int().nonnegative(),
8621
+ on: z.boolean()
8622
+ }), z.void(), {
8623
+ kind: "mutation",
8624
+ auth: "admin"
8625
+ }),
8626
+ /** Toggle the dispense chime. */
8627
+ setFeedSound: method(z.object({
8628
+ deviceId: z.number().int().nonnegative(),
8629
+ on: z.boolean()
8630
+ }), z.void(), {
8631
+ kind: "mutation",
8632
+ auth: "admin"
8633
+ }),
8634
+ /** Set the speaker / prompt volume level. */
8635
+ setVolume: method(z.object({
8636
+ deviceId: z.number().int().nonnegative(),
8637
+ level: z.number().int().nonnegative()
8638
+ }), z.void(), {
8639
+ kind: "mutation",
8640
+ auth: "admin"
8641
+ })
8642
+ },
8643
+ status: {
8644
+ schema: PetFeederStatusSchema,
8645
+ kind: "poll"
8646
+ },
8647
+ /**
8648
+ * Runtime-state slice — mirrored by the kernel. UI feeder cards read
8649
+ * the full slice via `device.state.petFeeder.value` and refresh on
8650
+ * every poll without re-querying the provider.
8651
+ */
8652
+ runtimeState: PetFeederStatusSchema
8653
+ };
8654
+ //#endregion
7673
8655
  //#region src/capabilities/power-meter.cap.ts
7674
8656
  /**
7675
8657
  * Multi-metric electrical meter. One slice can carry any combination
@@ -9126,6 +10108,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
9126
10108
  nativeObjectDetection: nativeObjectDetectionCapability,
9127
10109
  notifier: notifierCapability,
9128
10110
  numericSensor: numericSensorCapability,
10111
+ petFeeder: petFeederCapability,
9129
10112
  powerMeter: powerMeterCapability,
9130
10113
  presence: presenceCapability,
9131
10114
  pressureSensor: pressureSensorCapability,
@@ -9632,6 +10615,334 @@ var BaseDevice = class {
9632
10615
  }
9633
10616
  };
9634
10617
  //#endregion
10618
+ //#region src/units/unit-table.ts
10619
+ /**
10620
+ * Frozen unit → spec table. `•` in the doc marks each dimension's canonical
10621
+ * unit (`factor: 1, offset: 0`). °F derives from `°C = (°F − 32) × 5/9` ⇒
10622
+ * `factor = 5/9`, `offset = -160/9` (kept as exact expressions, not rounded
10623
+ * decimals). K derives from `°C = K − 273.15`.
10624
+ */
10625
+ var UNIT_TABLE = {
10626
+ "°C": {
10627
+ dimension: "temperature",
10628
+ factor: 1,
10629
+ offset: 0
10630
+ },
10631
+ "°F": {
10632
+ dimension: "temperature",
10633
+ factor: 5 / 9,
10634
+ offset: -160 / 9
10635
+ },
10636
+ K: {
10637
+ dimension: "temperature",
10638
+ factor: 1,
10639
+ offset: -273.15
10640
+ },
10641
+ hPa: {
10642
+ dimension: "pressure",
10643
+ factor: 1,
10644
+ offset: 0
10645
+ },
10646
+ kPa: {
10647
+ dimension: "pressure",
10648
+ factor: 10,
10649
+ offset: 0
10650
+ },
10651
+ Pa: {
10652
+ dimension: "pressure",
10653
+ factor: .01,
10654
+ offset: 0
10655
+ },
10656
+ mbar: {
10657
+ dimension: "pressure",
10658
+ factor: 1,
10659
+ offset: 0
10660
+ },
10661
+ bar: {
10662
+ dimension: "pressure",
10663
+ factor: 1e3,
10664
+ offset: 0
10665
+ },
10666
+ inHg: {
10667
+ dimension: "pressure",
10668
+ factor: 33.8639,
10669
+ offset: 0
10670
+ },
10671
+ mmHg: {
10672
+ dimension: "pressure",
10673
+ factor: 1.33322,
10674
+ offset: 0
10675
+ },
10676
+ psi: {
10677
+ dimension: "pressure",
10678
+ factor: 68.9476,
10679
+ offset: 0
10680
+ },
10681
+ "m/s": {
10682
+ dimension: "speed",
10683
+ factor: 1,
10684
+ offset: 0
10685
+ },
10686
+ "km/h": {
10687
+ dimension: "speed",
10688
+ factor: 1 / 3.6,
10689
+ offset: 0
10690
+ },
10691
+ mph: {
10692
+ dimension: "speed",
10693
+ factor: .44704,
10694
+ offset: 0
10695
+ },
10696
+ kn: {
10697
+ dimension: "speed",
10698
+ factor: .514444,
10699
+ offset: 0
10700
+ },
10701
+ "mm/h": {
10702
+ dimension: "precipitation-rate",
10703
+ factor: 1,
10704
+ offset: 0
10705
+ },
10706
+ "in/h": {
10707
+ dimension: "precipitation-rate",
10708
+ factor: 25.4,
10709
+ offset: 0
10710
+ },
10711
+ m: {
10712
+ dimension: "length",
10713
+ factor: 1,
10714
+ offset: 0
10715
+ },
10716
+ mm: {
10717
+ dimension: "length",
10718
+ factor: .001,
10719
+ offset: 0
10720
+ },
10721
+ cm: {
10722
+ dimension: "length",
10723
+ factor: .01,
10724
+ offset: 0
10725
+ },
10726
+ km: {
10727
+ dimension: "length",
10728
+ factor: 1e3,
10729
+ offset: 0
10730
+ },
10731
+ in: {
10732
+ dimension: "length",
10733
+ factor: .0254,
10734
+ offset: 0
10735
+ },
10736
+ ft: {
10737
+ dimension: "length",
10738
+ factor: .3048,
10739
+ offset: 0
10740
+ },
10741
+ mi: {
10742
+ dimension: "length",
10743
+ factor: 1609.344,
10744
+ offset: 0
10745
+ },
10746
+ lx: {
10747
+ dimension: "illuminance",
10748
+ factor: 1,
10749
+ offset: 0
10750
+ },
10751
+ "W/m²": {
10752
+ dimension: "irradiance",
10753
+ factor: 1,
10754
+ offset: 0
10755
+ },
10756
+ W: {
10757
+ dimension: "power",
10758
+ factor: 1,
10759
+ offset: 0
10760
+ },
10761
+ kW: {
10762
+ dimension: "power",
10763
+ factor: 1e3,
10764
+ offset: 0
10765
+ },
10766
+ VA: {
10767
+ dimension: "apparent-power",
10768
+ factor: 1,
10769
+ offset: 0
10770
+ },
10771
+ Wh: {
10772
+ dimension: "energy",
10773
+ factor: 1,
10774
+ offset: 0
10775
+ },
10776
+ kWh: {
10777
+ dimension: "energy",
10778
+ factor: 1e3,
10779
+ offset: 0
10780
+ },
10781
+ MWh: {
10782
+ dimension: "energy",
10783
+ factor: 1e6,
10784
+ offset: 0
10785
+ },
10786
+ V: {
10787
+ dimension: "voltage",
10788
+ factor: 1,
10789
+ offset: 0
10790
+ },
10791
+ mV: {
10792
+ dimension: "voltage",
10793
+ factor: .001,
10794
+ offset: 0
10795
+ },
10796
+ A: {
10797
+ dimension: "current",
10798
+ factor: 1,
10799
+ offset: 0
10800
+ },
10801
+ mA: {
10802
+ dimension: "current",
10803
+ factor: .001,
10804
+ offset: 0
10805
+ },
10806
+ ppm: {
10807
+ dimension: "concentration-volume",
10808
+ factor: 1,
10809
+ offset: 0
10810
+ },
10811
+ ppb: {
10812
+ dimension: "concentration-volume",
10813
+ factor: .001,
10814
+ offset: 0
10815
+ },
10816
+ "µg/m³": {
10817
+ dimension: "concentration-mass",
10818
+ factor: 1,
10819
+ offset: 0
10820
+ },
10821
+ "mg/m³": {
10822
+ dimension: "concentration-mass",
10823
+ factor: 1e3,
10824
+ offset: 0
10825
+ },
10826
+ kg: {
10827
+ dimension: "mass",
10828
+ factor: 1,
10829
+ offset: 0
10830
+ },
10831
+ g: {
10832
+ dimension: "mass",
10833
+ factor: .001,
10834
+ offset: 0
10835
+ },
10836
+ lb: {
10837
+ dimension: "mass",
10838
+ factor: .453592,
10839
+ offset: 0
10840
+ },
10841
+ oz: {
10842
+ dimension: "mass",
10843
+ factor: .0283495,
10844
+ offset: 0
10845
+ },
10846
+ "%": {
10847
+ dimension: "percentage",
10848
+ factor: 1,
10849
+ offset: 0
10850
+ }
10851
+ };
10852
+ //#endregion
10853
+ //#region src/units/convert.ts
10854
+ /**
10855
+ * Pure unit-conversion API over `UNIT_TABLE`. No dependencies, no side effects.
10856
+ *
10857
+ * Conversion is refused (throws `UnitConversionError`, or returns `undefined`
10858
+ * from the `try*` variant) whenever a unit is unknown or the two units belong
10859
+ * to different dimensions — cross-dimension conversion is deliberately
10860
+ * impossible so a render override can never make the value and its unit label
10861
+ * disagree.
10862
+ *
10863
+ * Callers pass units through `normalizeUnit` (`../device/source-info.ts`) BEFORE
10864
+ * calling here — the table keys only canonical spellings.
10865
+ */
10866
+ /** Thrown by `convertUnit` when a conversion is refused. Carries the offending
10867
+ * units + a machine-readable `reason` for callers that branch on the cause. */
10868
+ var UnitConversionError = class extends Error {
10869
+ from;
10870
+ to;
10871
+ reason;
10872
+ constructor(from, to, reason) {
10873
+ super(`[units] cannot convert '${from}' → '${to}': ${reason}`);
10874
+ this.name = "UnitConversionError";
10875
+ this.from = from;
10876
+ this.to = to;
10877
+ this.reason = reason;
10878
+ }
10879
+ };
10880
+ /** Resolve a unit's `UnitSpec`, or `undefined` when the spelling is unknown. */
10881
+ function specFor(unit) {
10882
+ return Object.hasOwn(UNIT_TABLE, unit) ? UNIT_TABLE[unit] : void 0;
10883
+ }
10884
+ /** The dimension a unit belongs to, or `undefined` for an unknown unit. */
10885
+ function unitDimension(unit) {
10886
+ return specFor(unit)?.dimension;
10887
+ }
10888
+ /** Value in `spec`'s unit → its dimension's canonical unit. */
10889
+ function toCanonical(value, spec) {
10890
+ return value * spec.factor + spec.offset;
10891
+ }
10892
+ /** Canonical-unit value → the unit described by `spec`. */
10893
+ function fromCanonical(canonical, spec) {
10894
+ return (canonical - spec.offset) / spec.factor;
10895
+ }
10896
+ /**
10897
+ * Convert `value` from unit `from` to unit `to`. Identity when `from === to`.
10898
+ * Throws `UnitConversionError` when either unit is unknown or the units belong
10899
+ * to different dimensions.
10900
+ */
10901
+ function convertUnit(value, from, to) {
10902
+ if (from === to) return value;
10903
+ const fromSpec = specFor(from);
10904
+ if (!fromSpec) throw new UnitConversionError(from, to, "unknown-from");
10905
+ const toSpec = specFor(to);
10906
+ if (!toSpec) throw new UnitConversionError(from, to, "unknown-to");
10907
+ if (fromSpec.dimension !== toSpec.dimension) throw new UnitConversionError(from, to, "cross-dimension");
10908
+ return fromCanonical(toCanonical(value, fromSpec), toSpec);
10909
+ }
10910
+ /**
10911
+ * Graceful variant for the render path: returns the converted value, or
10912
+ * `undefined` when the conversion is refused (unknown unit / cross-dimension).
10913
+ * Never throws — a render caller falls back to the raw value + source unit.
10914
+ */
10915
+ function tryConvertUnit(value, from, to) {
10916
+ if (from === to) return value;
10917
+ const fromSpec = specFor(from);
10918
+ if (!fromSpec) return void 0;
10919
+ const toSpec = specFor(to);
10920
+ if (!toSpec) return void 0;
10921
+ if (fromSpec.dimension !== toSpec.dimension) return void 0;
10922
+ return fromCanonical(toCanonical(value, fromSpec), toSpec);
10923
+ }
10924
+ /**
10925
+ * Whether `value` can be converted between `from` and `to` (same dimension,
10926
+ * both known). Cheap boolean probe for the UI's same-dimension unit picker and
10927
+ * the resolver's convertibility branch — compute ONCE so a unit label and its
10928
+ * value math can never disagree.
10929
+ */
10930
+ function canConvertUnit(from, to) {
10931
+ if (from === to) return true;
10932
+ const fromDim = unitDimension(from);
10933
+ if (fromDim === void 0) return false;
10934
+ return fromDim === unitDimension(to);
10935
+ }
10936
+ /**
10937
+ * Every known unit spelling in a dimension (table insertion order — canonical
10938
+ * unit first). Powers the UI's same-dimension unit picker.
10939
+ */
10940
+ function unitsForDimension(dimension) {
10941
+ const out = [];
10942
+ for (const [unit, spec] of Object.entries(UNIT_TABLE)) if (spec.dimension === dimension) out.push(unit);
10943
+ return out;
10944
+ }
10945
+ //#endregion
9635
10946
  //#region src/capabilities/device-provider.cap.ts
9636
10947
  var ProviderStatusSchema = z.object({
9637
10948
  connected: z.boolean(),
@@ -10490,6 +11801,8 @@ function createSystemProxy(api) {
10490
11801
  registerDevice: (input) => dispatch("deviceManager", "registerDevice", "mutation", input),
10491
11802
  removeDevice: (input) => dispatch("deviceManager", "removeDevice", "mutation", input),
10492
11803
  persistConfig: (input) => dispatch("deviceManager", "persistConfig", "mutation", input),
11804
+ getRoleDisplayDefaults: (input) => dispatch("deviceManager", "getRoleDisplayDefaults", "query", input),
11805
+ setRoleDisplayDefaults: (input) => dispatch("deviceManager", "setRoleDisplayDefaults", "mutation", input),
10493
11806
  listLocations: (input) => dispatch("deviceManager", "listLocations", "query", input),
10494
11807
  addLocation: (input) => dispatch("deviceManager", "addLocation", "mutation", input),
10495
11808
  removeLocation: (input) => dispatch("deviceManager", "removeLocation", "mutation", input),
@@ -12965,11 +14278,13 @@ var decoderCapability = {
12965
14278
  }), z.void()),
12966
14279
  pullFrames: method(z.object({
12967
14280
  sessionId: z.string(),
12968
- maxCount: z.number().default(1)
14281
+ maxCount: z.number().default(1),
14282
+ waitMs: z.number().optional()
12969
14283
  }), z.array(DecodedFrameSchema)),
12970
14284
  pullHandles: method(z.object({
12971
14285
  sessionId: z.string(),
12972
- maxCount: z.number().default(1)
14286
+ maxCount: z.number().default(1),
14287
+ waitMs: z.number().optional()
12973
14288
  }), z.array(FrameHandleSchema)),
12974
14289
  getFrame: method(z.object({ handle: FrameHandleSchema }), DecodedFrameSchema.nullable()),
12975
14290
  getShmStats: method(z.object({ sessionId: z.string() }), ShmRingStatsSchema.nullable()),
@@ -13362,30 +14677,57 @@ var ChildLayoutEntrySchema = z.object({
13362
14677
  * LITERAL source carries a per-device constant (no sibling is read); a
13363
14678
  * GLOBAL source (P2e) copies ANY device's status field, addressed by the
13364
14679
  * source device's full re-sync-stable `stableId`. */
14680
+ var DeviceLinkFieldSourceSchema = z.object({
14681
+ kind: z.literal("field").optional(),
14682
+ sourceKey: z.string(),
14683
+ cap: z.string(),
14684
+ fieldPath: z.string()
14685
+ });
14686
+ var DeviceLinkLiteralSourceSchema = z.object({
14687
+ kind: z.literal("literal"),
14688
+ value: z.union([
14689
+ z.string(),
14690
+ z.number(),
14691
+ z.boolean(),
14692
+ z.null()
14693
+ ])
14694
+ });
14695
+ var DeviceLinkGlobalSourceSchema = z.object({
14696
+ kind: z.literal("global"),
14697
+ sourceStableId: z.string(),
14698
+ cap: z.string(),
14699
+ fieldPath: z.string()
14700
+ });
14701
+ /** Expression source (Stage X): compute the target field from N named bindings
14702
+ * via the safe expression engine. Bindings are field | literal | global — never
14703
+ * another expression (no nesting). The `superRefine` runs the SAME author-time
14704
+ * validation as `validateExpressionSource` (compiles the expr, checks binding
14705
+ * names + identifier coverage) so every wire boundary that parses a DeviceLink
14706
+ * (tRPC mount, kernel create pre-seed, projection output) validates-at-write.
14707
+ * Compiles are LRU-cached, so repeated validation of the same expr is a hit. */
14708
+ var DeviceLinkExpressionSourceSchema = z.object({
14709
+ kind: z.literal("expression"),
14710
+ expr: z.string().min(1).max(MAX_EXPRESSION_SOURCE_LENGTH),
14711
+ bindings: z.record(z.string().regex(EXPRESSION_IDENTIFIER_RE), z.union([
14712
+ DeviceLinkFieldSourceSchema,
14713
+ DeviceLinkLiteralSourceSchema,
14714
+ DeviceLinkGlobalSourceSchema
14715
+ ]))
14716
+ }).superRefine((src, ctx) => {
14717
+ const err = validateExpressionSource(src);
14718
+ if (err !== null) ctx.addIssue({
14719
+ code: "custom",
14720
+ message: err,
14721
+ path: ["expr"]
14722
+ });
14723
+ });
13365
14724
  var DeviceLinkSchema = z.object({
13366
14725
  id: z.string(),
13367
14726
  source: z.union([
13368
- z.object({
13369
- kind: z.literal("field").optional(),
13370
- sourceKey: z.string(),
13371
- cap: z.string(),
13372
- fieldPath: z.string()
13373
- }),
13374
- z.object({
13375
- kind: z.literal("literal"),
13376
- value: z.union([
13377
- z.string(),
13378
- z.number(),
13379
- z.boolean(),
13380
- z.null()
13381
- ])
13382
- }),
13383
- z.object({
13384
- kind: z.literal("global"),
13385
- sourceStableId: z.string(),
13386
- cap: z.string(),
13387
- fieldPath: z.string()
13388
- })
14727
+ DeviceLinkFieldSourceSchema,
14728
+ DeviceLinkLiteralSourceSchema,
14729
+ DeviceLinkGlobalSourceSchema,
14730
+ DeviceLinkExpressionSourceSchema
13389
14731
  ]),
13390
14732
  target: z.object({
13391
14733
  cap: z.string(),
@@ -13415,6 +14757,31 @@ var DeviceLinkSchema = z.object({
13415
14757
  })
13416
14758
  ]).optional()
13417
14759
  });
14760
+ /** Cap-wire shape of a per-cap display refinement — mirrors
14761
+ * `DeviceCapDisplayOverride` in `device-management.ts`. */
14762
+ var DeviceCapDisplayOverrideSchema = z.object({
14763
+ unit: z.string().min(1).optional(),
14764
+ precision: z.number().int().min(0).max(10).optional()
14765
+ });
14766
+ /** Cap-wire shape of an operator-authored per-device display override —
14767
+ * mirrors `DeviceDisplayOverride` in `device-management.ts`. `precision`
14768
+ * bounds mirror `numeric-sensor.cap.ts` (`int 0-10`). */
14769
+ var DeviceDisplayOverrideSchema = z.object({
14770
+ icon: z.string().min(1).optional(),
14771
+ label: z.string().min(1).optional(),
14772
+ unit: z.string().min(1).optional(),
14773
+ precision: z.number().int().min(0).max(10).optional(),
14774
+ hidden: z.boolean().optional(),
14775
+ perCap: z.record(z.string(), DeviceCapDisplayOverrideSchema).optional()
14776
+ });
14777
+ /** Cap-wire shape of a per-role display default — mirrors `RoleDisplayDefault`
14778
+ * in `device-management.ts`. Keyed by `DeviceRole` string (role strings cross
14779
+ * the wire as plain strings everywhere else — cf. `DeviceInfoSchema.role`). */
14780
+ var RoleDisplayDefaultSchema = z.object({
14781
+ unit: z.string().min(1).optional(),
14782
+ precision: z.number().int().min(0).max(10).optional(),
14783
+ icon: z.string().min(1).optional()
14784
+ });
13418
14785
  /**
13419
14786
  * Serializable projection of a live IDevice.
13420
14787
  * Returned by listAll, getDevice, getChildren.
@@ -13470,7 +14837,9 @@ var DeviceInfoSchema = z.object({
13470
14837
  * `DeviceMeta.childLayout`. Absent ⇒ no layout declared. */
13471
14838
  childLayout: z.array(ChildLayoutEntrySchema).readonly().optional(),
13472
14839
  /** Operator-authored cross-device field wirings. See `DeviceMeta.deviceLinks`. */
13473
- deviceLinks: z.array(DeviceLinkSchema).readonly().optional()
14840
+ deviceLinks: z.array(DeviceLinkSchema).readonly().optional(),
14841
+ /** Operator-authored per-device display override. See `DeviceMeta.display`. */
14842
+ display: DeviceDisplayOverrideSchema.optional()
13474
14843
  });
13475
14844
  var ConfigEntrySchema = z.object({
13476
14845
  key: z.string(),
@@ -13535,7 +14904,9 @@ var DeviceMetaSchema = z.object({
13535
14904
  deviceLinks: z.array(DeviceLinkSchema).readonly().optional(),
13536
14905
  /** Semantic role string (`DeviceRole`) — propagated from the spawn pre-seed.
13537
14906
  * Optional: only present for accessory children that carry a known role. */
13538
- role: z.string().nullable().optional()
14907
+ role: z.string().nullable().optional(),
14908
+ /** Operator-authored per-device display override. See `DeviceMeta.display`. */
14909
+ display: DeviceDisplayOverrideSchema.optional()
13539
14910
  });
13540
14911
  /** ConfigUISchema passed through as unknown — mirrors device-provider's CreationSchemaOutputSchema */
13541
14912
  var ConfigUISchemaOutput = z.unknown().nullable();
@@ -13691,6 +15062,29 @@ var deviceManagerCapability = {
13691
15062
  kind: "mutation",
13692
15063
  auth: "admin"
13693
15064
  }),
15065
+ /** Set (or clear) the per-device display override on the meta row. Mirrors
15066
+ * `setChildLayout` persistence; `null` clears the override entirely. The
15067
+ * override unit(s) are normalized (`normalizeUnit`) at write so the render
15068
+ * path's `UNIT_TABLE` lookups always hit canonical spellings. Persisted,
15069
+ * projected, and preserved across re-register/restore. Idempotent. */
15070
+ setDisplay: method(z.object({
15071
+ deviceId: z.number(),
15072
+ display: DeviceDisplayOverrideSchema.nullable()
15073
+ }), z.void(), {
15074
+ kind: "mutation",
15075
+ auth: "admin"
15076
+ }),
15077
+ /** Read the operator-authored per-role display defaults (unit/precision/
15078
+ * icon), keyed by `DeviceRole` string. Empty record when none set. */
15079
+ getRoleDisplayDefaults: method(z.object({}), z.object({ defaults: z.record(z.string(), RoleDisplayDefaultSchema) }), { kind: "query" }),
15080
+ /** Replace the per-role display defaults whole-record (full replace — the
15081
+ * caller sends the complete map). Override unit(s) are normalized at write.
15082
+ * Not per-device, so nothing is emitted; the UI invalidates its own query
15083
+ * on mutate. */
15084
+ setRoleDisplayDefaults: method(z.object({ defaults: z.record(z.string(), RoleDisplayDefaultSchema) }), z.void(), {
15085
+ kind: "mutation",
15086
+ auth: "admin"
15087
+ }),
13694
15088
  /** List the wireable status-schema fields per cap bound to a device.
13695
15089
  * Powers the Wiring tab's field pickers. Caps without a status schema are
13696
15090
  * omitted. Item-array caps (`status.itemArray`, e.g. consumables) also
@@ -15784,7 +17178,10 @@ var pipelineOrchestratorCapability = {
15784
17178
  methods: {
15785
17179
  /**
15786
17180
  * Pin a camera's pipeline to a specific agent (L1 affinity).
15787
- * The orchestrator re-evaluates the assignment immediately.
17181
+ * The orchestrator re-evaluates the assignment immediately and persists
17182
+ * the pin under the canonical `pipelineNodeId` device-store key (the
17183
+ * legacy `preferredAgent` key is nulled on write and kept only as a
17184
+ * read-only fallback for stores written before the unification).
15788
17185
  */
15789
17186
  assignPipeline: method(z.object({
15790
17187
  deviceId: z.number(),
@@ -15795,8 +17192,9 @@ var pipelineOrchestratorCapability = {
15795
17192
  }),
15796
17193
  /**
15797
17194
  * Clear a camera's pipeline pin and let the auto-balancer re-pick
15798
- * the optimal agent. The orchestrator persists `preferredAgent=null`
15799
- * (and `pipelineNodeId='auto'`), then re-runs the balancer with the
17195
+ * the optimal agent. The orchestrator persists the canonical
17196
+ * `pipelineNodeId='auto'` (and nulls the legacy `preferredAgent`),
17197
+ * then re-runs the balancer with the
15800
17198
  * cached `RunnerCameraConfig` and migrates only when the chosen
15801
17199
  * node differs. The camera stays in `getPipelineAssignments()` —
15802
17200
  * just with `pinned=false`. If no runner is currently available
@@ -19414,7 +20812,10 @@ var HwAccelBackendInputSchema = z.enum([
19414
20812
  "webgpu",
19415
20813
  "none"
19416
20814
  ]).nullable().optional();
19417
- var HwAccelResolutionSchema = z.object({ preferred: z.array(z.string()).readonly() });
20815
+ var HwAccelResolutionSchema = z.object({
20816
+ preferred: z.array(z.string()).readonly(),
20817
+ rationale: z.string()
20818
+ });
19418
20819
  var HardwareEncoderIdSchema = z.enum([
19419
20820
  "h264_videotoolbox",
19420
20821
  "hevc_videotoolbox",
@@ -19528,10 +20929,7 @@ var platformProbeCapability = {
19528
20929
  getCapabilities: method(z.void(), PlatformCapabilitiesSchema),
19529
20930
  getHardware: method(z.void(), HardwareInfoSchema),
19530
20931
  resolveInferenceConfig: method(z.object({ requirements: z.array(ModelRequirementSchema).readonly() }), ResolvedInferenceConfigSchema),
19531
- resolveHwAccel: method(z.object({
19532
- prefer: HwAccelBackendInputSchema,
19533
- nodeId: z.string().optional()
19534
- }), HwAccelResolutionSchema),
20932
+ resolveHwAccel: method(z.object({ prefer: HwAccelBackendInputSchema }), HwAccelResolutionSchema),
19535
20933
  /**
19536
20934
  * Hardware-encoder probe — see Task #185. Cached after first call.
19537
20935
  */
@@ -20633,6 +22031,7 @@ var CAPABILITY_NAMES = {
20633
22031
  numericSensor: "numeric-sensor",
20634
22032
  oauthIntegration: "oauth-integration",
20635
22033
  osd: "osd",
22034
+ petFeeder: "pet-feeder",
20636
22035
  pipelineAnalytics: "pipeline-analytics",
20637
22036
  pipelineExecutor: "pipeline-executor",
20638
22037
  pipelineOrchestrator: "pipeline-orchestrator",
@@ -21033,6 +22432,10 @@ var CAPABILITY_ROUTER_KEYS = [
21033
22432
  key: "osd",
21034
22433
  name: "osd"
21035
22434
  },
22435
+ {
22436
+ key: "petFeeder",
22437
+ name: "pet-feeder"
22438
+ },
21036
22439
  {
21037
22440
  key: "pipelineAnalytics",
21038
22441
  name: "pipeline-analytics"
@@ -21327,6 +22730,7 @@ var ALL_CAPABILITY_DEFINITIONS = [
21327
22730
  numericSensorCapability,
21328
22731
  oauthIntegrationCapability,
21329
22732
  osdCapability,
22733
+ petFeederCapability,
21330
22734
  pipelineAnalyticsCapability,
21331
22735
  pipelineExecutorCapability,
21332
22736
  pipelineOrchestratorCapability,
@@ -21429,6 +22833,7 @@ var CAP_NAMES_WITH_STATUS = [
21429
22833
  "notifier",
21430
22834
  "numeric-sensor",
21431
22835
  "osd",
22836
+ "pet-feeder",
21432
22837
  "power-meter",
21433
22838
  "presence",
21434
22839
  "pressure-sensor",
@@ -22635,6 +24040,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
22635
24040
  addonId: null,
22636
24041
  access: "view"
22637
24042
  },
24043
+ "deviceManager.getRoleDisplayDefaults": {
24044
+ capName: "device-manager",
24045
+ capScope: "system",
24046
+ addonId: null,
24047
+ access: "view"
24048
+ },
22638
24049
  "deviceManager.getSettingsSchema": {
22639
24050
  capName: "device-manager",
22640
24051
  capScope: "system",
@@ -22785,6 +24196,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
22785
24196
  addonId: null,
22786
24197
  access: "create"
22787
24198
  },
24199
+ "deviceManager.setDisplay": {
24200
+ capName: "device-manager",
24201
+ capScope: "system",
24202
+ addonId: null,
24203
+ access: "create"
24204
+ },
22788
24205
  "deviceManager.setIntegrationId": {
22789
24206
  capName: "device-manager",
22790
24207
  capScope: "system",
@@ -22827,6 +24244,12 @@ var METHOD_ACCESS_MAP = Object.freeze({
22827
24244
  addonId: null,
22828
24245
  access: "create"
22829
24246
  },
24247
+ "deviceManager.setRoleDisplayDefaults": {
24248
+ capName: "device-manager",
24249
+ capScope: "system",
24250
+ addonId: null,
24251
+ access: "create"
24252
+ },
22830
24253
  "deviceManager.setStreamProfileMap": {
22831
24254
  capName: "device-manager",
22832
24255
  capScope: "system",
@@ -23877,6 +25300,66 @@ var METHOD_ACCESS_MAP = Object.freeze({
23877
25300
  addonId: null,
23878
25301
  access: "create"
23879
25302
  },
25303
+ "petFeeder.callPet": {
25304
+ capName: "pet-feeder",
25305
+ capScope: "device",
25306
+ addonId: null,
25307
+ access: "create"
25308
+ },
25309
+ "petFeeder.cancelFeed": {
25310
+ capName: "pet-feeder",
25311
+ capScope: "device",
25312
+ addonId: null,
25313
+ access: "create"
25314
+ },
25315
+ "petFeeder.feed": {
25316
+ capName: "pet-feeder",
25317
+ capScope: "device",
25318
+ addonId: null,
25319
+ access: "create"
25320
+ },
25321
+ "petFeeder.markFoodReplenished": {
25322
+ capName: "pet-feeder",
25323
+ capScope: "device",
25324
+ addonId: null,
25325
+ access: "create"
25326
+ },
25327
+ "petFeeder.playSound": {
25328
+ capName: "pet-feeder",
25329
+ capScope: "device",
25330
+ addonId: null,
25331
+ access: "create"
25332
+ },
25333
+ "petFeeder.resetDesiccant": {
25334
+ capName: "pet-feeder",
25335
+ capScope: "device",
25336
+ addonId: null,
25337
+ access: "delete"
25338
+ },
25339
+ "petFeeder.setChildLock": {
25340
+ capName: "pet-feeder",
25341
+ capScope: "device",
25342
+ addonId: null,
25343
+ access: "create"
25344
+ },
25345
+ "petFeeder.setFeedSound": {
25346
+ capName: "pet-feeder",
25347
+ capScope: "device",
25348
+ addonId: null,
25349
+ access: "create"
25350
+ },
25351
+ "petFeeder.setIndicatorLight": {
25352
+ capName: "pet-feeder",
25353
+ capScope: "device",
25354
+ addonId: null,
25355
+ access: "create"
25356
+ },
25357
+ "petFeeder.setVolume": {
25358
+ capName: "pet-feeder",
25359
+ capScope: "device",
25360
+ addonId: null,
25361
+ access: "create"
25362
+ },
23880
25363
  "pipelineAnalytics.clearTracks": {
23881
25364
  capName: "pipeline-analytics",
23882
25365
  capScope: "device",
@@ -25869,6 +27352,7 @@ var KNOWN_CAP_NAMES = [
25869
27352
  "notifier",
25870
27353
  "oauth-integration",
25871
27354
  "osd",
27355
+ "pet-feeder",
25872
27356
  "pipeline-analytics",
25873
27357
  "pipeline-executor",
25874
27358
  "pipeline-orchestrator",
@@ -25944,6 +27428,7 @@ var DEVICE_CAP_NAMES = [
25944
27428
  "native-object-detection",
25945
27429
  "notifier",
25946
27430
  "osd",
27431
+ "pet-feeder",
25947
27432
  "pipeline-analytics",
25948
27433
  "privacy-mask",
25949
27434
  "ptz",
@@ -26582,4 +28067,4 @@ function scoreRuntimes(hw) {
26582
28067
  };
26583
28068
  }
26584
28069
  //#endregion
26585
- export { ACCESSORY_LABEL, ALL_CAPABILITY_DEFINITIONS, APPLE_SA_TO_MACRO, AUDIO_BACKEND_CHOICES, AUDIO_MACRO_LABELS, AccessoriesStatusSchema, AccessoryKind, AddBrokerInputSchema, AddonAutoUpdateSchema, AddonListItemSchema, AddonPageDeclarationSchema, AddonPageInfoSchema, AdoptInputSchema as AdoptionAdoptInputSchema, AdoptResultSchema as AdoptionAdoptResultSchema, AdoptionFilterSchema, GetCandidateInputSchema as AdoptionGetCandidateInputSchema, ListCandidatesInputSchema as AdoptionListCandidatesInputSchema, ListCandidatesOutputSchema as AdoptionListCandidatesOutputSchema, ReleaseInputSchema as AdoptionReleaseInputSchema, AdoptionStatusSchema, AgentLoadSummarySchema, AirQualitySensorStatusSchema, AlarmArmModeSchema, AlarmPanelStatusSchema, AlarmStateSchema, AlertSchema, AlertSeveritySchema, AlertSourceSchema, AlertStatusSchema, AmbientLightSensorStatusSchema, ApiKeyRecordSchema, ApiKeySummarySchema, ArchiveEntrySchema, ArchiveManifestSchema, AttachmentMediaTypeSchema, AttachmentSchema, AudioAnalysisResultSchema, AudioAnalysisSettingsSchema, AudioChunkInputSchema, AudioClassSummarySchema, AudioClassificationLabelSchema, AudioClassificationResultSchema, AudioCodecInfoSchema, AudioDecodeSessionConfigSchema, AudioEncodeSchema, AudioEncodeSessionConfigSchema, AudioEncodedChunkSchema, AudioEventSchema, AudioLevelSchema, AudioMetricsHistoryPointSchema, AudioMetricsHistorySchema, AudioMetricsSnapshotSchema, AudioPcmChunkSchema, AuthResultSchema, AutoUpdateSettingsSchema, AutomationControlStatusSchema, AvailableIntegrationTypeSchema, BACKEND_TO_FORMAT, BATTERY_DEVICE_PROFILE, BackupDestinationInfoSchema, BackupEntrySchema, BaseAddon, BaseDevice, BaseDeviceProvider, BatteryStatusSchema, BinaryStatusSchema, BoundingBoxSchema, BrightnessStatusSchema, AddInputSchema as BrokerAddInputSchema, BrokerAudioClientSchema, BrokerClientsSchema, BrokerConnectionDetailsSchema, BrokerConsumerAttributionSchema, BrokerConsumerKindSchema, BrokerDecodedClientSchema, BrokerEncodedClientSchema, GetStateInputSchema as BrokerGetStateInputSchema, BrokerInfoSchema, BrokerProviderInfoSchema, PublishInputSchema as BrokerPublishInputSchema, RegistryStatusSchema as BrokerRegistryStatusSchema, BrokerRtspClientSchema, BrokerStatsSchema, BrokerStatusEnum, BrokerStatusSchema, SubscribeInputSchema as BrokerSubscribeInputSchema, SubscribeResultSchema as BrokerSubscribeResultSchema, TestConnectionResultSchema as BrokerTestConnectionResultSchema, UnsubscribeInputSchema as BrokerUnsubscribeInputSchema, CAM_PROFILE_ORDER, CAPABILITY_NAMES, CAPABILITY_ROUTER_KEYS, CAP_NAMES_WITH_STATUS, CAP_NODE_PIN_CONTEXT_KEY, CAP_PROVIDER_KIND_MAP, COCO_80_LABELS, COCO_TO_MACRO, CamProfileSchema, CamStreamDescriptorSchema, CamStreamKindSchema, CamStreamResolutionSchema, CameraAssignmentStatusSchema, CameraAudioStatusSchema, CameraBrokerProfileSchema, CameraBrokerStatusSchema, CameraCredentialsSchema, CameraCredentialsStatusSchema, CameraDecoderShmSchema, CameraDecoderStatusSchema, CameraDetectionPhaseSchema, CameraDetectionProvisioningSchema, CameraDetectionProvisioningStateSchema, CameraDetectionStatusSchema, CameraMetricsSchema, CameraMetricsWithDeviceIdSchema, CameraMotionStatusSchema, CameraRecordingModeSchema, CameraRecordingStatusSchema, CameraSourceStatusSchema, CameraSourceStreamSchema, CameraStatusSchema, CameraStreamSchema, CandidateQueryFilterSchema, CapScopeSchema, CapabilityBindingsSchema, CarbonMonoxideStatusSchema, ChargingStatus, ClientNetworkStatsSchema, ClimateControlStatusSchema, ClipPlaybackSchema, ClipSchema, ClusterAddonNodeDeploymentSchema, ClusterAddonStatusEntrySchema, CollectionColumnSchema, CollectionIndexSchema, ColorStatusSchema, ConfigEntrySchema, ConfigSectionWithValuesSchema, ConfigTabDeclarationSchema, ConnectivityStatusSchema, ConsumableItemSchema, ConsumablesStatusSchema, ContactStatusSchema, ControlKindSchema, ControlStatusSchema, ConvertArtifactSchema, ConvertResultSchema, ConvertTargetSchema, CoverStateSchema, CoverStatusSchema, CreateApiKeyInputSchema, CreateApiKeyResultSchema, CreateIntegrationInputSchema, CreateScopedTokenInputSchema, CreateScopedTokenResultSchema, CreateUserInputSchema, CustomActionInputSchema, CustomModelDescriptorSchema, DATAPLANE_SECRET_HEADER, DEFAULT_ADDON_PLACEMENT, DEFAULT_AUDIO_ANALYZER_CONFIG, DEFAULT_DECODER_HWACCEL_CONFIG, DEFAULT_FEATURES, DEFAULT_RETENTION, DEVICE_CAP_NAMES, DEVICE_PROFILES, DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATUS_METHOD, DEVICE_TYPE_INFO, DecodedAudioChunkSchema, DecodedFrameSchema, DecoderAssignmentSchema, DecoderSessionConfigSchema, DecoderStatsSchema, DeleteIntegrationResultSchema, DetectionSourceSchema, DetectorOutputSchema, DeviceCodeSeveritySchema, DeviceConfig, DeviceDiscoveryStatusSchema, ExposeInputSchema as DeviceExportExposeInputSchema, DeviceExportStatusSchema, UnexposeInputSchema as DeviceExportUnexposeInputSchema, DeviceFeature, DeviceInfoSchema, DeviceNetworkStatsSchema, DeviceRole, DeviceRuntimeState, DeviceStatusSchema, DeviceType, DiscoveredChildDeviceSchema, DiscoveredChildStatusSchema, DiscoveredDeviceSchema, DiscoveredTargetSchema, DisposerChain, DoorbellPressEventSchema, DoorbellStatusSchema, EVENT_PAD_MS, ElementConfigStore, EmbeddingInfoSchema, EmbeddingResultSchema, EncodeProfileSchema, EncodedPacketSchema, EnrichedWidgetMetadataSchema, EnumSensorDateTimeFormatSchema, EnumSensorStatusSchema, EventCategory, EventEmitterStatusSchema, EventFireSchema, EventItemSchema, EventKindSchema, EventSourceType, ExportSetupFieldSchema, ExportSetupSchema, ExposedDeviceSchema, ExposedResourceSchema, FanControlStatusSchema, FanDirectionSchema, FeatureManifestSchema, FeatureProbeStatusSchema, FloodStatusSchema, FrameHandleFormatSchema, FrameHandleSchema, FrameInputSchema, GasStatusSchema, GetStreamWithCodecInputSchema, GlobalMetricsSchema, HF_BASE_URL, HF_REPO, HWACCEL_OPTIONS, HealthStatusSchema, HistoryPointSchema, HistoryResolutionEnum, HumidifierStatusSchema, HumiditySensorStatusSchema, HvacModeSchema, ImageStatusSchema, InstalledPackageSchema, IntegrationLiteSchema, IntegrationWithStateSchema, IntercomAbilitySchema, IntercomStatusSchema, KNOWN_CAP_NAMES, LabelDefinitionSchema, LawnMowerActivitySchema, LawnMowerControlStatusSchema, LocateSegmentResultSchema, LocationStatSchema, LockControlStatusSchema, LockStateSchema, LogEntrySchema, LogLevelSchema, LogStreamEntrySchema, MACRO_LABELS, METHOD_ACCESS_MAP, MODEL_FORMATS, MaskGridDimsSchema, MaskGridShapeSchema, MaskLineShapeSchema, MaskPointSchema, MaskPolygonShapeSchema, MaskPolygonVerticesSchema, MaskRectShapeSchema, MaskShapeKindSchema, MaskShapeSchema, MediaFileSchema, MediaPlayerRepeatSchema, MediaPlayerStateSchema, MediaPlayerStatusSchema, MeshPeerSchema, MeshStatusSchema, MethodAccessSchema, ModelCatalogEntrySchema, ModelConvertInputSchema, ModelConvertMetadataSchema, ModelDistributeInputSchema, ModelDistributeResultSchema, ModelExtraFileSchema, ModelFormatEntrySchema, ModelFormatsSchema, MotionAnalysisResultSchema, MotionEventSchema, MotionOnMotionChangedDataSchema, MotionRegionSchema, MotionSourceEnum, MotionSourcesSchema, MotionStatusSchema, MotionTriggerRuntimeStateSchema, MotionTriggerStatusSchema, MotionZoneOptionsSchema, MotionZonePatchSchema, MotionZoneRegionSchema, MotionZoneStatusSchema, StatusSchema as MqttBrokerStatusSchema, NativeDetectionSchema, NativeObjectClassEnum, NativeObjectDetectionRuntimeStateSchema, NativeObjectDetectionStatusSchema, NetworkAccessStatusSchema, NetworkAddressSchema, NetworkEndpointSchema, NotificationActionSchema, NotificationFormatSchema, NotificationHistoryEntrySchema, NotificationRuleSchema, NotificationSchema, NotifierStatusSchema, NumericSensorStatusSchema, OauthIntegrationDescriptorSchema, ObjectEventSchema, OrchestratorMetricsSchema, OsdOverlayKindEnum, OsdOverlayPatchSchema, OsdOverlaySchema, OsdPositionEnum, OsdStatusSchema, PIPELINE_FLOW_CAPABILITY_NAMES, PIPELINE_OWNER_CAPABILITY_NAMES, PROVIDER_KIND_CAP_NAMES, PYTHON_SCRIPT, PackageUpdateSchema, PackageVersionInfoSchema, PasskeySummarySchema, PcmSampleFormatSchema, PerScopeBreakdownSchema, PickStreamPreferencesSchema, PickStreamRequirementsSchema, PickedCamStreamSchema, PipelineAssignmentSchema, PipelineDefaultStepSchema, PipelineEngineChoiceSchema, PipelineRunResultBridge, PipelineStepInputSchema, PlaceholderReasonSchema, PolygonPointSchema, PowerMeterStatusSchema, PresenceStatusSchema, PressureSensorStatusSchema, PrivacyMaskOptionsSchema, PrivacyMaskPatchSchema, PrivacyMaskRegionSchema, PrivacyMaskShapeSchema, PrivacyMaskStatusSchema, ProfileRtspEntrySchema, ProfileSlotSchema, ProfileSlotStatusSchema, ProviderStatusSchema, PtzAutotrackRuntimeStateSchema, PtzAutotrackSettingsSchema, PtzAutotrackStatusSchema, PtzAutotrackTargetOptionSchema, PtzMoveCommandSchema, PtzPositionSchema, PtzPresetSchema, PtzStatusSchema, QueryFilterSchema, RECOGNITION_TYPES, RUNTIME_DEFAULTS, RUNTIME_TO_FORMAT, RawStateResultSchema, ReadSegmentBytesResultSchema, ReadinessRegistry, ReadinessTimeoutError, RecordingAvailabilitySchema, RecordingBandModeSchema, RecordingBandSchema, RecordingBandTriggersSchema, RecordingConfigSchema, RecordingDaysSchema, RecordingDeviceUsageSchema, RecordingLocationUsageSchema, RecordingManifestSchema, RecordingModeSchema, RecordingRangeSchema, RecordingRetentionSchema, RecordingRuleSchema, RecordingScheduleSchema, RecordingStatusSchema, RecordingStorageModeSchema, RecordingStorageUsageSchema, RecordingTriggersSchema, RecordingWeekdaySchema, RegisteredStreamSchema, RenderedAsSchema, ReportMotionInputSchema, RingBuffer, RtpSourceSchema, RtspRestreamEntrySchema, RunnerCameraConfigSchema, RunnerCameraDeviceUIFields, RunnerFrameSourceSchema, RunnerLocalLoadSchema, RunnerLocalMetricsSchema, SCOPE_PRESETS, SOURCE_INFO_METADATA_KEY, STREAM_PROFILE_META, STREAM_QUALITY_LABELS, SUB_DETECTION_TYPES, SYSTEM_CAP_NAMES, ScopedTokenSchema, ScopedTokenSummarySchema, ScoredObjectEventSchema, ScriptRunnerStatusSchema, SearchResultSchema, SendEmailInputSchema, SendEmailResultSchema, SendResultSchema, SettingsPatchSchema, SettingsRecordSchema, SettingsSchemaWithValuesSchema, SettingsUpdateResultSchema, ShmRingStatsSchema, SmokeStatusSchema, SmtpStatusSchema, SnapshotImageSchema, SourceInfoSchema, SpatialDetectionSchema, SsoBridgeClaimsSchema, StartEmbeddedInputSchema, AbortUploadInputSchema as StorageAbortUploadInputSchema, BeginDownloadInputSchema as StorageBeginDownloadInputSchema, BeginDownloadResultSchema as StorageBeginDownloadResultSchema, BeginUploadInputSchema as StorageBeginUploadInputSchema, BeginUploadResultSchema as StorageBeginUploadResultSchema, EndDownloadInputSchema as StorageEndDownloadInputSchema, FinalizeUploadInputSchema as StorageFinalizeUploadInputSchema, StorageLocationDeclarationSchema, StorageLocationRefSchema, StorageLocationSchema, StorageLocationTypeSchema, ProviderInfoSchema as StorageProviderInfoSchema, ReadChunkInputSchema as StorageReadChunkInputSchema, TestLocationResultSchema as StorageTestLocationResultSchema, WriteChunkInputSchema as StorageWriteChunkInputSchema, StreamCodecSchema, StreamFormatSchema, StreamInfoSchema, StreamNetworkStatsSchema, StreamParamsOptionsSchema, StreamParamsStatusSchema, StreamProfileConfigSchema, StreamProfileOptionsSchema, StreamProfilePatchSchema, StreamProfileSchema, StreamSourceEntrySchema, StreamSourceSchema, SubscribeAudioChunksInputSchema, SubscribeAudioChunksResultSchema, SubscribeFramesInputSchema, SubscribeFramesResultSchema, SwitchStatusSchema, SystemMetricsSchema, SystemMirror, TIMEZONES, TamperStatusSchema, TankStatusSchema, TargetKindCapsSchema, TargetKindLevelSchema, TargetKindSchema, TargetSchema, TemperatureSensorStatusSchema, TestConnectionResultSchema$1 as TestConnectionResultSchema, TestResultSchema, ToastSchema, TokenScopeSchema, TopologyNodeSchema, TopologyProcessSchema, TopologyServiceSchema, TrackSchema, TrackStateSchema, TrackedDetectionSchema, TurnServerSchema, BrokerInfoSchema$1 as UnifiedBrokerInfoSchema, UpdateIntegrationInputSchema, UpdateStatusSchema, UpdateUserInputSchema, UserRecordSchema, UserSummarySchema, VacuumControlStatusSchema, VacuumStateSchema, ValveStateSchema, ValveStatusSchema, VibrationStatusSchema, VideoEncodeSchema, WELL_KNOWN_TABS, WELL_KNOWN_TAB_MAP, WaterHeaterStatusSchema, WeatherStatusSchema, WebrtcStreamChoiceSchema, WebrtcStreamTargetSchema, WidgetHostEnum, WidgetMetadataSchema, WidgetRemoteSchema, WidgetSizeEnum, YAMNET_TO_MACRO, ZoneKindEnum, ZoneRuleModeEnum, ZoneRuleSchema, ZoneRuleStageEnum, ZoneRulesArraySchema, ZoneSchema, ZoneScopeBreakdownSchema, accessoriesCapability, accessoryStableId, addonPagesCapability, addonPagesSourceCapability, addonRoutesCapability, addonSettingsCapability, addonWidgetsCapability, addonWidgetsSourceCapability, addonsCapability, adminUiCapability, advancedNotifierCapability, airQualitySensorCapability, alarmPanelCapability, alertsCapability, ambientLightSensorCapability, applyTransform, asBoolean, asJsonArray, asJsonObject, asNumber, asString, audioAnalysisCapability, audioAnalyzerCapability, audioCodecCapability, audioMetricsCapability, authProviderCapability, autoAssignProfiles, automationControlCapability, backupCapability, batteryCapability, bestLocationMatch, binaryCapability, bindAddonActions, brightnessCapability, brokerCapability, buildAddonRouteProvider, buildStreamParamsConfigSchema, buttonCapability, cameraCredentialsCapability, cameraPipelineConfigCapability, cameraStreamsCapability, carbonMonoxideCapability, cellsToRects, classifyStream, classifyStreams, climateControlCapability, colorCapability, connectivityCapability, consumablesCapability, contactCapability, controlCapability, cosineSimilarity, coverCapability, createDeviceProxy, createDurableState, createEvent, createLazyTrpcSource, createMirrorSource, createRuntimeStateBridge, createSliceHandle, createSystemProxy, customAction, customModelRegistryCapability, decoderCapability, defaultDeviceFor, defineCustomActions, detectionPipelineCapability, deviceAdoptionCapability, deviceCustomAction, deviceDiscoveryCapability, deviceExportCapability, deviceManagerCapability, deviceMatchesProfile, deviceOpsCapability, deviceProviderCapability, deviceStateCapability, deviceStatusCapability, doorbellCapability, embeddingEncoderCapability, emitDownForOwnedCaps, emitReadiness, encodeProfileFromStreamShape, enumSensorCapability, enumerateItemArrayFields, enumerateSchemaFields, errMsg, evaluateZoneRules, event, eventEmitterCapability, eventsCapability, expandCapMethods, extractSourceInfoFromMetadata, faceGalleryCapability, fanControlCapability, featureProbeCapability, filesystemBrowseCapability, findTimezone, floodCapability, formatForBackend, formatForRuntime, frameworkSwapConfirmSchema, frameworkSwapPackageSchema, gasCapability, getAudioMacroClassIds, getByPath, getCapsByProviderKind, hfModelUrl, htmlToText, humidifierCapability, humiditySensorCapability, hydrateSchema, imageCapability, integrationsCapability, intercomCapability, isAgentOnlyPlacement, isDeployableToAgent, isDeviceConfigCap, isEvent, jobKindSchema, lawnMowerControlCapability, lifecycleJobSchema, lifecycleJobScopeSchema, lifecycleJobStateSchema, lifecycleTaskSchema, localNetworkCapability, locationSimilarity, lockControlCapability, logDestinationCapability, makeProfileBrokerId, makeSourceBrokerId, mapAudioLabelToMacro, markdownToHtmlLite, markdownToText, maskUrlCredentials, mediaPlayerCapability, mergeSourceInfo, meshNetworkCapability, method, metricsProviderCapability, migrateConfigToBands, modelConvertCapability, modelDistributorCapability, modelFormatForRuntime, motionCapability, motionDetectionCapability, motionTriggerCapability, motionZonesCapability, mqttBrokerCapability, nativeObjectDetectionCapability, networkAccessCapability, networkQualityCapability, nodePin, nodesCapability, normalizeAddonInitResult, normalizeUnit, notificationOutputCapability, notifierCapability, numericSensorCapability, oauthIntegrationCapability, osdCapability, parseCameraStreamConfig, parseJsonArray, parseJsonObject, parseJsonUnknown, parseProfileBrokerId, parseStreamParamsFormPatch, pendingFrameworkSwapSchema, pickPreferredRtspEntry, pipelineAnalyticsCapability, pipelineExecutorCapability, pipelineOrchestratorCapability, pipelineRunnerCapability, plateGalleryCapability, platformProbeCapability, powerMeterCapability, prepareNotification, presenceCapability, pressureSensorCapability, privacyMaskCapability, ptzAutotrackCapability, ptzCapability, pythonScriptForBackend, readNodePin, readinessKey, rebootCapability, recordingCapability, rectsToCells, requiresPython, resolveAddonExecution, resolveAddonGroup, resolveAddonPlacement, resolveAddonRuntime, resolveCapMount, resolveDetectionRuntime, resolveDeviceProfile, resolveFormat, resolveModelFormat, resolveRunnerId, restreamerCapability, runInferenceStep, runtimeDevices, scopeKey, scoreRuntimes, scriptRunnerCapability, selectAssignedProfileSlots, setByPath, settingsStoreCapability, sleep, sleepCancellable, smokeCapability, smtpProviderCapability, snapshotCapability, snapshotProviderCapability, ssoBridgeCapability, storageCapability, storageEvictableCapability, storageProviderCapability, streamBrokerCapability, streamCatalogCapability, streamParamsCapability, streamPixels, streamQualityLabel, streamingEngineCapability, supportedRuntimes, switchCapability, synthesizeSourceInfo, systemCapability, tamperCapability, taskLogEntrySchema, taskPhaseSchema, taskTargetSchema, temperatureSensorCapability, textToHtml, toDeviceSummary, toStreamSourceEntry, toastCapability, transcodeBody, turnProviderCapability, updateCapability, userManagementCapability, userPasskeysCapability, vacuumControlCapability, valveCapability, vibrationCapability, videoclipsCapability, waterHeaterCapability, weatherCapability, webrtcCapability, webrtcClientHintsSchema, webrtcSessionCapability, wiringAddonHealthSchema, wiringHealthSnapshotSchema, wiringNodeHealthSchema, wiringProbeKindSchema, wiringProbeResultSchema, zodEntriesToConfigUI, zoneAnalyticsCapability, zoneRulesCapability, zonesCapability };
28070
+ export { ACCESSORY_LABEL, ALL_CAPABILITY_DEFINITIONS, APPLE_SA_TO_MACRO, AUDIO_BACKEND_CHOICES, AUDIO_MACRO_LABELS, AccessoriesStatusSchema, AccessoryKind, AddBrokerInputSchema, AddonAutoUpdateSchema, AddonListItemSchema, AddonPageDeclarationSchema, AddonPageInfoSchema, AdoptInputSchema as AdoptionAdoptInputSchema, AdoptResultSchema as AdoptionAdoptResultSchema, AdoptionFilterSchema, GetCandidateInputSchema as AdoptionGetCandidateInputSchema, ListCandidatesInputSchema as AdoptionListCandidatesInputSchema, ListCandidatesOutputSchema as AdoptionListCandidatesOutputSchema, ReleaseInputSchema as AdoptionReleaseInputSchema, AdoptionStatusSchema, AgentLoadSummarySchema, AirQualitySensorStatusSchema, AlarmArmModeSchema, AlarmPanelStatusSchema, AlarmStateSchema, AlertSchema, AlertSeveritySchema, AlertSourceSchema, AlertStatusSchema, AmbientLightSensorStatusSchema, ApiKeyRecordSchema, ApiKeySummarySchema, ArchiveEntrySchema, ArchiveManifestSchema, AttachmentMediaTypeSchema, AttachmentSchema, AudioAnalysisResultSchema, AudioAnalysisSettingsSchema, AudioChunkInputSchema, AudioClassSummarySchema, AudioClassificationLabelSchema, AudioClassificationResultSchema, AudioCodecInfoSchema, AudioDecodeSessionConfigSchema, AudioEncodeSchema, AudioEncodeSessionConfigSchema, AudioEncodedChunkSchema, AudioEventSchema, AudioLevelSchema, AudioMetricsHistoryPointSchema, AudioMetricsHistorySchema, AudioMetricsSnapshotSchema, AudioPcmChunkSchema, AuthResultSchema, AutoUpdateSettingsSchema, AutomationControlStatusSchema, AvailableIntegrationTypeSchema, BACKEND_TO_FORMAT, BATTERY_DEVICE_PROFILE, BackupDestinationInfoSchema, BackupEntrySchema, BaseAddon, BaseDevice, BaseDeviceProvider, BatteryStatusSchema, BinaryStatusSchema, BoundingBoxSchema, BrightnessStatusSchema, AddInputSchema as BrokerAddInputSchema, BrokerAudioClientSchema, BrokerClientsSchema, BrokerConnectionDetailsSchema, BrokerConsumerAttributionSchema, BrokerConsumerKindSchema, BrokerDecodedClientSchema, BrokerEncodedClientSchema, GetStateInputSchema as BrokerGetStateInputSchema, BrokerInfoSchema, BrokerProviderInfoSchema, PublishInputSchema as BrokerPublishInputSchema, RegistryStatusSchema as BrokerRegistryStatusSchema, BrokerRtspClientSchema, BrokerStatsSchema, BrokerStatusEnum, BrokerStatusSchema, SubscribeInputSchema as BrokerSubscribeInputSchema, SubscribeResultSchema as BrokerSubscribeResultSchema, TestConnectionResultSchema as BrokerTestConnectionResultSchema, UnsubscribeInputSchema as BrokerUnsubscribeInputSchema, CAM_PROFILE_ORDER, CAPABILITY_NAMES, CAPABILITY_ROUTER_KEYS, CAP_NAMES_WITH_STATUS, CAP_NODE_PIN_CONTEXT_KEY, CAP_PROVIDER_KIND_MAP, COCO_80_LABELS, COCO_TO_MACRO, CamProfileSchema, CamStreamDescriptorSchema, CamStreamKindSchema, CamStreamResolutionSchema, CameraAssignmentStatusSchema, CameraAudioStatusSchema, CameraBrokerProfileSchema, CameraBrokerStatusSchema, CameraCredentialsSchema, CameraCredentialsStatusSchema, CameraDecoderShmSchema, CameraDecoderStatusSchema, CameraDetectionPhaseSchema, CameraDetectionProvisioningSchema, CameraDetectionProvisioningStateSchema, CameraDetectionStatusSchema, CameraMetricsSchema, CameraMetricsWithDeviceIdSchema, CameraMotionStatusSchema, CameraRecordingModeSchema, CameraRecordingStatusSchema, CameraSourceStatusSchema, CameraSourceStreamSchema, CameraStatusSchema, CameraStreamSchema, CandidateQueryFilterSchema, CapScopeSchema, CapabilityBindingsSchema, CarbonMonoxideStatusSchema, ChargingStatus, ClientNetworkStatsSchema, ClimateControlStatusSchema, ClipPlaybackSchema, ClipSchema, ClusterAddonNodeDeploymentSchema, ClusterAddonStatusEntrySchema, CollectionColumnSchema, CollectionIndexSchema, ColorStatusSchema, ConfigEntrySchema, ConfigSectionWithValuesSchema, ConfigTabDeclarationSchema, ConnectivityStatusSchema, ConsumableItemSchema, ConsumablesStatusSchema, ContactStatusSchema, ControlKindSchema, ControlStatusSchema, ConvertArtifactSchema, ConvertResultSchema, ConvertTargetSchema, CoverStateSchema, CoverStatusSchema, CreateApiKeyInputSchema, CreateApiKeyResultSchema, CreateIntegrationInputSchema, CreateScopedTokenInputSchema, CreateScopedTokenResultSchema, CreateUserInputSchema, CustomActionInputSchema, CustomModelDescriptorSchema, DATAPLANE_SECRET_HEADER, DEFAULT_ADDON_PLACEMENT, DEFAULT_AUDIO_ANALYZER_CONFIG, DEFAULT_DECODER_HWACCEL_CONFIG, DEFAULT_FEATURES, DEFAULT_RETENTION, DEVICE_CAP_NAMES, DEVICE_PROFILES, DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATUS_METHOD, DEVICE_TYPE_INFO, DecodedAudioChunkSchema, DecodedFrameSchema, DecoderAssignmentSchema, DecoderSessionConfigSchema, DecoderStatsSchema, DeleteIntegrationResultSchema, DetectionSourceSchema, DetectorOutputSchema, DeviceCodeSeveritySchema, DeviceConfig, DeviceDiscoveryStatusSchema, ExposeInputSchema as DeviceExportExposeInputSchema, DeviceExportStatusSchema, UnexposeInputSchema as DeviceExportUnexposeInputSchema, DeviceFeature, DeviceInfoSchema, DeviceNetworkStatsSchema, DeviceRole, DeviceRuntimeState, DeviceStatusSchema, DeviceType, DiscoveredChildDeviceSchema, DiscoveredChildStatusSchema, DiscoveredDeviceSchema, DiscoveredTargetSchema, DisposerChain, DoorbellPressEventSchema, DoorbellStatusSchema, EVENT_PAD_MS, EXPRESSION_BUILTINS, EXPRESSION_BUILTIN_NAMES, EXPRESSION_COMPILE_CACHE_CAPACITY, EXPRESSION_IDENTIFIER_RE, EXPRESSION_INJECTED_NOW, ElementConfigStore, EmbeddingInfoSchema, EmbeddingResultSchema, EncodeProfileSchema, EncodedPacketSchema, EnrichedWidgetMetadataSchema, EnumSensorDateTimeFormatSchema, EnumSensorStatusSchema, EventCategory, EventEmitterStatusSchema, EventFireSchema, EventItemSchema, EventKindSchema, EventSourceType, ExportSetupFieldSchema, ExportSetupSchema, ExposedDeviceSchema, ExposedResourceSchema, ExpressionEvalError, ExpressionParseError, FanControlStatusSchema, FanDirectionSchema, FeatureManifestSchema, FeatureProbeStatusSchema, FloodStatusSchema, FrameHandleFormatSchema, FrameHandleSchema, FrameInputSchema, GasStatusSchema, GetStreamWithCodecInputSchema, GlobalMetricsSchema, HF_BASE_URL, HF_REPO, HWACCEL_OPTIONS, HealthStatusSchema, HistoryPointSchema, HistoryResolutionEnum, HumidifierStatusSchema, HumiditySensorStatusSchema, HvacModeSchema, ImageStatusSchema, InstalledPackageSchema, IntegrationLiteSchema, IntegrationWithStateSchema, IntercomAbilitySchema, IntercomStatusSchema, KNOWN_CAP_NAMES, LabelDefinitionSchema, LawnMowerActivitySchema, LawnMowerControlStatusSchema, LocateSegmentResultSchema, LocationStatSchema, LockControlStatusSchema, LockStateSchema, LogEntrySchema, LogLevelSchema, LogStreamEntrySchema, MACRO_LABELS, MAX_EXPRESSION_AST_NODES, MAX_EXPRESSION_BINDINGS, MAX_EXPRESSION_CALL_ARGS, MAX_EXPRESSION_EVAL_STEPS, MAX_EXPRESSION_SOURCE_LENGTH, METHOD_ACCESS_MAP, MODEL_FORMATS, MaskGridDimsSchema, MaskGridShapeSchema, MaskLineShapeSchema, MaskPointSchema, MaskPolygonShapeSchema, MaskPolygonVerticesSchema, MaskRectShapeSchema, MaskShapeKindSchema, MaskShapeSchema, MediaFileSchema, MediaPlayerRepeatSchema, MediaPlayerStateSchema, MediaPlayerStatusSchema, MeshPeerSchema, MeshStatusSchema, MethodAccessSchema, ModelCatalogEntrySchema, ModelConvertInputSchema, ModelConvertMetadataSchema, ModelDistributeInputSchema, ModelDistributeResultSchema, ModelExtraFileSchema, ModelFormatEntrySchema, ModelFormatsSchema, MotionAnalysisResultSchema, MotionEventSchema, MotionOnMotionChangedDataSchema, MotionRegionSchema, MotionSourceEnum, MotionSourcesSchema, MotionStatusSchema, MotionTriggerRuntimeStateSchema, MotionTriggerStatusSchema, MotionZoneOptionsSchema, MotionZonePatchSchema, MotionZoneRegionSchema, MotionZoneStatusSchema, StatusSchema as MqttBrokerStatusSchema, NativeDetectionSchema, NativeObjectClassEnum, NativeObjectDetectionRuntimeStateSchema, NativeObjectDetectionStatusSchema, NetworkAccessStatusSchema, NetworkAddressSchema, NetworkEndpointSchema, NotificationActionSchema, NotificationFormatSchema, NotificationHistoryEntrySchema, NotificationRuleSchema, NotificationSchema, NotifierStatusSchema, NumericSensorStatusSchema, OauthIntegrationDescriptorSchema, ObjectEventSchema, OrchestratorMetricsSchema, OsdOverlayKindEnum, OsdOverlayPatchSchema, OsdOverlaySchema, OsdPositionEnum, OsdStatusSchema, PET_FEEDER_MANUAL_FEED_MAX, PET_FEEDER_MANUAL_FEED_MIN, PIPELINE_FLOW_CAPABILITY_NAMES, PIPELINE_OWNER_CAPABILITY_NAMES, PROVIDER_KIND_CAP_NAMES, PYTHON_SCRIPT, PackageUpdateSchema, PackageVersionInfoSchema, PasskeySummarySchema, PcmSampleFormatSchema, PerScopeBreakdownSchema, PetFeederStatusSchema, PickStreamPreferencesSchema, PickStreamRequirementsSchema, PickedCamStreamSchema, PipelineAssignmentSchema, PipelineDefaultStepSchema, PipelineEngineChoiceSchema, PipelineRunResultBridge, PipelineStepInputSchema, PlaceholderReasonSchema, PolygonPointSchema, PowerMeterStatusSchema, PresenceStatusSchema, PressureSensorStatusSchema, PrivacyMaskOptionsSchema, PrivacyMaskPatchSchema, PrivacyMaskRegionSchema, PrivacyMaskShapeSchema, PrivacyMaskStatusSchema, ProfileRtspEntrySchema, ProfileSlotSchema, ProfileSlotStatusSchema, ProviderStatusSchema, PtzAutotrackRuntimeStateSchema, PtzAutotrackSettingsSchema, PtzAutotrackStatusSchema, PtzAutotrackTargetOptionSchema, PtzMoveCommandSchema, PtzPositionSchema, PtzPresetSchema, PtzStatusSchema, QueryFilterSchema, RECOGNITION_TYPES, RESERVED_BINDING_NAMES, RUNTIME_DEFAULTS, RUNTIME_TO_FORMAT, RawStateResultSchema, ReadSegmentBytesResultSchema, ReadinessRegistry, ReadinessTimeoutError, RecordingAvailabilitySchema, RecordingBandModeSchema, RecordingBandSchema, RecordingBandTriggersSchema, RecordingConfigSchema, RecordingDaysSchema, RecordingDeviceUsageSchema, RecordingLocationUsageSchema, RecordingManifestSchema, RecordingModeSchema, RecordingRangeSchema, RecordingRetentionSchema, RecordingRuleSchema, RecordingScheduleSchema, RecordingStatusSchema, RecordingStorageModeSchema, RecordingStorageUsageSchema, RecordingTriggersSchema, RecordingWeekdaySchema, RegisteredStreamSchema, RenderedAsSchema, ReportMotionInputSchema, RingBuffer, RtpSourceSchema, RtspRestreamEntrySchema, RunnerCameraConfigSchema, RunnerCameraDeviceUIFields, RunnerFrameSourceSchema, RunnerLocalLoadSchema, RunnerLocalMetricsSchema, SCOPE_PRESETS, SOURCE_INFO_METADATA_KEY, STREAM_PROFILE_META, STREAM_QUALITY_LABELS, SUB_DETECTION_TYPES, SYSTEM_CAP_NAMES, ScopedTokenSchema, ScopedTokenSummarySchema, ScoredObjectEventSchema, ScriptRunnerStatusSchema, SearchResultSchema, SendEmailInputSchema, SendEmailResultSchema, SendResultSchema, SettingsPatchSchema, SettingsRecordSchema, SettingsSchemaWithValuesSchema, SettingsUpdateResultSchema, ShmRingStatsSchema, SmokeStatusSchema, SmtpStatusSchema, SnapshotImageSchema, SourceInfoSchema, SpatialDetectionSchema, SsoBridgeClaimsSchema, StartEmbeddedInputSchema, AbortUploadInputSchema as StorageAbortUploadInputSchema, BeginDownloadInputSchema as StorageBeginDownloadInputSchema, BeginDownloadResultSchema as StorageBeginDownloadResultSchema, BeginUploadInputSchema as StorageBeginUploadInputSchema, BeginUploadResultSchema as StorageBeginUploadResultSchema, EndDownloadInputSchema as StorageEndDownloadInputSchema, FinalizeUploadInputSchema as StorageFinalizeUploadInputSchema, StorageLocationDeclarationSchema, StorageLocationRefSchema, StorageLocationSchema, StorageLocationTypeSchema, ProviderInfoSchema as StorageProviderInfoSchema, ReadChunkInputSchema as StorageReadChunkInputSchema, TestLocationResultSchema as StorageTestLocationResultSchema, WriteChunkInputSchema as StorageWriteChunkInputSchema, StreamCodecSchema, StreamFormatSchema, StreamInfoSchema, StreamNetworkStatsSchema, StreamParamsOptionsSchema, StreamParamsStatusSchema, StreamProfileConfigSchema, StreamProfileOptionsSchema, StreamProfilePatchSchema, StreamProfileSchema, StreamSourceEntrySchema, StreamSourceSchema, SubscribeAudioChunksInputSchema, SubscribeAudioChunksResultSchema, SubscribeFramesInputSchema, SubscribeFramesResultSchema, SwitchStatusSchema, SystemMetricsSchema, SystemMirror, TIMEZONES, TamperStatusSchema, TankStatusSchema, TargetKindCapsSchema, TargetKindLevelSchema, TargetKindSchema, TargetSchema, TemperatureSensorStatusSchema, TestConnectionResultSchema$1 as TestConnectionResultSchema, TestResultSchema, ToastSchema, TokenScopeSchema, TopologyNodeSchema, TopologyProcessSchema, TopologyServiceSchema, TrackSchema, TrackStateSchema, TrackedDetectionSchema, TurnServerSchema, UNIT_TABLE, BrokerInfoSchema$1 as UnifiedBrokerInfoSchema, UnitConversionError, UpdateIntegrationInputSchema, UpdateStatusSchema, UpdateUserInputSchema, UserRecordSchema, UserSummarySchema, VacuumControlStatusSchema, VacuumStateSchema, ValveStateSchema, ValveStatusSchema, VibrationStatusSchema, VideoEncodeSchema, WELL_KNOWN_TABS, WELL_KNOWN_TAB_MAP, WaterHeaterStatusSchema, WeatherStatusSchema, WebrtcStreamChoiceSchema, WebrtcStreamTargetSchema, WidgetHostEnum, WidgetMetadataSchema, WidgetRemoteSchema, WidgetSizeEnum, YAMNET_TO_MACRO, ZoneKindEnum, ZoneRuleModeEnum, ZoneRuleSchema, ZoneRuleStageEnum, ZoneRulesArraySchema, ZoneSchema, ZoneScopeBreakdownSchema, accessoriesCapability, accessoryStableId, addonPagesCapability, addonPagesSourceCapability, addonRoutesCapability, addonSettingsCapability, addonWidgetsCapability, addonWidgetsSourceCapability, addonsCapability, adminUiCapability, advancedNotifierCapability, airQualitySensorCapability, alarmPanelCapability, alertsCapability, ambientLightSensorCapability, applyTransform, asBoolean, asJsonArray, asJsonObject, asNumber, asString, audioAnalysisCapability, audioAnalyzerCapability, audioCodecCapability, audioMetricsCapability, authProviderCapability, autoAssignProfiles, automationControlCapability, backupCapability, batteryCapability, bestLocationMatch, binaryCapability, bindAddonActions, brightnessCapability, brokerCapability, buildAddonRouteProvider, buildStreamParamsConfigSchema, buttonCapability, cameraCredentialsCapability, cameraPipelineConfigCapability, cameraStreamsCapability, canConvertUnit, carbonMonoxideCapability, cellsToRects, classifyStream, classifyStreams, climateControlCapability, colorCapability, compileExpression, compileExpressionSafe, connectivityCapability, consumablesCapability, contactCapability, controlCapability, convertUnit, cosineSimilarity, coverCapability, createDeviceProxy, createDurableState, createEvent, createExpressionScope, createLazyTrpcSource, createMirrorSource, createRuntimeStateBridge, createSliceHandle, createSystemProxy, customAction, customModelRegistryCapability, decoderCapability, defaultDeviceFor, defineCustomActions, detectionPipelineCapability, deviceAdoptionCapability, deviceCustomAction, deviceDiscoveryCapability, deviceExportCapability, deviceManagerCapability, deviceMatchesProfile, deviceOpsCapability, deviceProviderCapability, deviceStateCapability, deviceStatusCapability, doorbellCapability, embeddingEncoderCapability, emitDownForOwnedCaps, emitReadiness, encodeProfileFromStreamShape, enumSensorCapability, enumerateItemArrayFields, enumerateSchemaFields, errMsg, evaluateAst, evaluateLinkExpression, evaluateZoneRules, event, eventEmitterCapability, eventsCapability, expandCapMethods, extractSourceInfoFromMetadata, faceGalleryCapability, fanControlCapability, featureProbeCapability, filesystemBrowseCapability, findTimezone, floodCapability, formatForBackend, formatForRuntime, frameworkSwapConfirmSchema, frameworkSwapPackageSchema, gasCapability, getAudioMacroClassIds, getByPath, getCapsByProviderKind, hfModelUrl, htmlToText, humidifierCapability, humiditySensorCapability, hydrateSchema, imageCapability, integrationsCapability, intercomCapability, isAgentOnlyPlacement, isDeployableToAgent, isDeviceConfigCap, isEvent, jobKindSchema, lawnMowerControlCapability, lifecycleJobSchema, lifecycleJobScopeSchema, lifecycleJobStateSchema, lifecycleTaskSchema, localNetworkCapability, locationSimilarity, lockControlCapability, logDestinationCapability, makeProfileBrokerId, makeSourceBrokerId, mapAudioLabelToMacro, markdownToHtmlLite, markdownToText, maskUrlCredentials, mediaPlayerCapability, mergeSourceInfo, meshNetworkCapability, method, metricsProviderCapability, migrateConfigToBands, modelConvertCapability, modelDistributorCapability, modelFormatForRuntime, motionCapability, motionDetectionCapability, motionTriggerCapability, motionZonesCapability, mqttBrokerCapability, nativeObjectDetectionCapability, networkAccessCapability, networkQualityCapability, nodePin, nodesCapability, normalizeAddonInitResult, normalizeUnit, notificationOutputCapability, notifierCapability, numericSensorCapability, oauthIntegrationCapability, osdCapability, parseCameraStreamConfig, parseExpression, parseJsonArray, parseJsonObject, parseJsonUnknown, parseProfileBrokerId, parseStreamParamsFormPatch, pendingFrameworkSwapSchema, petFeederCapability, pickPreferredRtspEntry, pipelineAnalyticsCapability, pipelineExecutorCapability, pipelineOrchestratorCapability, pipelineRunnerCapability, plateGalleryCapability, platformProbeCapability, powerMeterCapability, prepareNotification, presenceCapability, pressureSensorCapability, privacyMaskCapability, ptzAutotrackCapability, ptzCapability, pythonScriptForBackend, readNodePin, readinessKey, rebootCapability, recordingCapability, rectsToCells, requiresPython, resolveAddonExecution, resolveAddonGroup, resolveAddonPlacement, resolveAddonRuntime, resolveCapMount, resolveDetectionRuntime, resolveDeviceProfile, resolveFormat, resolveModelFormat, resolveRunnerId, restreamerCapability, runInferenceStep, runtimeDevices, scopeKey, scoreRuntimes, scriptRunnerCapability, selectAssignedProfileSlots, setByPath, settingsStoreCapability, sleep, sleepCancellable, smokeCapability, smtpProviderCapability, snapshotCapability, snapshotProviderCapability, ssoBridgeCapability, storageCapability, storageEvictableCapability, storageProviderCapability, streamBrokerCapability, streamCatalogCapability, streamParamsCapability, streamPixels, streamQualityLabel, streamingEngineCapability, supportedRuntimes, switchCapability, synthesizeSourceInfo, systemCapability, tamperCapability, taskLogEntrySchema, taskPhaseSchema, taskTargetSchema, temperatureSensorCapability, textToHtml, toDeviceSummary, toExpressionValue, toStreamSourceEntry, toastCapability, tokenize, transcodeBody, tryConvertUnit, turnProviderCapability, unitDimension, unitsForDimension, updateCapability, userManagementCapability, userPasskeysCapability, vacuumControlCapability, validateExpressionSource, valveCapability, vibrationCapability, videoclipsCapability, waterHeaterCapability, weatherCapability, webrtcCapability, webrtcClientHintsSchema, webrtcSessionCapability, wiringAddonHealthSchema, wiringHealthSnapshotSchema, wiringNodeHealthSchema, wiringProbeKindSchema, wiringProbeResultSchema, zodEntriesToConfigUI, zoneAnalyticsCapability, zoneRulesCapability, zonesCapability };