@camstack/addon-export-hap 1.2.156 → 1.2.158

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.
@@ -5426,7 +5426,7 @@ var ZodIssueCode = {
5426
5426
  var ZodFirstPartyTypeKind;
5427
5427
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5428
5428
  //#endregion
5429
- //#region ../types/dist/sleep-r3RWkGVx.mjs
5429
+ //#region ../types/dist/sleep-DwAQ9sqX.mjs
5430
5430
  /**
5431
5431
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5432
5432
  * window to float samples (D455).
@@ -10019,6 +10019,16 @@ var CompositionSchema = object({
10019
10019
  seen.add(feature.cap);
10020
10020
  });
10021
10021
  });
10022
+ var NodeColorIdSchema = _enum([
10023
+ "node-a",
10024
+ "node-b",
10025
+ "node-c",
10026
+ "node-d",
10027
+ "node-e",
10028
+ "node-f",
10029
+ "node-g",
10030
+ "node-h"
10031
+ ]);
10022
10032
  new Set([
10023
10033
  "track",
10024
10034
  "face",
@@ -19063,14 +19073,14 @@ var LlmProfileSchema = object({
19063
19073
  /** ConfigUISchema tree passed through untyped on the wire (the
19064
19074
  * notification-output `ConfigSchemaPassthrough` precedent at
19065
19075
  * notification-output.cap.ts:151); the exported TS type re-tightens it. */
19066
- var ConfigSchemaPassthrough$1 = unknown();
19076
+ var ConfigSchemaPassthrough$3 = unknown();
19067
19077
  var LlmProfileKindDescriptorSchema = object({
19068
19078
  kind: LlmProfileKindSchema,
19069
19079
  label: string(),
19070
19080
  icon: string(),
19071
19081
  /** Stamped by each provider so the concat-fanned catalog stays routable. */
19072
19082
  addonId: string(),
19073
- configSchema: ConfigSchemaPassthrough$1
19083
+ configSchema: ConfigSchemaPassthrough$3
19074
19084
  });
19075
19085
  var LlmDefaultSelectorSchema = union([object({ consumer: string() }), object({ purpose: _enum(["text", "vision"]) })]);
19076
19086
  var LlmDefaultSchema = object({
@@ -20191,7 +20201,7 @@ var TargetKindCapsSchema = object({
20191
20201
  * the union is large and not meant for runtime validation here; the exported
20192
20202
  * `TargetKind` type re-tightens `configSchema` to `ConfigUISchema`.
20193
20203
  */
20194
- var ConfigSchemaPassthrough = unknown();
20204
+ var ConfigSchemaPassthrough$2 = unknown();
20195
20205
  var TargetKindSchema = object({
20196
20206
  kind: string(),
20197
20207
  label: string(),
@@ -20228,7 +20238,7 @@ var TargetKindSchema = object({
20228
20238
  * its raster path, which is the safe default for an unknown image.
20229
20239
  */
20230
20240
  iconMediaType: string().optional(),
20231
- configSchema: ConfigSchemaPassthrough,
20241
+ configSchema: ConfigSchemaPassthrough$2,
20232
20242
  /**
20233
20243
  * The config keys that decide WHERE this kind's secrets are sent (server,
20234
20244
  * base URL, instance, chat, recipient). A save that changes any of them
@@ -23527,6 +23537,61 @@ var OauthIntegrationDescriptorSchema = object({
23527
23537
  });
23528
23538
  method(_void(), OauthIntegrationDescriptorSchema, { auth: "admin" });
23529
23539
  /**
23540
+ * `oidc-connections` — CRUD for IdP rows under `auth-oidc` (D828 sibling).
23541
+ *
23542
+ * One hub-only singleton (`auth-oidc`). The Settings UI is a DataTable +
23543
+ * ItemFormDialog; there is no `editable-array` in `globalSettingsSchema`.
23544
+ * Operator-chosen `id` is the URL slug (`/addon/auth-oidc/<id>/…`) and is
23545
+ * immutable after create.
23546
+ */
23547
+ var ConfigSchemaPassthrough$1 = unknown();
23548
+ var OidcConnectionSchema = object({
23549
+ id: string().min(1),
23550
+ displayName: string(),
23551
+ icon: string(),
23552
+ issuerUrl: string(),
23553
+ clientId: string(),
23554
+ /** Client id + secret present — never the secret value. */
23555
+ configured: boolean(),
23556
+ /**
23557
+ * Values for the connection form schema. `clientSecret` is a keychain
23558
+ * {@link SecretFieldView} or `null` / `''`, never plaintext (D789).
23559
+ */
23560
+ formValues: record(string(), unknown()).optional()
23561
+ });
23562
+ /**
23563
+ * Patch one connection. Omitted or empty `clientSecret` keeps the stored
23564
+ * secret (D787). `{ $secretClear: true }` clears it. `id` is never renamed.
23565
+ */
23566
+ var OidcConnectionUpdateInputSchema = object({
23567
+ id: string().min(1),
23568
+ displayName: string().min(1),
23569
+ icon: string().optional(),
23570
+ issuerUrl: string().optional(),
23571
+ clientId: string().optional(),
23572
+ clientSecret: union([string(), object({ $secretClear: literal(true) })]).optional(),
23573
+ redirectUri: string().optional(),
23574
+ scopes: string().optional(),
23575
+ usernameClaim: _enum([
23576
+ "preferred_username",
23577
+ "email",
23578
+ "sub"
23579
+ ]).optional()
23580
+ });
23581
+ method(object({}), ConfigSchemaPassthrough$1, { auth: "admin" }), method(object({}), array(OidcConnectionSchema).readonly(), { auth: "admin" }), method(object({
23582
+ id: string().min(1).regex(/^[a-z0-9][a-z0-9-]{0,63}$/, "id must be a lowercase slug"),
23583
+ displayName: string().min(1)
23584
+ }), object({ id: string() }), {
23585
+ kind: "mutation",
23586
+ auth: "admin"
23587
+ }), method(OidcConnectionUpdateInputSchema, object({ ok: literal(true) }), {
23588
+ kind: "mutation",
23589
+ auth: "admin"
23590
+ }), method(object({ id: string().min(1) }), object({ ok: literal(true) }), {
23591
+ kind: "mutation",
23592
+ auth: "admin"
23593
+ });
23594
+ /**
23530
23595
  * What started a camera's onboard motion (D672). `camera` is the camera's own
23531
23596
  * firmware; `sensor` is a device the operator ATTACHED to it. Absent on the
23532
23597
  * wire means the camera: only the camera-sensors bridge ever says `sensor`.
@@ -24883,24 +24948,69 @@ var RetrainFrameListSchema = object({
24883
24948
  /** What the page pre-selects — the native key frame when one survives. */
24884
24949
  autoPickMediaId: number().int().optional()
24885
24950
  });
24951
+ /** Exclusive partition of a corpus copy's annotation progress (design §4.2). */
24952
+ var RetrainFrameWorkStateSchema = _enum([
24953
+ "unannotated",
24954
+ "annotated",
24955
+ "complete"
24956
+ ]);
24957
+ /**
24958
+ * Filters for paginated corpus list, KPI, and matching export (design §4.4).
24959
+ * Every narrowing field is ANDed; omitted fields impose no constraint.
24960
+ */
24961
+ var RetrainCorpusFilterSchema = object({
24962
+ workState: RetrainFrameWorkStateSchema.optional(),
24963
+ deviceIds: array(number()).max(500).optional(),
24964
+ /** When set, only frames in this named collection. */
24965
+ collectionId: string().optional(),
24966
+ /** Frames that carry at least one saved annotation in one of these classes. */
24967
+ classes: array(RetrainMacroClassSchema).optional(),
24968
+ page: number().int().positive().default(1),
24969
+ pageSize: number().int().positive().max(100).default(50)
24970
+ });
24971
+ var RetrainCorpusPageSchema = object({
24972
+ frames: array(RetrainFrameSchema.extend({ workState: RetrainFrameWorkStateSchema })).readonly(),
24973
+ total: number().int().nonnegative(),
24974
+ page: number().int().positive(),
24975
+ pageSize: number().int().positive()
24976
+ });
24977
+ var RetrainCorpusKpiCameraRowSchema = object({
24978
+ deviceId: number(),
24979
+ unannotated: number().int().nonnegative(),
24980
+ annotated: number().int().nonnegative(),
24981
+ complete: number().int().nonnegative(),
24982
+ /** This camera's `complete` count divided by corpus `total`, in `[0,1]`.
24983
+ * `null` when the corpus is empty (no ratio). */
24984
+ pctOfCorpus: number().min(0).max(1).nullable()
24985
+ });
24986
+ var RetrainCorpusKpiSchema = object({
24987
+ total: number().int().nonnegative(),
24988
+ unannotated: number().int().nonnegative(),
24989
+ annotated: number().int().nonnegative(),
24990
+ complete: number().int().nonnegative(),
24991
+ cameras: array(RetrainCorpusKpiCameraRowSchema).readonly()
24992
+ });
24886
24993
  /**
24887
24994
  * Which frames an annotated export carries. Every field narrows; an empty
24888
- * filter is every annotated copy. A dataset VERSION is a frozen `frameIds`
24889
- * list owned by whoever trains (the training orchestrator), so `frameIds` is
24890
- * the primitive a version export uses; `batchId` re-selects what an earlier
24891
- * export carried (`exportedInBatch`).
24995
+ * filter is every annotated copy. `frameIds` is the primitive a job or
24996
+ * download uses; `batchId` re-selects what an earlier export carried
24997
+ * (`exportedInBatch`). Frozen dataset versions were removed — live selection
24998
+ * resolves to `frameIds` at plan/start.
24892
24999
  */
24893
25000
  var RetrainExportFilterSchema = object({
24894
25001
  deviceIds: array(number()).optional(),
24895
25002
  frameIds: array(string()).max(2e4).optional(),
24896
25003
  /** Only frames in at least one of these named collections. */
24897
25004
  collectionIds: array(string()).max(200).optional(),
24898
- /** Exactly the frames of this dataset version (and its completeOnly). An
24899
- * unknown id selects nothing. */
24900
- datasetVersionId: string().optional(),
25005
+ /** Single collection (Frames filter bar). ANDed with `collectionIds` when both set. */
25006
+ collectionId: string().optional(),
24901
25007
  batchId: string().optional(),
24902
25008
  /** Only frames the operator marked complete (all subjects boxed). */
24903
- completeOnly: boolean().optional()
25009
+ completeOnly: boolean().optional(),
25010
+ /** Exclusive work-state partition (`workStateOf`); same as the corpus list. */
25011
+ workState: RetrainFrameWorkStateSchema.optional(),
25012
+ /** Frames with at least one saved annotation in one of these classes. */
25013
+ classes: array(RetrainMacroClassSchema).optional()
24904
25014
  });
24905
25015
  /**
24906
25016
  * `frames`: the full frame copies, boxes in `annotations.json`.
@@ -25100,8 +25210,7 @@ var RetrainDatasetStatsSchema = object({
25100
25210
  completeFrames: number().int()
25101
25211
  })).readonly()
25102
25212
  });
25103
- /** An immutable dataset version, without its frame list. */
25104
- var RetrainDatasetVersionSchema = object({
25213
+ object({
25105
25214
  id: string(),
25106
25215
  name: string(),
25107
25216
  createdAt: number(),
@@ -25109,22 +25218,33 @@ var RetrainDatasetVersionSchema = object({
25109
25218
  layout: RetrainExportLayoutSchema,
25110
25219
  completeOnly: boolean(),
25111
25220
  frameCount: number().int(),
25112
- /** sha256 of what the frames taught when the version was frozen. */
25113
25221
  annotationHash: string(),
25114
- /** The export manifest schema the version was cut under. */
25115
25222
  manifestSchema: string(),
25116
25223
  stats: RetrainDatasetStatsSchema
25117
25224
  });
25118
- var CreateRetrainDatasetVersionResultSchema = discriminatedUnion("kind", [object({
25119
- kind: literal("created"),
25120
- version: RetrainDatasetVersionSchema
25225
+ /**
25226
+ * Live training corpus criteria — same shape as `TrainingCorpusSelection` on
25227
+ * the training cap. Resolved here so plan/start and the annotated export share
25228
+ * one definition of "the frames" (`buildRetrainExportPlan`).
25229
+ */
25230
+ var RetrainTrainingCorpusSelectionSchema = object({
25231
+ collectionIds: array(string()).min(1),
25232
+ workState: _enum([
25233
+ "complete",
25234
+ "annotated_or_complete",
25235
+ "any_annotated"
25236
+ ]).default("complete")
25237
+ });
25238
+ var RetrainTrainingCorpusResolveResultSchema = discriminatedUnion("kind", [object({
25239
+ kind: literal("resolved"),
25240
+ frameIds: array(string()).max(2e4).readonly(),
25241
+ stats: RetrainDatasetStatsSchema,
25242
+ annotationHash: string(),
25243
+ layout: RetrainExportLayoutSchema
25121
25244
  }), object({
25122
25245
  kind: literal("refused"),
25123
- reason: _enum([
25124
- "empty-name",
25125
- "duplicate-name",
25126
- "no-frames"
25127
- ])
25246
+ reason: _enum(["unknown-collection", "no-frames"]),
25247
+ detail: string()
25128
25248
  })]);
25129
25249
  /** The outcome of a lifecycle move owned by the retrain page. */
25130
25250
  var RetrainTransitionResultSchema = object({
@@ -25831,6 +25951,12 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25831
25951
  }), array(RetrainTrackSchema).readonly(), {
25832
25952
  kind: "query",
25833
25953
  auth: "admin"
25954
+ }), method(RetrainCorpusFilterSchema, RetrainCorpusPageSchema, {
25955
+ kind: "query",
25956
+ auth: "admin"
25957
+ }), method(object({}), RetrainCorpusKpiSchema, {
25958
+ kind: "query",
25959
+ auth: "admin"
25834
25960
  }), method(object({ trackId: string() }), RetrainFrameListSchema, {
25835
25961
  kind: "query",
25836
25962
  auth: "admin"
@@ -25926,36 +26052,6 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25926
26052
  kind: "mutation",
25927
26053
  auth: "admin",
25928
26054
  timeoutMs: 12e4
25929
- }), method(object({
25930
- selection: RetrainDatasetSelectionSchema,
25931
- completeOnly: boolean().optional()
25932
- }), RetrainDatasetStatsSchema, {
25933
- kind: "query",
25934
- auth: "admin"
25935
- }), method(object({
25936
- name: string().max(120),
25937
- selection: RetrainDatasetSelectionSchema,
25938
- layout: RetrainExportLayoutSchema,
25939
- completeOnly: boolean()
25940
- }), CreateRetrainDatasetVersionResultSchema, {
25941
- kind: "mutation",
25942
- auth: "admin",
25943
- timeoutMs: 12e4
25944
- }), method(object({}), array(RetrainDatasetVersionSchema).readonly(), {
25945
- kind: "query",
25946
- auth: "admin"
25947
- }), method(object({ id: string() }), object({ deleted: boolean() }), {
25948
- kind: "mutation",
25949
- auth: "admin"
25950
- }), method(object({ id: string() }), object({
25951
- found: boolean(),
25952
- annotationHash: string(),
25953
- matches: boolean(),
25954
- missingFrames: number().int()
25955
- }), {
25956
- kind: "query",
25957
- auth: "admin",
25958
- timeoutMs: 12e4
25959
26055
  }), method(object({}), array(RetrainAssistProfileSchema).readonly(), {
25960
26056
  kind: "query",
25961
26057
  auth: "admin"
@@ -25982,6 +26078,10 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
25982
26078
  }), method(object({}), array(RetrainCollectionSchema).readonly(), {
25983
26079
  kind: "query",
25984
26080
  auth: "admin"
26081
+ }), method(RetrainTrainingCorpusSelectionSchema, RetrainTrainingCorpusResolveResultSchema, {
26082
+ kind: "query",
26083
+ auth: "admin",
26084
+ timeoutMs: 6e4
25985
26085
  }), method(object({
25986
26086
  id: string(),
25987
26087
  name: string().max(120)
@@ -26598,11 +26698,14 @@ var HardwareClassIdSchema = _enum([
26598
26698
  "intel-n-series",
26599
26699
  "apple-m-base",
26600
26700
  "apple-m-pro",
26701
+ "amd-phoenix",
26601
26702
  "unknown"
26602
26703
  ]);
26603
26704
  var AcceleratorKindSchema = _enum([
26604
26705
  "intel-npu",
26605
26706
  "intel-igpu",
26707
+ "amd-igpu",
26708
+ "amd-npu",
26606
26709
  "x86-cpu",
26607
26710
  "arm-cpu",
26608
26711
  "apple-ane",
@@ -28492,6 +28595,8 @@ var AgentPipelineSettingsSchema = object({
28492
28595
  * address is wrong (multi-homed host, NAT, custom interface).
28493
28596
  */
28494
28597
  reachableHost: string().optional(),
28598
+ /** Hub-persisted UI colour (`--color-node-*` theme tokens). */
28599
+ color: NodeColorIdSchema.optional(),
28495
28600
  /**
28496
28601
  * Multi-device inference opt-in (Phase 4). Per-node map deviceKey → {enabled,
28497
28602
  * weight, steps}. Absent / all-disabled ⇒ the node's single default
@@ -29041,8 +29146,9 @@ method(object({
29041
29146
  auth: "admin"
29042
29147
  }), method(object({
29043
29148
  agentNodeId: string(),
29044
- reachableHost: string().nullable()
29045
- }), object({ success: literal(true) }), {
29149
+ reachableHost: string().nullable().optional(),
29150
+ color: NodeColorIdSchema.nullable().optional()
29151
+ }).refine((v) => v.reachableHost !== void 0 || v.color !== void 0, { message: "reachableHost or color required" }), object({ success: literal(true) }), {
29046
29152
  kind: "mutation",
29047
29153
  auth: "admin"
29048
29154
  }), method(object({
@@ -32282,7 +32388,7 @@ var CustomActionInputSchema = object({
32282
32388
  action: string().min(1),
32283
32389
  input: unknown()
32284
32390
  });
32285
- method(_void(), array(AddonListItemSchema).readonly()), method(object({
32391
+ method(object({ nodeId: string().optional() }).optional(), array(AddonListItemSchema).readonly()), method(object({
32286
32392
  addonId: string(),
32287
32393
  limit: number().min(1).max(500).default(100),
32288
32394
  level: LogLevelSchema$2.optional()
@@ -35865,7 +35971,13 @@ var TopologyNodeSchema = object({
35865
35971
  })).readonly(),
35866
35972
  processes: array(TopologyProcessSchema).readonly(),
35867
35973
  categories: array(TopologyCategorySchema).readonly(),
35868
- rootPackage: TopologyRootPackageSchema.nullable()
35974
+ rootPackage: TopologyRootPackageSchema.nullable(),
35975
+ /**
35976
+ * How an online AGENT reaches the hub (mesh mTLS Release A): `tls` once it has
35977
+ * completed a mutual-TLS handshake, `clear` otherwise. Absent for the hub,
35978
+ * for offline rows and when the hub cannot tell.
35979
+ */
35980
+ meshTransport: _enum(["tls", "clear"]).optional()
35869
35981
  });
35870
35982
  var CapUsageEdgeSchema = object({
35871
35983
  callerAddonId: string(),
@@ -36205,6 +36317,7 @@ var OsdNamedTemplateSchema = object({
36205
36317
  });
36206
36318
  /** Where a slot's value comes from. */
36207
36319
  var OsdSourceSchema = discriminatedUnion("kind", [
36320
+ object({ kind: literal("none") }),
36208
36321
  object({
36209
36322
  kind: literal("static"),
36210
36323
  text: string().max(64)
@@ -36331,6 +36444,13 @@ method(object({ deviceId: number().int() }), object({
36331
36444
  }), object({ success: literal(true) }), {
36332
36445
  kind: "mutation",
36333
36446
  auth: "admin"
36447
+ }), method(object({
36448
+ deviceId: number().int(),
36449
+ slotId: string().min(1),
36450
+ enabled: boolean()
36451
+ }), object({ success: literal(true) }), {
36452
+ kind: "mutation",
36453
+ auth: "admin"
36334
36454
  }), method(object({
36335
36455
  sourceDeviceId: number().int(),
36336
36456
  targetDeviceId: number().int()
@@ -36711,7 +36831,15 @@ var GpuInfoSchema = object({
36711
36831
  name: string(),
36712
36832
  memoryMB: number().optional()
36713
36833
  });
36714
- var NpuInfoSchema = object({ type: _enum(["apple-ane", "intel-npu"]) });
36834
+ var NpuInfoSchema = object({
36835
+ type: _enum([
36836
+ "apple-ane",
36837
+ "intel-npu",
36838
+ "amd-xdna"
36839
+ ]),
36840
+ name: string().optional(),
36841
+ generation: _enum(["xdna1", "xdna2"]).optional()
36842
+ });
36715
36843
  var CoralInfoSchema = object({
36716
36844
  type: literal("coral-edgetpu"),
36717
36845
  bus: string().optional()
@@ -40498,9 +40626,11 @@ DeviceType.Camera, method(object({
40498
40626
  * once is what makes a second provider (RunPod, a local NVIDIA node) a new
40499
40627
  * manifest entry and nothing else.
40500
40628
  *
40501
- * Collection, routed by the `addonId` in every single-row input (the `llm` /
40502
- * `notification-output` posture); `describe` concat-fans across providers.
40503
- * Every method is `admin`: these spend money.
40629
+ * Collection of provider **types** (addons). Each addon owns zero or more
40630
+ * **entries** (credentials + defaults). Concat-fans: `describe`,
40631
+ * `describeTypes`, `listEntries`, `listJobs`. Single-row work is keyed by
40632
+ * `entryId`; callers also pass the owning `addonId` as the collection
40633
+ * selector (broker posture). Every method is `admin`: these spend money.
40504
40634
  *
40505
40635
  * Every cloud object a provider creates is tagged with the orchestrator's
40506
40636
  * `jobKey`, so a retried submit finds the job it already started instead of
@@ -40524,8 +40654,8 @@ var TrainingRegionOptionSchema = object({
40524
40654
  priceMultiplier: number().positive()
40525
40655
  });
40526
40656
  /**
40527
- * The provider's per-account settings, as the orchestrator reads them. They
40528
- * live in the PROVIDER addon's settings (operator decision 2026-10-08: they
40657
+ * The provider's per-entry settings, as the orchestrator reads them. They
40658
+ * live on the PROVIDER addon's entry (operator decision 2026-10-08: they
40529
40659
  * depend on the user's account), never hard-coded in the orchestrator.
40530
40660
  */
40531
40661
  var TrainingProviderDefaultsSchema = object({
@@ -40536,9 +40666,44 @@ var TrainingProviderDefaultsSchema = object({
40536
40666
  /** Hours a FAILED job's cloud dataset is kept for debugging; 0 = delete at once. */
40537
40667
  failedDatasetGraceHours: number().nonnegative()
40538
40668
  });
40669
+ /**
40670
+ * Entry form schema for a provider type — same seam as notification
40671
+ * `TargetKind.configSchema` (`z.unknown()` at the wire; callers tighten to
40672
+ * {@link ConfigUISchema}). Drives `ConfigFormBuilder` on Training → Providers.
40673
+ */
40674
+ var ConfigSchemaPassthrough = unknown();
40675
+ /** One creatable provider type, for the Add-entry dialog. */
40676
+ var TrainingProviderTypeSchema = object({
40677
+ typeId: string(),
40678
+ label: string(),
40679
+ /** Path under the addon package (e.g. `assets/training-modal/icon.svg`). */
40680
+ iconAsset: string(),
40681
+ /** Owning `training-provider` addon — collection selector for createEntry. */
40682
+ addonId: string(),
40683
+ /**
40684
+ * Fields for one entry of this type (credentials + defaults). Absent on a
40685
+ * type that only needs a name. Password fields are keychain-backed on the
40686
+ * provider addon (`secretStatePaths`), not D634 plaintext.
40687
+ */
40688
+ configSchema: ConfigSchemaPassthrough.optional()
40689
+ });
40690
+ /** One configured account / workspace under a provider type. */
40691
+ var TrainingProviderEntrySchema = object({
40692
+ entryId: string(),
40693
+ typeId: string(),
40694
+ name: string(),
40695
+ addonId: string(),
40696
+ /** Credentials are present — never the values. */
40697
+ configured: boolean()
40698
+ });
40539
40699
  var TrainingProviderDescriptorSchema = object({
40540
40700
  addonId: string(),
40541
- /** `modal`, `runpod`, `fake`, … */
40701
+ entryId: string(),
40702
+ typeId: string(),
40703
+ /** Operator-chosen entry name. */
40704
+ name: string(),
40705
+ iconAsset: string(),
40706
+ /** `modal`, `runpod`, `fake`, … — same as typeId for current providers. */
40542
40707
  kind: string(),
40543
40708
  label: string(),
40544
40709
  gpuTypes: array(TrainingGpuOptionSchema).readonly(),
@@ -40550,7 +40715,30 @@ var TrainingProviderDescriptorSchema = object({
40550
40715
  dataResidencyNote: string(),
40551
40716
  /** Credentials are present — never the values. */
40552
40717
  configured: boolean(),
40553
- defaults: TrainingProviderDefaultsSchema
40718
+ defaults: TrainingProviderDefaultsSchema,
40719
+ /**
40720
+ * Values for {@link TrainingProviderTypeSchema}'s `configSchema` — password
40721
+ * fields are keychain {@link SecretFieldView} or `null` / `''` (create),
40722
+ * never plaintext. Same hydrate contract as settings forms (D789).
40723
+ */
40724
+ formValues: record(string(), unknown()).optional()
40725
+ });
40726
+ /**
40727
+ * Patch one entry's name, credentials and defaults. Pin with owning `{ addonId }`.
40728
+ * An omitted or empty `tokenSecret` means KEEP the stored secret (D787).
40729
+ * `{ $secretClear: true }` clears it.
40730
+ */
40731
+ var TrainingProviderUpdateEntryInputSchema = object({
40732
+ entryId: string().min(1),
40733
+ name: string().min(1),
40734
+ tokenId: string().optional(),
40735
+ tokenSecret: union([string(), object({ $secretClear: literal(true) })]).optional(),
40736
+ environment: string().optional(),
40737
+ gpuType: string().optional(),
40738
+ region: string().optional(),
40739
+ costCapUsd: number().nonnegative().optional(),
40740
+ maxRuntimeSec: number().int().positive().optional(),
40741
+ failedDatasetGraceHours: number().nonnegative().optional()
40554
40742
  });
40555
40743
  var TrainingCredentialCheckSchema = object({
40556
40744
  ok: boolean(),
@@ -40602,20 +40790,33 @@ var TrainerSourceRefSchema = object({
40602
40790
  /** A commit sha (never a branch) — the job must be reproducible. */
40603
40791
  revision: string().regex(/^[0-9a-f]{7,64}$/)
40604
40792
  });
40793
+ /** Cloud job identity — route with the owning addon's `addonId` selector. */
40605
40794
  var JobRef = {
40606
- addonId: string(),
40795
+ entryId: string().min(1),
40607
40796
  jobKey: string().uuid()
40608
40797
  };
40609
40798
  var TrainingLogLineSchema = object({
40610
40799
  ts: number(),
40611
40800
  text: string()
40612
40801
  });
40613
- method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "admin" }), method(object({ addonId: string() }), TrainingCredentialCheckSchema, {
40802
+ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "admin" }), method(object({}), array(TrainingProviderTypeSchema).readonly(), { auth: "admin" }), method(object({}), array(TrainingProviderEntrySchema).readonly(), { auth: "admin" }), method(object({
40803
+ typeId: string().min(1),
40804
+ name: string().min(1)
40805
+ }), object({ entryId: string() }), {
40806
+ kind: "mutation",
40807
+ auth: "admin"
40808
+ }), method(object({ entryId: string().min(1) }), object({ ok: literal(true) }), {
40809
+ kind: "mutation",
40810
+ auth: "admin"
40811
+ }), method(TrainingProviderUpdateEntryInputSchema, object({ ok: literal(true) }), {
40812
+ kind: "mutation",
40813
+ auth: "admin"
40814
+ }), method(object({ entryId: string().min(1) }), TrainingCredentialCheckSchema, {
40614
40815
  kind: "mutation",
40615
40816
  auth: "admin",
40616
40817
  timeoutMs: 3e4
40617
40818
  }), method(object({
40618
- addonId: string(),
40819
+ entryId: string().min(1),
40619
40820
  gpuType: string(),
40620
40821
  region: string(),
40621
40822
  datasetBytes: number().int().nonnegative(),
@@ -40681,7 +40882,7 @@ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "
40681
40882
  kind: "mutation",
40682
40883
  auth: "admin",
40683
40884
  timeoutMs: 5 * 6e4
40684
- }), method(object({ addonId: string() }), array(ProviderJobStatusSchema).readonly(), {
40885
+ }), method(object({ entryId: string().min(1).optional() }), array(ProviderJobStatusSchema).readonly(), {
40685
40886
  auth: "admin",
40686
40887
  timeoutMs: 2 * 6e4
40687
40888
  });
@@ -40691,20 +40892,31 @@ method(object({}), array(TrainingProviderDescriptorSchema).readonly(), { auth: "
40691
40892
  *
40692
40893
  * It owns what every provider must agree on, written once:
40693
40894
  *
40694
- * - **Dataset versions.** Taken over from pipeline-analytics (D796): the rows
40695
- * live here (D808); pipeline-analytics still CUTS a version (it owns the corpus and
40696
- * the export plan) and reaches this store through the five row methods
40697
- * below, so the Retrain page and the export did not change.
40698
40895
  * - **Jobs.** A persisted state machine, a reconcile loop against the
40699
40896
  * provider, a cost guard, a daily orphan sweep and the retention rules.
40700
40897
  * - **The return flow.** Verified artefacts → Model Studio
40701
40898
  * (`custom-model-registry.importModelBundle`) → canary on cameras →
40702
40899
  * rollback. Nothing is ever registered automatically.
40703
40900
  *
40901
+ * Plan/start takes a live {@link TrainingCorpusSelection} (collections +
40902
+ * work-state rule); frame ids are resolved via pipeline-analytics at that
40903
+ * moment and snapshotted on the job. No frozen dataset version.
40904
+ *
40704
40905
  * Every method is `admin`.
40705
40906
  */
40706
- /** A version WITH its frame list — what the export and a job read. */
40707
- var TrainingDatasetVersionRowSchema = RetrainDatasetVersionSchema.omit({ frameCount: true }).extend({ frameIds: array(string()).max(2e4).readonly() });
40907
+ /**
40908
+ * Live corpus criteria for plan/start (design §5.2). Default is complete-only.
40909
+ * Frame ids are resolved at plan/start — never a frozen version id.
40910
+ */
40911
+ var TrainingCorpusSelectionSchema = object({
40912
+ collectionIds: array(string()).min(1),
40913
+ /** Default complete-only for v1 */
40914
+ workState: _enum([
40915
+ "complete",
40916
+ "annotated_or_complete",
40917
+ "any_annotated"
40918
+ ]).default("complete")
40919
+ });
40708
40920
  /** A base model a detector job can fine-tune, and the baseline it is judged against. */
40709
40921
  var TrainingBaseModelSchema = object({
40710
40922
  modelId: string(),
@@ -40722,9 +40934,13 @@ var TrainingPresetSchema = _enum([
40722
40934
  "thorough"
40723
40935
  ]);
40724
40936
  var TrainingJobRequestSchema = object({
40725
- datasetVersionId: string().min(1),
40726
- /** The `training-provider` addon that runs it. */
40727
- addonId: string().min(1),
40937
+ /** Live collection + work-state criteria; resolved at plan/start. */
40938
+ selection: TrainingCorpusSelectionSchema,
40939
+ /**
40940
+ * The provider **entry** that runs it (credentials + defaults).
40941
+ * Resolve to an owning addon via `training-provider.describe` / `listEntries`.
40942
+ */
40943
+ entryId: string().min(1),
40728
40944
  gpuType: string().min(1),
40729
40945
  region: string(),
40730
40946
  baseModelId: string().min(1),
@@ -40783,6 +40999,7 @@ var TrainingJobPlanSchema = object({
40783
40999
  * result lives after the operator acted on it.
40784
41000
  */
40785
41001
  var TrainingJobStateSchema = _enum([
41002
+ "queued",
40786
41003
  "uploading",
40787
41004
  "submitted",
40788
41005
  "starting",
@@ -40836,6 +41053,11 @@ var TrainingJobSchema = object({
40836
41053
  createdAt: number(),
40837
41054
  updatedAt: number(),
40838
41055
  state: TrainingJobStateSchema,
41056
+ /**
41057
+ * Shared by every job enqueued together via `startJobBatch`.
41058
+ * `null` for a lone `startJob`. The engine advances queued siblings by this id.
41059
+ */
41060
+ batchId: string().nullable().default(null),
40839
41061
  stage: TrainingStageSchema.nullable(),
40840
41062
  failure: object({
40841
41063
  reason: TrainingFailureReasonSchema,
@@ -40847,6 +41069,12 @@ var TrainingJobSchema = object({
40847
41069
  maxRuntimeSec: number().int().positive(),
40848
41070
  trainer: TrainerSourceRefSchema,
40849
41071
  datasetLayout: RetrainExportLayoutSchema,
41072
+ /** Frame count snapshotted when the job started (audit; equals `frameIds.length`). */
41073
+ frameCount: number().int().nonnegative(),
41074
+ /** Resolved frame ids at start — the archive ships exactly these. */
41075
+ frameIds: array(string()).max(2e4).readonly(),
41076
+ /** Hash of what those frames taught at start (trainer `dataset.annotationHash`). */
41077
+ annotationHash: string(),
40850
41078
  dataset: object({
40851
41079
  bytes: number().int(),
40852
41080
  sha256: string(),
@@ -40888,13 +41116,7 @@ var TrainingJobSchema = object({
40888
41116
  canary: TrainingCanarySchema.nullable()
40889
41117
  });
40890
41118
  var IdInput = object({ id: string().min(1) });
40891
- method(TrainingDatasetVersionRowSchema, object({ stored: boolean() }), {
40892
- kind: "mutation",
40893
- auth: "admin"
40894
- }), 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() }), {
40895
- kind: "mutation",
40896
- auth: "admin"
40897
- }), method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" }), method(TrainingJobRequestSchema, TrainingJobPlanSchema, {
41119
+ method(object({}), array(TrainingBaseModelSchema).readonly(), { auth: "admin" }), method(TrainingJobRequestSchema, TrainingJobPlanSchema, {
40898
41120
  auth: "admin",
40899
41121
  timeoutMs: 6e4
40900
41122
  }), method(TrainingJobRequestSchema.extend({
@@ -40913,6 +41135,24 @@ method(TrainingDatasetVersionRowSchema, object({ stored: boolean() }), {
40913
41135
  kind: "mutation",
40914
41136
  auth: "admin",
40915
41137
  timeoutMs: 12e4
41138
+ }), method(TrainingJobRequestSchema.omit({ baseModelId: true }).extend({
41139
+ baseModelIds: array(string().min(1)).min(1),
41140
+ name: string().min(1).max(120),
41141
+ maxCostUsd: number().positive(),
41142
+ maxRuntimeSec: number().int().positive(),
41143
+ idempotencyKey: string().min(8).max(80)
41144
+ }), discriminatedUnion("kind", [object({
41145
+ kind: literal("started"),
41146
+ batchId: string(),
41147
+ jobs: array(TrainingJobSchema).min(1).readonly()
41148
+ }), object({
41149
+ kind: literal("refused"),
41150
+ reason: TrainingRefusalReasonSchema,
41151
+ detail: string()
41152
+ })]), {
41153
+ kind: "mutation",
41154
+ auth: "admin",
41155
+ timeoutMs: 12e4
40916
41156
  }), method(object({}), array(TrainingJobSchema).readonly(), { auth: "admin" }), method(IdInput, TrainingJobSchema.nullable(), { auth: "admin" }), method(IdInput, TrainingJobSchema, {
40917
41157
  kind: "mutation",
40918
41158
  auth: "admin",
@@ -44946,6 +45186,36 @@ Object.freeze({
44946
45186
  addonId: null,
44947
45187
  access: "view"
44948
45188
  },
45189
+ "oidcConnections.connectionFormSchema": {
45190
+ capName: "oidc-connections",
45191
+ capScope: "system",
45192
+ addonId: null,
45193
+ access: "view"
45194
+ },
45195
+ "oidcConnections.createConnection": {
45196
+ capName: "oidc-connections",
45197
+ capScope: "system",
45198
+ addonId: null,
45199
+ access: "create"
45200
+ },
45201
+ "oidcConnections.deleteConnection": {
45202
+ capName: "oidc-connections",
45203
+ capScope: "system",
45204
+ addonId: null,
45205
+ access: "delete"
45206
+ },
45207
+ "oidcConnections.listConnections": {
45208
+ capName: "oidc-connections",
45209
+ capScope: "system",
45210
+ addonId: null,
45211
+ access: "view"
45212
+ },
45213
+ "oidcConnections.updateConnection": {
45214
+ capName: "oidc-connections",
45215
+ capScope: "system",
45216
+ addonId: null,
45217
+ access: "create"
45218
+ },
44949
45219
  "osd.getStatus": {
44950
45220
  capName: "osd",
44951
45221
  capScope: "device",
@@ -45018,6 +45288,12 @@ Object.freeze({
45018
45288
  addonId: null,
45019
45289
  access: "create"
45020
45290
  },
45291
+ "osdManager.setSlotCameraEnabled": {
45292
+ capName: "osd-manager",
45293
+ capScope: "system",
45294
+ addonId: null,
45295
+ access: "create"
45296
+ },
45021
45297
  "osdManager.upsertTemplate": {
45022
45298
  capName: "osd-manager",
45023
45299
  capScope: "system",
@@ -45156,12 +45432,6 @@ Object.freeze({
45156
45432
  addonId: null,
45157
45433
  access: "create"
45158
45434
  },
45159
- "pipelineAnalytics.createRetrainDatasetVersion": {
45160
- capName: "pipeline-analytics",
45161
- capScope: "device",
45162
- addonId: null,
45163
- access: "create"
45164
- },
45165
45435
  "pipelineAnalytics.deleteDeviceEvents": {
45166
45436
  capName: "pipeline-analytics",
45167
45437
  capScope: "device",
@@ -45174,12 +45444,6 @@ Object.freeze({
45174
45444
  addonId: null,
45175
45445
  access: "delete"
45176
45446
  },
45177
- "pipelineAnalytics.deleteRetrainDatasetVersion": {
45178
- capName: "pipeline-analytics",
45179
- capScope: "device",
45180
- addonId: null,
45181
- access: "delete"
45182
- },
45183
45447
  "pipelineAnalytics.deleteTracks": {
45184
45448
  capName: "pipeline-analytics",
45185
45449
  capScope: "device",
@@ -45282,6 +45546,12 @@ Object.freeze({
45282
45546
  addonId: null,
45283
45547
  access: "view"
45284
45548
  },
45549
+ "pipelineAnalytics.getRetrainCorpusKpi": {
45550
+ capName: "pipeline-analytics",
45551
+ capScope: "device",
45552
+ addonId: null,
45553
+ access: "view"
45554
+ },
45285
45555
  "pipelineAnalytics.getRetrainExportUrl": {
45286
45556
  capName: "pipeline-analytics",
45287
45557
  capScope: "device",
@@ -45402,7 +45672,7 @@ Object.freeze({
45402
45672
  addonId: null,
45403
45673
  access: "view"
45404
45674
  },
45405
- "pipelineAnalytics.listRetrainDatasetVersions": {
45675
+ "pipelineAnalytics.listRetrainCorpusPage": {
45406
45676
  capName: "pipeline-analytics",
45407
45677
  capScope: "device",
45408
45678
  addonId: null,
@@ -45456,12 +45726,6 @@ Object.freeze({
45456
45726
  addonId: null,
45457
45727
  access: "create"
45458
45728
  },
45459
- "pipelineAnalytics.previewRetrainDataset": {
45460
- capName: "pipeline-analytics",
45461
- capScope: "device",
45462
- addonId: null,
45463
- access: "view"
45464
- },
45465
45729
  "pipelineAnalytics.proposeRetrainAnnotations": {
45466
45730
  capName: "pipeline-analytics",
45467
45731
  capScope: "device",
@@ -45540,6 +45804,12 @@ Object.freeze({
45540
45804
  addonId: null,
45541
45805
  access: "create"
45542
45806
  },
45807
+ "pipelineAnalytics.resolveRetrainTrainingCorpus": {
45808
+ capName: "pipeline-analytics",
45809
+ capScope: "device",
45810
+ addonId: null,
45811
+ access: "view"
45812
+ },
45543
45813
  "pipelineAnalytics.restageRetrainTrack": {
45544
45814
  capName: "pipeline-analytics",
45545
45815
  capScope: "device",
@@ -45600,12 +45870,6 @@ Object.freeze({
45600
45870
  addonId: null,
45601
45871
  access: "create"
45602
45872
  },
45603
- "pipelineAnalytics.verifyRetrainDatasetVersion": {
45604
- capName: "pipeline-analytics",
45605
- capScope: "device",
45606
- addonId: null,
45607
- access: "view"
45608
- },
45609
45873
  "pipelineAnalytics.wipeAllAnalytics": {
45610
45874
  capName: "pipeline-analytics",
45611
45875
  capScope: "device",
@@ -48000,18 +48264,6 @@ Object.freeze({
48000
48264
  addonId: null,
48001
48265
  access: "create"
48002
48266
  },
48003
- "training.findDatasetVersionIdByName": {
48004
- capName: "training",
48005
- capScope: "system",
48006
- addonId: null,
48007
- access: "view"
48008
- },
48009
- "training.getDatasetVersion": {
48010
- capName: "training",
48011
- capScope: "system",
48012
- addonId: null,
48013
- access: "view"
48014
- },
48015
48267
  "training.getJob": {
48016
48268
  capName: "training",
48017
48269
  capScope: "system",
@@ -48030,12 +48282,6 @@ Object.freeze({
48030
48282
  addonId: null,
48031
48283
  access: "view"
48032
48284
  },
48033
- "training.listDatasetVersions": {
48034
- capName: "training",
48035
- capScope: "system",
48036
- addonId: null,
48037
- access: "view"
48038
- },
48039
48285
  "training.listJobs": {
48040
48286
  capName: "training",
48041
48287
  capScope: "system",
@@ -48048,54 +48294,66 @@ Object.freeze({
48048
48294
  addonId: null,
48049
48295
  access: "view"
48050
48296
  },
48051
- "training.putDatasetVersion": {
48297
+ "training.registerResult": {
48052
48298
  capName: "training",
48053
48299
  capScope: "system",
48054
48300
  addonId: null,
48055
48301
  access: "create"
48056
48302
  },
48057
- "training.registerResult": {
48303
+ "training.rollbackCanary": {
48058
48304
  capName: "training",
48059
48305
  capScope: "system",
48060
48306
  addonId: null,
48061
48307
  access: "create"
48062
48308
  },
48063
- "training.removeDatasetVersion": {
48309
+ "training.startJob": {
48064
48310
  capName: "training",
48065
48311
  capScope: "system",
48066
48312
  addonId: null,
48067
- access: "delete"
48313
+ access: "create"
48068
48314
  },
48069
- "training.rollbackCanary": {
48315
+ "training.startJobBatch": {
48070
48316
  capName: "training",
48071
48317
  capScope: "system",
48072
48318
  addonId: null,
48073
48319
  access: "create"
48074
48320
  },
48075
- "training.startJob": {
48076
- capName: "training",
48321
+ "trainingProvider.cancelJob": {
48322
+ capName: "training-provider",
48077
48323
  capScope: "system",
48078
48324
  addonId: null,
48079
48325
  access: "create"
48080
48326
  },
48081
- "trainingProvider.cancelJob": {
48327
+ "trainingProvider.cleanupJob": {
48082
48328
  capName: "training-provider",
48083
48329
  capScope: "system",
48084
48330
  addonId: null,
48085
48331
  access: "create"
48086
48332
  },
48087
- "trainingProvider.cleanupJob": {
48333
+ "trainingProvider.createEntry": {
48088
48334
  capName: "training-provider",
48089
48335
  capScope: "system",
48090
48336
  addonId: null,
48091
48337
  access: "create"
48092
48338
  },
48339
+ "trainingProvider.deleteEntry": {
48340
+ capName: "training-provider",
48341
+ capScope: "system",
48342
+ addonId: null,
48343
+ access: "delete"
48344
+ },
48093
48345
  "trainingProvider.describe": {
48094
48346
  capName: "training-provider",
48095
48347
  capScope: "system",
48096
48348
  addonId: null,
48097
48349
  access: "view"
48098
48350
  },
48351
+ "trainingProvider.describeTypes": {
48352
+ capName: "training-provider",
48353
+ capScope: "system",
48354
+ addonId: null,
48355
+ access: "view"
48356
+ },
48099
48357
  "trainingProvider.estimateJob": {
48100
48358
  capName: "training-provider",
48101
48359
  capScope: "system",
@@ -48108,6 +48366,12 @@ Object.freeze({
48108
48366
  addonId: null,
48109
48367
  access: "view"
48110
48368
  },
48369
+ "trainingProvider.listEntries": {
48370
+ capName: "training-provider",
48371
+ capScope: "system",
48372
+ addonId: null,
48373
+ access: "view"
48374
+ },
48111
48375
  "trainingProvider.listJobEvents": {
48112
48376
  capName: "training-provider",
48113
48377
  capScope: "system",
@@ -48138,6 +48402,12 @@ Object.freeze({
48138
48402
  addonId: null,
48139
48403
  access: "create"
48140
48404
  },
48405
+ "trainingProvider.updateEntry": {
48406
+ capName: "training-provider",
48407
+ capScope: "system",
48408
+ addonId: null,
48409
+ access: "create"
48410
+ },
48141
48411
  "trainingProvider.uploadDataset": {
48142
48412
  capName: "training-provider",
48143
48413
  capScope: "system",
@@ -51344,6 +51614,11 @@ Object.freeze({
51344
51614
  form: "single",
51345
51615
  optional: false
51346
51616
  }],
51617
+ "osdManager.setSlotCameraEnabled": [{
51618
+ name: "deviceId",
51619
+ form: "single",
51620
+ optional: false
51621
+ }],
51347
51622
  "petFeeder.callPet": [{
51348
51623
  name: "deviceId",
51349
51624
  form: "single",
@@ -51564,6 +51839,11 @@ Object.freeze({
51564
51839
  form: "array",
51565
51840
  optional: false
51566
51841
  }],
51842
+ "pipelineAnalytics.listRetrainCorpusPage": [{
51843
+ name: "deviceIds",
51844
+ form: "array",
51845
+ optional: true
51846
+ }],
51567
51847
  "pipelineAnalytics.listRetrainStaging": [{
51568
51848
  name: "deviceIds",
51569
51849
  form: "array",
@@ -52673,6 +52953,7 @@ Object.freeze({
52673
52953
  });
52674
52954
  Object.freeze({
52675
52955
  "broker": "broker",
52956
+ "calendar-source": "calendar",
52676
52957
  "device-export": "device-export",
52677
52958
  "llm": "ai",
52678
52959
  "mesh-network": "mesh",
@@ -53158,6 +53439,8 @@ var STATE_SUMMARY_VARS = [
53158
53439
  [...RULE_TEXT],
53159
53440
  [...RULE_TEXT],
53160
53441
  [...RULE_TEXT],
53442
+ [...RULE_TEXT],
53443
+ [...RULE_TEXT],
53161
53444
  ([...RULE_TEXT], [...UPDATES]),
53162
53445
  ([...RULE_TEXT], [...PACKAGE_UPDATES]),
53163
53446
  ([...RULE_TEXT], [...PACKAGE_UPDATES]),