@toolproof-core/schema 1.0.3 → 1.0.4

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 (70) hide show
  1. package/dist/generated/normalized/Genesis.json +17 -9
  2. package/dist/generated/resources/Genesis.json +19 -11
  3. package/dist/generated/schemas/Genesis.json +15 -7
  4. package/dist/generated/schemas/standalone/RawStrategy.json +15 -7
  5. package/dist/generated/schemas/standalone/RunnableStrategy.json +15 -7
  6. package/dist/generated/schemas/standalone/StrategyRun.json +15 -7
  7. package/dist/generated/{types → typesTS}/standalone/Resource_Genesis.d.ts +1 -1
  8. package/{src/generated/types → dist/generated/typesTS}/standalone/Resource_Job.d.ts +1 -1
  9. package/dist/generated/{types → typesTS}/standalone/Resource_RawStrategy.d.ts +1 -1
  10. package/{src/generated/types → dist/generated/typesTS}/standalone/Resource_ResourceType.d.ts +1 -1
  11. package/dist/generated/{types → typesTS}/standalone/Resource_RunnableStrategy.d.ts +1 -1
  12. package/dist/generated/typesTS/typesTS.d.ts +745 -0
  13. package/dist/index.d.ts +6 -9
  14. package/dist/index.js +0 -2
  15. package/dist/scripts/_lib/config.d.ts +10 -10
  16. package/dist/scripts/_lib/config.js +23 -23
  17. package/dist/scripts/extractSchemasFromResourceTypeShells.js +109 -103
  18. package/dist/scripts/generateDependencies.js +15 -14
  19. package/dist/scripts/generateSchemaShims.js +76 -84
  20. package/dist/scripts/generateStandaloneSchema.js +47 -37
  21. package/dist/scripts/generateStandaloneTypeTS.js +108 -0
  22. package/dist/scripts/generateTypesTS.js +430 -0
  23. package/dist/scripts/normalizeAnchorsToPointers.js +37 -30
  24. package/dist/scripts/wrapResourceTypesWithResourceShells.js +14 -16
  25. package/package.json +11 -12
  26. package/src/Genesis.json +2007 -1999
  27. package/{dist/generated → src/generated/dependencies}/dependencyMap.json +8 -7
  28. package/src/generated/normalized/Genesis.json +17 -9
  29. package/src/generated/resources/Genesis.json +19 -11
  30. package/src/generated/schemas/Genesis.json +15 -7
  31. package/src/generated/schemas/standalone/RawStrategy.json +15 -7
  32. package/src/generated/schemas/standalone/RunnableStrategy.json +15 -7
  33. package/src/generated/schemas/standalone/StrategyRun.json +15 -7
  34. package/src/generated/{types → typesTS}/standalone/Resource_Genesis.d.ts +1 -1
  35. package/{dist/generated/types → src/generated/typesTS}/standalone/Resource_Job.d.ts +1 -1
  36. package/src/generated/{types → typesTS}/standalone/Resource_RawStrategy.d.ts +1 -1
  37. package/{dist/generated/types → src/generated/typesTS}/standalone/Resource_ResourceType.d.ts +1 -1
  38. package/src/generated/{types → typesTS}/standalone/Resource_RunnableStrategy.d.ts +1 -1
  39. package/src/generated/typesTS/typesTS.d.ts +745 -0
  40. package/src/index.ts +67 -93
  41. package/src/scripts/_lib/config.ts +205 -205
  42. package/src/scripts/extractSchemasFromResourceTypeShells.ts +261 -218
  43. package/src/scripts/generateDependencies.ts +121 -120
  44. package/src/scripts/generateSchemaShims.ts +127 -135
  45. package/src/scripts/generateStandaloneSchema.ts +185 -175
  46. package/src/scripts/generateStandaloneTypeTS.ts +127 -0
  47. package/src/scripts/generateTypesTS.ts +532 -0
  48. package/src/scripts/normalizeAnchorsToPointers.ts +115 -123
  49. package/src/scripts/wrapResourceTypesWithResourceShells.ts +82 -84
  50. package/dist/generated/types/types.d.ts +0 -1723
  51. package/dist/scripts/generateStandaloneType.js +0 -102
  52. package/dist/scripts/generateTypes.js +0 -550
  53. package/src/generated/dependencyMap.json +0 -292
  54. package/src/generated/types/types.d.ts +0 -1723
  55. package/src/scripts/generateStandaloneType.ts +0 -119
  56. package/src/scripts/generateTypes.ts +0 -615
  57. /package/dist/generated/{types → typesTS}/standalone/Resource_Genesis.js +0 -0
  58. /package/dist/generated/{types → typesTS}/standalone/Resource_Job.js +0 -0
  59. /package/dist/generated/{types → typesTS}/standalone/Resource_RawStrategy.js +0 -0
  60. /package/dist/generated/{types → typesTS}/standalone/Resource_ResourceType.js +0 -0
  61. /package/dist/generated/{types → typesTS}/standalone/Resource_RunnableStrategy.js +0 -0
  62. /package/dist/generated/{types/types.js → typesTS/typesTS.js} +0 -0
  63. /package/dist/scripts/{generateStandaloneType.d.ts → generateStandaloneTypeTS.d.ts} +0 -0
  64. /package/dist/scripts/{generateTypes.d.ts → generateTypesTS.d.ts} +0 -0
  65. /package/src/generated/{types → typesTS}/standalone/Resource_Genesis.js +0 -0
  66. /package/src/generated/{types → typesTS}/standalone/Resource_Job.js +0 -0
  67. /package/src/generated/{types → typesTS}/standalone/Resource_RawStrategy.js +0 -0
  68. /package/src/generated/{types → typesTS}/standalone/Resource_ResourceType.js +0 -0
  69. /package/src/generated/{types → typesTS}/standalone/Resource_RunnableStrategy.js +0 -0
  70. /package/src/generated/{types/types.js → typesTS/typesTS.js} +0 -0
