@camstack/addon-model-studio 1.1.182 → 1.1.183

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (18) hide show
  1. package/dist/{MotionZonesSettings-DB-47cOo.mjs → MotionZonesSettings-D5fe7czg.mjs} +2 -2
  2. package/dist/{PrivacyMaskSettings-BIzb0D_0.mjs → PrivacyMaskSettings-C2hylmd3.mjs} +4 -4
  3. package/dist/{SceneMonitorEditor-IaL6eXRr.mjs → SceneMonitorEditor-CLZ8DeD3.mjs} +3 -3
  4. package/dist/_stub.js +13 -13
  5. package/dist/{_virtual_mf-localSharedImportMap___mfe_internal__addon_model_studio_page-CsOTOHLQ.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_model_studio_page-Ca-jPREF.mjs} +3 -3
  6. package/dist/_virtual_mf___mfe_internal__addon_model_studio_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-CEWbeCwN.mjs +26 -0
  7. package/dist/{hostInit-Bl24UlY4.mjs → hostInit-DiUsU_UL.mjs} +2 -2
  8. package/dist/model-studio.addon.js +137 -158
  9. package/dist/model-studio.addon.mjs +137 -158
  10. package/dist/{player-overlays-CISEjNtj.mjs → player-overlays-CgxP2Qzw.mjs} +1 -1
  11. package/dist/remoteEntry.js +1 -1
  12. package/dist/{responsive-CUot36ya.mjs → responsive-F2i_EZ7a.mjs} +1 -1
  13. package/dist/{scene-monitor-copy-J64_2zC1.mjs → scene-monitor-copy-RkL6wtjU.mjs} +1 -1
  14. package/dist/{square-CDSkPKBQ.mjs → square-C4QMTFWA.mjs} +1 -1
  15. package/dist/{trash-2-C1NZwuGu.mjs → trash-2-BtfILwcu.mjs} +1 -1
  16. package/dist/{virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_model_studio_page__remoteEntry_js-DcHcLEYl.mjs → virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_model_studio_page__remoteEntry_js-DflrE0ec.mjs} +1 -1
  17. package/package.json +1 -1
  18. package/dist/_virtual_mf___mfe_internal__addon_model_studio_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-BmwlvTun.mjs +0 -26
