@fluidgrids/workflows 0.0.0-stage → 2026.1027.0

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 (60) hide show
  1. package/LICENSE +9 -0
  2. package/README.md +187 -2
  3. package/dist/assemble-BJo9TECS.d.cts +569 -0
  4. package/dist/assemble-DMOuaxRI.d.ts +569 -0
  5. package/dist/chunk-265J2FCH.cjs +33 -0
  6. package/dist/chunk-27HASETB.cjs +250 -0
  7. package/dist/chunk-4DPEGDPW.js +74 -0
  8. package/dist/chunk-5LUIDMF4.js +42 -0
  9. package/dist/chunk-AU3YW7FZ.cjs +279 -0
  10. package/dist/chunk-BWSLWF2E.js +722 -0
  11. package/dist/chunk-BYJ7QTLY.cjs +76 -0
  12. package/dist/chunk-G4UEPUGO.cjs +46 -0
  13. package/dist/chunk-GO34UHSY.js +95 -0
  14. package/dist/chunk-IZQNUNSU.cjs +931 -0
  15. package/dist/chunk-KUTMY2IO.cjs +745 -0
  16. package/dist/chunk-LMX35GNQ.js +893 -0
  17. package/dist/chunk-LRM6JXJA.cjs +181 -0
  18. package/dist/chunk-LSKSBVL4.cjs +102 -0
  19. package/dist/chunk-LUXCXFOE.cjs +269 -0
  20. package/dist/chunk-PL73GJR4.js +174 -0
  21. package/dist/chunk-REV7ZOA4.js +170 -0
  22. package/dist/chunk-RRQ5HOBF.cjs +185 -0
  23. package/dist/chunk-S34NJE3A.js +262 -0
  24. package/dist/chunk-SRQRLWOS.js +31 -0
  25. package/dist/chunk-SS4LT2IP.js +268 -0
  26. package/dist/chunk-X4HKU3MX.js +244 -0
  27. package/dist/codegen/index.cjs +18 -0
  28. package/dist/codegen/index.d.cts +15 -0
  29. package/dist/codegen/index.d.ts +15 -0
  30. package/dist/codegen/index.js +5 -0
  31. package/dist/expressions-DhHaqyar.d.cts +62 -0
  32. package/dist/expressions-DhHaqyar.d.ts +62 -0
  33. package/dist/hash-CZkTXPCX.d.cts +15 -0
  34. package/dist/hash-CZkTXPCX.d.ts +15 -0
  35. package/dist/index.cjs +117 -0
  36. package/dist/index.d.cts +27 -0
  37. package/dist/index.d.ts +27 -0
  38. package/dist/index.js +4 -0
  39. package/dist/ir/index.cjs +1244 -0
  40. package/dist/ir/index.d.cts +828 -0
  41. package/dist/ir/index.d.ts +828 -0
  42. package/dist/ir/index.js +1120 -0
  43. package/dist/lower-DcOY8ux0.d.cts +49 -0
  44. package/dist/lower-Dw5grNrI.d.ts +49 -0
  45. package/dist/manifest-Bp9ZJlav.d.ts +60 -0
  46. package/dist/manifest-Duf-gHdO.d.cts +60 -0
  47. package/dist/node-evaluator-2GTUZVPK.cjs +17 -0
  48. package/dist/node-evaluator-RMYEWCXZ.js +8 -0
  49. package/dist/quickjs/index.cjs +92 -0
  50. package/dist/quickjs/index.d.cts +18 -0
  51. package/dist/quickjs/index.d.ts +18 -0
  52. package/dist/quickjs/index.js +90 -0
  53. package/dist/roundtrip/index.cjs +1375 -0
  54. package/dist/roundtrip/index.d.cts +287 -0
  55. package/dist/roundtrip/index.d.ts +287 -0
  56. package/dist/roundtrip/index.js +1328 -0
  57. package/dist/types-Dr2Fn1Ax.d.cts +225 -0
  58. package/dist/types-Dr2Fn1Ax.d.ts +225 -0
  59. package/package.json +117 -4
  60. package/schema/ir-v2.schema.json +655 -0
