@camstack/types 1.2.260 → 1.2.262
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/addon/base-addon.d.ts +9 -1
- package/dist/addon.js +4 -6
- package/dist/addon.mjs +4 -6
- package/dist/capabilities/capability-definition.d.ts +9 -0
- package/dist/capabilities/custom-model-registry.cap.d.ts +18 -0
- package/dist/capabilities/device-extension.cap.d.ts +408 -0
- package/dist/capabilities/device-manager.cap.d.ts +59 -6
- package/dist/capabilities/doorbell.cap.d.ts +41 -1
- package/dist/capabilities/embedding-encoder.cap.d.ts +175 -0
- package/dist/capabilities/index.d.ts +15 -12
- package/dist/capabilities/llm-runtime.cap.d.ts +4 -4
- package/dist/capabilities/llm-shared.d.ts +6 -6
- package/dist/capabilities/llm.cap.d.ts +6 -6
- package/dist/capabilities/model-convert.cap.d.ts +9 -0
- package/dist/capabilities/model-distributor.cap.d.ts +18 -0
- package/dist/capabilities/notification-rules.cap.d.ts +32 -14
- package/dist/capabilities/osd-manager.cap.d.ts +6 -6
- package/dist/capabilities/pipeline-analytics.cap.d.ts +80 -2
- package/dist/capabilities/pipeline-executor.cap.d.ts +1 -0
- package/dist/capabilities/pipeline-orchestrator.cap.d.ts +62 -1
- package/dist/capabilities/pipeline-runner.cap.d.ts +24 -0
- package/dist/capabilities/vector-store.cap.d.ts +14 -0
- package/dist/device-extension/index.d.ts +3 -0
- package/dist/device-extension/slot-descriptor.d.ts +62 -0
- package/dist/device-extension/slot-provider.d.ts +70 -0
- package/dist/generated/addon-api.d.ts +39 -31
- package/dist/generated/capability-router-map.d.ts +5 -2
- package/dist/generated/collection-array-methods.d.ts +1 -1
- package/dist/generated/device-proxy.d.ts +8 -8
- package/dist/generated/device-scoped-caps.d.ts +1 -1
- package/dist/generated/extension-slots.d.ts +40 -0
- package/dist/generated/method-access-map.d.ts +1 -1
- package/dist/generated/method-device-selectors.d.ts +1 -1
- package/dist/generated/system-proxy.d.ts +4 -2
- package/dist/index.d.ts +5 -1
- package/dist/index.js +1483 -507
- package/dist/index.mjs +1422 -508
- package/dist/interfaces/addon.d.ts +41 -0
- package/dist/interfaces/event-bus.d.ts +10 -0
- package/dist/node.d.ts +1 -0
- package/dist/node.js +73 -7
- package/dist/node.mjs +73 -8
- package/dist/pipeline/cluster-model-scope.d.ts +59 -3
- package/dist/pipeline/step-format-runnable.d.ts +31 -0
- package/dist/{sleep-BDYxE1ax.js → sleep-8K9gue-H.js} +56 -42
- package/dist/{sleep-BaRu0bS5.mjs → sleep-DC-wdyeS.mjs} +51 -43
- package/dist/storage/atomic-write.d.ts +25 -0
- package/dist/types/clip-model.d.ts +64 -0
- package/dist/types/models.d.ts +18 -0
- package/package.json +1 -1
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* An EXTENSION SLOT — one way a device can be extended by OTHER devices,
|
|
3
|
+
* declared by the capability that already owns the function (D648).
|
|
4
|
+
*
|
|
5
|
+
* A slot is metadata, and behavioural metadata lives in the owning `*.cap.ts`
|
|
6
|
+
* (D4): `device-manager.cap.ts` declares `linked-devices`, `doorbell.cap.ts`
|
|
7
|
+
* declares `doorbell-source`. `npm run codegen` folds every declaration into
|
|
8
|
+
* `generated/extension-slots.ts` (the id enum, the table and the discriminated
|
|
9
|
+
* union of slot values), and `device-extension` is the device-scoped
|
|
10
|
+
* collection contract that lists and writes them. The contract persists
|
|
11
|
+
* NOTHING: each slot is served by the addon that owns its store (D62).
|
|
12
|
+
*
|
|
13
|
+
* Two shapes:
|
|
14
|
+
*
|
|
15
|
+
* - `association` — the host LISTS other devices (a camera's linked devices,
|
|
16
|
+
* its doorbell trigger sources). Removing every source is "off"; there is
|
|
17
|
+
* no separate switch.
|
|
18
|
+
* - `graft` — the host GAINS a whole capability (`projects`), registered
|
|
19
|
+
* natively by the host's own provider from sources it owns. Declared here
|
|
20
|
+
* so the contract has room for it; the first graft (HA consumables) is
|
|
21
|
+
* slice 2, and a graft carries its own `enabled` switch.
|
|
22
|
+
*/
|
|
23
|
+
import type { z } from 'zod';
|
|
24
|
+
import type { DeviceType } from '../device/device-type.js';
|
|
25
|
+
/** How a slot extends its host. See the module docblock. */
|
|
26
|
+
export type ExtensionSlotShape = 'association' | 'graft';
|
|
27
|
+
/** How many sources a slot takes. */
|
|
28
|
+
export type ExtensionSlotCardinality = 'one' | 'many';
|
|
29
|
+
/**
|
|
30
|
+
* One slot, as declared in its owning `*.cap.ts`.
|
|
31
|
+
*
|
|
32
|
+
* `value` is the slot's EDITABLE value — what `setSlot` takes and `listSlots`
|
|
33
|
+
* returns. It must be a Zod OBJECT that does not itself carry a `slot` key:
|
|
34
|
+
* codegen extends it with `slot: z.literal(<id>)` to build the discriminated
|
|
35
|
+
* union, and it must be a NAMED EXPORT of the declaring cap file (codegen
|
|
36
|
+
* imports it by name so the generated module never imports the caps barrel).
|
|
37
|
+
*/
|
|
38
|
+
export interface ExtensionSlotDescriptor<TValue extends z.ZodObject = z.ZodObject> {
|
|
39
|
+
/** Kebab id, unique across every cap. Becomes a member of `ExtensionSlotId`. */
|
|
40
|
+
readonly id: string;
|
|
41
|
+
/** Operator-facing name of the slot ("Linked devices"). */
|
|
42
|
+
readonly label: string;
|
|
43
|
+
/** One sentence saying what a source of this slot DOES to the host. */
|
|
44
|
+
readonly description: string;
|
|
45
|
+
readonly shape: ExtensionSlotShape;
|
|
46
|
+
/**
|
|
47
|
+
* Host device types the slot is offered on. Absent = the declaring cap's
|
|
48
|
+
* `deviceTypes`; a slot on a cap that declares none (a `system` cap such as
|
|
49
|
+
* `device-manager`) MUST state it (guarded).
|
|
50
|
+
*/
|
|
51
|
+
readonly hostDeviceTypes?: readonly DeviceType[];
|
|
52
|
+
/**
|
|
53
|
+
* Source filter for the picker, tested against a candidate's capabilities
|
|
54
|
+
* (D12: its bindings, never the global cap list). `'any'` = no cap filter.
|
|
55
|
+
*/
|
|
56
|
+
readonly sourceCaps: readonly string[] | 'any';
|
|
57
|
+
readonly cardinality: ExtensionSlotCardinality;
|
|
58
|
+
/** graft only — MUST equal the declaring cap's `name` (guarded). */
|
|
59
|
+
readonly projects?: string;
|
|
60
|
+
/** The slot's editable value. See the interface docblock. */
|
|
61
|
+
readonly value: TValue;
|
|
62
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The owner's side of `device-extension` (D648): `defineExtensionSlotProvider`
|
|
3
|
+
* binds ONE slot id to the functions that read and write the owner's existing
|
|
4
|
+
* store, and `createDeviceExtensionProvider` turns an owner's slots into the
|
|
5
|
+
* cap provider it registers.
|
|
6
|
+
*
|
|
7
|
+
* The id is typed on the GENERATED `ExtensionSlotId`, so a typo does not
|
|
8
|
+
* compile, and the literal `defineExtensionSlotProvider('<id>'` is what
|
|
9
|
+
* `scripts/check-extension-slots.ts` counts to prove every declared slot has
|
|
10
|
+
* exactly one owner.
|
|
11
|
+
*
|
|
12
|
+
* Nothing here persists. An owner's `set` goes through the write path the
|
|
13
|
+
* owner already had for its store; this module only routes, checks the host
|
|
14
|
+
* type and logs the write.
|
|
15
|
+
*/
|
|
16
|
+
import type { IScopedLogger } from '../interfaces/logging.js';
|
|
17
|
+
import { type ExtensionCandidate, type ExtensionSetResult, type ExtensionSlotActivation, type ExtensionSlotSource, type IDeviceExtensionProvider } from '../capabilities/device-extension.cap.js';
|
|
18
|
+
import { type ExtensionSlotId, type ExtensionSlotValue } from '../generated/extension-slots.js';
|
|
19
|
+
/** The value shape of ONE slot, picked out of the generated union. */
|
|
20
|
+
export type ExtensionSlotValueOf<Id extends ExtensionSlotId> = Extract<ExtensionSlotValue, {
|
|
21
|
+
readonly slot: Id;
|
|
22
|
+
}>;
|
|
23
|
+
/** What an owner reads for one host: everything of the row but the routing. */
|
|
24
|
+
export interface ExtensionSlotListing<Id extends ExtensionSlotId> {
|
|
25
|
+
/** The store written (D62), `<addon>:<key>`. */
|
|
26
|
+
readonly authority: string;
|
|
27
|
+
/** graft: its switch; association: null. */
|
|
28
|
+
readonly enabled: boolean | null;
|
|
29
|
+
readonly activation: ExtensionSlotActivation | null;
|
|
30
|
+
readonly value: ExtensionSlotValueOf<Id>;
|
|
31
|
+
readonly sources: readonly ExtensionSlotSource[];
|
|
32
|
+
/** Linked by the owner's own structure, not picked (D655). Omit when none. */
|
|
33
|
+
readonly impliedSources?: readonly ExtensionSlotSource[];
|
|
34
|
+
}
|
|
35
|
+
/** The three functions an owner implements for one slot. */
|
|
36
|
+
export interface ExtensionSlotImpl<Id extends ExtensionSlotId> {
|
|
37
|
+
/** The slot as the owner's store holds it, or null when this host is not the owner's. */
|
|
38
|
+
list(deviceId: number): Promise<ExtensionSlotListing<Id> | null>;
|
|
39
|
+
/** Write through the owner's EXISTING path. Refuse by name before persisting. */
|
|
40
|
+
set(deviceId: number, value: ExtensionSlotValueOf<Id>): Promise<ExtensionSetResult>;
|
|
41
|
+
/** Devices the editor may offer, suggestions pre-marked and never saved. */
|
|
42
|
+
candidates(deviceId: number): Promise<readonly ExtensionCandidate[]>;
|
|
43
|
+
}
|
|
44
|
+
/** A slot bound to its owner, with the id erased so owners can hold a list. */
|
|
45
|
+
export interface ExtensionSlotProvider {
|
|
46
|
+
readonly slot: ExtensionSlotId;
|
|
47
|
+
list(deviceId: number): Promise<ExtensionSlotListing<ExtensionSlotId> | null>;
|
|
48
|
+
set(deviceId: number, value: ExtensionSlotValue): Promise<ExtensionSetResult>;
|
|
49
|
+
candidates(deviceId: number): Promise<readonly ExtensionCandidate[]>;
|
|
50
|
+
}
|
|
51
|
+
/** Bind slot `slot` to its owner's functions. See the module docblock. */
|
|
52
|
+
export declare function defineExtensionSlotProvider<Id extends ExtensionSlotId>(slot: Id, impl: ExtensionSlotImpl<Id>): ExtensionSlotProvider;
|
|
53
|
+
/** `<source>:<slotId>`. */
|
|
54
|
+
export declare function extensionSlotRef(source: string, slot: ExtensionSlotId): string;
|
|
55
|
+
export interface DeviceExtensionProviderOptions {
|
|
56
|
+
/** The routing prefix of every `slotRef` this owner serves. */
|
|
57
|
+
readonly source: string;
|
|
58
|
+
readonly label: string;
|
|
59
|
+
readonly slots: readonly ExtensionSlotProvider[];
|
|
60
|
+
/**
|
|
61
|
+
* The host's device type, answered LOCALLY by the owner (R6: a provider
|
|
62
|
+
* answers `[]` for a host it does not serve without a fleet round trip), or
|
|
63
|
+
* null when the owner does not know the device. A THROW is not "unknown":
|
|
64
|
+
* it propagates, and the dispatcher turns it into an `unreachable` row.
|
|
65
|
+
*/
|
|
66
|
+
readonly hostTypeOf: (deviceId: number) => Promise<string | null>;
|
|
67
|
+
readonly logger: IScopedLogger;
|
|
68
|
+
}
|
|
69
|
+
/** Build the `device-extension` provider one owner registers. */
|
|
70
|
+
export declare function createDeviceExtensionProvider(options: DeviceExtensionProviderOptions): IDeviceExtensionProvider;
|
|
@@ -40,6 +40,7 @@ import type { deviceAdminLinkCapability } from '../capabilities/device-admin-lin
|
|
|
40
40
|
import type { deviceAdoptionCapability } from '../capabilities/device-adoption.cap.js';
|
|
41
41
|
import type { deviceDiscoveryCapability } from '../capabilities/device-discovery.cap.js';
|
|
42
42
|
import type { deviceExportCapability } from '../capabilities/device-export.cap.js';
|
|
43
|
+
import type { deviceExtensionCapability } from '../capabilities/device-extension.cap.js';
|
|
43
44
|
import type { deviceManagerCapability } from '../capabilities/device-manager.cap.js';
|
|
44
45
|
import type { deviceOpsCapability } from '../capabilities/device-ops.cap.js';
|
|
45
46
|
import type { deviceProviderCapability } from '../capabilities/device-provider.cap.js';
|
|
@@ -2104,33 +2105,47 @@ export type AppRouter = TrpcCoreRouter<{
|
|
|
2104
2105
|
meta: object;
|
|
2105
2106
|
}>;
|
|
2106
2107
|
}>>;
|
|
2107
|
-
|
|
2108
|
+
deviceExtension: TRPCBuiltRouter<{
|
|
2108
2109
|
ctx: TrpcContext;
|
|
2109
2110
|
meta: object;
|
|
2110
2111
|
errorShape: AugmentedErrorShape;
|
|
2111
2112
|
transformer: true;
|
|
2112
2113
|
}, TRPCDecorateCreateRouterOptions<{
|
|
2113
|
-
|
|
2114
|
+
listSources: TRPCQueryProcedure<{
|
|
2114
2115
|
input: {
|
|
2115
2116
|
[x: string]: unknown;
|
|
2116
|
-
} & z.input<typeof
|
|
2117
|
-
output: z.infer<typeof
|
|
2117
|
+
} & z.input<typeof deviceExtensionCapability.methods.listSources.input>;
|
|
2118
|
+
output: z.infer<typeof deviceExtensionCapability.methods.listSources.output>;
|
|
2118
2119
|
meta: object;
|
|
2119
2120
|
}>;
|
|
2120
|
-
|
|
2121
|
+
listSlots: TRPCQueryProcedure<{
|
|
2121
2122
|
input: {
|
|
2122
2123
|
[x: string]: unknown;
|
|
2123
|
-
} & z.input<typeof
|
|
2124
|
-
output: z.infer<typeof
|
|
2124
|
+
} & z.input<typeof deviceExtensionCapability.methods.listSlots.input>;
|
|
2125
|
+
output: z.infer<typeof deviceExtensionCapability.methods.listSlots.output>;
|
|
2125
2126
|
meta: object;
|
|
2126
2127
|
}>;
|
|
2127
|
-
|
|
2128
|
+
listCandidates: TRPCQueryProcedure<{
|
|
2128
2129
|
input: {
|
|
2129
2130
|
[x: string]: unknown;
|
|
2130
|
-
} & z.input<typeof
|
|
2131
|
-
output: z.infer<typeof
|
|
2131
|
+
} & z.input<typeof deviceExtensionCapability.methods.listCandidates.input>;
|
|
2132
|
+
output: z.infer<typeof deviceExtensionCapability.methods.listCandidates.output>;
|
|
2133
|
+
meta: object;
|
|
2134
|
+
}>;
|
|
2135
|
+
setSlot: TRPCMutationProcedure<{
|
|
2136
|
+
input: {
|
|
2137
|
+
[x: string]: unknown;
|
|
2138
|
+
} & z.input<typeof deviceExtensionCapability.methods.setSlot.input>;
|
|
2139
|
+
output: z.infer<typeof deviceExtensionCapability.methods.setSlot.output>;
|
|
2132
2140
|
meta: object;
|
|
2133
2141
|
}>;
|
|
2142
|
+
}>>;
|
|
2143
|
+
deviceManager: TRPCBuiltRouter<{
|
|
2144
|
+
ctx: TrpcContext;
|
|
2145
|
+
meta: object;
|
|
2146
|
+
errorShape: AugmentedErrorShape;
|
|
2147
|
+
transformer: true;
|
|
2148
|
+
}, TRPCDecorateCreateRouterOptions<{
|
|
2134
2149
|
allocateDeviceId: TRPCMutationProcedure<{
|
|
2135
2150
|
input: {
|
|
2136
2151
|
[x: string]: unknown;
|
|
@@ -2982,27 +2997,6 @@ export type AppRouter = TrpcCoreRouter<{
|
|
|
2982
2997
|
output: z.infer<typeof DEVICE_STATUS_METHOD.getStatus.output>;
|
|
2983
2998
|
meta: object;
|
|
2984
2999
|
}>;
|
|
2985
|
-
getDeviceSettingsContribution: TRPCQueryProcedure<{
|
|
2986
|
-
input: {
|
|
2987
|
-
[x: string]: unknown;
|
|
2988
|
-
} & z.input<typeof DEVICE_SETTINGS_CONTRIBUTION_METHODS.getDeviceSettingsContribution.input>;
|
|
2989
|
-
output: z.infer<typeof DEVICE_SETTINGS_CONTRIBUTION_METHODS.getDeviceSettingsContribution.output>;
|
|
2990
|
-
meta: object;
|
|
2991
|
-
}>;
|
|
2992
|
-
getDeviceLiveContribution: TRPCQueryProcedure<{
|
|
2993
|
-
input: {
|
|
2994
|
-
[x: string]: unknown;
|
|
2995
|
-
} & z.input<typeof DEVICE_SETTINGS_CONTRIBUTION_METHODS.getDeviceLiveContribution.input>;
|
|
2996
|
-
output: z.infer<typeof DEVICE_SETTINGS_CONTRIBUTION_METHODS.getDeviceLiveContribution.output>;
|
|
2997
|
-
meta: object;
|
|
2998
|
-
}>;
|
|
2999
|
-
applyDeviceSettingsPatch: TRPCMutationProcedure<{
|
|
3000
|
-
input: {
|
|
3001
|
-
[x: string]: unknown;
|
|
3002
|
-
} & z.input<typeof DEVICE_SETTINGS_CONTRIBUTION_METHODS.applyDeviceSettingsPatch.input>;
|
|
3003
|
-
output: z.infer<typeof DEVICE_SETTINGS_CONTRIBUTION_METHODS.applyDeviceSettingsPatch.output>;
|
|
3004
|
-
meta: object;
|
|
3005
|
-
}>;
|
|
3006
3000
|
}>>;
|
|
3007
3001
|
embeddingEncoder: TRPCBuiltRouter<{
|
|
3008
3002
|
ctx: TrpcContext;
|
|
@@ -3032,6 +3026,13 @@ export type AppRouter = TrpcCoreRouter<{
|
|
|
3032
3026
|
output: z.infer<typeof embeddingEncoderCapability.methods.getInfo.output>;
|
|
3033
3027
|
meta: object;
|
|
3034
3028
|
}>;
|
|
3029
|
+
resetFailedModels: TRPCMutationProcedure<{
|
|
3030
|
+
input: {
|
|
3031
|
+
[x: string]: unknown;
|
|
3032
|
+
} & z.input<typeof embeddingEncoderCapability.methods.resetFailedModels.input>;
|
|
3033
|
+
output: z.infer<typeof embeddingEncoderCapability.methods.resetFailedModels.output>;
|
|
3034
|
+
meta: object;
|
|
3035
|
+
}>;
|
|
3035
3036
|
}>>;
|
|
3036
3037
|
enumSensor: TRPCBuiltRouter<{
|
|
3037
3038
|
ctx: TrpcContext;
|
|
@@ -6080,6 +6081,13 @@ export type AppRouter = TrpcCoreRouter<{
|
|
|
6080
6081
|
output: z.infer<typeof pipelineOrchestratorCapability.methods.getAgentLoad.output>;
|
|
6081
6082
|
meta: object;
|
|
6082
6083
|
}>;
|
|
6084
|
+
getClusterModelChoice: TRPCQueryProcedure<{
|
|
6085
|
+
input: {
|
|
6086
|
+
[x: string]: unknown;
|
|
6087
|
+
} & z.input<typeof pipelineOrchestratorCapability.methods.getClusterModelChoice.input>;
|
|
6088
|
+
output: z.infer<typeof pipelineOrchestratorCapability.methods.getClusterModelChoice.output>;
|
|
6089
|
+
meta: object;
|
|
6090
|
+
}>;
|
|
6083
6091
|
getGlobalMetrics: TRPCQueryProcedure<{
|
|
6084
6092
|
input: {
|
|
6085
6093
|
nodeId?: string | undefined;
|
|
@@ -46,6 +46,7 @@ export { deviceAdminLinkCapability } from '../capabilities/device-admin-link.cap
|
|
|
46
46
|
export { deviceAdoptionCapability } from '../capabilities/device-adoption.cap.js';
|
|
47
47
|
export { deviceDiscoveryCapability } from '../capabilities/device-discovery.cap.js';
|
|
48
48
|
export { deviceExportCapability } from '../capabilities/device-export.cap.js';
|
|
49
|
+
export { deviceExtensionCapability } from '../capabilities/device-extension.cap.js';
|
|
49
50
|
export { deviceManagerCapability } from '../capabilities/device-manager.cap.js';
|
|
50
51
|
export { deviceOpsCapability } from '../capabilities/device-ops.cap.js';
|
|
51
52
|
export { deviceProviderCapability } from '../capabilities/device-provider.cap.js';
|
|
@@ -207,6 +208,7 @@ export declare const CAPABILITY_NAMES: {
|
|
|
207
208
|
readonly deviceAdoption: "device-adoption";
|
|
208
209
|
readonly deviceDiscovery: "device-discovery";
|
|
209
210
|
readonly deviceExport: "device-export";
|
|
211
|
+
readonly deviceExtension: "device-extension";
|
|
210
212
|
readonly deviceManager: "device-manager";
|
|
211
213
|
readonly deviceOps: "device-ops";
|
|
212
214
|
readonly deviceProvider: "device-provider";
|
|
@@ -381,6 +383,7 @@ export interface CapabilityRouterMap<TRouter = unknown> {
|
|
|
381
383
|
readonly deviceAdoption: TRouter;
|
|
382
384
|
readonly deviceDiscovery: TRouter;
|
|
383
385
|
readonly deviceExport: TRouter;
|
|
386
|
+
readonly deviceExtension: TRouter;
|
|
384
387
|
readonly deviceManager: TRouter;
|
|
385
388
|
readonly deviceOps: TRouter;
|
|
386
389
|
readonly deviceProvider: TRouter;
|
|
@@ -498,8 +501,8 @@ export interface CapabilityRouterMap<TRouter = unknown> {
|
|
|
498
501
|
export declare const SINGLETON_CAPABILITY_NAMES: readonly ["accessories", "addon-pages", "addon-settings", "addon-widgets", "addons", "admin-ui", "air-quality-sensor", "alarm-panel", "alerts", "ambient-light-sensor", "audio-analysis", "audio-analyzer", "audio-codec", "audio-metrics", "automation-control", "backup", "battery", "binary", "brightness", "button", "camera-credentials", "camera-grid-layout", "camera-pipeline-config", "camera-streams", "carbon-monoxide", "climate-control", "color", "connectivity", "consumables", "contact", "control", "core-blocks", "cover", "day-night", "decoder", "detection-pipeline", "device-admin-link", "device-adoption", "device-discovery", "device-manager", "device-ops", "device-state", "device-status", "doorbell", "enum-sensor", "event-emitter", "face-gallery", "fan-control", "feature-probe", "filesystem-browse", "flood", "gas", "humidifier", "humidity-sensor", "image", "image-settings", "integrations", "intercom", "lawn-mower-control", "llm-runtime", "local-network", "lock-control", "media-player", "metrics-provider", "model-convert", "model-distributor", "motion", "motion-detection", "motion-trigger", "motion-zones", "native-object-detection", "navigation", "network-link", "network-quality", "nodes", "notification-rules", "notifier", "numeric-sensor", "osd", "osd-manager", "pet-feeder", "pipeline-analytics", "pipeline-executor", "pipeline-orchestrator", "pipeline-runner", "plate-gallery", "platform-probe", "power-meter", "presence", "pressure-sensor", "privacy-mask", "ptz", "ptz-autotrack", "reboot", "recording-archive", "recording-export", "recording-onboard", "recording-signal", "scene-monitor", "script-runner", "server-management", "settings-store", "smoke", "snapshot", "sso-bridge", "storage", "storage-migration", "stream-broker", "stream-catalog", "stream-params", "stream-signals", "switch", "system", "tamper", "temperature-sensor", "terminal-session", "toast", "update", "user-management", "vacuum-control", "valve", "vector-store", "vibration", "viewer-ui", "water-heater", "weather", "webrtc-session", "zone-analytics", "zone-rules", "zones"];
|
|
499
502
|
/** Union of singleton capability names (literal string union). */
|
|
500
503
|
export type SingletonCapabilityName = typeof SINGLETON_CAPABILITY_NAMES[number];
|
|
501
|
-
/** Capability names whose mode is `collection` (
|
|
502
|
-
export declare const COLLECTION_CAPABILITY_NAMES: readonly ["addon-pages-source", "addon-routes", "addon-widgets-source", "auth-provider", "broker", "connection-test", "custom-model-registry", "data-store-provider", "device-export", "device-provider", "embedding-encoder", "failure-contribution", "llm", "load-contribution", "log-channels", "log-destination", "login-method", "mesh-network", "mqtt-broker", "network-access", "notification-output", "oauth-integration", "recording", "smtp-provider", "storage-evictable", "storage-occupancy", "storage-provider", "turn-provider", "user-passkeys", "videoclips"];
|
|
504
|
+
/** Capability names whose mode is `collection` (31 caps). */
|
|
505
|
+
export declare const COLLECTION_CAPABILITY_NAMES: readonly ["addon-pages-source", "addon-routes", "addon-widgets-source", "auth-provider", "broker", "connection-test", "custom-model-registry", "data-store-provider", "device-export", "device-extension", "device-provider", "embedding-encoder", "failure-contribution", "llm", "load-contribution", "log-channels", "log-destination", "login-method", "mesh-network", "mqtt-broker", "network-access", "notification-output", "oauth-integration", "recording", "smtp-provider", "storage-evictable", "storage-occupancy", "storage-provider", "turn-provider", "user-passkeys", "videoclips"];
|
|
503
506
|
/** Union of collection capability names (literal string union). */
|
|
504
507
|
export type CollectionCapabilityName = typeof COLLECTION_CAPABILITY_NAMES[number];
|
|
505
508
|
/** Capability mode lookup at runtime — mirrors the `.cap.ts` definitions. */
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
* barrel (`ALL_CAPABILITY_DEFINITIONS`), which would cost ~144MB RSS per
|
|
9
9
|
* forked runner. See docs/decisions/adr-0028.md.
|
|
10
10
|
*
|
|
11
|
-
* Coverage:
|
|
11
|
+
* Coverage: 24 collection caps, 39 array methods.
|
|
12
12
|
*/
|
|
13
13
|
export declare const COLLECTION_ARRAY_METHODS: Readonly<Record<string, readonly string[]>>;
|
|
14
14
|
/**
|
|
@@ -15,6 +15,7 @@ import type { brightnessCapability } from '../capabilities/brightness.cap.js';
|
|
|
15
15
|
import type { buttonCapability } from '../capabilities/button.cap.js';
|
|
16
16
|
import type { cameraCredentialsCapability } from '../capabilities/camera-credentials.cap.js';
|
|
17
17
|
import type { cameraGridLayoutCapability } from '../capabilities/camera-grid-layout.cap.js';
|
|
18
|
+
import type { cameraPipelineConfigCapability } from '../capabilities/camera-pipeline-config.cap.js';
|
|
18
19
|
import type { cameraStreamsCapability } from '../capabilities/camera-streams.cap.js';
|
|
19
20
|
import type { carbonMonoxideCapability } from '../capabilities/carbon-monoxide.cap.js';
|
|
20
21
|
import type { climateControlCapability } from '../capabilities/climate-control.cap.js';
|
|
@@ -28,6 +29,7 @@ import type { dayNightCapability } from '../capabilities/day-night.cap.js';
|
|
|
28
29
|
import type { detectionPipelineCapability } from '../capabilities/detection-pipeline.cap.js';
|
|
29
30
|
import type { deviceAdminLinkCapability } from '../capabilities/device-admin-link.cap.js';
|
|
30
31
|
import type { deviceDiscoveryCapability } from '../capabilities/device-discovery.cap.js';
|
|
32
|
+
import type { deviceExtensionCapability } from '../capabilities/device-extension.cap.js';
|
|
31
33
|
import type { deviceOpsCapability } from '../capabilities/device-ops.cap.js';
|
|
32
34
|
import type { deviceStatusCapability } from '../capabilities/device-status.cap.js';
|
|
33
35
|
import type { doorbellCapability } from '../capabilities/doorbell.cap.js';
|
|
@@ -52,7 +54,6 @@ import type { motionZonesCapability } from '../capabilities/motion-zones.cap.js'
|
|
|
52
54
|
import type { nativeObjectDetectionCapability } from '../capabilities/native-object-detection.cap.js';
|
|
53
55
|
import type { navigationCapability } from '../capabilities/navigation.cap.js';
|
|
54
56
|
import type { networkLinkCapability } from '../capabilities/network-link.cap.js';
|
|
55
|
-
import type { notificationRulesCapability } from '../capabilities/notification-rules.cap.js';
|
|
56
57
|
import type { notifierCapability } from '../capabilities/notifier.cap.js';
|
|
57
58
|
import type { numericSensorCapability } from '../capabilities/numeric-sensor.cap.js';
|
|
58
59
|
import type { osdCapability } from '../capabilities/osd.cap.js';
|
|
@@ -91,14 +92,13 @@ import type { zoneRulesCapability } from '../capabilities/zone-rules.cap.js';
|
|
|
91
92
|
import type { zonesCapability } from '../capabilities/zones.cap.js';
|
|
92
93
|
import type { addonSettingsCapability } from '../capabilities/addon-settings.cap.js';
|
|
93
94
|
import type { audioAnalyzerCapability } from '../capabilities/audio-analyzer.cap.js';
|
|
94
|
-
import type { cameraPipelineConfigCapability } from '../capabilities/camera-pipeline-config.cap.js';
|
|
95
95
|
import type { deviceAdoptionCapability } from '../capabilities/device-adoption.cap.js';
|
|
96
96
|
import type { deviceExportCapability } from '../capabilities/device-export.cap.js';
|
|
97
97
|
import type { deviceManagerCapability } from '../capabilities/device-manager.cap.js';
|
|
98
|
-
import type { deviceProviderCapability } from '../capabilities/device-provider.cap.js';
|
|
99
98
|
import type { deviceStateCapability } from '../capabilities/device-state.cap.js';
|
|
100
99
|
import type { faceGalleryCapability } from '../capabilities/face-gallery.cap.js';
|
|
101
100
|
import type { networkQualityCapability } from '../capabilities/network-quality.cap.js';
|
|
101
|
+
import type { notificationRulesCapability } from '../capabilities/notification-rules.cap.js';
|
|
102
102
|
import type { osdManagerCapability } from '../capabilities/osd-manager.cap.js';
|
|
103
103
|
import type { pipelineExecutorCapability } from '../capabilities/pipeline-executor.cap.js';
|
|
104
104
|
import type { pipelineOrchestratorCapability } from '../capabilities/pipeline-orchestrator.cap.js';
|
|
@@ -214,6 +214,7 @@ export interface DeviceProxy {
|
|
|
214
214
|
readonly button?: InferDeviceProxyCap<typeof buttonCapability>;
|
|
215
215
|
readonly cameraCredentials?: InferDeviceProxyCap<typeof cameraCredentialsCapability>;
|
|
216
216
|
readonly cameraGridLayout?: InferDeviceProxyCap<typeof cameraGridLayoutCapability>;
|
|
217
|
+
readonly cameraPipelineConfig?: InferDeviceProxyCap<typeof cameraPipelineConfigCapability>;
|
|
217
218
|
readonly cameraStreams?: InferDeviceProxyCap<typeof cameraStreamsCapability>;
|
|
218
219
|
readonly carbonMonoxide?: InferDeviceProxyCap<typeof carbonMonoxideCapability>;
|
|
219
220
|
readonly climateControl?: InferDeviceProxyCap<typeof climateControlCapability>;
|
|
@@ -227,6 +228,7 @@ export interface DeviceProxy {
|
|
|
227
228
|
readonly detectionPipeline?: InferDeviceProxyCap<typeof detectionPipelineCapability>;
|
|
228
229
|
readonly deviceAdminLink?: InferDeviceProxyCap<typeof deviceAdminLinkCapability>;
|
|
229
230
|
readonly deviceDiscovery?: InferDeviceProxyCap<typeof deviceDiscoveryCapability>;
|
|
231
|
+
readonly deviceExtension?: InferDeviceProxyCap<typeof deviceExtensionCapability>;
|
|
230
232
|
readonly deviceOps?: InferDeviceProxyCap<typeof deviceOpsCapability>;
|
|
231
233
|
readonly deviceStatus?: InferDeviceProxyCap<typeof deviceStatusCapability>;
|
|
232
234
|
readonly doorbell?: InferDeviceProxyCap<typeof doorbellCapability>;
|
|
@@ -251,7 +253,6 @@ export interface DeviceProxy {
|
|
|
251
253
|
readonly nativeObjectDetection?: InferDeviceProxyCap<typeof nativeObjectDetectionCapability>;
|
|
252
254
|
readonly navigation?: InferDeviceProxyCap<typeof navigationCapability>;
|
|
253
255
|
readonly networkLink?: InferDeviceProxyCap<typeof networkLinkCapability>;
|
|
254
|
-
readonly notificationRules?: InferDeviceProxyCap<typeof notificationRulesCapability>;
|
|
255
256
|
readonly notifier?: InferDeviceProxyCap<typeof notifierCapability>;
|
|
256
257
|
readonly numericSensor?: InferDeviceProxyCap<typeof numericSensorCapability>;
|
|
257
258
|
readonly osd?: InferDeviceProxyCap<typeof osdCapability>;
|
|
@@ -290,17 +291,16 @@ export interface DeviceProxy {
|
|
|
290
291
|
readonly zones?: InferDeviceProxyCap<typeof zonesCapability>;
|
|
291
292
|
readonly addonSettings: Pick<InferDeviceProxyCap<typeof addonSettingsCapability>, 'getDeviceSettings' | 'updateDeviceSettings'>;
|
|
292
293
|
readonly audioAnalyzer: Pick<InferDeviceProxyCap<typeof audioAnalyzerCapability>, 'detachDevice'>;
|
|
293
|
-
readonly cameraPipelineConfig: Pick<InferDeviceProxyCap<typeof cameraPipelineConfigCapability>, 'getDeviceSettingsContribution' | 'getDeviceLiveContribution' | 'applyDeviceSettingsPatch'>;
|
|
294
294
|
readonly deviceAdoption: Pick<InferDeviceProxyCap<typeof deviceAdoptionCapability>, 'getStatus'>;
|
|
295
295
|
readonly deviceExport: Pick<InferDeviceProxyCap<typeof deviceExportCapability>, 'getDeviceSettingsContribution' | 'getDeviceLiveContribution' | 'applyDeviceSettingsPatch'>;
|
|
296
|
-
readonly deviceManager: Pick<InferDeviceProxyCap<typeof deviceManagerCapability>, 'loadConfig' | 'loadRuntimeState' | 'loadMeta' | 'setName' | 'setLocation' | 'setType' | 'setIntegrationId' | 'setLinkDeviceId' | 'setPrimaryChildEntityId' | 'setChildLayout' | 'setDisplay' | 'getWireableFields' | 'setRole' | 'applyInitialMeta' | 'setMetadata' | 'setDisabled' | 'getDevice' | 'getLinkedDevices' | 'getStreamSources' | 'getConfigSchema' | 'getSettingsSchema' | 'updateConfig' | 'enable' | 'disable' | 'remove' | 'getStreamProfileMap' | 'setStreamProfileMap' | 'probeStreams' | 'getBindings' | 'setWrapperActive' | 'getDeviceSettingsAggregate' | 'getDeviceLiveInfoAggregate' | 'getDeviceAggregate' | 'runDeviceAction' | 'updateDeviceField' | 'updateDeviceFieldsBatch' | 'testField' | 'getDeviceStatusAggregate'
|
|
297
|
-
readonly deviceProvider: Pick<InferDeviceProxyCap<typeof deviceProviderCapability>, 'reloadDevice'>;
|
|
296
|
+
readonly deviceManager: Pick<InferDeviceProxyCap<typeof deviceManagerCapability>, 'loadConfig' | 'loadRuntimeState' | 'loadMeta' | 'setName' | 'setLocation' | 'setType' | 'setIntegrationId' | 'setLinkDeviceId' | 'setPrimaryChildEntityId' | 'setChildLayout' | 'setDisplay' | 'getWireableFields' | 'setRole' | 'applyInitialMeta' | 'setMetadata' | 'setDisabled' | 'getDevice' | 'getLinkedDevices' | 'getStreamSources' | 'getConfigSchema' | 'getSettingsSchema' | 'updateConfig' | 'enable' | 'disable' | 'remove' | 'getStreamProfileMap' | 'setStreamProfileMap' | 'probeStreams' | 'getBindings' | 'setWrapperActive' | 'getDeviceSettingsAggregate' | 'getDeviceLiveInfoAggregate' | 'getDeviceAggregate' | 'runDeviceAction' | 'updateDeviceField' | 'updateDeviceFieldsBatch' | 'testField' | 'getDeviceStatusAggregate'>;
|
|
298
297
|
readonly deviceState: Pick<InferDeviceProxyCap<typeof deviceStateCapability>, 'getSnapshot' | 'getCapSlice' | 'setCapSlice'>;
|
|
299
298
|
readonly faceGallery: Pick<InferDeviceProxyCap<typeof faceGalleryCapability>, 'listRecentFaces' | 'getFaceByTrack'>;
|
|
300
299
|
readonly networkQuality: Pick<InferDeviceProxyCap<typeof networkQualityCapability>, 'getDeviceStats' | 'reportClientStats'>;
|
|
300
|
+
readonly notificationRules: Pick<InferDeviceProxyCap<typeof notificationRulesCapability>, 'setDeviceMuted'>;
|
|
301
301
|
readonly osdManager: Pick<InferDeviceProxyCap<typeof osdManagerCapability>, 'getDeviceOsd' | 'getSourceCatalog' | 'setSlotBinding' | 'clearSlotBinding' | 'previewSlot' | 'renderDevice'>;
|
|
302
302
|
readonly pipelineExecutor: Pick<InferDeviceProxyCap<typeof pipelineExecutorCapability>, 'runPipeline' | 'runPipelineBatch'>;
|
|
303
|
-
readonly pipelineOrchestrator: Pick<InferDeviceProxyCap<typeof pipelineOrchestratorCapability>, 'assignPipeline' | 'unassignPipeline' | 'setPipelineDevicePin' | 'getPipelineDevicePin' | 'getPipelineAssignment' | 'getCameraMetrics' | 'assignAudio' | 'unassignAudio' | 'getAudioAssignment' | '
|
|
303
|
+
readonly pipelineOrchestrator: Pick<InferDeviceProxyCap<typeof pipelineOrchestratorCapability>, 'assignPipeline' | 'unassignPipeline' | 'setPipelineDevicePin' | 'getPipelineDevicePin' | 'getPipelineAssignment' | 'getCameraMetrics' | 'assignAudio' | 'unassignAudio' | 'getAudioAssignment' | 'getCameraSettings' | 'setCameraStepToggle' | 'getCameraStepOverrides' | 'setCameraStepOverride' | 'setCameraPipelineForAgent' | 'resolvePipeline' | 'getCameraSwitches' | 'setCameraSwitch' | 'getCameraStatus' | 'getDeviceSettingsContribution' | 'getDeviceLiveContribution' | 'applyDeviceSettingsPatch'>;
|
|
304
304
|
readonly pipelineRunner: Pick<InferDeviceProxyCap<typeof pipelineRunnerCapability>, 'detachCamera' | 'getCameraMetrics' | 'requestOccupancyBurst' | 'runDetailSubtree' | 'parkTrackFrame' | 'getParkedTrackFrame' | 'releaseParkedTrackFrames'>;
|
|
305
305
|
readonly plateGallery: Pick<InferDeviceProxyCap<typeof plateGalleryCapability>, 'listPlates' | 'getPlateByTrack'>;
|
|
306
306
|
readonly recordingArchive: Pick<InferDeviceProxyCap<typeof recordingArchiveCapability>, 'getDeviceConfig' | 'locateSegment' | 'readSegmentBytes' | 'readGopBytes' | 'readWindowBytes' | 'setDeviceConfig' | 'rescanStorage' | 'pruneFootage' | 'deleteFootprint' | 'renderGif' | 'renderClip' | 'getStatus' | 'getDeviceSettingsContribution' | 'getDeviceLiveContribution' | 'applyDeviceSettingsPatch'>;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* can answer "may a rule actuate this?" without importing the schema barrel
|
|
6
6
|
* (~144MB RSS per runner, D28).
|
|
7
7
|
*
|
|
8
|
-
* Coverage:
|
|
8
|
+
* Coverage: 88 device-scoped capabilities.
|
|
9
9
|
*/
|
|
10
10
|
export declare const DEVICE_SCOPED_CAPS: ReadonlySet<string>;
|
|
11
11
|
/**
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* AUTO-GENERATED by scripts/generate-extension-slots.ts — DO NOT EDIT.
|
|
3
|
+
*
|
|
4
|
+
* Every extension slot declared by a capability (`extensionSlots` in its
|
|
5
|
+
* `*.cap.ts`, D648), folded into one typed table. Imports ONLY the declaring
|
|
6
|
+
* caps' descriptors and value schemas — never the caps barrel — so
|
|
7
|
+
* `device-extension.cap.ts` can import this module without a cycle.
|
|
8
|
+
*
|
|
9
|
+
* Coverage: 2 slot(s).
|
|
10
|
+
*/
|
|
11
|
+
import { z } from 'zod';
|
|
12
|
+
import { DeviceType } from '../device/device-type.js';
|
|
13
|
+
import type { ExtensionSlotDescriptor } from '../device-extension/slot-descriptor.js';
|
|
14
|
+
/** Every declared slot id, in table order. */
|
|
15
|
+
export declare const EXTENSION_SLOT_IDS: readonly ["doorbell-source", "linked-devices"];
|
|
16
|
+
export declare const ExtensionSlotIdSchema: z.ZodEnum<{
|
|
17
|
+
"linked-devices": "linked-devices";
|
|
18
|
+
"doorbell-source": "doorbell-source";
|
|
19
|
+
}>;
|
|
20
|
+
export type ExtensionSlotId = z.infer<typeof ExtensionSlotIdSchema>;
|
|
21
|
+
/** One row of the table: the descriptor, who declared it, where it is offered. */
|
|
22
|
+
export interface ExtensionSlotEntry {
|
|
23
|
+
readonly descriptor: ExtensionSlotDescriptor;
|
|
24
|
+
readonly declaringCap: string;
|
|
25
|
+
/** `descriptor.hostDeviceTypes ?? declaringCap.deviceTypes`, resolved here. */
|
|
26
|
+
readonly hostDeviceTypes: readonly DeviceType[];
|
|
27
|
+
}
|
|
28
|
+
export declare const EXTENSION_SLOTS: Readonly<Record<ExtensionSlotId, ExtensionSlotEntry>>;
|
|
29
|
+
/** A slot's editable value, discriminated on `slot`. */
|
|
30
|
+
export declare const ExtensionSlotValueSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
31
|
+
deviceIds: z.ZodArray<z.ZodNumber>;
|
|
32
|
+
slot: z.ZodLiteral<"doorbell-source">;
|
|
33
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
34
|
+
deviceIds: z.ZodArray<z.ZodNumber>;
|
|
35
|
+
trackedDeviceIds: z.ZodOptional<z.ZodArray<z.ZodNumber>>;
|
|
36
|
+
slot: z.ZodLiteral<"linked-devices">;
|
|
37
|
+
}, z.core.$strip>], "slot">;
|
|
38
|
+
export type ExtensionSlotValue = z.infer<typeof ExtensionSlotValueSchema>;
|
|
39
|
+
/** Every device type at least one slot is offered on — `device-extension`'s `deviceTypes`. */
|
|
40
|
+
export declare const EXTENSION_HOST_DEVICE_TYPES: readonly DeviceType[];
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* scope+access check inside `protectedProcedure` (see
|
|
7
7
|
* `server/backend/src/api/trpc/trpc.middleware.ts`).
|
|
8
8
|
*
|
|
9
|
-
* Coverage: 1178 method paths across
|
|
9
|
+
* Coverage: 1178 method paths across 161 capabilities.
|
|
10
10
|
*/
|
|
11
11
|
import type { CapabilityMethodAccess } from '../capabilities/capability-definition.js';
|
|
12
12
|
export interface MethodAccessRecord {
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* system-scope cap that takes a deviceId was previously never device-filtered
|
|
7
7
|
* — see the generator header).
|
|
8
8
|
*
|
|
9
|
-
* Coverage:
|
|
9
|
+
* Coverage: 399 methods carry a device reference, of which
|
|
10
10
|
* 138 are on SYSTEM-scope caps.
|
|
11
11
|
*
|
|
12
12
|
* Top-level fields, number arrays, and one-level arrays of objects carrying
|
|
@@ -28,6 +28,7 @@ import type { networkAccessCapability } from '../capabilities/network-access.cap
|
|
|
28
28
|
import type { networkQualityCapability } from '../capabilities/network-quality.cap.js';
|
|
29
29
|
import type { nodesCapability } from '../capabilities/nodes.cap.js';
|
|
30
30
|
import type { notificationOutputCapability } from '../capabilities/notification-output.cap.js';
|
|
31
|
+
import type { notificationRulesCapability } from '../capabilities/notification-rules.cap.js';
|
|
31
32
|
import type { osdManagerCapability } from '../capabilities/osd-manager.cap.js';
|
|
32
33
|
import type { pipelineExecutorCapability } from '../capabilities/pipeline-executor.cap.js';
|
|
33
34
|
import type { pipelineOrchestratorCapability } from '../capabilities/pipeline-orchestrator.cap.js';
|
|
@@ -69,7 +70,7 @@ export interface SystemProxy {
|
|
|
69
70
|
readonly deviceAdoption: Pick<InferProvider<typeof deviceAdoptionCapability>, 'listCandidateFilters' | 'listCandidates' | 'getCandidate' | 'refresh' | 'adopt' | 'release' | 'resync'>;
|
|
70
71
|
readonly deviceExport: Pick<InferProvider<typeof deviceExportCapability>, 'getStatus' | 'listSupportedDeviceKinds' | 'listExposedDevices' | 'exposeDevice' | 'unexposeDevice'>;
|
|
71
72
|
readonly deviceManager: Pick<InferProvider<typeof deviceManagerCapability>, 'allocateDeviceId' | 'migrateDevice' | 'registerDevice' | 'removeDevice' | 'persistConfig' | 'getRoleDisplayDefaults' | 'setRoleDisplayDefaults' | 'listLocations' | 'addLocation' | 'removeLocation' | 'renameLocation' | 'listLocationIcons' | 'setLocationIcon' | 'listLocationDescriptions' | 'setLocationDescription' | 'listSiteZones' | 'setSiteZone' | 'removeSiteZone' | 'renameSiteZone' | 'setLocationZone' | 'listPersistedByAddon' | 'listAll' | 'getChildren' | 'getChildrenBatch' | 'getLinkedDevicesBatch' | 'removeByIntegration' | 'getBindingsBatch' | 'getAllBindings' | 'listDeviceIdsByCaps' | 'listWrappersForCap' | 'listBindableCapsForDeviceType' | 'discoverDevices' | 'adoptDevice' | 'getCreationSchema' | 'createDevice' | 'testCreationField' | 'adoptionListCandidateFilters' | 'adoptionListCandidates' | 'adoptionRefresh' | 'adoptionAdopt' | 'adoptionRelease' | 'adoptionStartJob' | 'adoptionListJobs' | 'adoptionCancelJob' | 'adoptionResync' | 'discoveryProviders' | 'discoverAllProviders' | 'discoverProvider' | 'providerCreationType' | 'providerDiscoveryParamsSchema' | 'getDeviceStatusAggregateBatch'>;
|
|
72
|
-
readonly deviceProvider: Pick<InferProvider<typeof deviceProviderCapability>, 'start' | 'stop' | 'getStatus' | 'getDevices' | 'supportsDiscovery' | 'discoverDevices' | 'getDiscoveryParamsSchema' | 'getManualCreationType' | 'adoptDiscoveredDevice' | 'supportsManualCreation' | 'getChildCreationSchema' | 'createDevice' | 'testCreationField'>;
|
|
73
|
+
readonly deviceProvider: Pick<InferProvider<typeof deviceProviderCapability>, 'start' | 'stop' | 'getStatus' | 'getDevices' | 'reloadDevice' | 'supportsDiscovery' | 'discoverDevices' | 'getDiscoveryParamsSchema' | 'getManualCreationType' | 'adoptDiscoveredDevice' | 'supportsManualCreation' | 'getChildCreationSchema' | 'createDevice' | 'testCreationField'>;
|
|
73
74
|
readonly deviceState: Pick<InferProvider<typeof deviceStateCapability>, 'getAllSnapshots'>;
|
|
74
75
|
readonly faceGallery: Pick<InferProvider<typeof faceGalleryCapability>, 'listIdentities' | 'createIdentity' | 'renameIdentity' | 'deleteIdentity' | 'listIdentitySamples' | 'auditIdentitySamples' | 'removeSample' | 'getFaceMedia' | 'assignFace' | 'unassignFace' | 'deleteFace' | 'assignFaces' | 'unassignFaces' | 'suggestFaceClusters'>;
|
|
75
76
|
readonly integrations: Pick<InferProvider<typeof integrationsCapability>, 'list' | 'get' | 'getByAddonId' | 'create' | 'update' | 'delete' | 'getSettings' | 'setSettings' | 'getAvailableTypes' | 'testConnection'>;
|
|
@@ -82,9 +83,10 @@ export interface SystemProxy {
|
|
|
82
83
|
readonly networkQuality: Pick<InferProvider<typeof networkQualityCapability>, 'getAllStats'>;
|
|
83
84
|
readonly nodes: Pick<InferProvider<typeof nodesCapability>, 'topology' | 'directory' | 'deployAddon' | 'undeployAddon' | 'restartAddon' | 'restartProcess' | 'restartNode' | 'shutdownNode' | 'renameNode' | 'clusterAddonStatus' | 'getCapUsageGraph' | 'getNodeAddons' | 'setProcessLogLevel' | 'executeQuery'>;
|
|
84
85
|
readonly notificationOutput: Pick<InferProvider<typeof notificationOutputCapability>, 'listTargetKinds' | 'listTargets' | 'discoverTargets' | 'send' | 'testTarget' | 'upsertTarget' | 'deleteTarget' | 'setTargetEnabled'>;
|
|
86
|
+
readonly notificationRules: Pick<InferProvider<typeof notificationRulesCapability>, 'listRules' | 'getRule' | 'createRule' | 'updateRule' | 'deleteRule' | 'setRuleEnabled' | 'getClipRetentionAsks' | 'listDeviceMutes' | 'testRule' | 'previewStateSummary' | 'getConditionCatalog' | 'getTemplateCatalog' | 'previewTemplate' | 'getHistory' | 'getRuleLastRuns' | 'resolveArtifactUrl' | 'listSnoozes' | 'createSnooze' | 'cancelSnooze' | 'getAlarmConfig' | 'setAlarmConfig'>;
|
|
85
87
|
readonly osdManager: Pick<InferProvider<typeof osdManagerCapability>, 'getConditionSupport' | 'copyDeviceConfiguration'>;
|
|
86
88
|
readonly pipelineExecutor: Pick<InferProvider<typeof pipelineExecutorCapability>, 'getAvailableEngines' | 'getSelectedEngine' | 'getDefaultSteps' | 'getEngineProvisioning' | 'getVideoPipelineSteps' | 'setVideoPipelineSteps' | 'clearDeviceOverrides' | 'getInferenceDeviceHealth' | 'rearmInferenceDevice' | 'getSchema' | 'getGlobalSteps' | 'getGlobalPipelineConfig' | 'getOrchestratorConfigSchema' | 'validatePipeline' | 'listTemplates' | 'saveTemplate' | 'updateTemplate' | 'deleteTemplate' | 'getCapabilities' | 'getAddonModels' | 'downloadModel' | 'deleteModel' | 'cacheFrameInPool' | 'inferCached' | 'uncacheFrame' | 'getEffectiveTuning' | 'listLoadedEngines' | 'spinEngine' | 'killEngine' | 'listReferenceImages' | 'getReferenceImage' | 'getReferenceAudioFiles' | 'getReferenceAudio' | 'getAudioCapabilities' | 'runAudioTest' | 'getDetectionConfigSchema'>;
|
|
87
|
-
readonly pipelineOrchestrator: Pick<InferProvider<typeof pipelineOrchestratorCapability>, 'pauseForStorageMigration' | 'resumeForStorageMigration' | 'rebalance' | 'getPipelineAssignments' | 'getAgentLoad' | 'getGlobalMetrics' | 'getCapabilityBindings' | 'setCapabilityBinding' | 'getIngestOwner' | 'getAudioNodeLoad' | 'getAgentSettings' | 'listAgentSettings' | 'removeAgentSettings' | 'setAgentMaxCameras' | 'setAgentDetectWeight' | 'setAgentCapabilities' | 'setAgentDecodeLimits' | 'setAgentReachableHost' | 'setAgentInferenceDevices' | 'getNodeInferenceDevices' | 'resetNodePipelineDefaults' | 'getCameraStatuses' | 'reconcileFromDisk' | 'getReconcileFromDiskStatus' | 'listTemplates' | 'saveTemplate' | 'updateTemplate' | 'deleteTemplate'>;
|
|
89
|
+
readonly pipelineOrchestrator: Pick<InferProvider<typeof pipelineOrchestratorCapability>, 'pauseForStorageMigration' | 'resumeForStorageMigration' | 'rebalance' | 'getPipelineAssignments' | 'getAgentLoad' | 'getClusterModelChoice' | 'getGlobalMetrics' | 'getCapabilityBindings' | 'setCapabilityBinding' | 'getIngestOwner' | 'getAudioNodeLoad' | 'getAudioAssignments' | 'getAgentSettings' | 'listAgentSettings' | 'removeAgentSettings' | 'setAgentMaxCameras' | 'setAgentDetectWeight' | 'setAgentCapabilities' | 'setAgentDecodeLimits' | 'setAgentReachableHost' | 'setAgentInferenceDevices' | 'getNodeInferenceDevices' | 'resetNodePipelineDefaults' | 'getCameraStatuses' | 'reconcileFromDisk' | 'getReconcileFromDiskStatus' | 'listTemplates' | 'saveTemplate' | 'updateTemplate' | 'deleteTemplate'>;
|
|
88
90
|
readonly pipelineRunner: Pick<InferProvider<typeof pipelineRunnerCapability>, 'attachCamera' | 'reportMotion' | 'getLocalLoad' | 'getLocalMetrics' | 'getAllCameraMetrics' | 'getLocalCameras' | 'getNativeCrop' | 'runStatelessStep'>;
|
|
89
91
|
readonly plateGallery: Pick<InferProvider<typeof plateGalleryCapability>, 'getPlateMedia' | 'searchPlates' | 'suggestPlateClusters' | 'correctPlateText' | 'deletePlate' | 'listVehicles' | 'createVehicle' | 'renameVehicle' | 'deleteVehicle' | 'listVehicleSamples' | 'removeVehicleSample' | 'assignPlate' | 'unassignPlate' | 'assignPlates' | 'unassignPlates'>;
|
|
90
92
|
readonly recordingArchive: Pick<InferProvider<typeof recordingArchiveCapability>, 'getAvailabilityBatch' | 'getDaysWithRecordingsBatch' | 'getStorageUsage' | 'listOpsLog' | 'pauseForStorageMigration' | 'resumeForStorageMigration' | 'refreshStorageLocationsForMigration' | 'startStorageMigrationMove' | 'getStorageMigrationMoveStatus' | 'cancelStorageMigrationMove' | 'relocateFootage' | 'listRelocateJobs' | 'getRelocateResidue' | 'reconcileLedgerAgainstDisk' | 'cancelRelocateJob' | 'planStorageRebalance' | 'startStorageRebalance' | 'getPlacement' | 'setDevicePlacement'>;
|
package/dist/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ export type { EventOwnerType, MediaOwnerKey, MediaOwnerKeyInput, MediaOwnerType,
|
|
|
3
3
|
export { EVENT_OWNER_TYPES, EventOwnerTypeSchema, MEDIA_OWNER_TYPES, MEDIA_PRESENCE_OWNER_KINDS, MediaPresenceOwnerKindSchema, formatMediaOwnerKey, isEventOwnerType, isMediaOwnerType, parseMediaOwnerKey, } from './media/media-owner-key.js';
|
|
4
4
|
export type { CapabilitiesAccess } from './addon/base-addon.js';
|
|
5
5
|
export { BaseAddon, normalizeAddonInitResult } from './addon/base-addon.js';
|
|
6
|
+
export { normalizeNodeId } from './addon/per-node-store.js';
|
|
6
7
|
export type { AddonRouteInvokeRequest, AddonRouteReplyEnvelope, } from './addon/build-addon-route-provider.js';
|
|
7
8
|
export { buildAddonRouteProvider } from './addon/build-addon-route-provider.js';
|
|
8
9
|
export type { DurableState, DurableStateDeps } from './addon/durable-state.js';
|
|
@@ -131,6 +132,7 @@ export * from './types/labels.js';
|
|
|
131
132
|
export * from './types/live-state.js';
|
|
132
133
|
export * from './types/model-variant-groups.js';
|
|
133
134
|
export * from './types/models.js';
|
|
135
|
+
export * from './types/clip-model.js';
|
|
134
136
|
export * from './types/pipeline.js';
|
|
135
137
|
export type { AvailableEngine, PipelineAddonSchema, PipelineDefaultStep, PipelineModelOption, PipelineSchema, PipelineSlotSchema, PipelineTemplate, PipelineTemplateStep, TemplateValidationResult, } from './types/pipeline-schema.js';
|
|
136
138
|
export * from './types/pipeline-step.js';
|
|
@@ -140,6 +142,7 @@ export type { AutomationAction, AutomationCondition, AutomationConditionAll, Aut
|
|
|
140
142
|
export { AutomationActionSchema, AutomationConditionOperatorSchema, AutomationConditionSchema, AutomationRecipeSchema, AutomationTriggerSchema, conditionDepth, countConditionLeaves, generateAutomationBlock, MAX_CONDITION_DEPTH, MAX_CONDITION_LEAVES, validateRecipeBounds, } from './automation/index.js';
|
|
141
143
|
export * from './cap-call-context.js';
|
|
142
144
|
export * from './capabilities/index.js';
|
|
145
|
+
export * from './device-extension/index.js';
|
|
143
146
|
export { APPLE_SA_TO_MACRO, AUDIO_MACRO_LABELS, getAudioMacroClassIds, mapAudioLabelToMacro, YAMNET_TO_MACRO, } from './catalogs/audio-classmap.js';
|
|
144
147
|
export { COCO_80_LABELS, COCO_TO_MACRO, DETECTION_MACRO_CLASSES, isDetectionMacroClass, MACRO_LABELS, } from './catalogs/coco-classmap.js';
|
|
145
148
|
export { DEVICE_STATE_READERS, readDeviceStateFrom, stateVocabularyFor, } from './catalogs/device-state-vocabulary.js';
|
|
@@ -237,7 +240,8 @@ export { describeSystemEventDeliveryProblem, isSystemEventSummaryRule, NC_SYSTEM
|
|
|
237
240
|
export { NC_SERVER_PACKAGE_NAME, NC_UPDATE_EVENT_PACKAGE_NAMES, type NcInstalledPackageLike, type NcScopePickerItem, nodePickerItems, packagePickerItems, } from './notification/scope-picker-items.js';
|
|
238
241
|
export type { TimelapseCadencePair, TimelapsePreviewMode, TimelapseRule, TimelapseRuleInput, TimelapseRulePatch, TimelapseTemplate, } from './notification/timelapse-rule.js';
|
|
239
242
|
export { assertTimelapseCadences, DEFAULT_TIMELAPSE_PREVIEW_TEXT, readTimelapseGeneratedAt, TIMELAPSE_DENSE_FLOOR_SEC, TimelapseRuleInputSchema, TimelapseRulePatchSchema, TimelapseRuleSchema, TimelapseTemplateSchema, } from './notification/timelapse-rule.js';
|
|
240
|
-
export { CLUSTER_MODEL_SCOPED_STEPS, CLUSTER_MODEL_SECTION_ID, CLUSTER_STEP_SETTING_FIELDS, type ClusterModelScopedStep, type ClusterStepModels, type ClusterStepSettingField, type ClusterStepSettings, clusterModelSettingKey, clusterStepSettingFieldsFor, clusterStepSettingKey, DEFAULT_CLUSTER_STEP_MODELS, DEFAULT_CLUSTER_STEP_SETTINGS, DEFAULT_MIN_LANDMARK_FACE_SIZE_PX, type HydratedClusterSection, type HydratedClusterView, isClusterScopedStep, overlayClusterStepSettings, pickClusterStepModels, pickClusterStepSettings, readClusterStepModels, readClusterStepSettings, resolveClusterStepModelId, type StepModelScope, } from './pipeline/cluster-model-scope.js';
|
|
243
|
+
export { CLUSTER_MODEL_SCOPED_STEPS, CLUSTER_MODEL_SECTION_ID, CLUSTER_STEP_SETTING_FIELDS, type ClusterModelScopedStep, type ClusterStepModels, type ClusterStepSettingField, type ClusterStepSettings, clusterModelSettingKey, clusterStepSettingFieldsFor, clusterStepSettingKey, DEFAULT_CLUSTER_STEP_MODELS, DEFAULT_CLUSTER_STEP_SETTINGS, DEFAULT_MIN_LANDMARK_FACE_SIZE_PX, type HydratedClusterSection, type HydratedClusterView, interpretStoredClusterModel, type InvalidClusterStepModelEntry, invalidClusterStepModelEntries, isClusterScopedStep, overlayClusterStepSettings, pickClusterStepModels, pickClusterStepSettings, pickInvalidClusterStepModels, readClusterStepModels, readClusterStepSettings, resolveClusterStepModelId, type StepModelScope, type StoredClusterModelInterpretation, } from './pipeline/cluster-model-scope.js';
|
|
244
|
+
export { type FormatRunnableModel, stepModelRunsOnFormat, } from './pipeline/step-format-runnable.js';
|
|
241
245
|
export { DEFAULT_DETAIL_CROP_CONVENTION, DETAIL_CROP_PADDING_FIELD, DETAIL_CROP_PADDING_KEY, DETAIL_CROP_SECTION_ID, DETAIL_CROP_SQUARE_KEY, type DetailCropConvention, DetailCropConventionSchema, type DetailCropRect, deriveDetailCropRect, FULL_IMAGE_BBOX, type HydratedSettingsSection, type HydratedSettingsView, pickDetailCropConvention, readDetailCropConvention, } from './pipeline/detail-crop.js';
|
|
242
246
|
export { DEFAULT_NATIVE_LEASE_SETTINGS, NATIVE_LEASE_ACTIVITY_FIELD, NATIVE_LEASE_ACTIVITY_KEY, NATIVE_LEASE_ADMISSION_FIELD, NATIVE_LEASE_ADMISSION_KEY, NATIVE_LEASE_BUDGET_FIELD, NATIVE_LEASE_BUDGET_KEY, NATIVE_LEASE_HOLD_FIELD, NATIVE_LEASE_HOLD_KEY, NATIVE_LEASE_SCENE_BUDGET_FIELD, NATIVE_LEASE_SCENE_BUDGET_KEY, NATIVE_LEASE_SECTION_ID, NATIVE_LEASE_TILE_BUDGET_FIELD, NATIVE_LEASE_TILE_BUDGET_KEY, type NativeLeaseAdmission, NativeLeaseAdmissionSchema, type NativeLeaseKnob, type NativeLeaseNumberKnob, type NativeLeaseSettings, type NativeLeaseSettingsOverride, NativeLeaseSettingsSchema, pickNativeLeaseOverride, readNativeLeaseOverride, } from './pipeline/native-lease.js';
|
|
243
247
|
export { ACCESS_ROLES, type AccessRoleAssignment, type AccessRoleId, type AccessRoleSpec, buildRoleScopes, detectAccessRole, roleSpec, } from './schemas/access-roles.js';
|