@camstack/addon-terminal 0.1.129 → 0.1.131

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
@@ -5409,7 +5409,7 @@ var ZodIssueCode = {
5409
5409
  var ZodFirstPartyTypeKind;
5410
5410
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5411
5411
  //#endregion
5412
- //#region ../types/dist/sleep-r3RWkGVx.mjs
5412
+ //#region ../types/dist/sleep-DwAQ9sqX.mjs
5413
5413
  /**
5414
5414
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5415
5415
  * window to float samples (D455).
@@ -9474,6 +9474,16 @@ var CompositionSchema = object({
9474
9474
  seen.add(feature.cap);
9475
9475
  });
9476
9476
  });
9477
+ var NodeColorIdSchema = _enum([
9478
+ "node-a",
9479
+ "node-b",
9480
+ "node-c",
9481
+ "node-d",
9482
+ "node-e",
9483
+ "node-f",
9484
+ "node-g",
9485
+ "node-h"
9486
+ ]);
9477
9487
  new Set([
9478
9488
  "track",
9479
9489
  "face",
@@ -18454,14 +18464,14 @@ var LlmProfileSchema = object({
18454
18464
  /** ConfigUISchema tree passed through untyped on the wire (the
18455
18465
  * notification-output `ConfigSchemaPassthrough` precedent at
18456
18466
  * notification-output.cap.ts:151); the exported TS type re-tightens it. */
18457
- var ConfigSchemaPassthrough$1 = unknown();
18467
+ var ConfigSchemaPassthrough$3 = unknown();
18458
18468
  var LlmProfileKindDescriptorSchema = object({
18459
18469
  kind: LlmProfileKindSchema,
18460
18470
  label: string(),
18461
18471
  icon: string(),
18462
18472
  /** Stamped by each provider so the concat-fanned catalog stays routable. */
18463
18473
  addonId: string(),
18464
- configSchema: ConfigSchemaPassthrough$1
18474
+ configSchema: ConfigSchemaPassthrough$3
18465
18475
  });
18466
18476
  var LlmDefaultSelectorSchema = union([object({ consumer: string() }), object({ purpose: _enum(["text", "vision"]) })]);
18467
18477
  var LlmDefaultSchema = object({
@@ -19582,7 +19592,7 @@ var TargetKindCapsSchema = object({
19582
19592
  * the union is large and not meant for runtime validation here; the exported
19583
19593
  * `TargetKind` type re-tightens `configSchema` to `ConfigUISchema`.
19584
19594
  */
19585
- var ConfigSchemaPassthrough = unknown();
19595
+ var ConfigSchemaPassthrough$2 = unknown();
19586
19596
  var TargetKindSchema = object({
19587
19597
  kind: string(),
19588
19598
  label: string(),
@@ -19619,7 +19629,7 @@ var TargetKindSchema = object({
19619
19629
  * its raster path, which is the safe default for an unknown image.
19620
19630
  */
19621
19631
  iconMediaType: string().optional(),
19622
- configSchema: ConfigSchemaPassthrough,
19632
+ configSchema: ConfigSchemaPassthrough$2,
19623
19633
  /**
19624
19634
  * The config keys that decide WHERE this kind's secrets are sent (server,
19625
19635
  * base URL, instance, chat, recipient). A save that changes any of them
@@ -22956,6 +22966,61 @@ var OauthIntegrationDescriptorSchema = object({
22956
22966
  });
22957
22967
  method(_void(), OauthIntegrationDescriptorSchema, { auth: "admin" });
22958
22968
  /**
22969
+ * `oidc-connections` — CRUD for IdP rows under `auth-oidc` (D828 sibling).
22970
+ *
22971
+ * One hub-only singleton (`auth-oidc`). The Settings UI is a DataTable +
22972
+ * ItemFormDialog; there is no `editable-array` in `globalSettingsSchema`.
22973
+ * Operator-chosen `id` is the URL slug (`/addon/auth-oidc/<id>/…`) and is
22974
+ * immutable after create.
22975
+ */
22976
+ var ConfigSchemaPassthrough$1 = unknown();
22977
+ var OidcConnectionSchema = object({
22978
+ id: string().min(1),
22979
+ displayName: string(),
22980
+ icon: string(),
22981
+ issuerUrl: string(),
22982
+ clientId: string(),
22983
+ /** Client id + secret present — never the secret value. */
22984
+ configured: boolean(),
22985
+ /**
22986
+ * Values for the connection form schema. `clientSecret` is a keychain
22987
+ * {@link SecretFieldView} or `null` / `''`, never plaintext (D789).
22988
+ */
22989
+ formValues: record(string(), unknown()).optional()
22990
+ });
22991
+ /**
22992
+ * Patch one connection. Omitted or empty `clientSecret` keeps the stored
22993
+ * secret (D787). `{ $secretClear: true }` clears it. `id` is never renamed.
22994
+ */
22995
+ var OidcConnectionUpdateInputSchema = object({
22996
+ id: string().min(1),
22997
+ displayName: string().min(1),
22998
+ icon: string().optional(),
22999
+ issuerUrl: string().optional(),
23000
+ clientId: string().optional(),
23001
+ clientSecret: union([string(), object({ $secretClear: literal(true) })]).optional(),
23002
+ redirectUri: string().optional(),
23003
+ scopes: string().optional(),
23004
+ usernameClaim: _enum([
23005
+ "preferred_username",
23006
+ "email",
23007
+ "sub"
23008
+ ]).optional()
23009
+ });
23010
+ method(object({}), ConfigSchemaPassthrough$1, { auth: "admin" }), method(object({}), array(OidcConnectionSchema).readonly(), { auth: "admin" }), method(object({
23011
+ id: string().min(1).regex(/^[a-z0-9][a-z0-9-]{0,63}$/, "id must be a lowercase slug"),
23012
+ displayName: string().min(1)
23013
+ }), object({ id: string() }), {
23014
+ kind: "mutation",
23015
+ auth: "admin"
23016
+ }), method(OidcConnectionUpdateInputSchema, object({ ok: literal(true) }), {
23017
+ kind: "mutation",
23018
+ auth: "admin"
23019
+ }), method(object({ id: string().min(1) }), object({ ok: literal(true) }), {
23020
+ kind: "mutation",
23021
+ auth: "admin"
23022
+ });
23023
+ /**
22959
23024
  * What started a camera's onboard motion (D672). `camera` is the camera's own
22960
23025
  * firmware; `sensor` is a device the operator ATTACHED to it. Absent on the
22961
23026
  * wire means the camera: only the camera-sensors bridge ever says `sensor`.
@@ -24312,24 +24377,69 @@ var RetrainFrameListSchema = object({
24312
24377
  /** What the page pre-selects — the native key frame when one survives. */
24313
24378
  autoPickMediaId: number().int().optional()
24314
24379
  });
24380
+ /** Exclusive partition of a corpus copy's annotation progress (design §4.2). */
24381
+ var RetrainFrameWorkStateSchema = _enum([
24382
+ "unannotated",
24383
+ "annotated",
24384
+ "complete"
24385
+ ]);
24386
+ /**
24387
+ * Filters for paginated corpus list, KPI, and matching export (design §4.4).
24388
+ * Every narrowing field is ANDed; omitted fields impose no constraint.
24389
+ */
24390
+ var RetrainCorpusFilterSchema = object({
24391
+ workState: RetrainFrameWorkStateSchema.optional(),
24392
+ deviceIds: array(number()).max(500).optional(),
24393
+ /** When set, only frames in this named collection. */
24394
+ collectionId: string().optional(),
24395
+ /** Frames that carry at least one saved annotation in one of these classes. */
24396
+ classes: array(RetrainMacroClassSchema).optional(),
24397
+ page: number().int().positive().default(1),
24398
+ pageSize: number().int().positive().max(100).default(50)
24399
+ });
24400
+ var RetrainCorpusPageSchema = object({
24401
+ frames: array(RetrainFrameSchema.extend({ workState: RetrainFrameWorkStateSchema })).readonly(),
24402
+ total: number().int().nonnegative(),
24403
+ page: number().int().positive(),
24404
+ pageSize: number().int().positive()
24405
+ });
24406
+ var RetrainCorpusKpiCameraRowSchema = object({
24407
+ deviceId: number(),
24408
+ unannotated: number().int().nonnegative(),
24409
+ annotated: number().int().nonnegative(),
24410
+ complete: number().int().nonnegative(),
24411
+ /** This camera's `complete` count divided by corpus `total`, in `[0,1]`.
24412
+ * `null` when the corpus is empty (no ratio). */
24413
+ pctOfCorpus: number().min(0).max(1).nullable()
24414
+ });
24415
+ var RetrainCorpusKpiSchema = object({
24416
+ total: number().int().nonnegative(),
24417
+ unannotated: number().int().nonnegative(),
24418
+ annotated: number().int().nonnegative(),
24419
+ complete: number().int().nonnegative(),
24420
+ cameras: array(RetrainCorpusKpiCameraRowSchema).readonly()
24421
+ });
24315
24422
  /**
24316
24423
  * Which frames an annotated export carries. Every field narrows; an empty
24317
- * filter is every annotated copy. A dataset VERSION is a frozen `frameIds`
24318
- * list owned by whoever trains (the training orchestrator), so `frameIds` is
24319
- * the primitive a version export uses; `batchId` re-selects what an earlier
24320
- * export carried (`exportedInBatch`).
24424
+ * filter is every annotated copy. `frameIds` is the primitive a job or
24425
+ * download uses; `batchId` re-selects what an earlier export carried
24426
+ * (`exportedInBatch`). Frozen dataset versions were removed — live selection
24427
+ * resolves to `frameIds` at plan/start.
24321
24428
  */
24322
24429
  var RetrainExportFilterSchema = object({
24323
24430
  deviceIds: array(number()).optional(),
24324
24431
  frameIds: array(string()).max(2e4).optional(),
24325
24432
  /** Only frames in at least one of these named collections. */
24326
24433
  collectionIds: array(string()).max(200).optional(),
24327
- /** Exactly the frames of this dataset version (and its completeOnly). An
24328
- * unknown id selects nothing. */
24329
- datasetVersionId: string().optional(),
24434
+ /** Single collection (Frames filter bar). ANDed with `collectionIds` when both set. */
24435
+ collectionId: string().optional(),
24330
24436
  batchId: string().optional(),
24331
24437
  /** Only frames the operator marked complete (all subjects boxed). */
24332
- completeOnly: boolean().optional()
24438
+ completeOnly: boolean().optional(),
24439
+ /** Exclusive work-state partition (`workStateOf`); same as the corpus list. */
24440
+ workState: RetrainFrameWorkStateSchema.optional(),
24441
+ /** Frames with at least one saved annotation in one of these classes. */
24442
+ classes: array(RetrainMacroClassSchema).optional()
24333
24443
  });
24334
24444
  /**
24335
24445
  * `frames`: the full frame copies, boxes in `annotations.json`.
@@ -24529,8 +24639,7 @@ var RetrainDatasetStatsSchema = object({
24529
24639
  completeFrames: number().int()
24530
24640
  })).readonly()
24531
24641
  });
24532
- /** An immutable dataset version, without its frame list. */
24533
- var RetrainDatasetVersionSchema = object({
24642
+ object({
24534
24643
  id: string(),
24535
24644
  name: string(),
24536
24645
  createdAt: number(),
@@ -24538,22 +24647,33 @@ var RetrainDatasetVersionSchema = object({
24538
24647
  layout: RetrainExportLayoutSchema,
24539
24648
  completeOnly: boolean(),
24540
24649
  frameCount: number().int(),
24541
- /** sha256 of what the frames taught when the version was frozen. */
24542
24650
  annotationHash: string(),
24543
- /** The export manifest schema the version was cut under. */
24544
24651
  manifestSchema: string(),
24545
24652
  stats: RetrainDatasetStatsSchema
24546
24653
  });
24547
- var CreateRetrainDatasetVersionResultSchema = discriminatedUnion("kind", [object({
24548
- kind: literal("created"),
24549
- version: RetrainDatasetVersionSchema
24654
+ /**
24655
+ * Live training corpus criteria — same shape as `TrainingCorpusSelection` on
24656
+ * the training cap. Resolved here so plan/start and the annotated export share
24657
+ * one definition of "the frames" (`buildRetrainExportPlan`).
24658
+ */
24659
+ var RetrainTrainingCorpusSelectionSchema = object({
24660
+ collectionIds: array(string()).min(1),
24661
+ workState: _enum([
24662
+ "complete",
24663
+ "annotated_or_complete",
24664
+ "any_annotated"
24665
+ ]).default("complete")
24666
+ });
24667
+ var RetrainTrainingCorpusResolveResultSchema = discriminatedUnion("kind", [object({
24668
+ kind: literal("resolved"),
24669
+ frameIds: array(string()).max(2e4).readonly(),
24670
+ stats: RetrainDatasetStatsSchema,
24671
+ annotationHash: string(),
24672
+ layout: RetrainExportLayoutSchema
24550
24673
  }), object({
24551
24674
  kind: literal("refused"),
24552
- reason: _enum([
24553
- "empty-name",
24554
- "duplicate-name",
24555
- "no-frames"
24556
- ])
24675
+ reason: _enum(["unknown-collection", "no-frames"]),
24676
+ detail: string()
24557
24677
  })]);
24558
24678
  /** The outcome of a lifecycle move owned by the retrain page. */
24559
24679
  var RetrainTransitionResultSchema = object({
@@ -25260,6 +25380,12 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25260
25380
  }), array(RetrainTrackSchema).readonly(), {
25261
25381
  kind: "query",
25262
25382
  auth: "admin"
25383
+ }), method(RetrainCorpusFilterSchema, RetrainCorpusPageSchema, {
25384
+ kind: "query",
25385
+ auth: "admin"
25386
+ }), method(object({}), RetrainCorpusKpiSchema, {
25387
+ kind: "query",
25388
+ auth: "admin"
25263
25389
  }), method(object({ trackId: string() }), RetrainFrameListSchema, {
25264
25390
  kind: "query",
25265
25391
  auth: "admin"
@@ -25355,36 +25481,6 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25355
25481
  kind: "mutation",
25356
25482
  auth: "admin",
25357
25483
  timeoutMs: 12e4
25358
- }), method(object({
25359
- selection: RetrainDatasetSelectionSchema,
25360
- completeOnly: boolean().optional()
25361
- }), RetrainDatasetStatsSchema, {
25362
- kind: "query",
25363
- auth: "admin"
25364
- }), method(object({
25365
- name: string().max(120),
25366
- selection: RetrainDatasetSelectionSchema,
25367
- layout: RetrainExportLayoutSchema,
25368
- completeOnly: boolean()
25369
- }), CreateRetrainDatasetVersionResultSchema, {
25370
- kind: "mutation",
25371
- auth: "admin",
25372
- timeoutMs: 12e4
25373
- }), method(object({}), array(RetrainDatasetVersionSchema).readonly(), {
25374
- kind: "query",
25375
- auth: "admin"
25376
- }), method(object({ id: string() }), object({ deleted: boolean() }), {
25377
- kind: "mutation",
25378
- auth: "admin"
25379
- }), method(object({ id: string() }), object({
25380
- found: boolean(),
25381
- annotationHash: string(),
25382
- matches: boolean(),
25383
- missingFrames: number().int()
25384
- }), {
25385
- kind: "query",
25386
- auth: "admin",
25387
- timeoutMs: 12e4
25388
25484
  }), method(object({}), array(RetrainAssistProfileSchema).readonly(), {
25389
25485
  kind: "query",
25390
25486
  auth: "admin"
@@ -25411,6 +25507,10 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25411
25507
  }), method(object({}), array(RetrainCollectionSchema).readonly(), {
25412
25508
  kind: "query",
25413
25509
  auth: "admin"
25510
+ }), method(RetrainTrainingCorpusSelectionSchema, RetrainTrainingCorpusResolveResultSchema, {
25511
+ kind: "query",
25512
+ auth: "admin",
25513
+ timeoutMs: 6e4
25414
25514
  }), method(object({
25415
25515
  id: string(),
25416
25516
  name: string().max(120)
@@ -26027,11 +26127,14 @@ var HardwareClassIdSchema = _enum([
26027
26127
  "intel-n-series",
26028
26128
  "apple-m-base",
26029
26129
  "apple-m-pro",
26130
+ "amd-phoenix",
26030
26131
  "unknown"
26031
26132
  ]);
26032
26133
  var AcceleratorKindSchema = _enum([
26033
26134
  "intel-npu",
26034
26135
  "intel-igpu",
26136
+ "amd-igpu",
26137
+ "amd-npu",
26035
26138
  "x86-cpu",
26036
26139
  "arm-cpu",
26037
26140
  "apple-ane",
@@ -27961,6 +28064,8 @@ var AgentPipelineSettingsSchema = object({
27961
28064
  * address is wrong (multi-homed host, NAT, custom interface).
27962
28065
  */
27963
28066
  reachableHost: string().optional(),
28067
+ /** Hub-persisted UI colour (`--color-node-*` theme tokens). */
28068
+ color: NodeColorIdSchema.optional(),
27964
28069
  /**
27965
28070
  * Multi-device inference opt-in (Phase 4). Per-node map deviceKey → {enabled,
27966
28071
  * weight, steps}. Absent / all-disabled ⇒ the node's single default
@@ -28510,8 +28615,9 @@ method(object({
28510
28615
  auth: "admin"
28511
28616
  }), method(object({
28512
28617
  agentNodeId: string(),
28513
- reachableHost: string().nullable()
28514
- }), object({ success: literal(true) }), {
28618
+ reachableHost: string().nullable().optional(),
28619
+ color: NodeColorIdSchema.nullable().optional()
28620
+ }).refine((v) => v.reachableHost !== void 0 || v.color !== void 0, { message: "reachableHost or color required" }), object({ success: literal(true) }), {
28515
28621
  kind: "mutation",
28516
28622
  auth: "admin"
28517
28623
  }), method(object({
@@ -31735,7 +31841,7 @@ var CustomActionInputSchema = object({
31735
31841
  action: string().min(1),
31736
31842
  input: unknown()
31737
31843
  });
31738
- method(_void(), array(AddonListItemSchema).readonly()), method(object({
31844
+ method(object({ nodeId: string().optional() }).optional(), array(AddonListItemSchema).readonly()), method(object({
31739
31845
  addonId: string(),
31740
31846
  limit: number().min(1).max(500).default(100),
31741
31847
  level: LogLevelSchema$2.optional()
@@ -36797,7 +36903,13 @@ var TopologyNodeSchema = object({
36797
36903
  })).readonly(),
36798
36904
  processes: array(TopologyProcessSchema).readonly(),
36799
36905
  categories: array(TopologyCategorySchema).readonly(),
36800
- rootPackage: TopologyRootPackageSchema.nullable()
36906
+ rootPackage: TopologyRootPackageSchema.nullable(),
36907
+ /**
36908
+ * How an online AGENT reaches the hub (mesh mTLS Release A): `tls` once it has
36909
+ * completed a mutual-TLS handshake, `clear` otherwise. Absent for the hub,
36910
+ * for offline rows and when the hub cannot tell.
36911
+ */
36912
+ meshTransport: _enum(["tls", "clear"]).optional()
36801
36913
  });
36802
36914
  var CapUsageEdgeSchema = object({
36803
36915
  callerAddonId: string(),
@@ -37210,6 +37322,7 @@ var OsdNamedTemplateSchema = object({
37210
37322
  });
37211
37323
  /** Where a slot's value comes from. */
37212
37324
  var OsdSourceSchema = discriminatedUnion("kind", [
37325
+ object({ kind: literal("none") }),
37213
37326
  object({
37214
37327
  kind: literal("static"),
37215
37328
  text: string().max(64)
@@ -37336,6 +37449,13 @@ method(object({ deviceId: number().int() }), object({
37336
37449
  }), object({ success: literal(true) }), {
37337
37450
  kind: "mutation",
37338
37451
  auth: "admin"
37452
+ }), method(object({
37453
+ deviceId: number().int(),
37454
+ slotId: string().min(1),
37455
+ enabled: boolean()
37456
+ }), object({ success: literal(true) }), {
37457
+ kind: "mutation",
37458
+ auth: "admin"
37339
37459
  }), method(object({
37340
37460
  sourceDeviceId: number().int(),
37341
37461
  targetDeviceId: number().int()
@@ -37767,7 +37887,15 @@ var GpuInfoSchema = object({
37767
37887
  name: string(),
37768
37888
  memoryMB: number().optional()
37769
37889
  });
37770
- var NpuInfoSchema = object({ type: _enum(["apple-ane", "intel-npu"]) });
37890
+ var NpuInfoSchema = object({
37891
+ type: _enum([
37892
+ "apple-ane",
37893
+ "intel-npu",
37894
+ "amd-xdna"
37895
+ ]),
37896
+ name: string().optional(),
37897
+ generation: _enum(["xdna1", "xdna2"]).optional()
37898
+ });
37771
37899
  var CoralInfoSchema = object({
37772
37900
  type: literal("coral-edgetpu"),
37773
37901
  bus: string().optional()
@@ -42510,9 +42638,11 @@ var zoneRulesCapability = {
42510
42638
  * once is what makes a second provider (RunPod, a local NVIDIA node) a new
42511
42639
  * manifest entry and nothing else.
42512
42640
  *
42513
- * Collection, routed by the `addonId` in every single-row input (the `llm` /
42514
- * `notification-output` posture); `describe` concat-fans across providers.
42515
- * Every method is `admin`: these spend money.
42641
+ * Collection of provider **types** (addons). Each addon owns zero or more
42642
+ * **entries** (credentials + defaults). Concat-fans: `describe`,
42643
+ * `describeTypes`, `listEntries`, `listJobs`. Single-row work is keyed by
42644
+ * `entryId`; callers also pass the owning `addonId` as the collection
42645
+ * selector (broker posture). Every method is `admin`: these spend money.
42516
42646
  *
42517
42647
  * Every cloud object a provider creates is tagged with the orchestrator's
42518
42648
  * `jobKey`, so a retried submit finds the job it already started instead of
@@ -42536,8 +42666,8 @@ var TrainingRegionOptionSchema = object({
42536
42666
  priceMultiplier: number().positive()
42537
42667
  });
42538
42668
  /**
42539
- * The provider's per-account settings, as the orchestrator reads them. They
42540
- * live in the PROVIDER addon's settings (operator decision 2026-10-08: they
42669
+ * The provider's per-entry settings, as the orchestrator reads them. They
42670
+ * live on the PROVIDER addon's entry (operator decision 2026-10-08: they
42541
42671
  * depend on the user's account), never hard-coded in the orchestrator.
42542
42672
  */
42543
42673
  var TrainingProviderDefaultsSchema = object({
@@ -42548,9 +42678,44 @@ var TrainingProviderDefaultsSchema = object({
42548
42678
  /** Hours a FAILED job's cloud dataset is kept for debugging; 0 = delete at once. */
42549
42679
  failedDatasetGraceHours: number().nonnegative()
42550
42680
  });
42681
+ /**
42682
+ * Entry form schema for a provider type — same seam as notification
42683
+ * `TargetKind.configSchema` (`z.unknown()` at the wire; callers tighten to
42684
+ * {@link ConfigUISchema}). Drives `ConfigFormBuilder` on Training → Providers.
42685
+ */
42686
+ var ConfigSchemaPassthrough = unknown();
42687
+ /** One creatable provider type, for the Add-entry dialog. */
42688
+ var TrainingProviderTypeSchema = object({
42689
+ typeId: string(),
42690
+ label: string(),
42691
+ /** Path under the addon package (e.g. `assets/training-modal/icon.svg`). */
42692
+ iconAsset: string(),
42693
+ /** Owning `training-provider` addon — collection selector for createEntry. */
42694
+ addonId: string(),
42695
+ /**
42696
+ * Fields for one entry of this type (credentials + defaults). Absent on a
42697
+ * type that only needs a name. Password fields are keychain-backed on the
42698
+ * provider addon (`secretStatePaths`), not D634 plaintext.
42699
+ */
42700
+ configSchema: ConfigSchemaPassthrough.optional()
42701
+ });
42702
+ /** One configured account / workspace under a provider type. */
42703
+ var TrainingProviderEntrySchema = object({
42704
+ entryId: string(),
42705
+ typeId: string(),
42706
+ name: string(),
42707
+ addonId: string(),
42708
+ /** Credentials are present — never the values. */
42709
+ configured: boolean()
42710
+ });
42551
42711
  var TrainingProviderDescriptorSchema = object({
42552
42712
  addonId: string(),
42553
- /** `modal`, `runpod`, `fake`, … */
42713
+ entryId: string(),
42714
+ typeId: string(),
42715
+ /** Operator-chosen entry name. */
42716
+ name: string(),
42717
+ iconAsset: string(),
42718
+ /** `modal`, `runpod`, `fake`, … — same as typeId for current providers. */
42554
42719
  kind: string(),
42555
42720
  label: string(),
42556
42721
  gpuTypes: array(TrainingGpuOptionSchema).readonly(),
@@ -42562,7 +42727,30 @@ var TrainingProviderDescriptorSchema = object({
42562
42727
  dataResidencyNote: string(),
42563
42728
  /** Credentials are present — never the values. */
42564
42729
  configured: boolean(),
42565
- defaults: TrainingProviderDefaultsSchema
42730
+ defaults: TrainingProviderDefaultsSchema,
42731
+ /**
42732
+ * Values for {@link TrainingProviderTypeSchema}'s `configSchema` — password
42733
+ * fields are keychain {@link SecretFieldView} or `null` / `''` (create),
42734
+ * never plaintext. Same hydrate contract as settings forms (D789).
42735
+ */
42736
+ formValues: record(string(), unknown()).optional()
42737
+ });
42738
+ /**
42739
+ * Patch one entry's name, credentials and defaults. Pin with owning `{ addonId }`.
42740
+ * An omitted or empty `tokenSecret` means KEEP the stored secret (D787).
42741
+ * `{ $secretClear: true }` clears it.
42742
+ */
42743
+ var TrainingProviderUpdateEntryInputSchema = object({
42744
+ entryId: string().min(1),
42745
+ name: string().min(1),
42746
+ tokenId: string().optional(),
42747
+ tokenSecret: union([string(), object({ $secretClear: literal(true) })]).optional(),
42748
+ environment: string().optional(),
42749
+ gpuType: string().optional(),
42750
+ region: string().optional(),
42751
+ costCapUsd: number().nonnegative().optional(),
42752
+ maxRuntimeSec: number().int().positive().optional(),
42753
+ failedDatasetGraceHours: number().nonnegative().optional()
42566
42754
  });
42567
42755
  var TrainingCredentialCheckSchema = object({
42568
42756
  ok: boolean(),
@@ -42614,20 +42802,33 @@ var TrainerSourceRefSchema = object({
42614
42802
  /** A commit sha (never a branch) — the job must be reproducible. */
42615
42803
  revision: string().regex(/^[0-9a-f]{7,64}$/)
42616
42804
  });
42805
+ /** Cloud job identity — route with the owning addon's `addonId` selector. */
42617
42806
  var JobRef = {
42618
- addonId: string(),
42807
+ entryId: string().min(1),
42619
42808
  jobKey: string().uuid()
42620
42809
  };
42621
42810
  var TrainingLogLineSchema = object({
42622
42811
  ts: number(),
42623
42812
  text: string()
42624
42813
  });
42625
- method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "admin" }), method(object({ addonId: string() }), TrainingCredentialCheckSchema, {
42814
+ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "admin" }), method(object({}), array(TrainingProviderTypeSchema).readonly(), { auth: "admin" }), method(object({}), array(TrainingProviderEntrySchema).readonly(), { auth: "admin" }), method(object({
42815
+ typeId: string().min(1),
42816
+ name: string().min(1)
42817
+ }), object({ entryId: string() }), {
42818
+ kind: "mutation",
42819
+ auth: "admin"
42820
+ }), method(object({ entryId: string().min(1) }), object({ ok: literal(true) }), {
42821
+ kind: "mutation",
42822
+ auth: "admin"
42823
+ }), method(TrainingProviderUpdateEntryInputSchema, object({ ok: literal(true) }), {
42824
+ kind: "mutation",
42825
+ auth: "admin"
42826
+ }), method(object({ entryId: string().min(1) }), TrainingCredentialCheckSchema, {
42626
42827
  kind: "mutation",
42627
42828
  auth: "admin",
42628
42829
  timeoutMs: 3e4
42629
42830
  }), method(object({
42630
- addonId: string(),
42831
+ entryId: string().min(1),
42631
42832
  gpuType: string(),
42632
42833
  region: string(),
42633
42834
  datasetBytes: number().int().nonnegative(),
@@ -42693,7 +42894,7 @@ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "
42693
42894
  kind: "mutation",
42694
42895
  auth: "admin",
42695
42896
  timeoutMs: 5 * 6e4
42696
- }), method(object({ addonId: string() }), array(ProviderJobStatusSchema).readonly(), {
42897
+ }), method(object({ entryId: string().min(1).optional() }), array(ProviderJobStatusSchema).readonly(), {
42697
42898
  auth: "admin",
42698
42899
  timeoutMs: 2 * 6e4
42699
42900
  });
@@ -42703,20 +42904,31 @@ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "
42703
42904
  *
42704
42905
  * It owns what every provider must agree on, written once:
42705
42906
  *
42706
- * - **Dataset versions.** Taken over from pipeline-analytics (D796): the rows
42707
- * live here (D808); pipeline-analytics still CUTS a version (it owns the corpus and
42708
- * the export plan) and reaches this store through the five row methods
42709
- * below, so the Retrain page and the export did not change.
42710
42907
  * - **Jobs.** A persisted state machine, a reconcile loop against the
42711
42908
  * provider, a cost guard, a daily orphan sweep and the retention rules.
42712
42909
  * - **The return flow.** Verified artefacts → Model Studio
42713
42910
  * (`custom-model-registry.importModelBundle`) → canary on cameras →
42714
42911
  * rollback. Nothing is ever registered automatically.
42715
42912
  *
42913
+ * Plan/start takes a live {@link TrainingCorpusSelection} (collections +
42914
+ * work-state rule); frame ids are resolved via pipeline-analytics at that
42915
+ * moment and snapshotted on the job. No frozen dataset version.
42916
+ *
42716
42917
  * Every method is `admin`.
42717
42918
  */
42718
- /** A version WITH its frame list — what the export and a job read. */
42719
- var TrainingDatasetVersionRowSchema = RetrainDatasetVersionSchema.omit({ frameCount: true }).extend({ frameIds: array(string()).max(2e4).readonly() });
42919
+ /**
42920
+ * Live corpus criteria for plan/start (design §5.2). Default is complete-only.
42921
+ * Frame ids are resolved at plan/start — never a frozen version id.
42922
+ */
42923
+ var TrainingCorpusSelectionSchema = object({
42924
+ collectionIds: array(string()).min(1),
42925
+ /** Default complete-only for v1 */
42926
+ workState: _enum([
42927
+ "complete",
42928
+ "annotated_or_complete",
42929
+ "any_annotated"
42930
+ ]).default("complete")
42931
+ });
42720
42932
  /** A base model a detector job can fine-tune, and the baseline it is judged against. */
42721
42933
  var TrainingBaseModelSchema = object({
42722
42934
  modelId: string(),
@@ -42734,9 +42946,13 @@ var TrainingPresetSchema = _enum([
42734
42946
  "thorough"
42735
42947
  ]);
42736
42948
  var TrainingJobRequestSchema = object({
42737
- datasetVersionId: string().min(1),
42738
- /** The `training-provider` addon that runs it. */
42739
- addonId: string().min(1),
42949
+ /** Live collection + work-state criteria; resolved at plan/start. */
42950
+ selection: TrainingCorpusSelectionSchema,
42951
+ /**
42952
+ * The provider **entry** that runs it (credentials + defaults).
42953
+ * Resolve to an owning addon via `training-provider.describe` / `listEntries`.
42954
+ */
42955
+ entryId: string().min(1),
42740
42956
  gpuType: string().min(1),
42741
42957
  region: string(),
42742
42958
  baseModelId: string().min(1),
@@ -42795,6 +43011,7 @@ var TrainingJobPlanSchema = object({
42795
43011
  * result lives after the operator acted on it.
42796
43012
  */
42797
43013
  var TrainingJobStateSchema = _enum([
43014
+ "queued",
42798
43015
  "uploading",
42799
43016
  "submitted",
42800
43017
  "starting",
@@ -42848,6 +43065,11 @@ var TrainingJobSchema = object({
42848
43065
  createdAt: number(),
42849
43066
  updatedAt: number(),
42850
43067
  state: TrainingJobStateSchema,
43068
+ /**
43069
+ * Shared by every job enqueued together via `startJobBatch`.
43070
+ * `null` for a lone `startJob`. The engine advances queued siblings by this id.
43071
+ */
43072
+ batchId: string().nullable().default(null),
42851
43073
  stage: TrainingStageSchema.nullable(),
42852
43074
  failure: object({
42853
43075
  reason: TrainingFailureReasonSchema,
@@ -42859,6 +43081,12 @@ var TrainingJobSchema = object({
42859
43081
  maxRuntimeSec: number().int().positive(),
42860
43082
  trainer: TrainerSourceRefSchema,
42861
43083
  datasetLayout: RetrainExportLayoutSchema,
43084
+ /** Frame count snapshotted when the job started (audit; equals `frameIds.length`). */
43085
+ frameCount: number().int().nonnegative(),
43086
+ /** Resolved frame ids at start — the archive ships exactly these. */
43087
+ frameIds: array(string()).max(2e4).readonly(),
43088
+ /** Hash of what those frames taught at start (trainer `dataset.annotationHash`). */
43089
+ annotationHash: string(),
42862
43090
  dataset: object({
42863
43091
  bytes: number().int(),
42864
43092
  sha256: string(),
@@ -42900,13 +43128,7 @@ var TrainingJobSchema = object({
42900
43128
  canary: TrainingCanarySchema.nullable()
42901
43129
  });
42902
43130
  var IdInput = object({ id: string().min(1) });
42903
- method(TrainingDatasetVersionRowSchema, object({ stored: boolean() }), {
42904
- kind: "mutation",
42905
- auth: "admin"
42906
- }), 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() }), {
42907
- kind: "mutation",
42908
- auth: "admin"
42909
- }), method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" }), method(TrainingJobRequestSchema, TrainingJobPlanSchema, {
43131
+ method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" }), method(TrainingJobRequestSchema, TrainingJobPlanSchema, {
42910
43132
  auth: "admin",
42911
43133
  timeoutMs: 6e4
42912
43134
  }), method(TrainingJobRequestSchema.extend({
@@ -42925,6 +43147,24 @@ method(TrainingDatasetVersionRowSchema, object({ stored: boolean() }), {
42925
43147
  kind: "mutation",
42926
43148
  auth: "admin",
42927
43149
  timeoutMs: 12e4
43150
+ }), method(TrainingJobRequestSchema.omit({ baseModelId: true }).extend({
43151
+ baseModelIds: array(string().min(1)).min(1),
43152
+ name: string().min(1).max(120),
43153
+ maxCostUsd: number().positive(),
43154
+ maxRuntimeSec: number().int().positive(),
43155
+ idempotencyKey: string().min(8).max(80)
43156
+ }), discriminatedUnion("kind", [object({
43157
+ kind: literal("started"),
43158
+ batchId: string(),
43159
+ jobs: array(TrainingJobSchema).min(1).readonly()
43160
+ }), object({
43161
+ kind: literal("refused"),
43162
+ reason: TrainingRefusalReasonSchema,
43163
+ detail: string()
43164
+ })]), {
43165
+ kind: "mutation",
43166
+ auth: "admin",
43167
+ timeoutMs: 12e4
42928
43168
  }), method(object({}), array(TrainingJobSchema).readonly(), { auth: "admin" }), method(IdInput, TrainingJobSchema.nullable(), { auth: "admin" }), method(IdInput, TrainingJobSchema, {
42929
43169
  kind: "mutation",
42930
43170
  auth: "admin",
@@ -48006,6 +48246,36 @@ Object.freeze({
48006
48246
  addonId: null,
48007
48247
  access: "view"
48008
48248
  },
48249
+ "oidcConnections.connectionFormSchema": {
48250
+ capName: "oidc-connections",
48251
+ capScope: "system",
48252
+ addonId: null,
48253
+ access: "view"
48254
+ },
48255
+ "oidcConnections.createConnection": {
48256
+ capName: "oidc-connections",
48257
+ capScope: "system",
48258
+ addonId: null,
48259
+ access: "create"
48260
+ },
48261
+ "oidcConnections.deleteConnection": {
48262
+ capName: "oidc-connections",
48263
+ capScope: "system",
48264
+ addonId: null,
48265
+ access: "delete"
48266
+ },
48267
+ "oidcConnections.listConnections": {
48268
+ capName: "oidc-connections",
48269
+ capScope: "system",
48270
+ addonId: null,
48271
+ access: "view"
48272
+ },
48273
+ "oidcConnections.updateConnection": {
48274
+ capName: "oidc-connections",
48275
+ capScope: "system",
48276
+ addonId: null,
48277
+ access: "create"
48278
+ },
48009
48279
  "osd.getStatus": {
48010
48280
  capName: "osd",
48011
48281
  capScope: "device",
@@ -48078,6 +48348,12 @@ Object.freeze({
48078
48348
  addonId: null,
48079
48349
  access: "create"
48080
48350
  },
48351
+ "osdManager.setSlotCameraEnabled": {
48352
+ capName: "osd-manager",
48353
+ capScope: "system",
48354
+ addonId: null,
48355
+ access: "create"
48356
+ },
48081
48357
  "osdManager.upsertTemplate": {
48082
48358
  capName: "osd-manager",
48083
48359
  capScope: "system",
@@ -48216,12 +48492,6 @@ Object.freeze({
48216
48492
  addonId: null,
48217
48493
  access: "create"
48218
48494
  },
48219
- "pipelineAnalytics.createRetrainDatasetVersion": {
48220
- capName: "pipeline-analytics",
48221
- capScope: "device",
48222
- addonId: null,
48223
- access: "create"
48224
- },
48225
48495
  "pipelineAnalytics.deleteDeviceEvents": {
48226
48496
  capName: "pipeline-analytics",
48227
48497
  capScope: "device",
@@ -48234,12 +48504,6 @@ Object.freeze({
48234
48504
  addonId: null,
48235
48505
  access: "delete"
48236
48506
  },
48237
- "pipelineAnalytics.deleteRetrainDatasetVersion": {
48238
- capName: "pipeline-analytics",
48239
- capScope: "device",
48240
- addonId: null,
48241
- access: "delete"
48242
- },
48243
48507
  "pipelineAnalytics.deleteTracks": {
48244
48508
  capName: "pipeline-analytics",
48245
48509
  capScope: "device",
@@ -48342,6 +48606,12 @@ Object.freeze({
48342
48606
  addonId: null,
48343
48607
  access: "view"
48344
48608
  },
48609
+ "pipelineAnalytics.getRetrainCorpusKpi": {
48610
+ capName: "pipeline-analytics",
48611
+ capScope: "device",
48612
+ addonId: null,
48613
+ access: "view"
48614
+ },
48345
48615
  "pipelineAnalytics.getRetrainExportUrl": {
48346
48616
  capName: "pipeline-analytics",
48347
48617
  capScope: "device",
@@ -48462,7 +48732,7 @@ Object.freeze({
48462
48732
  addonId: null,
48463
48733
  access: "view"
48464
48734
  },
48465
- "pipelineAnalytics.listRetrainDatasetVersions": {
48735
+ "pipelineAnalytics.listRetrainCorpusPage": {
48466
48736
  capName: "pipeline-analytics",
48467
48737
  capScope: "device",
48468
48738
  addonId: null,
@@ -48516,12 +48786,6 @@ Object.freeze({
48516
48786
  addonId: null,
48517
48787
  access: "create"
48518
48788
  },
48519
- "pipelineAnalytics.previewRetrainDataset": {
48520
- capName: "pipeline-analytics",
48521
- capScope: "device",
48522
- addonId: null,
48523
- access: "view"
48524
- },
48525
48789
  "pipelineAnalytics.proposeRetrainAnnotations": {
48526
48790
  capName: "pipeline-analytics",
48527
48791
  capScope: "device",
@@ -48600,6 +48864,12 @@ Object.freeze({
48600
48864
  addonId: null,
48601
48865
  access: "create"
48602
48866
  },
48867
+ "pipelineAnalytics.resolveRetrainTrainingCorpus": {
48868
+ capName: "pipeline-analytics",
48869
+ capScope: "device",
48870
+ addonId: null,
48871
+ access: "view"
48872
+ },
48603
48873
  "pipelineAnalytics.restageRetrainTrack": {
48604
48874
  capName: "pipeline-analytics",
48605
48875
  capScope: "device",
@@ -48660,12 +48930,6 @@ Object.freeze({
48660
48930
  addonId: null,
48661
48931
  access: "create"
48662
48932
  },
48663
- "pipelineAnalytics.verifyRetrainDatasetVersion": {
48664
- capName: "pipeline-analytics",
48665
- capScope: "device",
48666
- addonId: null,
48667
- access: "view"
48668
- },
48669
48933
  "pipelineAnalytics.wipeAllAnalytics": {
48670
48934
  capName: "pipeline-analytics",
48671
48935
  capScope: "device",
@@ -51060,18 +51324,6 @@ Object.freeze({
51060
51324
  addonId: null,
51061
51325
  access: "create"
51062
51326
  },
51063
- "training.findDatasetVersionIdByName": {
51064
- capName: "training",
51065
- capScope: "system",
51066
- addonId: null,
51067
- access: "view"
51068
- },
51069
- "training.getDatasetVersion": {
51070
- capName: "training",
51071
- capScope: "system",
51072
- addonId: null,
51073
- access: "view"
51074
- },
51075
51327
  "training.getJob": {
51076
51328
  capName: "training",
51077
51329
  capScope: "system",
@@ -51090,12 +51342,6 @@ Object.freeze({
51090
51342
  addonId: null,
51091
51343
  access: "view"
51092
51344
  },
51093
- "training.listDatasetVersions": {
51094
- capName: "training",
51095
- capScope: "system",
51096
- addonId: null,
51097
- access: "view"
51098
- },
51099
51345
  "training.listJobs": {
51100
51346
  capName: "training",
51101
51347
  capScope: "system",
@@ -51108,54 +51354,66 @@ Object.freeze({
51108
51354
  addonId: null,
51109
51355
  access: "view"
51110
51356
  },
51111
- "training.putDatasetVersion": {
51357
+ "training.registerResult": {
51112
51358
  capName: "training",
51113
51359
  capScope: "system",
51114
51360
  addonId: null,
51115
51361
  access: "create"
51116
51362
  },
51117
- "training.registerResult": {
51363
+ "training.rollbackCanary": {
51118
51364
  capName: "training",
51119
51365
  capScope: "system",
51120
51366
  addonId: null,
51121
51367
  access: "create"
51122
51368
  },
51123
- "training.removeDatasetVersion": {
51369
+ "training.startJob": {
51124
51370
  capName: "training",
51125
51371
  capScope: "system",
51126
51372
  addonId: null,
51127
- access: "delete"
51373
+ access: "create"
51128
51374
  },
51129
- "training.rollbackCanary": {
51375
+ "training.startJobBatch": {
51130
51376
  capName: "training",
51131
51377
  capScope: "system",
51132
51378
  addonId: null,
51133
51379
  access: "create"
51134
51380
  },
51135
- "training.startJob": {
51136
- capName: "training",
51381
+ "trainingProvider.cancelJob": {
51382
+ capName: "training-provider",
51137
51383
  capScope: "system",
51138
51384
  addonId: null,
51139
51385
  access: "create"
51140
51386
  },
51141
- "trainingProvider.cancelJob": {
51387
+ "trainingProvider.cleanupJob": {
51142
51388
  capName: "training-provider",
51143
51389
  capScope: "system",
51144
51390
  addonId: null,
51145
51391
  access: "create"
51146
51392
  },
51147
- "trainingProvider.cleanupJob": {
51393
+ "trainingProvider.createEntry": {
51148
51394
  capName: "training-provider",
51149
51395
  capScope: "system",
51150
51396
  addonId: null,
51151
51397
  access: "create"
51152
51398
  },
51399
+ "trainingProvider.deleteEntry": {
51400
+ capName: "training-provider",
51401
+ capScope: "system",
51402
+ addonId: null,
51403
+ access: "delete"
51404
+ },
51153
51405
  "trainingProvider.describe": {
51154
51406
  capName: "training-provider",
51155
51407
  capScope: "system",
51156
51408
  addonId: null,
51157
51409
  access: "view"
51158
51410
  },
51411
+ "trainingProvider.describeTypes": {
51412
+ capName: "training-provider",
51413
+ capScope: "system",
51414
+ addonId: null,
51415
+ access: "view"
51416
+ },
51159
51417
  "trainingProvider.estimateJob": {
51160
51418
  capName: "training-provider",
51161
51419
  capScope: "system",
@@ -51168,6 +51426,12 @@ Object.freeze({
51168
51426
  addonId: null,
51169
51427
  access: "view"
51170
51428
  },
51429
+ "trainingProvider.listEntries": {
51430
+ capName: "training-provider",
51431
+ capScope: "system",
51432
+ addonId: null,
51433
+ access: "view"
51434
+ },
51171
51435
  "trainingProvider.listJobEvents": {
51172
51436
  capName: "training-provider",
51173
51437
  capScope: "system",
@@ -51198,6 +51462,12 @@ Object.freeze({
51198
51462
  addonId: null,
51199
51463
  access: "create"
51200
51464
  },
51465
+ "trainingProvider.updateEntry": {
51466
+ capName: "training-provider",
51467
+ capScope: "system",
51468
+ addonId: null,
51469
+ access: "create"
51470
+ },
51201
51471
  "trainingProvider.uploadDataset": {
51202
51472
  capName: "training-provider",
51203
51473
  capScope: "system",
@@ -54404,6 +54674,11 @@ Object.freeze({
54404
54674
  form: "single",
54405
54675
  optional: false
54406
54676
  }],
54677
+ "osdManager.setSlotCameraEnabled": [{
54678
+ name: "deviceId",
54679
+ form: "single",
54680
+ optional: false
54681
+ }],
54407
54682
  "petFeeder.callPet": [{
54408
54683
  name: "deviceId",
54409
54684
  form: "single",
@@ -54624,6 +54899,11 @@ Object.freeze({
54624
54899
  form: "array",
54625
54900
  optional: false
54626
54901
  }],
54902
+ "pipelineAnalytics.listRetrainCorpusPage": [{
54903
+ name: "deviceIds",
54904
+ form: "array",
54905
+ optional: true
54906
+ }],
54627
54907
  "pipelineAnalytics.listRetrainStaging": [{
54628
54908
  name: "deviceIds",
54629
54909
  form: "array",
@@ -55733,6 +56013,7 @@ Object.freeze({
55733
56013
  });
55734
56014
  Object.freeze({
55735
56015
  "broker": "broker",
56016
+ "calendar-source": "calendar",
55736
56017
  "device-export": "device-export",
55737
56018
  "llm": "ai",
55738
56019
  "mesh-network": "mesh",
@@ -56218,6 +56499,8 @@ var STATE_SUMMARY_VARS = [
56218
56499
  [...RULE_TEXT],
56219
56500
  [...RULE_TEXT],
56220
56501
  [...RULE_TEXT],
56502
+ [...RULE_TEXT],
56503
+ [...RULE_TEXT],
56221
56504
  ([...RULE_TEXT], [...UPDATES]),
56222
56505
  ([...RULE_TEXT], [...PACKAGE_UPDATES]),
56223
56506
  ([...RULE_TEXT], [...PACKAGE_UPDATES]),