@camstack/addon-auth 1.1.8 → 1.1.9
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/{dist-BmBZpi5F.js → dist-BW9lD5lw.js} +942 -38
- package/dist/{dist-By_wIEBw.mjs → dist-BnW6cspM.mjs} +942 -38
- package/dist/magic-link/auth-magic-link.addon.js +1 -1
- package/dist/magic-link/auth-magic-link.addon.mjs +1 -1
- package/dist/oidc/auth-oidc.addon.js +1 -1
- package/dist/oidc/auth-oidc.addon.mjs +1 -1
- package/dist/webauthn/_stub.js +1 -1
- package/dist/webauthn/{_virtual_mf-localSharedImportMap___mfe_internal__addon_auth_webauthn_widgets-BluKoTcU.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_auth_webauthn_widgets-CxRwJuPN.mjs} +2 -2
- package/dist/webauthn/{_virtual_mf___mfe_internal__addon_auth_webauthn_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-CQL0LLWT.mjs → _virtual_mf___mfe_internal__addon_auth_webauthn_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-Bq3gIXH1.mjs} +1 -1
- package/dist/webauthn/auth-webauthn.addon.js +36 -27
- package/dist/webauthn/auth-webauthn.addon.mjs +36 -27
- package/dist/webauthn/{hostInit-sCTQKnLH.mjs → hostInit-DzkeVZUs.mjs} +2 -2
- package/dist/webauthn/remoteEntry.js +1 -1
- package/package.json +1 -1
|
@@ -4286,6 +4286,14 @@ function object(shape, params) {
|
|
|
4286
4286
|
...normalizeParams(params)
|
|
4287
4287
|
});
|
|
4288
4288
|
}
|
|
4289
|
+
function looseObject(shape, params) {
|
|
4290
|
+
return new ZodObject({
|
|
4291
|
+
type: "object",
|
|
4292
|
+
shape,
|
|
4293
|
+
catchall: unknown(),
|
|
4294
|
+
...normalizeParams(params)
|
|
4295
|
+
});
|
|
4296
|
+
}
|
|
4289
4297
|
var ZodUnion = /*@__PURE__*/ $constructor("ZodUnion", (inst, def) => {
|
|
4290
4298
|
$ZodUnion.init(inst, def);
|
|
4291
4299
|
ZodType.init(inst, def);
|
|
@@ -4627,7 +4635,7 @@ function _instanceof(cls, params = {}) {
|
|
|
4627
4635
|
return inst;
|
|
4628
4636
|
}
|
|
4629
4637
|
//#endregion
|
|
4630
|
-
//#region ../types/dist/sleep-
|
|
4638
|
+
//#region ../types/dist/sleep-DkhOVOjW.mjs
|
|
4631
4639
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
4632
4640
|
EventCategory["SystemBoot"] = "system.boot";
|
|
4633
4641
|
EventCategory["SystemAddonsReady"] = "system.addons-ready";
|
|
@@ -5037,10 +5045,43 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
|
5037
5045
|
EventCategory["EnrichmentEmbeddingStored"] = "enrichment.embedding.stored";
|
|
5038
5046
|
EventCategory["EnrichmentSceneStateChanged"] = "enrichment.scene.state-changed";
|
|
5039
5047
|
EventCategory["EnrichmentActivitySummary"] = "enrichment.activity.summary";
|
|
5048
|
+
/**
|
|
5049
|
+
* Unified track-lifecycle event: ONE category carrying `phase:
|
|
5050
|
+
* 'start' | 'update' | 'end'` with a rich, typed
|
|
5051
|
+
* `PipelineAnalyticsTrackLifecyclePayload`. Supersedes the thin
|
|
5052
|
+
* `PipelineAnalyticsTrackStarted` / `PipelineAnalyticsTrackEnded`
|
|
5053
|
+
* pair — a consumer subscribes once and branches on `phase`.
|
|
5054
|
+
*/
|
|
5055
|
+
EventCategory["PipelineAnalyticsTrackLifecycle"] = "pipeline-analytics.track-lifecycle";
|
|
5056
|
+
/**
|
|
5057
|
+
* @deprecated Superseded by {@link PipelineAnalyticsTrackLifecycle}
|
|
5058
|
+
* (`phase:'start'`). Kept as a soft alias — no known subscribers.
|
|
5059
|
+
*/
|
|
5040
5060
|
EventCategory["PipelineAnalyticsTrackStarted"] = "pipeline-analytics.track-started";
|
|
5061
|
+
/**
|
|
5062
|
+
* @deprecated Superseded by {@link PipelineAnalyticsTrackLifecycle}
|
|
5063
|
+
* (`phase:'end'`). Kept as a soft alias — no known subscribers.
|
|
5064
|
+
*/
|
|
5041
5065
|
EventCategory["PipelineAnalyticsTrackEnded"] = "pipeline-analytics.track-ended";
|
|
5042
5066
|
EventCategory["PipelineAnalyticsDetectionEvent"] = "pipeline-analytics.detection-event";
|
|
5043
5067
|
EventCategory["PipelineAnalyticsFrameTracked"] = "pipeline-analytics.frame-tracked";
|
|
5068
|
+
/**
|
|
5069
|
+
* Fired by `addon-post-analysis` whenever a gallery face row changes:
|
|
5070
|
+
* `kind:'buffered'` a new detected face was persisted, `'assigned'` /
|
|
5071
|
+
* `'unassigned'` its identity link changed, `'deleted'` the row was
|
|
5072
|
+
* removed. Telemetry semantics (D8): a lost event only delays a refresh,
|
|
5073
|
+
* never a correctness issue. Payload `PipelineAnalyticsFaceGalleryChangedPayload`.
|
|
5074
|
+
*/
|
|
5075
|
+
EventCategory["PipelineAnalyticsFaceGalleryChanged"] = "pipeline-analytics.face-gallery-changed";
|
|
5076
|
+
/**
|
|
5077
|
+
* Fired by `addon-post-analysis` whenever a gallery plate row changes:
|
|
5078
|
+
* `kind:'buffered'` a new read was persisted (`PlateRecognizer.onTrackEnd`),
|
|
5079
|
+
* `'assigned'` / `'unassigned'` its vehicle link changed
|
|
5080
|
+
* (`PlateGalleryProvider`), `'deleted'` the row was removed. Telemetry
|
|
5081
|
+
* semantics (D8): a lost event only delays a refresh, never a correctness
|
|
5082
|
+
* issue. Payload `PipelineAnalyticsPlateGalleryChangedPayload`.
|
|
5083
|
+
*/
|
|
5084
|
+
EventCategory["PipelineAnalyticsPlateGalleryChanged"] = "pipeline-analytics.plate-gallery-changed";
|
|
5044
5085
|
EventCategory["FrigateLiveEvent"] = "frigate.live-event";
|
|
5045
5086
|
EventCategory["CameraStreamsProfileSlotsChanged"] = "camera-streams.onProfileSlotsChanged";
|
|
5046
5087
|
/**
|
|
@@ -6881,7 +6922,8 @@ var MODEL_FORMATS = [
|
|
|
6881
6922
|
"coreml",
|
|
6882
6923
|
"openvino",
|
|
6883
6924
|
"tflite",
|
|
6884
|
-
"pt"
|
|
6925
|
+
"pt",
|
|
6926
|
+
"gguf"
|
|
6885
6927
|
];
|
|
6886
6928
|
/**
|
|
6887
6929
|
* Multi-file format payload.
|
|
@@ -6925,7 +6967,8 @@ var ModelFormatsSchema = object({
|
|
|
6925
6967
|
coreml: ModelFormatEntrySchema.optional(),
|
|
6926
6968
|
openvino: ModelFormatEntrySchema.optional(),
|
|
6927
6969
|
tflite: ModelFormatEntrySchema.optional(),
|
|
6928
|
-
pt: ModelFormatEntrySchema.optional()
|
|
6970
|
+
pt: ModelFormatEntrySchema.optional(),
|
|
6971
|
+
gguf: ModelFormatEntrySchema.optional()
|
|
6929
6972
|
});
|
|
6930
6973
|
/**
|
|
6931
6974
|
* Variant-selector grouping axes. Shared by the full `ModelCatalogEntry` and by
|
|
@@ -10537,7 +10580,8 @@ var ModelFormatSchema$1 = _enum([
|
|
|
10537
10580
|
"coreml",
|
|
10538
10581
|
"openvino",
|
|
10539
10582
|
"tflite",
|
|
10540
|
-
"pt"
|
|
10583
|
+
"pt",
|
|
10584
|
+
"gguf"
|
|
10541
10585
|
]);
|
|
10542
10586
|
var PipelineSlotSchema = _enum([
|
|
10543
10587
|
"detector",
|
|
@@ -11843,6 +11887,140 @@ DeviceType.Camera, method(object({ deviceId: number() }), PtzAutotrackStatusSche
|
|
|
11843
11887
|
deviceId: number(),
|
|
11844
11888
|
status: PtzAutotrackStatusSchema
|
|
11845
11889
|
});
|
|
11890
|
+
/**
|
|
11891
|
+
* scene-monitor — device-scoped reference-region state cap. An operator marks
|
|
11892
|
+
* a rect ROI on a camera frame and names one or more states; the engine
|
|
11893
|
+
* (pipeline-analytics, designated post-processing node) reports which state is
|
|
11894
|
+
* active on an ongoing basis. Two operator-selectable check modes share every-
|
|
11895
|
+
* thing except the comparator: `similarity` (CLIP cosine at the same ROI coords
|
|
11896
|
+
* vs condition-tagged references) and `llm` (vision-LLM judgment over the crop).
|
|
11897
|
+
*
|
|
11898
|
+
* D14 device-config archetype (`deviceConfig.ui.kind:'widget'`) — the framework
|
|
11899
|
+
* derives the device-detail contribution; the provider carries NO hand-written
|
|
11900
|
+
* settings-contribution methods. `status.kind:'push'` — the engine pushes on
|
|
11901
|
+
* every hysteresis flip / availability change; consumers never poll.
|
|
11902
|
+
*/
|
|
11903
|
+
/** Extensible condition tag. Seeded 'day' | 'night'; open by design so more can
|
|
11904
|
+
* be added without a wire break (matching falls back to any-condition refs). */
|
|
11905
|
+
var SceneConditionSchema = string();
|
|
11906
|
+
/** One captured reference — condition-tagged, model-version-gated. `embedding`
|
|
11907
|
+
* is `number[]` (Float32Array does NOT survive MsgPack/UDS). */
|
|
11908
|
+
var SceneReferenceSchema = object({
|
|
11909
|
+
embedding: array(number()),
|
|
11910
|
+
modelId: string(),
|
|
11911
|
+
condition: SceneConditionSchema,
|
|
11912
|
+
capturedAt: number(),
|
|
11913
|
+
thumbnailMediaId: string().optional()
|
|
11914
|
+
});
|
|
11915
|
+
var SceneMonitorStateSchema = object({
|
|
11916
|
+
id: string(),
|
|
11917
|
+
label: string(),
|
|
11918
|
+
references: array(SceneReferenceSchema),
|
|
11919
|
+
textPrompts: array(string()).optional(),
|
|
11920
|
+
referenceCount: number(),
|
|
11921
|
+
currentlyMatched: boolean()
|
|
11922
|
+
});
|
|
11923
|
+
/** Per-mode comparator params in a discriminated union so an `llm` scene never
|
|
11924
|
+
* carries similarity knobs and vice-versa. */
|
|
11925
|
+
var SceneCheckSchema = discriminatedUnion("mode", [object({
|
|
11926
|
+
mode: literal("similarity"),
|
|
11927
|
+
threshold: number().min(0).max(1),
|
|
11928
|
+
hysteresisCount: number().int().positive()
|
|
11929
|
+
}), object({
|
|
11930
|
+
mode: literal("llm"),
|
|
11931
|
+
prompt: string(),
|
|
11932
|
+
profileId: string().optional(),
|
|
11933
|
+
hysteresisCount: number().int().positive()
|
|
11934
|
+
})]);
|
|
11935
|
+
var SceneMonitorSchema = object({
|
|
11936
|
+
id: string(),
|
|
11937
|
+
label: string(),
|
|
11938
|
+
roi: MaskRectShapeSchema,
|
|
11939
|
+
enabled: boolean(),
|
|
11940
|
+
triggerMode: _enum([
|
|
11941
|
+
"periodic",
|
|
11942
|
+
"on-motion",
|
|
11943
|
+
"both"
|
|
11944
|
+
]),
|
|
11945
|
+
checkIntervalSec: number().optional(),
|
|
11946
|
+
check: SceneCheckSchema,
|
|
11947
|
+
states: array(SceneMonitorStateSchema),
|
|
11948
|
+
currentStateId: string().nullable(),
|
|
11949
|
+
lastCheckedAt: number().nullable(),
|
|
11950
|
+
lastConfidence: number().nullable(),
|
|
11951
|
+
currentCondition: SceneConditionSchema.nullable(),
|
|
11952
|
+
availability: _enum(["ok", "unavailable"]),
|
|
11953
|
+
unavailableReason: string().nullable()
|
|
11954
|
+
});
|
|
11955
|
+
var SceneMonitorStatusSchema = object({
|
|
11956
|
+
monitors: array(SceneMonitorSchema),
|
|
11957
|
+
lastFetchedAt: number()
|
|
11958
|
+
});
|
|
11959
|
+
DeviceType.Camera, method(object({ deviceId: number() }), SceneMonitorStatusSchema), method(object({
|
|
11960
|
+
deviceId: number(),
|
|
11961
|
+
label: string(),
|
|
11962
|
+
roi: MaskRectShapeSchema,
|
|
11963
|
+
check: SceneCheckSchema,
|
|
11964
|
+
triggerMode: _enum([
|
|
11965
|
+
"periodic",
|
|
11966
|
+
"on-motion",
|
|
11967
|
+
"both"
|
|
11968
|
+
]).optional(),
|
|
11969
|
+
checkIntervalSec: number().optional()
|
|
11970
|
+
}), SceneMonitorSchema, {
|
|
11971
|
+
kind: "mutation",
|
|
11972
|
+
auth: "admin"
|
|
11973
|
+
}), method(object({
|
|
11974
|
+
deviceId: number(),
|
|
11975
|
+
monitorId: string(),
|
|
11976
|
+
patch: object({
|
|
11977
|
+
label: string().optional(),
|
|
11978
|
+
roi: MaskRectShapeSchema.optional(),
|
|
11979
|
+
enabled: boolean().optional(),
|
|
11980
|
+
triggerMode: _enum([
|
|
11981
|
+
"periodic",
|
|
11982
|
+
"on-motion",
|
|
11983
|
+
"both"
|
|
11984
|
+
]).optional(),
|
|
11985
|
+
checkIntervalSec: number().optional(),
|
|
11986
|
+
check: SceneCheckSchema.optional()
|
|
11987
|
+
})
|
|
11988
|
+
}), _void(), {
|
|
11989
|
+
kind: "mutation",
|
|
11990
|
+
auth: "admin"
|
|
11991
|
+
}), method(object({
|
|
11992
|
+
deviceId: number(),
|
|
11993
|
+
monitorId: string()
|
|
11994
|
+
}), _void(), {
|
|
11995
|
+
kind: "mutation",
|
|
11996
|
+
auth: "admin"
|
|
11997
|
+
}), method(object({
|
|
11998
|
+
deviceId: number(),
|
|
11999
|
+
monitorId: string(),
|
|
12000
|
+
stateId: string().optional(),
|
|
12001
|
+
label: string().optional(),
|
|
12002
|
+
condition: SceneConditionSchema.optional()
|
|
12003
|
+
}), object({
|
|
12004
|
+
stateId: string(),
|
|
12005
|
+
referenceCount: number()
|
|
12006
|
+
}), {
|
|
12007
|
+
kind: "mutation",
|
|
12008
|
+
auth: "admin"
|
|
12009
|
+
}), method(object({
|
|
12010
|
+
deviceId: number(),
|
|
12011
|
+
monitorId: string(),
|
|
12012
|
+
stateId: string(),
|
|
12013
|
+
index: number()
|
|
12014
|
+
}), _void(), {
|
|
12015
|
+
kind: "mutation",
|
|
12016
|
+
auth: "admin"
|
|
12017
|
+
}), method(object({
|
|
12018
|
+
deviceId: number(),
|
|
12019
|
+
monitorId: string()
|
|
12020
|
+
}), _void(), {
|
|
12021
|
+
kind: "mutation",
|
|
12022
|
+
auth: "admin"
|
|
12023
|
+
});
|
|
11846
12024
|
object({
|
|
11847
12025
|
/** Whether the script is currently executing. */
|
|
11848
12026
|
isRunning: boolean(),
|
|
@@ -12889,7 +13067,12 @@ var NotificationRuleConditionsSchema = object({
|
|
|
12889
13067
|
clipDescription: object({
|
|
12890
13068
|
text: string().min(1),
|
|
12891
13069
|
minSimilarity: number().min(0).max(1)
|
|
12892
|
-
}).optional()
|
|
13070
|
+
}).optional(),
|
|
13071
|
+
/** Match events whose recognized-entity label (face identity name or plate
|
|
13072
|
+
* vehicle name, propagated onto `event.data.label`) is one of these values.
|
|
13073
|
+
* Empty/absent → unaffected (back-compat). Enables "notify me when <named
|
|
13074
|
+
* vehicle/person> is seen". */
|
|
13075
|
+
labels: array(string()).readonly().optional()
|
|
12893
13076
|
});
|
|
12894
13077
|
var NotificationRuleTemplateSchema = object({
|
|
12895
13078
|
title: string(),
|
|
@@ -13160,11 +13343,19 @@ var authProviderCapability = {
|
|
|
13160
13343
|
* login page needs NO change.
|
|
13161
13344
|
*
|
|
13162
13345
|
* - `widget` — a Module-Federation widget the login page mounts (via
|
|
13163
|
-
* `loadRemoteBundle`) for an in-page ceremony.
|
|
13164
|
-
*
|
|
13165
|
-
*
|
|
13166
|
-
*
|
|
13167
|
-
*
|
|
13346
|
+
* `loadRemoteBundle`) for an in-page ceremony. `auth.listLoginMethods`
|
|
13347
|
+
* stamps a public `bundleUrl` from `addonId` + `bundle`. Generic
|
|
13348
|
+
* mechanism kept for future use; no shipped addon uses it on the login
|
|
13349
|
+
* page (the passkey ceremony below runs natively in the shell instead).
|
|
13350
|
+
*
|
|
13351
|
+
* - `passkey` — a declarative WebAuthn ceremony the shell renders
|
|
13352
|
+
* natively (`@simplewebauthn/browser` lives in `addon-admin-ui`, not in
|
|
13353
|
+
* a remotely-loaded bundle). Carries the addon's effective `rpId` /
|
|
13354
|
+
* `origin` (from its `resolveRpID()` / `resolveOrigin()`) so the shell
|
|
13355
|
+
* can gate visibility (IP-literal origin, hostname/rpId mismatch) WITHOUT
|
|
13356
|
+
* fetching any remote code pre-auth. Contribution stays unconditional —
|
|
13357
|
+
* enrollment state is never leaked pre-auth; visibility is a shell
|
|
13358
|
+
* decision.
|
|
13168
13359
|
*
|
|
13169
13360
|
* Every contribution carries a `stage`:
|
|
13170
13361
|
* - `primary` — shown on the first credentials screen (OIDC /
|
|
@@ -13178,30 +13369,45 @@ var authProviderCapability = {
|
|
|
13178
13369
|
*/
|
|
13179
13370
|
/** When a login method renders in the two-phase login flow. */
|
|
13180
13371
|
var LoginStageEnum = _enum(["primary", "second-factor"]);
|
|
13181
|
-
/** One login-method contribution — redirect button
|
|
13182
|
-
var LoginMethodContributionSchema = discriminatedUnion("kind", [
|
|
13183
|
-
|
|
13184
|
-
|
|
13185
|
-
|
|
13186
|
-
|
|
13187
|
-
|
|
13188
|
-
|
|
13189
|
-
|
|
13190
|
-
|
|
13191
|
-
|
|
13192
|
-
|
|
13193
|
-
|
|
13194
|
-
|
|
13195
|
-
|
|
13196
|
-
|
|
13197
|
-
|
|
13198
|
-
|
|
13199
|
-
|
|
13200
|
-
|
|
13201
|
-
|
|
13202
|
-
|
|
13203
|
-
|
|
13204
|
-
|
|
13372
|
+
/** One login-method contribution — redirect button, pre-auth widget, or native passkey ceremony. */
|
|
13373
|
+
var LoginMethodContributionSchema = discriminatedUnion("kind", [
|
|
13374
|
+
object({
|
|
13375
|
+
kind: literal("redirect"),
|
|
13376
|
+
/** Stable id within the login-method set (e.g. `auth-oidc/google`). */
|
|
13377
|
+
id: string(),
|
|
13378
|
+
/** Operator-facing button label. */
|
|
13379
|
+
label: string(),
|
|
13380
|
+
/** lucide-react icon name. */
|
|
13381
|
+
icon: string().optional(),
|
|
13382
|
+
/** Addon-owned HTTP route the button navigates to (GET). */
|
|
13383
|
+
startUrl: string(),
|
|
13384
|
+
stage: LoginStageEnum
|
|
13385
|
+
}),
|
|
13386
|
+
object({
|
|
13387
|
+
kind: literal("widget"),
|
|
13388
|
+
/** Stable id within the login-method set (e.g. `auth-webauthn/passkey-login`). */
|
|
13389
|
+
id: string(),
|
|
13390
|
+
/** Owning addon id — drives the public bundle URL + the MF namespace. */
|
|
13391
|
+
addonId: string(),
|
|
13392
|
+
/** Bundle filename inside the addon's dist dir (`remoteEntry.js`). */
|
|
13393
|
+
bundle: string(),
|
|
13394
|
+
/** MF remote descriptor — `{ remoteName, exposedModule, componentKey }`. */
|
|
13395
|
+
remote: WidgetRemoteSchema,
|
|
13396
|
+
stage: LoginStageEnum
|
|
13397
|
+
}),
|
|
13398
|
+
object({
|
|
13399
|
+
kind: literal("passkey"),
|
|
13400
|
+
/** Stable id within the login-method set (e.g. `auth-webauthn/passkey-direct-login`). */
|
|
13401
|
+
id: string(),
|
|
13402
|
+
/** Operator-facing button label. */
|
|
13403
|
+
label: string(),
|
|
13404
|
+
stage: LoginStageEnum,
|
|
13405
|
+
/** Effective WebAuthn RP ID (`resolveRpID()`) — the shell gates visibility on it. */
|
|
13406
|
+
rpId: string(),
|
|
13407
|
+
/** Effective expected origin (`resolveOrigin()`), null when unconfigured. */
|
|
13408
|
+
origin: string().nullable()
|
|
13409
|
+
})
|
|
13410
|
+
]);
|
|
13205
13411
|
var loginMethodCapability = {
|
|
13206
13412
|
name: "login-method",
|
|
13207
13413
|
scope: "system",
|
|
@@ -15037,14 +15243,14 @@ var TargetKindCapsSchema = object({
|
|
|
15037
15243
|
* the union is large and not meant for runtime validation here; the exported
|
|
15038
15244
|
* `TargetKind` type re-tightens `configSchema` to `ConfigUISchema`.
|
|
15039
15245
|
*/
|
|
15040
|
-
var ConfigSchemaPassthrough = unknown();
|
|
15246
|
+
var ConfigSchemaPassthrough$1 = unknown();
|
|
15041
15247
|
var TargetKindSchema = object({
|
|
15042
15248
|
kind: string(),
|
|
15043
15249
|
label: string(),
|
|
15044
15250
|
icon: string(),
|
|
15045
15251
|
/** Stamped by each provider so the concat-fanned catalog stays routable. */
|
|
15046
15252
|
addonId: string(),
|
|
15047
|
-
configSchema: ConfigSchemaPassthrough,
|
|
15253
|
+
configSchema: ConfigSchemaPassthrough$1,
|
|
15048
15254
|
supportsDiscovery: boolean(),
|
|
15049
15255
|
caps: TargetKindCapsSchema
|
|
15050
15256
|
});
|
|
@@ -15097,6 +15303,298 @@ method(object({}), array(TargetKindSchema)), method(object({}), array(TargetSche
|
|
|
15097
15303
|
enabled: boolean()
|
|
15098
15304
|
}), _void(), { kind: "mutation" });
|
|
15099
15305
|
/**
|
|
15306
|
+
* Shared LLM generate contracts — imported by BOTH `llm.cap.ts` (consumer
|
|
15307
|
+
* surface) and `llm-runtime.cap.ts` (node-side managed executor) so the two
|
|
15308
|
+
* caps stay wire-compatible without a circular cap→cap import.
|
|
15309
|
+
*
|
|
15310
|
+
* Errors are a discriminated-union RESULT, never thrown: the shape survives
|
|
15311
|
+
* every transport tier structurally, and failed calls still write usage rows.
|
|
15312
|
+
* Token counts only in v1 — no costUsd (operator decision, 2026-07-15).
|
|
15313
|
+
*/
|
|
15314
|
+
var LlmUsageSchema = object({
|
|
15315
|
+
inputTokens: number(),
|
|
15316
|
+
outputTokens: number()
|
|
15317
|
+
});
|
|
15318
|
+
var LlmErrorCodeSchema = _enum([
|
|
15319
|
+
"timeout",
|
|
15320
|
+
"rate-limited",
|
|
15321
|
+
"auth",
|
|
15322
|
+
"refusal",
|
|
15323
|
+
"bad-request",
|
|
15324
|
+
"unavailable",
|
|
15325
|
+
"no-profile",
|
|
15326
|
+
"budget-exceeded",
|
|
15327
|
+
"adapter-error"
|
|
15328
|
+
]);
|
|
15329
|
+
var LlmGenerateResultSchema = discriminatedUnion("ok", [object({
|
|
15330
|
+
ok: literal(true),
|
|
15331
|
+
text: string(),
|
|
15332
|
+
model: string(),
|
|
15333
|
+
usage: LlmUsageSchema,
|
|
15334
|
+
truncated: boolean(),
|
|
15335
|
+
latencyMs: number()
|
|
15336
|
+
}), object({
|
|
15337
|
+
ok: literal(false),
|
|
15338
|
+
code: LlmErrorCodeSchema,
|
|
15339
|
+
message: string(),
|
|
15340
|
+
retryAfterMs: number().optional()
|
|
15341
|
+
})]);
|
|
15342
|
+
/**
|
|
15343
|
+
* `Uint8Array` is the sanctioned binary convention — superjson + the UDS
|
|
15344
|
+
* MsgPack channel round-trip typed arrays (embedding-encoder.cap.ts:29,
|
|
15345
|
+
* notification-output.cap.ts:27-31 precedents).
|
|
15346
|
+
*/
|
|
15347
|
+
var LlmImageSchema = object({
|
|
15348
|
+
bytes: _instanceof(Uint8Array),
|
|
15349
|
+
mimeType: string()
|
|
15350
|
+
});
|
|
15351
|
+
var LlmGenerateBaseInputSchema = object({
|
|
15352
|
+
/** Collection routing (the notification-output posture). */
|
|
15353
|
+
addonId: string().optional(),
|
|
15354
|
+
/** Explicit profile; else the resolution chain (spec §3). */
|
|
15355
|
+
profileId: string().optional(),
|
|
15356
|
+
/** MANDATORY usage tag: 'ai-summary', 'notifier-rules', 'adhoc-ui', … */
|
|
15357
|
+
consumer: string(),
|
|
15358
|
+
system: string().optional(),
|
|
15359
|
+
/** v1: single-turn. `messages[]` is a v2 additive field. */
|
|
15360
|
+
prompt: string(),
|
|
15361
|
+
/** Structured output — adapter-mapped (response_format / forced tool / responseSchema). */
|
|
15362
|
+
jsonSchema: record(string(), unknown()).optional(),
|
|
15363
|
+
/** Per-call override of the profile default. */
|
|
15364
|
+
maxTokens: number().int().positive().optional(),
|
|
15365
|
+
temperature: number().optional()
|
|
15366
|
+
});
|
|
15367
|
+
/**
|
|
15368
|
+
* `llm-runtime` — node-side managed llama.cpp executor (spec §4). Registered
|
|
15369
|
+
* on EVERY node where `addon-ai` is installed; the hub `llm` provider reaches
|
|
15370
|
+
* a specific node's runtime with `nodePin(profile.runtime.nodeId)` — normal
|
|
15371
|
+
* cap routing, zero bespoke plumbing. `internal: true`: the operator reaches
|
|
15372
|
+
* this only through the `llm` cap's methods.
|
|
15373
|
+
*
|
|
15374
|
+
* One running llama-server child per node in v1 (models are RAM-heavy).
|
|
15375
|
+
* Resource ceiling = llama-server flags + idleStopMinutes ONLY (no RSS
|
|
15376
|
+
* watchdog — operator decision #3).
|
|
15377
|
+
*/
|
|
15378
|
+
var ManagedModelRefSchema = discriminatedUnion("kind", [
|
|
15379
|
+
object({
|
|
15380
|
+
kind: literal("catalog"),
|
|
15381
|
+
catalogId: string()
|
|
15382
|
+
}),
|
|
15383
|
+
object({
|
|
15384
|
+
kind: literal("url"),
|
|
15385
|
+
url: string(),
|
|
15386
|
+
sha256: string().optional()
|
|
15387
|
+
}),
|
|
15388
|
+
object({
|
|
15389
|
+
kind: literal("path"),
|
|
15390
|
+
path: string()
|
|
15391
|
+
})
|
|
15392
|
+
]);
|
|
15393
|
+
var ManagedRuntimeConfigSchema = object({
|
|
15394
|
+
/** WHERE the runtime lives — hub or any agent. */
|
|
15395
|
+
nodeId: string(),
|
|
15396
|
+
/** Closed for v1; 'ollama' is a v2 candidate. */
|
|
15397
|
+
engine: _enum(["llama-cpp"]),
|
|
15398
|
+
model: ManagedModelRefSchema,
|
|
15399
|
+
contextSize: number().int().default(4096),
|
|
15400
|
+
/** 0 = CPU-only. */
|
|
15401
|
+
gpuLayers: number().int().default(0),
|
|
15402
|
+
/** Default: cpus-2, clamped ≥1 (resolved node-side). */
|
|
15403
|
+
threads: number().int().optional(),
|
|
15404
|
+
/** Concurrent slots. */
|
|
15405
|
+
parallel: number().int().default(1),
|
|
15406
|
+
/** Else lazy: first generate boots it. */
|
|
15407
|
+
autoStart: boolean().default(false),
|
|
15408
|
+
/** 0 = never; frees RAM after quiet periods. */
|
|
15409
|
+
idleStopMinutes: number().int().default(30)
|
|
15410
|
+
});
|
|
15411
|
+
var LlmRuntimeStatusSchema = object({
|
|
15412
|
+
/** Status is ALWAYS node-qualified. */
|
|
15413
|
+
nodeId: string(),
|
|
15414
|
+
state: _enum([
|
|
15415
|
+
"stopped",
|
|
15416
|
+
"downloading",
|
|
15417
|
+
"starting",
|
|
15418
|
+
"ready",
|
|
15419
|
+
"crashed",
|
|
15420
|
+
"failed"
|
|
15421
|
+
]),
|
|
15422
|
+
pid: number().optional(),
|
|
15423
|
+
port: number().optional(),
|
|
15424
|
+
modelPath: string().optional(),
|
|
15425
|
+
modelId: string().optional(),
|
|
15426
|
+
downloadProgress: number().min(0).max(1).optional(),
|
|
15427
|
+
lastError: string().optional(),
|
|
15428
|
+
crashesInWindow: number(),
|
|
15429
|
+
/** Child RSS (sampled best-effort). */
|
|
15430
|
+
memoryBytes: number().optional(),
|
|
15431
|
+
vramBytes: number().optional()
|
|
15432
|
+
});
|
|
15433
|
+
var LlmNodeModelSchema = object({
|
|
15434
|
+
file: string(),
|
|
15435
|
+
sizeBytes: number(),
|
|
15436
|
+
catalogId: string().optional(),
|
|
15437
|
+
installedAt: number().optional()
|
|
15438
|
+
});
|
|
15439
|
+
var LlmRuntimeDiskUsageSchema = object({
|
|
15440
|
+
nodeId: string(),
|
|
15441
|
+
modelsBytes: number(),
|
|
15442
|
+
freeBytes: number().optional()
|
|
15443
|
+
});
|
|
15444
|
+
method(LlmGenerateBaseInputSchema.extend({
|
|
15445
|
+
images: array(LlmImageSchema).optional(),
|
|
15446
|
+
runtime: ManagedRuntimeConfigSchema,
|
|
15447
|
+
/** The managed profile's timeout, threaded by the hub provider. */
|
|
15448
|
+
timeoutMs: number().int().positive().optional()
|
|
15449
|
+
}), LlmGenerateResultSchema, { kind: "mutation" }), method(object({ runtime: ManagedRuntimeConfigSchema }), LlmRuntimeStatusSchema, {
|
|
15450
|
+
kind: "mutation",
|
|
15451
|
+
auth: "admin"
|
|
15452
|
+
}), method(object({}), _void(), {
|
|
15453
|
+
kind: "mutation",
|
|
15454
|
+
auth: "admin"
|
|
15455
|
+
}), method(object({}), LlmRuntimeStatusSchema), method(object({ model: ManagedModelRefSchema }), _void(), {
|
|
15456
|
+
kind: "mutation",
|
|
15457
|
+
auth: "admin"
|
|
15458
|
+
}), method(object({ file: string() }), _void(), {
|
|
15459
|
+
kind: "mutation",
|
|
15460
|
+
auth: "admin"
|
|
15461
|
+
}), method(object({}), array(LlmNodeModelSchema)), method(object({}), LlmRuntimeDiskUsageSchema);
|
|
15462
|
+
/**
|
|
15463
|
+
* `llm` — consumer-facing LLM surface (spec §1-§3). Collection-mode: array
|
|
15464
|
+
* methods concat-fan across providers; single-row methods route to ONE
|
|
15465
|
+
* provider by the `addonId` in the call input (the notification-output
|
|
15466
|
+
* posture, notification-output.cap.ts:215-250). Provided by `addon-ai`
|
|
15467
|
+
* (hub-placed); the cap stays open for future providers.
|
|
15468
|
+
*
|
|
15469
|
+
* Profiles are ROWS (data), not addons: one row = one usable model endpoint.
|
|
15470
|
+
* `apiKey` is a password field — providers REDACT it on read and merge on
|
|
15471
|
+
* write; a stored key NEVER round-trips to a client.
|
|
15472
|
+
*/
|
|
15473
|
+
var LlmProfileKindSchema = _enum([
|
|
15474
|
+
"openai-compatible",
|
|
15475
|
+
"openai",
|
|
15476
|
+
"anthropic",
|
|
15477
|
+
"google",
|
|
15478
|
+
"managed-local"
|
|
15479
|
+
]);
|
|
15480
|
+
var LlmProfileSchema = object({
|
|
15481
|
+
id: string(),
|
|
15482
|
+
name: string(),
|
|
15483
|
+
kind: LlmProfileKindSchema,
|
|
15484
|
+
/** Stamped by the provider — keeps the fanned catalog routable. */
|
|
15485
|
+
addonId: string(),
|
|
15486
|
+
enabled: boolean(),
|
|
15487
|
+
/** Vendor model id, or the managed runtime's loaded model. */
|
|
15488
|
+
model: string(),
|
|
15489
|
+
/** Required for openai-compatible; override for cloud kinds. */
|
|
15490
|
+
baseUrl: string().optional(),
|
|
15491
|
+
/** ConfigUISchema type:'password' — never round-trips (spec §5). */
|
|
15492
|
+
apiKey: string().optional(),
|
|
15493
|
+
supportsVision: boolean(),
|
|
15494
|
+
temperature: number().min(0).max(2).optional(),
|
|
15495
|
+
maxTokens: number().int().positive().optional(),
|
|
15496
|
+
timeoutMs: number().int().positive().default(6e4),
|
|
15497
|
+
extraHeaders: record(string(), string()).optional(),
|
|
15498
|
+
/** kind === 'managed-local' only (spec §4). */
|
|
15499
|
+
runtime: ManagedRuntimeConfigSchema.optional()
|
|
15500
|
+
});
|
|
15501
|
+
/** ConfigUISchema tree passed through untyped on the wire (the
|
|
15502
|
+
* notification-output `ConfigSchemaPassthrough` precedent at
|
|
15503
|
+
* notification-output.cap.ts:151); the exported TS type re-tightens it. */
|
|
15504
|
+
var ConfigSchemaPassthrough = unknown();
|
|
15505
|
+
var LlmProfileKindDescriptorSchema = object({
|
|
15506
|
+
kind: LlmProfileKindSchema,
|
|
15507
|
+
label: string(),
|
|
15508
|
+
icon: string(),
|
|
15509
|
+
/** Stamped by each provider so the concat-fanned catalog stays routable. */
|
|
15510
|
+
addonId: string(),
|
|
15511
|
+
configSchema: ConfigSchemaPassthrough
|
|
15512
|
+
});
|
|
15513
|
+
var LlmDefaultSelectorSchema = union([object({ consumer: string() }), object({ purpose: _enum(["text", "vision"]) })]);
|
|
15514
|
+
var LlmDefaultSchema = object({
|
|
15515
|
+
selector: LlmDefaultSelectorSchema,
|
|
15516
|
+
profileId: string()
|
|
15517
|
+
});
|
|
15518
|
+
/** Server-side rollup row — getUsage never dumps raw call rows (spec §6). */
|
|
15519
|
+
var LlmUsageRollupSchema = object({
|
|
15520
|
+
day: string(),
|
|
15521
|
+
consumer: string(),
|
|
15522
|
+
profileId: string(),
|
|
15523
|
+
calls: number(),
|
|
15524
|
+
okCalls: number(),
|
|
15525
|
+
errorCalls: number(),
|
|
15526
|
+
inputTokens: number(),
|
|
15527
|
+
outputTokens: number(),
|
|
15528
|
+
avgLatencyMs: number()
|
|
15529
|
+
});
|
|
15530
|
+
/** LLM-facing view over the reused ModelCatalogEntry mechanism (spec §4.2). */
|
|
15531
|
+
var ManagedModelCatalogEntrySchema = object({
|
|
15532
|
+
id: string(),
|
|
15533
|
+
label: string(),
|
|
15534
|
+
family: string(),
|
|
15535
|
+
purpose: _enum(["text", "vision"]),
|
|
15536
|
+
url: string(),
|
|
15537
|
+
sha256: string(),
|
|
15538
|
+
sizeBytes: number(),
|
|
15539
|
+
quantization: string(),
|
|
15540
|
+
/** Load-time guidance shown in the picker. */
|
|
15541
|
+
minRamBytes: number(),
|
|
15542
|
+
contextSizeDefault: number().int(),
|
|
15543
|
+
/** Vision models: companion projector file. */
|
|
15544
|
+
mmprojUrl: string().optional()
|
|
15545
|
+
});
|
|
15546
|
+
var LlmRuntimeNodeSchema = object({
|
|
15547
|
+
nodeId: string(),
|
|
15548
|
+
reachable: boolean(),
|
|
15549
|
+
status: LlmRuntimeStatusSchema.optional(),
|
|
15550
|
+
disk: LlmRuntimeDiskUsageSchema.optional(),
|
|
15551
|
+
error: string().optional()
|
|
15552
|
+
});
|
|
15553
|
+
var GenerateVisionInputSchema = LlmGenerateBaseInputSchema.extend({ images: array(LlmImageSchema).min(1) });
|
|
15554
|
+
var ProfileRefInputSchema = object({
|
|
15555
|
+
addonId: string(),
|
|
15556
|
+
profileId: string()
|
|
15557
|
+
});
|
|
15558
|
+
method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, { kind: "mutation" }), method(GenerateVisionInputSchema, LlmGenerateResultSchema, { kind: "mutation" }), method(object({}), array(LlmProfileKindDescriptorSchema)), method(object({}), array(LlmProfileSchema)), method(object({ profile: LlmProfileSchema }), LlmProfileSchema, {
|
|
15559
|
+
kind: "mutation",
|
|
15560
|
+
auth: "admin"
|
|
15561
|
+
}), method(ProfileRefInputSchema, _void(), {
|
|
15562
|
+
kind: "mutation",
|
|
15563
|
+
auth: "admin"
|
|
15564
|
+
}), method(ProfileRefInputSchema, LlmGenerateResultSchema, {
|
|
15565
|
+
kind: "mutation",
|
|
15566
|
+
auth: "admin"
|
|
15567
|
+
}), method(ProfileRefInputSchema, array(string())), method(object({}), array(LlmDefaultSchema)), method(object({
|
|
15568
|
+
selector: LlmDefaultSelectorSchema,
|
|
15569
|
+
profileId: string().nullable()
|
|
15570
|
+
}), _void(), {
|
|
15571
|
+
kind: "mutation",
|
|
15572
|
+
auth: "admin"
|
|
15573
|
+
}), method(object({
|
|
15574
|
+
since: number().optional(),
|
|
15575
|
+
until: number().optional(),
|
|
15576
|
+
consumer: string().optional(),
|
|
15577
|
+
profileId: string().optional()
|
|
15578
|
+
}), array(LlmUsageRollupSchema)), method(object({}), array(ManagedModelCatalogEntrySchema)), method(object({}), array(LlmRuntimeNodeSchema)), method(object({ nodeId: string() }), array(LlmNodeModelSchema)), method(object({
|
|
15579
|
+
nodeId: string(),
|
|
15580
|
+
model: ManagedModelRefSchema
|
|
15581
|
+
}), _void(), {
|
|
15582
|
+
kind: "mutation",
|
|
15583
|
+
auth: "admin"
|
|
15584
|
+
}), method(object({
|
|
15585
|
+
nodeId: string(),
|
|
15586
|
+
file: string()
|
|
15587
|
+
}), _void(), {
|
|
15588
|
+
kind: "mutation",
|
|
15589
|
+
auth: "admin"
|
|
15590
|
+
}), method(ProfileRefInputSchema, LlmRuntimeStatusSchema), method(ProfileRefInputSchema, LlmRuntimeStatusSchema, {
|
|
15591
|
+
kind: "mutation",
|
|
15592
|
+
auth: "admin"
|
|
15593
|
+
}), method(ProfileRefInputSchema, _void(), {
|
|
15594
|
+
kind: "mutation",
|
|
15595
|
+
auth: "admin"
|
|
15596
|
+
});
|
|
15597
|
+
/**
|
|
15100
15598
|
* Zod schemas for persisted record types.
|
|
15101
15599
|
*
|
|
15102
15600
|
* These schemas serve as the single source of truth for types that are
|
|
@@ -15312,6 +15810,10 @@ var TrackSchema = object({
|
|
|
15312
15810
|
snapshots: array(TrackSnapshotSchema).readonly(),
|
|
15313
15811
|
/** Deduplicated zones the track has entered at least once. */
|
|
15314
15812
|
zonesVisited: array(string()).readonly(),
|
|
15813
|
+
/** Deduplicated set of detector classes observed for this track over its
|
|
15814
|
+
* life (a track may be reclassified, e.g. person→vehicle). Absent on
|
|
15815
|
+
* legacy rows written before class accumulation shipped. */
|
|
15816
|
+
classes: array(string()).readonly().optional(),
|
|
15315
15817
|
/** Cumulative normalized distance travelled (0..1 units = full frame width). */
|
|
15316
15818
|
totalDistance: number(),
|
|
15317
15819
|
state: TrackStateSchema,
|
|
@@ -15473,7 +15975,7 @@ var KeyEventSchema = object({
|
|
|
15473
15975
|
/** Track lifetime in ms (lastSeen - firstSeen). */
|
|
15474
15976
|
windowMs: number().optional()
|
|
15475
15977
|
});
|
|
15476
|
-
|
|
15978
|
+
object({
|
|
15477
15979
|
trackId: string(),
|
|
15478
15980
|
className: string(),
|
|
15479
15981
|
confidence: number(),
|
|
@@ -15481,6 +15983,23 @@ var TrackedDetectionSchema = object({
|
|
|
15481
15983
|
zones: array(string()).readonly(),
|
|
15482
15984
|
state: TrackStateSchema
|
|
15483
15985
|
});
|
|
15986
|
+
var OverlayDetectionSchema = looseObject({
|
|
15987
|
+
id: string(),
|
|
15988
|
+
kind: _enum(["first-level", "detail"]),
|
|
15989
|
+
macroClass: string(),
|
|
15990
|
+
score: number(),
|
|
15991
|
+
bbox: object({
|
|
15992
|
+
x: number(),
|
|
15993
|
+
y: number(),
|
|
15994
|
+
width: number(),
|
|
15995
|
+
height: number()
|
|
15996
|
+
}),
|
|
15997
|
+
labels: array(looseObject({
|
|
15998
|
+
label: string(),
|
|
15999
|
+
score: number()
|
|
16000
|
+
})).readonly(),
|
|
16001
|
+
parentId: string().optional()
|
|
16002
|
+
});
|
|
15484
16003
|
var ScoredObjectEventSchema = ObjectEventSchema.extend({ score: number() });
|
|
15485
16004
|
var SearchObjectEventsInput = object({
|
|
15486
16005
|
text: string(),
|
|
@@ -15491,6 +16010,20 @@ var SearchObjectEventsInput = object({
|
|
|
15491
16010
|
limit: number().default(50),
|
|
15492
16011
|
minScore: number().min(0).max(1).default(.2)
|
|
15493
16012
|
});
|
|
16013
|
+
var TrackCascadeCountsSchema = object({
|
|
16014
|
+
/** Persisted track roots deleted (authoritative). */
|
|
16015
|
+
tracks: number().int(),
|
|
16016
|
+
/** Object events removed with their tracks (best-effort; see note above). */
|
|
16017
|
+
events: number().int(),
|
|
16018
|
+
/** Track/face/plate-owned media removed (best-effort). Never identity media. */
|
|
16019
|
+
media: number().int(),
|
|
16020
|
+
/** Unassigned (non-enrolled) face reads removed (best-effort). */
|
|
16021
|
+
faces: number().int(),
|
|
16022
|
+
/** Unassigned plate reads removed (best-effort; plate leg deferred to plate-intelligence). */
|
|
16023
|
+
plates: number().int(),
|
|
16024
|
+
/** Per-track CLIP search vectors removed (best-effort). */
|
|
16025
|
+
embeddings: number().int()
|
|
16026
|
+
});
|
|
15494
16027
|
DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).readonly()), method(object({
|
|
15495
16028
|
deviceId: number(),
|
|
15496
16029
|
trackId: string()
|
|
@@ -15522,6 +16055,24 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
|
|
|
15522
16055
|
}), {
|
|
15523
16056
|
kind: "mutation",
|
|
15524
16057
|
auth: "admin"
|
|
16058
|
+
}), method(object({
|
|
16059
|
+
deviceId: number(),
|
|
16060
|
+
cutoffMs: number()
|
|
16061
|
+
}), TrackCascadeCountsSchema, {
|
|
16062
|
+
kind: "mutation",
|
|
16063
|
+
auth: "admin"
|
|
16064
|
+
}), method(object({ deviceId: number() }), TrackCascadeCountsSchema, {
|
|
16065
|
+
kind: "mutation",
|
|
16066
|
+
auth: "admin"
|
|
16067
|
+
}), method(object({
|
|
16068
|
+
deviceId: number(),
|
|
16069
|
+
trackIds: array(string()).min(1)
|
|
16070
|
+
}), object({
|
|
16071
|
+
deleted: number().int(),
|
|
16072
|
+
failed: array(string()).readonly()
|
|
16073
|
+
}), {
|
|
16074
|
+
kind: "mutation",
|
|
16075
|
+
auth: "admin"
|
|
15525
16076
|
}), method(object({
|
|
15526
16077
|
eventId: string(),
|
|
15527
16078
|
kind: MediaFileKindEnum.optional()
|
|
@@ -15530,7 +16081,7 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
|
|
|
15530
16081
|
timestamp: number(),
|
|
15531
16082
|
frameWidth: number(),
|
|
15532
16083
|
frameHeight: number(),
|
|
15533
|
-
detections: array(
|
|
16084
|
+
detections: array(OverlayDetectionSchema).readonly()
|
|
15534
16085
|
}), object({
|
|
15535
16086
|
deviceId: number(),
|
|
15536
16087
|
trackId: string(),
|
|
@@ -18316,6 +18867,24 @@ DeviceType.Camera, method(object({
|
|
|
18316
18867
|
deviceId: number(),
|
|
18317
18868
|
status: OsdStatusSchema
|
|
18318
18869
|
});
|
|
18870
|
+
var VehicleSchema = object({
|
|
18871
|
+
id: string(),
|
|
18872
|
+
name: string(),
|
|
18873
|
+
sampleCount: number().int().nonnegative(),
|
|
18874
|
+
coverMediaKey: string().optional(),
|
|
18875
|
+
/** Inline base64 of the cover sample's plate crop, resolved from `coverMediaKey`. */
|
|
18876
|
+
coverBase64: string().optional()
|
|
18877
|
+
});
|
|
18878
|
+
var VehicleSampleInfoSchema = object({
|
|
18879
|
+
id: string(),
|
|
18880
|
+
/** The plate text this sample enrolled (self-labeling — no embedding). */
|
|
18881
|
+
text: string(),
|
|
18882
|
+
/** OCR confidence of the enrolled read (0..1). */
|
|
18883
|
+
score: number(),
|
|
18884
|
+
addedAt: number().int(),
|
|
18885
|
+
deviceId: number().int().optional(),
|
|
18886
|
+
base64: string().optional()
|
|
18887
|
+
});
|
|
18319
18888
|
var PlateInfoSchema = object({
|
|
18320
18889
|
plateId: string(),
|
|
18321
18890
|
deviceId: number().int(),
|
|
@@ -18327,6 +18896,16 @@ var PlateInfoSchema = object({
|
|
|
18327
18896
|
score: number(),
|
|
18328
18897
|
/** True when the text was manually corrected (exempt from retention). */
|
|
18329
18898
|
corrected: boolean(),
|
|
18899
|
+
/** Recognized vehicle id when a matcher lookup named this read (SQL NULL → absent). */
|
|
18900
|
+
recognizedVehicleId: string().optional(),
|
|
18901
|
+
/** Resolved vehicle name for `recognizedVehicleId` (UI convenience). */
|
|
18902
|
+
vehicleName: string().optional(),
|
|
18903
|
+
/** True once the read was assigned to a vehicle (enrolled as a sample). */
|
|
18904
|
+
assigned: boolean(),
|
|
18905
|
+
/** keyFrame parity: the plate bbox (pixel space) on the native key frame. */
|
|
18906
|
+
plateBbox: BoundingBoxSchema.optional(),
|
|
18907
|
+
/** keyFrame parity: MediaStore key of the track's native-resolution key frame. */
|
|
18908
|
+
keyFrameMediaKey: string().optional(),
|
|
18330
18909
|
base64: string().optional()
|
|
18331
18910
|
});
|
|
18332
18911
|
var MediaFileLiteSchema = object({
|
|
@@ -18366,6 +18945,48 @@ method(object({
|
|
|
18366
18945
|
}), method(object({ plateId: string() }), _void(), {
|
|
18367
18946
|
kind: "mutation",
|
|
18368
18947
|
auth: "admin"
|
|
18948
|
+
}), method(_void(), array(VehicleSchema).readonly()), method(object({ name: string().min(1) }), VehicleSchema, {
|
|
18949
|
+
kind: "mutation",
|
|
18950
|
+
auth: "admin"
|
|
18951
|
+
}), method(object({
|
|
18952
|
+
id: string(),
|
|
18953
|
+
name: string().min(1)
|
|
18954
|
+
}), _void(), {
|
|
18955
|
+
kind: "mutation",
|
|
18956
|
+
auth: "admin"
|
|
18957
|
+
}), method(object({ id: string() }), _void(), {
|
|
18958
|
+
kind: "mutation",
|
|
18959
|
+
auth: "admin"
|
|
18960
|
+
}), method(object({ vehicleId: string() }), array(VehicleSampleInfoSchema).readonly()), method(object({
|
|
18961
|
+
vehicleId: string(),
|
|
18962
|
+
sampleId: string()
|
|
18963
|
+
}), _void(), {
|
|
18964
|
+
kind: "mutation",
|
|
18965
|
+
auth: "admin"
|
|
18966
|
+
}), method(object({
|
|
18967
|
+
plateId: string(),
|
|
18968
|
+
vehicleId: string()
|
|
18969
|
+
}), _void(), {
|
|
18970
|
+
kind: "mutation",
|
|
18971
|
+
auth: "admin"
|
|
18972
|
+
}), method(object({ plateId: string() }), _void(), {
|
|
18973
|
+
kind: "mutation",
|
|
18974
|
+
auth: "admin"
|
|
18975
|
+
}), method(object({
|
|
18976
|
+
plateIds: array(string()).min(1),
|
|
18977
|
+
vehicleId: string()
|
|
18978
|
+
}), object({
|
|
18979
|
+
assigned: number().int(),
|
|
18980
|
+
failed: array(string()).readonly()
|
|
18981
|
+
}), {
|
|
18982
|
+
kind: "mutation",
|
|
18983
|
+
auth: "admin"
|
|
18984
|
+
}), method(object({ plateIds: array(string()).min(1) }), object({
|
|
18985
|
+
unassigned: number().int(),
|
|
18986
|
+
failed: array(string()).readonly()
|
|
18987
|
+
}), {
|
|
18988
|
+
kind: "mutation",
|
|
18989
|
+
auth: "admin"
|
|
18369
18990
|
});
|
|
18370
18991
|
var ModelFormatSchema = _enum(MODEL_FORMATS);
|
|
18371
18992
|
var HwAccelBackendInputSchema = _enum([
|
|
@@ -20911,6 +21532,168 @@ Object.freeze({
|
|
|
20911
21532
|
addonId: null,
|
|
20912
21533
|
access: "create"
|
|
20913
21534
|
},
|
|
21535
|
+
"llm.deleteModel": {
|
|
21536
|
+
capName: "llm",
|
|
21537
|
+
capScope: "system",
|
|
21538
|
+
addonId: null,
|
|
21539
|
+
access: "delete"
|
|
21540
|
+
},
|
|
21541
|
+
"llm.deleteProfile": {
|
|
21542
|
+
capName: "llm",
|
|
21543
|
+
capScope: "system",
|
|
21544
|
+
addonId: null,
|
|
21545
|
+
access: "delete"
|
|
21546
|
+
},
|
|
21547
|
+
"llm.generate": {
|
|
21548
|
+
capName: "llm",
|
|
21549
|
+
capScope: "system",
|
|
21550
|
+
addonId: null,
|
|
21551
|
+
access: "create"
|
|
21552
|
+
},
|
|
21553
|
+
"llm.generateVision": {
|
|
21554
|
+
capName: "llm",
|
|
21555
|
+
capScope: "system",
|
|
21556
|
+
addonId: null,
|
|
21557
|
+
access: "create"
|
|
21558
|
+
},
|
|
21559
|
+
"llm.getDefaults": {
|
|
21560
|
+
capName: "llm",
|
|
21561
|
+
capScope: "system",
|
|
21562
|
+
addonId: null,
|
|
21563
|
+
access: "view"
|
|
21564
|
+
},
|
|
21565
|
+
"llm.getRuntimeStatus": {
|
|
21566
|
+
capName: "llm",
|
|
21567
|
+
capScope: "system",
|
|
21568
|
+
addonId: null,
|
|
21569
|
+
access: "view"
|
|
21570
|
+
},
|
|
21571
|
+
"llm.getUsage": {
|
|
21572
|
+
capName: "llm",
|
|
21573
|
+
capScope: "system",
|
|
21574
|
+
addonId: null,
|
|
21575
|
+
access: "view"
|
|
21576
|
+
},
|
|
21577
|
+
"llm.installModel": {
|
|
21578
|
+
capName: "llm",
|
|
21579
|
+
capScope: "system",
|
|
21580
|
+
addonId: null,
|
|
21581
|
+
access: "create"
|
|
21582
|
+
},
|
|
21583
|
+
"llm.listModelCatalog": {
|
|
21584
|
+
capName: "llm",
|
|
21585
|
+
capScope: "system",
|
|
21586
|
+
addonId: null,
|
|
21587
|
+
access: "view"
|
|
21588
|
+
},
|
|
21589
|
+
"llm.listModels": {
|
|
21590
|
+
capName: "llm",
|
|
21591
|
+
capScope: "system",
|
|
21592
|
+
addonId: null,
|
|
21593
|
+
access: "view"
|
|
21594
|
+
},
|
|
21595
|
+
"llm.listNodeModels": {
|
|
21596
|
+
capName: "llm",
|
|
21597
|
+
capScope: "system",
|
|
21598
|
+
addonId: null,
|
|
21599
|
+
access: "view"
|
|
21600
|
+
},
|
|
21601
|
+
"llm.listProfileKinds": {
|
|
21602
|
+
capName: "llm",
|
|
21603
|
+
capScope: "system",
|
|
21604
|
+
addonId: null,
|
|
21605
|
+
access: "view"
|
|
21606
|
+
},
|
|
21607
|
+
"llm.listProfiles": {
|
|
21608
|
+
capName: "llm",
|
|
21609
|
+
capScope: "system",
|
|
21610
|
+
addonId: null,
|
|
21611
|
+
access: "view"
|
|
21612
|
+
},
|
|
21613
|
+
"llm.listRuntimeNodes": {
|
|
21614
|
+
capName: "llm",
|
|
21615
|
+
capScope: "system",
|
|
21616
|
+
addonId: null,
|
|
21617
|
+
access: "view"
|
|
21618
|
+
},
|
|
21619
|
+
"llm.setDefault": {
|
|
21620
|
+
capName: "llm",
|
|
21621
|
+
capScope: "system",
|
|
21622
|
+
addonId: null,
|
|
21623
|
+
access: "create"
|
|
21624
|
+
},
|
|
21625
|
+
"llm.startRuntime": {
|
|
21626
|
+
capName: "llm",
|
|
21627
|
+
capScope: "system",
|
|
21628
|
+
addonId: null,
|
|
21629
|
+
access: "create"
|
|
21630
|
+
},
|
|
21631
|
+
"llm.stopRuntime": {
|
|
21632
|
+
capName: "llm",
|
|
21633
|
+
capScope: "system",
|
|
21634
|
+
addonId: null,
|
|
21635
|
+
access: "create"
|
|
21636
|
+
},
|
|
21637
|
+
"llm.testProfile": {
|
|
21638
|
+
capName: "llm",
|
|
21639
|
+
capScope: "system",
|
|
21640
|
+
addonId: null,
|
|
21641
|
+
access: "create"
|
|
21642
|
+
},
|
|
21643
|
+
"llm.upsertProfile": {
|
|
21644
|
+
capName: "llm",
|
|
21645
|
+
capScope: "system",
|
|
21646
|
+
addonId: null,
|
|
21647
|
+
access: "create"
|
|
21648
|
+
},
|
|
21649
|
+
"llmRuntime.complete": {
|
|
21650
|
+
capName: "llm-runtime",
|
|
21651
|
+
capScope: "system",
|
|
21652
|
+
addonId: null,
|
|
21653
|
+
access: "create"
|
|
21654
|
+
},
|
|
21655
|
+
"llmRuntime.deleteModel": {
|
|
21656
|
+
capName: "llm-runtime",
|
|
21657
|
+
capScope: "system",
|
|
21658
|
+
addonId: null,
|
|
21659
|
+
access: "delete"
|
|
21660
|
+
},
|
|
21661
|
+
"llmRuntime.ensureStarted": {
|
|
21662
|
+
capName: "llm-runtime",
|
|
21663
|
+
capScope: "system",
|
|
21664
|
+
addonId: null,
|
|
21665
|
+
access: "create"
|
|
21666
|
+
},
|
|
21667
|
+
"llmRuntime.getDiskUsage": {
|
|
21668
|
+
capName: "llm-runtime",
|
|
21669
|
+
capScope: "system",
|
|
21670
|
+
addonId: null,
|
|
21671
|
+
access: "view"
|
|
21672
|
+
},
|
|
21673
|
+
"llmRuntime.installModel": {
|
|
21674
|
+
capName: "llm-runtime",
|
|
21675
|
+
capScope: "system",
|
|
21676
|
+
addonId: null,
|
|
21677
|
+
access: "create"
|
|
21678
|
+
},
|
|
21679
|
+
"llmRuntime.listLocalModels": {
|
|
21680
|
+
capName: "llm-runtime",
|
|
21681
|
+
capScope: "system",
|
|
21682
|
+
addonId: null,
|
|
21683
|
+
access: "view"
|
|
21684
|
+
},
|
|
21685
|
+
"llmRuntime.status": {
|
|
21686
|
+
capName: "llm-runtime",
|
|
21687
|
+
capScope: "system",
|
|
21688
|
+
addonId: null,
|
|
21689
|
+
access: "view"
|
|
21690
|
+
},
|
|
21691
|
+
"llmRuntime.stop": {
|
|
21692
|
+
capName: "llm-runtime",
|
|
21693
|
+
capScope: "system",
|
|
21694
|
+
addonId: null,
|
|
21695
|
+
access: "create"
|
|
21696
|
+
},
|
|
20914
21697
|
"localNetwork.getAllowedAddresses": {
|
|
20915
21698
|
capName: "local-network",
|
|
20916
21699
|
capScope: "system",
|
|
@@ -21541,6 +22324,12 @@ Object.freeze({
|
|
|
21541
22324
|
addonId: null,
|
|
21542
22325
|
access: "delete"
|
|
21543
22326
|
},
|
|
22327
|
+
"pipelineAnalytics.deleteTracks": {
|
|
22328
|
+
capName: "pipeline-analytics",
|
|
22329
|
+
capScope: "device",
|
|
22330
|
+
addonId: null,
|
|
22331
|
+
access: "delete"
|
|
22332
|
+
},
|
|
21544
22333
|
"pipelineAnalytics.getActiveTracks": {
|
|
21545
22334
|
capName: "pipeline-analytics",
|
|
21546
22335
|
capScope: "device",
|
|
@@ -21607,12 +22396,24 @@ Object.freeze({
|
|
|
21607
22396
|
addonId: null,
|
|
21608
22397
|
access: "create"
|
|
21609
22398
|
},
|
|
22399
|
+
"pipelineAnalytics.pruneTracksBefore": {
|
|
22400
|
+
capName: "pipeline-analytics",
|
|
22401
|
+
capScope: "device",
|
|
22402
|
+
addonId: null,
|
|
22403
|
+
access: "create"
|
|
22404
|
+
},
|
|
21610
22405
|
"pipelineAnalytics.searchObjectEvents": {
|
|
21611
22406
|
capName: "pipeline-analytics",
|
|
21612
22407
|
capScope: "device",
|
|
21613
22408
|
addonId: null,
|
|
21614
22409
|
access: "view"
|
|
21615
22410
|
},
|
|
22411
|
+
"pipelineAnalytics.wipeAllAnalytics": {
|
|
22412
|
+
capName: "pipeline-analytics",
|
|
22413
|
+
capScope: "device",
|
|
22414
|
+
addonId: null,
|
|
22415
|
+
access: "delete"
|
|
22416
|
+
},
|
|
21616
22417
|
"pipelineExecutor.cacheFrameInPool": {
|
|
21617
22418
|
capName: "pipeline-executor",
|
|
21618
22419
|
capScope: "system",
|
|
@@ -22117,18 +22918,42 @@ Object.freeze({
|
|
|
22117
22918
|
addonId: null,
|
|
22118
22919
|
access: "create"
|
|
22119
22920
|
},
|
|
22921
|
+
"plateGallery.assignPlate": {
|
|
22922
|
+
capName: "plate-gallery",
|
|
22923
|
+
capScope: "system",
|
|
22924
|
+
addonId: null,
|
|
22925
|
+
access: "create"
|
|
22926
|
+
},
|
|
22927
|
+
"plateGallery.assignPlates": {
|
|
22928
|
+
capName: "plate-gallery",
|
|
22929
|
+
capScope: "system",
|
|
22930
|
+
addonId: null,
|
|
22931
|
+
access: "create"
|
|
22932
|
+
},
|
|
22120
22933
|
"plateGallery.correctPlateText": {
|
|
22121
22934
|
capName: "plate-gallery",
|
|
22122
22935
|
capScope: "system",
|
|
22123
22936
|
addonId: null,
|
|
22124
22937
|
access: "create"
|
|
22125
22938
|
},
|
|
22939
|
+
"plateGallery.createVehicle": {
|
|
22940
|
+
capName: "plate-gallery",
|
|
22941
|
+
capScope: "system",
|
|
22942
|
+
addonId: null,
|
|
22943
|
+
access: "create"
|
|
22944
|
+
},
|
|
22126
22945
|
"plateGallery.deletePlate": {
|
|
22127
22946
|
capName: "plate-gallery",
|
|
22128
22947
|
capScope: "system",
|
|
22129
22948
|
addonId: null,
|
|
22130
22949
|
access: "delete"
|
|
22131
22950
|
},
|
|
22951
|
+
"plateGallery.deleteVehicle": {
|
|
22952
|
+
capName: "plate-gallery",
|
|
22953
|
+
capScope: "system",
|
|
22954
|
+
addonId: null,
|
|
22955
|
+
access: "delete"
|
|
22956
|
+
},
|
|
22132
22957
|
"plateGallery.getPlateByTrack": {
|
|
22133
22958
|
capName: "plate-gallery",
|
|
22134
22959
|
capScope: "system",
|
|
@@ -22147,6 +22972,30 @@ Object.freeze({
|
|
|
22147
22972
|
addonId: null,
|
|
22148
22973
|
access: "view"
|
|
22149
22974
|
},
|
|
22975
|
+
"plateGallery.listVehicles": {
|
|
22976
|
+
capName: "plate-gallery",
|
|
22977
|
+
capScope: "system",
|
|
22978
|
+
addonId: null,
|
|
22979
|
+
access: "view"
|
|
22980
|
+
},
|
|
22981
|
+
"plateGallery.listVehicleSamples": {
|
|
22982
|
+
capName: "plate-gallery",
|
|
22983
|
+
capScope: "system",
|
|
22984
|
+
addonId: null,
|
|
22985
|
+
access: "view"
|
|
22986
|
+
},
|
|
22987
|
+
"plateGallery.removeVehicleSample": {
|
|
22988
|
+
capName: "plate-gallery",
|
|
22989
|
+
capScope: "system",
|
|
22990
|
+
addonId: null,
|
|
22991
|
+
access: "delete"
|
|
22992
|
+
},
|
|
22993
|
+
"plateGallery.renameVehicle": {
|
|
22994
|
+
capName: "plate-gallery",
|
|
22995
|
+
capScope: "system",
|
|
22996
|
+
addonId: null,
|
|
22997
|
+
access: "create"
|
|
22998
|
+
},
|
|
22150
22999
|
"plateGallery.searchPlates": {
|
|
22151
23000
|
capName: "plate-gallery",
|
|
22152
23001
|
capScope: "system",
|
|
@@ -22159,6 +23008,18 @@ Object.freeze({
|
|
|
22159
23008
|
addonId: null,
|
|
22160
23009
|
access: "view"
|
|
22161
23010
|
},
|
|
23011
|
+
"plateGallery.unassignPlate": {
|
|
23012
|
+
capName: "plate-gallery",
|
|
23013
|
+
capScope: "system",
|
|
23014
|
+
addonId: null,
|
|
23015
|
+
access: "create"
|
|
23016
|
+
},
|
|
23017
|
+
"plateGallery.unassignPlates": {
|
|
23018
|
+
capName: "plate-gallery",
|
|
23019
|
+
capScope: "system",
|
|
23020
|
+
addonId: null,
|
|
23021
|
+
access: "create"
|
|
23022
|
+
},
|
|
22162
23023
|
"platformProbe.getCapabilities": {
|
|
22163
23024
|
capName: "platform-probe",
|
|
22164
23025
|
capScope: "system",
|
|
@@ -22351,6 +23212,48 @@ Object.freeze({
|
|
|
22351
23212
|
addonId: null,
|
|
22352
23213
|
access: "create"
|
|
22353
23214
|
},
|
|
23215
|
+
"sceneMonitor.captureReference": {
|
|
23216
|
+
capName: "scene-monitor",
|
|
23217
|
+
capScope: "device",
|
|
23218
|
+
addonId: null,
|
|
23219
|
+
access: "create"
|
|
23220
|
+
},
|
|
23221
|
+
"sceneMonitor.createScene": {
|
|
23222
|
+
capName: "scene-monitor",
|
|
23223
|
+
capScope: "device",
|
|
23224
|
+
addonId: null,
|
|
23225
|
+
access: "create"
|
|
23226
|
+
},
|
|
23227
|
+
"sceneMonitor.deleteReference": {
|
|
23228
|
+
capName: "scene-monitor",
|
|
23229
|
+
capScope: "device",
|
|
23230
|
+
addonId: null,
|
|
23231
|
+
access: "delete"
|
|
23232
|
+
},
|
|
23233
|
+
"sceneMonitor.deleteScene": {
|
|
23234
|
+
capName: "scene-monitor",
|
|
23235
|
+
capScope: "device",
|
|
23236
|
+
addonId: null,
|
|
23237
|
+
access: "delete"
|
|
23238
|
+
},
|
|
23239
|
+
"sceneMonitor.listScenes": {
|
|
23240
|
+
capName: "scene-monitor",
|
|
23241
|
+
capScope: "device",
|
|
23242
|
+
addonId: null,
|
|
23243
|
+
access: "view"
|
|
23244
|
+
},
|
|
23245
|
+
"sceneMonitor.recheckNow": {
|
|
23246
|
+
capName: "scene-monitor",
|
|
23247
|
+
capScope: "device",
|
|
23248
|
+
addonId: null,
|
|
23249
|
+
access: "create"
|
|
23250
|
+
},
|
|
23251
|
+
"sceneMonitor.updateScene": {
|
|
23252
|
+
capName: "scene-monitor",
|
|
23253
|
+
capScope: "device",
|
|
23254
|
+
addonId: null,
|
|
23255
|
+
access: "create"
|
|
23256
|
+
},
|
|
22354
23257
|
"scriptRunner.run": {
|
|
22355
23258
|
capName: "script-runner",
|
|
22356
23259
|
capScope: "device",
|
|
@@ -23435,6 +24338,7 @@ Object.freeze({
|
|
|
23435
24338
|
Object.freeze({
|
|
23436
24339
|
"broker": "broker",
|
|
23437
24340
|
"device-export": "device-export",
|
|
24341
|
+
"llm": "ai",
|
|
23438
24342
|
"mesh-network": "mesh",
|
|
23439
24343
|
"mqtt-broker": "broker",
|
|
23440
24344
|
"network-access": "ingress",
|