@wopr-network/defcon 1.2.2 → 1.4.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.
@@ -0,0 +1,1086 @@
1
+ {
2
+ "version": "6",
3
+ "dialect": "sqlite",
4
+ "id": "0e92bb1e-afc5-4558-9835-15b28868866c",
5
+ "prevId": "a2384a7a-1eaf-4a3b-9c15-63d80b01de50",
6
+ "tables": {
7
+ "entities": {
8
+ "name": "entities",
9
+ "columns": {
10
+ "id": {
11
+ "name": "id",
12
+ "type": "text",
13
+ "primaryKey": true,
14
+ "notNull": true,
15
+ "autoincrement": false
16
+ },
17
+ "flow_id": {
18
+ "name": "flow_id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true,
22
+ "autoincrement": false
23
+ },
24
+ "state": {
25
+ "name": "state",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true,
29
+ "autoincrement": false
30
+ },
31
+ "refs": {
32
+ "name": "refs",
33
+ "type": "text",
34
+ "primaryKey": false,
35
+ "notNull": false,
36
+ "autoincrement": false
37
+ },
38
+ "artifacts": {
39
+ "name": "artifacts",
40
+ "type": "text",
41
+ "primaryKey": false,
42
+ "notNull": false,
43
+ "autoincrement": false
44
+ },
45
+ "claimed_by": {
46
+ "name": "claimed_by",
47
+ "type": "text",
48
+ "primaryKey": false,
49
+ "notNull": false,
50
+ "autoincrement": false
51
+ },
52
+ "claimed_at": {
53
+ "name": "claimed_at",
54
+ "type": "integer",
55
+ "primaryKey": false,
56
+ "notNull": false,
57
+ "autoincrement": false
58
+ },
59
+ "flow_version": {
60
+ "name": "flow_version",
61
+ "type": "integer",
62
+ "primaryKey": false,
63
+ "notNull": false,
64
+ "autoincrement": false
65
+ },
66
+ "priority": {
67
+ "name": "priority",
68
+ "type": "integer",
69
+ "primaryKey": false,
70
+ "notNull": false,
71
+ "autoincrement": false,
72
+ "default": 0
73
+ },
74
+ "created_at": {
75
+ "name": "created_at",
76
+ "type": "integer",
77
+ "primaryKey": false,
78
+ "notNull": false,
79
+ "autoincrement": false
80
+ },
81
+ "updated_at": {
82
+ "name": "updated_at",
83
+ "type": "integer",
84
+ "primaryKey": false,
85
+ "notNull": false,
86
+ "autoincrement": false
87
+ },
88
+ "affinity_worker_id": {
89
+ "name": "affinity_worker_id",
90
+ "type": "text",
91
+ "primaryKey": false,
92
+ "notNull": false,
93
+ "autoincrement": false
94
+ },
95
+ "affinity_role": {
96
+ "name": "affinity_role",
97
+ "type": "text",
98
+ "primaryKey": false,
99
+ "notNull": false,
100
+ "autoincrement": false
101
+ },
102
+ "affinity_expires_at": {
103
+ "name": "affinity_expires_at",
104
+ "type": "integer",
105
+ "primaryKey": false,
106
+ "notNull": false,
107
+ "autoincrement": false
108
+ }
109
+ },
110
+ "indexes": {
111
+ "entities_flow_state_idx": {
112
+ "name": "entities_flow_state_idx",
113
+ "columns": [
114
+ "flow_id",
115
+ "state"
116
+ ],
117
+ "isUnique": false
118
+ },
119
+ "entities_claim_idx": {
120
+ "name": "entities_claim_idx",
121
+ "columns": [
122
+ "flow_id",
123
+ "state",
124
+ "claimed_by"
125
+ ],
126
+ "isUnique": false
127
+ },
128
+ "entities_affinity_idx": {
129
+ "name": "entities_affinity_idx",
130
+ "columns": [
131
+ "affinity_worker_id",
132
+ "affinity_role",
133
+ "affinity_expires_at"
134
+ ],
135
+ "isUnique": false
136
+ }
137
+ },
138
+ "foreignKeys": {
139
+ "entities_flow_id_flow_definitions_id_fk": {
140
+ "name": "entities_flow_id_flow_definitions_id_fk",
141
+ "tableFrom": "entities",
142
+ "tableTo": "flow_definitions",
143
+ "columnsFrom": [
144
+ "flow_id"
145
+ ],
146
+ "columnsTo": [
147
+ "id"
148
+ ],
149
+ "onDelete": "no action",
150
+ "onUpdate": "no action"
151
+ }
152
+ },
153
+ "compositePrimaryKeys": {},
154
+ "uniqueConstraints": {},
155
+ "checkConstraints": {}
156
+ },
157
+ "entity_history": {
158
+ "name": "entity_history",
159
+ "columns": {
160
+ "id": {
161
+ "name": "id",
162
+ "type": "text",
163
+ "primaryKey": true,
164
+ "notNull": true,
165
+ "autoincrement": false
166
+ },
167
+ "entity_id": {
168
+ "name": "entity_id",
169
+ "type": "text",
170
+ "primaryKey": false,
171
+ "notNull": true,
172
+ "autoincrement": false
173
+ },
174
+ "from_state": {
175
+ "name": "from_state",
176
+ "type": "text",
177
+ "primaryKey": false,
178
+ "notNull": false,
179
+ "autoincrement": false
180
+ },
181
+ "to_state": {
182
+ "name": "to_state",
183
+ "type": "text",
184
+ "primaryKey": false,
185
+ "notNull": true,
186
+ "autoincrement": false
187
+ },
188
+ "trigger": {
189
+ "name": "trigger",
190
+ "type": "text",
191
+ "primaryKey": false,
192
+ "notNull": false,
193
+ "autoincrement": false
194
+ },
195
+ "invocation_id": {
196
+ "name": "invocation_id",
197
+ "type": "text",
198
+ "primaryKey": false,
199
+ "notNull": false,
200
+ "autoincrement": false
201
+ },
202
+ "timestamp": {
203
+ "name": "timestamp",
204
+ "type": "integer",
205
+ "primaryKey": false,
206
+ "notNull": true,
207
+ "autoincrement": false
208
+ }
209
+ },
210
+ "indexes": {
211
+ "entity_history_entity_ts_idx": {
212
+ "name": "entity_history_entity_ts_idx",
213
+ "columns": [
214
+ "entity_id",
215
+ "timestamp"
216
+ ],
217
+ "isUnique": false
218
+ }
219
+ },
220
+ "foreignKeys": {
221
+ "entity_history_entity_id_entities_id_fk": {
222
+ "name": "entity_history_entity_id_entities_id_fk",
223
+ "tableFrom": "entity_history",
224
+ "tableTo": "entities",
225
+ "columnsFrom": [
226
+ "entity_id"
227
+ ],
228
+ "columnsTo": [
229
+ "id"
230
+ ],
231
+ "onDelete": "no action",
232
+ "onUpdate": "no action"
233
+ },
234
+ "entity_history_invocation_id_invocations_id_fk": {
235
+ "name": "entity_history_invocation_id_invocations_id_fk",
236
+ "tableFrom": "entity_history",
237
+ "tableTo": "invocations",
238
+ "columnsFrom": [
239
+ "invocation_id"
240
+ ],
241
+ "columnsTo": [
242
+ "id"
243
+ ],
244
+ "onDelete": "no action",
245
+ "onUpdate": "no action"
246
+ }
247
+ },
248
+ "compositePrimaryKeys": {},
249
+ "uniqueConstraints": {},
250
+ "checkConstraints": {}
251
+ },
252
+ "events": {
253
+ "name": "events",
254
+ "columns": {
255
+ "id": {
256
+ "name": "id",
257
+ "type": "text",
258
+ "primaryKey": true,
259
+ "notNull": true,
260
+ "autoincrement": false
261
+ },
262
+ "type": {
263
+ "name": "type",
264
+ "type": "text",
265
+ "primaryKey": false,
266
+ "notNull": true,
267
+ "autoincrement": false
268
+ },
269
+ "entity_id": {
270
+ "name": "entity_id",
271
+ "type": "text",
272
+ "primaryKey": false,
273
+ "notNull": false,
274
+ "autoincrement": false
275
+ },
276
+ "flow_id": {
277
+ "name": "flow_id",
278
+ "type": "text",
279
+ "primaryKey": false,
280
+ "notNull": false,
281
+ "autoincrement": false
282
+ },
283
+ "payload": {
284
+ "name": "payload",
285
+ "type": "text",
286
+ "primaryKey": false,
287
+ "notNull": false,
288
+ "autoincrement": false
289
+ },
290
+ "emitted_at": {
291
+ "name": "emitted_at",
292
+ "type": "integer",
293
+ "primaryKey": false,
294
+ "notNull": true,
295
+ "autoincrement": false
296
+ }
297
+ },
298
+ "indexes": {
299
+ "events_type_emitted_idx": {
300
+ "name": "events_type_emitted_idx",
301
+ "columns": [
302
+ "type",
303
+ "emitted_at"
304
+ ],
305
+ "isUnique": false
306
+ }
307
+ },
308
+ "foreignKeys": {},
309
+ "compositePrimaryKeys": {},
310
+ "uniqueConstraints": {},
311
+ "checkConstraints": {}
312
+ },
313
+ "flow_definitions": {
314
+ "name": "flow_definitions",
315
+ "columns": {
316
+ "id": {
317
+ "name": "id",
318
+ "type": "text",
319
+ "primaryKey": true,
320
+ "notNull": true,
321
+ "autoincrement": false
322
+ },
323
+ "name": {
324
+ "name": "name",
325
+ "type": "text",
326
+ "primaryKey": false,
327
+ "notNull": true,
328
+ "autoincrement": false
329
+ },
330
+ "description": {
331
+ "name": "description",
332
+ "type": "text",
333
+ "primaryKey": false,
334
+ "notNull": false,
335
+ "autoincrement": false
336
+ },
337
+ "entity_schema": {
338
+ "name": "entity_schema",
339
+ "type": "text",
340
+ "primaryKey": false,
341
+ "notNull": false,
342
+ "autoincrement": false
343
+ },
344
+ "initial_state": {
345
+ "name": "initial_state",
346
+ "type": "text",
347
+ "primaryKey": false,
348
+ "notNull": true,
349
+ "autoincrement": false
350
+ },
351
+ "max_concurrent": {
352
+ "name": "max_concurrent",
353
+ "type": "integer",
354
+ "primaryKey": false,
355
+ "notNull": false,
356
+ "autoincrement": false,
357
+ "default": 0
358
+ },
359
+ "max_concurrent_per_repo": {
360
+ "name": "max_concurrent_per_repo",
361
+ "type": "integer",
362
+ "primaryKey": false,
363
+ "notNull": false,
364
+ "autoincrement": false,
365
+ "default": 0
366
+ },
367
+ "affinity_window_ms": {
368
+ "name": "affinity_window_ms",
369
+ "type": "integer",
370
+ "primaryKey": false,
371
+ "notNull": false,
372
+ "autoincrement": false,
373
+ "default": 300000
374
+ },
375
+ "claim_retry_after_ms": {
376
+ "name": "claim_retry_after_ms",
377
+ "type": "integer",
378
+ "primaryKey": false,
379
+ "notNull": false,
380
+ "autoincrement": false
381
+ },
382
+ "gate_timeout_ms": {
383
+ "name": "gate_timeout_ms",
384
+ "type": "integer",
385
+ "primaryKey": false,
386
+ "notNull": false,
387
+ "autoincrement": false
388
+ },
389
+ "version": {
390
+ "name": "version",
391
+ "type": "integer",
392
+ "primaryKey": false,
393
+ "notNull": false,
394
+ "autoincrement": false,
395
+ "default": 1
396
+ },
397
+ "created_by": {
398
+ "name": "created_by",
399
+ "type": "text",
400
+ "primaryKey": false,
401
+ "notNull": false,
402
+ "autoincrement": false
403
+ },
404
+ "discipline": {
405
+ "name": "discipline",
406
+ "type": "text",
407
+ "primaryKey": false,
408
+ "notNull": false,
409
+ "autoincrement": false
410
+ },
411
+ "default_model_tier": {
412
+ "name": "default_model_tier",
413
+ "type": "text",
414
+ "primaryKey": false,
415
+ "notNull": false,
416
+ "autoincrement": false
417
+ },
418
+ "timeout_prompt": {
419
+ "name": "timeout_prompt",
420
+ "type": "text",
421
+ "primaryKey": false,
422
+ "notNull": false,
423
+ "autoincrement": false
424
+ },
425
+ "paused": {
426
+ "name": "paused",
427
+ "type": "integer",
428
+ "primaryKey": false,
429
+ "notNull": false,
430
+ "autoincrement": false,
431
+ "default": 0
432
+ },
433
+ "created_at": {
434
+ "name": "created_at",
435
+ "type": "integer",
436
+ "primaryKey": false,
437
+ "notNull": false,
438
+ "autoincrement": false
439
+ },
440
+ "updated_at": {
441
+ "name": "updated_at",
442
+ "type": "integer",
443
+ "primaryKey": false,
444
+ "notNull": false,
445
+ "autoincrement": false
446
+ }
447
+ },
448
+ "indexes": {
449
+ "flow_definitions_name_unique": {
450
+ "name": "flow_definitions_name_unique",
451
+ "columns": [
452
+ "name"
453
+ ],
454
+ "isUnique": true
455
+ }
456
+ },
457
+ "foreignKeys": {},
458
+ "compositePrimaryKeys": {},
459
+ "uniqueConstraints": {},
460
+ "checkConstraints": {}
461
+ },
462
+ "flow_versions": {
463
+ "name": "flow_versions",
464
+ "columns": {
465
+ "id": {
466
+ "name": "id",
467
+ "type": "text",
468
+ "primaryKey": true,
469
+ "notNull": true,
470
+ "autoincrement": false
471
+ },
472
+ "flow_id": {
473
+ "name": "flow_id",
474
+ "type": "text",
475
+ "primaryKey": false,
476
+ "notNull": true,
477
+ "autoincrement": false
478
+ },
479
+ "version": {
480
+ "name": "version",
481
+ "type": "integer",
482
+ "primaryKey": false,
483
+ "notNull": true,
484
+ "autoincrement": false
485
+ },
486
+ "snapshot": {
487
+ "name": "snapshot",
488
+ "type": "text",
489
+ "primaryKey": false,
490
+ "notNull": false,
491
+ "autoincrement": false
492
+ },
493
+ "changed_by": {
494
+ "name": "changed_by",
495
+ "type": "text",
496
+ "primaryKey": false,
497
+ "notNull": false,
498
+ "autoincrement": false
499
+ },
500
+ "change_reason": {
501
+ "name": "change_reason",
502
+ "type": "text",
503
+ "primaryKey": false,
504
+ "notNull": false,
505
+ "autoincrement": false
506
+ },
507
+ "created_at": {
508
+ "name": "created_at",
509
+ "type": "integer",
510
+ "primaryKey": false,
511
+ "notNull": false,
512
+ "autoincrement": false
513
+ }
514
+ },
515
+ "indexes": {
516
+ "flow_versions_flow_version_unique": {
517
+ "name": "flow_versions_flow_version_unique",
518
+ "columns": [
519
+ "flow_id",
520
+ "version"
521
+ ],
522
+ "isUnique": true
523
+ }
524
+ },
525
+ "foreignKeys": {
526
+ "flow_versions_flow_id_flow_definitions_id_fk": {
527
+ "name": "flow_versions_flow_id_flow_definitions_id_fk",
528
+ "tableFrom": "flow_versions",
529
+ "tableTo": "flow_definitions",
530
+ "columnsFrom": [
531
+ "flow_id"
532
+ ],
533
+ "columnsTo": [
534
+ "id"
535
+ ],
536
+ "onDelete": "no action",
537
+ "onUpdate": "no action"
538
+ }
539
+ },
540
+ "compositePrimaryKeys": {},
541
+ "uniqueConstraints": {},
542
+ "checkConstraints": {}
543
+ },
544
+ "gate_definitions": {
545
+ "name": "gate_definitions",
546
+ "columns": {
547
+ "id": {
548
+ "name": "id",
549
+ "type": "text",
550
+ "primaryKey": true,
551
+ "notNull": true,
552
+ "autoincrement": false
553
+ },
554
+ "name": {
555
+ "name": "name",
556
+ "type": "text",
557
+ "primaryKey": false,
558
+ "notNull": true,
559
+ "autoincrement": false
560
+ },
561
+ "type": {
562
+ "name": "type",
563
+ "type": "text",
564
+ "primaryKey": false,
565
+ "notNull": true,
566
+ "autoincrement": false
567
+ },
568
+ "command": {
569
+ "name": "command",
570
+ "type": "text",
571
+ "primaryKey": false,
572
+ "notNull": false,
573
+ "autoincrement": false
574
+ },
575
+ "function_ref": {
576
+ "name": "function_ref",
577
+ "type": "text",
578
+ "primaryKey": false,
579
+ "notNull": false,
580
+ "autoincrement": false
581
+ },
582
+ "api_config": {
583
+ "name": "api_config",
584
+ "type": "text",
585
+ "primaryKey": false,
586
+ "notNull": false,
587
+ "autoincrement": false
588
+ },
589
+ "timeout_ms": {
590
+ "name": "timeout_ms",
591
+ "type": "integer",
592
+ "primaryKey": false,
593
+ "notNull": false,
594
+ "autoincrement": false
595
+ },
596
+ "failure_prompt": {
597
+ "name": "failure_prompt",
598
+ "type": "text",
599
+ "primaryKey": false,
600
+ "notNull": false,
601
+ "autoincrement": false
602
+ },
603
+ "timeout_prompt": {
604
+ "name": "timeout_prompt",
605
+ "type": "text",
606
+ "primaryKey": false,
607
+ "notNull": false,
608
+ "autoincrement": false
609
+ }
610
+ },
611
+ "indexes": {
612
+ "gate_definitions_name_unique": {
613
+ "name": "gate_definitions_name_unique",
614
+ "columns": [
615
+ "name"
616
+ ],
617
+ "isUnique": true
618
+ }
619
+ },
620
+ "foreignKeys": {},
621
+ "compositePrimaryKeys": {},
622
+ "uniqueConstraints": {},
623
+ "checkConstraints": {}
624
+ },
625
+ "gate_results": {
626
+ "name": "gate_results",
627
+ "columns": {
628
+ "id": {
629
+ "name": "id",
630
+ "type": "text",
631
+ "primaryKey": true,
632
+ "notNull": true,
633
+ "autoincrement": false
634
+ },
635
+ "entity_id": {
636
+ "name": "entity_id",
637
+ "type": "text",
638
+ "primaryKey": false,
639
+ "notNull": true,
640
+ "autoincrement": false
641
+ },
642
+ "gate_id": {
643
+ "name": "gate_id",
644
+ "type": "text",
645
+ "primaryKey": false,
646
+ "notNull": true,
647
+ "autoincrement": false
648
+ },
649
+ "passed": {
650
+ "name": "passed",
651
+ "type": "integer",
652
+ "primaryKey": false,
653
+ "notNull": true,
654
+ "autoincrement": false
655
+ },
656
+ "output": {
657
+ "name": "output",
658
+ "type": "text",
659
+ "primaryKey": false,
660
+ "notNull": false,
661
+ "autoincrement": false
662
+ },
663
+ "evaluated_at": {
664
+ "name": "evaluated_at",
665
+ "type": "integer",
666
+ "primaryKey": false,
667
+ "notNull": false,
668
+ "autoincrement": false
669
+ }
670
+ },
671
+ "indexes": {},
672
+ "foreignKeys": {
673
+ "gate_results_entity_id_entities_id_fk": {
674
+ "name": "gate_results_entity_id_entities_id_fk",
675
+ "tableFrom": "gate_results",
676
+ "tableTo": "entities",
677
+ "columnsFrom": [
678
+ "entity_id"
679
+ ],
680
+ "columnsTo": [
681
+ "id"
682
+ ],
683
+ "onDelete": "no action",
684
+ "onUpdate": "no action"
685
+ },
686
+ "gate_results_gate_id_gate_definitions_id_fk": {
687
+ "name": "gate_results_gate_id_gate_definitions_id_fk",
688
+ "tableFrom": "gate_results",
689
+ "tableTo": "gate_definitions",
690
+ "columnsFrom": [
691
+ "gate_id"
692
+ ],
693
+ "columnsTo": [
694
+ "id"
695
+ ],
696
+ "onDelete": "no action",
697
+ "onUpdate": "no action"
698
+ }
699
+ },
700
+ "compositePrimaryKeys": {},
701
+ "uniqueConstraints": {},
702
+ "checkConstraints": {}
703
+ },
704
+ "invocations": {
705
+ "name": "invocations",
706
+ "columns": {
707
+ "id": {
708
+ "name": "id",
709
+ "type": "text",
710
+ "primaryKey": true,
711
+ "notNull": true,
712
+ "autoincrement": false
713
+ },
714
+ "entity_id": {
715
+ "name": "entity_id",
716
+ "type": "text",
717
+ "primaryKey": false,
718
+ "notNull": true,
719
+ "autoincrement": false
720
+ },
721
+ "stage": {
722
+ "name": "stage",
723
+ "type": "text",
724
+ "primaryKey": false,
725
+ "notNull": true,
726
+ "autoincrement": false
727
+ },
728
+ "agent_role": {
729
+ "name": "agent_role",
730
+ "type": "text",
731
+ "primaryKey": false,
732
+ "notNull": false,
733
+ "autoincrement": false
734
+ },
735
+ "mode": {
736
+ "name": "mode",
737
+ "type": "text",
738
+ "primaryKey": false,
739
+ "notNull": true,
740
+ "autoincrement": false
741
+ },
742
+ "prompt": {
743
+ "name": "prompt",
744
+ "type": "text",
745
+ "primaryKey": false,
746
+ "notNull": true,
747
+ "autoincrement": false
748
+ },
749
+ "context": {
750
+ "name": "context",
751
+ "type": "text",
752
+ "primaryKey": false,
753
+ "notNull": false,
754
+ "autoincrement": false
755
+ },
756
+ "claimed_by": {
757
+ "name": "claimed_by",
758
+ "type": "text",
759
+ "primaryKey": false,
760
+ "notNull": false,
761
+ "autoincrement": false
762
+ },
763
+ "claimed_at": {
764
+ "name": "claimed_at",
765
+ "type": "integer",
766
+ "primaryKey": false,
767
+ "notNull": false,
768
+ "autoincrement": false
769
+ },
770
+ "started_at": {
771
+ "name": "started_at",
772
+ "type": "integer",
773
+ "primaryKey": false,
774
+ "notNull": false,
775
+ "autoincrement": false
776
+ },
777
+ "completed_at": {
778
+ "name": "completed_at",
779
+ "type": "integer",
780
+ "primaryKey": false,
781
+ "notNull": false,
782
+ "autoincrement": false
783
+ },
784
+ "failed_at": {
785
+ "name": "failed_at",
786
+ "type": "integer",
787
+ "primaryKey": false,
788
+ "notNull": false,
789
+ "autoincrement": false
790
+ },
791
+ "signal": {
792
+ "name": "signal",
793
+ "type": "text",
794
+ "primaryKey": false,
795
+ "notNull": false,
796
+ "autoincrement": false
797
+ },
798
+ "artifacts": {
799
+ "name": "artifacts",
800
+ "type": "text",
801
+ "primaryKey": false,
802
+ "notNull": false,
803
+ "autoincrement": false
804
+ },
805
+ "error": {
806
+ "name": "error",
807
+ "type": "text",
808
+ "primaryKey": false,
809
+ "notNull": false,
810
+ "autoincrement": false
811
+ },
812
+ "ttl_ms": {
813
+ "name": "ttl_ms",
814
+ "type": "integer",
815
+ "primaryKey": false,
816
+ "notNull": false,
817
+ "autoincrement": false,
818
+ "default": 1800000
819
+ },
820
+ "created_at": {
821
+ "name": "created_at",
822
+ "type": "integer",
823
+ "primaryKey": false,
824
+ "notNull": false,
825
+ "autoincrement": false
826
+ }
827
+ },
828
+ "indexes": {
829
+ "invocations_entity_idx": {
830
+ "name": "invocations_entity_idx",
831
+ "columns": [
832
+ "entity_id"
833
+ ],
834
+ "isUnique": false
835
+ }
836
+ },
837
+ "foreignKeys": {
838
+ "invocations_entity_id_entities_id_fk": {
839
+ "name": "invocations_entity_id_entities_id_fk",
840
+ "tableFrom": "invocations",
841
+ "tableTo": "entities",
842
+ "columnsFrom": [
843
+ "entity_id"
844
+ ],
845
+ "columnsTo": [
846
+ "id"
847
+ ],
848
+ "onDelete": "no action",
849
+ "onUpdate": "no action"
850
+ }
851
+ },
852
+ "compositePrimaryKeys": {},
853
+ "uniqueConstraints": {},
854
+ "checkConstraints": {}
855
+ },
856
+ "state_definitions": {
857
+ "name": "state_definitions",
858
+ "columns": {
859
+ "id": {
860
+ "name": "id",
861
+ "type": "text",
862
+ "primaryKey": true,
863
+ "notNull": true,
864
+ "autoincrement": false
865
+ },
866
+ "flow_id": {
867
+ "name": "flow_id",
868
+ "type": "text",
869
+ "primaryKey": false,
870
+ "notNull": true,
871
+ "autoincrement": false
872
+ },
873
+ "name": {
874
+ "name": "name",
875
+ "type": "text",
876
+ "primaryKey": false,
877
+ "notNull": true,
878
+ "autoincrement": false
879
+ },
880
+ "agent_role": {
881
+ "name": "agent_role",
882
+ "type": "text",
883
+ "primaryKey": false,
884
+ "notNull": false,
885
+ "autoincrement": false
886
+ },
887
+ "model_tier": {
888
+ "name": "model_tier",
889
+ "type": "text",
890
+ "primaryKey": false,
891
+ "notNull": false,
892
+ "autoincrement": false
893
+ },
894
+ "mode": {
895
+ "name": "mode",
896
+ "type": "text",
897
+ "primaryKey": false,
898
+ "notNull": false,
899
+ "autoincrement": false,
900
+ "default": "'passive'"
901
+ },
902
+ "prompt_template": {
903
+ "name": "prompt_template",
904
+ "type": "text",
905
+ "primaryKey": false,
906
+ "notNull": false,
907
+ "autoincrement": false
908
+ },
909
+ "constraints": {
910
+ "name": "constraints",
911
+ "type": "text",
912
+ "primaryKey": false,
913
+ "notNull": false,
914
+ "autoincrement": false
915
+ },
916
+ "on_enter": {
917
+ "name": "on_enter",
918
+ "type": "text",
919
+ "primaryKey": false,
920
+ "notNull": false,
921
+ "autoincrement": false
922
+ },
923
+ "retry_after_ms": {
924
+ "name": "retry_after_ms",
925
+ "type": "integer",
926
+ "primaryKey": false,
927
+ "notNull": false,
928
+ "autoincrement": false
929
+ }
930
+ },
931
+ "indexes": {
932
+ "state_definitions_flow_name_unique": {
933
+ "name": "state_definitions_flow_name_unique",
934
+ "columns": [
935
+ "flow_id",
936
+ "name"
937
+ ],
938
+ "isUnique": true
939
+ }
940
+ },
941
+ "foreignKeys": {
942
+ "state_definitions_flow_id_flow_definitions_id_fk": {
943
+ "name": "state_definitions_flow_id_flow_definitions_id_fk",
944
+ "tableFrom": "state_definitions",
945
+ "tableTo": "flow_definitions",
946
+ "columnsFrom": [
947
+ "flow_id"
948
+ ],
949
+ "columnsTo": [
950
+ "id"
951
+ ],
952
+ "onDelete": "no action",
953
+ "onUpdate": "no action"
954
+ }
955
+ },
956
+ "compositePrimaryKeys": {},
957
+ "uniqueConstraints": {},
958
+ "checkConstraints": {}
959
+ },
960
+ "transition_rules": {
961
+ "name": "transition_rules",
962
+ "columns": {
963
+ "id": {
964
+ "name": "id",
965
+ "type": "text",
966
+ "primaryKey": true,
967
+ "notNull": true,
968
+ "autoincrement": false
969
+ },
970
+ "flow_id": {
971
+ "name": "flow_id",
972
+ "type": "text",
973
+ "primaryKey": false,
974
+ "notNull": true,
975
+ "autoincrement": false
976
+ },
977
+ "from_state": {
978
+ "name": "from_state",
979
+ "type": "text",
980
+ "primaryKey": false,
981
+ "notNull": true,
982
+ "autoincrement": false
983
+ },
984
+ "to_state": {
985
+ "name": "to_state",
986
+ "type": "text",
987
+ "primaryKey": false,
988
+ "notNull": true,
989
+ "autoincrement": false
990
+ },
991
+ "trigger": {
992
+ "name": "trigger",
993
+ "type": "text",
994
+ "primaryKey": false,
995
+ "notNull": true,
996
+ "autoincrement": false
997
+ },
998
+ "gate_id": {
999
+ "name": "gate_id",
1000
+ "type": "text",
1001
+ "primaryKey": false,
1002
+ "notNull": false,
1003
+ "autoincrement": false
1004
+ },
1005
+ "condition": {
1006
+ "name": "condition",
1007
+ "type": "text",
1008
+ "primaryKey": false,
1009
+ "notNull": false,
1010
+ "autoincrement": false
1011
+ },
1012
+ "priority": {
1013
+ "name": "priority",
1014
+ "type": "integer",
1015
+ "primaryKey": false,
1016
+ "notNull": false,
1017
+ "autoincrement": false,
1018
+ "default": 0
1019
+ },
1020
+ "spawn_flow": {
1021
+ "name": "spawn_flow",
1022
+ "type": "text",
1023
+ "primaryKey": false,
1024
+ "notNull": false,
1025
+ "autoincrement": false
1026
+ },
1027
+ "spawn_template": {
1028
+ "name": "spawn_template",
1029
+ "type": "text",
1030
+ "primaryKey": false,
1031
+ "notNull": false,
1032
+ "autoincrement": false
1033
+ },
1034
+ "created_at": {
1035
+ "name": "created_at",
1036
+ "type": "integer",
1037
+ "primaryKey": false,
1038
+ "notNull": false,
1039
+ "autoincrement": false
1040
+ }
1041
+ },
1042
+ "indexes": {},
1043
+ "foreignKeys": {
1044
+ "transition_rules_flow_id_flow_definitions_id_fk": {
1045
+ "name": "transition_rules_flow_id_flow_definitions_id_fk",
1046
+ "tableFrom": "transition_rules",
1047
+ "tableTo": "flow_definitions",
1048
+ "columnsFrom": [
1049
+ "flow_id"
1050
+ ],
1051
+ "columnsTo": [
1052
+ "id"
1053
+ ],
1054
+ "onDelete": "no action",
1055
+ "onUpdate": "no action"
1056
+ },
1057
+ "transition_rules_gate_id_gate_definitions_id_fk": {
1058
+ "name": "transition_rules_gate_id_gate_definitions_id_fk",
1059
+ "tableFrom": "transition_rules",
1060
+ "tableTo": "gate_definitions",
1061
+ "columnsFrom": [
1062
+ "gate_id"
1063
+ ],
1064
+ "columnsTo": [
1065
+ "id"
1066
+ ],
1067
+ "onDelete": "no action",
1068
+ "onUpdate": "no action"
1069
+ }
1070
+ },
1071
+ "compositePrimaryKeys": {},
1072
+ "uniqueConstraints": {},
1073
+ "checkConstraints": {}
1074
+ }
1075
+ },
1076
+ "views": {},
1077
+ "enums": {},
1078
+ "_meta": {
1079
+ "schemas": {},
1080
+ "tables": {},
1081
+ "columns": {}
1082
+ },
1083
+ "internal": {
1084
+ "indexes": {}
1085
+ }
1086
+ }