@@ -5941,7 +5941,7 @@ var ZodIssueCode = {
5941
5941
  var ZodFirstPartyTypeKind;
5942
5942
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5943
5943
  //#endregion
5944
- //#region ../types/dist/sleep-DlrgY4Qb.mjs
5944
+ //#region ../types/dist/sleep-C-v96WpE.mjs
5945
5945
  /**
5946
5946
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5947
5947
  * window to float samples (D455).
@@ -8855,7 +8855,6 @@ var CompositionSchema = object({
8855
8855
  });
8856
8856
  new Set([
8857
8857
  "track",
8858
- "summary",
8859
8858
  "face",
8860
8859
  "identity",
8861
8860
  "plate",
@@ -20697,6 +20696,102 @@ var OauthIntegrationDescriptorSchema = object({
20697
20696
  });
20698
20697
  method(_void(), OauthIntegrationDescriptorSchema, { auth: "admin" });
20699
20698
  /**
20699
+ * What started a camera's onboard motion (D672). `camera` is the camera's own
20700
+ * firmware; `sensor` is a device the operator ATTACHED to it. Absent on the
20701
+ * wire means the camera: only the camera-sensors bridge ever says `sensor`.
20702
+ */
20703
+ var MotionTriggeredBySchema = discriminatedUnion("kind", [object({ kind: literal("camera") }), object({
20704
+ kind: literal("sensor"),
20705
+ deviceId: number().int().positive()
20706
+ })]);
20707
+ Object.freeze({ kind: "camera" });
20708
+ var CameraSensorRefSchema = object({
20709
+ addonId: string().min(1),
20710
+ stableId: string().min(1)
20711
+ });
20712
+ function cameraSensorRefKey(ref) {
20713
+ return `${ref.addonId}/${ref.stableId}`;
20714
+ }
20715
+ /** CS-1 accepts exactly one mode; CS-2 (D673) widens it to confirm / replace. */
20716
+ var CameraSensorsModeSchema = _enum(["in-addition"]);
20717
+ object({
20718
+ mode: CameraSensorsModeSchema,
20719
+ sensors: array(CameraSensorRefSchema).min(1).max(8)
20720
+ }).superRefine((value, ctx) => {
20721
+ const seen = /* @__PURE__ */ new Set();
20722
+ value.sensors.forEach((ref, index) => {
20723
+ const key = cameraSensorRefKey(ref);
20724
+ if (seen.has(key)) ctx.addIssue({
20725
+ code: "custom",
20726
+ path: ["sensors", index],
20727
+ message: `duplicate camera sensor ${key}`
20728
+ });
20729
+ seen.add(key);
20730
+ });
20731
+ });
20732
+ var RefFields = {
20733
+ addonId: string(),
20734
+ stableId: string()
20735
+ };
20736
+ var CameraSensorAttachmentSchema = discriminatedUnion("state", [
20737
+ object({
20738
+ ...RefFields,
20739
+ state: literal("ready"),
20740
+ deviceId: number(),
20741
+ name: string(),
20742
+ caps: array(string()).readonly()
20743
+ }),
20744
+ object({
20745
+ ...RefFields,
20746
+ state: literal("offline"),
20747
+ deviceId: number(),
20748
+ name: string(),
20749
+ reason: _enum(["offline", "disabled"])
20750
+ }),
20751
+ object({
20752
+ ...RefFields,
20753
+ state: literal("missing"),
20754
+ reason: string()
20755
+ }),
20756
+ object({
20757
+ ...RefFields,
20758
+ state: literal("unsupported"),
20759
+ deviceId: number(),
20760
+ name: string(),
20761
+ reason: string()
20762
+ }),
20763
+ object({
20764
+ ...RefFields,
20765
+ state: literal("unreadable"),
20766
+ reason: string()
20767
+ })
20768
+ ]);
20769
+ /**
20770
+ * Why a configured camera forwards NOTHING from its sensors, however ready they
20771
+ * are (D672): it does not list `onboard` in `motionSources` (attaching a sensor
20772
+ * does not add it), or it has no active detection config at all (the bridge
20773
+ * reads the active config). Absent = forwarded, or an older node that does not
20774
+ * say.
20775
+ */
20776
+ var CameraSensorsNotForwardedSchema = _enum(["onboard-not-listed", "no-active-detection"]);
20777
+ var CameraSensorsStatusSchema = discriminatedUnion("state", [
20778
+ object({ state: literal("not-configured") }),
20779
+ object({
20780
+ state: literal("unreadable"),
20781
+ reason: string()
20782
+ }),
20783
+ object({
20784
+ state: literal("configured"),
20785
+ mode: CameraSensorsModeSchema,
20786
+ sensors: array(CameraSensorAttachmentSchema).readonly(),
20787
+ notForwarded: CameraSensorsNotForwardedSchema.optional()
20788
+ })
20789
+ ]);
20790
+ Object.freeze({
20791
+ state: "unreadable",
20792
+ reason: "camera sensor mappings not loaded"
20793
+ });
20794
+ /**
20700
20795
  * A model choice has a SCOPE, and a scope change has a workflow.
20701
20796
  *
20702
20797
  * ## The two scopes
@@ -21445,6 +21540,12 @@ var MotionEventSchema = object({
21445
21540
  /** Populated by B5 (recording playback URL for this event). */
21446
21541
  mediaUrl: string().optional(),
21447
21542
  /**
21543
+ * The FIRST trigger of an `onboard` episode, written once at open (D672).
21544
+ * Absent = not recorded (a row written before D672, or an analyzer /
21545
+ * device-activity episode) — never read as "the camera" (D393).
21546
+ */
21547
+ triggeredBy: MotionTriggeredBySchema.optional(),
21548
+ /**
21448
21549
  * One row per motion EPISODE, not one per push (D475). `null` while the
21449
21550
  * episode is still open — a further rising edge extends it in place rather
21450
21551
  * than inserting a new row. Set once, at close, to `lastOnAt - startedAt`
@@ -21938,131 +22039,6 @@ var RecentTracksQueryInput = object({
21938
22039
  /** See {@link ExcludeSourcesDoc}. */
21939
22040
  excludeSources: array(TrackSourceSchema).optional()
21940
22041
  });
