@camstack/addon-provider-onvif 1.2.101 → 1.2.103
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/addon.js +316 -10
- package/dist/addon.mjs +316 -10
- package/package.json +2 -2
package/dist/addon.js
CHANGED
|
@@ -5363,7 +5363,7 @@ var ZodIssueCode = {
|
|
|
5363
5363
|
var ZodFirstPartyTypeKind;
|
|
5364
5364
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5365
5365
|
//#endregion
|
|
5366
|
-
//#region ../types/dist/sleep-
|
|
5366
|
+
//#region ../types/dist/sleep-BDR76Ykr.mjs
|
|
5367
5367
|
/**
|
|
5368
5368
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5369
5369
|
* window to float samples (D455).
|
|
@@ -17914,6 +17914,48 @@ var NcAlarmConfigSchema = object({
|
|
|
17914
17914
|
settings: NcAlarmSettingsSchema,
|
|
17915
17915
|
coverage: array(NcAlarmModeCoverageSchema)
|
|
17916
17916
|
});
|
|
17917
|
+
/**
|
|
17918
|
+
* ONE rule's demand on ONE camera's clip ring.
|
|
17919
|
+
*
|
|
17920
|
+
* A rule, not a camera: the broker takes the MAX over the asks that reach a
|
|
17921
|
+
* camera, so the answer stays a faithful description of the rules and the
|
|
17922
|
+
* bounding (the byte budget, the broker's own ceiling) stays where the cost
|
|
17923
|
+
* lives. A camera that appears in no ask is being told **nothing** — which is
|
|
17924
|
+
* a different thing from never having been told, and only the envelope
|
|
17925
|
+
* (`rulesLoaded`) can tell those apart.
|
|
17926
|
+
*/
|
|
17927
|
+
var NcClipRetentionAskSchema = object({
|
|
17928
|
+
/**
|
|
17929
|
+
* The camera this ask is about. **Absent = every camera**, which is what a
|
|
17930
|
+
* rule with no `conditions.devices` means: it can fire anywhere, so it is
|
|
17931
|
+
* asking everywhere.
|
|
17932
|
+
*/
|
|
17933
|
+
deviceId: number().int().nonnegative().optional(),
|
|
17934
|
+
/** Seconds of history the rule needs held for it. Never zero — a rule that
|
|
17935
|
+
* needs nothing produces no ask at all. */
|
|
17936
|
+
seconds: number().min(0).max(60),
|
|
17937
|
+
/** The profile the rule cuts from, when it named one. Absent = the cheapest
|
|
17938
|
+
* assigned, which is what the cut defaults to. */
|
|
17939
|
+
profile: CamProfileSchema.optional(),
|
|
17940
|
+
/** Who is asking — so a retention the operator did not expect names a rule. */
|
|
17941
|
+
ruleId: string(),
|
|
17942
|
+
ruleName: string(),
|
|
17943
|
+
/** Why this many seconds: the rule's own window, or the occupancy ceiling. */
|
|
17944
|
+
reason: _enum(["window", "occupancy"])
|
|
17945
|
+
});
|
|
17946
|
+
/**
|
|
17947
|
+
* The whole answer, with the one bit that keeps absence from reading as zero.
|
|
17948
|
+
*
|
|
17949
|
+
* `rulesLoaded` is false until the rule ledger has completed a load at least
|
|
17950
|
+
* once. A centre that is up but has not read its rules yet answers with an
|
|
17951
|
+
* empty ask list that means nothing at all — applying it would drop every
|
|
17952
|
+
* camera's ring to zero for the first events after a restart, which is the
|
|
17953
|
+
* footage this mechanism exists to keep.
|
|
17954
|
+
*/
|
|
17955
|
+
var NcClipRetentionPlanSchema = object({
|
|
17956
|
+
rulesLoaded: boolean(),
|
|
17957
|
+
asks: array(NcClipRetentionAskSchema).readonly()
|
|
17958
|
+
});
|
|
17917
17959
|
method(object({}), object({ rules: array(NcRuleSchema) }), { auth: "admin" }), method(object({ ruleId: string() }), object({ rule: NcRuleSchema.nullable() }), { auth: "admin" }), method(object({ rule: NcRuleInputSchema }), object({ rule: NcRuleSchema }), {
|
|
17918
17960
|
kind: "mutation",
|
|
17919
17961
|
auth: "admin",
|
|
@@ -17934,7 +17976,7 @@ method(object({}), object({ rules: array(NcRuleSchema) }), { auth: "admin" }), m
|
|
|
17934
17976
|
}), object({ success: literal(true) }), {
|
|
17935
17977
|
kind: "mutation",
|
|
17936
17978
|
auth: "admin"
|
|
17937
|
-
}), method(object({}), object({ mutedDeviceIds: array(number().int()).readonly() }), { auth: "admin" }), method(object({
|
|
17979
|
+
}), method(object({}), NcClipRetentionPlanSchema, { auth: "admin" }), method(object({}), object({ mutedDeviceIds: array(number().int()).readonly() }), { auth: "admin" }), method(object({
|
|
17938
17980
|
deviceId: number().int(),
|
|
17939
17981
|
muted: boolean()
|
|
17940
17982
|
}), object({ success: literal(true) }), {
|
|
@@ -19079,13 +19121,26 @@ var TrackAudioLabelSchema = object({
|
|
|
19079
19121
|
* - `audio` — an audio event on the camera itself that was anomalous for
|
|
19080
19122
|
* THAT camera, loud, and heard while nothing visual was happening (D62).
|
|
19081
19123
|
*
|
|
19124
|
+
* - `onboard` — the CAMERA's own firmware, paired with a decoded frame in
|
|
19125
|
+
* that frame's pixel space. A real root detector and a SPATIAL one: its
|
|
19126
|
+
* boxes are the same kind of fact `pipeline`'s are, produced by a different
|
|
19127
|
+
* detector.
|
|
19128
|
+
*
|
|
19129
|
+
* `onboard` was missing here while `DetectionSourceSchema` already had it, so
|
|
19130
|
+
* a persisted onboard track failed `safeParse` on read and came back with NO
|
|
19131
|
+
* source at all — which `isSpatialTrack` then admitted by accident, through the
|
|
19132
|
+
* `undefined` arm rather than by anybody's decision, and which `excludeSources`
|
|
19133
|
+
* could not name.
|
|
19134
|
+
*
|
|
19082
19135
|
* The spatial subsystems (tracker association, occupancy count, re-id /
|
|
19083
19136
|
* embedding, resurrection) MUST skip every synthetic source. Test for that
|
|
19084
|
-
* with `isSpatialTrack`, which allow-lists
|
|
19085
|
-
* check silently readmits every source added after it was
|
|
19137
|
+
* with `isSpatialTrack`, which allow-lists the spatial sources explicitly — a
|
|
19138
|
+
* `!== 'sensor'` check silently readmits every source added after it was
|
|
19139
|
+
* written.
|
|
19086
19140
|
*/
|
|
19087
19141
|
var TrackSourceSchema = _enum([
|
|
19088
19142
|
"pipeline",
|
|
19143
|
+
"onboard",
|
|
19089
19144
|
"sensor",
|
|
19090
19145
|
"audio"
|
|
19091
19146
|
]);
|
|
@@ -20468,6 +20523,33 @@ var RunReplayFrameProcessorResultSchema = object({ tracks: array(object({
|
|
|
20468
20523
|
* solid is this track", cheaper than re-deriving it from a trajectory. */
|
|
20469
20524
|
framesMatched: number().int()
|
|
20470
20525
|
})).readonly() });
|
|
20526
|
+
/**
|
|
20527
|
+
* The long-term series a camera produces. A closed union so a typo cannot
|
|
20528
|
+
* invent one, and the ONE declaration of it — the addon's `AnalyticsLtsSeries`
|
|
20529
|
+
* is an alias of this, not a second list.
|
|
20530
|
+
*/
|
|
20531
|
+
var AnalyticsLtsSeriesSchema = _enum([
|
|
20532
|
+
"motion",
|
|
20533
|
+
"audio-dbfs",
|
|
20534
|
+
"battery",
|
|
20535
|
+
"occupancy"
|
|
20536
|
+
]);
|
|
20537
|
+
/**
|
|
20538
|
+
* One closed 5-minute bucket of a long-term series.
|
|
20539
|
+
*
|
|
20540
|
+
* `samples` is how many readings the bucket folded — it is the ACTIVITY for a
|
|
20541
|
+
* series like `motion`, and the confidence for one like `occupancy`. A bucket
|
|
20542
|
+
* that exists at all was measured; a bucket that is absent was not, which is a
|
|
20543
|
+
* different claim from zero and the reason this is a sparse series.
|
|
20544
|
+
*/
|
|
20545
|
+
var LtsBucketSchema = object({
|
|
20546
|
+
scope: string(),
|
|
20547
|
+
bucketStart: number().int(),
|
|
20548
|
+
samples: number().int().nonnegative(),
|
|
20549
|
+
sum: number(),
|
|
20550
|
+
min: number(),
|
|
20551
|
+
max: number()
|
|
20552
|
+
});
|
|
20471
20553
|
DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).readonly()), method(object({
|
|
20472
20554
|
deviceId: number(),
|
|
20473
20555
|
trackId: string()
|
|
@@ -20514,6 +20596,14 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
|
|
|
20514
20596
|
kinds: array(string()).optional(),
|
|
20515
20597
|
limit: number().int().min(1).max(MAX_EVENT_QUERY_LIMIT).default(DEFAULT_EVENT_QUERY_LIMIT)
|
|
20516
20598
|
}), array(SensorEventSchema).readonly()), method(KeyEventQueryInput, array(KeyEventSchema).readonly()), method(KeyEventBatchQueryInput, array(KeyEventsForDeviceSchema).readonly()), method(object({
|
|
20599
|
+
deviceId: number(),
|
|
20600
|
+
series: AnalyticsLtsSeriesSchema,
|
|
20601
|
+
/** Omit for EVERY scope of this series in the range. */
|
|
20602
|
+
scope: string().optional(),
|
|
20603
|
+
from: number(),
|
|
20604
|
+
to: number(),
|
|
20605
|
+
limit: number().int().positive().optional()
|
|
20606
|
+
}), array(LtsBucketSchema).readonly()), method(object({
|
|
20517
20607
|
deviceId: number(),
|
|
20518
20608
|
since: number(),
|
|
20519
20609
|
until: number(),
|
|
@@ -21132,6 +21222,40 @@ var MotionSourceEnum = _enum([
|
|
|
21132
21222
|
*/
|
|
21133
21223
|
var MotionSourcesSchema = array(MotionSourceEnum);
|
|
21134
21224
|
/**
|
|
21225
|
+
* Which root detector a camera runs — EXACTLY ONE.
|
|
21226
|
+
*
|
|
21227
|
+
* Deliberately the SAME vocabulary post-analysis already tags every detection
|
|
21228
|
+
* with (`DetectionSource`) rather than a second spelling of the same two
|
|
21229
|
+
* ideas: the value an operator picks here is the value that comes back on the
|
|
21230
|
+
* track, the overlay and the debug row.
|
|
21231
|
+
*
|
|
21232
|
+
* ## Why one, and why it is still an array
|
|
21233
|
+
*
|
|
21234
|
+
* Two roots on one camera is a capability nobody asked for and the operator has
|
|
21235
|
+
* since ruled out. It was never free: both planes feed the SAME per-device
|
|
21236
|
+
* stationary registry, both can promote the same parked object, and the two
|
|
21237
|
+
* detectors disagree about the same box by construction — which is the
|
|
21238
|
+
* disagreement D505 had to arbitrate. Removing the case removes the arbitration.
|
|
21239
|
+
*
|
|
21240
|
+
* The ARRAY shape survives because the stored settings and the attach payload
|
|
21241
|
+
* already speak it on every camera of every fleet, and a cap input that
|
|
21242
|
+
* suddenly refuses a stored value makes the camera un-attachable — a fail-closed
|
|
21243
|
+
* in the one direction that costs an operator their cameras. So the wire stays
|
|
21244
|
+
* tolerant and the TYPE is exact: a longer list is truncated to its first
|
|
21245
|
+
* element rather than refused, and `max(1)` is what every consumer can then
|
|
21246
|
+
* rely on.
|
|
21247
|
+
*
|
|
21248
|
+
* AT MOST one, not exactly one. The EMPTY list is a legal, deliberate pick —
|
|
21249
|
+
* a camera an operator left with no root detector — and `planDetectionSources`
|
|
21250
|
+
* has always said so: inventing a root for them is how a default acts without
|
|
21251
|
+
* anybody choosing it. Tightening this to `length(1)` broke that, and the
|
|
21252
|
+
* suite caught it.
|
|
21253
|
+
*
|
|
21254
|
+
* Measured before tightening (2026-09-15, this fleet, 6 h of attaches): 3327
|
|
21255
|
+
* `["pipeline"]` and 2 `["onboard"]`. Not one camera had two.
|
|
21256
|
+
*/
|
|
21257
|
+
var DetectionSourcesSchema = preprocess((value) => Array.isArray(value) && value.length > 1 ? value.slice(0, 1) : value, array(DetectionSourceSchema).max(1));
|
|
21258
|
+
/**
|
|
21135
21259
|
* Input shape for `pipeline-runner.reportMotion` cap method. Exported
|
|
21136
21260
|
* so cap-side consumers (the orchestrator forward, the runner addon's
|
|
21137
21261
|
* cap implementation, tests) can reuse the type instead of redeclaring
|
|
@@ -21282,6 +21406,35 @@ var RunnerCameraConfigSchema = object({
|
|
|
21282
21406
|
* events; the orchestrator forwards to `reportMotion`.
|
|
21283
21407
|
*/
|
|
21284
21408
|
motionSources: MotionSourcesSchema.default(["analyzer"]),
|
|
21409
|
+
/**
|
|
21410
|
+
* WHICH root detector runs for this camera. The detection counterpart of
|
|
21411
|
+
* {@link motionSources}, same shape and same discipline: a per-camera list
|
|
21412
|
+
* of sources the system understands, vendor-agnostic, owned here.
|
|
21413
|
+
*
|
|
21414
|
+
* - `pipeline` — this runner's own root step on decoded pixels (`steps`).
|
|
21415
|
+
* - `onboard` — the CAMERA's own detector, admitted only when it is named
|
|
21416
|
+
* here. Its boxes reach post-analysis on the same
|
|
21417
|
+
* `PipelineInferenceResult` payload as the pipeline's, so an onboard-born
|
|
21418
|
+
* track gets the same tracker, the same overlay and the same detail
|
|
21419
|
+
* subtree (face / plate / embedding).
|
|
21420
|
+
*
|
|
21421
|
+
* `['onboard']` alone is the REPLACEMENT: this runner's root step does not
|
|
21422
|
+
* run, and that is where a camera with a usable onboard detector buys back
|
|
21423
|
+
* its share of the accelerator. It saves the root inference, not the decode
|
|
21424
|
+
* — the detail subtree still needs pixels to cut crops from.
|
|
21425
|
+
*
|
|
21426
|
+
* A camera whose onboard detections carry no geometry cannot serve as a root
|
|
21427
|
+
* step at all (there is nothing to track), and the cap that knows this says
|
|
21428
|
+
* so on `native-object-detection.getOptions().geometry`. On Reolink that is
|
|
21429
|
+
* every battery camera: the boxes ride a sub-stream a battery camera never
|
|
21430
|
+
* attaches, so such a camera stays on `['pipeline']` and its onboard AI is
|
|
21431
|
+
* worth exactly what it already is — a wake signal with a class.
|
|
21432
|
+
*
|
|
21433
|
+
* Defaults to `['pipeline']`, which is byte-for-byte today's behaviour: a
|
|
21434
|
+
* vendor never turns a detector on for the operator, and neither does a
|
|
21435
|
+
* default.
|
|
21436
|
+
*/
|
|
21437
|
+
detectionSources: DetectionSourcesSchema.default(["pipeline"]),
|
|
21285
21438
|
pipelineEnabled: boolean().default(true),
|
|
21286
21439
|
/** Ordered tree of video steps. Absent → runner skips video detection. */
|
|
21287
21440
|
steps: array(PipelineStepInputSchema).readonly().optional(),
|
|
@@ -21463,7 +21616,47 @@ var RunnerLocalMetricsSchema = object({
|
|
|
21463
21616
|
queueDepth: number(),
|
|
21464
21617
|
frameLazy: FrameLazyMetricsSchema.optional()
|
|
21465
21618
|
});
|
|
21619
|
+
/**
|
|
21620
|
+
* Pipeline Runner capability — runtime detection workhorse.
|
|
21621
|
+
*
|
|
21622
|
+
* One instance per node. Receives camera assignments from
|
|
21623
|
+
* `addon-pipeline-orchestrator`, subscribes to the local stream-broker for
|
|
21624
|
+
* decoded frames, drains motion + detection queues, calls the local
|
|
21625
|
+
* `motion-detection` and `pipeline-executor` capabilities, and emits typed
|
|
21626
|
+
* `pipeline.inference-result` and `detection.motion-analysis` events on
|
|
21627
|
+
* the bus.
|
|
21628
|
+
*
|
|
21629
|
+
* Distinct from `pipeline-orchestrator` (the hub-side load balancer) — the
|
|
21630
|
+
* runner has zero knowledge of other agents, no global state, and never
|
|
21631
|
+
* makes assignment decisions itself.
|
|
21632
|
+
*/
|
|
21633
|
+
/**
|
|
21634
|
+
* Why a runner declined to look at a camera out of band. Named rather than a
|
|
21635
|
+
* bare `false`: a camera asleep on battery (D173), one attached elsewhere, one
|
|
21636
|
+
* already mid-session and one already bursting are four different facts, and a
|
|
21637
|
+
* caller told only "no" cannot tell a protection from a bug.
|
|
21638
|
+
*/
|
|
21639
|
+
var OccupancyBurstRefusalSchema = _enum([
|
|
21640
|
+
"not-attached",
|
|
21641
|
+
"battery-asleep",
|
|
21642
|
+
"not-watching",
|
|
21643
|
+
"already-bursting"
|
|
21644
|
+
]);
|
|
21466
21645
|
method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mutation" }), method(object({ deviceId: number() }), object({ success: literal(true) }), { kind: "mutation" }), method(ReportMotionInputSchema, object({ success: literal(true) }), { kind: "mutation" }), method(_void(), RunnerLocalLoadSchema), method(_void(), RunnerLocalMetricsSchema), method(object({ deviceId: number() }), CameraMetricsSchema.nullable()), method(_void(), array(CameraMetricsWithDeviceIdSchema).readonly()), method(_void(), array(number()).readonly()), method(object({
|
|
21646
|
+
deviceId: number(),
|
|
21647
|
+
/** How many frames to collect. The caller sizes this against what its
|
|
21648
|
+
* own confirmation needs; the runner clamps it to the field's range. */
|
|
21649
|
+
frames: number().int().positive().optional(),
|
|
21650
|
+
/** Why, for the log. A burst nobody can attribute is a cost nobody can
|
|
21651
|
+
* defend — the periodic one at least has a timer to point at. */
|
|
21652
|
+
reason: string()
|
|
21653
|
+
}), object({
|
|
21654
|
+
started: boolean(),
|
|
21655
|
+
refusedBecause: OccupancyBurstRefusalSchema.optional()
|
|
21656
|
+
}), {
|
|
21657
|
+
auth: "admin",
|
|
21658
|
+
kind: "mutation"
|
|
21659
|
+
}), method(object({
|
|
21467
21660
|
handle: FrameHandleSchema,
|
|
21468
21661
|
bbox: NativeCropBboxSchema,
|
|
21469
21662
|
maxWidth: number().int().positive().optional(),
|
|
@@ -27036,7 +27229,7 @@ var NativeDetectionSchema = object({
|
|
|
27036
27229
|
/** Firmware-provided confidence [0..1]. Reolink pushes don't carry it → undefined. */
|
|
27037
27230
|
confidence: number().min(0).max(1).optional()
|
|
27038
27231
|
});
|
|
27039
|
-
object({
|
|
27232
|
+
var NativeObjectDetectionStatusSchema = object({
|
|
27040
27233
|
/**
|
|
27041
27234
|
* Last observed instance per class. Missing entries mean the class
|
|
27042
27235
|
* is supported but nothing has been seen since the provider started.
|
|
@@ -27053,14 +27246,56 @@ object({
|
|
|
27053
27246
|
supportedClasses: array(NativeObjectClassEnum).readonly(),
|
|
27054
27247
|
/**
|
|
27055
27248
|
* Whether forwarding of onboard AI detections is enabled for this device.
|
|
27056
|
-
*
|
|
27057
|
-
*
|
|
27249
|
+
*
|
|
27250
|
+
* Cold-start OFF on every camera. A vendor does not decide which detector a
|
|
27251
|
+
* camera runs — that is the operator's choice, and it is made where every
|
|
27252
|
+
* other detection choice is made. `geometry` on
|
|
27253
|
+
* {@link NativeObjectDetectionOptionsSchema} is how the form says what the
|
|
27254
|
+
* choice would buy this particular camera.
|
|
27058
27255
|
*/
|
|
27059
27256
|
enabled: boolean()
|
|
27060
|
-
})
|
|
27257
|
+
});
|
|
27258
|
+
/**
|
|
27259
|
+
* WHEN a camera's onboard detections carry geometry.
|
|
27260
|
+
*
|
|
27261
|
+
* - `boxed` — always. The provider holds a standing channel for the boxes, so
|
|
27262
|
+
* a detection is a trackable subject whenever the camera sees one.
|
|
27263
|
+
* - `while-streaming` — only while some stream of this camera is already open.
|
|
27264
|
+
* The boxes ride the video's own side-channel rather than a feed of their
|
|
27265
|
+
* own, so they cost nothing and they exist only when something is pulling.
|
|
27266
|
+
* On Reolink this is every BATTERY camera: a persistent second feed is real
|
|
27267
|
+
* radio drain, but a camera that is awake is awake precisely because
|
|
27268
|
+
* something is in front of it, and its stream is already being pulled.
|
|
27269
|
+
* - `flag-only` — never. The firmware ships the class and nothing else; the
|
|
27270
|
+
* pipeline needs geometry to make a subject, so such a push reaches the
|
|
27271
|
+
* tracker as motion and no further.
|
|
27272
|
+
*
|
|
27273
|
+
* Reported and not inferred, because the operator's question in front of the
|
|
27274
|
+
* picker is "what do I get", and these are three different answers (D14: the
|
|
27275
|
+
* derived form is only as honest as `getOptions`).
|
|
27276
|
+
*/
|
|
27277
|
+
var NativeObjectGeometryEnum = _enum([
|
|
27278
|
+
"boxed",
|
|
27279
|
+
"while-streaming",
|
|
27280
|
+
"flag-only"
|
|
27281
|
+
]);
|
|
27282
|
+
var NativeObjectDetectionOptionsSchema = object({
|
|
27283
|
+
/** Classes this firmware can detect — the same list the status reports. */
|
|
27284
|
+
supportedClasses: array(NativeObjectClassEnum).readonly(),
|
|
27285
|
+
/** What a detection from this camera carries. */
|
|
27286
|
+
geometry: NativeObjectGeometryEnum
|
|
27287
|
+
});
|
|
27288
|
+
var NativeObjectDetectionSettingsPatchSchema = object({ enabled: boolean().optional() });
|
|
27289
|
+
NativeObjectDetectionStatusSchema.extend({
|
|
27061
27290
|
/** Required by createRuntimeStateBridge — epoch ms of last refresh. */
|
|
27062
27291
|
lastFetchedAt: number() });
|
|
27063
|
-
DeviceType.Camera, method(object({
|
|
27292
|
+
DeviceType.Camera, method(object({ deviceId: number() }), NativeObjectDetectionOptionsSchema), method(object({
|
|
27293
|
+
deviceId: number(),
|
|
27294
|
+
settings: NativeObjectDetectionSettingsPatchSchema
|
|
27295
|
+
}), _void(), {
|
|
27296
|
+
kind: "mutation",
|
|
27297
|
+
auth: "admin"
|
|
27298
|
+
}), method(object({
|
|
27064
27299
|
deviceId: number(),
|
|
27065
27300
|
enabled: boolean()
|
|
27066
27301
|
}), _void(), {
|
|
@@ -30901,7 +31136,28 @@ var PerScopeBreakdownSchema = object({
|
|
|
30901
31136
|
/** Total tracked objects in this scope (frame / zone / unzoned). */
|
|
30902
31137
|
totalObjects: number().int().nonnegative(),
|
|
30903
31138
|
/** Per-class count. Keys are macro class names (e.g. `person`, `car`). */
|
|
30904
|
-
byClass: record(string(), number().int().nonnegative())
|
|
31139
|
+
byClass: record(string(), number().int().nonnegative()),
|
|
31140
|
+
/**
|
|
31141
|
+
* Of `totalObjects`, how many are STANDING — objects the census holds,
|
|
31142
|
+
* present but not going anywhere (a parked car, a bin, a statue).
|
|
31143
|
+
*
|
|
31144
|
+
* The operator's question about a scene has two halves and they answer
|
|
31145
|
+
* different things: "what is parked here" is stable for hours and must not
|
|
31146
|
+
* flap, while "who is walking through" is the thing an alert is about. One
|
|
31147
|
+
* number could only serve one of them, and `totalObjects` served the first
|
|
31148
|
+
* badly — a passer-by moved it and every occupancy rule saw a change.
|
|
31149
|
+
*
|
|
31150
|
+
* `standing + transient === totalObjects`, always. The total keeps its old
|
|
31151
|
+
* meaning exactly, so no rule written against it changes behaviour.
|
|
31152
|
+
*
|
|
31153
|
+
* ABSENT means UNKNOWN, never zero (D393): a snapshot from a node older than
|
|
31154
|
+
* this field cannot say, and a reader that folds absence in as 0 reports "no
|
|
31155
|
+
* parked objects here" about a camera whose lot is full.
|
|
31156
|
+
*/
|
|
31157
|
+
standingObjects: number().int().nonnegative().optional(),
|
|
31158
|
+
/** Of `totalObjects`, how many are passing through. See `standingObjects` —
|
|
31159
|
+
* same absence rule. */
|
|
31160
|
+
transientObjects: number().int().nonnegative().optional()
|
|
30905
31161
|
});
|
|
30906
31162
|
var ZoneScopeBreakdownSchema = PerScopeBreakdownSchema.extend({
|
|
30907
31163
|
zoneId: string(),
|
|
@@ -34666,12 +34922,24 @@ Object.freeze({
|
|
|
34666
34922
|
addonId: null,
|
|
34667
34923
|
access: "create"
|
|
34668
34924
|
},
|
|
34925
|
+
"nativeObjectDetection.getOptions": {
|
|
34926
|
+
capName: "native-object-detection",
|
|
34927
|
+
capScope: "device",
|
|
34928
|
+
addonId: null,
|
|
34929
|
+
access: "view"
|
|
34930
|
+
},
|
|
34669
34931
|
"nativeObjectDetection.setEnabled": {
|
|
34670
34932
|
capName: "native-object-detection",
|
|
34671
34933
|
capScope: "device",
|
|
34672
34934
|
addonId: null,
|
|
34673
34935
|
access: "create"
|
|
34674
34936
|
},
|
|
34937
|
+
"nativeObjectDetection.setSettings": {
|
|
34938
|
+
capName: "native-object-detection",
|
|
34939
|
+
capScope: "device",
|
|
34940
|
+
addonId: null,
|
|
34941
|
+
access: "create"
|
|
34942
|
+
},
|
|
34675
34943
|
"navigation.getFeatures": {
|
|
34676
34944
|
capName: "navigation",
|
|
34677
34945
|
capScope: "device",
|
|
@@ -34936,6 +35204,12 @@ Object.freeze({
|
|
|
34936
35204
|
addonId: null,
|
|
34937
35205
|
access: "view"
|
|
34938
35206
|
},
|
|
35207
|
+
"notificationRules.getClipRetentionAsks": {
|
|
35208
|
+
capName: "notification-rules",
|
|
35209
|
+
capScope: "system",
|
|
35210
|
+
addonId: null,
|
|
35211
|
+
access: "view"
|
|
35212
|
+
},
|
|
34939
35213
|
"notificationRules.getConditionCatalog": {
|
|
34940
35214
|
capName: "notification-rules",
|
|
34941
35215
|
capScope: "system",
|
|
@@ -35446,6 +35720,12 @@ Object.freeze({
|
|
|
35446
35720
|
addonId: null,
|
|
35447
35721
|
access: "create"
|
|
35448
35722
|
},
|
|
35723
|
+
"pipelineAnalytics.readLongTermSeries": {
|
|
35724
|
+
capName: "pipeline-analytics",
|
|
35725
|
+
capScope: "device",
|
|
35726
|
+
addonId: null,
|
|
35727
|
+
access: "view"
|
|
35728
|
+
},
|
|
35449
35729
|
"pipelineAnalytics.rebuildObjectEmbeddings": {
|
|
35450
35730
|
capName: "pipeline-analytics",
|
|
35451
35731
|
capScope: "device",
|
|
@@ -36118,6 +36398,12 @@ Object.freeze({
|
|
|
36118
36398
|
addonId: null,
|
|
36119
36399
|
access: "create"
|
|
36120
36400
|
},
|
|
36401
|
+
"pipelineRunner.requestOccupancyBurst": {
|
|
36402
|
+
capName: "pipeline-runner",
|
|
36403
|
+
capScope: "system",
|
|
36404
|
+
addonId: null,
|
|
36405
|
+
access: "create"
|
|
36406
|
+
},
|
|
36121
36407
|
"pipelineRunner.runDetailSubtree": {
|
|
36122
36408
|
capName: "pipeline-runner",
|
|
36123
36409
|
capScope: "system",
|
|
@@ -38898,11 +39184,21 @@ Object.freeze({
|
|
|
38898
39184
|
form: "single",
|
|
38899
39185
|
optional: false
|
|
38900
39186
|
}],
|
|
39187
|
+
"nativeObjectDetection.getOptions": [{
|
|
39188
|
+
name: "deviceId",
|
|
39189
|
+
form: "single",
|
|
39190
|
+
optional: false
|
|
39191
|
+
}],
|
|
38901
39192
|
"nativeObjectDetection.setEnabled": [{
|
|
38902
39193
|
name: "deviceId",
|
|
38903
39194
|
form: "single",
|
|
38904
39195
|
optional: false
|
|
38905
39196
|
}],
|
|
39197
|
+
"nativeObjectDetection.setSettings": [{
|
|
39198
|
+
name: "deviceId",
|
|
39199
|
+
form: "single",
|
|
39200
|
+
optional: false
|
|
39201
|
+
}],
|
|
38906
39202
|
"navigation.getFeatures": [{
|
|
38907
39203
|
name: "deviceId",
|
|
38908
39204
|
form: "single",
|
|
@@ -39252,6 +39548,11 @@ Object.freeze({
|
|
|
39252
39548
|
form: "single",
|
|
39253
39549
|
optional: false
|
|
39254
39550
|
}],
|
|
39551
|
+
"pipelineAnalytics.readLongTermSeries": [{
|
|
39552
|
+
name: "deviceId",
|
|
39553
|
+
form: "single",
|
|
39554
|
+
optional: false
|
|
39555
|
+
}],
|
|
39255
39556
|
"pipelineAnalytics.rebuildObjectEmbeddings": [{
|
|
39256
39557
|
name: "deviceId",
|
|
39257
39558
|
form: "single",
|
|
@@ -39442,6 +39743,11 @@ Object.freeze({
|
|
|
39442
39743
|
form: "single",
|
|
39443
39744
|
optional: false
|
|
39444
39745
|
}],
|
|
39746
|
+
"pipelineRunner.requestOccupancyBurst": [{
|
|
39747
|
+
name: "deviceId",
|
|
39748
|
+
form: "single",
|
|
39749
|
+
optional: false
|
|
39750
|
+
}],
|
|
39445
39751
|
"pipelineRunner.runDetailSubtree": [{
|
|
39446
39752
|
name: "deviceId",
|
|
39447
39753
|
form: "single",
|
package/dist/addon.mjs
CHANGED
|
@@ -5364,7 +5364,7 @@ var ZodIssueCode = {
|
|
|
5364
5364
|
var ZodFirstPartyTypeKind;
|
|
5365
5365
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5366
5366
|
//#endregion
|
|
5367
|
-
//#region ../types/dist/sleep-
|
|
5367
|
+
//#region ../types/dist/sleep-BDR76Ykr.mjs
|
|
5368
5368
|
/**
|
|
5369
5369
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5370
5370
|
* window to float samples (D455).
|
|
@@ -17915,6 +17915,48 @@ var NcAlarmConfigSchema = object({
|
|
|
17915
17915
|
settings: NcAlarmSettingsSchema,
|
|
17916
17916
|
coverage: array(NcAlarmModeCoverageSchema)
|
|
17917
17917
|
});
|
|
17918
|
+
/**
|
|
17919
|
+
* ONE rule's demand on ONE camera's clip ring.
|
|
17920
|
+
*
|
|
17921
|
+
* A rule, not a camera: the broker takes the MAX over the asks that reach a
|
|
17922
|
+
* camera, so the answer stays a faithful description of the rules and the
|
|
17923
|
+
* bounding (the byte budget, the broker's own ceiling) stays where the cost
|
|
17924
|
+
* lives. A camera that appears in no ask is being told **nothing** — which is
|
|
17925
|
+
* a different thing from never having been told, and only the envelope
|
|
17926
|
+
* (`rulesLoaded`) can tell those apart.
|
|
17927
|
+
*/
|
|
17928
|
+
var NcClipRetentionAskSchema = object({
|
|
17929
|
+
/**
|
|
17930
|
+
* The camera this ask is about. **Absent = every camera**, which is what a
|
|
17931
|
+
* rule with no `conditions.devices` means: it can fire anywhere, so it is
|
|
17932
|
+
* asking everywhere.
|
|
17933
|
+
*/
|
|
17934
|
+
deviceId: number().int().nonnegative().optional(),
|
|
17935
|
+
/** Seconds of history the rule needs held for it. Never zero — a rule that
|
|
17936
|
+
* needs nothing produces no ask at all. */
|
|
17937
|
+
seconds: number().min(0).max(60),
|
|
17938
|
+
/** The profile the rule cuts from, when it named one. Absent = the cheapest
|
|
17939
|
+
* assigned, which is what the cut defaults to. */
|
|
17940
|
+
profile: CamProfileSchema.optional(),
|
|
17941
|
+
/** Who is asking — so a retention the operator did not expect names a rule. */
|
|
17942
|
+
ruleId: string(),
|
|
17943
|
+
ruleName: string(),
|
|
17944
|
+
/** Why this many seconds: the rule's own window, or the occupancy ceiling. */
|
|
17945
|
+
reason: _enum(["window", "occupancy"])
|
|
17946
|
+
});
|
|
17947
|
+
/**
|
|
17948
|
+
* The whole answer, with the one bit that keeps absence from reading as zero.
|
|
17949
|
+
*
|
|
17950
|
+
* `rulesLoaded` is false until the rule ledger has completed a load at least
|
|
17951
|
+
* once. A centre that is up but has not read its rules yet answers with an
|
|
17952
|
+
* empty ask list that means nothing at all — applying it would drop every
|
|
17953
|
+
* camera's ring to zero for the first events after a restart, which is the
|
|
17954
|
+
* footage this mechanism exists to keep.
|
|
17955
|
+
*/
|
|
17956
|
+
var NcClipRetentionPlanSchema = object({
|
|
17957
|
+
rulesLoaded: boolean(),
|
|
17958
|
+
asks: array(NcClipRetentionAskSchema).readonly()
|
|
17959
|
+
});
|
|
17918
17960
|
method(object({}), object({ rules: array(NcRuleSchema) }), { auth: "admin" }), method(object({ ruleId: string() }), object({ rule: NcRuleSchema.nullable() }), { auth: "admin" }), method(object({ rule: NcRuleInputSchema }), object({ rule: NcRuleSchema }), {
|
|
17919
17961
|
kind: "mutation",
|
|
17920
17962
|
auth: "admin",
|
|
@@ -17935,7 +17977,7 @@ method(object({}), object({ rules: array(NcRuleSchema) }), { auth: "admin" }), m
|
|
|
17935
17977
|
}), object({ success: literal(true) }), {
|
|
17936
17978
|
kind: "mutation",
|
|
17937
17979
|
auth: "admin"
|
|
17938
|
-
}), method(object({}), object({ mutedDeviceIds: array(number().int()).readonly() }), { auth: "admin" }), method(object({
|
|
17980
|
+
}), method(object({}), NcClipRetentionPlanSchema, { auth: "admin" }), method(object({}), object({ mutedDeviceIds: array(number().int()).readonly() }), { auth: "admin" }), method(object({
|
|
17939
17981
|
deviceId: number().int(),
|
|
17940
17982
|
muted: boolean()
|
|
17941
17983
|
}), object({ success: literal(true) }), {
|
|
@@ -19080,13 +19122,26 @@ var TrackAudioLabelSchema = object({
|
|
|
19080
19122
|
* - `audio` — an audio event on the camera itself that was anomalous for
|
|
19081
19123
|
* THAT camera, loud, and heard while nothing visual was happening (D62).
|
|
19082
19124
|
*
|
|
19125
|
+
* - `onboard` — the CAMERA's own firmware, paired with a decoded frame in
|
|
19126
|
+
* that frame's pixel space. A real root detector and a SPATIAL one: its
|
|
19127
|
+
* boxes are the same kind of fact `pipeline`'s are, produced by a different
|
|
19128
|
+
* detector.
|
|
19129
|
+
*
|
|
19130
|
+
* `onboard` was missing here while `DetectionSourceSchema` already had it, so
|
|
19131
|
+
* a persisted onboard track failed `safeParse` on read and came back with NO
|
|
19132
|
+
* source at all — which `isSpatialTrack` then admitted by accident, through the
|
|
19133
|
+
* `undefined` arm rather than by anybody's decision, and which `excludeSources`
|
|
19134
|
+
* could not name.
|
|
19135
|
+
*
|
|
19083
19136
|
* The spatial subsystems (tracker association, occupancy count, re-id /
|
|
19084
19137
|
* embedding, resurrection) MUST skip every synthetic source. Test for that
|
|
19085
|
-
* with `isSpatialTrack`, which allow-lists
|
|
19086
|
-
* check silently readmits every source added after it was
|
|
19138
|
+
* with `isSpatialTrack`, which allow-lists the spatial sources explicitly — a
|
|
19139
|
+
* `!== 'sensor'` check silently readmits every source added after it was
|
|
19140
|
+
* written.
|
|
19087
19141
|
*/
|
|
19088
19142
|
var TrackSourceSchema = _enum([
|
|
19089
19143
|
"pipeline",
|
|
19144
|
+
"onboard",
|
|
19090
19145
|
"sensor",
|
|
19091
19146
|
"audio"
|
|
19092
19147
|
]);
|
|
@@ -20469,6 +20524,33 @@ var RunReplayFrameProcessorResultSchema = object({ tracks: array(object({
|
|
|
20469
20524
|
* solid is this track", cheaper than re-deriving it from a trajectory. */
|
|
20470
20525
|
framesMatched: number().int()
|
|
20471
20526
|
})).readonly() });
|
|
20527
|
+
/**
|
|
20528
|
+
* The long-term series a camera produces. A closed union so a typo cannot
|
|
20529
|
+
* invent one, and the ONE declaration of it — the addon's `AnalyticsLtsSeries`
|
|
20530
|
+
* is an alias of this, not a second list.
|
|
20531
|
+
*/
|
|
20532
|
+
var AnalyticsLtsSeriesSchema = _enum([
|
|
20533
|
+
"motion",
|
|
20534
|
+
"audio-dbfs",
|
|
20535
|
+
"battery",
|
|
20536
|
+
"occupancy"
|
|
20537
|
+
]);
|
|
20538
|
+
/**
|
|
20539
|
+
* One closed 5-minute bucket of a long-term series.
|
|
20540
|
+
*
|
|
20541
|
+
* `samples` is how many readings the bucket folded — it is the ACTIVITY for a
|
|
20542
|
+
* series like `motion`, and the confidence for one like `occupancy`. A bucket
|
|
20543
|
+
* that exists at all was measured; a bucket that is absent was not, which is a
|
|
20544
|
+
* different claim from zero and the reason this is a sparse series.
|
|
20545
|
+
*/
|
|
20546
|
+
var LtsBucketSchema = object({
|
|
20547
|
+
scope: string(),
|
|
20548
|
+
bucketStart: number().int(),
|
|
20549
|
+
samples: number().int().nonnegative(),
|
|
20550
|
+
sum: number(),
|
|
20551
|
+
min: number(),
|
|
20552
|
+
max: number()
|
|
20553
|
+
});
|
|
20472
20554
|
DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).readonly()), method(object({
|
|
20473
20555
|
deviceId: number(),
|
|
20474
20556
|
trackId: string()
|
|
@@ -20515,6 +20597,14 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
|
|
|
20515
20597
|
kinds: array(string()).optional(),
|
|
20516
20598
|
limit: number().int().min(1).max(MAX_EVENT_QUERY_LIMIT).default(DEFAULT_EVENT_QUERY_LIMIT)
|
|
20517
20599
|
}), array(SensorEventSchema).readonly()), method(KeyEventQueryInput, array(KeyEventSchema).readonly()), method(KeyEventBatchQueryInput, array(KeyEventsForDeviceSchema).readonly()), method(object({
|
|
20600
|
+
deviceId: number(),
|
|
20601
|
+
series: AnalyticsLtsSeriesSchema,
|
|
20602
|
+
/** Omit for EVERY scope of this series in the range. */
|
|
20603
|
+
scope: string().optional(),
|
|
20604
|
+
from: number(),
|
|
20605
|
+
to: number(),
|
|
20606
|
+
limit: number().int().positive().optional()
|
|
20607
|
+
}), array(LtsBucketSchema).readonly()), method(object({
|
|
20518
20608
|
deviceId: number(),
|
|
20519
20609
|
since: number(),
|
|
20520
20610
|
until: number(),
|
|
@@ -21133,6 +21223,40 @@ var MotionSourceEnum = _enum([
|
|
|
21133
21223
|
*/
|
|
21134
21224
|
var MotionSourcesSchema = array(MotionSourceEnum);
|
|
21135
21225
|
/**
|
|
21226
|
+
* Which root detector a camera runs — EXACTLY ONE.
|
|
21227
|
+
*
|
|
21228
|
+
* Deliberately the SAME vocabulary post-analysis already tags every detection
|
|
21229
|
+
* with (`DetectionSource`) rather than a second spelling of the same two
|
|
21230
|
+
* ideas: the value an operator picks here is the value that comes back on the
|
|
21231
|
+
* track, the overlay and the debug row.
|
|
21232
|
+
*
|
|
21233
|
+
* ## Why one, and why it is still an array
|
|
21234
|
+
*
|
|
21235
|
+
* Two roots on one camera is a capability nobody asked for and the operator has
|
|
21236
|
+
* since ruled out. It was never free: both planes feed the SAME per-device
|
|
21237
|
+
* stationary registry, both can promote the same parked object, and the two
|
|
21238
|
+
* detectors disagree about the same box by construction — which is the
|
|
21239
|
+
* disagreement D505 had to arbitrate. Removing the case removes the arbitration.
|
|
21240
|
+
*
|
|
21241
|
+
* The ARRAY shape survives because the stored settings and the attach payload
|
|
21242
|
+
* already speak it on every camera of every fleet, and a cap input that
|
|
21243
|
+
* suddenly refuses a stored value makes the camera un-attachable — a fail-closed
|
|
21244
|
+
* in the one direction that costs an operator their cameras. So the wire stays
|
|
21245
|
+
* tolerant and the TYPE is exact: a longer list is truncated to its first
|
|
21246
|
+
* element rather than refused, and `max(1)` is what every consumer can then
|
|
21247
|
+
* rely on.
|
|
21248
|
+
*
|
|
21249
|
+
* AT MOST one, not exactly one. The EMPTY list is a legal, deliberate pick —
|
|
21250
|
+
* a camera an operator left with no root detector — and `planDetectionSources`
|
|
21251
|
+
* has always said so: inventing a root for them is how a default acts without
|
|
21252
|
+
* anybody choosing it. Tightening this to `length(1)` broke that, and the
|
|
21253
|
+
* suite caught it.
|
|
21254
|
+
*
|
|
21255
|
+
* Measured before tightening (2026-09-15, this fleet, 6 h of attaches): 3327
|
|
21256
|
+
* `["pipeline"]` and 2 `["onboard"]`. Not one camera had two.
|
|
21257
|
+
*/
|
|
21258
|
+
var DetectionSourcesSchema = preprocess((value) => Array.isArray(value) && value.length > 1 ? value.slice(0, 1) : value, array(DetectionSourceSchema).max(1));
|
|
21259
|
+
/**
|
|
21136
21260
|
* Input shape for `pipeline-runner.reportMotion` cap method. Exported
|
|
21137
21261
|
* so cap-side consumers (the orchestrator forward, the runner addon's
|
|
21138
21262
|
* cap implementation, tests) can reuse the type instead of redeclaring
|
|
@@ -21283,6 +21407,35 @@ var RunnerCameraConfigSchema = object({
|
|
|
21283
21407
|
* events; the orchestrator forwards to `reportMotion`.
|
|
21284
21408
|
*/
|
|
21285
21409
|
motionSources: MotionSourcesSchema.default(["analyzer"]),
|
|
21410
|
+
/**
|
|
21411
|
+
* WHICH root detector runs for this camera. The detection counterpart of
|
|
21412
|
+
* {@link motionSources}, same shape and same discipline: a per-camera list
|
|
21413
|
+
* of sources the system understands, vendor-agnostic, owned here.
|
|
21414
|
+
*
|
|
21415
|
+
* - `pipeline` — this runner's own root step on decoded pixels (`steps`).
|
|
21416
|
+
* - `onboard` — the CAMERA's own detector, admitted only when it is named
|
|
21417
|
+
* here. Its boxes reach post-analysis on the same
|
|
21418
|
+
* `PipelineInferenceResult` payload as the pipeline's, so an onboard-born
|
|
21419
|
+
* track gets the same tracker, the same overlay and the same detail
|
|
21420
|
+
* subtree (face / plate / embedding).
|
|
21421
|
+
*
|
|
21422
|
+
* `['onboard']` alone is the REPLACEMENT: this runner's root step does not
|
|
21423
|
+
* run, and that is where a camera with a usable onboard detector buys back
|
|
21424
|
+
* its share of the accelerator. It saves the root inference, not the decode
|
|
21425
|
+
* — the detail subtree still needs pixels to cut crops from.
|
|
21426
|
+
*
|
|
21427
|
+
* A camera whose onboard detections carry no geometry cannot serve as a root
|
|
21428
|
+
* step at all (there is nothing to track), and the cap that knows this says
|
|
21429
|
+
* so on `native-object-detection.getOptions().geometry`. On Reolink that is
|
|
21430
|
+
* every battery camera: the boxes ride a sub-stream a battery camera never
|
|
21431
|
+
* attaches, so such a camera stays on `['pipeline']` and its onboard AI is
|
|
21432
|
+
* worth exactly what it already is — a wake signal with a class.
|
|
21433
|
+
*
|
|
21434
|
+
* Defaults to `['pipeline']`, which is byte-for-byte today's behaviour: a
|
|
21435
|
+
* vendor never turns a detector on for the operator, and neither does a
|
|
21436
|
+
* default.
|
|
21437
|
+
*/
|
|
21438
|
+
detectionSources: DetectionSourcesSchema.default(["pipeline"]),
|
|
21286
21439
|
pipelineEnabled: boolean().default(true),
|
|
21287
21440
|
/** Ordered tree of video steps. Absent → runner skips video detection. */
|
|
21288
21441
|
steps: array(PipelineStepInputSchema).readonly().optional(),
|
|
@@ -21464,7 +21617,47 @@ var RunnerLocalMetricsSchema = object({
|
|
|
21464
21617
|
queueDepth: number(),
|
|
21465
21618
|
frameLazy: FrameLazyMetricsSchema.optional()
|
|
21466
21619
|
});
|
|
21620
|
+
/**
|
|
21621
|
+
* Pipeline Runner capability — runtime detection workhorse.
|
|
21622
|
+
*
|
|
21623
|
+
* One instance per node. Receives camera assignments from
|
|
21624
|
+
* `addon-pipeline-orchestrator`, subscribes to the local stream-broker for
|
|
21625
|
+
* decoded frames, drains motion + detection queues, calls the local
|
|
21626
|
+
* `motion-detection` and `pipeline-executor` capabilities, and emits typed
|
|
21627
|
+
* `pipeline.inference-result` and `detection.motion-analysis` events on
|
|
21628
|
+
* the bus.
|
|
21629
|
+
*
|
|
21630
|
+
* Distinct from `pipeline-orchestrator` (the hub-side load balancer) — the
|
|
21631
|
+
* runner has zero knowledge of other agents, no global state, and never
|
|
21632
|
+
* makes assignment decisions itself.
|
|
21633
|
+
*/
|
|
21634
|
+
/**
|
|
21635
|
+
* Why a runner declined to look at a camera out of band. Named rather than a
|
|
21636
|
+
* bare `false`: a camera asleep on battery (D173), one attached elsewhere, one
|
|
21637
|
+
* already mid-session and one already bursting are four different facts, and a
|
|
21638
|
+
* caller told only "no" cannot tell a protection from a bug.
|
|
21639
|
+
*/
|
|
21640
|
+
var OccupancyBurstRefusalSchema = _enum([
|
|
21641
|
+
"not-attached",
|
|
21642
|
+
"battery-asleep",
|
|
21643
|
+
"not-watching",
|
|
21644
|
+
"already-bursting"
|
|
21645
|
+
]);
|
|
21467
21646
|
method(RunnerCameraConfigSchema, object({ success: literal(true) }), { kind: "mutation" }), method(object({ deviceId: number() }), object({ success: literal(true) }), { kind: "mutation" }), method(ReportMotionInputSchema, object({ success: literal(true) }), { kind: "mutation" }), method(_void(), RunnerLocalLoadSchema), method(_void(), RunnerLocalMetricsSchema), method(object({ deviceId: number() }), CameraMetricsSchema.nullable()), method(_void(), array(CameraMetricsWithDeviceIdSchema).readonly()), method(_void(), array(number()).readonly()), method(object({
|
|
21647
|
+
deviceId: number(),
|
|
21648
|
+
/** How many frames to collect. The caller sizes this against what its
|
|
21649
|
+
* own confirmation needs; the runner clamps it to the field's range. */
|
|
21650
|
+
frames: number().int().positive().optional(),
|
|
21651
|
+
/** Why, for the log. A burst nobody can attribute is a cost nobody can
|
|
21652
|
+
* defend — the periodic one at least has a timer to point at. */
|
|
21653
|
+
reason: string()
|
|
21654
|
+
}), object({
|
|
21655
|
+
started: boolean(),
|
|
21656
|
+
refusedBecause: OccupancyBurstRefusalSchema.optional()
|
|
21657
|
+
}), {
|
|
21658
|
+
auth: "admin",
|
|
21659
|
+
kind: "mutation"
|
|
21660
|
+
}), method(object({
|
|
21468
21661
|
handle: FrameHandleSchema,
|
|
21469
21662
|
bbox: NativeCropBboxSchema,
|
|
21470
21663
|
maxWidth: number().int().positive().optional(),
|
|
@@ -27037,7 +27230,7 @@ var NativeDetectionSchema = object({
|
|
|
27037
27230
|
/** Firmware-provided confidence [0..1]. Reolink pushes don't carry it → undefined. */
|
|
27038
27231
|
confidence: number().min(0).max(1).optional()
|
|
27039
27232
|
});
|
|
27040
|
-
object({
|
|
27233
|
+
var NativeObjectDetectionStatusSchema = object({
|
|
27041
27234
|
/**
|
|
27042
27235
|
* Last observed instance per class. Missing entries mean the class
|
|
27043
27236
|
* is supported but nothing has been seen since the provider started.
|
|
@@ -27054,14 +27247,56 @@ object({
|
|
|
27054
27247
|
supportedClasses: array(NativeObjectClassEnum).readonly(),
|
|
27055
27248
|
/**
|
|
27056
27249
|
* Whether forwarding of onboard AI detections is enabled for this device.
|
|
27057
|
-
*
|
|
27058
|
-
*
|
|
27250
|
+
*
|
|
27251
|
+
* Cold-start OFF on every camera. A vendor does not decide which detector a
|
|
27252
|
+
* camera runs — that is the operator's choice, and it is made where every
|
|
27253
|
+
* other detection choice is made. `geometry` on
|
|
27254
|
+
* {@link NativeObjectDetectionOptionsSchema} is how the form says what the
|
|
27255
|
+
* choice would buy this particular camera.
|
|
27059
27256
|
*/
|
|
27060
27257
|
enabled: boolean()
|
|
27061
|
-
})
|
|
27258
|
+
});
|
|
27259
|
+
/**
|
|
27260
|
+
* WHEN a camera's onboard detections carry geometry.
|
|
27261
|
+
*
|
|
27262
|
+
* - `boxed` — always. The provider holds a standing channel for the boxes, so
|
|
27263
|
+
* a detection is a trackable subject whenever the camera sees one.
|
|
27264
|
+
* - `while-streaming` — only while some stream of this camera is already open.
|
|
27265
|
+
* The boxes ride the video's own side-channel rather than a feed of their
|
|
27266
|
+
* own, so they cost nothing and they exist only when something is pulling.
|
|
27267
|
+
* On Reolink this is every BATTERY camera: a persistent second feed is real
|
|
27268
|
+
* radio drain, but a camera that is awake is awake precisely because
|
|
27269
|
+
* something is in front of it, and its stream is already being pulled.
|
|
27270
|
+
* - `flag-only` — never. The firmware ships the class and nothing else; the
|
|
27271
|
+
* pipeline needs geometry to make a subject, so such a push reaches the
|
|
27272
|
+
* tracker as motion and no further.
|
|
27273
|
+
*
|
|
27274
|
+
* Reported and not inferred, because the operator's question in front of the
|
|
27275
|
+
* picker is "what do I get", and these are three different answers (D14: the
|
|
27276
|
+
* derived form is only as honest as `getOptions`).
|
|
27277
|
+
*/
|
|
27278
|
+
var NativeObjectGeometryEnum = _enum([
|
|
27279
|
+
"boxed",
|
|
27280
|
+
"while-streaming",
|
|
27281
|
+
"flag-only"
|
|
27282
|
+
]);
|
|
27283
|
+
var NativeObjectDetectionOptionsSchema = object({
|
|
27284
|
+
/** Classes this firmware can detect — the same list the status reports. */
|
|
27285
|
+
supportedClasses: array(NativeObjectClassEnum).readonly(),
|
|
27286
|
+
/** What a detection from this camera carries. */
|
|
27287
|
+
geometry: NativeObjectGeometryEnum
|
|
27288
|
+
});
|
|
27289
|
+
var NativeObjectDetectionSettingsPatchSchema = object({ enabled: boolean().optional() });
|
|
27290
|
+
NativeObjectDetectionStatusSchema.extend({
|
|
27062
27291
|
/** Required by createRuntimeStateBridge — epoch ms of last refresh. */
|
|
27063
27292
|
lastFetchedAt: number() });
|
|
27064
|
-
DeviceType.Camera, method(object({
|
|
27293
|
+
DeviceType.Camera, method(object({ deviceId: number() }), NativeObjectDetectionOptionsSchema), method(object({
|
|
27294
|
+
deviceId: number(),
|
|
27295
|
+
settings: NativeObjectDetectionSettingsPatchSchema
|
|
27296
|
+
}), _void(), {
|
|
27297
|
+
kind: "mutation",
|
|
27298
|
+
auth: "admin"
|
|
27299
|
+
}), method(object({
|
|
27065
27300
|
deviceId: number(),
|
|
27066
27301
|
enabled: boolean()
|
|
27067
27302
|
}), _void(), {
|
|
@@ -30902,7 +31137,28 @@ var PerScopeBreakdownSchema = object({
|
|
|
30902
31137
|
/** Total tracked objects in this scope (frame / zone / unzoned). */
|
|
30903
31138
|
totalObjects: number().int().nonnegative(),
|
|
30904
31139
|
/** Per-class count. Keys are macro class names (e.g. `person`, `car`). */
|
|
30905
|
-
byClass: record(string(), number().int().nonnegative())
|
|
31140
|
+
byClass: record(string(), number().int().nonnegative()),
|
|
31141
|
+
/**
|
|
31142
|
+
* Of `totalObjects`, how many are STANDING — objects the census holds,
|
|
31143
|
+
* present but not going anywhere (a parked car, a bin, a statue).
|
|
31144
|
+
*
|
|
31145
|
+
* The operator's question about a scene has two halves and they answer
|
|
31146
|
+
* different things: "what is parked here" is stable for hours and must not
|
|
31147
|
+
* flap, while "who is walking through" is the thing an alert is about. One
|
|
31148
|
+
* number could only serve one of them, and `totalObjects` served the first
|
|
31149
|
+
* badly — a passer-by moved it and every occupancy rule saw a change.
|
|
31150
|
+
*
|
|
31151
|
+
* `standing + transient === totalObjects`, always. The total keeps its old
|
|
31152
|
+
* meaning exactly, so no rule written against it changes behaviour.
|
|
31153
|
+
*
|
|
31154
|
+
* ABSENT means UNKNOWN, never zero (D393): a snapshot from a node older than
|
|
31155
|
+
* this field cannot say, and a reader that folds absence in as 0 reports "no
|
|
31156
|
+
* parked objects here" about a camera whose lot is full.
|
|
31157
|
+
*/
|
|
31158
|
+
standingObjects: number().int().nonnegative().optional(),
|
|
31159
|
+
/** Of `totalObjects`, how many are passing through. See `standingObjects` —
|
|
31160
|
+
* same absence rule. */
|
|
31161
|
+
transientObjects: number().int().nonnegative().optional()
|
|
30906
31162
|
});
|
|
30907
31163
|
var ZoneScopeBreakdownSchema = PerScopeBreakdownSchema.extend({
|
|
30908
31164
|
zoneId: string(),
|
|
@@ -34667,12 +34923,24 @@ Object.freeze({
|
|
|
34667
34923
|
addonId: null,
|
|
34668
34924
|
access: "create"
|
|
34669
34925
|
},
|
|
34926
|
+
"nativeObjectDetection.getOptions": {
|
|
34927
|
+
capName: "native-object-detection",
|
|
34928
|
+
capScope: "device",
|
|
34929
|
+
addonId: null,
|
|
34930
|
+
access: "view"
|
|
34931
|
+
},
|
|
34670
34932
|
"nativeObjectDetection.setEnabled": {
|
|
34671
34933
|
capName: "native-object-detection",
|
|
34672
34934
|
capScope: "device",
|
|
34673
34935
|
addonId: null,
|
|
34674
34936
|
access: "create"
|
|
34675
34937
|
},
|
|
34938
|
+
"nativeObjectDetection.setSettings": {
|
|
34939
|
+
capName: "native-object-detection",
|
|
34940
|
+
capScope: "device",
|
|
34941
|
+
addonId: null,
|
|
34942
|
+
access: "create"
|
|
34943
|
+
},
|
|
34676
34944
|
"navigation.getFeatures": {
|
|
34677
34945
|
capName: "navigation",
|
|
34678
34946
|
capScope: "device",
|
|
@@ -34937,6 +35205,12 @@ Object.freeze({
|
|
|
34937
35205
|
addonId: null,
|
|
34938
35206
|
access: "view"
|
|
34939
35207
|
},
|
|
35208
|
+
"notificationRules.getClipRetentionAsks": {
|
|
35209
|
+
capName: "notification-rules",
|
|
35210
|
+
capScope: "system",
|
|
35211
|
+
addonId: null,
|
|
35212
|
+
access: "view"
|
|
35213
|
+
},
|
|
34940
35214
|
"notificationRules.getConditionCatalog": {
|
|
34941
35215
|
capName: "notification-rules",
|
|
34942
35216
|
capScope: "system",
|
|
@@ -35447,6 +35721,12 @@ Object.freeze({
|
|
|
35447
35721
|
addonId: null,
|
|
35448
35722
|
access: "create"
|
|
35449
35723
|
},
|
|
35724
|
+
"pipelineAnalytics.readLongTermSeries": {
|
|
35725
|
+
capName: "pipeline-analytics",
|
|
35726
|
+
capScope: "device",
|
|
35727
|
+
addonId: null,
|
|
35728
|
+
access: "view"
|
|
35729
|
+
},
|
|
35450
35730
|
"pipelineAnalytics.rebuildObjectEmbeddings": {
|
|
35451
35731
|
capName: "pipeline-analytics",
|
|
35452
35732
|
capScope: "device",
|
|
@@ -36119,6 +36399,12 @@ Object.freeze({
|
|
|
36119
36399
|
addonId: null,
|
|
36120
36400
|
access: "create"
|
|
36121
36401
|
},
|
|
36402
|
+
"pipelineRunner.requestOccupancyBurst": {
|
|
36403
|
+
capName: "pipeline-runner",
|
|
36404
|
+
capScope: "system",
|
|
36405
|
+
addonId: null,
|
|
36406
|
+
access: "create"
|
|
36407
|
+
},
|
|
36122
36408
|
"pipelineRunner.runDetailSubtree": {
|
|
36123
36409
|
capName: "pipeline-runner",
|
|
36124
36410
|
capScope: "system",
|
|
@@ -38899,11 +39185,21 @@ Object.freeze({
|
|
|
38899
39185
|
form: "single",
|
|
38900
39186
|
optional: false
|
|
38901
39187
|
}],
|
|
39188
|
+
"nativeObjectDetection.getOptions": [{
|
|
39189
|
+
name: "deviceId",
|
|
39190
|
+
form: "single",
|
|
39191
|
+
optional: false
|
|
39192
|
+
}],
|
|
38902
39193
|
"nativeObjectDetection.setEnabled": [{
|
|
38903
39194
|
name: "deviceId",
|
|
38904
39195
|
form: "single",
|
|
38905
39196
|
optional: false
|
|
38906
39197
|
}],
|
|
39198
|
+
"nativeObjectDetection.setSettings": [{
|
|
39199
|
+
name: "deviceId",
|
|
39200
|
+
form: "single",
|
|
39201
|
+
optional: false
|
|
39202
|
+
}],
|
|
38907
39203
|
"navigation.getFeatures": [{
|
|
38908
39204
|
name: "deviceId",
|
|
38909
39205
|
form: "single",
|
|
@@ -39253,6 +39549,11 @@ Object.freeze({
|
|
|
39253
39549
|
form: "single",
|
|
39254
39550
|
optional: false
|
|
39255
39551
|
}],
|
|
39552
|
+
"pipelineAnalytics.readLongTermSeries": [{
|
|
39553
|
+
name: "deviceId",
|
|
39554
|
+
form: "single",
|
|
39555
|
+
optional: false
|
|
39556
|
+
}],
|
|
39256
39557
|
"pipelineAnalytics.rebuildObjectEmbeddings": [{
|
|
39257
39558
|
name: "deviceId",
|
|
39258
39559
|
form: "single",
|
|
@@ -39443,6 +39744,11 @@ Object.freeze({
|
|
|
39443
39744
|
form: "single",
|
|
39444
39745
|
optional: false
|
|
39445
39746
|
}],
|
|
39747
|
+
"pipelineRunner.requestOccupancyBurst": [{
|
|
39748
|
+
name: "deviceId",
|
|
39749
|
+
form: "single",
|
|
39750
|
+
optional: false
|
|
39751
|
+
}],
|
|
39446
39752
|
"pipelineRunner.runDetailSubtree": [{
|
|
39447
39753
|
name: "deviceId",
|
|
39448
39754
|
form: "single",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@camstack/addon-provider-onvif",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.103",
|
|
4
4
|
"description": "ONVIF camera device provider addon for CamStack",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"camstack",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"build": "vite build",
|
|
61
61
|
"dev": "vite build --watch",
|
|
62
62
|
"typecheck": "tsc --noEmit",
|
|
63
|
-
"publish": "npm publish --access public"
|
|
63
|
+
"publish:npm": "npm publish --access public"
|
|
64
64
|
},
|
|
65
65
|
"dependencies": {
|
|
66
66
|
"onvif": "^0.8.1",
|