@@ -1,1723 +0,0 @@
1
- // Auto-generated from JSON schemas. Do not edit.
2
-
3
- /**
4
- * This interface was referenced by `GenesisJson`'s JSON-Schema
5
- * via the `definition` "Name".
6
- */
7
- export type Name =
8
- string;
9
- /**
10
- * This interface was referenced by `GenesisJson`'s JSON-Schema
11
- * via the `definition` "Description".
12
- */
13
- export type Description =
14
- string;
15
- /**
16
- * This interface was referenced by `GenesisJson`'s JSON-Schema
17
- * via the `definition` "DocumentationFacet".
18
- */
19
- export type DocumentationFacet =
20
- NameFacet & DescriptionFacet;
21
- /**
22
- * This interface was referenced by `GenesisJson`'s JSON-Schema
23
- * via the `definition` "ResourceTypeImplementationKind".
24
- */
25
- export type ResourceTypeImplementationKind =
26
- "internal-without-identity" | "internal-with-identity" | "external";
27
- /**
28
- * This interface was referenced by `GenesisJson`'s JSON-Schema
29
- * via the `definition` "Uri".
30
- */
31
- export type Uri =
32
- string;
33
- /**
34
- * This interface was referenced by `GenesisJson`'s JSON-Schema
35
- * via the `definition` "ResourceTypeIdentity".
36
- */
37
- export type ResourceTypeIdentity =
38
- `TYPE-${string}`;
39
- /**
40
- * This interface was referenced by `GenesisJson`'s JSON-Schema
41
- * via the `definition` "ResourceType".
42
- */
43
- export type ResourceType =
44
- {
45
- identity: ResourceTypeIdentity;
46
- nucleusSchema: unknown;
47
- embeddingUriMap?: {
48
- [k: string]: Uri;
49
- };
50
- generatorUriMap?: {
51
- [k: string]: Uri;
52
- };
53
- } & DocumentationFacet &
54
- ResourceTypeImplementationKindFacet;
55
- /**
56
- * This interface was referenced by `GenesisJson`'s JSON-Schema
57
- * via the `definition` "ResourceRoleIdentity".
58
- */
59
- export type ResourceRoleIdentity =
60
- `ROLE-${string}`;
61
- /**
62
- * This interface was referenced by `GenesisJson`'s JSON-Schema
63
- * via the `definition` "ResourceRoleValue".
64
- */
65
- export type ResourceRoleValue =
66
- {
67
- resourceTypeHandle: ResourceTypeIdentity;
68
- } & DocumentationFacet;
69
- /**
70
- * This interface was referenced by `GenesisJson`'s JSON-Schema
71
- * via the `definition` "Error".
72
- */
73
- export type Error =
74
- {
75
- } & DocumentationFacet & {
76
- details?: {
77
- };
78
- };
79
- /**
80
- * This interface was referenced by `GenesisJson`'s JSON-Schema
81
- * via the `definition` "Domain".
82
- */
83
- export type Domain =
84
- "internal" | "numerical" | "biological" | "logical" | "augmental";
85
- /**
86
- * This interface was referenced by `GenesisJson`'s JSON-Schema
87
- * via the `definition` "JobIdentity".
88
- */
89
- export type JobIdentity =
90
- `JOB-${string}`;
91
- /**
92
- * This interface was referenced by `GenesisJson`'s JSON-Schema
93
- * via the `definition` "Job".
94
- */
95
- export type Job =
96
- {
97
- identity: JobIdentity;
98
- implementationUri: Uri;
99
- } & DocumentationFacet &
100
- DomainFacet &
101
- RolesFacet;
102
- /**
103
- * This interface was referenced by `GenesisJson`'s JSON-Schema
104
- * via the `definition` "RoleBindingArray".
105
- */
106
- export type RoleBindingArray =
107
- ResourceRoleIdentity[];
108
- /**
109
- * This interface was referenced by `GenesisJson`'s JSON-Schema
110
- * via the `definition` "StepKind".
111
- */
112
- export type StepKind =
113
- "job" | "branch" | "while" | "for";
114
- /**
115
- * This interface was referenced by `GenesisJson`'s JSON-Schema
116
- * via the `definition` "JobStepIdentity".
117
- */
118
- export type JobStepIdentity =
119
- `JOB_STEP-${string}`;
120
- /**
121
- * This interface was referenced by `GenesisJson`'s JSON-Schema
122
- * via the `definition` "JobStep".
123
- */
124
- export type JobStep =
125
- {
126
- identity: JobStepIdentity;
127
- stepKind?: "job";
128
- jobHandle: JobIdentity;
129
- } & StepKindFacet &
130
- RoleBindingsFacet1;
131
- /**
132
- * This interface was referenced by `GenesisJson`'s JSON-Schema
133
- * via the `definition` "BranchStepIdentity".
134
- */
135
- export type BranchStepIdentity =
136
- `BRANCH_STEP-${string}`;
137
- /**
138
- * This interface was referenced by `GenesisJson`'s JSON-Schema
139
- * via the `definition` "BranchStep".
140
- */
141
- export type BranchStep =
142
- {
143
- identity: BranchStepIdentity;
144
- stepKind?: "branch";
145
- /**
146
- * @minItems 1
147
- */
148
- cases: [Conditional, ...Conditional[]];
149
- } & StepKindFacet;
150
- /**
151
- * This interface was referenced by `GenesisJson`'s JSON-Schema
152
- * via the `definition` "WhileStepIdentity".
153
- */
154
- export type WhileStepIdentity =
155
- `WHILE_STEP-${string}`;
156
- /**
157
- * This interface was referenced by `GenesisJson`'s JSON-Schema
158
- * via the `definition` "WhileStep".
159
- */
160
- export type WhileStep =
161
- {
162
- identity: WhileStepIdentity;
163
- stepKind?: "while";
164
- case: Conditional;
165
- } & StepKindFacet;
166
- /**
167
- * This interface was referenced by `GenesisJson`'s JSON-Schema
168
- * via the `definition` "ForStepIdentity".
169
- */
170
- export type ForStepIdentity =
171
- `FOR_STEP-${string}`;
172
- /**
173
- * This interface was referenced by `GenesisJson`'s JSON-Schema
174
- * via the `definition` "ForStep".
175
- */
176
- export type ForStep =
177
- {
178
- identity: ForStepIdentity;
179
- stepKind?: "for";
180
- case: Conditional;
181
- } & StepKindFacet;
182
- /**
183
- * This interface was referenced by `GenesisJson`'s JSON-Schema
184
- * via the `definition` "StepIdentity".
185
- */
186
- export type StepIdentity =
187
- JobStepIdentity | BranchStepIdentity | WhileStepIdentity | ForStepIdentity;
188
- /**
189
- * This interface was referenced by `GenesisJson`'s JSON-Schema
190
- * via the `definition` "Step".
191
- */
192
- export type Step =
193
- JobStep | BranchStep | WhileStep | ForStep;
194
- /**
195
- * This interface was referenced by `GenesisJson`'s JSON-Schema
196
- * via the `definition` "ResourceIdentity".
197
- */
198
- export type ResourceIdentity =
199
- `RESOURCE-${string}`;
200
- /**
201
- * This interface was referenced by `GenesisJson`'s JSON-Schema
202
- * via the `definition` "ResourceKind".
203
- */
204
- export type ResourceKind =
205
- "missing" | "input-potential" | "output-potential" | "materialized";
206
- /**
207
- * This interface was referenced by `GenesisJson`'s JSON-Schema
208
- * via the `definition` "ShellMissing".
209
- */
210
- export type ShellMissing =
211
- {
212
- resourceKind?: "missing";
213
- } & ResourceBase &
214
- ResourceKindFacet;
215
- /**
216
- * This interface was referenced by `GenesisJson`'s JSON-Schema
217
- * via the `definition` "ShellInputPotential".
218
- */
219
- export type ShellInputPotential =
220
- {
221
- resourceKind?: "input-potential";
222
- } & ResourceBase &
223
- CreationContextFacet &
224
- ResourceKindFacet;
225
- /**
226
- * This interface was referenced by `GenesisJson`'s JSON-Schema
227
- * via the `definition` "ShellOutputPotential".
228
- */
229
- export type ShellOutputPotential =
230
- {
231
- resourceKind?: "output-potential";
232
- } & ResourceBase &
233
- CreationContextFacet &
234
- ResourceKindFacet;
235
- /**
236
- * This interface was referenced by `GenesisJson`'s JSON-Schema
237
- * via the `definition` "Timestamp".
238
- */
239
- export type Timestamp =
240
- string;
241
- /**
242
- * This interface was referenced by `GenesisJson`'s JSON-Schema
243
- * via the `definition` "Path".
244
- */
245
- export type Path =
246
- string;
247
- /**
248
- * This interface was referenced by `GenesisJson`'s JSON-Schema
249
- * via the `definition` "ShellMaterializedBase".
250
- */
251
- export type ShellMaterializedBase =
252
- {
253
- version: 1;
254
- resourceKind?: "materialized";
255
- } & ResourceBase &
256
- CreationContextFacet &
257
- ResourceKindFacet &
258
- TimestampFacet &
259
- PathFacet;
260
- /**
261
- * This interface was referenced by `GenesisJson`'s JSON-Schema
262
- * via the `definition` "ShellMaterialized".
263
- */
264
- export type ShellMaterializedBase1 =
265
- {
266
- version: 1;
267
- resourceKind?: "materialized";
268
- } & ResourceBase &
269
- CreationContextFacet &
270
- ResourceKindFacet &
271
- TimestampFacet &
272
- PathFacet;
273
- /**
274
- * This interface was referenced by `GenesisJson`'s JSON-Schema
275
- * via the `definition` "ResourceMissing".
276
- */
277
- export type ResourceMissing =
278
- {
279
- resourceKind?: "missing";
280
- } & ResourceBase &
281
- ResourceKindFacet;
282
- /**
283
- * This interface was referenced by `GenesisJson`'s JSON-Schema
284
- * via the `definition` "ResourceInputPotential".
285
- */
286
- export type ResourceInputPotential =
287
- {
288
- resourceKind?: "input-potential";
289
- } & ResourceBase &
290
- CreationContextFacet &
291
- ResourceKindFacet;
292
- /**
293
- * This interface was referenced by `GenesisJson`'s JSON-Schema
294
- * via the `definition` "ResourceOutputPotential".
295
- */
296
- export type ResourceOutputPotential =
297
- {
298
- resourceKind?: "output-potential";
299
- } & ResourceBase &
300
- CreationContextFacet &
301
- ResourceKindFacet;
302
- /**
303
- * This interface was referenced by `GenesisJson`'s JSON-Schema
304
- * via the `definition` "JsonData".
305
- */
306
- export type JsonData =
307
- | null
308
- | boolean
309
- | number
310
- | string
311
- | JsonData
312
- | {
313
- [k: string]: JsonData;
314
- };
315
- /**
316
- * This interface was referenced by `GenesisJson`'s JSON-Schema
317
- * via the `definition` "ResourceMaterialized".
318
- */
319
- export type ResourceMaterialized =
320
- {
321
- } & ShellMaterializedBase &
322
- NucleusFacet1;
323
- /**
324
- * This interface was referenced by `GenesisJson`'s JSON-Schema
325
- * via the `definition` "Resource".
326
- */
327
- export type Resource =
328
- ResourceMissing | ResourceInputPotential | ResourceOutputPotential | ResourceMaterialized;
329
- /**
330
- * This interface was referenced by `GenesisJson`'s JSON-Schema
331
- * via the `definition` "StepArray".
332
- */
333
- export type StepArray =
334
- Step[];
335
- /**
336
- * This interface was referenced by `GenesisJson`'s JSON-Schema
337
- * via the `definition` "RawStrategy".
338
- */
339
- export type RawStrategy =
340
- {
341
- } & StepsFacet &
342
- StrategyStateFacet;
343
- /**
344
- * This interface was referenced by `GenesisJson`'s JSON-Schema
345
- * via the `definition` "RunnableStrategyIdentity".
346
- */
347
- export type RunnableStrategyIdentity =
348
- `RUNNABLE_STRATEGY-${string}`;
349
- /**
350
- * This interface was referenced by `GenesisJson`'s JSON-Schema
351
- * via the `definition` "RunnableStrategyStatus".
352
- */
353
- export type RunnableStrategyStatus =
354
- "pending" | "running" | "completed" | "failed" | "cancelled";
355
- /**
356
- * This interface was referenced by `GenesisJson`'s JSON-Schema
357
- * via the `definition` "StrategyThreadIdentity".
358
- */
359
- export type StrategyThreadIdentity =
360
- `STRATEGY_THREAD-${string}`;
361
- /**
362
- * This interface was referenced by `GenesisJson`'s JSON-Schema
363
- * via the `definition` "RunnableStrategy".
364
- */
365
- export type RunnableStrategy =
366
- {
367
- identity: RunnableStrategyIdentity;
368
- runnableStrategyContext: RunnableStrategyContext;
369
- } & StrategyThreadMapFacet1 &
370
- StrategyStateFacet1;
371
- /**
372
- * This interface was referenced by `GenesisJson`'s JSON-Schema
373
- * via the `definition` "RunnableStrategyUpdate".
374
- */
375
- export type RunnableStrategyUpdate =
376
- {
377
- runnableStrategyHandle: RunnableStrategyIdentity;
378
- runnableStrategy?: RunnableStrategy1;
379
- } & StrategyStateDelta;
380
- export type RunnableStrategy1 =
381
- {
382
- identity: RunnableStrategyIdentity;
383
- runnableStrategyContext: RunnableStrategyContext;
384
- } & StrategyThreadMapFacet1 &
385
- StrategyStateFacet1;
386
- /**
387
- * This interface was referenced by `GenesisJson`'s JSON-Schema
388
- * via the `definition` "RunEventUpdates".
389
- */
390
- export type RunEventUpdates =
391
- {
392
- stepsMutation?: {
393
- insertAt: number;
394
- inserted: StepArray;
395
- };
396
- interruptData?: {
397
- } | null;
398
- } & StrategyStateDelta;
399
- /**
400
- * This interface was referenced by `GenesisJson`'s JSON-Schema
401
- * via the `definition` "RunEventKind".
402
- */
403
- export type RunEventKind =
404
- "graph_start" | "tick" | "interrupt" | "graph_end";
405
- /**
406
- * This interface was referenced by `GenesisJson`'s JSON-Schema
407
- * via the `definition` "GraphStartRunEvent".
408
- */
409
- export type GraphStartRunEvent =
410
- RunEventBase & {
411
- runEventKind?: "graph_start";
412
- runnableStrategySeed: RunnableStrategy;
413
- };
414
- /**
415
- * This interface was referenced by `GenesisJson`'s JSON-Schema
416
- * via the `definition` "TickRunEvent".
417
- */
418
- export type TickRunEvent =
419
- RunEventBase & {
420
- runEventKind?: "tick";
421
- };
422
- /**
423
- * This interface was referenced by `GenesisJson`'s JSON-Schema
424
- * via the `definition` "InterruptRunEvent".
425
- */
426
- export type InterruptRunEvent =
427
- RunEventBase & {
428
- runEventKind?: "interrupt";
429
- };
430
- /**
431
- * This interface was referenced by `GenesisJson`'s JSON-Schema
432
- * via the `definition` "GraphEndRunEvent".
433
- */
434
- export type GraphEndRunEvent =
435
- RunEventBase & {
436
- runEventKind?: "graph_end";
437
- };
438
- /**
439
- * This interface was referenced by `GenesisJson`'s JSON-Schema
440
- * via the `definition` "RunEvent".
441
- */
442
- export type RunEvent =
443
- GraphStartRunEvent | TickRunEvent | InterruptRunEvent | GraphEndRunEvent;
444
- /**
445
- * This interface was referenced by `GenesisJson`'s JSON-Schema
446
- * via the `definition` "StrategyRunIdentity".
447
- */
448
- export type StrategyRunIdentity =
449
- `STRATEGY_RUN-${string}`;
450
- /**
451
- * This interface was referenced by `GenesisJson`'s JSON-Schema
452
- * via the `definition` "GoalIdentity".
453
- */
454
- export type GoalIdentity =
455
- `GOAL-${string}`;
456
- /**
457
- * This interface was referenced by `GenesisJson`'s JSON-Schema
458
- * via the `definition` "Goal".
459
- */
460
- export type Goal =
461
- {
462
- identity: GoalIdentity;
463
- target: number;
464
- disallowedJobs?: JobIdentity[];
465
- disallowedSequences?: JobIdentity[][];
466
- minSteps?: number;
467
- maxSteps?: number;
468
- } & DomainFacet;
469
- /**
470
- * This interface was referenced by `GenesisJson`'s JSON-Schema
471
- * via the `definition` "NaturalIdentity".
472
- */
473
- export type NaturalIdentity =
474
- number;
475
- /**
476
- * This interface was referenced by `GenesisJson`'s JSON-Schema
477
- * via the `definition` "BooleanIdentity".
478
- */
479
- export type BooleanIdentity =
480
- boolean;
481
-
482
- export interface GenesisJson {
483
- }
484
- /**
485
- * This interface was referenced by `GenesisJson`'s JSON-Schema
486
- * via the `definition` "NameFacet".
487
- */
488
- export interface NameFacet {
489
- name: Name;
490
- }
491
- /**
492
- * This interface was referenced by `GenesisJson`'s JSON-Schema
493
- * via the `definition` "DescriptionFacet".
494
- */
495
- export interface DescriptionFacet {
496
- description: Description;
497
- }
498
- /**
499
- * This interface was referenced by `GenesisJson`'s JSON-Schema
500
- * via the `definition` "ResourceTypeImplementationKindFacet".
501
- */
502
- export interface ResourceTypeImplementationKindFacet {
503
- resourceTypeImplementationKind: ResourceTypeImplementationKind;
504
- }
505
- /**
506
- * This interface was referenced by `GenesisJson`'s JSON-Schema
507
- * via the `definition` "RoleMap".
508
- */
509
- export type RoleMap = Record<ResourceRoleIdentity, ResourceRoleValue>;
510
- /**
511
- * This interface was referenced by `GenesisJson`'s JSON-Schema
512
- * via the `definition` "Roles".
513
- */
514
- export interface Roles {
515
- inputMap: RoleMap;
516
- outputMap: RoleMap & {
517
- "ROLE-ErrorOutput": ResourceRoleValue & {
518
- resourceTypeHandle: "TYPE-Error";
519
- name: "ErrorOutput";
520
- description: "Represents error outputs from job runs.";
521
- };
522
- };
523
- }
524
- /**
525
- * This interface was referenced by `GenesisJson`'s JSON-Schema
526
- * via the `definition` "RolesFacet".
527
- */
528
- export interface RolesFacet {
529
- roles: Roles;
530
- }
531
- /**
532
- * This interface was referenced by `GenesisJson`'s JSON-Schema
533
- * via the `definition` "DomainFacet".
534
- */
535
- export interface DomainFacet {
536
- domain: Domain;
537
- }
538
- /**
539
- * This interface was referenced by `GenesisJson`'s JSON-Schema
540
- * via the `definition` "RoleBindings".
541
- */
542
- export interface RoleBindings {
543
- inputBindings: RoleBindingArray;
544
- outputBindings: RoleBindingArray;
545
- }
546
- /**
547
- * This interface was referenced by `GenesisJson`'s JSON-Schema
548
- * via the `definition` "RoleBindingsFacet".
549
- */
550
- export interface RoleBindingsFacet {
551
- roleBindings: RoleBindings;
552
- }
553
- /**
554
- * This interface was referenced by `GenesisJson`'s JSON-Schema
555
- * via the `definition` "StepKindFacet".
556
- */
557
- export interface StepKindFacet {
558
- stepKind: StepKind;
559
- }
560
- export interface RoleBindingsFacet1 {
561
- roleBindings: RoleBindings;
562
- }
563
- /**
564
- * This interface was referenced by `GenesisJson`'s JSON-Schema
565
- * via the `definition` "Conditional".
566
- */
567
- export interface Conditional {
568
- when: JobStep;
569
- what: JobStep;
570
- }
571
- /**
572
- * This interface was referenced by `GenesisJson`'s JSON-Schema
573
- * via the `definition` "CreationContext".
574
- */
575
- export interface CreationContext {
576
- resourceRoleHandle: ResourceRoleIdentity;
577
- jobStepHandle: JobStepIdentity;
578
- }
579
- /**
580
- * This interface was referenced by `GenesisJson`'s JSON-Schema
581
- * via the `definition` "CreationContextFacet".
582
- */
583
- export interface CreationContextFacet {
584
- creationContext: CreationContext;
585
- }
586
- /**
587
- * This interface was referenced by `GenesisJson`'s JSON-Schema
588
- * via the `definition` "ResourceBase".
589
- */
590
- export interface ResourceBase {
591
- identity: ResourceIdentity;
592
- resourceTypeHandle: ResourceTypeIdentity;
593
- }
594
- /**
595
- * This interface was referenced by `GenesisJson`'s JSON-Schema
596
- * via the `definition` "ResourceKindFacet".
597
- */
598
- export interface ResourceKindFacet {
599
- resourceKind: ResourceKind;
600
- }
601
- /**
602
- * This interface was referenced by `GenesisJson`'s JSON-Schema
603
- * via the `definition` "TimestampFacet".
604
- */
605
- export interface TimestampFacet {
606
- timestamp: Timestamp;
607
- }
608
- /**
609
- * This interface was referenced by `GenesisJson`'s JSON-Schema
610
- * via the `definition` "PathFacet".
611
- */
612
- export interface PathFacet {
613
- path: Path;
614
- }
615
- /**
616
- * This interface was referenced by `GenesisJson`'s JSON-Schema
617
- * via the `definition` "Nucleus".
618
- */
619
- export interface Nucleus {
620
- [k: string]: JsonData;
621
- }
622
- /**
623
- * This interface was referenced by `GenesisJson`'s JSON-Schema
624
- * via the `definition` "NucleusFacet".
625
- */
626
- export interface NucleusFacet {
627
- nucleus: Nucleus;
628
- }
629
- export interface NucleusFacet1 {
630
- nucleus: Nucleus;
631
- }
632
- /**
633
- * This interface was referenced by `GenesisJson`'s JSON-Schema
634
- * via the `definition` "JobStepSocket".
635
- */
636
- export interface JobStepSocket {
637
- [k: string]: Resource;
638
- }
639
- /**
640
- * This interface was referenced by `GenesisJson`'s JSON-Schema
641
- * via the `definition` "StrategyState".
642
- */
643
- export interface StrategyState {
644
- [k: string]: JobStepSocket;
645
- }
646
- /**
647
- * This interface was referenced by `GenesisJson`'s JSON-Schema
648
- * via the `definition` "StrategyStateFacet".
649
- */
650
- export interface StrategyStateFacet {
651
- strategyState: StrategyState;
652
- }
653
- /**
654
- * This interface was referenced by `GenesisJson`'s JSON-Schema
655
- * via the `definition` "StepsFacet".
656
- */
657
- export interface StepsFacet {
658
- steps: StepArray;
659
- }
660
- /**
661
- * This interface was referenced by `GenesisJson`'s JSON-Schema
662
- * via the `definition` "RunnableStrategyContext".
663
- */
664
- export interface RunnableStrategyContext {
665
- status: RunnableStrategyStatus;
666
- startedAt?: Timestamp;
667
- completedAt?: Timestamp;
668
- }
669
- /**
670
- * This interface was referenced by `GenesisJson`'s JSON-Schema
671
- * via the `definition` "StrategyThreadMap".
672
- */
673
- export interface StrategyThreadMap {
674
- [k: string]: StepArray;
675
- }
676
- /**
677
- * This interface was referenced by `GenesisJson`'s JSON-Schema
678
- * via the `definition` "StrategyThreadMapFacet".
679
- */
680
- export interface StrategyThreadMapFacet {
681
- strategyThreadMap: StrategyThreadMap;
682
- }
683
- export interface StrategyThreadMapFacet1 {
684
- strategyThreadMap: StrategyThreadMap;
685
- }
686
- export interface StrategyStateFacet1 {
687
- strategyState: StrategyState;
688
- }
689
- /**
690
- * This interface was referenced by `GenesisJson`'s JSON-Schema
691
- * via the `definition` "StrategyStateDelta".
692
- */
693
- export interface StrategyStateDelta {
694
- strategyStateUpdate: StrategyState;
695
- }
696
- /**
697
- * This interface was referenced by `GenesisJson`'s JSON-Schema
698
- * via the `definition` "RunEventCounters".
699
- */
700
- export interface RunEventCounters {
701
- stepCounterAfter?: number;
702
- iterationCounterAfter?: number;
703
- }
704
- /**
705
- * This interface was referenced by `GenesisJson`'s JSON-Schema
706
- * via the `definition` "RunEventStepMetadata".
707
- */
708
- export interface RunEventStepMetadata {
709
- stepHandle: StepIdentity;
710
- stepKind: StepKind;
711
- threadStepIndex: number;
712
- }
713
- /**
714
- * This interface was referenced by `GenesisJson`'s JSON-Schema
715
- * via the `definition` "RunEventBase".
716
- */
717
- export interface RunEventBase {
718
- runEventKind: RunEventKind;
719
- runnableStrategyHandle: RunnableStrategyIdentity;
720
- strategyThreadHandle: StrategyThreadIdentity;
721
- createdAt: Timestamp;
722
- nodeName: string;
723
- eventSeq: number;
724
- counters?: RunEventCounters;
725
- stepMetadata?: RunEventStepMetadata;
726
- updates?: RunEventUpdates;
727
- }
728
- /**
729
- * This interface was referenced by `GenesisJson`'s JSON-Schema
730
- * via the `definition` "StrategyRun".
731
- */
732
- export interface StrategyRun {
733
- identity: StrategyRunIdentity;
734
- runnableStrategyHandle: string;
735
- recordedAt: Timestamp;
736
- runEvents: RunEvent[];
737
- }
738
- /**
739
- * This interface was referenced by `GenesisJson`'s JSON-Schema
740
- * via the `definition` "Natural".
741
- */
742
- export interface Natural {
743
- identity: NaturalIdentity;
744
- }
745
- /**
746
- * This interface was referenced by `GenesisJson`'s JSON-Schema
747
- * via the `definition` "Boolean".
748
- */
749
- export interface Boolean {
750
- identity: BooleanIdentity;
751
- }
752
-
753
- export type Normalized =
754
- {
755
- identity: GoalIdentity;
756
- target: number;
757
- disallowedJobs?: JobIdentity[];
758
- disallowedSequences?: JobIdentity[][];
759
- minSteps?: number;
760
- maxSteps?: number;
761
- } & DomainFacet;
762
- export type GoalIdentity =
763
- `GOAL-${string}`;
764
- export type JobIdentity =
765
- `JOB-${string}`;
766
- export type Domain =
767
- "internal" | "numerical" | "biological" | "logical" | "augmental";
768
-
769
- export interface DomainFacet {
770
- domain: Domain;
771
- }
772
-
773
- export type Normalized =
774
- {
775
- identity: JobIdentity;
776
- implementationUri: Uri;
777
- } & DocumentationFacet &
778
- DomainFacet &
779
- RolesFacet;
780
- export type JobIdentity =
781
- `JOB-${string}`;
782
- export type Uri =
783
- string;
784
- export type DocumentationFacet =
785
- NameFacet & DescriptionFacet;
786
- export type Name =
787
- string;
788
- export type Description =
789
- string;
790
- export type Domain =
791
- "internal" | "numerical" | "biological" | "logical" | "augmental";
792
- export type ResourceRoleValue =
793
- {
794
- resourceTypeHandle: ResourceTypeIdentity;
795
- } & DocumentationFacet;
796
- export type ResourceTypeIdentity =
797
- `TYPE-${string}`;
798
-
799
- export interface NameFacet {
800
- name: Name;
801
- }
802
- export interface DescriptionFacet {
803
- description: Description;
804
- }
805
- export interface DomainFacet {
806
- domain: Domain;
807
- }
808
- export interface RolesFacet {
809
- roles: Roles;
810
- }
811
- export interface Roles {
812
- inputMap: RoleMap;
813
- outputMap: RoleMap & {
814
- "ROLE-ErrorOutput": ResourceRoleValue & {
815
- resourceTypeHandle: "TYPE-Error";
816
- name: "ErrorOutput";
817
- description: "Represents error outputs from job runs.";
818
- };
819
- };
820
- }
821
- export type RoleMap = Record<ResourceRoleIdentity, ResourceRoleValue>;
822
-
823
- export type Normalized =
824
- {
825
- } & StepsFacet &
826
- StrategyStateFacet;
827
- export type Step =
828
- JobStep | BranchStep | WhileStep | ForStep;
829
- export type JobStep =
830
- {
831
- identity: JobStepIdentity;
832
- stepKind?: "job";
833
- jobHandle: JobIdentity;
834
- } & StepKindFacet &
835
- RoleBindingsFacet;
836
- export type JobStepIdentity =
837
- `JOB_STEP-${string}`;
838
- export type JobIdentity =
839
- `JOB-${string}`;
840
- export type StepKind =
841
- "job" | "branch" | "while" | "for";
842
- export type ResourceRoleIdentity =
843
- `ROLE-${string}`;
844
- export type RoleBindingArray =
845
- ResourceRoleIdentity[];
846
- export type BranchStep =
847
- {
848
- identity: BranchStepIdentity;
849
- stepKind?: "branch";
850
- /**
851
- * @minItems 1
852
- */
853
- cases: [Conditional, ...Conditional[]];
854
- } & StepKindFacet;
855
- export type BranchStepIdentity =
856
- `BRANCH_STEP-${string}`;
857
- export type WhileStep =
858
- {
859
- identity: WhileStepIdentity;
860
- stepKind?: "while";
861
- case: Conditional;
862
- } & StepKindFacet;
863
- export type WhileStepIdentity =
864
- `WHILE_STEP-${string}`;
865
- export type ForStep =
866
- {
867
- identity: ForStepIdentity;
868
- stepKind?: "for";
869
- case: Conditional;
870
- } & StepKindFacet;
871
- export type ForStepIdentity =
872
- `FOR_STEP-${string}`;
873
- export type StepArray =
874
- Step[];
875
- export type Resource =
876
- ResourceMissing | ResourceInputPotential | ResourceOutputPotential | ResourceMaterialized;
877
- export type ResourceMissing =
878
- {
879
- resourceKind?: "missing";
880
- } & ResourceBase &
881
- ResourceKindFacet;
882
- export type ResourceIdentity =
883
- `RESOURCE-${string}`;
884
- export type ResourceTypeIdentity =
885
- `TYPE-${string}`;
886
- export type ResourceKind =
887
- "missing" | "input-potential" | "output-potential" | "materialized";
888
- export type ResourceInputPotential =
889
- {
890
- resourceKind?: "input-potential";
891
- } & ResourceBase &
892
- CreationContextFacet &
893
- ResourceKindFacet;
894
- export type ResourceOutputPotential =
895
- {
896
- resourceKind?: "output-potential";
897
- } & ResourceBase &
898
- CreationContextFacet &
899
- ResourceKindFacet;
900
- export type ResourceMaterialized =
901
- {
902
- } & ShellMaterializedBase &
903
- NucleusFacet;
904
- export type ShellMaterializedBase =
905
- {
906
- version: 1;
907
- resourceKind?: "materialized";
908
- } & ResourceBase &
909
- CreationContextFacet &
910
- ResourceKindFacet &
911
- TimestampFacet &
912
- PathFacet;
913
- export type Timestamp =
914
- string;
915
- export type Path =
916
- string;
917
- export type JsonData =
918
- | null
919
- | boolean
920
- | number
921
- | string
922
- | JsonData
923
- | {
924
- [k: string]: JsonData;
925
- };
926
-
927
- export interface StepsFacet {
928
- steps: StepArray;
929
- }
930
- export interface StepKindFacet {
931
- stepKind: StepKind;
932
- }
933
- export interface RoleBindingsFacet {
934
- roleBindings: RoleBindings;
935
- }
936
- export interface RoleBindings {
937
- inputBindings: RoleBindingArray;
938
- outputBindings: RoleBindingArray;
939
- }
940
- export interface Conditional {
941
- when: JobStep;
942
- what: JobStep;
943
- }
944
- export interface StrategyStateFacet {
945
- strategyState: StrategyState;
946
- }
947
- export interface StrategyState {
948
- [k: string]: JobStepSocket;
949
- }
950
- export interface JobStepSocket {
951
- [k: string]: Resource;
952
- }
953
- export interface ResourceBase {
954
- identity: ResourceIdentity;
955
- resourceTypeHandle: ResourceTypeIdentity;
956
- }
957
- export interface ResourceKindFacet {
958
- resourceKind: ResourceKind;
959
- }
960
- export interface CreationContextFacet {
961
- creationContext: CreationContext;
962
- }
963
- export interface CreationContext {
964
- resourceRoleHandle: ResourceRoleIdentity;
965
- jobStepHandle: JobStepIdentity;
966
- }
967
- export interface TimestampFacet {
968
- timestamp: Timestamp;
969
- }
970
- export interface PathFacet {
971
- path: Path;
972
- }
973
- export interface NucleusFacet {
974
- nucleus: Nucleus;
975
- }
976
- export interface Nucleus {
977
- [k: string]: JsonData;
978
- }
979
-
980
- export type Normalized =
981
- {
982
- identity: ResourceTypeIdentity;
983
- nucleusSchema: unknown;
984
- embeddingUriMap?: {
985
- [k: string]: Uri;
986
- };
987
- generatorUriMap?: {
988
- [k: string]: Uri;
989
- };
990
- } & DocumentationFacet &
991
- ResourceTypeImplementationKindFacet;
992
- export type ResourceTypeIdentity =
993
- `TYPE-${string}`;
994
- export type Uri =
995
- string;
996
- export type DocumentationFacet =
997
- NameFacet & DescriptionFacet;
998
- export type Name =
999
- string;
1000
- export type Description =
1001
- string;
1002
- export type ResourceTypeImplementationKind =
1003
- "internal-without-identity" | "internal-with-identity" | "external";
1004
-
1005
- export interface NameFacet {
1006
- name: Name;
1007
- }
1008
- export interface DescriptionFacet {
1009
- description: Description;
1010
- }
1011
- export interface ResourceTypeImplementationKindFacet {
1012
- resourceTypeImplementationKind: ResourceTypeImplementationKind;
1013
- }
1014
-
1015
- export type Normalized =
1016
- {
1017
- identity: RunnableStrategyIdentity;
1018
- runnableStrategyContext: RunnableStrategyContext;
1019
- } & StrategyThreadMapFacet &
1020
- StrategyStateFacet;
1021
- export type RunnableStrategyIdentity =
1022
- `RUNNABLE_STRATEGY-${string}`;
1023
- export type RunnableStrategyStatus =
1024
- "pending" | "running" | "completed" | "failed" | "cancelled";
1025
- export type Timestamp =
1026
- string;
1027
- export type Step =
1028
- JobStep | BranchStep | WhileStep | ForStep;
1029
- export type JobStep =
1030
- {
1031
- identity: JobStepIdentity;
1032
- stepKind?: "job";
1033
- jobHandle: JobIdentity;
1034
- } & StepKindFacet &
1035
- RoleBindingsFacet;
1036
- export type JobStepIdentity =
1037
- `JOB_STEP-${string}`;
1038
- export type JobIdentity =
1039
- `JOB-${string}`;
1040
- export type StepKind =
1041
- "job" | "branch" | "while" | "for";
1042
- export type ResourceRoleIdentity =
1043
- `ROLE-${string}`;
1044
- export type RoleBindingArray =
1045
- ResourceRoleIdentity[];
1046
- export type BranchStep =
1047
- {
1048
- identity: BranchStepIdentity;
1049
- stepKind?: "branch";
1050
- /**
1051
- * @minItems 1
1052
- */
1053
- cases: [Conditional, ...Conditional[]];
1054
- } & StepKindFacet;
1055
- export type BranchStepIdentity =
1056
- `BRANCH_STEP-${string}`;
1057
- export type WhileStep =
1058
- {
1059
- identity: WhileStepIdentity;
1060
- stepKind?: "while";
1061
- case: Conditional;
1062
- } & StepKindFacet;
1063
- export type WhileStepIdentity =
1064
- `WHILE_STEP-${string}`;
1065
- export type ForStep =
1066
- {
1067
- identity: ForStepIdentity;
1068
- stepKind?: "for";
1069
- case: Conditional;
1070
- } & StepKindFacet;
1071
- export type ForStepIdentity =
1072
- `FOR_STEP-${string}`;
1073
- export type StepArray =
1074
- Step[];
1075
- export type Resource =
1076
- ResourceMissing | ResourceInputPotential | ResourceOutputPotential | ResourceMaterialized;
1077
- export type ResourceMissing =
1078
- {
1079
- resourceKind?: "missing";
1080
- } & ResourceBase &
1081
- ResourceKindFacet;
1082
- export type ResourceIdentity =
1083
- `RESOURCE-${string}`;
1084
- export type ResourceTypeIdentity =
1085
- `TYPE-${string}`;
1086
- export type ResourceKind =
1087
- "missing" | "input-potential" | "output-potential" | "materialized";
1088
- export type ResourceInputPotential =
1089
- {
1090
- resourceKind?: "input-potential";
1091
- } & ResourceBase &
1092
- CreationContextFacet &
1093
- ResourceKindFacet;
1094
- export type ResourceOutputPotential =
1095
- {
1096
- resourceKind?: "output-potential";
1097
- } & ResourceBase &
1098
- CreationContextFacet &
1099
- ResourceKindFacet;
1100
- export type ResourceMaterialized =
1101
- {
1102
- } & ShellMaterializedBase &
1103
- NucleusFacet;
1104
- export type ShellMaterializedBase =
1105
- {
1106
- version: 1;
1107
- resourceKind?: "materialized";
1108
- } & ResourceBase &
1109
- CreationContextFacet &
1110
- ResourceKindFacet &
1111
- TimestampFacet &
1112
- PathFacet;
1113
- export type Path =
1114
- string;
1115
- export type JsonData =
1116
- | null
1117
- | boolean
1118
- | number
1119
- | string
1120
- | JsonData
1121
- | {
1122
- [k: string]: JsonData;
1123
- };
1124
-
1125
- export interface RunnableStrategyContext {
1126
- status: RunnableStrategyStatus;
1127
- startedAt?: Timestamp;
1128
- completedAt?: Timestamp;
1129
- }
1130
- export interface StrategyThreadMapFacet {
1131
- strategyThreadMap: StrategyThreadMap;
1132
- }
1133
- export interface StrategyThreadMap {
1134
- [k: string]: StepArray;
1135
- }
1136
- export interface StepKindFacet {
1137
- stepKind: StepKind;
1138
- }
1139
- export interface RoleBindingsFacet {
1140
- roleBindings: RoleBindings;
1141
- }
1142
- export interface RoleBindings {
1143
- inputBindings: RoleBindingArray;
1144
- outputBindings: RoleBindingArray;
1145
- }
1146
- export interface Conditional {
1147
- when: JobStep;
1148
- what: JobStep;
1149
- }
1150
- export interface StrategyStateFacet {
1151
- strategyState: StrategyState;
1152
- }
1153
- export interface StrategyState {
1154
- [k: string]: JobStepSocket;
1155
- }
1156
- export interface JobStepSocket {
1157
- [k: string]: Resource;
1158
- }
1159
- export interface ResourceBase {
1160
- identity: ResourceIdentity;
1161
- resourceTypeHandle: ResourceTypeIdentity;
1162
- }
1163
- export interface ResourceKindFacet {
1164
- resourceKind: ResourceKind;
1165
- }
1166
- export interface CreationContextFacet {
1167
- creationContext: CreationContext;
1168
- }
1169
- export interface CreationContext {
1170
- resourceRoleHandle: ResourceRoleIdentity;
1171
- jobStepHandle: JobStepIdentity;
1172
- }
1173
- export interface TimestampFacet {
1174
- timestamp: Timestamp;
1175
- }
1176
- export interface PathFacet {
1177
- path: Path;
1178
- }
1179
- export interface NucleusFacet {
1180
- nucleus: Nucleus;
1181
- }
1182
- export interface Nucleus {
1183
- [k: string]: JsonData;
1184
- }
1185
-
1186
- /**
1187
- * This interface was referenced by `Normalized`'s JSON-Schema
1188
- * via the `definition` "StrategyRunIdentity".
1189
- */
1190
- export type StrategyRunIdentity =
1191
- `STRATEGY_RUN-${string}`;
1192
- /**
1193
- * This interface was referenced by `Normalized`'s JSON-Schema
1194
- * via the `definition` "Timestamp".
1195
- */
1196
- export type Timestamp =
1197
- string;
1198
- /**
1199
- * This interface was referenced by `Normalized`'s JSON-Schema
1200
- * via the `definition` "RunEvent".
1201
- */
1202
- export type RunEvent =
1203
- GraphStartRunEvent | TickRunEvent | InterruptRunEvent | GraphEndRunEvent;
1204
- /**
1205
- * This interface was referenced by `Normalized`'s JSON-Schema
1206
- * via the `definition` "GraphStartRunEvent".
1207
- */
1208
- export type GraphStartRunEvent =
1209
- RunEventBase & {
1210
- runEventKind?: "graph_start";
1211
- runnableStrategySeed: RunnableStrategy;
1212
- };
1213
- /**
1214
- * This interface was referenced by `Normalized`'s JSON-Schema
1215
- * via the `definition` "RunEventKind".
1216
- */
1217
- export type RunEventKind =
1218
- "graph_start" | "tick" | "interrupt" | "graph_end";
1219
- /**
1220
- * This interface was referenced by `Normalized`'s JSON-Schema
1221
- * via the `definition` "RunnableStrategyIdentity".
1222
- */
1223
- export type RunnableStrategyIdentity =
1224
- `RUNNABLE_STRATEGY-${string}`;
1225
- /**
1226
- * This interface was referenced by `Normalized`'s JSON-Schema
1227
- * via the `definition` "StrategyThreadIdentity".
1228
- */
1229
- export type StrategyThreadIdentity =
1230
- `STRATEGY_THREAD-${string}`;
1231
- /**
1232
- * This interface was referenced by `Normalized`'s JSON-Schema
1233
- * via the `definition` "StepIdentity".
1234
- */
1235
- export type StepIdentity =
1236
- JobStepIdentity | BranchStepIdentity | WhileStepIdentity | ForStepIdentity;
1237
- /**
1238
- * This interface was referenced by `Normalized`'s JSON-Schema
1239
- * via the `definition` "JobStepIdentity".
1240
- */
1241
- export type JobStepIdentity =
1242
- `JOB_STEP-${string}`;
1243
- /**
1244
- * This interface was referenced by `Normalized`'s JSON-Schema
1245
- * via the `definition` "BranchStepIdentity".
1246
- */
1247
- export type BranchStepIdentity =
1248
- `BRANCH_STEP-${string}`;
1249
- /**
1250
- * This interface was referenced by `Normalized`'s JSON-Schema
1251
- * via the `definition` "WhileStepIdentity".
1252
- */
1253
- export type WhileStepIdentity =
1254
- `WHILE_STEP-${string}`;
1255
- /**
1256
- * This interface was referenced by `Normalized`'s JSON-Schema
1257
- * via the `definition` "ForStepIdentity".
1258
- */
1259
- export type ForStepIdentity =
1260
- `FOR_STEP-${string}`;
1261
- /**
1262
- * This interface was referenced by `Normalized`'s JSON-Schema
1263
- * via the `definition` "StepKind".
1264
- */
1265
- export type StepKind =
1266
- "job" | "branch" | "while" | "for";
1267
- /**
1268
- * This interface was referenced by `Normalized`'s JSON-Schema
1269
- * via the `definition` "RunEventUpdates".
1270
- */
1271
- export type RunEventUpdates =
1272
- {
1273
- stepsMutation?: {
1274
- insertAt: number;
1275
- inserted: StepArray;
1276
- };
1277
- interruptData?: {
1278
- } | null;
1279
- } & StrategyStateDelta;
1280
- /**
1281
- * This interface was referenced by `Normalized`'s JSON-Schema
1282
- * via the `definition` "Step".
1283
- */
1284
- export type Step =
1285
- JobStep | BranchStep | WhileStep | ForStep;
1286
- /**
1287
- * This interface was referenced by `Normalized`'s JSON-Schema
1288
- * via the `definition` "JobStep".
1289
- */
1290
- export type JobStep =
1291
- {
1292
- identity: JobStepIdentity;
1293
- stepKind?: "job";
1294
- jobHandle: JobIdentity;
1295
- } & StepKindFacet &
1296
- RoleBindingsFacet;
1297
- /**
1298
- * This interface was referenced by `Normalized`'s JSON-Schema
1299
- * via the `definition` "JobIdentity".
1300
- */
1301
- export type JobIdentity =
1302
- `JOB-${string}`;
1303
- /**
1304
- * This interface was referenced by `Normalized`'s JSON-Schema
1305
- * via the `definition` "ResourceRoleIdentity".
1306
- */
1307
- export type ResourceRoleIdentity =
1308
- `ROLE-${string}`;
1309
- /**
1310
- * This interface was referenced by `Normalized`'s JSON-Schema
1311
- * via the `definition` "RoleBindingArray".
1312
- */
1313
- export type RoleBindingArray =
1314
- ResourceRoleIdentity[];
1315
- /**
1316
- * This interface was referenced by `Normalized`'s JSON-Schema
1317
- * via the `definition` "BranchStep".
1318
- */
1319
- export type BranchStep =
1320
- {
1321
- identity: BranchStepIdentity;
1322
- stepKind?: "branch";
1323
- /**
1324
- * @minItems 1
1325
- */
1326
- cases: [Conditional, ...Conditional[]];
1327
- } & StepKindFacet;
1328
- /**
1329
- * This interface was referenced by `Normalized`'s JSON-Schema
1330
- * via the `definition` "WhileStep".
1331
- */
1332
- export type WhileStep =
1333
- {
1334
- identity: WhileStepIdentity;
1335
- stepKind?: "while";
1336
- case: Conditional;
1337
- } & StepKindFacet;
1338
- /**
1339
- * This interface was referenced by `Normalized`'s JSON-Schema
1340
- * via the `definition` "ForStep".
1341
- */
1342
- export type ForStep =
1343
- {
1344
- identity: ForStepIdentity;
1345
- stepKind?: "for";
1346
- case: Conditional;
1347
- } & StepKindFacet;
1348
- /**
1349
- * This interface was referenced by `Normalized`'s JSON-Schema
1350
- * via the `definition` "StepArray".
1351
- */
1352
- export type StepArray =
1353
- Step[];
1354
- /**
1355
- * This interface was referenced by `Normalized`'s JSON-Schema
1356
- * via the `definition` "Resource".
1357
- */
1358
- export type Resource =
1359
- ResourceMissing | ResourceInputPotential | ResourceOutputPotential | ResourceMaterialized;
1360
- export type ResourceMissing =
1361
- {
1362
- resourceKind?: "missing";
1363
- } & ResourceBase &
1364
- ResourceKindFacet;
1365
- /**
1366
- * This interface was referenced by `Normalized`'s JSON-Schema
1367
- * via the `definition` "ResourceIdentity".
1368
- */
1369
- export type ResourceIdentity =
1370
- `RESOURCE-${string}`;
1371
- /**
1372
- * This interface was referenced by `Normalized`'s JSON-Schema
1373
- * via the `definition` "ResourceTypeIdentity".
1374
- */
1375
- export type ResourceTypeIdentity =
1376
- `TYPE-${string}`;
1377
- /**
1378
- * This interface was referenced by `Normalized`'s JSON-Schema
1379
- * via the `definition` "ResourceKind".
1380
- */
1381
- export type ResourceKind =
1382
- "missing" | "input-potential" | "output-potential" | "materialized";
1383
- export type ResourceInputPotential =
1384
- {
1385
- resourceKind?: "input-potential";
1386
- } & ResourceBase &
1387
- CreationContextFacet &
1388
- ResourceKindFacet;
1389
- export type ResourceOutputPotential =
1390
- {
1391
- resourceKind?: "output-potential";
1392
- } & ResourceBase &
1393
- CreationContextFacet &
1394
- ResourceKindFacet;
1395
- /**
1396
- * This interface was referenced by `Normalized`'s JSON-Schema
1397
- * via the `definition` "ResourceMaterialized".
1398
- */
1399
- export type ResourceMaterialized =
1400
- {
1401
- } & ShellMaterializedBase &
1402
- NucleusFacet;
1403
- /**
1404
- * This interface was referenced by `Normalized`'s JSON-Schema
1405
- * via the `definition` "ShellMaterializedBase".
1406
- */
1407
- export type ShellMaterializedBase =
1408
- {
1409
- version: 1;
1410
- resourceKind?: "materialized";
1411
- } & ResourceBase &
1412
- CreationContextFacet &
1413
- ResourceKindFacet &
1414
- TimestampFacet &
1415
- PathFacet;
1416
- /**
1417
- * This interface was referenced by `Normalized`'s JSON-Schema
1418
- * via the `definition` "Path".
1419
- */
1420
- export type Path =
1421
- string;
1422
- /**
1423
- * This interface was referenced by `Normalized`'s JSON-Schema
1424
- * via the `definition` "JsonData".
1425
- */
1426
- export type JsonData =
1427
- | null
1428
- | boolean
1429
- | number
1430
- | string
1431
- | JsonData
1432
- | {
1433
- [k: string]: JsonData;
1434
- };
1435
- /**
1436
- * This interface was referenced by `Normalized`'s JSON-Schema
1437
- * via the `definition` "RunnableStrategy".
1438
- */
1439
- export type RunnableStrategy =
1440
- {
1441
- identity: RunnableStrategyIdentity;
1442
- runnableStrategyContext: RunnableStrategyContext;
1443
- } & StrategyThreadMapFacet &
1444
- StrategyStateFacet;
1445
- /**
1446
- * This interface was referenced by `Normalized`'s JSON-Schema
1447
- * via the `definition` "RunnableStrategyStatus".
1448
- */
1449
- export type RunnableStrategyStatus =
1450
- "pending" | "running" | "completed" | "failed" | "cancelled";
1451
- /**
1452
- * This interface was referenced by `Normalized`'s JSON-Schema
1453
- * via the `definition` "TickRunEvent".
1454
- */
1455
- export type TickRunEvent =
1456
- RunEventBase & {
1457
- runEventKind?: "tick";
1458
- };
1459
- /**
1460
- * This interface was referenced by `Normalized`'s JSON-Schema
1461
- * via the `definition` "InterruptRunEvent".
1462
- */
1463
- export type InterruptRunEvent =
1464
- RunEventBase & {
1465
- runEventKind?: "interrupt";
1466
- };
1467
- /**
1468
- * This interface was referenced by `Normalized`'s JSON-Schema
1469
- * via the `definition` "GraphEndRunEvent".
1470
- */
1471
- export type GraphEndRunEvent =
1472
- RunEventBase & {
1473
- runEventKind?: "graph_end";
1474
- };
1475
- /**
1476
- * This interface was referenced by `Normalized`'s JSON-Schema
1477
- * via the `definition` "ResourceMissing".
1478
- */
1479
- export type ShellMissing =
1480
- {
1481
- resourceKind?: "missing";
1482
- } & ResourceBase &
1483
- ResourceKindFacet;
1484
- /**
1485
- * This interface was referenced by `Normalized`'s JSON-Schema
1486
- * via the `definition` "ResourceInputPotential".
1487
- */
1488
- export type ShellInputPotential =
1489
- {
1490
- resourceKind?: "input-potential";
1491
- } & ResourceBase &
1492
- CreationContextFacet &
1493
- ResourceKindFacet;
1494
- /**
1495
- * This interface was referenced by `Normalized`'s JSON-Schema
1496
- * via the `definition` "ResourceOutputPotential".
1497
- */
1498
- export type ShellOutputPotential =
1499
- {
1500
- resourceKind?: "output-potential";
1501
- } & ResourceBase &
1502
- CreationContextFacet &
1503
- ResourceKindFacet;
1504
- /**
1505
- * This interface was referenced by `Normalized`'s JSON-Schema
1506
- * via the `definition` "ShellMissing".
1507
- */
1508
- export type ShellMissing1 =
1509
- {
1510
- resourceKind?: "missing";
1511
- } & ResourceBase &
1512
- ResourceKindFacet;
1513
- /**
1514
- * This interface was referenced by `Normalized`'s JSON-Schema
1515
- * via the `definition` "ShellInputPotential".
1516
- */
1517
- export type ShellInputPotential1 =
1518
- {
1519
- resourceKind?: "input-potential";
1520
- } & ResourceBase &
1521
- CreationContextFacet &
1522
- ResourceKindFacet;
1523
- /**
1524
- * This interface was referenced by `Normalized`'s JSON-Schema
1525
- * via the `definition` "ShellOutputPotential".
1526
- */
1527
- export type ShellOutputPotential1 =
1528
- {
1529
- resourceKind?: "output-potential";
1530
- } & ResourceBase &
1531
- CreationContextFacet &
1532
- ResourceKindFacet;
1533
-
1534
- export interface Normalized {
1535
- identity: StrategyRunIdentity;
1536
- runnableStrategyHandle: string;
1537
- recordedAt: Timestamp;
1538
- runEvents: RunEvent[];
1539
- }
1540
- /**
1541
- * This interface was referenced by `Normalized`'s JSON-Schema
1542
- * via the `definition` "RunEventBase".
1543
- */
1544
- export interface RunEventBase {
1545
- runEventKind: RunEventKind;
1546
- runnableStrategyHandle: RunnableStrategyIdentity;
1547
- strategyThreadHandle: StrategyThreadIdentity;
1548
- createdAt: Timestamp;
1549
- nodeName: string;
1550
- eventSeq: number;
1551
- counters?: RunEventCounters;
1552
- stepMetadata?: RunEventStepMetadata;
1553
- updates?: RunEventUpdates;
1554
- }
1555
- /**
1556
- * This interface was referenced by `Normalized`'s JSON-Schema
1557
- * via the `definition` "RunEventCounters".
1558
- */
1559
- export interface RunEventCounters {
1560
- stepCounterAfter?: number;
1561
- iterationCounterAfter?: number;
1562
- }
1563
- /**
1564
- * This interface was referenced by `Normalized`'s JSON-Schema
1565
- * via the `definition` "RunEventStepMetadata".
1566
- */
1567
- export interface RunEventStepMetadata {
1568
- stepHandle: StepIdentity;
1569
- stepKind: StepKind;
1570
- threadStepIndex: number;
1571
- }
1572
- /**
1573
- * This interface was referenced by `Normalized`'s JSON-Schema
1574
- * via the `definition` "StepKindFacet".
1575
- */
1576
- export interface StepKindFacet {
1577
- stepKind: StepKind;
1578
- }
1579
- export interface RoleBindingsFacet {
1580
- roleBindings: RoleBindings;
1581
- }
1582
- /**
1583
- * This interface was referenced by `Normalized`'s JSON-Schema
1584
- * via the `definition` "RoleBindings".
1585
- */
1586
- export interface RoleBindings {
1587
- inputBindings: RoleBindingArray;
1588
- outputBindings: RoleBindingArray;
1589
- }
1590
- /**
1591
- * This interface was referenced by `Normalized`'s JSON-Schema
1592
- * via the `definition` "Conditional".
1593
- */
1594
- export interface Conditional {
1595
- when: JobStep;
1596
- what: JobStep;
1597
- }
1598
- /**
1599
- * This interface was referenced by `Normalized`'s JSON-Schema
1600
- * via the `definition` "StrategyStateDelta".
1601
- */
1602
- export interface StrategyStateDelta {
1603
- strategyStateUpdate: StrategyState;
1604
- }
1605
- /**
1606
- * This interface was referenced by `Normalized`'s JSON-Schema
1607
- * via the `definition` "StrategyState".
1608
- */
1609
- export interface StrategyState {
1610
- [k: string]: JobStepSocket;
1611
- }
1612
- /**
1613
- * This interface was referenced by `Normalized`'s JSON-Schema
1614
- * via the `definition` "JobStepSocket".
1615
- */
1616
- export interface JobStepSocket {
1617
- [k: string]: Resource;
1618
- }
1619
- /**
1620
- * This interface was referenced by `Normalized`'s JSON-Schema
1621
- * via the `definition` "ResourceBase".
1622
- */
1623
- export interface ResourceBase {
1624
- identity: ResourceIdentity;
1625
- resourceTypeHandle: ResourceTypeIdentity;
1626
- }
1627
- /**
1628
- * This interface was referenced by `Normalized`'s JSON-Schema
1629
- * via the `definition` "ResourceKindFacet".
1630
- */
1631
- export interface ResourceKindFacet {
1632
- resourceKind: ResourceKind;
1633
- }
1634
- /**
1635
- * This interface was referenced by `Normalized`'s JSON-Schema
1636
- * via the `definition` "CreationContextFacet".
1637
- */
1638
- export interface CreationContextFacet {
1639
- creationContext: CreationContext;
1640
- }
1641
- /**
1642
- * This interface was referenced by `Normalized`'s JSON-Schema
1643
- * via the `definition` "CreationContext".
1644
- */
1645
- export interface CreationContext {
1646
- resourceRoleHandle: ResourceRoleIdentity;
1647
- jobStepHandle: JobStepIdentity;
1648
- }
1649
- /**
1650
- * This interface was referenced by `Normalized`'s JSON-Schema
1651
- * via the `definition` "TimestampFacet".
1652
- */
1653
- export interface TimestampFacet {
1654
- timestamp: Timestamp;
1655
- }
1656
- /**
1657
- * This interface was referenced by `Normalized`'s JSON-Schema
1658
- * via the `definition` "PathFacet".
1659
- */
1660
- export interface PathFacet {
1661
- path: Path;
1662
- }
1663
- export interface NucleusFacet {
1664
- nucleus: Nucleus;
1665
- }
1666
- /**
1667
- * This interface was referenced by `Normalized`'s JSON-Schema
1668
- * via the `definition` "Nucleus".
1669
- */
1670
- export interface Nucleus {
1671
- [k: string]: JsonData;
1672
- }
1673
- /**
1674
- * This interface was referenced by `Normalized`'s JSON-Schema
1675
- * via the `definition` "RunnableStrategyContext".
1676
- */
1677
- export interface RunnableStrategyContext {
1678
- status: RunnableStrategyStatus;
1679
- startedAt?: Timestamp;
1680
- completedAt?: Timestamp;
1681
- }
1682
- export interface StrategyThreadMapFacet {
1683
- strategyThreadMap: StrategyThreadMap;
1684
- }
1685
- /**
1686
- * This interface was referenced by `Normalized`'s JSON-Schema
1687
- * via the `definition` "StrategyThreadMap".
1688
- */
1689
- export interface StrategyThreadMap {
1690
- [k: string]: StepArray;
1691
- }
1692
- export interface StrategyStateFacet {
1693
- strategyState: StrategyState;
1694
- }
1695
- /**
1696
- * This interface was referenced by `Normalized`'s JSON-Schema
1697
- * via the `definition` "StrategyThreadMapFacet".
1698
- */
1699
- export interface StrategyThreadMapFacet1 {
1700
- strategyThreadMap: StrategyThreadMap;
1701
- }
1702
- /**
1703
- * This interface was referenced by `Normalized`'s JSON-Schema
1704
- * via the `definition` "StrategyStateFacet".
1705
- */
1706
- export interface StrategyStateFacet1 {
1707
- strategyState: StrategyState;
1708
- }
1709
- /**
1710
- * This interface was referenced by `Normalized`'s JSON-Schema
1711
- * via the `definition` "RoleBindingsFacet".
1712
- */
1713
- export interface RoleBindingsFacet1 {
1714
- roleBindings: RoleBindings;
1715
- }
1716
- /**
1717
- * This interface was referenced by `Normalized`'s JSON-Schema
1718
- * via the `definition` "NucleusFacet".
1719
- */
1720
- export interface NucleusFacet1 {
1721
- nucleus: Nucleus;
1722
- }
1723
-