21941
- /**
21942
- * A Summary (D359): the per-camera session envelope that references tracks.
21943
- * `groupShotMediaId` is the media ROW id of its group shot (`ownerKind:
21944
- * 'summary'`, served by the event-media plane at `/m/<id>`), null until the
21945
- * first frame with a member visible has been materialised (D482 — it was the
21946
- * row's composite key, which embedded the owner and could name another table's
21947
- * row once event ids became per-table rowids).
21948
- */
21949
- var SummarySchema = object({
21950
- id: string(),
21951
- deviceId: number(),
21952
- openedAt: number(),
21953
- lastActiveAt: number(),
21954
- sealedAt: number().nullable(),
21955
- memberCount: number().int().nonnegative(),
21956
- groupShotMediaId: number().int().nullable()
21957
- });
21958
- var SummariesQueryInput = object({
21959
- deviceIds: array(number()).min(1),
21960
- since: number().optional(),
21961
- until: number().optional(),
21962
- limit: number().int().min(1).max(200).default(50),
21963
- /** The same member-wise filter {@link listRecentSummaries} takes — one
21964
- * meaning of "dog" on every summary surface. */
21965
- classes: array(string().min(1).max(60)).max(40).optional()
21966
- });
21967
- var SummaryDetailSchema = object({
21968
- summary: SummarySchema,
21969
- /** Members in absorption order, oldest join first. */
21970
- members: array(object({
21971
- trackId: string(),
21972
- /**
21973
- * The track's class at the time it JOINED, or `null` when it was unresolved
21974
- * and the track no longer exists to fill it.
21975
- *
21976
- * The join, not the latest opinion: class voting can re-decide a track's
21977
- * class afterwards, and a group's composition is the history of who came
21978
- * together. A consumer counts these to badge a thumbnail — "two people and a
21979
- * dog" — rather than being handed a second, denormalised tally that would
21980
- * drift from the members it claims to describe.
21981
- */
21982
- className: string().nullable(),
21983
- /** `primary` is the one member that carries the group's identity. */
21984
- role: _enum([
21985
- "primary",
21986
- "sibling",
21987
- "child"
21988
- ]).nullable(),
21989
- joinedAt: number(),
21990
- /** Tier 1 — the sub-class (`dog`, `van`), resolved from the member's track
21991
- * at read time. Absent when nothing resolved, never an empty string. */
21992
- label: string().optional(),
21993
- /** Tier 2 — the instance: a person's name, a plate. Absent when the pipeline
21994
- * recognised nobody, and absent for a member whose track has been pruned —
21995
- * a thumbnail that names the wrong person is worse than one naming nobody. */
21996
- subLabel: string().optional()
21997
- })).readonly()
21998
- });
21999
- /**
22000
- * What a LIST of groups carries: the envelope plus what it is MADE OF.
22001
- *
22002
- * Coarse on purpose — the operator's rule is "only the rough data on the list,
22003
- * we extend when we notice we need more". Enough to draw the card ("two people
22004
- * and a dog") and no more. The MEMBERS, their names and the per-member links
22005
- * are on {@link getSummary}: shipping every member of every group so a client
22006
- * can count them turns a page of two hundred groups into a thousand records to
22007
- * draw two hundred badges.
22008
- */
22009
- var SummaryListItemSchema = object({
22010
- summary: SummarySchema,
22011
- /** Class counts, most numerous first; `className: null` is a member whose
22012
- * class never resolved, counted so the counts add up to `memberCount`. */
22013
- classes: array(object({
22014
- className: string().nullable(),
22015
- count: number().int().positive()
22016
- })).readonly()
22017
- });
22018
- var SummariesPageSchema = object({ summaries: array(SummaryListItemSchema).readonly() });
22019
- /**
22020
- * The paged feed, deliberately the SAME shape as {@link RecentTracksQueryInput}.
22021
- *
22022
- * The reel on the cameras page and the Events gallery both ride a cursor, so a
22023
- * summaries feed that could only answer "the last N for these cameras"
22024
- * (`listSummaries`) would make groups available in the timeline and nowhere
22025
- * else. Two feeds with different ordering contracts would be two ideas of what
22026
- * "newest" means, on one screen.
22027
- */
22028
- var RecentSummariesQueryInput = object({
22029
- /** Devices to merge. An empty array yields an empty page. */
22030
- deviceIds: array(number()),
22031
- /** Window lower bound on `lastActiveAt` (inclusive). */
22032
- since: number().optional(),
22033
- /** Window upper bound on `lastActiveAt` (inclusive). */
22034
- until: number().optional(),
22035
- limit: number().int().min(1).max(500).default(100),
22036
- /** Opaque continuation cursor from a previous page's `nextCursor`. */
22037
- cursor: string().optional(),
22038
- /**
22039
- * Restrict to these classes — THE SAME FIELD `listRecentTracks` takes, and
22040
- * deliberately the same name: the events filter tree emits one list of ticked
22041
- * taxonomy nodes, and a summaries feed that called it something else would
22042
- * make the operator's one filter component produce two shapes.
22043
- *
22044
- * A question about the MEMBERS: a group matches when ANY of them does. "Show
22045
- * me the arrivals with a dog" has to return the group of four people who had
22046
- * one with them; a filter on the group's own fields could only ever answer
22047
- * about its primary.
22048
- *
22049
- * Matched against all THREE tiers of a member — the class (`animal`), the
22050
- * sub-class (`dog`) and the instance (a name, a plate) — because which tier a
22051
- * ticked node lives on is the taxonomy's business, not the caller's. `dog` is
22052
- * an event kind in the tree and a tier-1 label on an `animal` track; a filter
22053
- * that read only the class would answer "animal" and never "dog".
22054
- *
22055
- * ABSENT or EMPTY means no filter — absent is not a selection of none.
22056
- */
22057
- classes: array(string().min(1).max(60)).max(40).optional()
22058
- });
22059
- var RecentSummariesPageSchema = object({
22060
- /** Ordered by (`lastActiveAt` DESC, id DESC). Same light item as
22061
- * {@link listSummaries} — one list shape, so a card renders the same
22062
- * whichever feed drew it. */
22063
- summaries: array(SummaryListItemSchema).readonly(),
22064
- nextCursor: string().nullable()
22065
- });
22066
22042
  var RecentTracksPageSchema = object({
22067
22043
  /** Merged page, ordered by (`lastSeen` DESC, `trackId` DESC). */
22068
22044
  tracks: array(TrackSchema).readonly(),
@@ -22574,7 +22550,7 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
22574
22550
  classes: array(string()).optional(),
22575
22551
  /** See {@link ExcludeSourcesDoc}. */
22576
22552
  excludeSources: array(TrackSourceSchema).optional()
22577
- }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(SummariesQueryInput, SummariesPageSchema), method(RecentSummariesQueryInput, RecentSummariesPageSchema), method(object({ id: string() }), SummaryDetailSchema.nullable()), method(object({ deviceId: number() }), _void(), {
22553
+ }), array(TrackSchema).readonly()), method(RecentTracksQueryInput, RecentTracksPageSchema), method(object({ deviceId: number() }), _void(), {
22578
22554
  kind: "mutation",
22579
22555
  auth: "admin"
22580
22556
  }), method(DeviceEventQueryInput, array(MotionEventSchema).readonly()), method(ObjectEventQueryInput, array(ObjectEventSchema).readonly()), method(DeviceEventQueryInput, array(AudioEventSchema).readonly()), method(object({ deviceId: number() }), array(EventKindDescriptorSchema).readonly()), method(object({ deviceIds: array(number()).min(1).max(200) }), array(EventKindsForDeviceSchema).readonly()), method(object({
@@ -23754,6 +23730,23 @@ var MotionSourceEnum = _enum([
23754
23730
  */
23755
23731
  var MotionSourcesSchema = array(MotionSourceEnum);
23756
23732
  /**
23733
+ * The operator-facing name of each MOTION source (D672: `onboard` = the
23734
+ * camera's sensors — its own motion plus any sensor attached to it). The wire
23735
+ * value stays `onboard`; only the label changed. `detectionSources: 'onboard'`
23736
+ * ("Camera onboard AI") and the notification source filter keep their labels.
23737
+ */
23738
+ var MOTION_SOURCE_LABELS = {
23739
+ analyzer: "Frame-diff Analyzer (motion addon)",
23740
+ onboard: "Camera sensors",
23741
+ "device-activity": "Device activity (the device says it is working)"
23742
+ };
23743
+ /** The order the motion-source picker offers them in (not the enum's order). */
23744
+ var MOTION_SOURCE_PICKER_ORDER = [
23745
+ "analyzer",
23746
+ "onboard",
23747
+ "device-activity"
23748
+ ];
23749
+ /**
23757
23750
  * Which root detector a camera runs — EXACTLY ONE.
23758
23751
  *
23759
23752
  * Deliberately the SAME vocabulary post-analysis already tags every detection
@@ -24100,7 +24093,14 @@ var RunnerCameraConfigSchema = object({
24100
24093
  */
24101
24094
  inferenceDevices: array(RunnerInferenceDeviceSchema).readonly().optional()
24102
24095
  });
24103
- motionFpsField.min, motionFpsField.max, motionFpsField.step, motionFpsField.default, detectionFpsField.min, detectionFpsField.max, detectionFpsField.step, detectionFpsField.default, motionCooldownMsField.min, motionCooldownMsField.max, motionCooldownMsField.step, motionCooldownMsField.default, maxSessionHoldMsField.min, maxSessionHoldMsField.max, maxSessionHoldMsField.step, maxSessionHoldMsField.default, audioMotionWindowMsField.min, audioMotionWindowMsField.max, audioMotionWindowMsField.step, audioMotionWindowMsField.default, preRollInferenceFramesField.min, preRollInferenceFramesField.max, preRollInferenceFramesField.step, preRollInferenceFramesField.default, occupancyRecheckSecField.min, occupancyRecheckSecField.max, occupancyRecheckSecField.step, occupancyRecheckSecField.default, occupancyRecheckFramesField.min, occupancyRecheckFramesField.max, occupancyRecheckFramesField.step, occupancyRecheckFramesField.default;
24096
+ MOTION_SOURCE_PICKER_ORDER.map((value) => value === "onboard" ? {
24097
+ value,
24098
+ label: MOTION_SOURCE_LABELS[value],
24099
+ description: "The camera's own motion, plus any sensor attached to it"
24100
+ } : {
24101
+ value,
24102
+ label: MOTION_SOURCE_LABELS[value]
24103
+ }), motionFpsField.min, motionFpsField.max, motionFpsField.step, motionFpsField.default, detectionFpsField.min, detectionFpsField.max, detectionFpsField.step, detectionFpsField.default, motionCooldownMsField.min, motionCooldownMsField.max, motionCooldownMsField.step, motionCooldownMsField.default, maxSessionHoldMsField.min, maxSessionHoldMsField.max, maxSessionHoldMsField.step, maxSessionHoldMsField.default, audioMotionWindowMsField.min, audioMotionWindowMsField.max, audioMotionWindowMsField.step, audioMotionWindowMsField.default, preRollInferenceFramesField.min, preRollInferenceFramesField.max, preRollInferenceFramesField.step, preRollInferenceFramesField.default, occupancyRecheckSecField.min, occupancyRecheckSecField.max, occupancyRecheckSecField.step, occupancyRecheckSecField.default, occupancyRecheckFramesField.min, occupancyRecheckFramesField.max, occupancyRecheckFramesField.step, occupancyRecheckFramesField.default;
24104
24104
  /**
24105
24105
  * Runtime load summary returned by `getLocalLoad`. Used by the orchestrator's
24106
24106
  * load-balancing levels (L2 capacity-based, L3 hardware-aware) to decide
@@ -24674,6 +24674,11 @@ var CameraStatusSchema = object({
24674
24674
  */
24675
24675
  switchedOff: array(CameraSwitchIdSchema).readonly(),
24676
24676
  /**
24677
+ * The camera's attached sensors (D672). Optional only for a status composed
24678
+ * by an orchestrator older than D672; this orchestrator always sets it.
24679
+ */
24680
+ cameraSensors: CameraSensorsStatusSchema.optional(),
24681
+ /**
24677
24682
  * Stages of the bounded fan-out that were CUT SHORT — a timeout or a
24678
24683
  * rejection — and whose block is therefore `null` because we could not
24679
24684
  * READ it, not because there is nothing there.
@@ -30745,7 +30750,9 @@ object({
30745
30750
  detected: boolean(),
30746
30751
  timestamp: number(),
30747
30752
  source: MotionSourceEnum,
30748
- regions: array(MotionRegionSchema).readonly().optional()
30753
+ regions: array(MotionRegionSchema).readonly().optional(),
30754
+ /** Who started it (D672). Absent = the camera itself. Only `onboard` carries `sensor`. */
30755
+ triggeredBy: MotionTriggeredBySchema.optional()
30749
30756
  });
30750
30757
  DeviceType.Camera, DeviceType.Sensor, method(object({ deviceId: number() }), boolean());
30751
30758
  object({
@@ -41252,12 +41259,6 @@ Object.freeze({
41252
41259
  addonId: null,
41253
41260
  access: "view"
41254
41261
  },
41255
- "pipelineAnalytics.getSummary": {
41256
- capName: "pipeline-analytics",
41257
- capScope: "device",
41258
- addonId: null,
41259
- access: "view"
41260
- },
41261
41262
  "pipelineAnalytics.getTrack": {
41262
41263
  capName: "pipeline-analytics",
41263
41264
  capScope: "device",
@@ -41318,12 +41319,6 @@ Object.freeze({
41318
41319
  addonId: null,
41319
41320
  access: "view"
41320
41321
  },
41321
- "pipelineAnalytics.listRecentSummaries": {
41322
- capName: "pipeline-analytics",
41323
- capScope: "device",
41324
- addonId: null,
41325
- access: "view"
41326
- },
41327
41322
  "pipelineAnalytics.listRecentTracks": {
41328
41323
  capName: "pipeline-analytics",
41329
41324
  capScope: "device",
@@ -41354,12 +41349,6 @@ Object.freeze({
41354
41349
  addonId: null,
41355
41350
  access: "view"
41356
41351
  },
41357
- "pipelineAnalytics.listSummaries": {
41358
- capName: "pipeline-analytics",
41359
- capScope: "device",
41360
- addonId: null,
41361
- access: "view"
41362
- },
41363
41352
  "pipelineAnalytics.listTrackMedia": {
41364
41353
  capName: "pipeline-analytics",
41365
41354
  capScope: "device",
@@ -45529,11 +45518,6 @@ Object.freeze({
45529
45518
  form: "single",
45530
45519
  optional: true
45531
45520
  }],
45532
- "pipelineAnalytics.listRecentSummaries": [{
45533
- name: "deviceIds",
45534
- form: "array",
45535
- optional: false
45536
- }],
45537
45521
  "pipelineAnalytics.listRecentTracks": [{
45538
45522
  name: "deviceIds",
45539
45523
  form: "array",
@@ -45544,11 +45528,6 @@ Object.freeze({
45544
45528
  form: "array",
45545
45529
  optional: true
45546
45530
  }],
45547
- "pipelineAnalytics.listSummaries": [{
45548
- name: "deviceIds",
45549
- form: "array",
45550
- optional: false
45551
- }],
45552
45531
  "pipelineAnalytics.listTrackMedia": [{
45553
45532
  name: "deviceId",
45554
45533
  form: "single",