@camstack/addon-ai 0.4.124 → 0.4.126
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/THIRD_PARTY_MODELS.md +126 -115
- package/dist/addon.js +801 -169
- package/dist/addon.mjs +801 -169
- package/package.json +1 -1
package/dist/addon.js
CHANGED
|
@@ -5525,7 +5525,7 @@ function number(params) {
|
|
|
5525
5525
|
return /* @__PURE__ */ _coercedNumber(ZodNumber, params);
|
|
5526
5526
|
}
|
|
5527
5527
|
//#endregion
|
|
5528
|
-
//#region ../types/dist/sleep-
|
|
5528
|
+
//#region ../types/dist/sleep-DC-wdyeS.mjs
|
|
5529
5529
|
/**
|
|
5530
5530
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5531
5531
|
* window to float samples (D455).
|
|
@@ -6310,6 +6310,40 @@ var BaseAddon = class {
|
|
|
6310
6310
|
const node = normalizeNodeId(nodeId ?? this._ctx?.kernel?.localNodeId);
|
|
6311
6311
|
return keys.size > 0 ? projectStore(raw, keys, node) : raw;
|
|
6312
6312
|
}
|
|
6313
|
+
/**
|
|
6314
|
+
* Whether ONE global key of this addon's store was written, read three-way
|
|
6315
|
+
* (D651). For a question a hydrated view cannot answer: `getGlobalSettings`
|
|
6316
|
+
* reports `value ?? default`, so "the operator chose the default" and "nobody
|
|
6317
|
+
* chose" look the same, and a failed read looks like both. A `perNode` key is
|
|
6318
|
+
* not supported here: its stored name is scoped.
|
|
6319
|
+
*/
|
|
6320
|
+
async readStoredGlobalKey(key) {
|
|
6321
|
+
const read = this._ctx?.settings?.readAddonStoreResult;
|
|
6322
|
+
if (read === void 0) return {
|
|
6323
|
+
kind: "unreadable",
|
|
6324
|
+
reason: "three-way-read-unavailable"
|
|
6325
|
+
};
|
|
6326
|
+
let result;
|
|
6327
|
+
try {
|
|
6328
|
+
result = await read.call(this._ctx?.settings);
|
|
6329
|
+
} catch (err) {
|
|
6330
|
+
return {
|
|
6331
|
+
kind: "unreadable",
|
|
6332
|
+
reason: "store-read-failed",
|
|
6333
|
+
error: err instanceof Error ? err.message : String(err)
|
|
6334
|
+
};
|
|
6335
|
+
}
|
|
6336
|
+
if (result.kind === "failed") return {
|
|
6337
|
+
kind: "unreadable",
|
|
6338
|
+
reason: "store-read-failed",
|
|
6339
|
+
error: result.error
|
|
6340
|
+
};
|
|
6341
|
+
if (result.kind === "missing" || !Object.prototype.hasOwnProperty.call(result.value, key)) return { kind: "absent" };
|
|
6342
|
+
return {
|
|
6343
|
+
kind: "present",
|
|
6344
|
+
value: result.value[key]
|
|
6345
|
+
};
|
|
6346
|
+
}
|
|
6313
6347
|
async updateGlobalSettings(patch, nodeId) {
|
|
6314
6348
|
const keys = this.perNodeKeys();
|
|
6315
6349
|
const localNode = normalizeNodeId(this._ctx?.kernel?.localNodeId);
|
|
@@ -9611,6 +9645,43 @@ var LogChannelWindowSchema = object({
|
|
|
9611
9645
|
/** `null` = every camera. A non-empty list narrows to those numeric ids. */
|
|
9612
9646
|
deviceIds: array(number$1().int()).readonly().nullable()
|
|
9613
9647
|
});
|
|
9648
|
+
var ClipModelMetaSchema = object({
|
|
9649
|
+
/** The paired text encoder's catalog id (the embedding-encoder's text catalog). */
|
|
9650
|
+
textModelId: string().min(1),
|
|
9651
|
+
/** Output dimension of BOTH towers. A vector of any other length is refused. */
|
|
9652
|
+
embeddingDim: number$1().int().positive(),
|
|
9653
|
+
/**
|
|
9654
|
+
* The `vector-store` index this model's vectors live in. ONE feature space
|
|
9655
|
+
* per index: two models share an index only when their vectors are ranked
|
|
9656
|
+
* against each other, which for CLIP means never across families. MobileCLIP
|
|
9657
|
+
* S1 and S2 share `object-clip` for history (separated by the row's
|
|
9658
|
+
* `modelId`); any other model gets its own.
|
|
9659
|
+
*/
|
|
9660
|
+
vectorIndex: string().regex(/^object-clip(-[a-z0-9][a-z0-9-]*)?$/),
|
|
9661
|
+
/**
|
|
9662
|
+
* The text encoder's tokenizer, a declared SIBLING file of its onnx. The name
|
|
9663
|
+
* must be unique per tokenizer: every model's siblings land in ONE flat
|
|
9664
|
+
* models directory, so two different tokenizers under the same name would
|
|
9665
|
+
* silently overwrite each other (whichever model downloaded last wins, and
|
|
9666
|
+
* the other one tokenises with the wrong vocabulary).
|
|
9667
|
+
*/
|
|
9668
|
+
tokenizerFile: string().min(1),
|
|
9669
|
+
/** Token window the text graph takes (SigLIP2: 64; CLIP BPE: 77). */
|
|
9670
|
+
contextLength: number$1().int().positive(),
|
|
9671
|
+
/** Id the tokenizer pads with. */
|
|
9672
|
+
padId: number$1().int().nonnegative(),
|
|
9673
|
+
/**
|
|
9674
|
+
* The search cosine floor at `strictness: 'loose'` — calibrated per model,
|
|
9675
|
+
* because cosine bands are a property of the model: 0.2 keeps 96% of matched
|
|
9676
|
+
* COCO caption-image pairs on MobileCLIP S1 and 2.7% on SigLIP2.
|
|
9677
|
+
*/
|
|
9678
|
+
searchMinScore: number$1().min(0).max(1)
|
|
9679
|
+
});
|
|
9680
|
+
var ClipSearchStrictnessSchema = _enum([
|
|
9681
|
+
"loose",
|
|
9682
|
+
"balanced",
|
|
9683
|
+
"strict"
|
|
9684
|
+
]);
|
|
9614
9685
|
var MODEL_FORMATS = [
|
|
9615
9686
|
"onnx",
|
|
9616
9687
|
"coreml",
|
|
@@ -9700,6 +9771,48 @@ var ModelProviderIdSchema = _enum([
|
|
|
9700
9771
|
"scrypted",
|
|
9701
9772
|
"custom"
|
|
9702
9773
|
]);
|
|
9774
|
+
/**
|
|
9775
|
+
* The licence of a model, as a record rather than a bare SPDX string: a
|
|
9776
|
+
* permissive CODE licence routinely sits on top of restrictive WEIGHTS or
|
|
9777
|
+
* DATA, and the obligations (attribution, modification notices, source offers)
|
|
9778
|
+
* are per upstream. A persisted custom-model row written when this field was a
|
|
9779
|
+
* string still parses — the string is lifted into `{ weights }`.
|
|
9780
|
+
*
|
|
9781
|
+
* Every licence surface (the admin "Models and licenses" page,
|
|
9782
|
+
* `THIRD_PARTY_MODELS.md`, the Hugging Face model table) is GENERATED from
|
|
9783
|
+
* these records by `scripts/gen-model-licenses.ts` (D661).
|
|
9784
|
+
*/
|
|
9785
|
+
var ModelLicenseSchema = preprocess((value) => typeof value === "string" ? { weights: value } : value, object({
|
|
9786
|
+
/** SPDX id of the WEIGHTS' terms, a `LicenseRef-*` for non-SPDX terms, or `UNKNOWN`. */
|
|
9787
|
+
weights: string().min(1),
|
|
9788
|
+
/** SPDX id of the upstream code that defines / trained the network. */
|
|
9789
|
+
code: string().min(1).optional(),
|
|
9790
|
+
/** Training data whose terms add obligations (attribution, non-commercial). */
|
|
9791
|
+
data: object({
|
|
9792
|
+
name: string().min(1),
|
|
9793
|
+
terms: string().min(1),
|
|
9794
|
+
url: string().url().optional()
|
|
9795
|
+
}).optional(),
|
|
9796
|
+
/** The project the weights come from. Required on built-in entries (guard). */
|
|
9797
|
+
upstream: object({
|
|
9798
|
+
name: string().min(1),
|
|
9799
|
+
url: string().url()
|
|
9800
|
+
}).optional(),
|
|
9801
|
+
/** Where the licence text governing the weights is published. */
|
|
9802
|
+
url: string().url().optional(),
|
|
9803
|
+
/** Attribution the licence REQUIRES, verbatim. */
|
|
9804
|
+
attribution: string().min(1).optional(),
|
|
9805
|
+
/** What CamStack changed. Required when `hosting` is `camstack-hf` (guard). */
|
|
9806
|
+
modifications: string().min(1).optional(),
|
|
9807
|
+
/** Who serves the file a node downloads. */
|
|
9808
|
+
hosting: _enum([
|
|
9809
|
+
"camstack-hf",
|
|
9810
|
+
"third-party",
|
|
9811
|
+
"built-in"
|
|
9812
|
+
]).optional(),
|
|
9813
|
+
/** True when the weights or their data forbid commercial use. */
|
|
9814
|
+
nonCommercial: boolean().optional()
|
|
9815
|
+
}));
|
|
9703
9816
|
var ModelCatalogEntrySchema = object({
|
|
9704
9817
|
id: string(),
|
|
9705
9818
|
name: string(),
|
|
@@ -9788,11 +9901,11 @@ var ModelCatalogEntrySchema = object({
|
|
|
9788
9901
|
p95LatencyMs: record(string(), number$1()).optional()
|
|
9789
9902
|
}).optional(),
|
|
9790
9903
|
/**
|
|
9791
|
-
*
|
|
9792
|
-
*
|
|
9793
|
-
*
|
|
9904
|
+
* The model's licence record — see {@link ModelLicenseSchema}. Optional in
|
|
9905
|
+
* the schema (a custom model's author may state none); REQUIRED and complete
|
|
9906
|
+
* on every built-in catalog entry (`scripts/check-catalog-licence.ts`).
|
|
9794
9907
|
*/
|
|
9795
|
-
license:
|
|
9908
|
+
license: ModelLicenseSchema.optional(),
|
|
9796
9909
|
/**
|
|
9797
9910
|
* Variant-selector grouping. The UI groups models by `family` + `tier` and
|
|
9798
9911
|
* offers `precision` / `optimization` as variant axes WITHIN a tier — so all
|
|
@@ -9814,7 +9927,14 @@ var ModelCatalogEntrySchema = object({
|
|
|
9814
9927
|
* applies (Frigate / COCO public catalog). Set on a custom model whose raw
|
|
9815
9928
|
* labels already ARE the CamStack macros (Scrypted identity map).
|
|
9816
9929
|
*/
|
|
9817
|
-
classMap: DetectionCatalogClassMapSchema.optional()
|
|
9930
|
+
classMap: DetectionCatalogClassMapSchema.optional(),
|
|
9931
|
+
/**
|
|
9932
|
+
* The model's CLIP feature-space contract (text encoder, dimension, vector
|
|
9933
|
+
* index, token window, search floor) — see `clip-model.ts`. Present ONLY on a
|
|
9934
|
+
* CLIP image encoder; its absence is what "not a CLIP model" means to the
|
|
9935
|
+
* embedding encoder and the semantic-search store (D649).
|
|
9936
|
+
*/
|
|
9937
|
+
clip: ClipModelMetaSchema.optional()
|
|
9818
9938
|
});
|
|
9819
9939
|
var ConvertTargetSchema = discriminatedUnion("format", [object({
|
|
9820
9940
|
format: literal("openvino"),
|
|
@@ -11094,12 +11214,32 @@ var AudioClassificationLabelSchema = object({
|
|
|
11094
11214
|
originalClass: string().optional(),
|
|
11095
11215
|
score: number$1()
|
|
11096
11216
|
});
|
|
11217
|
+
/**
|
|
11218
|
+
* Did the classifier RUN on this window? (D660)
|
|
11219
|
+
*
|
|
11220
|
+
* `classified` with no labels means the model heard nothing above the
|
|
11221
|
+
* camera's floor. `not-classified` means nobody listened — and until D660 the
|
|
11222
|
+
* two were the same shape (`classification` absent), so a window the global
|
|
11223
|
+
* busy gate threw away read downstream exactly like a quiet one (D393).
|
|
11224
|
+
*/
|
|
11225
|
+
var AudioClassifyOutcomeSchema = discriminatedUnion("state", [object({ state: literal("classified") }), object({
|
|
11226
|
+
state: literal("not-classified"),
|
|
11227
|
+
reason: _enum([
|
|
11228
|
+
"superseded",
|
|
11229
|
+
"error",
|
|
11230
|
+
"timeout",
|
|
11231
|
+
"disposed"
|
|
11232
|
+
])
|
|
11233
|
+
})]);
|
|
11097
11234
|
var AudioAnalysisResultSchema = object({
|
|
11098
11235
|
level: AudioLevelSchema,
|
|
11236
|
+
/** Labels at or above the camera's floor. Absent = none — read `classifyOutcome` to know whether the model ran at all. */
|
|
11099
11237
|
classification: object({
|
|
11100
11238
|
labels: array(AudioClassificationLabelSchema).readonly(),
|
|
11101
11239
|
inferenceMs: number$1()
|
|
11102
11240
|
}).optional(),
|
|
11241
|
+
/** Whether the classifier ran on this window (D660). */
|
|
11242
|
+
classifyOutcome: AudioClassifyOutcomeSchema,
|
|
11103
11243
|
timestamp: number$1()
|
|
11104
11244
|
});
|
|
11105
11245
|
var AudioAnalysisSettingsSchema = object({
|
|
@@ -14032,6 +14172,27 @@ var LinkedDeviceSchema = object({
|
|
|
14032
14172
|
features: array(string()),
|
|
14033
14173
|
producesTrackedEvents: boolean().optional()
|
|
14034
14174
|
});
|
|
14175
|
+
/**
|
|
14176
|
+
* The `linked-devices` extension slot's editable value (D648): the operator's
|
|
14177
|
+
* pick list, exactly what `_linkedDeviceIds` persists. Tree children are NOT
|
|
14178
|
+
* in it — they are always linked and are not a pick.
|
|
14179
|
+
*
|
|
14180
|
+
* `trackedDeviceIds` (D655) is the tracked-event opt-in, exactly what
|
|
14181
|
+
* `_linkedDeviceTrackedIds` persists: which linked devices materialize a
|
|
14182
|
+
* synthetic tracked event on the camera. A read always carries it AS STORED
|
|
14183
|
+
* (an absent key reads as `[]`, which is what the resolver makes of it —
|
|
14184
|
+
* NONE). On a write it is optional: absent leaves the opt-in untouched, so a
|
|
14185
|
+
* card built before D655 cannot erase it by saving the pick list. A present
|
|
14186
|
+
* list REPLACES the opt-in; each id must be a pick, a device the camera links
|
|
14187
|
+
* by structure (the row's `impliedSources`: tree children, a picked
|
|
14188
|
+
* container's child) or already stored — so what was read can always be
|
|
14189
|
+
* written back unchanged, and a NEW opt-in outside the linked set is refused.
|
|
14190
|
+
*/
|
|
14191
|
+
var LinkedDevicesSlotValueSchema = object({
|
|
14192
|
+
deviceIds: array(number$1().int().positive()),
|
|
14193
|
+
trackedDeviceIds: array(number$1().int().positive()).optional()
|
|
14194
|
+
});
|
|
14195
|
+
DeviceType.Camera;
|
|
14035
14196
|
/** One camera's resolved linked set, tagged with the camera it belongs to.
|
|
14036
14197
|
* The batch answer needs the tag; the single-device answer already has it
|
|
14037
14198
|
* from the input, which is why `getLinkedDevices` keeps the untagged shape. */
|
|
@@ -14557,16 +14718,101 @@ var EmbeddingResultSchema = object({
|
|
|
14557
14718
|
embedding: array(number$1()),
|
|
14558
14719
|
inferenceMs: number$1()
|
|
14559
14720
|
});
|
|
14721
|
+
/** The two CLIP towers the encoder runs; a crash budget is kept per tower. */
|
|
14722
|
+
var EmbeddingTowerSchema = _enum(["image", "text"]);
|
|
14723
|
+
/**
|
|
14724
|
+
* A tower in the terminal `failed` state (D649, D6): it crashed or failed to
|
|
14725
|
+
* load `crashes` times within `windowMs`, and is refused by name until an
|
|
14726
|
+
* operator `resetFailedModels` or a model change — never on a timer.
|
|
14727
|
+
*
|
|
14728
|
+
* `nodeId` is the node whose tower failed. The state lives in THAT node's
|
|
14729
|
+
* encoder process (in memory — a runner respawn clears it), and one node's
|
|
14730
|
+
* answer says nothing about another's.
|
|
14731
|
+
*/
|
|
14732
|
+
var EmbeddingFailedModelSchema = object({
|
|
14733
|
+
modelId: string(),
|
|
14734
|
+
tower: EmbeddingTowerSchema,
|
|
14735
|
+
nodeId: string(),
|
|
14736
|
+
crashes: number$1(),
|
|
14737
|
+
windowMs: number$1(),
|
|
14738
|
+
sinceMs: number$1(),
|
|
14739
|
+
lastReason: string()
|
|
14740
|
+
});
|
|
14741
|
+
/**
|
|
14742
|
+
* A model whose REQUIREMENTS can never be met on this node (D649 round 5):
|
|
14743
|
+
* an id the catalog does not know, a model URL answering 404/410, a declared
|
|
14744
|
+
* sibling (the tokenizer) that is not there. After `attempts` failed builds
|
|
14745
|
+
* it is terminally `requirements-failed`, refused by name until an operator
|
|
14746
|
+
* `resetFailedModels` or a model change — the same exits as a crashed tower.
|
|
14747
|
+
*/
|
|
14748
|
+
var EmbeddingFailedRequirementSchema = object({
|
|
14749
|
+
modelId: string(),
|
|
14750
|
+
tower: EmbeddingTowerSchema,
|
|
14751
|
+
nodeId: string(),
|
|
14752
|
+
attempts: number$1(),
|
|
14753
|
+
sinceMs: number$1(),
|
|
14754
|
+
lastReason: string()
|
|
14755
|
+
});
|
|
14560
14756
|
var EmbeddingInfoSchema = object({
|
|
14561
14757
|
modelId: string(),
|
|
14562
14758
|
embeddingDim: number$1(),
|
|
14563
|
-
ready: boolean()
|
|
14564
|
-
|
|
14759
|
+
ready: boolean(),
|
|
14760
|
+
/**
|
|
14761
|
+
* The node that answered. Absent only from an encoder older than D649's
|
|
14762
|
+
* crash budget — whose `failedModels` is then UNKNOWN (D315), never "none".
|
|
14763
|
+
*/
|
|
14764
|
+
nodeId: string().optional(),
|
|
14765
|
+
/**
|
|
14766
|
+
* Towers in `failed` on the answering node, each row naming it. `undefined`
|
|
14767
|
+
* means the node could not say (pre-budget encoder); a node that has the
|
|
14768
|
+
* budget always answers an array, empty included.
|
|
14769
|
+
*/
|
|
14770
|
+
failedModels: array(EmbeddingFailedModelSchema).optional(),
|
|
14771
|
+
/** Models terminally `requirements-failed` on the answering node; same reading as above. */
|
|
14772
|
+
failedRequirements: array(EmbeddingFailedRequirementSchema).optional()
|
|
14773
|
+
});
|
|
14774
|
+
/**
|
|
14775
|
+
* The THREE codes an encoder refusal can carry (D649, D6). Same shape as
|
|
14776
|
+
* `VECTOR_INDEX_DIM_CONFLICT`: the code rides in the MESSAGE, because an
|
|
14777
|
+
* Error's own properties do not survive the UDS/tRPC hop and its message does,
|
|
14778
|
+
* and both sides go through the helpers below — the encoder builds the
|
|
14779
|
+
* refusal, the live detail plane classifies on it to count refusals per
|
|
14780
|
+
* camera instead of logging one warning per track. The bracketed token
|
|
14781
|
+
* carries the code, the model, the tower and the node so a consumer never
|
|
14782
|
+
* parses prose.
|
|
14783
|
+
*
|
|
14784
|
+
* - `EMBEDDING_MODEL_FAILED`: the tower crashed / failed to load past the crash
|
|
14785
|
+
* budget — terminal until `resetFailedModels` or a model change.
|
|
14786
|
+
* - `EMBEDDING_REQUIREMENTS_UNAVAILABLE`: files or runtime not there right now
|
|
14787
|
+
* (a download or Python that failed, or the cooldown after one) — the next
|
|
14788
|
+
* request past the cooldown tries again.
|
|
14789
|
+
* - `EMBEDDING_REQUIREMENTS_FAILED`: the requirements can never be met (unknown
|
|
14790
|
+
* id, 404/410, missing sibling) and the bounded attempts are spent —
|
|
14791
|
+
* terminal, same exits as a crashed tower.
|
|
14792
|
+
*/
|
|
14793
|
+
var EMBEDDING_MODEL_FAILED = "embedding-model-failed";
|
|
14794
|
+
var EMBEDDING_REQUIREMENTS_UNAVAILABLE = "embedding-requirements-unavailable";
|
|
14795
|
+
var EMBEDDING_REQUIREMENTS_FAILED = "embedding-requirements-failed";
|
|
14796
|
+
_enum([
|
|
14797
|
+
EMBEDDING_MODEL_FAILED,
|
|
14798
|
+
EMBEDDING_REQUIREMENTS_UNAVAILABLE,
|
|
14799
|
+
EMBEDDING_REQUIREMENTS_FAILED
|
|
14800
|
+
]);
|
|
14801
|
+
new RegExp(`\\[(${EMBEDDING_MODEL_FAILED}|${EMBEDDING_REQUIREMENTS_UNAVAILABLE}|${EMBEDDING_REQUIREMENTS_FAILED}) model=([^\\s\\]]+) tower=(image|text) node=([^\\s\\]]+)\\]`);
|
|
14565
14802
|
method(object({
|
|
14566
14803
|
crop: _instanceof(Uint8Array),
|
|
14567
14804
|
width: number$1(),
|
|
14568
14805
|
height: number$1()
|
|
14569
|
-
}), EmbeddingResultSchema, { auth: "admin" }), method(object({
|
|
14806
|
+
}), EmbeddingResultSchema, { auth: "admin" }), method(object({
|
|
14807
|
+
text: string(),
|
|
14808
|
+
modelId: string().min(1).optional()
|
|
14809
|
+
}), EmbeddingResultSchema, { auth: "admin" }), method(_void(), EmbeddingInfoSchema, { auth: "admin" }), method(object({ modelId: string().min(1).optional() }), object({
|
|
14810
|
+
cleared: array(string()),
|
|
14811
|
+
nodeId: string()
|
|
14812
|
+
}), {
|
|
14813
|
+
kind: "mutation",
|
|
14814
|
+
auth: "admin"
|
|
14815
|
+
});
|
|
14570
14816
|
/**
|
|
14571
14817
|
* `failure-contribution` — the capability an addon reports its OWN losses
|
|
14572
14818
|
* through, per camera, with the denominator attached. It stores nothing.
|
|
@@ -18080,7 +18326,12 @@ var NcMediaPolicySchema = object({
|
|
|
18080
18326
|
* the degrade engine, which drops the video and keeps the still.
|
|
18081
18327
|
*/
|
|
18082
18328
|
clip: boolean().optional(),
|
|
18083
|
-
/**
|
|
18329
|
+
/**
|
|
18330
|
+
* Seconds of footage BEFORE / AFTER the event instant. Absent =
|
|
18331
|
+
* {@link NC_CLIP_PRE_ROLL_DEFAULT_SEC} / {@link NC_CLIP_POST_ROLL_DEFAULT_SEC}
|
|
18332
|
+
* (4 / 6), resolved by the Notification Center at dispatch — deliberately not
|
|
18333
|
+
* a Zod default, so a rule that never chose keeps following the hub's.
|
|
18334
|
+
*/
|
|
18084
18335
|
clipPreRollSec: number$1().int().min(0).max(30).optional(),
|
|
18085
18336
|
clipPostRollSec: number$1().int().min(0).max(30).optional(),
|
|
18086
18337
|
/**
|
|
@@ -19458,6 +19709,130 @@ var OauthIntegrationDescriptorSchema = object({
|
|
|
19458
19709
|
});
|
|
19459
19710
|
method(_void(), OauthIntegrationDescriptorSchema, { auth: "admin" });
|
|
19460
19711
|
/**
|
|
19712
|
+
* A model choice has a SCOPE, and a scope change has a workflow.
|
|
19713
|
+
*
|
|
19714
|
+
* ## The two scopes
|
|
19715
|
+
*
|
|
19716
|
+
* Almost every pipeline step's model is a **node** question: which build runs
|
|
19717
|
+
* fastest on THIS accelerator. Two nodes may legitimately answer differently —
|
|
19718
|
+
* a Coral runs the tflite SSD, a Mac runs the coreml YOLO — because the answers
|
|
19719
|
+
* are compared against nothing. They produce boxes, and a box is a box.
|
|
19720
|
+
*
|
|
19721
|
+
* Two steps are not like that. `face-embedding` and `clip-embedding` produce
|
|
19722
|
+
* **vectors that land in ONE shared index** (`identity_samples`,
|
|
19723
|
+
* `vec_object_clip`) and are ranked against each other by cosine similarity.
|
|
19724
|
+
* Cosine similarity between two encoders is not a weak signal, it is a
|
|
19725
|
+
* meaningless number — and nothing inside a vector can tell you it happened.
|
|
19726
|
+
* So for those two steps the model is a **cluster** question with exactly one
|
|
19727
|
+
* answer, stored in exactly one row.
|
|
19728
|
+
*
|
|
19729
|
+
* That is the same argument [D52](../../../../docs/decisions/adr-0052.md) makes
|
|
19730
|
+
* for the crop convention (`detail-crop.ts`), one level up: the crop decides
|
|
19731
|
+
* WHAT pixels the encoder sees, this decides WHICH encoder sees them. Both are
|
|
19732
|
+
* cluster-wide for the same reason and neither may become per-node.
|
|
19733
|
+
*
|
|
19734
|
+
* ## Why the registry lives here and not in the step catalog
|
|
19735
|
+
*
|
|
19736
|
+
* The scope itself is declared on the step, in
|
|
19737
|
+
* `detection-pipeline/registry/step-definitions.ts` (`StepDefinition.modelScope`)
|
|
19738
|
+
* — that is where a new step declares what kind of choice its model is. But the
|
|
19739
|
+
* catalog lives inside `addon-pipeline`, and three packages that must NOT
|
|
19740
|
+
* import an addon need to know the set: the orchestrator (which renders and
|
|
19741
|
+
* stores the row), post-analysis (which pins the row for a re-embed pass) and
|
|
19742
|
+
* admin-ui (which mirrors it). So the set is mirrored here, and
|
|
19743
|
+
* `scripts/check-cluster-model-scope.ts` fails the build when the two disagree.
|
|
19744
|
+
* A hand-copied key that stops matching is exactly how a setting silently stops
|
|
19745
|
+
* arriving while both sides still look correct.
|
|
19746
|
+
*
|
|
19747
|
+
* ## The defaults ARE today's behaviour
|
|
19748
|
+
*
|
|
19749
|
+
* {@link DEFAULT_CLUSTER_STEP_MODELS} reproduces the catalog `defaultModelId`
|
|
19750
|
+
* of both steps. Declaring the scope therefore changes nothing on the day it
|
|
19751
|
+
* ships: the cluster row starts out saying what every node was already doing.
|
|
19752
|
+
* Changing it is legitimate — that is what the knob is for — but it invalidates
|
|
19753
|
+
* the stored vectors of that surface, and must be followed by a re-embed pass
|
|
19754
|
+
* (`face-reembed-pass.ts`, `embedding-rebuild.ts`).
|
|
19755
|
+
*/
|
|
19756
|
+
/**
|
|
19757
|
+
* Why the orchestrator cannot say which model the operator chose for a
|
|
19758
|
+
* cluster-scoped step (D651).
|
|
19759
|
+
*/
|
|
19760
|
+
var CLUSTER_MODEL_CHOICE_UNREADABLE_REASONS = [
|
|
19761
|
+
"owner-not-ready",
|
|
19762
|
+
"store-read-failed",
|
|
19763
|
+
"three-way-read-unavailable",
|
|
19764
|
+
"invalid-stored",
|
|
19765
|
+
"not-cluster-scoped"
|
|
19766
|
+
];
|
|
19767
|
+
Object.freeze(Object.fromEntries([{
|
|
19768
|
+
stepId: "face-embedding",
|
|
19769
|
+
label: "Face recognition model",
|
|
19770
|
+
defaultModelId: "auraface-r100",
|
|
19771
|
+
indexName: "the enrolled face gallery",
|
|
19772
|
+
options: [
|
|
19773
|
+
{
|
|
19774
|
+
id: "auraface-r100",
|
|
19775
|
+
label: "AuraFace R100"
|
|
19776
|
+
},
|
|
19777
|
+
{
|
|
19778
|
+
id: "arcface-r100",
|
|
19779
|
+
label: "ArcFace (ResNet34)"
|
|
19780
|
+
},
|
|
19781
|
+
{
|
|
19782
|
+
id: "inception-resnet-v1",
|
|
19783
|
+
label: "Inception ResNet V1"
|
|
19784
|
+
}
|
|
19785
|
+
]
|
|
19786
|
+
}, {
|
|
19787
|
+
stepId: "clip-embedding",
|
|
19788
|
+
label: "Semantic search model",
|
|
19789
|
+
defaultModelId: "mobileclip-s1",
|
|
19790
|
+
indexName: "the object semantic-search index",
|
|
19791
|
+
options: [
|
|
19792
|
+
{
|
|
19793
|
+
id: "mobileclip-s1",
|
|
19794
|
+
label: "MobileCLIP S1"
|
|
19795
|
+
},
|
|
19796
|
+
{
|
|
19797
|
+
id: "mobileclip-s2",
|
|
19798
|
+
label: "MobileCLIP S2"
|
|
19799
|
+
},
|
|
19800
|
+
{
|
|
19801
|
+
id: "siglip2-b16-224",
|
|
19802
|
+
label: "SigLIP2 B/16 (Apache-2.0)"
|
|
19803
|
+
}
|
|
19804
|
+
]
|
|
19805
|
+
}].map((s) => [s.stepId, s.defaultModelId])));
|
|
19806
|
+
var CLUSTER_STEP_SETTING_FIELDS = [{
|
|
19807
|
+
stepId: "face-embedding",
|
|
19808
|
+
key: "minLandmarkFaceSize",
|
|
19809
|
+
label: "Min face size for recognition (detection px)",
|
|
19810
|
+
description: "Refuse to embed a face smaller than this IN THE DETECTION FRAME. Applies to every node — the enrolled gallery is one index, and two admission floors would fill it from two policies. 0 disables the gate.",
|
|
19811
|
+
type: "slider",
|
|
19812
|
+
min: 0,
|
|
19813
|
+
max: 64,
|
|
19814
|
+
step: 2,
|
|
19815
|
+
default: 24
|
|
19816
|
+
}];
|
|
19817
|
+
function clusterStepSettingKey(stepId, fieldKey) {
|
|
19818
|
+
return `clusterStepSetting:${stepId}:${fieldKey}`;
|
|
19819
|
+
}
|
|
19820
|
+
var ClusterSettingNumberSchema = number$1().finite();
|
|
19821
|
+
function readClusterStepSettings(config) {
|
|
19822
|
+
const out = {};
|
|
19823
|
+
for (const field of CLUSTER_STEP_SETTING_FIELDS) {
|
|
19824
|
+
const parsed = ClusterSettingNumberSchema.safeParse(config[clusterStepSettingKey(field.stepId, field.key)]);
|
|
19825
|
+
const value = parsed.success ? parsed.data : field.default;
|
|
19826
|
+
const existing = out[field.stepId] ?? {};
|
|
19827
|
+
out[field.stepId] = {
|
|
19828
|
+
...existing,
|
|
19829
|
+
[field.key]: value
|
|
19830
|
+
};
|
|
19831
|
+
}
|
|
19832
|
+
return out;
|
|
19833
|
+
}
|
|
19834
|
+
readClusterStepSettings({});
|
|
19835
|
+
/**
|
|
19461
19836
|
* pipeline-analytics — device-scoped wrapper cap. Refines raw
|
|
19462
19837
|
* per-frame detections emitted by the pipeline runner into tracked
|
|
19463
19838
|
* objects, per-kind event collections (motion / object / audio), and
|
|
@@ -20255,6 +20630,13 @@ var AudioEventSchema = object({
|
|
|
20255
20630
|
originalClass: string().optional(),
|
|
20256
20631
|
score: number$1()
|
|
20257
20632
|
}).optional(),
|
|
20633
|
+
/**
|
|
20634
|
+
* Whether the classifier RAN on the window behind this row (D660). Absent
|
|
20635
|
+
* on rows written before D660 — unknown, NOT classified: until then a
|
|
20636
|
+
* window the analyzer's busy gate threw away was stored exactly like one
|
|
20637
|
+
* that heard nothing above the floor.
|
|
20638
|
+
*/
|
|
20639
|
+
classifyOutcome: AudioClassifyOutcomeSchema.optional(),
|
|
20258
20640
|
/** Populated by B5 (recording playback URL for this event). */
|
|
20259
20641
|
mediaUrl: string().optional()
|
|
20260
20642
|
});
|
|
@@ -20273,7 +20655,8 @@ var MediaFileKindEnum = _enum([
|
|
|
20273
20655
|
"thumbnailSmall",
|
|
20274
20656
|
"confirmationCrop",
|
|
20275
20657
|
"debugCrop",
|
|
20276
|
-
"sceneFrame"
|
|
20658
|
+
"sceneFrame",
|
|
20659
|
+
"lastSceneFrame"
|
|
20277
20660
|
]);
|
|
20278
20661
|
/**
|
|
20279
20662
|
* One media row ON THE WIRE: what it is, how big it is, and WHERE ITS BYTES
|
|
@@ -20825,7 +21208,23 @@ var SearchObjectEventsInput = object({
|
|
|
20825
21208
|
until: number$1().optional(),
|
|
20826
21209
|
classFilter: string().optional(),
|
|
20827
21210
|
limit: number$1().default(50),
|
|
20828
|
-
|
|
21211
|
+
/**
|
|
21212
|
+
* An ABSOLUTE cosine floor. Optional since D649: a floor is a property of the
|
|
21213
|
+
* model (0.2 kept 96% of matched pairs on MobileCLIP S1 and 2.7% on SigLIP2),
|
|
21214
|
+
* so an absent one resolves to the searched model's own `searchMinScore`
|
|
21215
|
+
* scaled by `strictness`. A number sent here is honoured verbatim.
|
|
21216
|
+
*/
|
|
21217
|
+
minScore: number$1().min(0).max(1).optional(),
|
|
21218
|
+
/** Model-relative floor — see `resolveClipSearchMinScore`. Default `loose`. */
|
|
21219
|
+
strictness: ClipSearchStrictnessSchema.optional(),
|
|
21220
|
+
/**
|
|
21221
|
+
* Search THIS CLIP model's index instead of the cluster row's. Every index a
|
|
21222
|
+
* model ever wrote stays searchable until it is wiped (the MobileCLIP index
|
|
21223
|
+
* through a SigLIP2 cutover and its rollback window). An id with no CLIP
|
|
21224
|
+
* metadata is refused; an id other than the cluster row's is ADMIN-only
|
|
21225
|
+
* (`model-override-requires-admin`).
|
|
21226
|
+
*/
|
|
21227
|
+
modelId: string().min(1).optional()
|
|
20829
21228
|
});
|
|
20830
21229
|
var TrackCascadeCountsSchema = object({
|
|
20831
21230
|
/** Persisted track roots deleted (authoritative). */
|
|
@@ -20960,7 +21359,41 @@ var RebuildObjectEmbeddingsInput = object({
|
|
|
20960
21359
|
* comparable, so wiping and rebuilding is the only way to be sure every vector
|
|
20961
21360
|
* means the same thing.
|
|
20962
21361
|
*/
|
|
20963
|
-
var WipeObjectEmbeddingsResultSchema = object({
|
|
21362
|
+
var WipeObjectEmbeddingsResultSchema = object({
|
|
21363
|
+
deleted: number$1(),
|
|
21364
|
+
/**
|
|
21365
|
+
* CLIP indexes that could NOT be emptied (unreachable, or refused at their
|
|
21366
|
+
* dimension) — not a clean slate. Additive and optional (D649).
|
|
21367
|
+
*/
|
|
21368
|
+
failedIndexes: array(string()).optional()
|
|
21369
|
+
});
|
|
21370
|
+
/**
|
|
21371
|
+
* Why a rebuild did not start, BY NAME — ONE vocabulary for both gates in front
|
|
21372
|
+
* of a pass (D649 over D651). A bare `started: false` read the same for "the
|
|
21373
|
+
* stores are booting" and "the cluster row names a model with no CLIP
|
|
21374
|
+
* metadata", which need different fixes.
|
|
21375
|
+
* - `stores-unavailable` — the analytics stores or the API are not up yet.
|
|
21376
|
+
* - the owner's confirmation of the cluster model (D651, `ClusterPinConfirmer`):
|
|
21377
|
+
* a pass that rewrites an index needs two agreeing reads of the OWNER's
|
|
21378
|
+
* answer (`pipelineOrchestrator.getClusterModelChoice`) — a pass that cannot
|
|
21379
|
+
* name its model does not run (D54):
|
|
21380
|
+
* - the owner's own `unreadable` reasons (`owner-not-ready`,
|
|
21381
|
+
* `store-read-failed`, `three-way-read-unavailable`, `invalid-stored`,
|
|
21382
|
+
* `not-cluster-scoped`);
|
|
21383
|
+
* - `method-unavailable` — the orchestrator predates the method;
|
|
21384
|
+
* - `read-failed` — the call failed or answered something unparseable;
|
|
21385
|
+
* - `reads-disagree` — the two reads named different choices.
|
|
21386
|
+
* - `not-a-clip-model` — the CONFIRMED id has no CLIP metadata, so there is no
|
|
21387
|
+
* index to fill and no dimension to check against (D649).
|
|
21388
|
+
*/
|
|
21389
|
+
var RebuildObjectEmbeddingsRefusalSchema = _enum([
|
|
21390
|
+
"stores-unavailable",
|
|
21391
|
+
...CLUSTER_MODEL_CHOICE_UNREADABLE_REASONS,
|
|
21392
|
+
"method-unavailable",
|
|
21393
|
+
"read-failed",
|
|
21394
|
+
"reads-disagree",
|
|
21395
|
+
"not-a-clip-model"
|
|
21396
|
+
]);
|
|
20964
21397
|
/**
|
|
20965
21398
|
* Acknowledgement that a rebuild STARTED.
|
|
20966
21399
|
*
|
|
@@ -20973,7 +21406,12 @@ var WipeObjectEmbeddingsResultSchema = object({ deleted: number$1() });
|
|
|
20973
21406
|
var RebuildObjectEmbeddingsResultSchema = object({
|
|
20974
21407
|
started: boolean(),
|
|
20975
21408
|
/** True when a pass was already running; the new request is ignored. */
|
|
20976
|
-
alreadyRunning: boolean()
|
|
21409
|
+
alreadyRunning: boolean(),
|
|
21410
|
+
/** Present when the pass refused to start — see `RebuildObjectEmbeddingsRefusalSchema`. */
|
|
21411
|
+
refusal: RebuildObjectEmbeddingsRefusalSchema.optional(),
|
|
21412
|
+
/** The CLIP model the pass pinned, and the index it fills (when it started). */
|
|
21413
|
+
modelId: string().optional(),
|
|
21414
|
+
index: string().optional()
|
|
20977
21415
|
});
|
|
20978
21416
|
var RebuildStatusSchema = object({
|
|
20979
21417
|
running: boolean(),
|
|
@@ -21007,7 +21445,11 @@ var RebuildStatusSchema = object({
|
|
|
21007
21445
|
startedAtMs: number$1().nullable(),
|
|
21008
21446
|
finishedAtMs: number$1().nullable(),
|
|
21009
21447
|
/** Present when the pass ended by throwing. */
|
|
21010
|
-
error: string().nullable()
|
|
21448
|
+
error: string().nullable(),
|
|
21449
|
+
/** The CLIP model the current / last pass pinned (D54), `null` before any. */
|
|
21450
|
+
modelId: string().nullable(),
|
|
21451
|
+
/** The index that pass fills — `ClipModelMeta.vectorIndex` of `modelId` (D649). */
|
|
21452
|
+
index: string().nullable()
|
|
21011
21453
|
});
|
|
21012
21454
|
/**
|
|
21013
21455
|
* Acknowledgement that a debug-media reclaim STARTED.
|
|
@@ -21328,7 +21770,7 @@ DeviceType.Camera, method(object({ deviceId: number$1() }), array(TrackSchema).r
|
|
|
21328
21770
|
deviceId: number$1(),
|
|
21329
21771
|
ownerKind: MediaPresenceOwnerKindSchema,
|
|
21330
21772
|
ownerIds: array(string()).max(5e3)
|
|
21331
|
-
}), array(string()).readonly()), method(SearchObjectEventsInput, array(ScoredObjectEventSchema).readonly()), method(object({}), WipeObjectEmbeddingsResultSchema, {
|
|
21773
|
+
}), array(string()).readonly()), method(SearchObjectEventsInput, array(ScoredObjectEventSchema).readonly(), { caller: "required" }), method(object({}), WipeObjectEmbeddingsResultSchema, {
|
|
21332
21774
|
kind: "mutation",
|
|
21333
21775
|
auth: "admin"
|
|
21334
21776
|
}), method(RebuildObjectEmbeddingsInput, RebuildObjectEmbeddingsResultSchema, {
|
|
@@ -21786,7 +22228,14 @@ method(_void(), array(PipelineEngineChoiceSchema)), method(_void(), PipelineEngi
|
|
|
21786
22228
|
height: number$1()
|
|
21787
22229
|
}), { kind: "mutation" }), method(object({
|
|
21788
22230
|
stepId: string(),
|
|
21789
|
-
frameId: number$1().int()
|
|
22231
|
+
frameId: number$1().int(),
|
|
22232
|
+
/**
|
|
22233
|
+
* The model to time — REQUIRED (D658). Without it the pool answered the
|
|
22234
|
+
* step's ACTIVE variant (the first loaded after boot), so a benchmark
|
|
22235
|
+
* of model B silently timed model A. Callers pass the `rootModelId`
|
|
22236
|
+
* their warmup `runPipeline` reported: the model that actually ran.
|
|
22237
|
+
*/
|
|
22238
|
+
modelId: string().min(1)
|
|
21790
22239
|
}), record(string(), unknown()), { kind: "mutation" }), method(object({ frameId: number$1().int() }), _void(), { kind: "mutation" }), method(object({ deviceKey: string().optional() }), EffectiveTuningSchema), method(_void(), array(object({
|
|
21791
22240
|
engineKey: string(),
|
|
21792
22241
|
engine: PipelineEngineChoiceSchema,
|
|
@@ -22363,6 +22812,17 @@ var RunnerFrameSourceSchema = discriminatedUnion("kind", [object({ kind: literal
|
|
|
22363
22812
|
hubHostnameOverride: string().optional()
|
|
22364
22813
|
})]).describe("Per-camera frame-source mode for the runner (P2c)");
|
|
22365
22814
|
/**
|
|
22815
|
+
* What ONE step runs with on ONE roster device for THIS camera (D650): the
|
|
22816
|
+
* device's per-(node,device) base with the camera's override for that device
|
|
22817
|
+
* on top — the same `override ?? base` merge the orchestrator applies to the
|
|
22818
|
+
* elected device (`applyDeviceProvisioning`). Absent `modelId` ⇒ the executor
|
|
22819
|
+
* resolves the device format's default, exactly as on the elected device.
|
|
22820
|
+
*/
|
|
22821
|
+
var RunnerJumpStepProvisioningSchema = object({
|
|
22822
|
+
modelId: string().optional(),
|
|
22823
|
+
settings: record(string(), unknown()).optional()
|
|
22824
|
+
});
|
|
22825
|
+
/**
|
|
22366
22826
|
* One ENABLED inference device on the runner's node, as the step-tree
|
|
22367
22827
|
* device-jump resolver sees it (phase 1). The orchestrator populates this
|
|
22368
22828
|
* roster on the attach payload whenever the camera is elected onto a specific
|
|
@@ -22374,7 +22834,16 @@ var RunnerFrameSourceSchema = discriminatedUnion("kind", [object({ kind: literal
|
|
|
22374
22834
|
var RunnerInferenceDeviceSchema = object({
|
|
22375
22835
|
deviceKey: string(),
|
|
22376
22836
|
weight: number$1().positive().default(1),
|
|
22377
|
-
maxSessions: number$1().int().positive().nullable().default(null)
|
|
22837
|
+
maxSessions: number$1().int().positive().nullable().default(null),
|
|
22838
|
+
/**
|
|
22839
|
+
* Per-step provisioning for this camera on THIS device (D650), keyed by step
|
|
22840
|
+
* id. A step the runner jumps here runs with these fields, never with the
|
|
22841
|
+
* elected device's: `modelId` / `settings` are REPLACED on the jumped subtree
|
|
22842
|
+
* (a step absent from the map runs with neither — the target format default).
|
|
22843
|
+
* Absent field ⇒ an orchestrator that predates D650: the jumped step keeps
|
|
22844
|
+
* the elected device's provisioning, as before.
|
|
22845
|
+
*/
|
|
22846
|
+
steps: record(string(), RunnerJumpStepProvisioningSchema).optional()
|
|
22378
22847
|
});
|
|
22379
22848
|
/**
|
|
22380
22849
|
* Camera assignment payload sent by `addon-pipeline-orchestrator` to a
|
|
@@ -23249,6 +23718,28 @@ var NodeInferenceDeviceSchema = object({
|
|
|
23249
23718
|
*/
|
|
23250
23719
|
exclusion: InferenceDeviceExclusionReasonSchema.nullable()
|
|
23251
23720
|
});
|
|
23721
|
+
/**
|
|
23722
|
+
* The operator's model choice for one cluster-scoped step, answered by the
|
|
23723
|
+
* addon that OWNS the `clusterModel:*` settings (D651). Three answers, never
|
|
23724
|
+
* folded: a written choice, a key nobody wrote (the cluster runs the default
|
|
23725
|
+
* BY ABSENCE), or no answer. A caller that rewrites an index acts only on the
|
|
23726
|
+
* first two, read twice and agreeing.
|
|
23727
|
+
*/
|
|
23728
|
+
var ClusterModelChoiceSchema = discriminatedUnion("kind", [
|
|
23729
|
+
object({
|
|
23730
|
+
kind: literal("stored"),
|
|
23731
|
+
modelId: string()
|
|
23732
|
+
}),
|
|
23733
|
+
object({
|
|
23734
|
+
kind: literal("absent"),
|
|
23735
|
+
defaultModelId: string()
|
|
23736
|
+
}),
|
|
23737
|
+
object({
|
|
23738
|
+
kind: literal("unreadable"),
|
|
23739
|
+
reason: _enum(CLUSTER_MODEL_CHOICE_UNREADABLE_REASONS),
|
|
23740
|
+
error: string().optional()
|
|
23741
|
+
})
|
|
23742
|
+
]);
|
|
23252
23743
|
var NodeInferenceDevicesSchema = object({
|
|
23253
23744
|
nodeId: string(),
|
|
23254
23745
|
/** False when the node's platform-probe was unreachable (no live device set). */
|
|
@@ -23276,10 +23767,17 @@ method(StorageMigrationLeaseInputSchema, object({ paused: literal(true) }), {
|
|
|
23276
23767
|
}), object({ success: literal(true) }), {
|
|
23277
23768
|
kind: "mutation",
|
|
23278
23769
|
auth: "admin"
|
|
23279
|
-
}), method(object({ deviceId: number$1() }), object({ deviceKey: string().nullable() })), method(_void(), object({
|
|
23770
|
+
}), method(object({ deviceId: number$1() }), object({ deviceKey: string().nullable() })), method(_void(), object({
|
|
23771
|
+
migrated: number$1(),
|
|
23772
|
+
skipped: array(object({
|
|
23773
|
+
deviceId: number$1(),
|
|
23774
|
+
targetNodeId: string(),
|
|
23775
|
+
reason: string()
|
|
23776
|
+
})).default([])
|
|
23777
|
+
}), {
|
|
23280
23778
|
kind: "mutation",
|
|
23281
23779
|
auth: "admin"
|
|
23282
|
-
}), method(_void(), array(PipelineAssignmentSchema).readonly()), method(object({ deviceId: number$1() }), PipelineAssignmentSchema.nullable()), method(_void(), array(AgentLoadSummarySchema).readonly()), method(_void(), GlobalMetricsSchema), method(object({ deviceId: number$1() }), CameraMetricsSchema.nullable()), method(object({ nodeId: string() }), CapabilityBindingsSchema), method(object({
|
|
23780
|
+
}), method(_void(), array(PipelineAssignmentSchema).readonly()), method(object({ deviceId: number$1() }), PipelineAssignmentSchema.nullable()), method(_void(), array(AgentLoadSummarySchema).readonly()), method(object({ stepId: string() }), ClusterModelChoiceSchema), method(_void(), GlobalMetricsSchema), method(object({ deviceId: number$1() }), CameraMetricsSchema.nullable()), method(object({ nodeId: string() }), CapabilityBindingsSchema), method(object({
|
|
23283
23781
|
nodeId: string(),
|
|
23284
23782
|
capName: string(),
|
|
23285
23783
|
addonId: string()
|
|
@@ -25579,6 +26077,177 @@ DeviceType.Camera, method(object({
|
|
|
25579
26077
|
auth: "protected"
|
|
25580
26078
|
});
|
|
25581
26079
|
/**
|
|
26080
|
+
* LA tabella "quale booleano di questo tipo di device conta come ALTO", e il
|
|
26081
|
+
* valutatore puro del suo FRONTE.
|
|
26082
|
+
*
|
|
26083
|
+
* Viveva dentro il builtin virtual-doorbell
|
|
26084
|
+
* (`@camstack/system` — `builtins/doorbell/trigger-engine.ts`) e i suoi
|
|
26085
|
+
* predicati erano privati al modulo. Il recorder ne ha bisogno per il trigger
|
|
26086
|
+
* `RecordingTriggers.sensorDeviceIds`: copiarla avrebbe creato la SECONDA
|
|
26087
|
+
* tabella, che diverge alla prima cap aggiunta e il cui sintomo — "il sensore
|
|
26088
|
+
* fa suonare il campanello ma non registra" — è esattamente D62. Quindi si
|
|
26089
|
+
* SPOSTA qui e il doorbell la ri-esporta.
|
|
26090
|
+
*
|
|
26091
|
+
* ⚠ NON è `DEVICE_STATE_READERS` (`catalogs/device-state-vocabulary.ts`), e le
|
|
26092
|
+
* due non vanno unificate: quella risponde a "qual è la PAROLA di stato per una
|
|
26093
|
+
* regola" (e include `presence`, `cover`, `alarm-panel`), questa a "qual è il
|
|
26094
|
+
* booleano il cui FRONTE conta". Vocabolari deliberatamente diversi.
|
|
26095
|
+
*/
|
|
26096
|
+
/**
|
|
26097
|
+
* Known binary / switch source caps → the boolean slice field whose
|
|
26098
|
+
* false→true rise counts as ACTIVE. Every entry is "fire on active".
|
|
26099
|
+
* Sensors whose "active" reading is not a plain boolean (presence's string
|
|
26100
|
+
* state, connectivity's connected flag) are deliberately excluded — a
|
|
26101
|
+
* reconnect is not a doorbell press, and it is not a recording either.
|
|
26102
|
+
*/
|
|
26103
|
+
var SOURCE_CAP_ACTIVE_FIELD = {
|
|
26104
|
+
contact: "entryOpen",
|
|
26105
|
+
binary: "on",
|
|
26106
|
+
switch: "on",
|
|
26107
|
+
motion: "detected",
|
|
26108
|
+
flood: "flooded",
|
|
26109
|
+
gas: "detected",
|
|
26110
|
+
smoke: "detected",
|
|
26111
|
+
"carbon-monoxide": "detected",
|
|
26112
|
+
vibration: "detected",
|
|
26113
|
+
tamper: "tampered"
|
|
26114
|
+
};
|
|
26115
|
+
object({
|
|
26116
|
+
/** Ms epoch of the last press. null = never observed since this provider started. */
|
|
26117
|
+
lastPressedAt: number$1().nullable(),
|
|
26118
|
+
/** Counter since provider start. Resets on reboot. Useful for metrics/debug. */
|
|
26119
|
+
pressCountSinceStart: number$1()
|
|
26120
|
+
});
|
|
26121
|
+
object({
|
|
26122
|
+
deviceId: number$1(),
|
|
26123
|
+
timestamp: number$1()
|
|
26124
|
+
});
|
|
26125
|
+
/**
|
|
26126
|
+
* The `doorbell-source` extension slot's editable value (D648): the camera's
|
|
26127
|
+
* virtual-doorbell trigger devices, exactly what the wrapper's
|
|
26128
|
+
* `doorbellSources` persists (as `{ deviceId }` records).
|
|
26129
|
+
*/
|
|
26130
|
+
var DoorbellSourceSlotValueSchema = object({ deviceIds: array(number$1().int().positive()) });
|
|
26131
|
+
DeviceType.Camera;
|
|
26132
|
+
DeviceType.Button, DeviceType.Camera;
|
|
26133
|
+
var ExtensionSlotIdSchema = _enum(["doorbell-source", "linked-devices"]);
|
|
26134
|
+
DeviceType.Camera, DeviceType.Camera;
|
|
26135
|
+
/** A slot's editable value, discriminated on `slot`. */
|
|
26136
|
+
var ExtensionSlotValueSchema = discriminatedUnion("slot", [DoorbellSourceSlotValueSchema.extend({ slot: literal("doorbell-source") }), LinkedDevicesSlotValueSchema.extend({ slot: literal("linked-devices") })]);
|
|
26137
|
+
DeviceType.Camera;
|
|
26138
|
+
var ExtensionSourceAvailabilitySchema = discriminatedUnion("state", [object({ state: literal("ok") }), object({
|
|
26139
|
+
state: literal("unreachable"),
|
|
26140
|
+
reason: string()
|
|
26141
|
+
})]);
|
|
26142
|
+
/** One provider of slots — the D554 source-listing row. */
|
|
26143
|
+
var ExtensionSourceSchema = object({
|
|
26144
|
+
/** The routing prefix of every `slotRef` this provider serves. */
|
|
26145
|
+
source: string(),
|
|
26146
|
+
label: string(),
|
|
26147
|
+
/** Stamped by the dispatcher from the registry (D557). */
|
|
26148
|
+
addonId: string().optional(),
|
|
26149
|
+
availability: ExtensionSourceAvailabilitySchema
|
|
26150
|
+
});
|
|
26151
|
+
/**
|
|
26152
|
+
* How one picked source stands. `missing` — no such device (deleted, or an id
|
|
26153
|
+
* that never existed); `foreign` — a device the slot's owner cannot read from
|
|
26154
|
+
* (slice 2's cross-owner graft source); `unavailable` — it exists but is not a
|
|
26155
|
+
* valid source now (a container, which is never a pick). A source in any of
|
|
26156
|
+
* these states is SHOWN, never silently dropped or re-pointed.
|
|
26157
|
+
*/
|
|
26158
|
+
var ExtensionSourceHealthSchema = _enum([
|
|
26159
|
+
"ok",
|
|
26160
|
+
"missing",
|
|
26161
|
+
"foreign",
|
|
26162
|
+
"unavailable"
|
|
26163
|
+
]);
|
|
26164
|
+
var ExtensionSlotSourceSchema = object({
|
|
26165
|
+
deviceId: number$1().int(),
|
|
26166
|
+
/** The device's name, or null when it could not be resolved (`missing`). */
|
|
26167
|
+
name: string().nullable(),
|
|
26168
|
+
health: ExtensionSourceHealthSchema,
|
|
26169
|
+
detail: string().optional()
|
|
26170
|
+
});
|
|
26171
|
+
/**
|
|
26172
|
+
* A DIFFERENT authority that gates whether the slot's sources do anything —
|
|
26173
|
+
* reported read-only, named, never written through this contract (D62). The
|
|
26174
|
+
* virtual doorbell's sources ring only while the wrapper is bound to the
|
|
26175
|
+
* camera, and that binding belongs to `deviceManager.setWrapperActive`.
|
|
26176
|
+
* `unknown` means the gate could not be read; it is not "inactive" (D315).
|
|
26177
|
+
*/
|
|
26178
|
+
var ExtensionSlotActivationSchema = object({
|
|
26179
|
+
state: _enum([
|
|
26180
|
+
"active",
|
|
26181
|
+
"inactive",
|
|
26182
|
+
"unknown"
|
|
26183
|
+
]),
|
|
26184
|
+
authority: string(),
|
|
26185
|
+
detail: string().optional()
|
|
26186
|
+
});
|
|
26187
|
+
var ExtensionSlotRowSchema = discriminatedUnion("state", [object({
|
|
26188
|
+
state: literal("ok"),
|
|
26189
|
+
/** `<source>:<slotId>` — the routing key for `listCandidates` / `setSlot`. */
|
|
26190
|
+
slotRef: string(),
|
|
26191
|
+
slot: ExtensionSlotIdSchema,
|
|
26192
|
+
/** Names the store written (D62), e.g. `virtual-doorbell:doorbellSources`. */
|
|
26193
|
+
authority: string(),
|
|
26194
|
+
/** graft: its switch. association: null — removing every source is "off". */
|
|
26195
|
+
enabled: boolean().nullable(),
|
|
26196
|
+
/** graft: the cap registered on the host. association: null. */
|
|
26197
|
+
projects: string().nullable(),
|
|
26198
|
+
activation: ExtensionSlotActivationSchema.nullable(),
|
|
26199
|
+
value: ExtensionSlotValueSchema,
|
|
26200
|
+
sources: array(ExtensionSlotSourceSchema),
|
|
26201
|
+
/**
|
|
26202
|
+
* Devices the owner links to the host ON ITS OWN, by structure, and that
|
|
26203
|
+
* are therefore not in `value` (D655): a camera's device-tree children, and
|
|
26204
|
+
* the child a picked container stands for (D356 — a container is never a
|
|
26205
|
+
* pick, its children are). Read-only; the editor shows them and may offer
|
|
26206
|
+
* per-device options on them (the linked-devices tracked-event opt-in).
|
|
26207
|
+
* Absent when the owner links nothing beyond the picks, and from an owner
|
|
26208
|
+
* older than D655.
|
|
26209
|
+
*/
|
|
26210
|
+
impliedSources: array(ExtensionSlotSourceSchema).optional()
|
|
26211
|
+
}), object({
|
|
26212
|
+
state: literal("unreachable"),
|
|
26213
|
+
addonId: string(),
|
|
26214
|
+
reason: string()
|
|
26215
|
+
})]);
|
|
26216
|
+
var ExtensionCandidatesSchema = object({ candidates: array(object({
|
|
26217
|
+
deviceId: number$1().int(),
|
|
26218
|
+
name: string(),
|
|
26219
|
+
type: string(),
|
|
26220
|
+
location: string().nullable(),
|
|
26221
|
+
/** The container a child belongs to — "Spotlight 2" alone does not say which. */
|
|
26222
|
+
parentName: string().nullable(),
|
|
26223
|
+
/** Pre-marked by the owner's suggestion rule. NEVER saved on its own (D356). */
|
|
26224
|
+
suggested: boolean(),
|
|
26225
|
+
/** Why it is suggested ("same location"), null when it is not. */
|
|
26226
|
+
reason: string().nullable()
|
|
26227
|
+
})) });
|
|
26228
|
+
/**
|
|
26229
|
+
* What a write did. `none` — applied in place. `host` / `parent` — the owner
|
|
26230
|
+
* reloaded the host (or, for an accessory child, its parent) because the
|
|
26231
|
+
* write changed what the host REGISTERS (a graft switched on or off, slice 2).
|
|
26232
|
+
*/
|
|
26233
|
+
var ExtensionSetResultSchema = object({
|
|
26234
|
+
applied: literal(true),
|
|
26235
|
+
reload: _enum([
|
|
26236
|
+
"none",
|
|
26237
|
+
"host",
|
|
26238
|
+
"parent"
|
|
26239
|
+
])
|
|
26240
|
+
});
|
|
26241
|
+
var ExtensionSlotRefInputSchema = object({
|
|
26242
|
+
deviceId: number$1().int(),
|
|
26243
|
+
slotRef: string().min(1)
|
|
26244
|
+
});
|
|
26245
|
+
var ExtensionSetSlotInputSchema = ExtensionSlotRefInputSchema.extend({ value: ExtensionSlotValueSchema });
|
|
26246
|
+
method(object({ deviceId: number$1().int() }), array(ExtensionSourceSchema)), method(object({ deviceId: number$1().int() }), array(ExtensionSlotRowSchema)), method(ExtensionSlotRefInputSchema, ExtensionCandidatesSchema), method(ExtensionSetSlotInputSchema, ExtensionSetResultSchema, {
|
|
26247
|
+
kind: "mutation",
|
|
26248
|
+
auth: "admin"
|
|
26249
|
+
});
|
|
26250
|
+
/**
|
|
25582
26251
|
* Optional client-side hints sent at session creation to help the provider
|
|
25583
26252
|
* pick the best native source. All fields optional — a viewer that knows
|
|
25584
26253
|
* nothing still gets a sane default. (Relocated from the retired `webrtc`
|
|
@@ -27367,17 +28036,6 @@ object({
|
|
|
27367
28036
|
deviceId: number$1(),
|
|
27368
28037
|
status: DeviceStatusSchema
|
|
27369
28038
|
});
|
|
27370
|
-
object({
|
|
27371
|
-
/** Ms epoch of the last press. null = never observed since this provider started. */
|
|
27372
|
-
lastPressedAt: number$1().nullable(),
|
|
27373
|
-
/** Counter since provider start. Resets on reboot. Useful for metrics/debug. */
|
|
27374
|
-
pressCountSinceStart: number$1()
|
|
27375
|
-
});
|
|
27376
|
-
object({
|
|
27377
|
-
deviceId: number$1(),
|
|
27378
|
-
timestamp: number$1()
|
|
27379
|
-
});
|
|
27380
|
-
DeviceType.Button, DeviceType.Camera;
|
|
27381
28039
|
/**
|
|
27382
28040
|
* Enum-state sensor — a string value picked from a finite option set.
|
|
27383
28041
|
* Drives HA `sensor` entries with `state_class: enum` (HVAC action
|
|
@@ -34144,42 +34802,6 @@ DeviceType.Camera, method(object({
|
|
|
34144
34802
|
package: array(ZoneRuleSchema).readonly()
|
|
34145
34803
|
});
|
|
34146
34804
|
/**
|
|
34147
|
-
* LA tabella "quale booleano di questo tipo di device conta come ALTO", e il
|
|
34148
|
-
* valutatore puro del suo FRONTE.
|
|
34149
|
-
*
|
|
34150
|
-
* Viveva dentro il builtin virtual-doorbell
|
|
34151
|
-
* (`@camstack/system` — `builtins/doorbell/trigger-engine.ts`) e i suoi
|
|
34152
|
-
* predicati erano privati al modulo. Il recorder ne ha bisogno per il trigger
|
|
34153
|
-
* `RecordingTriggers.sensorDeviceIds`: copiarla avrebbe creato la SECONDA
|
|
34154
|
-
* tabella, che diverge alla prima cap aggiunta e il cui sintomo — "il sensore
|
|
34155
|
-
* fa suonare il campanello ma non registra" — è esattamente D62. Quindi si
|
|
34156
|
-
* SPOSTA qui e il doorbell la ri-esporta.
|
|
34157
|
-
*
|
|
34158
|
-
* ⚠ NON è `DEVICE_STATE_READERS` (`catalogs/device-state-vocabulary.ts`), e le
|
|
34159
|
-
* due non vanno unificate: quella risponde a "qual è la PAROLA di stato per una
|
|
34160
|
-
* regola" (e include `presence`, `cover`, `alarm-panel`), questa a "qual è il
|
|
34161
|
-
* booleano il cui FRONTE conta". Vocabolari deliberatamente diversi.
|
|
34162
|
-
*/
|
|
34163
|
-
/**
|
|
34164
|
-
* Known binary / switch source caps → the boolean slice field whose
|
|
34165
|
-
* false→true rise counts as ACTIVE. Every entry is "fire on active".
|
|
34166
|
-
* Sensors whose "active" reading is not a plain boolean (presence's string
|
|
34167
|
-
* state, connectivity's connected flag) are deliberately excluded — a
|
|
34168
|
-
* reconnect is not a doorbell press, and it is not a recording either.
|
|
34169
|
-
*/
|
|
34170
|
-
var SOURCE_CAP_ACTIVE_FIELD = {
|
|
34171
|
-
contact: "entryOpen",
|
|
34172
|
-
binary: "on",
|
|
34173
|
-
switch: "on",
|
|
34174
|
-
motion: "detected",
|
|
34175
|
-
flood: "flooded",
|
|
34176
|
-
gas: "detected",
|
|
34177
|
-
smoke: "detected",
|
|
34178
|
-
"carbon-monoxide": "detected",
|
|
34179
|
-
vibration: "detected",
|
|
34180
|
-
tamper: "tampered"
|
|
34181
|
-
};
|
|
34182
|
-
/**
|
|
34183
34805
|
* Accessory device helpers — shared across drivers.
|
|
34184
34806
|
*
|
|
34185
34807
|
* Many vendor-specific drivers register accessory child devices on
|
|
@@ -36979,6 +37601,30 @@ Object.freeze({
|
|
|
36979
37601
|
addonId: null,
|
|
36980
37602
|
access: "create"
|
|
36981
37603
|
},
|
|
37604
|
+
"deviceExtension.listCandidates": {
|
|
37605
|
+
capName: "device-extension",
|
|
37606
|
+
capScope: "device",
|
|
37607
|
+
addonId: null,
|
|
37608
|
+
access: "view"
|
|
37609
|
+
},
|
|
37610
|
+
"deviceExtension.listSlots": {
|
|
37611
|
+
capName: "device-extension",
|
|
37612
|
+
capScope: "device",
|
|
37613
|
+
addonId: null,
|
|
37614
|
+
access: "view"
|
|
37615
|
+
},
|
|
37616
|
+
"deviceExtension.listSources": {
|
|
37617
|
+
capName: "device-extension",
|
|
37618
|
+
capScope: "device",
|
|
37619
|
+
addonId: null,
|
|
37620
|
+
access: "view"
|
|
37621
|
+
},
|
|
37622
|
+
"deviceExtension.setSlot": {
|
|
37623
|
+
capName: "device-extension",
|
|
37624
|
+
capScope: "device",
|
|
37625
|
+
addonId: null,
|
|
37626
|
+
access: "create"
|
|
37627
|
+
},
|
|
36982
37628
|
"deviceManager.addLocation": {
|
|
36983
37629
|
capName: "device-manager",
|
|
36984
37630
|
capScope: "system",
|
|
@@ -37051,12 +37697,6 @@ Object.freeze({
|
|
|
37051
37697
|
addonId: null,
|
|
37052
37698
|
access: "create"
|
|
37053
37699
|
},
|
|
37054
|
-
"deviceManager.applyDeviceSettingsPatch": {
|
|
37055
|
-
capName: "device-manager",
|
|
37056
|
-
capScope: "system",
|
|
37057
|
-
addonId: null,
|
|
37058
|
-
access: "create"
|
|
37059
|
-
},
|
|
37060
37700
|
"deviceManager.applyInitialMeta": {
|
|
37061
37701
|
capName: "device-manager",
|
|
37062
37702
|
capScope: "system",
|
|
@@ -37159,12 +37799,6 @@ Object.freeze({
|
|
|
37159
37799
|
addonId: null,
|
|
37160
37800
|
access: "view"
|
|
37161
37801
|
},
|
|
37162
|
-
"deviceManager.getDeviceLiveContribution": {
|
|
37163
|
-
capName: "device-manager",
|
|
37164
|
-
capScope: "system",
|
|
37165
|
-
addonId: null,
|
|
37166
|
-
access: "view"
|
|
37167
|
-
},
|
|
37168
37802
|
"deviceManager.getDeviceLiveInfoAggregate": {
|
|
37169
37803
|
capName: "device-manager",
|
|
37170
37804
|
capScope: "system",
|
|
@@ -37177,12 +37811,6 @@ Object.freeze({
|
|
|
37177
37811
|
addonId: null,
|
|
37178
37812
|
access: "view"
|
|
37179
37813
|
},
|
|
37180
|
-
"deviceManager.getDeviceSettingsContribution": {
|
|
37181
|
-
capName: "device-manager",
|
|
37182
|
-
capScope: "system",
|
|
37183
|
-
addonId: null,
|
|
37184
|
-
access: "view"
|
|
37185
|
-
},
|
|
37186
37814
|
"deviceManager.getDeviceStatusAggregate": {
|
|
37187
37815
|
capName: "device-manager",
|
|
37188
37816
|
capScope: "system",
|
|
@@ -37687,24 +38315,6 @@ Object.freeze({
|
|
|
37687
38315
|
addonId: null,
|
|
37688
38316
|
access: "view"
|
|
37689
38317
|
},
|
|
37690
|
-
"doorbell.applyDeviceSettingsPatch": {
|
|
37691
|
-
capName: "doorbell",
|
|
37692
|
-
capScope: "device",
|
|
37693
|
-
addonId: null,
|
|
37694
|
-
access: "create"
|
|
37695
|
-
},
|
|
37696
|
-
"doorbell.getDeviceLiveContribution": {
|
|
37697
|
-
capName: "doorbell",
|
|
37698
|
-
capScope: "device",
|
|
37699
|
-
addonId: null,
|
|
37700
|
-
access: "view"
|
|
37701
|
-
},
|
|
37702
|
-
"doorbell.getDeviceSettingsContribution": {
|
|
37703
|
-
capName: "doorbell",
|
|
37704
|
-
capScope: "device",
|
|
37705
|
-
addonId: null,
|
|
37706
|
-
access: "view"
|
|
37707
|
-
},
|
|
37708
38318
|
"doorbell.getStatus": {
|
|
37709
38319
|
capName: "doorbell",
|
|
37710
38320
|
capScope: "device",
|
|
@@ -37729,6 +38339,12 @@ Object.freeze({
|
|
|
37729
38339
|
addonId: null,
|
|
37730
38340
|
access: "view"
|
|
37731
38341
|
},
|
|
38342
|
+
"embeddingEncoder.resetFailedModels": {
|
|
38343
|
+
capName: "embedding-encoder",
|
|
38344
|
+
capScope: "system",
|
|
38345
|
+
addonId: null,
|
|
38346
|
+
access: "delete"
|
|
38347
|
+
},
|
|
37732
38348
|
"enumSensor.getStatus": {
|
|
37733
38349
|
capName: "enum-sensor",
|
|
37734
38350
|
capScope: "device",
|
|
@@ -40063,6 +40679,12 @@ Object.freeze({
|
|
|
40063
40679
|
addonId: null,
|
|
40064
40680
|
access: "view"
|
|
40065
40681
|
},
|
|
40682
|
+
"pipelineOrchestrator.getClusterModelChoice": {
|
|
40683
|
+
capName: "pipeline-orchestrator",
|
|
40684
|
+
capScope: "system",
|
|
40685
|
+
addonId: null,
|
|
40686
|
+
access: "view"
|
|
40687
|
+
},
|
|
40066
40688
|
"pipelineOrchestrator.getDeviceLiveContribution": {
|
|
40067
40689
|
capName: "pipeline-orchestrator",
|
|
40068
40690
|
capScope: "system",
|
|
@@ -42888,6 +43510,26 @@ Object.freeze({
|
|
|
42888
43510
|
form: "single",
|
|
42889
43511
|
optional: false
|
|
42890
43512
|
}],
|
|
43513
|
+
"deviceExtension.listCandidates": [{
|
|
43514
|
+
name: "deviceId",
|
|
43515
|
+
form: "single",
|
|
43516
|
+
optional: false
|
|
43517
|
+
}],
|
|
43518
|
+
"deviceExtension.listSlots": [{
|
|
43519
|
+
name: "deviceId",
|
|
43520
|
+
form: "single",
|
|
43521
|
+
optional: false
|
|
43522
|
+
}],
|
|
43523
|
+
"deviceExtension.listSources": [{
|
|
43524
|
+
name: "deviceId",
|
|
43525
|
+
form: "single",
|
|
43526
|
+
optional: false
|
|
43527
|
+
}],
|
|
43528
|
+
"deviceExtension.setSlot": [{
|
|
43529
|
+
name: "deviceId",
|
|
43530
|
+
form: "single",
|
|
43531
|
+
optional: false
|
|
43532
|
+
}],
|
|
42891
43533
|
"deviceManager.adoptionRelease": [{
|
|
42892
43534
|
name: "camDeviceId",
|
|
42893
43535
|
form: "single",
|
|
@@ -45347,68 +45989,6 @@ TimelapseRuleInputSchema.extend({
|
|
|
45347
45989
|
createdAt: number$1(),
|
|
45348
45990
|
updatedAt: number$1()
|
|
45349
45991
|
});
|
|
45350
|
-
Object.freeze(Object.fromEntries([{
|
|
45351
|
-
stepId: "face-embedding",
|
|
45352
|
-
label: "Face recognition model",
|
|
45353
|
-
defaultModelId: "arcface-r100",
|
|
45354
|
-
indexName: "the enrolled face gallery",
|
|
45355
|
-
options: [
|
|
45356
|
-
{
|
|
45357
|
-
id: "arcface-r100",
|
|
45358
|
-
label: "ArcFace (ResNet34)"
|
|
45359
|
-
},
|
|
45360
|
-
{
|
|
45361
|
-
id: "auraface-r100",
|
|
45362
|
-
label: "AuraFace R100"
|
|
45363
|
-
},
|
|
45364
|
-
{
|
|
45365
|
-
id: "inception-resnet-v1",
|
|
45366
|
-
label: "Inception ResNet V1"
|
|
45367
|
-
}
|
|
45368
|
-
]
|
|
45369
|
-
}, {
|
|
45370
|
-
stepId: "clip-embedding",
|
|
45371
|
-
label: "Semantic search model",
|
|
45372
|
-
defaultModelId: "mobileclip-s1",
|
|
45373
|
-
indexName: "the object semantic-search index",
|
|
45374
|
-
options: [{
|
|
45375
|
-
id: "mobileclip-s1",
|
|
45376
|
-
label: "MobileCLIP S1"
|
|
45377
|
-
}, {
|
|
45378
|
-
id: "mobileclip-s2",
|
|
45379
|
-
label: "MobileCLIP S2"
|
|
45380
|
-
}]
|
|
45381
|
-
}].map((s) => [s.stepId, s.defaultModelId])));
|
|
45382
|
-
string().min(1);
|
|
45383
|
-
var CLUSTER_STEP_SETTING_FIELDS = [{
|
|
45384
|
-
stepId: "face-embedding",
|
|
45385
|
-
key: "minLandmarkFaceSize",
|
|
45386
|
-
label: "Min face size for recognition (detection px)",
|
|
45387
|
-
description: "Refuse to embed a face smaller than this IN THE DETECTION FRAME. Applies to every node — the enrolled gallery is one index, and two admission floors would fill it from two policies. 0 disables the gate.",
|
|
45388
|
-
type: "slider",
|
|
45389
|
-
min: 0,
|
|
45390
|
-
max: 64,
|
|
45391
|
-
step: 2,
|
|
45392
|
-
default: 24
|
|
45393
|
-
}];
|
|
45394
|
-
function clusterStepSettingKey(stepId, fieldKey) {
|
|
45395
|
-
return `clusterStepSetting:${stepId}:${fieldKey}`;
|
|
45396
|
-
}
|
|
45397
|
-
var ClusterSettingNumberSchema = number$1().finite();
|
|
45398
|
-
function readClusterStepSettings(config) {
|
|
45399
|
-
const out = {};
|
|
45400
|
-
for (const field of CLUSTER_STEP_SETTING_FIELDS) {
|
|
45401
|
-
const parsed = ClusterSettingNumberSchema.safeParse(config[clusterStepSettingKey(field.stepId, field.key)]);
|
|
45402
|
-
const value = parsed.success ? parsed.data : field.default;
|
|
45403
|
-
const existing = out[field.stepId] ?? {};
|
|
45404
|
-
out[field.stepId] = {
|
|
45405
|
-
...existing,
|
|
45406
|
-
[field.key]: value
|
|
45407
|
-
};
|
|
45408
|
-
}
|
|
45409
|
-
return out;
|
|
45410
|
-
}
|
|
45411
|
-
readClusterStepSettings({});
|
|
45412
45992
|
object({
|
|
45413
45993
|
/**
|
|
45414
45994
|
* Fraction of the box's own size added on EACH side before cutting.
|
|
@@ -83301,6 +83881,53 @@ function createLlmProvider(deps) {
|
|
|
83301
83881
|
};
|
|
83302
83882
|
}
|
|
83303
83883
|
//#endregion
|
|
83884
|
+
//#region src/runtime/llm-model-licenses.ts
|
|
83885
|
+
var QWEN_ATTRIBUTION = "Qwen models © Alibaba Cloud, Apache-2.0.";
|
|
83886
|
+
var QWEN_APACHE = {
|
|
83887
|
+
weights: "Apache-2.0",
|
|
83888
|
+
upstream: {
|
|
83889
|
+
name: "Qwen (Alibaba Cloud)",
|
|
83890
|
+
url: "https://huggingface.co/Qwen"
|
|
83891
|
+
},
|
|
83892
|
+
url: "https://huggingface.co/Qwen/Qwen2.5-1.5B-Instruct-GGUF",
|
|
83893
|
+
attribution: QWEN_ATTRIBUTION,
|
|
83894
|
+
modifications: "none (GGUF Q4_K_M published by Qwen; not re-hosted by CamStack)",
|
|
83895
|
+
hosting: "third-party"
|
|
83896
|
+
};
|
|
83897
|
+
var LLAMA_32_COMMUNITY = {
|
|
83898
|
+
weights: "LicenseRef-Llama-3.2-Community",
|
|
83899
|
+
upstream: {
|
|
83900
|
+
name: "Meta Llama 3.2 (GGUF by bartowski)",
|
|
83901
|
+
url: "https://huggingface.co/bartowski/Llama-3.2-3B-Instruct-GGUF"
|
|
83902
|
+
},
|
|
83903
|
+
url: "https://github.com/meta-llama/llama-models/blob/main/models/llama3_2/LICENSE",
|
|
83904
|
+
attribution: "Built with Llama. Llama 3.2 is licensed under the Llama 3.2 Community License, Copyright © Meta Platforms, Inc. All Rights Reserved.",
|
|
83905
|
+
modifications: "Q4_K_M GGUF quantisation by bartowski (not re-hosted by CamStack)",
|
|
83906
|
+
hosting: "third-party"
|
|
83907
|
+
};
|
|
83908
|
+
var QWEN_VL_APACHE = {
|
|
83909
|
+
weights: "Apache-2.0",
|
|
83910
|
+
upstream: {
|
|
83911
|
+
name: "Qwen3-VL (GGUF by unsloth)",
|
|
83912
|
+
url: "https://huggingface.co/unsloth"
|
|
83913
|
+
},
|
|
83914
|
+
url: "https://huggingface.co/Qwen/Qwen3-VL-8B-Instruct",
|
|
83915
|
+
attribution: QWEN_ATTRIBUTION,
|
|
83916
|
+
modifications: "Q4_K_M GGUF quantisation by unsloth (not re-hosted by CamStack)",
|
|
83917
|
+
hosting: "third-party"
|
|
83918
|
+
};
|
|
83919
|
+
var QWEN36_APACHE = {
|
|
83920
|
+
weights: "Apache-2.0",
|
|
83921
|
+
upstream: {
|
|
83922
|
+
name: "Qwen3.6-35B-A3B (GGUF by unsloth)",
|
|
83923
|
+
url: "https://huggingface.co/unsloth/Qwen3.6-35B-A3B-GGUF"
|
|
83924
|
+
},
|
|
83925
|
+
url: "https://huggingface.co/Qwen/Qwen3.6-35B-A3B/blob/main/LICENSE",
|
|
83926
|
+
attribution: QWEN_ATTRIBUTION,
|
|
83927
|
+
modifications: "UD-Q4_K_M GGUF quantisation by unsloth (not re-hosted by CamStack)",
|
|
83928
|
+
hosting: "third-party"
|
|
83929
|
+
};
|
|
83930
|
+
//#endregion
|
|
83304
83931
|
//#region src/runtime/llm-model-catalog.ts
|
|
83305
83932
|
/**
|
|
83306
83933
|
* Curated managed-model catalog (operator decision #4). Each entry carries BOTH
|
|
@@ -83331,7 +83958,7 @@ var GIB = 1024 * 1024 * 1024;
|
|
|
83331
83958
|
function mb(bytes) {
|
|
83332
83959
|
return Math.round(bytes / (1024 * 1024));
|
|
83333
83960
|
}
|
|
83334
|
-
function textEntry(meta) {
|
|
83961
|
+
function textEntry(meta, license) {
|
|
83335
83962
|
return {
|
|
83336
83963
|
meta,
|
|
83337
83964
|
entry: {
|
|
@@ -83346,7 +83973,8 @@ function textEntry(meta) {
|
|
|
83346
83973
|
width: 0,
|
|
83347
83974
|
height: 0
|
|
83348
83975
|
},
|
|
83349
|
-
labels: []
|
|
83976
|
+
labels: [],
|
|
83977
|
+
license
|
|
83350
83978
|
}
|
|
83351
83979
|
};
|
|
83352
83980
|
}
|
|
@@ -83361,7 +83989,7 @@ var QWEN = textEntry({
|
|
|
83361
83989
|
quantization: "Q4_K_M",
|
|
83362
83990
|
minRamBytes: 2 * GIB,
|
|
83363
83991
|
contextSizeDefault: 4096
|
|
83364
|
-
});
|
|
83992
|
+
}, QWEN_APACHE);
|
|
83365
83993
|
var LLAMA = textEntry({
|
|
83366
83994
|
id: "llm-llama3.2-3b-instruct-q4",
|
|
83367
83995
|
label: "Llama 3.2 3B Instruct",
|
|
@@ -83373,7 +84001,7 @@ var LLAMA = textEntry({
|
|
|
83373
84001
|
quantization: "Q4_K_M",
|
|
83374
84002
|
minRamBytes: Math.round(3.5 * GIB),
|
|
83375
84003
|
contextSizeDefault: 4096
|
|
83376
|
-
});
|
|
84004
|
+
}, LLAMA_32_COMMUNITY);
|
|
83377
84005
|
var QWEN3VL2B_MODEL_BYTES = 1107410624;
|
|
83378
84006
|
var QWEN3VL2B_MMPROJ_BYTES = 819395232;
|
|
83379
84007
|
var QWEN3VL2B_BASE = "https://huggingface.co/unsloth/Qwen3-VL-2B-Instruct-GGUF/resolve/main";
|
|
@@ -83402,6 +84030,7 @@ var QWEN3VL_2B = {
|
|
|
83402
84030
|
},
|
|
83403
84031
|
entry: {
|
|
83404
84032
|
id: "llm-qwen3-vl-2b-instruct-q4",
|
|
84033
|
+
license: QWEN_VL_APACHE,
|
|
83405
84034
|
name: "Qwen3-VL 2B Instruct (vision, light)",
|
|
83406
84035
|
description: "qwen3-vl · Q4_K_M · +mmproj",
|
|
83407
84036
|
formats: { gguf: {
|
|
@@ -83456,6 +84085,7 @@ var QWEN3VL_4B = {
|
|
|
83456
84085
|
},
|
|
83457
84086
|
entry: {
|
|
83458
84087
|
id: "llm-qwen3-vl-4b-instruct-q4",
|
|
84088
|
+
license: QWEN_VL_APACHE,
|
|
83459
84089
|
name: "Qwen3-VL 4B Instruct (vision)",
|
|
83460
84090
|
description: "qwen3-vl · Q4_K_M · +mmproj",
|
|
83461
84091
|
formats: { gguf: {
|
|
@@ -83507,6 +84137,7 @@ var QWEN3VL_8B = {
|
|
|
83507
84137
|
},
|
|
83508
84138
|
entry: {
|
|
83509
84139
|
id: "llm-qwen3-vl-8b-instruct-q4",
|
|
84140
|
+
license: QWEN_VL_APACHE,
|
|
83510
84141
|
name: "Qwen3-VL 8B Instruct (vision)",
|
|
83511
84142
|
description: "qwen3-vl · Q4_K_M · +mmproj",
|
|
83512
84143
|
formats: { gguf: {
|
|
@@ -83552,6 +84183,7 @@ var LLM_MODEL_CATALOG = [
|
|
|
83552
84183
|
},
|
|
83553
84184
|
entry: {
|
|
83554
84185
|
id: "llm-qwen3.6-35b-a3b-ud-q4",
|
|
84186
|
+
license: QWEN36_APACHE,
|
|
83555
84187
|
name: "Qwen3.6 35B-A3B (vision)",
|
|
83556
84188
|
description: "qwen3.6 · UD-Q4_K_M · +mmproj",
|
|
83557
84189
|
formats: { gguf: {
|