@camstack/addon-notifiers 1.2.129 → 1.2.130

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 (3) hide show
  1. package/dist/addon.js +422 -139
  2. package/dist/addon.mjs +422 -139
  3. package/package.json +1 -1
package/dist/addon.js CHANGED
@@ -5407,7 +5407,7 @@ var ZodIssueCode = {
5407
5407
  var ZodFirstPartyTypeKind;
5408
5408
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5409
5409
  //#endregion
5410
- //#region ../types/dist/sleep-r3RWkGVx.mjs
5410
+ //#region ../types/dist/sleep-DwAQ9sqX.mjs
5411
5411
  /**
5412
5412
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5413
5413
  * window to float samples (D455).
@@ -9358,6 +9358,16 @@ var CompositionSchema = object({
9358
9358
  seen.add(feature.cap);
9359
9359
  });
9360
9360
  });
9361
+ var NodeColorIdSchema = _enum([
9362
+ "node-a",
9363
+ "node-b",
9364
+ "node-c",
9365
+ "node-d",
9366
+ "node-e",
9367
+ "node-f",
9368
+ "node-g",
9369
+ "node-h"
9370
+ ]);
9361
9371
  new Set([
9362
9372
  "track",
9363
9373
  "face",
@@ -18233,14 +18243,14 @@ var LlmProfileSchema = object({
18233
18243
  /** ConfigUISchema tree passed through untyped on the wire (the
18234
18244
  * notification-output `ConfigSchemaPassthrough` precedent at
18235
18245
  * notification-output.cap.ts:151); the exported TS type re-tightens it. */
18236
- var ConfigSchemaPassthrough$1 = unknown();
18246
+ var ConfigSchemaPassthrough$3 = unknown();
18237
18247
  var LlmProfileKindDescriptorSchema = object({
18238
18248
  kind: LlmProfileKindSchema,
18239
18249
  label: string(),
18240
18250
  icon: string(),
18241
18251
  /** Stamped by each provider so the concat-fanned catalog stays routable. */
18242
18252
  addonId: string(),
18243
- configSchema: ConfigSchemaPassthrough$1
18253
+ configSchema: ConfigSchemaPassthrough$3
18244
18254
  });
18245
18255
  var LlmDefaultSelectorSchema = union([object({ consumer: string() }), object({ purpose: _enum(["text", "vision"]) })]);
18246
18256
  var LlmDefaultSchema = object({
@@ -19361,7 +19371,7 @@ var TargetKindCapsSchema = object({
19361
19371
  * the union is large and not meant for runtime validation here; the exported
19362
19372
  * `TargetKind` type re-tightens `configSchema` to `ConfigUISchema`.
19363
19373
  */
19364
- var ConfigSchemaPassthrough = unknown();
19374
+ var ConfigSchemaPassthrough$2 = unknown();
19365
19375
  var TargetKindSchema = object({
19366
19376
  kind: string(),
19367
19377
  label: string(),
@@ -19398,7 +19408,7 @@ var TargetKindSchema = object({
19398
19408
  * its raster path, which is the safe default for an unknown image.
19399
19409
  */
19400
19410
  iconMediaType: string().optional(),
19401
- configSchema: ConfigSchemaPassthrough,
19411
+ configSchema: ConfigSchemaPassthrough$2,
19402
19412
  /**
19403
19413
  * The config keys that decide WHERE this kind's secrets are sent (server,
19404
19414
  * base URL, instance, chat, recipient). A save that changes any of them
@@ -22719,6 +22729,61 @@ var OauthIntegrationDescriptorSchema = object({
22719
22729
  });
22720
22730
  method(_void(), OauthIntegrationDescriptorSchema, { auth: "admin" });
22721
22731
  /**
22732
+ * `oidc-connections` — CRUD for IdP rows under `auth-oidc` (D828 sibling).
22733
+ *
22734
+ * One hub-only singleton (`auth-oidc`). The Settings UI is a DataTable +
22735
+ * ItemFormDialog; there is no `editable-array` in `globalSettingsSchema`.
22736
+ * Operator-chosen `id` is the URL slug (`/addon/auth-oidc/<id>/…`) and is
22737
+ * immutable after create.
22738
+ */
22739
+ var ConfigSchemaPassthrough$1 = unknown();
22740
+ var OidcConnectionSchema = object({
22741
+ id: string().min(1),
22742
+ displayName: string(),
22743
+ icon: string(),
22744
+ issuerUrl: string(),
22745
+ clientId: string(),
22746
+ /** Client id + secret present — never the secret value. */
22747
+ configured: boolean(),
22748
+ /**
22749
+ * Values for the connection form schema. `clientSecret` is a keychain
22750
+ * {@link SecretFieldView} or `null` / `''`, never plaintext (D789).
22751
+ */
22752
+ formValues: record(string(), unknown()).optional()
22753
+ });
22754
+ /**
22755
+ * Patch one connection. Omitted or empty `clientSecret` keeps the stored
22756
+ * secret (D787). `{ $secretClear: true }` clears it. `id` is never renamed.
22757
+ */
22758
+ var OidcConnectionUpdateInputSchema = object({
22759
+ id: string().min(1),
22760
+ displayName: string().min(1),
22761
+ icon: string().optional(),
22762
+ issuerUrl: string().optional(),
22763
+ clientId: string().optional(),
22764
+ clientSecret: union([string(), object({ $secretClear: literal(true) })]).optional(),
22765
+ redirectUri: string().optional(),
22766
+ scopes: string().optional(),
22767
+ usernameClaim: _enum([
22768
+ "preferred_username",
22769
+ "email",
22770
+ "sub"
22771
+ ]).optional()
22772
+ });
22773
+ method(object({}), ConfigSchemaPassthrough$1, { auth: "admin" }), method(object({}), array(OidcConnectionSchema).readonly(), { auth: "admin" }), method(object({
22774
+ id: string().min(1).regex(/^[a-z0-9][a-z0-9-]{0,63}$/, "id must be a lowercase slug"),
22775
+ displayName: string().min(1)
22776
+ }), object({ id: string() }), {
22777
+ kind: "mutation",
22778
+ auth: "admin"
22779
+ }), method(OidcConnectionUpdateInputSchema, object({ ok: literal(true) }), {
22780
+ kind: "mutation",
22781
+ auth: "admin"
22782
+ }), method(object({ id: string().min(1) }), object({ ok: literal(true) }), {
22783
+ kind: "mutation",
22784
+ auth: "admin"
22785
+ });
22786
+ /**
22722
22787
  * What started a camera's onboard motion (D672). `camera` is the camera's own
22723
22788
  * firmware; `sensor` is a device the operator ATTACHED to it. Absent on the
22724
22789
  * wire means the camera: only the camera-sensors bridge ever says `sensor`.
@@ -24075,24 +24140,69 @@ var RetrainFrameListSchema = object({
24075
24140
  /** What the page pre-selects — the native key frame when one survives. */
24076
24141
  autoPickMediaId: number().int().optional()
24077
24142
  });
24143
+ /** Exclusive partition of a corpus copy's annotation progress (design §4.2). */
24144
+ var RetrainFrameWorkStateSchema = _enum([
24145
+ "unannotated",
24146
+ "annotated",
24147
+ "complete"
24148
+ ]);
24149
+ /**
24150
+ * Filters for paginated corpus list, KPI, and matching export (design §4.4).
24151
+ * Every narrowing field is ANDed; omitted fields impose no constraint.
24152
+ */
24153
+ var RetrainCorpusFilterSchema = object({
24154
+ workState: RetrainFrameWorkStateSchema.optional(),
24155
+ deviceIds: array(number()).max(500).optional(),
24156
+ /** When set, only frames in this named collection. */
24157
+ collectionId: string().optional(),
24158
+ /** Frames that carry at least one saved annotation in one of these classes. */
24159
+ classes: array(RetrainMacroClassSchema).optional(),
24160
+ page: number().int().positive().default(1),
24161
+ pageSize: number().int().positive().max(100).default(50)
24162
+ });
24163
+ var RetrainCorpusPageSchema = object({
24164
+ frames: array(RetrainFrameSchema.extend({ workState: RetrainFrameWorkStateSchema })).readonly(),
24165
+ total: number().int().nonnegative(),
24166
+ page: number().int().positive(),
24167
+ pageSize: number().int().positive()
24168
+ });
24169
+ var RetrainCorpusKpiCameraRowSchema = object({
24170
+ deviceId: number(),
24171
+ unannotated: number().int().nonnegative(),
24172
+ annotated: number().int().nonnegative(),
24173
+ complete: number().int().nonnegative(),
24174
+ /** This camera's `complete` count divided by corpus `total`, in `[0,1]`.
24175
+ * `null` when the corpus is empty (no ratio). */
24176
+ pctOfCorpus: number().min(0).max(1).nullable()
24177
+ });
24178
+ var RetrainCorpusKpiSchema = object({
24179
+ total: number().int().nonnegative(),
24180
+ unannotated: number().int().nonnegative(),
24181
+ annotated: number().int().nonnegative(),
24182
+ complete: number().int().nonnegative(),
24183
+ cameras: array(RetrainCorpusKpiCameraRowSchema).readonly()
24184
+ });
24078
24185
  /**
24079
24186
  * Which frames an annotated export carries. Every field narrows; an empty
24080
- * filter is every annotated copy. A dataset VERSION is a frozen `frameIds`
24081
- * list owned by whoever trains (the training orchestrator), so `frameIds` is
24082
- * the primitive a version export uses; `batchId` re-selects what an earlier
24083
- * export carried (`exportedInBatch`).
24187
+ * filter is every annotated copy. `frameIds` is the primitive a job or
24188
+ * download uses; `batchId` re-selects what an earlier export carried
24189
+ * (`exportedInBatch`). Frozen dataset versions were removed — live selection
24190
+ * resolves to `frameIds` at plan/start.
24084
24191
  */
24085
24192
  var RetrainExportFilterSchema = object({
24086
24193
  deviceIds: array(number()).optional(),
24087
24194
  frameIds: array(string()).max(2e4).optional(),
24088
24195
  /** Only frames in at least one of these named collections. */
24089
24196
  collectionIds: array(string()).max(200).optional(),
24090
- /** Exactly the frames of this dataset version (and its completeOnly). An
24091
- * unknown id selects nothing. */
24092
- datasetVersionId: string().optional(),
24197
+ /** Single collection (Frames filter bar). ANDed with `collectionIds` when both set. */
24198
+ collectionId: string().optional(),
24093
24199
  batchId: string().optional(),
24094
24200
  /** Only frames the operator marked complete (all subjects boxed). */
24095
- completeOnly: boolean().optional()
24201
+ completeOnly: boolean().optional(),
24202
+ /** Exclusive work-state partition (`workStateOf`); same as the corpus list. */
24203
+ workState: RetrainFrameWorkStateSchema.optional(),
24204
+ /** Frames with at least one saved annotation in one of these classes. */
24205
+ classes: array(RetrainMacroClassSchema).optional()
24096
24206
  });
24097
24207
  /**
24098
24208
  * `frames`: the full frame copies, boxes in `annotations.json`.
@@ -24292,8 +24402,7 @@ var RetrainDatasetStatsSchema = object({
24292
24402
  completeFrames: number().int()
24293
24403
  })).readonly()
24294
24404
  });
24295
- /** An immutable dataset version, without its frame list. */
24296
- var RetrainDatasetVersionSchema = object({
24405
+ object({
24297
24406
  id: string(),
24298
24407
  name: string(),
24299
24408
  createdAt: number(),
@@ -24301,22 +24410,33 @@ var RetrainDatasetVersionSchema = object({
24301
24410
  layout: RetrainExportLayoutSchema,
24302
24411
  completeOnly: boolean(),
24303
24412
  frameCount: number().int(),
24304
- /** sha256 of what the frames taught when the version was frozen. */
24305
24413
  annotationHash: string(),
24306
- /** The export manifest schema the version was cut under. */
24307
24414
  manifestSchema: string(),
24308
24415
  stats: RetrainDatasetStatsSchema
24309
24416
  });
24310
- var CreateRetrainDatasetVersionResultSchema = discriminatedUnion("kind", [object({
24311
- kind: literal("created"),
24312
- version: RetrainDatasetVersionSchema
24417
+ /**
24418
+ * Live training corpus criteria — same shape as `TrainingCorpusSelection` on
24419
+ * the training cap. Resolved here so plan/start and the annotated export share
24420
+ * one definition of "the frames" (`buildRetrainExportPlan`).
24421
+ */
24422
+ var RetrainTrainingCorpusSelectionSchema = object({
24423
+ collectionIds: array(string()).min(1),
24424
+ workState: _enum([
24425
+ "complete",
24426
+ "annotated_or_complete",
24427
+ "any_annotated"
24428
+ ]).default("complete")
24429
+ });
24430
+ var RetrainTrainingCorpusResolveResultSchema = discriminatedUnion("kind", [object({
24431
+ kind: literal("resolved"),
24432
+ frameIds: array(string()).max(2e4).readonly(),
24433
+ stats: RetrainDatasetStatsSchema,
24434
+ annotationHash: string(),
24435
+ layout: RetrainExportLayoutSchema
24313
24436
  }), object({
24314
24437
  kind: literal("refused"),
24315
- reason: _enum([
24316
- "empty-name",
24317
- "duplicate-name",
24318
- "no-frames"
24319
- ])
24438
+ reason: _enum(["unknown-collection", "no-frames"]),
24439
+ detail: string()
24320
24440
  })]);
24321
24441
  /** The outcome of a lifecycle move owned by the retrain page. */
24322
24442
  var RetrainTransitionResultSchema = object({
@@ -25023,6 +25143,12 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25023
25143
  }), array(RetrainTrackSchema).readonly(), {
25024
25144
  kind: "query",
25025
25145
  auth: "admin"
25146
+ }), method(RetrainCorpusFilterSchema, RetrainCorpusPageSchema, {
25147
+ kind: "query",
25148
+ auth: "admin"
25149
+ }), method(object({}), RetrainCorpusKpiSchema, {
25150
+ kind: "query",
25151
+ auth: "admin"
25026
25152
  }), method(object({ trackId: string() }), RetrainFrameListSchema, {
25027
25153
  kind: "query",
25028
25154
  auth: "admin"
@@ -25118,36 +25244,6 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25118
25244
  kind: "mutation",
25119
25245
  auth: "admin",
25120
25246
  timeoutMs: 12e4
25121
- }), method(object({
25122
- selection: RetrainDatasetSelectionSchema,
25123
- completeOnly: boolean().optional()
25124
- }), RetrainDatasetStatsSchema, {
25125
- kind: "query",
25126
- auth: "admin"
25127
- }), method(object({
25128
- name: string().max(120),
25129
- selection: RetrainDatasetSelectionSchema,
25130
- layout: RetrainExportLayoutSchema,
25131
- completeOnly: boolean()
25132
- }), CreateRetrainDatasetVersionResultSchema, {
25133
- kind: "mutation",
25134
- auth: "admin",
25135
- timeoutMs: 12e4
25136
- }), method(object({}), array(RetrainDatasetVersionSchema).readonly(), {
25137
- kind: "query",
25138
- auth: "admin"
25139
- }), method(object({ id: string() }), object({ deleted: boolean() }), {
25140
- kind: "mutation",
25141
- auth: "admin"
25142
- }), method(object({ id: string() }), object({
25143
- found: boolean(),
25144
- annotationHash: string(),
25145
- matches: boolean(),
25146
- missingFrames: number().int()
25147
- }), {
25148
- kind: "query",
25149
- auth: "admin",
25150
- timeoutMs: 12e4
25151
25247
  }), method(object({}), array(RetrainAssistProfileSchema).readonly(), {
25152
25248
  kind: "query",
25153
25249
  auth: "admin"
@@ -25174,6 +25270,10 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25174
25270
  }), method(object({}), array(RetrainCollectionSchema).readonly(), {
25175
25271
  kind: "query",
25176
25272
  auth: "admin"
25273
+ }), method(RetrainTrainingCorpusSelectionSchema, RetrainTrainingCorpusResolveResultSchema, {
25274
+ kind: "query",
25275
+ auth: "admin",
25276
+ timeoutMs: 6e4
25177
25277
  }), method(object({
25178
25278
  id: string(),
25179
25279
  name: string().max(120)
@@ -25790,11 +25890,14 @@ var HardwareClassIdSchema = _enum([
25790
25890
  "intel-n-series",
25791
25891
  "apple-m-base",
25792
25892
  "apple-m-pro",
25893
+ "amd-phoenix",
25793
25894
  "unknown"
25794
25895
  ]);
25795
25896
  var AcceleratorKindSchema = _enum([
25796
25897
  "intel-npu",
25797
25898
  "intel-igpu",
25899
+ "amd-igpu",
25900
+ "amd-npu",
25798
25901
  "x86-cpu",
25799
25902
  "arm-cpu",
25800
25903
  "apple-ane",
@@ -27684,6 +27787,8 @@ var AgentPipelineSettingsSchema = object({
27684
27787
  * address is wrong (multi-homed host, NAT, custom interface).
27685
27788
  */
27686
27789
  reachableHost: string().optional(),
27790
+ /** Hub-persisted UI colour (`--color-node-*` theme tokens). */
27791
+ color: NodeColorIdSchema.optional(),
27687
27792
  /**
27688
27793
  * Multi-device inference opt-in (Phase 4). Per-node map deviceKey → {enabled,
27689
27794
  * weight, steps}. Absent / all-disabled ⇒ the node's single default
@@ -28233,8 +28338,9 @@ method(object({
28233
28338
  auth: "admin"
28234
28339
  }), method(object({
28235
28340
  agentNodeId: string(),
28236
- reachableHost: string().nullable()
28237
- }), object({ success: literal(true) }), {
28341
+ reachableHost: string().nullable().optional(),
28342
+ color: NodeColorIdSchema.nullable().optional()
28343
+ }).refine((v) => v.reachableHost !== void 0 || v.color !== void 0, { message: "reachableHost or color required" }), object({ success: literal(true) }), {
28238
28344
  kind: "mutation",
28239
28345
  auth: "admin"
28240
28346
  }), method(object({
@@ -31281,7 +31387,7 @@ var CustomActionInputSchema = object({
31281
31387
  action: string().min(1),
31282
31388
  input: unknown()
31283
31389
  });
31284
- method(_void(), array(AddonListItemSchema).readonly()), method(object({
31390
+ method(object({ nodeId: string().optional() }).optional(), array(AddonListItemSchema).readonly()), method(object({
31285
31391
  addonId: string(),
31286
31392
  limit: number().min(1).max(500).default(100),
31287
31393
  level: LogLevelSchema$2.optional()
@@ -34828,7 +34934,13 @@ var TopologyNodeSchema = object({
34828
34934
  })).readonly(),
34829
34935
  processes: array(TopologyProcessSchema).readonly(),
34830
34936
  categories: array(TopologyCategorySchema).readonly(),
34831
- rootPackage: TopologyRootPackageSchema.nullable()
34937
+ rootPackage: TopologyRootPackageSchema.nullable(),
34938
+ /**
34939
+ * How an online AGENT reaches the hub (mesh mTLS Release A): `tls` once it has
34940
+ * completed a mutual-TLS handshake, `clear` otherwise. Absent for the hub,
34941
+ * for offline rows and when the hub cannot tell.
34942
+ */
34943
+ meshTransport: _enum(["tls", "clear"]).optional()
34832
34944
  });
34833
34945
  var CapUsageEdgeSchema = object({
34834
34946
  callerAddonId: string(),
@@ -35168,6 +35280,7 @@ var OsdNamedTemplateSchema = object({
35168
35280
  });
35169
35281
  /** Where a slot's value comes from. */
35170
35282
  var OsdSourceSchema = discriminatedUnion("kind", [
35283
+ object({ kind: literal("none") }),
35171
35284
  object({
35172
35285
  kind: literal("static"),
35173
35286
  text: string().max(64)
@@ -35294,6 +35407,13 @@ method(object({ deviceId: number().int() }), object({
35294
35407
  }), object({ success: literal(true) }), {
35295
35408
  kind: "mutation",
35296
35409
  auth: "admin"
35410
+ }), method(object({
35411
+ deviceId: number().int(),
35412
+ slotId: string().min(1),
35413
+ enabled: boolean()
35414
+ }), object({ success: literal(true) }), {
35415
+ kind: "mutation",
35416
+ auth: "admin"
35297
35417
  }), method(object({
35298
35418
  sourceDeviceId: number().int(),
35299
35419
  targetDeviceId: number().int()
@@ -35674,7 +35794,15 @@ var GpuInfoSchema = object({
35674
35794
  name: string(),
35675
35795
  memoryMB: number().optional()
35676
35796
  });
35677
- var NpuInfoSchema = object({ type: _enum(["apple-ane", "intel-npu"]) });
35797
+ var NpuInfoSchema = object({
35798
+ type: _enum([
35799
+ "apple-ane",
35800
+ "intel-npu",
35801
+ "amd-xdna"
35802
+ ]),
35803
+ name: string().optional(),
35804
+ generation: _enum(["xdna1", "xdna2"]).optional()
35805
+ });
35678
35806
  var CoralInfoSchema = object({
35679
35807
  type: literal("coral-edgetpu"),
35680
35808
  bus: string().optional()
@@ -39436,9 +39564,11 @@ DeviceType.Camera, method(object({
39436
39564
  * once is what makes a second provider (RunPod, a local NVIDIA node) a new
39437
39565
  * manifest entry and nothing else.
39438
39566
  *
39439
- * Collection, routed by the `addonId` in every single-row input (the `llm` /
39440
- * `notification-output` posture); `describe` concat-fans across providers.
39441
- * Every method is `admin`: these spend money.
39567
+ * Collection of provider **types** (addons). Each addon owns zero or more
39568
+ * **entries** (credentials + defaults). Concat-fans: `describe`,
39569
+ * `describeTypes`, `listEntries`, `listJobs`. Single-row work is keyed by
39570
+ * `entryId`; callers also pass the owning `addonId` as the collection
39571
+ * selector (broker posture). Every method is `admin`: these spend money.
39442
39572
  *
39443
39573
  * Every cloud object a provider creates is tagged with the orchestrator's
39444
39574
  * `jobKey`, so a retried submit finds the job it already started instead of
@@ -39462,8 +39592,8 @@ var TrainingRegionOptionSchema = object({
39462
39592
  priceMultiplier: number().positive()
39463
39593
  });
39464
39594
  /**
39465
- * The provider's per-account settings, as the orchestrator reads them. They
39466
- * live in the PROVIDER addon's settings (operator decision 2026-10-08: they
39595
+ * The provider's per-entry settings, as the orchestrator reads them. They
39596
+ * live on the PROVIDER addon's entry (operator decision 2026-10-08: they
39467
39597
  * depend on the user's account), never hard-coded in the orchestrator.
39468
39598
  */
39469
39599
  var TrainingProviderDefaultsSchema = object({
@@ -39474,9 +39604,44 @@ var TrainingProviderDefaultsSchema = object({
39474
39604
  /** Hours a FAILED job's cloud dataset is kept for debugging; 0 = delete at once. */
39475
39605
  failedDatasetGraceHours: number().nonnegative()
39476
39606
  });
39607
+ /**
39608
+ * Entry form schema for a provider type — same seam as notification
39609
+ * `TargetKind.configSchema` (`z.unknown()` at the wire; callers tighten to
39610
+ * {@link ConfigUISchema}). Drives `ConfigFormBuilder` on Training → Providers.
39611
+ */
39612
+ var ConfigSchemaPassthrough = unknown();
39613
+ /** One creatable provider type, for the Add-entry dialog. */
39614
+ var TrainingProviderTypeSchema = object({
39615
+ typeId: string(),
39616
+ label: string(),
39617
+ /** Path under the addon package (e.g. `assets/training-modal/icon.svg`). */
39618
+ iconAsset: string(),
39619
+ /** Owning `training-provider` addon — collection selector for createEntry. */
39620
+ addonId: string(),
39621
+ /**
39622
+ * Fields for one entry of this type (credentials + defaults). Absent on a
39623
+ * type that only needs a name. Password fields are keychain-backed on the
39624
+ * provider addon (`secretStatePaths`), not D634 plaintext.
39625
+ */
39626
+ configSchema: ConfigSchemaPassthrough.optional()
39627
+ });
39628
+ /** One configured account / workspace under a provider type. */
39629
+ var TrainingProviderEntrySchema = object({
39630
+ entryId: string(),
39631
+ typeId: string(),
39632
+ name: string(),
39633
+ addonId: string(),
39634
+ /** Credentials are present — never the values. */
39635
+ configured: boolean()
39636
+ });
39477
39637
  var TrainingProviderDescriptorSchema = object({
39478
39638
  addonId: string(),
39479
- /** `modal`, `runpod`, `fake`, … */
39639
+ entryId: string(),
39640
+ typeId: string(),
39641
+ /** Operator-chosen entry name. */
39642
+ name: string(),
39643
+ iconAsset: string(),
39644
+ /** `modal`, `runpod`, `fake`, … — same as typeId for current providers. */
39480
39645
  kind: string(),
39481
39646
  label: string(),
39482
39647
  gpuTypes: array(TrainingGpuOptionSchema).readonly(),
@@ -39488,7 +39653,30 @@ var TrainingProviderDescriptorSchema = object({
39488
39653
  dataResidencyNote: string(),
39489
39654
  /** Credentials are present — never the values. */
39490
39655
  configured: boolean(),
39491
- defaults: TrainingProviderDefaultsSchema
39656
+ defaults: TrainingProviderDefaultsSchema,
39657
+ /**
39658
+ * Values for {@link TrainingProviderTypeSchema}'s `configSchema` — password
39659
+ * fields are keychain {@link SecretFieldView} or `null` / `''` (create),
39660
+ * never plaintext. Same hydrate contract as settings forms (D789).
39661
+ */
39662
+ formValues: record(string(), unknown()).optional()
39663
+ });
39664
+ /**
39665
+ * Patch one entry's name, credentials and defaults. Pin with owning `{ addonId }`.
39666
+ * An omitted or empty `tokenSecret` means KEEP the stored secret (D787).
39667
+ * `{ $secretClear: true }` clears it.
39668
+ */
39669
+ var TrainingProviderUpdateEntryInputSchema = object({
39670
+ entryId: string().min(1),
39671
+ name: string().min(1),
39672
+ tokenId: string().optional(),
39673
+ tokenSecret: union([string(), object({ $secretClear: literal(true) })]).optional(),
39674
+ environment: string().optional(),
39675
+ gpuType: string().optional(),
39676
+ region: string().optional(),
39677
+ costCapUsd: number().nonnegative().optional(),
39678
+ maxRuntimeSec: number().int().positive().optional(),
39679
+ failedDatasetGraceHours: number().nonnegative().optional()
39492
39680
  });
39493
39681
  var TrainingCredentialCheckSchema = object({
39494
39682
  ok: boolean(),
@@ -39540,20 +39728,33 @@ var TrainerSourceRefSchema = object({
39540
39728
  /** A commit sha (never a branch) — the job must be reproducible. */
39541
39729
  revision: string().regex(/^[0-9a-f]{7,64}$/)
39542
39730
  });
39731
+ /** Cloud job identity — route with the owning addon's `addonId` selector. */
39543
39732
  var JobRef = {
39544
- addonId: string(),
39733
+ entryId: string().min(1),
39545
39734
  jobKey: string().uuid()
39546
39735
  };
39547
39736
  var TrainingLogLineSchema = object({
39548
39737
  ts: number(),
39549
39738
  text: string()
39550
39739
  });
39551
- method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "admin" }), method(object({ addonId: string() }), TrainingCredentialCheckSchema, {
39740
+ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "admin" }), method(object({}), array(TrainingProviderTypeSchema).readonly(), { auth: "admin" }), method(object({}), array(TrainingProviderEntrySchema).readonly(), { auth: "admin" }), method(object({
39741
+ typeId: string().min(1),
39742
+ name: string().min(1)
39743
+ }), object({ entryId: string() }), {
39744
+ kind: "mutation",
39745
+ auth: "admin"
39746
+ }), method(object({ entryId: string().min(1) }), object({ ok: literal(true) }), {
39747
+ kind: "mutation",
39748
+ auth: "admin"
39749
+ }), method(TrainingProviderUpdateEntryInputSchema, object({ ok: literal(true) }), {
39750
+ kind: "mutation",
39751
+ auth: "admin"
39752
+ }), method(object({ entryId: string().min(1) }), TrainingCredentialCheckSchema, {
39552
39753
  kind: "mutation",
39553
39754
  auth: "admin",
39554
39755
  timeoutMs: 3e4
39555
39756
  }), method(object({
39556
- addonId: string(),
39757
+ entryId: string().min(1),
39557
39758
  gpuType: string(),
39558
39759
  region: string(),
39559
39760
  datasetBytes: number().int().nonnegative(),
@@ -39619,7 +39820,7 @@ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "
39619
39820
  kind: "mutation",
39620
39821
  auth: "admin",
39621
39822
  timeoutMs: 5 * 6e4
39622
- }), method(object({ addonId: string() }), array(ProviderJobStatusSchema).readonly(), {
39823
+ }), method(object({ entryId: string().min(1).optional() }), array(ProviderJobStatusSchema).readonly(), {
39623
39824
  auth: "admin",
39624
39825
  timeoutMs: 2 * 6e4
39625
39826
  });
@@ -39629,20 +39830,31 @@ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "
39629
39830
  *
39630
39831
  * It owns what every provider must agree on, written once:
39631
39832
  *
39632
- * - **Dataset versions.** Taken over from pipeline-analytics (D796): the rows
39633
- * live here (D808); pipeline-analytics still CUTS a version (it owns the corpus and
39634
- * the export plan) and reaches this store through the five row methods
39635
- * below, so the Retrain page and the export did not change.
39636
39833
  * - **Jobs.** A persisted state machine, a reconcile loop against the
39637
39834
  * provider, a cost guard, a daily orphan sweep and the retention rules.
39638
39835
  * - **The return flow.** Verified artefacts → Model Studio
39639
39836
  * (`custom-model-registry.importModelBundle`) → canary on cameras →
39640
39837
  * rollback. Nothing is ever registered automatically.
39641
39838
  *
39839
+ * Plan/start takes a live {@link TrainingCorpusSelection} (collections +
39840
+ * work-state rule); frame ids are resolved via pipeline-analytics at that
39841
+ * moment and snapshotted on the job. No frozen dataset version.
39842
+ *
39642
39843
  * Every method is `admin`.
39643
39844
  */
39644
- /** A version WITH its frame list — what the export and a job read. */
39645
- var TrainingDatasetVersionRowSchema = RetrainDatasetVersionSchema.omit({ frameCount: true }).extend({ frameIds: array(string()).max(2e4).readonly() });
39845
+ /**
39846
+ * Live corpus criteria for plan/start (design §5.2). Default is complete-only.
39847
+ * Frame ids are resolved at plan/start — never a frozen version id.
39848
+ */
39849
+ var TrainingCorpusSelectionSchema = object({
39850
+ collectionIds: array(string()).min(1),
39851
+ /** Default complete-only for v1 */
39852
+ workState: _enum([
39853
+ "complete",
39854
+ "annotated_or_complete",
39855
+ "any_annotated"
39856
+ ]).default("complete")
39857
+ });
39646
39858
  /** A base model a detector job can fine-tune, and the baseline it is judged against. */
39647
39859
  var TrainingBaseModelSchema = object({
39648
39860
  modelId: string(),
@@ -39660,9 +39872,13 @@ var TrainingPresetSchema = _enum([
39660
39872
  "thorough"
39661
39873
  ]);
39662
39874
  var TrainingJobRequestSchema = object({
39663
- datasetVersionId: string().min(1),
39664
- /** The `training-provider` addon that runs it. */
39665
- addonId: string().min(1),
39875
+ /** Live collection + work-state criteria; resolved at plan/start. */
39876
+ selection: TrainingCorpusSelectionSchema,
39877
+ /**
39878
+ * The provider **entry** that runs it (credentials + defaults).
39879
+ * Resolve to an owning addon via `training-provider.describe` / `listEntries`.
39880
+ */
39881
+ entryId: string().min(1),
39666
39882
  gpuType: string().min(1),
39667
39883
  region: string(),
39668
39884
  baseModelId: string().min(1),
@@ -39721,6 +39937,7 @@ var TrainingJobPlanSchema = object({
39721
39937
  * result lives after the operator acted on it.
39722
39938
  */
39723
39939
  var TrainingJobStateSchema = _enum([
39940
+ "queued",
39724
39941
  "uploading",
39725
39942
  "submitted",
39726
39943
  "starting",
@@ -39774,6 +39991,11 @@ var TrainingJobSchema = object({
39774
39991
  createdAt: number(),
39775
39992
  updatedAt: number(),
39776
39993
  state: TrainingJobStateSchema,
39994
+ /**
39995
+ * Shared by every job enqueued together via `startJobBatch`.
39996
+ * `null` for a lone `startJob`. The engine advances queued siblings by this id.
39997
+ */
39998
+ batchId: string().nullable().default(null),
39777
39999
  stage: TrainingStageSchema.nullable(),
39778
40000
  failure: object({
39779
40001
  reason: TrainingFailureReasonSchema,
@@ -39785,6 +40007,12 @@ var TrainingJobSchema = object({
39785
40007
  maxRuntimeSec: number().int().positive(),
39786
40008
  trainer: TrainerSourceRefSchema,
39787
40009
  datasetLayout: RetrainExportLayoutSchema,
40010
+ /** Frame count snapshotted when the job started (audit; equals `frameIds.length`). */
40011
+ frameCount: number().int().nonnegative(),
40012
+ /** Resolved frame ids at start — the archive ships exactly these. */
40013
+ frameIds: array(string()).max(2e4).readonly(),
40014
+ /** Hash of what those frames taught at start (trainer `dataset.annotationHash`). */
40015
+ annotationHash: string(),
39788
40016
  dataset: object({
39789
40017
  bytes: number().int(),
39790
40018
  sha256: string(),
@@ -39826,13 +40054,7 @@ var TrainingJobSchema = object({
39826
40054
  canary: TrainingCanarySchema.nullable()
39827
40055
  });
39828
40056
  var IdInput = object({ id: string().min(1) });
39829
- method(TrainingDatasetVersionRowSchema, object({ stored: boolean() }), {
39830
- kind: "mutation",
39831
- auth: "admin"
39832
- }), method(IdInput, TrainingDatasetVersionRowSchema.nullable(), { auth: "admin" }), method(object({}), array(RetrainDatasetVersionSchema).readonly(), { auth: "admin" }), method(object({ name: string() }), object({ id: string().nullable() }), { auth: "admin" }), method(IdInput, object({ removed: boolean() }), {
39833
- kind: "mutation",
39834
- auth: "admin"
39835
- }), method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" }), method(TrainingJobRequestSchema, TrainingJobPlanSchema, {
40057
+ method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" }), method(TrainingJobRequestSchema, TrainingJobPlanSchema, {
39836
40058
  auth: "admin",
39837
40059
  timeoutMs: 6e4
39838
40060
  }), method(TrainingJobRequestSchema.extend({
@@ -39851,6 +40073,24 @@ method(TrainingDatasetVersionRowSchema, object({ stored: boolean() }), {
39851
40073
  kind: "mutation",
39852
40074
  auth: "admin",
39853
40075
  timeoutMs: 12e4
40076
+ }), method(TrainingJobRequestSchema.omit({ baseModelId: true }).extend({
40077
+ baseModelIds: array(string().min(1)).min(1),
40078
+ name: string().min(1).max(120),
40079
+ maxCostUsd: number().positive(),
40080
+ maxRuntimeSec: number().int().positive(),
40081
+ idempotencyKey: string().min(8).max(80)
40082
+ }), discriminatedUnion("kind", [object({
40083
+ kind: literal("started"),
40084
+ batchId: string(),
40085
+ jobs: array(TrainingJobSchema).min(1).readonly()
40086
+ }), object({
40087
+ kind: literal("refused"),
40088
+ reason: TrainingRefusalReasonSchema,
40089
+ detail: string()
40090
+ })]), {
40091
+ kind: "mutation",
40092
+ auth: "admin",
40093
+ timeoutMs: 12e4
39854
40094
  }), method(object({}), array(TrainingJobSchema).readonly(), { auth: "admin" }), method(IdInput, TrainingJobSchema.nullable(), { auth: "admin" }), method(IdInput, TrainingJobSchema, {
39855
40095
  kind: "mutation",
39856
40096
  auth: "admin",
@@ -43884,6 +44124,36 @@ Object.freeze({
43884
44124
  addonId: null,
43885
44125
  access: "view"
43886
44126
  },
44127
+ "oidcConnections.connectionFormSchema": {
44128
+ capName: "oidc-connections",
44129
+ capScope: "system",
44130
+ addonId: null,
44131
+ access: "view"
44132
+ },
44133
+ "oidcConnections.createConnection": {
44134
+ capName: "oidc-connections",
44135
+ capScope: "system",
44136
+ addonId: null,
44137
+ access: "create"
44138
+ },
44139
+ "oidcConnections.deleteConnection": {
44140
+ capName: "oidc-connections",
44141
+ capScope: "system",
44142
+ addonId: null,
44143
+ access: "delete"
44144
+ },
44145
+ "oidcConnections.listConnections": {
44146
+ capName: "oidc-connections",
44147
+ capScope: "system",
44148
+ addonId: null,
44149
+ access: "view"
44150
+ },
44151
+ "oidcConnections.updateConnection": {
44152
+ capName: "oidc-connections",
44153
+ capScope: "system",
44154
+ addonId: null,
44155
+ access: "create"
44156
+ },
43887
44157
  "osd.getStatus": {
43888
44158
  capName: "osd",
43889
44159
  capScope: "device",
@@ -43956,6 +44226,12 @@ Object.freeze({
43956
44226
  addonId: null,
43957
44227
  access: "create"
43958
44228
  },
44229
+ "osdManager.setSlotCameraEnabled": {
44230
+ capName: "osd-manager",
44231
+ capScope: "system",
44232
+ addonId: null,
44233
+ access: "create"
44234
+ },
43959
44235
  "osdManager.upsertTemplate": {
43960
44236
  capName: "osd-manager",
43961
44237
  capScope: "system",
@@ -44094,12 +44370,6 @@ Object.freeze({
44094
44370
  addonId: null,
44095
44371
  access: "create"
44096
44372
  },
44097
- "pipelineAnalytics.createRetrainDatasetVersion": {
44098
- capName: "pipeline-analytics",
44099
- capScope: "device",
44100
- addonId: null,
44101
- access: "create"
44102
- },
44103
44373
  "pipelineAnalytics.deleteDeviceEvents": {
44104
44374
  capName: "pipeline-analytics",
44105
44375
  capScope: "device",
@@ -44112,12 +44382,6 @@ Object.freeze({
44112
44382
  addonId: null,
44113
44383
  access: "delete"
44114
44384
  },
44115
- "pipelineAnalytics.deleteRetrainDatasetVersion": {
44116
- capName: "pipeline-analytics",
44117
- capScope: "device",
44118
- addonId: null,
44119
- access: "delete"
44120
- },
44121
44385
  "pipelineAnalytics.deleteTracks": {
44122
44386
  capName: "pipeline-analytics",
44123
44387
  capScope: "device",
@@ -44220,6 +44484,12 @@ Object.freeze({
44220
44484
  addonId: null,
44221
44485
  access: "view"
44222
44486
  },
44487
+ "pipelineAnalytics.getRetrainCorpusKpi": {
44488
+ capName: "pipeline-analytics",
44489
+ capScope: "device",
44490
+ addonId: null,
44491
+ access: "view"
44492
+ },
44223
44493
  "pipelineAnalytics.getRetrainExportUrl": {
44224
44494
  capName: "pipeline-analytics",
44225
44495
  capScope: "device",
@@ -44340,7 +44610,7 @@ Object.freeze({
44340
44610
  addonId: null,
44341
44611
  access: "view"
44342
44612
  },
44343
- "pipelineAnalytics.listRetrainDatasetVersions": {
44613
+ "pipelineAnalytics.listRetrainCorpusPage": {
44344
44614
  capName: "pipeline-analytics",
44345
44615
  capScope: "device",
44346
44616
  addonId: null,
@@ -44394,12 +44664,6 @@ Object.freeze({
44394
44664
  addonId: null,
44395
44665
  access: "create"
44396
44666
  },
44397
- "pipelineAnalytics.previewRetrainDataset": {
44398
- capName: "pipeline-analytics",
44399
- capScope: "device",
44400
- addonId: null,
44401
- access: "view"
44402
- },
44403
44667
  "pipelineAnalytics.proposeRetrainAnnotations": {
44404
44668
  capName: "pipeline-analytics",
44405
44669
  capScope: "device",
@@ -44478,6 +44742,12 @@ Object.freeze({
44478
44742
  addonId: null,
44479
44743
  access: "create"
44480
44744
  },
44745
+ "pipelineAnalytics.resolveRetrainTrainingCorpus": {
44746
+ capName: "pipeline-analytics",
44747
+ capScope: "device",
44748
+ addonId: null,
44749
+ access: "view"
44750
+ },
44481
44751
  "pipelineAnalytics.restageRetrainTrack": {
44482
44752
  capName: "pipeline-analytics",
44483
44753
  capScope: "device",
@@ -44538,12 +44808,6 @@ Object.freeze({
44538
44808
  addonId: null,
44539
44809
  access: "create"
44540
44810
  },
44541
- "pipelineAnalytics.verifyRetrainDatasetVersion": {
44542
- capName: "pipeline-analytics",
44543
- capScope: "device",
44544
- addonId: null,
44545
- access: "view"
44546
- },
44547
44811
  "pipelineAnalytics.wipeAllAnalytics": {
44548
44812
  capName: "pipeline-analytics",
44549
44813
  capScope: "device",
@@ -46938,18 +47202,6 @@ Object.freeze({
46938
47202
  addonId: null,
46939
47203
  access: "create"
46940
47204
  },
46941
- "training.findDatasetVersionIdByName": {
46942
- capName: "training",
46943
- capScope: "system",
46944
- addonId: null,
46945
- access: "view"
46946
- },
46947
- "training.getDatasetVersion": {
46948
- capName: "training",
46949
- capScope: "system",
46950
- addonId: null,
46951
- access: "view"
46952
- },
46953
47205
  "training.getJob": {
46954
47206
  capName: "training",
46955
47207
  capScope: "system",
@@ -46968,12 +47220,6 @@ Object.freeze({
46968
47220
  addonId: null,
46969
47221
  access: "view"
46970
47222
  },
46971
- "training.listDatasetVersions": {
46972
- capName: "training",
46973
- capScope: "system",
46974
- addonId: null,
46975
- access: "view"
46976
- },
46977
47223
  "training.listJobs": {
46978
47224
  capName: "training",
46979
47225
  capScope: "system",
@@ -46986,54 +47232,66 @@ Object.freeze({
46986
47232
  addonId: null,
46987
47233
  access: "view"
46988
47234
  },
46989
- "training.putDatasetVersion": {
47235
+ "training.registerResult": {
46990
47236
  capName: "training",
46991
47237
  capScope: "system",
46992
47238
  addonId: null,
46993
47239
  access: "create"
46994
47240
  },
46995
- "training.registerResult": {
47241
+ "training.rollbackCanary": {
46996
47242
  capName: "training",
46997
47243
  capScope: "system",
46998
47244
  addonId: null,
46999
47245
  access: "create"
47000
47246
  },
47001
- "training.removeDatasetVersion": {
47247
+ "training.startJob": {
47002
47248
  capName: "training",
47003
47249
  capScope: "system",
47004
47250
  addonId: null,
47005
- access: "delete"
47251
+ access: "create"
47006
47252
  },
47007
- "training.rollbackCanary": {
47253
+ "training.startJobBatch": {
47008
47254
  capName: "training",
47009
47255
  capScope: "system",
47010
47256
  addonId: null,
47011
47257
  access: "create"
47012
47258
  },
47013
- "training.startJob": {
47014
- capName: "training",
47259
+ "trainingProvider.cancelJob": {
47260
+ capName: "training-provider",
47015
47261
  capScope: "system",
47016
47262
  addonId: null,
47017
47263
  access: "create"
47018
47264
  },
47019
- "trainingProvider.cancelJob": {
47265
+ "trainingProvider.cleanupJob": {
47020
47266
  capName: "training-provider",
47021
47267
  capScope: "system",
47022
47268
  addonId: null,
47023
47269
  access: "create"
47024
47270
  },
47025
- "trainingProvider.cleanupJob": {
47271
+ "trainingProvider.createEntry": {
47026
47272
  capName: "training-provider",
47027
47273
  capScope: "system",
47028
47274
  addonId: null,
47029
47275
  access: "create"
47030
47276
  },
47277
+ "trainingProvider.deleteEntry": {
47278
+ capName: "training-provider",
47279
+ capScope: "system",
47280
+ addonId: null,
47281
+ access: "delete"
47282
+ },
47031
47283
  "trainingProvider.describe": {
47032
47284
  capName: "training-provider",
47033
47285
  capScope: "system",
47034
47286
  addonId: null,
47035
47287
  access: "view"
47036
47288
  },
47289
+ "trainingProvider.describeTypes": {
47290
+ capName: "training-provider",
47291
+ capScope: "system",
47292
+ addonId: null,
47293
+ access: "view"
47294
+ },
47037
47295
  "trainingProvider.estimateJob": {
47038
47296
  capName: "training-provider",
47039
47297
  capScope: "system",
@@ -47046,6 +47304,12 @@ Object.freeze({
47046
47304
  addonId: null,
47047
47305
  access: "view"
47048
47306
  },
47307
+ "trainingProvider.listEntries": {
47308
+ capName: "training-provider",
47309
+ capScope: "system",
47310
+ addonId: null,
47311
+ access: "view"
47312
+ },
47049
47313
  "trainingProvider.listJobEvents": {
47050
47314
  capName: "training-provider",
47051
47315
  capScope: "system",
@@ -47076,6 +47340,12 @@ Object.freeze({
47076
47340
  addonId: null,
47077
47341
  access: "create"
47078
47342
  },
47343
+ "trainingProvider.updateEntry": {
47344
+ capName: "training-provider",
47345
+ capScope: "system",
47346
+ addonId: null,
47347
+ access: "create"
47348
+ },
47079
47349
  "trainingProvider.uploadDataset": {
47080
47350
  capName: "training-provider",
47081
47351
  capScope: "system",
@@ -50282,6 +50552,11 @@ Object.freeze({
50282
50552
  form: "single",
50283
50553
  optional: false
50284
50554
  }],
50555
+ "osdManager.setSlotCameraEnabled": [{
50556
+ name: "deviceId",
50557
+ form: "single",
50558
+ optional: false
50559
+ }],
50285
50560
  "petFeeder.callPet": [{
50286
50561
  name: "deviceId",
50287
50562
  form: "single",
@@ -50502,6 +50777,11 @@ Object.freeze({
50502
50777
  form: "array",
50503
50778
  optional: false
50504
50779
  }],
50780
+ "pipelineAnalytics.listRetrainCorpusPage": [{
50781
+ name: "deviceIds",
50782
+ form: "array",
50783
+ optional: true
50784
+ }],
50505
50785
  "pipelineAnalytics.listRetrainStaging": [{
50506
50786
  name: "deviceIds",
50507
50787
  form: "array",
@@ -51611,6 +51891,7 @@ Object.freeze({
51611
51891
  });
51612
51892
  Object.freeze({
51613
51893
  "broker": "broker",
51894
+ "calendar-source": "calendar",
51614
51895
  "device-export": "device-export",
51615
51896
  "llm": "ai",
51616
51897
  "mesh-network": "mesh",
@@ -52303,6 +52584,8 @@ var STATE_SUMMARY_VARS = [
52303
52584
  [...RULE_TEXT],
52304
52585
  [...RULE_TEXT],
52305
52586
  [...RULE_TEXT],
52587
+ [...RULE_TEXT],
52588
+ [...RULE_TEXT],
52306
52589
  ([...RULE_TEXT], [...UPDATES]),
52307
52590
  ([...RULE_TEXT], [...PACKAGE_UPDATES]),
52308
52591
  ([...RULE_TEXT], [...PACKAGE_UPDATES]),