@@ -0,0 +1,655 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://docs.fluidgrids.ai/schemas/workflow-ir-v2.schema.json",
4
+ "title": "FluidGrids workflow definition (IR schema version 2)",
5
+ "description": "The canonical workflow definition (definitionJson). Version 2 is a strict superset of version 1: a document without schemaVersion is version 1 and validates here unchanged.",
6
+ "type": "object",
7
+ "required": [
8
+ "data"
9
+ ],
10
+ "properties": {
11
+ "schemaVersion": {
12
+ "enum": [
13
+ 1,
14
+ 2
15
+ ],
16
+ "description": "Absent means 1."
17
+ },
18
+ "key": {
19
+ "type": "string"
20
+ },
21
+ "name": {
22
+ "type": "string"
23
+ },
24
+ "description": {
25
+ "type": [
26
+ "string",
27
+ "null"
28
+ ]
29
+ },
30
+ "interface": {
31
+ "$ref": "#/$defs/interface"
32
+ },
33
+ "code": {
34
+ "$ref": "#/$defs/code"
35
+ },
36
+ "authoring": {
37
+ "$ref": "#/$defs/authoring"
38
+ },
39
+ "data": {
40
+ "type": "object",
41
+ "required": [
42
+ "nodes",
43
+ "edges"
44
+ ],
45
+ "properties": {
46
+ "nodes": {
47
+ "type": "array",
48
+ "items": {
49
+ "$ref": "#/$defs/node"
50
+ }
51
+ },
52
+ "edges": {
53
+ "type": "array",
54
+ "items": {
55
+ "$ref": "#/$defs/edge"
56
+ }
57
+ },
58
+ "stickyNotes": {
59
+ "type": "array",
60
+ "items": {
61
+ "type": "object"
62
+ }
63
+ }
64
+ }
65
+ },
66
+ "config": {
67
+ "$ref": "#/$defs/config"
68
+ },
69
+ "pinnedData": {
70
+ "type": "object"
71
+ },
72
+ "meta": {
73
+ "type": "object",
74
+ "properties": {
75
+ "layout": {
76
+ "type": "object",
77
+ "description": "Positions and sizes keyed by node id, preserved verbatim by every code tool."
78
+ }
79
+ }
80
+ },
81
+ "tags": {
82
+ "type": "array"
83
+ }
84
+ },
85
+ "$defs": {
86
+ "position": {
87
+ "type": "object",
88
+ "required": [
89
+ "x",
90
+ "y"
91
+ ],
92
+ "properties": {
93
+ "x": {
94
+ "type": "number"
95
+ },
96
+ "y": {
97
+ "type": "number"
98
+ }
99
+ }
100
+ },
101
+ "connectionRef": {
102
+ "type": "object",
103
+ "required": [
104
+ "connectionId",
105
+ "adapter"
106
+ ],
107
+ "properties": {
108
+ "connectionId": {
109
+ "type": "string"
110
+ },
111
+ "adapter": {
112
+ "type": "string"
113
+ }
114
+ }
115
+ },
116
+ "retryConfig": {
117
+ "type": "object",
118
+ "properties": {
119
+ "maxRetries": {
120
+ "type": "number",
121
+ "minimum": 0
122
+ },
123
+ "retryDelay": {
124
+ "type": "number",
125
+ "minimum": 0
126
+ },
127
+ "backoffMultiplier": {
128
+ "type": "number"
129
+ },
130
+ "maxDelay": {
131
+ "type": "number",
132
+ "minimum": 0
133
+ },
134
+ "retryOnErrorTypes": {
135
+ "type": "array",
136
+ "items": {
137
+ "type": "string"
138
+ }
139
+ },
140
+ "nonRetryableErrorTypes": {
141
+ "type": "array",
142
+ "items": {
143
+ "type": "string"
144
+ }
145
+ }
146
+ }
147
+ },
148
+ "errorConfig": {
149
+ "type": "object",
150
+ "properties": {
151
+ "onError": {
152
+ "type": "string"
153
+ },
154
+ "errorBranchId": {
155
+ "type": "string"
156
+ },
157
+ "retryConfig": {
158
+ "$ref": "#/$defs/retryConfig"
159
+ },
160
+ "timeout": {
161
+ "type": "object",
162
+ "properties": {
163
+ "duration": {
164
+ "type": "number",
165
+ "minimum": 0
166
+ },
167
+ "onTimeout": {
168
+ "type": "string"
169
+ },
170
+ "timeoutBranchId": {
171
+ "type": "string"
172
+ }
173
+ }
174
+ }
175
+ }
176
+ },
177
+ "executionSettings": {
178
+ "type": "object",
179
+ "properties": {
180
+ "alwaysOutputData": {
181
+ "type": "boolean"
182
+ },
183
+ "executeOnce": {
184
+ "type": "boolean"
185
+ },
186
+ "runOn": {
187
+ "type": "object"
188
+ }
189
+ }
190
+ },
191
+ "node": {
192
+ "type": "object",
193
+ "required": [
194
+ "id",
195
+ "type"
196
+ ],
197
+ "properties": {
198
+ "id": {
199
+ "type": "string",
200
+ "minLength": 1
201
+ },
202
+ "type": {
203
+ "type": "string",
204
+ "minLength": 1
205
+ },
206
+ "label": {
207
+ "type": "string"
208
+ },
209
+ "position": {
210
+ "$ref": "#/$defs/position"
211
+ },
212
+ "operation_name": {
213
+ "type": "string"
214
+ },
215
+ "version": {
216
+ "type": "string"
217
+ },
218
+ "args": {
219
+ "type": "object",
220
+ "properties": {
221
+ "state": {
222
+ "type": "object"
223
+ },
224
+ "context": {
225
+ "type": "object"
226
+ },
227
+ "connections": {
228
+ "type": "array",
229
+ "items": {
230
+ "$ref": "#/$defs/connectionRef"
231
+ }
232
+ },
233
+ "credentials": {
234
+ "type": "array",
235
+ "items": {
236
+ "type": "object"
237
+ }
238
+ }
239
+ }
240
+ },
241
+ "errorConfig": {
242
+ "$ref": "#/$defs/errorConfig"
243
+ },
244
+ "executionSettings": {
245
+ "$ref": "#/$defs/executionSettings"
246
+ },
247
+ "disabled": {
248
+ "type": "boolean"
249
+ },
250
+ "data": {
251
+ "type": "object"
252
+ },
253
+ "config": {
254
+ "type": "object"
255
+ }
256
+ },
257
+ "allOf": [
258
+ {
259
+ "if": {
260
+ "properties": {
261
+ "type": {
262
+ "const": "internal:code-workflow"
263
+ }
264
+ },
265
+ "required": [
266
+ "type"
267
+ ]
268
+ },
269
+ "then": {
270
+ "required": [
271
+ "args"
272
+ ],
273
+ "properties": {
274
+ "args": {
275
+ "required": [
276
+ "state"
277
+ ],
278
+ "properties": {
279
+ "state": {
280
+ "type": "object",
281
+ "required": [
282
+ "workflowFn"
283
+ ],
284
+ "properties": {
285
+ "workflowFn": {
286
+ "type": "string",
287
+ "minLength": 1
288
+ },
289
+ "inputMapping": {},
290
+ "taskQueue": {
291
+ "type": "string",
292
+ "minLength": 1
293
+ },
294
+ "waitForCompletion": {
295
+ "type": "boolean"
296
+ },
297
+ "timeout": {
298
+ "type": "number",
299
+ "minimum": 0
300
+ },
301
+ "failOnError": {
302
+ "type": "boolean"
303
+ },
304
+ "parentClosePolicy": {
305
+ "enum": [
306
+ "TERMINATE",
307
+ "ABANDON",
308
+ "REQUEST_CANCEL"
309
+ ]
310
+ }
311
+ }
312
+ }
313
+ }
314
+ }
315
+ }
316
+ }
317
+ },
318
+ {
319
+ "if": {
320
+ "properties": {
321
+ "type": {
322
+ "const": "internal:wait-for-signal"
323
+ }
324
+ },
325
+ "required": [
326
+ "type"
327
+ ]
328
+ },
329
+ "then": {
330
+ "required": [
331
+ "args"
332
+ ],
333
+ "properties": {
334
+ "args": {
335
+ "required": [
336
+ "state"
337
+ ],
338
+ "properties": {
339
+ "state": {
340
+ "type": "object",
341
+ "required": [
342
+ "signalName"
343
+ ],
344
+ "properties": {
345
+ "signalName": {
346
+ "type": "string",
347
+ "minLength": 1
348
+ },
349
+ "limitWait": {
350
+ "type": "object",
351
+ "required": [
352
+ "amount",
353
+ "unit"
354
+ ],
355
+ "properties": {
356
+ "amount": {
357
+ "type": "number",
358
+ "exclusiveMinimum": 0
359
+ },
360
+ "unit": {
361
+ "type": "string"
362
+ }
363
+ }
364
+ },
365
+ "payloadSchema": {
366
+ "type": "object"
367
+ }
368
+ }
369
+ }
370
+ }
371
+ }
372
+ }
373
+ }
374
+ }
375
+ ]
376
+ },
377
+ "edge": {
378
+ "type": "object",
379
+ "required": [
380
+ "source",
381
+ "target"
382
+ ],
383
+ "properties": {
384
+ "id": {
385
+ "type": "string"
386
+ },
387
+ "source": {
388
+ "type": "string",
389
+ "minLength": 1
390
+ },
391
+ "target": {
392
+ "type": "string",
393
+ "minLength": 1
394
+ },
395
+ "sourceHandle": {
396
+ "type": [
397
+ "string",
398
+ "null"
399
+ ]
400
+ },
401
+ "targetHandle": {
402
+ "type": [
403
+ "string",
404
+ "null"
405
+ ]
406
+ },
407
+ "type": {
408
+ "type": "string"
409
+ },
410
+ "label": {},
411
+ "data": {
412
+ "type": "object"
413
+ },
414
+ "mapping": {
415
+ "type": "object"
416
+ }
417
+ }
418
+ },
419
+ "config": {
420
+ "type": "object",
421
+ "properties": {
422
+ "maxParallelism": {
423
+ "type": "number",
424
+ "minimum": 1
425
+ },
426
+ "timeout": {
427
+ "type": "number",
428
+ "minimum": 0,
429
+ "description": "Run timeout in seconds."
430
+ },
431
+ "executionTimeout": {
432
+ "type": [
433
+ "number",
434
+ "string"
435
+ ],
436
+ "description": "Seconds or a duration string."
437
+ },
438
+ "workflowTaskTimeout": {
439
+ "type": [
440
+ "number",
441
+ "string"
442
+ ],
443
+ "description": "Seconds or a duration string."
444
+ },
445
+ "versioningBehavior": {
446
+ "enum": [
447
+ "PINNED",
448
+ "AUTO_UPGRADE"
449
+ ]
450
+ }
451
+ }
452
+ },
453
+ "interface": {
454
+ "type": "object",
455
+ "additionalProperties": false,
456
+ "properties": {
457
+ "input": {
458
+ "type": "object"
459
+ },
460
+ "output": {
461
+ "type": "object"
462
+ },
463
+ "signals": {
464
+ "type": "object",
465
+ "additionalProperties": {
466
+ "type": "object",
467
+ "additionalProperties": false,
468
+ "properties": {
469
+ "payload": {
470
+ "type": "object"
471
+ },
472
+ "description": {
473
+ "type": "string"
474
+ }
475
+ }
476
+ }
477
+ },
478
+ "queries": {
479
+ "type": "object",
480
+ "additionalProperties": {
481
+ "type": "object",
482
+ "additionalProperties": false,
483
+ "properties": {
484
+ "args": {
485
+ "type": "object"
486
+ },
487
+ "result": {
488
+ "type": "object"
489
+ },
490
+ "description": {
491
+ "type": "string"
492
+ }
493
+ }
494
+ }
495
+ },
496
+ "updates": {
497
+ "type": "object",
498
+ "additionalProperties": {
499
+ "type": "object",
500
+ "additionalProperties": false,
501
+ "properties": {
502
+ "args": {
503
+ "type": "object"
504
+ },
505
+ "result": {
506
+ "type": "object"
507
+ },
508
+ "description": {
509
+ "type": "string"
510
+ }
511
+ }
512
+ }
513
+ },
514
+ "open": {
515
+ "type": "object",
516
+ "additionalProperties": false,
517
+ "properties": {
518
+ "signals": {
519
+ "type": "boolean"
520
+ },
521
+ "queries": {
522
+ "type": "boolean"
523
+ },
524
+ "updates": {
525
+ "type": "boolean"
526
+ }
527
+ }
528
+ }
529
+ }
530
+ },
531
+ "code": {
532
+ "type": "object",
533
+ "additionalProperties": false,
534
+ "required": [
535
+ "language",
536
+ "buildId"
537
+ ],
538
+ "properties": {
539
+ "language": {
540
+ "enum": [
541
+ "typescript",
542
+ "python"
543
+ ]
544
+ },
545
+ "sdk": {
546
+ "type": "string"
547
+ },
548
+ "buildId": {
549
+ "type": "string",
550
+ "pattern": "^sha256:[0-9a-f]{64}$"
551
+ },
552
+ "bundleRef": {
553
+ "type": "string"
554
+ },
555
+ "sourceRef": {
556
+ "type": "string"
557
+ },
558
+ "entry": {
559
+ "type": "string"
560
+ },
561
+ "exports": {
562
+ "type": "object",
563
+ "additionalProperties": false,
564
+ "properties": {
565
+ "workflows": {
566
+ "type": "object",
567
+ "additionalProperties": {
568
+ "type": "object",
569
+ "properties": {
570
+ "interface": {
571
+ "$ref": "#/$defs/interface"
572
+ },
573
+ "taskQueue": {
574
+ "type": "string"
575
+ }
576
+ }
577
+ }
578
+ },
579
+ "activities": {
580
+ "type": "object",
581
+ "additionalProperties": {
582
+ "type": "object",
583
+ "properties": {
584
+ "taskQueue": {
585
+ "type": "string"
586
+ },
587
+ "input": {
588
+ "type": "object"
589
+ },
590
+ "output": {
591
+ "type": "object"
592
+ }
593
+ }
594
+ }
595
+ }
596
+ }
597
+ },
598
+ "determinism": {
599
+ "enum": [
600
+ "isolate",
601
+ "worker"
602
+ ]
603
+ }
604
+ }
605
+ },
606
+ "authoring": {
607
+ "type": "object",
608
+ "additionalProperties": false,
609
+ "properties": {
610
+ "mode": {
611
+ "enum": [
612
+ "canvas",
613
+ "code",
614
+ "hybrid"
615
+ ]
616
+ },
617
+ "generator": {
618
+ "enum": [
619
+ "builder",
620
+ "sdk-ts",
621
+ "sdk-py",
622
+ "ai",
623
+ "import",
624
+ "lift"
625
+ ]
626
+ },
627
+ "generatorVersion": {
628
+ "type": "string"
629
+ },
630
+ "sourceHash": {
631
+ "type": "string",
632
+ "pattern": "^sha256:[0-9a-f]{64}$"
633
+ },
634
+ "liftedFrom": {
635
+ "type": "object",
636
+ "additionalProperties": false,
637
+ "properties": {
638
+ "workflowKey": {
639
+ "type": "string"
640
+ },
641
+ "version": {
642
+ "type": "string"
643
+ },
644
+ "fidelity": {
645
+ "enum": [
646
+ "lossless",
647
+ "lossy"
648
+ ]
649
+ }
650
+ }
651
+ }
652
+ }
653
+ }
654
+ }
655
+ }