relavium 0.1.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,1805 @@
1
+ {
2
+ "version": "6",
3
+ "dialect": "sqlite",
4
+ "id": "b746cb45-0fa2-4b58-9b19-0e259b75af22",
5
+ "prevId": "e3adefeb-1981-42fa-a3f5-f3306d288d9a",
6
+ "tables": {
7
+ "agent_sessions": {
8
+ "name": "agent_sessions",
9
+ "columns": {
10
+ "id": {
11
+ "name": "id",
12
+ "type": "text",
13
+ "primaryKey": true,
14
+ "notNull": true,
15
+ "autoincrement": false
16
+ },
17
+ "agent_id": {
18
+ "name": "agent_id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": false,
22
+ "autoincrement": false
23
+ },
24
+ "agent_slug": {
25
+ "name": "agent_slug",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true,
29
+ "autoincrement": false
30
+ },
31
+ "agent_snapshot": {
32
+ "name": "agent_snapshot",
33
+ "type": "text",
34
+ "primaryKey": false,
35
+ "notNull": false,
36
+ "autoincrement": false
37
+ },
38
+ "title": {
39
+ "name": "title",
40
+ "type": "text",
41
+ "primaryKey": false,
42
+ "notNull": false,
43
+ "autoincrement": false
44
+ },
45
+ "model_id": {
46
+ "name": "model_id",
47
+ "type": "text",
48
+ "primaryKey": false,
49
+ "notNull": false,
50
+ "autoincrement": false
51
+ },
52
+ "working_dir": {
53
+ "name": "working_dir",
54
+ "type": "text",
55
+ "primaryKey": false,
56
+ "notNull": false,
57
+ "autoincrement": false
58
+ },
59
+ "git_ref": {
60
+ "name": "git_ref",
61
+ "type": "text",
62
+ "primaryKey": false,
63
+ "notNull": false,
64
+ "autoincrement": false
65
+ },
66
+ "fs_scope_tier": {
67
+ "name": "fs_scope_tier",
68
+ "type": "text",
69
+ "primaryKey": false,
70
+ "notNull": true,
71
+ "autoincrement": false,
72
+ "default": "'sandboxed'"
73
+ },
74
+ "status": {
75
+ "name": "status",
76
+ "type": "text",
77
+ "primaryKey": false,
78
+ "notNull": true,
79
+ "autoincrement": false,
80
+ "default": "'active'"
81
+ },
82
+ "context_json": {
83
+ "name": "context_json",
84
+ "type": "text",
85
+ "primaryKey": false,
86
+ "notNull": true,
87
+ "autoincrement": false,
88
+ "default": "'{}'"
89
+ },
90
+ "total_input_tokens": {
91
+ "name": "total_input_tokens",
92
+ "type": "integer",
93
+ "primaryKey": false,
94
+ "notNull": true,
95
+ "autoincrement": false,
96
+ "default": 0
97
+ },
98
+ "total_output_tokens": {
99
+ "name": "total_output_tokens",
100
+ "type": "integer",
101
+ "primaryKey": false,
102
+ "notNull": true,
103
+ "autoincrement": false,
104
+ "default": 0
105
+ },
106
+ "total_cost_microcents": {
107
+ "name": "total_cost_microcents",
108
+ "type": "integer",
109
+ "primaryKey": false,
110
+ "notNull": true,
111
+ "autoincrement": false,
112
+ "default": 0
113
+ },
114
+ "exported_workflow_path": {
115
+ "name": "exported_workflow_path",
116
+ "type": "text",
117
+ "primaryKey": false,
118
+ "notNull": false,
119
+ "autoincrement": false
120
+ },
121
+ "deleted_at": {
122
+ "name": "deleted_at",
123
+ "type": "integer",
124
+ "primaryKey": false,
125
+ "notNull": false,
126
+ "autoincrement": false
127
+ },
128
+ "created_at": {
129
+ "name": "created_at",
130
+ "type": "integer",
131
+ "primaryKey": false,
132
+ "notNull": true,
133
+ "autoincrement": false
134
+ },
135
+ "updated_at": {
136
+ "name": "updated_at",
137
+ "type": "integer",
138
+ "primaryKey": false,
139
+ "notNull": true,
140
+ "autoincrement": false
141
+ }
142
+ },
143
+ "indexes": {
144
+ "idx_agent_sessions_status": {
145
+ "name": "idx_agent_sessions_status",
146
+ "columns": [
147
+ "status",
148
+ "\"updated_at\" desc"
149
+ ],
150
+ "isUnique": false,
151
+ "where": "\"agent_sessions\".\"deleted_at\" is null"
152
+ },
153
+ "idx_agent_sessions_agent": {
154
+ "name": "idx_agent_sessions_agent",
155
+ "columns": [
156
+ "agent_id",
157
+ "\"created_at\" desc"
158
+ ],
159
+ "isUnique": false,
160
+ "where": "\"agent_sessions\".\"agent_id\" is not null"
161
+ }
162
+ },
163
+ "foreignKeys": {
164
+ "agent_sessions_agent_id_agents_id_fk": {
165
+ "name": "agent_sessions_agent_id_agents_id_fk",
166
+ "tableFrom": "agent_sessions",
167
+ "tableTo": "agents",
168
+ "columnsFrom": [
169
+ "agent_id"
170
+ ],
171
+ "columnsTo": [
172
+ "id"
173
+ ],
174
+ "onDelete": "no action",
175
+ "onUpdate": "no action"
176
+ },
177
+ "agent_sessions_model_id_model_catalog_id_fk": {
178
+ "name": "agent_sessions_model_id_model_catalog_id_fk",
179
+ "tableFrom": "agent_sessions",
180
+ "tableTo": "model_catalog",
181
+ "columnsFrom": [
182
+ "model_id"
183
+ ],
184
+ "columnsTo": [
185
+ "id"
186
+ ],
187
+ "onDelete": "no action",
188
+ "onUpdate": "no action"
189
+ }
190
+ },
191
+ "compositePrimaryKeys": {},
192
+ "uniqueConstraints": {},
193
+ "checkConstraints": {
194
+ "agent_sessions_fs_scope_tier_check": {
195
+ "name": "agent_sessions_fs_scope_tier_check",
196
+ "value": "\"agent_sessions\".\"fs_scope_tier\" in ('sandboxed', 'project', 'full')"
197
+ },
198
+ "agent_sessions_status_check": {
199
+ "name": "agent_sessions_status_check",
200
+ "value": "\"agent_sessions\".\"status\" in ('active', 'idle', 'exported', 'ended')"
201
+ }
202
+ }
203
+ },
204
+ "agents": {
205
+ "name": "agents",
206
+ "columns": {
207
+ "id": {
208
+ "name": "id",
209
+ "type": "text",
210
+ "primaryKey": true,
211
+ "notNull": true,
212
+ "autoincrement": false
213
+ },
214
+ "name": {
215
+ "name": "name",
216
+ "type": "text",
217
+ "primaryKey": false,
218
+ "notNull": true,
219
+ "autoincrement": false
220
+ },
221
+ "slug": {
222
+ "name": "slug",
223
+ "type": "text",
224
+ "primaryKey": false,
225
+ "notNull": true,
226
+ "autoincrement": false
227
+ },
228
+ "description": {
229
+ "name": "description",
230
+ "type": "text",
231
+ "primaryKey": false,
232
+ "notNull": false,
233
+ "autoincrement": false
234
+ },
235
+ "model_id": {
236
+ "name": "model_id",
237
+ "type": "text",
238
+ "primaryKey": false,
239
+ "notNull": true,
240
+ "autoincrement": false
241
+ },
242
+ "system_prompt": {
243
+ "name": "system_prompt",
244
+ "type": "text",
245
+ "primaryKey": false,
246
+ "notNull": true,
247
+ "autoincrement": false,
248
+ "default": "''"
249
+ },
250
+ "tools": {
251
+ "name": "tools",
252
+ "type": "text",
253
+ "primaryKey": false,
254
+ "notNull": true,
255
+ "autoincrement": false,
256
+ "default": "'[]'"
257
+ },
258
+ "config": {
259
+ "name": "config",
260
+ "type": "text",
261
+ "primaryKey": false,
262
+ "notNull": true,
263
+ "autoincrement": false,
264
+ "default": "'{}'"
265
+ },
266
+ "input_schema": {
267
+ "name": "input_schema",
268
+ "type": "text",
269
+ "primaryKey": false,
270
+ "notNull": false,
271
+ "autoincrement": false
272
+ },
273
+ "output_schema": {
274
+ "name": "output_schema",
275
+ "type": "text",
276
+ "primaryKey": false,
277
+ "notNull": false,
278
+ "autoincrement": false
279
+ },
280
+ "tags": {
281
+ "name": "tags",
282
+ "type": "text",
283
+ "primaryKey": false,
284
+ "notNull": true,
285
+ "autoincrement": false,
286
+ "default": "'[]'"
287
+ },
288
+ "source_path": {
289
+ "name": "source_path",
290
+ "type": "text",
291
+ "primaryKey": false,
292
+ "notNull": false,
293
+ "autoincrement": false
294
+ },
295
+ "is_active": {
296
+ "name": "is_active",
297
+ "type": "integer",
298
+ "primaryKey": false,
299
+ "notNull": true,
300
+ "autoincrement": false,
301
+ "default": "1"
302
+ },
303
+ "deleted_at": {
304
+ "name": "deleted_at",
305
+ "type": "integer",
306
+ "primaryKey": false,
307
+ "notNull": false,
308
+ "autoincrement": false
309
+ },
310
+ "created_at": {
311
+ "name": "created_at",
312
+ "type": "integer",
313
+ "primaryKey": false,
314
+ "notNull": true,
315
+ "autoincrement": false
316
+ },
317
+ "updated_at": {
318
+ "name": "updated_at",
319
+ "type": "integer",
320
+ "primaryKey": false,
321
+ "notNull": true,
322
+ "autoincrement": false
323
+ }
324
+ },
325
+ "indexes": {
326
+ "idx_agents_slug": {
327
+ "name": "idx_agents_slug",
328
+ "columns": [
329
+ "slug"
330
+ ],
331
+ "isUnique": true,
332
+ "where": "\"agents\".\"deleted_at\" is null"
333
+ },
334
+ "idx_agents_model": {
335
+ "name": "idx_agents_model",
336
+ "columns": [
337
+ "model_id"
338
+ ],
339
+ "isUnique": false
340
+ },
341
+ "idx_agents_active": {
342
+ "name": "idx_agents_active",
343
+ "columns": [
344
+ "is_active",
345
+ "\"created_at\" desc"
346
+ ],
347
+ "isUnique": false,
348
+ "where": "\"agents\".\"deleted_at\" is null"
349
+ }
350
+ },
351
+ "foreignKeys": {
352
+ "agents_model_id_model_catalog_id_fk": {
353
+ "name": "agents_model_id_model_catalog_id_fk",
354
+ "tableFrom": "agents",
355
+ "tableTo": "model_catalog",
356
+ "columnsFrom": [
357
+ "model_id"
358
+ ],
359
+ "columnsTo": [
360
+ "id"
361
+ ],
362
+ "onDelete": "no action",
363
+ "onUpdate": "no action"
364
+ }
365
+ },
366
+ "compositePrimaryKeys": {},
367
+ "uniqueConstraints": {},
368
+ "checkConstraints": {}
369
+ },
370
+ "llm_providers": {
371
+ "name": "llm_providers",
372
+ "columns": {
373
+ "id": {
374
+ "name": "id",
375
+ "type": "text",
376
+ "primaryKey": true,
377
+ "notNull": true,
378
+ "autoincrement": false
379
+ },
380
+ "name": {
381
+ "name": "name",
382
+ "type": "text",
383
+ "primaryKey": false,
384
+ "notNull": true,
385
+ "autoincrement": false
386
+ },
387
+ "display_name": {
388
+ "name": "display_name",
389
+ "type": "text",
390
+ "primaryKey": false,
391
+ "notNull": true,
392
+ "autoincrement": false
393
+ },
394
+ "base_url": {
395
+ "name": "base_url",
396
+ "type": "text",
397
+ "primaryKey": false,
398
+ "notNull": true,
399
+ "autoincrement": false
400
+ },
401
+ "api_key_keychain_ref": {
402
+ "name": "api_key_keychain_ref",
403
+ "type": "text",
404
+ "primaryKey": false,
405
+ "notNull": false,
406
+ "autoincrement": false
407
+ },
408
+ "default_headers": {
409
+ "name": "default_headers",
410
+ "type": "text",
411
+ "primaryKey": false,
412
+ "notNull": true,
413
+ "autoincrement": false,
414
+ "default": "'{}'"
415
+ },
416
+ "is_active": {
417
+ "name": "is_active",
418
+ "type": "integer",
419
+ "primaryKey": false,
420
+ "notNull": true,
421
+ "autoincrement": false,
422
+ "default": "1"
423
+ },
424
+ "deleted_at": {
425
+ "name": "deleted_at",
426
+ "type": "integer",
427
+ "primaryKey": false,
428
+ "notNull": false,
429
+ "autoincrement": false
430
+ },
431
+ "created_at": {
432
+ "name": "created_at",
433
+ "type": "integer",
434
+ "primaryKey": false,
435
+ "notNull": true,
436
+ "autoincrement": false
437
+ },
438
+ "updated_at": {
439
+ "name": "updated_at",
440
+ "type": "integer",
441
+ "primaryKey": false,
442
+ "notNull": true,
443
+ "autoincrement": false
444
+ }
445
+ },
446
+ "indexes": {
447
+ "idx_llm_providers_name": {
448
+ "name": "idx_llm_providers_name",
449
+ "columns": [
450
+ "name"
451
+ ],
452
+ "isUnique": true,
453
+ "where": "\"llm_providers\".\"deleted_at\" is null"
454
+ }
455
+ },
456
+ "foreignKeys": {},
457
+ "compositePrimaryKeys": {},
458
+ "uniqueConstraints": {},
459
+ "checkConstraints": {}
460
+ },
461
+ "messages": {
462
+ "name": "messages",
463
+ "columns": {
464
+ "id": {
465
+ "name": "id",
466
+ "type": "text",
467
+ "primaryKey": true,
468
+ "notNull": true,
469
+ "autoincrement": false
470
+ },
471
+ "step_execution_id": {
472
+ "name": "step_execution_id",
473
+ "type": "text",
474
+ "primaryKey": false,
475
+ "notNull": true,
476
+ "autoincrement": false
477
+ },
478
+ "run_id": {
479
+ "name": "run_id",
480
+ "type": "text",
481
+ "primaryKey": false,
482
+ "notNull": true,
483
+ "autoincrement": false
484
+ },
485
+ "sequence_number": {
486
+ "name": "sequence_number",
487
+ "type": "integer",
488
+ "primaryKey": false,
489
+ "notNull": true,
490
+ "autoincrement": false
491
+ },
492
+ "role": {
493
+ "name": "role",
494
+ "type": "text",
495
+ "primaryKey": false,
496
+ "notNull": true,
497
+ "autoincrement": false
498
+ },
499
+ "content": {
500
+ "name": "content",
501
+ "type": "text",
502
+ "primaryKey": false,
503
+ "notNull": false,
504
+ "autoincrement": false
505
+ },
506
+ "content_parts": {
507
+ "name": "content_parts",
508
+ "type": "text",
509
+ "primaryKey": false,
510
+ "notNull": false,
511
+ "autoincrement": false
512
+ },
513
+ "tool_calls": {
514
+ "name": "tool_calls",
515
+ "type": "text",
516
+ "primaryKey": false,
517
+ "notNull": false,
518
+ "autoincrement": false
519
+ },
520
+ "tool_call_id": {
521
+ "name": "tool_call_id",
522
+ "type": "text",
523
+ "primaryKey": false,
524
+ "notNull": false,
525
+ "autoincrement": false
526
+ },
527
+ "name": {
528
+ "name": "name",
529
+ "type": "text",
530
+ "primaryKey": false,
531
+ "notNull": false,
532
+ "autoincrement": false
533
+ },
534
+ "finish_reason": {
535
+ "name": "finish_reason",
536
+ "type": "text",
537
+ "primaryKey": false,
538
+ "notNull": false,
539
+ "autoincrement": false
540
+ },
541
+ "created_at": {
542
+ "name": "created_at",
543
+ "type": "integer",
544
+ "primaryKey": false,
545
+ "notNull": true,
546
+ "autoincrement": false
547
+ }
548
+ },
549
+ "indexes": {
550
+ "idx_messages_step": {
551
+ "name": "idx_messages_step",
552
+ "columns": [
553
+ "step_execution_id",
554
+ "sequence_number"
555
+ ],
556
+ "isUnique": false
557
+ },
558
+ "idx_messages_run": {
559
+ "name": "idx_messages_run",
560
+ "columns": [
561
+ "run_id",
562
+ "created_at"
563
+ ],
564
+ "isUnique": false
565
+ }
566
+ },
567
+ "foreignKeys": {
568
+ "messages_step_execution_id_step_executions_id_fk": {
569
+ "name": "messages_step_execution_id_step_executions_id_fk",
570
+ "tableFrom": "messages",
571
+ "tableTo": "step_executions",
572
+ "columnsFrom": [
573
+ "step_execution_id"
574
+ ],
575
+ "columnsTo": [
576
+ "id"
577
+ ],
578
+ "onDelete": "cascade",
579
+ "onUpdate": "no action"
580
+ }
581
+ },
582
+ "compositePrimaryKeys": {},
583
+ "uniqueConstraints": {},
584
+ "checkConstraints": {}
585
+ },
586
+ "model_catalog": {
587
+ "name": "model_catalog",
588
+ "columns": {
589
+ "id": {
590
+ "name": "id",
591
+ "type": "text",
592
+ "primaryKey": true,
593
+ "notNull": true,
594
+ "autoincrement": false
595
+ },
596
+ "provider_id": {
597
+ "name": "provider_id",
598
+ "type": "text",
599
+ "primaryKey": false,
600
+ "notNull": true,
601
+ "autoincrement": false
602
+ },
603
+ "model_id": {
604
+ "name": "model_id",
605
+ "type": "text",
606
+ "primaryKey": false,
607
+ "notNull": true,
608
+ "autoincrement": false
609
+ },
610
+ "display_name": {
611
+ "name": "display_name",
612
+ "type": "text",
613
+ "primaryKey": false,
614
+ "notNull": true,
615
+ "autoincrement": false
616
+ },
617
+ "context_window_tokens": {
618
+ "name": "context_window_tokens",
619
+ "type": "integer",
620
+ "primaryKey": false,
621
+ "notNull": true,
622
+ "autoincrement": false
623
+ },
624
+ "max_output_tokens": {
625
+ "name": "max_output_tokens",
626
+ "type": "integer",
627
+ "primaryKey": false,
628
+ "notNull": true,
629
+ "autoincrement": false
630
+ },
631
+ "input_cost_per_mtok_microcents": {
632
+ "name": "input_cost_per_mtok_microcents",
633
+ "type": "integer",
634
+ "primaryKey": false,
635
+ "notNull": true,
636
+ "autoincrement": false,
637
+ "default": 0
638
+ },
639
+ "output_cost_per_mtok_microcents": {
640
+ "name": "output_cost_per_mtok_microcents",
641
+ "type": "integer",
642
+ "primaryKey": false,
643
+ "notNull": true,
644
+ "autoincrement": false,
645
+ "default": 0
646
+ },
647
+ "cached_input_cost_per_mtok_microcents": {
648
+ "name": "cached_input_cost_per_mtok_microcents",
649
+ "type": "integer",
650
+ "primaryKey": false,
651
+ "notNull": true,
652
+ "autoincrement": false,
653
+ "default": 0
654
+ },
655
+ "supports_tool_calling": {
656
+ "name": "supports_tool_calling",
657
+ "type": "integer",
658
+ "primaryKey": false,
659
+ "notNull": true,
660
+ "autoincrement": false,
661
+ "default": "0"
662
+ },
663
+ "supports_vision": {
664
+ "name": "supports_vision",
665
+ "type": "integer",
666
+ "primaryKey": false,
667
+ "notNull": true,
668
+ "autoincrement": false,
669
+ "default": "0"
670
+ },
671
+ "supports_streaming": {
672
+ "name": "supports_streaming",
673
+ "type": "integer",
674
+ "primaryKey": false,
675
+ "notNull": true,
676
+ "autoincrement": false,
677
+ "default": "1"
678
+ },
679
+ "supports_json_mode": {
680
+ "name": "supports_json_mode",
681
+ "type": "integer",
682
+ "primaryKey": false,
683
+ "notNull": true,
684
+ "autoincrement": false,
685
+ "default": "0"
686
+ },
687
+ "capabilities": {
688
+ "name": "capabilities",
689
+ "type": "text",
690
+ "primaryKey": false,
691
+ "notNull": true,
692
+ "autoincrement": false,
693
+ "default": "'{}'"
694
+ },
695
+ "deprecation_date": {
696
+ "name": "deprecation_date",
697
+ "type": "integer",
698
+ "primaryKey": false,
699
+ "notNull": false,
700
+ "autoincrement": false
701
+ },
702
+ "is_active": {
703
+ "name": "is_active",
704
+ "type": "integer",
705
+ "primaryKey": false,
706
+ "notNull": true,
707
+ "autoincrement": false,
708
+ "default": "1"
709
+ },
710
+ "deleted_at": {
711
+ "name": "deleted_at",
712
+ "type": "integer",
713
+ "primaryKey": false,
714
+ "notNull": false,
715
+ "autoincrement": false
716
+ },
717
+ "created_at": {
718
+ "name": "created_at",
719
+ "type": "integer",
720
+ "primaryKey": false,
721
+ "notNull": true,
722
+ "autoincrement": false
723
+ },
724
+ "updated_at": {
725
+ "name": "updated_at",
726
+ "type": "integer",
727
+ "primaryKey": false,
728
+ "notNull": true,
729
+ "autoincrement": false
730
+ }
731
+ },
732
+ "indexes": {
733
+ "idx_model_catalog_provider_model": {
734
+ "name": "idx_model_catalog_provider_model",
735
+ "columns": [
736
+ "provider_id",
737
+ "model_id"
738
+ ],
739
+ "isUnique": true,
740
+ "where": "\"model_catalog\".\"deleted_at\" is null"
741
+ },
742
+ "idx_model_catalog_provider": {
743
+ "name": "idx_model_catalog_provider",
744
+ "columns": [
745
+ "provider_id"
746
+ ],
747
+ "isUnique": false
748
+ },
749
+ "idx_model_catalog_active": {
750
+ "name": "idx_model_catalog_active",
751
+ "columns": [
752
+ "is_active"
753
+ ],
754
+ "isUnique": false,
755
+ "where": "\"model_catalog\".\"deleted_at\" is null"
756
+ }
757
+ },
758
+ "foreignKeys": {
759
+ "model_catalog_provider_id_llm_providers_id_fk": {
760
+ "name": "model_catalog_provider_id_llm_providers_id_fk",
761
+ "tableFrom": "model_catalog",
762
+ "tableTo": "llm_providers",
763
+ "columnsFrom": [
764
+ "provider_id"
765
+ ],
766
+ "columnsTo": [
767
+ "id"
768
+ ],
769
+ "onDelete": "no action",
770
+ "onUpdate": "no action"
771
+ }
772
+ },
773
+ "compositePrimaryKeys": {},
774
+ "uniqueConstraints": {},
775
+ "checkConstraints": {}
776
+ },
777
+ "run_costs": {
778
+ "name": "run_costs",
779
+ "columns": {
780
+ "id": {
781
+ "name": "id",
782
+ "type": "text",
783
+ "primaryKey": true,
784
+ "notNull": true,
785
+ "autoincrement": false
786
+ },
787
+ "run_id": {
788
+ "name": "run_id",
789
+ "type": "text",
790
+ "primaryKey": false,
791
+ "notNull": true,
792
+ "autoincrement": false
793
+ },
794
+ "node_id": {
795
+ "name": "node_id",
796
+ "type": "text",
797
+ "primaryKey": false,
798
+ "notNull": true,
799
+ "autoincrement": false
800
+ },
801
+ "model_id": {
802
+ "name": "model_id",
803
+ "type": "text",
804
+ "primaryKey": false,
805
+ "notNull": false,
806
+ "autoincrement": false
807
+ },
808
+ "input_tokens": {
809
+ "name": "input_tokens",
810
+ "type": "integer",
811
+ "primaryKey": false,
812
+ "notNull": true,
813
+ "autoincrement": false,
814
+ "default": 0
815
+ },
816
+ "output_tokens": {
817
+ "name": "output_tokens",
818
+ "type": "integer",
819
+ "primaryKey": false,
820
+ "notNull": true,
821
+ "autoincrement": false,
822
+ "default": 0
823
+ },
824
+ "cost_microcents": {
825
+ "name": "cost_microcents",
826
+ "type": "integer",
827
+ "primaryKey": false,
828
+ "notNull": true,
829
+ "autoincrement": false,
830
+ "default": 0
831
+ },
832
+ "created_at": {
833
+ "name": "created_at",
834
+ "type": "integer",
835
+ "primaryKey": false,
836
+ "notNull": true,
837
+ "autoincrement": false
838
+ }
839
+ },
840
+ "indexes": {
841
+ "idx_run_costs_run": {
842
+ "name": "idx_run_costs_run",
843
+ "columns": [
844
+ "run_id"
845
+ ],
846
+ "isUnique": false
847
+ }
848
+ },
849
+ "foreignKeys": {
850
+ "run_costs_run_id_runs_id_fk": {
851
+ "name": "run_costs_run_id_runs_id_fk",
852
+ "tableFrom": "run_costs",
853
+ "tableTo": "runs",
854
+ "columnsFrom": [
855
+ "run_id"
856
+ ],
857
+ "columnsTo": [
858
+ "id"
859
+ ],
860
+ "onDelete": "cascade",
861
+ "onUpdate": "no action"
862
+ },
863
+ "run_costs_model_id_model_catalog_id_fk": {
864
+ "name": "run_costs_model_id_model_catalog_id_fk",
865
+ "tableFrom": "run_costs",
866
+ "tableTo": "model_catalog",
867
+ "columnsFrom": [
868
+ "model_id"
869
+ ],
870
+ "columnsTo": [
871
+ "id"
872
+ ],
873
+ "onDelete": "no action",
874
+ "onUpdate": "no action"
875
+ }
876
+ },
877
+ "compositePrimaryKeys": {},
878
+ "uniqueConstraints": {},
879
+ "checkConstraints": {}
880
+ },
881
+ "run_events": {
882
+ "name": "run_events",
883
+ "columns": {
884
+ "id": {
885
+ "name": "id",
886
+ "type": "text",
887
+ "primaryKey": true,
888
+ "notNull": true,
889
+ "autoincrement": false
890
+ },
891
+ "run_id": {
892
+ "name": "run_id",
893
+ "type": "text",
894
+ "primaryKey": false,
895
+ "notNull": true,
896
+ "autoincrement": false
897
+ },
898
+ "step_execution_id": {
899
+ "name": "step_execution_id",
900
+ "type": "text",
901
+ "primaryKey": false,
902
+ "notNull": false,
903
+ "autoincrement": false
904
+ },
905
+ "seq": {
906
+ "name": "seq",
907
+ "type": "integer",
908
+ "primaryKey": false,
909
+ "notNull": true,
910
+ "autoincrement": false
911
+ },
912
+ "event_type": {
913
+ "name": "event_type",
914
+ "type": "text",
915
+ "primaryKey": false,
916
+ "notNull": true,
917
+ "autoincrement": false
918
+ },
919
+ "level": {
920
+ "name": "level",
921
+ "type": "text",
922
+ "primaryKey": false,
923
+ "notNull": true,
924
+ "autoincrement": false,
925
+ "default": "'info'"
926
+ },
927
+ "node_id": {
928
+ "name": "node_id",
929
+ "type": "text",
930
+ "primaryKey": false,
931
+ "notNull": false,
932
+ "autoincrement": false
933
+ },
934
+ "payload_json": {
935
+ "name": "payload_json",
936
+ "type": "text",
937
+ "primaryKey": false,
938
+ "notNull": true,
939
+ "autoincrement": false,
940
+ "default": "'{}'"
941
+ },
942
+ "ts": {
943
+ "name": "ts",
944
+ "type": "integer",
945
+ "primaryKey": false,
946
+ "notNull": true,
947
+ "autoincrement": false
948
+ }
949
+ },
950
+ "indexes": {
951
+ "idx_run_events_run_seq": {
952
+ "name": "idx_run_events_run_seq",
953
+ "columns": [
954
+ "run_id",
955
+ "seq"
956
+ ],
957
+ "isUnique": true
958
+ },
959
+ "idx_run_events_step": {
960
+ "name": "idx_run_events_step",
961
+ "columns": [
962
+ "step_execution_id",
963
+ "ts"
964
+ ],
965
+ "isUnique": false,
966
+ "where": "\"run_events\".\"step_execution_id\" is not null"
967
+ },
968
+ "idx_run_events_run_type": {
969
+ "name": "idx_run_events_run_type",
970
+ "columns": [
971
+ "run_id",
972
+ "event_type",
973
+ "ts"
974
+ ],
975
+ "isUnique": false
976
+ }
977
+ },
978
+ "foreignKeys": {
979
+ "run_events_run_id_runs_id_fk": {
980
+ "name": "run_events_run_id_runs_id_fk",
981
+ "tableFrom": "run_events",
982
+ "tableTo": "runs",
983
+ "columnsFrom": [
984
+ "run_id"
985
+ ],
986
+ "columnsTo": [
987
+ "id"
988
+ ],
989
+ "onDelete": "cascade",
990
+ "onUpdate": "no action"
991
+ }
992
+ },
993
+ "compositePrimaryKeys": {},
994
+ "uniqueConstraints": {},
995
+ "checkConstraints": {}
996
+ },
997
+ "runs": {
998
+ "name": "runs",
999
+ "columns": {
1000
+ "id": {
1001
+ "name": "id",
1002
+ "type": "text",
1003
+ "primaryKey": true,
1004
+ "notNull": true,
1005
+ "autoincrement": false
1006
+ },
1007
+ "workflow_id": {
1008
+ "name": "workflow_id",
1009
+ "type": "text",
1010
+ "primaryKey": false,
1011
+ "notNull": true,
1012
+ "autoincrement": false
1013
+ },
1014
+ "workflow_path": {
1015
+ "name": "workflow_path",
1016
+ "type": "text",
1017
+ "primaryKey": false,
1018
+ "notNull": false,
1019
+ "autoincrement": false
1020
+ },
1021
+ "project_root": {
1022
+ "name": "project_root",
1023
+ "type": "text",
1024
+ "primaryKey": false,
1025
+ "notNull": false,
1026
+ "autoincrement": false
1027
+ },
1028
+ "workflow_definition_snapshot": {
1029
+ "name": "workflow_definition_snapshot",
1030
+ "type": "text",
1031
+ "primaryKey": false,
1032
+ "notNull": true,
1033
+ "autoincrement": false
1034
+ },
1035
+ "status": {
1036
+ "name": "status",
1037
+ "type": "text",
1038
+ "primaryKey": false,
1039
+ "notNull": true,
1040
+ "autoincrement": false,
1041
+ "default": "'pending'"
1042
+ },
1043
+ "execution_mode": {
1044
+ "name": "execution_mode",
1045
+ "type": "text",
1046
+ "primaryKey": false,
1047
+ "notNull": true,
1048
+ "autoincrement": false,
1049
+ "default": "'local'"
1050
+ },
1051
+ "trigger_type": {
1052
+ "name": "trigger_type",
1053
+ "type": "text",
1054
+ "primaryKey": false,
1055
+ "notNull": true,
1056
+ "autoincrement": false,
1057
+ "default": "'manual'"
1058
+ },
1059
+ "trigger_metadata": {
1060
+ "name": "trigger_metadata",
1061
+ "type": "text",
1062
+ "primaryKey": false,
1063
+ "notNull": true,
1064
+ "autoincrement": false,
1065
+ "default": "'{}'"
1066
+ },
1067
+ "input_json": {
1068
+ "name": "input_json",
1069
+ "type": "text",
1070
+ "primaryKey": false,
1071
+ "notNull": true,
1072
+ "autoincrement": false,
1073
+ "default": "'{}'"
1074
+ },
1075
+ "output_json": {
1076
+ "name": "output_json",
1077
+ "type": "text",
1078
+ "primaryKey": false,
1079
+ "notNull": false,
1080
+ "autoincrement": false
1081
+ },
1082
+ "error_json": {
1083
+ "name": "error_json",
1084
+ "type": "text",
1085
+ "primaryKey": false,
1086
+ "notNull": false,
1087
+ "autoincrement": false
1088
+ },
1089
+ "started_at": {
1090
+ "name": "started_at",
1091
+ "type": "integer",
1092
+ "primaryKey": false,
1093
+ "notNull": false,
1094
+ "autoincrement": false
1095
+ },
1096
+ "completed_at": {
1097
+ "name": "completed_at",
1098
+ "type": "integer",
1099
+ "primaryKey": false,
1100
+ "notNull": false,
1101
+ "autoincrement": false
1102
+ },
1103
+ "total_input_tokens": {
1104
+ "name": "total_input_tokens",
1105
+ "type": "integer",
1106
+ "primaryKey": false,
1107
+ "notNull": true,
1108
+ "autoincrement": false,
1109
+ "default": 0
1110
+ },
1111
+ "total_output_tokens": {
1112
+ "name": "total_output_tokens",
1113
+ "type": "integer",
1114
+ "primaryKey": false,
1115
+ "notNull": true,
1116
+ "autoincrement": false,
1117
+ "default": 0
1118
+ },
1119
+ "total_cost_microcents": {
1120
+ "name": "total_cost_microcents",
1121
+ "type": "integer",
1122
+ "primaryKey": false,
1123
+ "notNull": true,
1124
+ "autoincrement": false,
1125
+ "default": 0
1126
+ },
1127
+ "deleted_at": {
1128
+ "name": "deleted_at",
1129
+ "type": "integer",
1130
+ "primaryKey": false,
1131
+ "notNull": false,
1132
+ "autoincrement": false
1133
+ },
1134
+ "created_at": {
1135
+ "name": "created_at",
1136
+ "type": "integer",
1137
+ "primaryKey": false,
1138
+ "notNull": true,
1139
+ "autoincrement": false
1140
+ },
1141
+ "updated_at": {
1142
+ "name": "updated_at",
1143
+ "type": "integer",
1144
+ "primaryKey": false,
1145
+ "notNull": true,
1146
+ "autoincrement": false
1147
+ }
1148
+ },
1149
+ "indexes": {
1150
+ "idx_runs_workflow": {
1151
+ "name": "idx_runs_workflow",
1152
+ "columns": [
1153
+ "workflow_id",
1154
+ "\"created_at\" desc"
1155
+ ],
1156
+ "isUnique": false
1157
+ },
1158
+ "idx_runs_status": {
1159
+ "name": "idx_runs_status",
1160
+ "columns": [
1161
+ "status",
1162
+ "\"created_at\" desc"
1163
+ ],
1164
+ "isUnique": false,
1165
+ "where": "\"runs\".\"deleted_at\" is null"
1166
+ },
1167
+ "idx_runs_cost": {
1168
+ "name": "idx_runs_cost",
1169
+ "columns": [
1170
+ "workflow_id",
1171
+ "created_at",
1172
+ "total_cost_microcents"
1173
+ ],
1174
+ "isUnique": false,
1175
+ "where": "\"runs\".\"deleted_at\" is null"
1176
+ }
1177
+ },
1178
+ "foreignKeys": {
1179
+ "runs_workflow_id_workflows_id_fk": {
1180
+ "name": "runs_workflow_id_workflows_id_fk",
1181
+ "tableFrom": "runs",
1182
+ "tableTo": "workflows",
1183
+ "columnsFrom": [
1184
+ "workflow_id"
1185
+ ],
1186
+ "columnsTo": [
1187
+ "id"
1188
+ ],
1189
+ "onDelete": "no action",
1190
+ "onUpdate": "no action"
1191
+ }
1192
+ },
1193
+ "compositePrimaryKeys": {},
1194
+ "uniqueConstraints": {},
1195
+ "checkConstraints": {
1196
+ "runs_status_check": {
1197
+ "name": "runs_status_check",
1198
+ "value": "\"runs\".\"status\" in ('pending', 'running', 'paused', 'completed', 'failed', 'cancelled')"
1199
+ },
1200
+ "runs_execution_mode_check": {
1201
+ "name": "runs_execution_mode_check",
1202
+ "value": "\"runs\".\"execution_mode\" in ('local', 'cloud', 'managed')"
1203
+ }
1204
+ }
1205
+ },
1206
+ "session_messages": {
1207
+ "name": "session_messages",
1208
+ "columns": {
1209
+ "id": {
1210
+ "name": "id",
1211
+ "type": "text",
1212
+ "primaryKey": true,
1213
+ "notNull": true,
1214
+ "autoincrement": false
1215
+ },
1216
+ "session_id": {
1217
+ "name": "session_id",
1218
+ "type": "text",
1219
+ "primaryKey": false,
1220
+ "notNull": true,
1221
+ "autoincrement": false
1222
+ },
1223
+ "sequence_number": {
1224
+ "name": "sequence_number",
1225
+ "type": "integer",
1226
+ "primaryKey": false,
1227
+ "notNull": true,
1228
+ "autoincrement": false
1229
+ },
1230
+ "role": {
1231
+ "name": "role",
1232
+ "type": "text",
1233
+ "primaryKey": false,
1234
+ "notNull": true,
1235
+ "autoincrement": false
1236
+ },
1237
+ "content": {
1238
+ "name": "content",
1239
+ "type": "text",
1240
+ "primaryKey": false,
1241
+ "notNull": false,
1242
+ "autoincrement": false
1243
+ },
1244
+ "content_parts": {
1245
+ "name": "content_parts",
1246
+ "type": "text",
1247
+ "primaryKey": false,
1248
+ "notNull": false,
1249
+ "autoincrement": false
1250
+ },
1251
+ "tool_calls": {
1252
+ "name": "tool_calls",
1253
+ "type": "text",
1254
+ "primaryKey": false,
1255
+ "notNull": false,
1256
+ "autoincrement": false
1257
+ },
1258
+ "tool_call_id": {
1259
+ "name": "tool_call_id",
1260
+ "type": "text",
1261
+ "primaryKey": false,
1262
+ "notNull": false,
1263
+ "autoincrement": false
1264
+ },
1265
+ "name": {
1266
+ "name": "name",
1267
+ "type": "text",
1268
+ "primaryKey": false,
1269
+ "notNull": false,
1270
+ "autoincrement": false
1271
+ },
1272
+ "finish_reason": {
1273
+ "name": "finish_reason",
1274
+ "type": "text",
1275
+ "primaryKey": false,
1276
+ "notNull": false,
1277
+ "autoincrement": false
1278
+ },
1279
+ "model_id": {
1280
+ "name": "model_id",
1281
+ "type": "text",
1282
+ "primaryKey": false,
1283
+ "notNull": false,
1284
+ "autoincrement": false
1285
+ },
1286
+ "input_tokens": {
1287
+ "name": "input_tokens",
1288
+ "type": "integer",
1289
+ "primaryKey": false,
1290
+ "notNull": true,
1291
+ "autoincrement": false,
1292
+ "default": 0
1293
+ },
1294
+ "output_tokens": {
1295
+ "name": "output_tokens",
1296
+ "type": "integer",
1297
+ "primaryKey": false,
1298
+ "notNull": true,
1299
+ "autoincrement": false,
1300
+ "default": 0
1301
+ },
1302
+ "cost_microcents": {
1303
+ "name": "cost_microcents",
1304
+ "type": "integer",
1305
+ "primaryKey": false,
1306
+ "notNull": true,
1307
+ "autoincrement": false,
1308
+ "default": 0
1309
+ },
1310
+ "created_at": {
1311
+ "name": "created_at",
1312
+ "type": "integer",
1313
+ "primaryKey": false,
1314
+ "notNull": true,
1315
+ "autoincrement": false
1316
+ }
1317
+ },
1318
+ "indexes": {
1319
+ "idx_session_messages_seq": {
1320
+ "name": "idx_session_messages_seq",
1321
+ "columns": [
1322
+ "session_id",
1323
+ "sequence_number"
1324
+ ],
1325
+ "isUnique": true
1326
+ },
1327
+ "idx_session_messages_session": {
1328
+ "name": "idx_session_messages_session",
1329
+ "columns": [
1330
+ "session_id",
1331
+ "created_at"
1332
+ ],
1333
+ "isUnique": false
1334
+ }
1335
+ },
1336
+ "foreignKeys": {
1337
+ "session_messages_session_id_agent_sessions_id_fk": {
1338
+ "name": "session_messages_session_id_agent_sessions_id_fk",
1339
+ "tableFrom": "session_messages",
1340
+ "tableTo": "agent_sessions",
1341
+ "columnsFrom": [
1342
+ "session_id"
1343
+ ],
1344
+ "columnsTo": [
1345
+ "id"
1346
+ ],
1347
+ "onDelete": "cascade",
1348
+ "onUpdate": "no action"
1349
+ },
1350
+ "session_messages_model_id_model_catalog_id_fk": {
1351
+ "name": "session_messages_model_id_model_catalog_id_fk",
1352
+ "tableFrom": "session_messages",
1353
+ "tableTo": "model_catalog",
1354
+ "columnsFrom": [
1355
+ "model_id"
1356
+ ],
1357
+ "columnsTo": [
1358
+ "id"
1359
+ ],
1360
+ "onDelete": "no action",
1361
+ "onUpdate": "no action"
1362
+ }
1363
+ },
1364
+ "compositePrimaryKeys": {},
1365
+ "uniqueConstraints": {},
1366
+ "checkConstraints": {}
1367
+ },
1368
+ "step_executions": {
1369
+ "name": "step_executions",
1370
+ "columns": {
1371
+ "id": {
1372
+ "name": "id",
1373
+ "type": "text",
1374
+ "primaryKey": true,
1375
+ "notNull": true,
1376
+ "autoincrement": false
1377
+ },
1378
+ "run_id": {
1379
+ "name": "run_id",
1380
+ "type": "text",
1381
+ "primaryKey": false,
1382
+ "notNull": true,
1383
+ "autoincrement": false
1384
+ },
1385
+ "node_id": {
1386
+ "name": "node_id",
1387
+ "type": "text",
1388
+ "primaryKey": false,
1389
+ "notNull": true,
1390
+ "autoincrement": false
1391
+ },
1392
+ "node_type": {
1393
+ "name": "node_type",
1394
+ "type": "text",
1395
+ "primaryKey": false,
1396
+ "notNull": true,
1397
+ "autoincrement": false
1398
+ },
1399
+ "agent_id": {
1400
+ "name": "agent_id",
1401
+ "type": "text",
1402
+ "primaryKey": false,
1403
+ "notNull": false,
1404
+ "autoincrement": false
1405
+ },
1406
+ "agent_snapshot": {
1407
+ "name": "agent_snapshot",
1408
+ "type": "text",
1409
+ "primaryKey": false,
1410
+ "notNull": false,
1411
+ "autoincrement": false
1412
+ },
1413
+ "model_id": {
1414
+ "name": "model_id",
1415
+ "type": "text",
1416
+ "primaryKey": false,
1417
+ "notNull": false,
1418
+ "autoincrement": false
1419
+ },
1420
+ "attempt_number": {
1421
+ "name": "attempt_number",
1422
+ "type": "integer",
1423
+ "primaryKey": false,
1424
+ "notNull": true,
1425
+ "autoincrement": false,
1426
+ "default": 1
1427
+ },
1428
+ "status": {
1429
+ "name": "status",
1430
+ "type": "text",
1431
+ "primaryKey": false,
1432
+ "notNull": true,
1433
+ "autoincrement": false,
1434
+ "default": "'pending'"
1435
+ },
1436
+ "input_json": {
1437
+ "name": "input_json",
1438
+ "type": "text",
1439
+ "primaryKey": false,
1440
+ "notNull": true,
1441
+ "autoincrement": false,
1442
+ "default": "'{}'"
1443
+ },
1444
+ "output_json": {
1445
+ "name": "output_json",
1446
+ "type": "text",
1447
+ "primaryKey": false,
1448
+ "notNull": false,
1449
+ "autoincrement": false
1450
+ },
1451
+ "error_json": {
1452
+ "name": "error_json",
1453
+ "type": "text",
1454
+ "primaryKey": false,
1455
+ "notNull": false,
1456
+ "autoincrement": false
1457
+ },
1458
+ "started_at": {
1459
+ "name": "started_at",
1460
+ "type": "integer",
1461
+ "primaryKey": false,
1462
+ "notNull": false,
1463
+ "autoincrement": false
1464
+ },
1465
+ "completed_at": {
1466
+ "name": "completed_at",
1467
+ "type": "integer",
1468
+ "primaryKey": false,
1469
+ "notNull": false,
1470
+ "autoincrement": false
1471
+ },
1472
+ "duration_ms": {
1473
+ "name": "duration_ms",
1474
+ "type": "integer",
1475
+ "primaryKey": false,
1476
+ "notNull": false,
1477
+ "autoincrement": false
1478
+ },
1479
+ "input_tokens": {
1480
+ "name": "input_tokens",
1481
+ "type": "integer",
1482
+ "primaryKey": false,
1483
+ "notNull": true,
1484
+ "autoincrement": false,
1485
+ "default": 0
1486
+ },
1487
+ "output_tokens": {
1488
+ "name": "output_tokens",
1489
+ "type": "integer",
1490
+ "primaryKey": false,
1491
+ "notNull": true,
1492
+ "autoincrement": false,
1493
+ "default": 0
1494
+ },
1495
+ "cached_tokens": {
1496
+ "name": "cached_tokens",
1497
+ "type": "integer",
1498
+ "primaryKey": false,
1499
+ "notNull": true,
1500
+ "autoincrement": false,
1501
+ "default": 0
1502
+ },
1503
+ "cost_microcents": {
1504
+ "name": "cost_microcents",
1505
+ "type": "integer",
1506
+ "primaryKey": false,
1507
+ "notNull": true,
1508
+ "autoincrement": false,
1509
+ "default": 0
1510
+ },
1511
+ "created_at": {
1512
+ "name": "created_at",
1513
+ "type": "integer",
1514
+ "primaryKey": false,
1515
+ "notNull": true,
1516
+ "autoincrement": false
1517
+ },
1518
+ "updated_at": {
1519
+ "name": "updated_at",
1520
+ "type": "integer",
1521
+ "primaryKey": false,
1522
+ "notNull": true,
1523
+ "autoincrement": false
1524
+ }
1525
+ },
1526
+ "indexes": {
1527
+ "idx_step_exec_run": {
1528
+ "name": "idx_step_exec_run",
1529
+ "columns": [
1530
+ "run_id",
1531
+ "created_at"
1532
+ ],
1533
+ "isUnique": false
1534
+ },
1535
+ "idx_step_exec_run_node": {
1536
+ "name": "idx_step_exec_run_node",
1537
+ "columns": [
1538
+ "run_id",
1539
+ "node_id",
1540
+ "attempt_number"
1541
+ ],
1542
+ "isUnique": false
1543
+ },
1544
+ "idx_step_exec_agent": {
1545
+ "name": "idx_step_exec_agent",
1546
+ "columns": [
1547
+ "agent_id",
1548
+ "\"created_at\" desc"
1549
+ ],
1550
+ "isUnique": false,
1551
+ "where": "\"step_executions\".\"agent_id\" is not null"
1552
+ },
1553
+ "idx_step_exec_model": {
1554
+ "name": "idx_step_exec_model",
1555
+ "columns": [
1556
+ "model_id",
1557
+ "\"created_at\" desc"
1558
+ ],
1559
+ "isUnique": false,
1560
+ "where": "\"step_executions\".\"model_id\" is not null"
1561
+ },
1562
+ "idx_step_exec_cost": {
1563
+ "name": "idx_step_exec_cost",
1564
+ "columns": [
1565
+ "model_id",
1566
+ "created_at",
1567
+ "cost_microcents"
1568
+ ],
1569
+ "isUnique": false,
1570
+ "where": "\"step_executions\".\"model_id\" is not null"
1571
+ }
1572
+ },
1573
+ "foreignKeys": {
1574
+ "step_executions_run_id_runs_id_fk": {
1575
+ "name": "step_executions_run_id_runs_id_fk",
1576
+ "tableFrom": "step_executions",
1577
+ "tableTo": "runs",
1578
+ "columnsFrom": [
1579
+ "run_id"
1580
+ ],
1581
+ "columnsTo": [
1582
+ "id"
1583
+ ],
1584
+ "onDelete": "cascade",
1585
+ "onUpdate": "no action"
1586
+ },
1587
+ "step_executions_agent_id_agents_id_fk": {
1588
+ "name": "step_executions_agent_id_agents_id_fk",
1589
+ "tableFrom": "step_executions",
1590
+ "tableTo": "agents",
1591
+ "columnsFrom": [
1592
+ "agent_id"
1593
+ ],
1594
+ "columnsTo": [
1595
+ "id"
1596
+ ],
1597
+ "onDelete": "no action",
1598
+ "onUpdate": "no action"
1599
+ },
1600
+ "step_executions_model_id_model_catalog_id_fk": {
1601
+ "name": "step_executions_model_id_model_catalog_id_fk",
1602
+ "tableFrom": "step_executions",
1603
+ "tableTo": "model_catalog",
1604
+ "columnsFrom": [
1605
+ "model_id"
1606
+ ],
1607
+ "columnsTo": [
1608
+ "id"
1609
+ ],
1610
+ "onDelete": "no action",
1611
+ "onUpdate": "no action"
1612
+ }
1613
+ },
1614
+ "compositePrimaryKeys": {},
1615
+ "uniqueConstraints": {},
1616
+ "checkConstraints": {
1617
+ "step_executions_status_check": {
1618
+ "name": "step_executions_status_check",
1619
+ "value": "\"step_executions\".\"status\" in ('pending', 'running', 'completed', 'failed', 'skipped')"
1620
+ }
1621
+ }
1622
+ },
1623
+ "workflows": {
1624
+ "name": "workflows",
1625
+ "columns": {
1626
+ "id": {
1627
+ "name": "id",
1628
+ "type": "text",
1629
+ "primaryKey": true,
1630
+ "notNull": true,
1631
+ "autoincrement": false
1632
+ },
1633
+ "name": {
1634
+ "name": "name",
1635
+ "type": "text",
1636
+ "primaryKey": false,
1637
+ "notNull": true,
1638
+ "autoincrement": false
1639
+ },
1640
+ "slug": {
1641
+ "name": "slug",
1642
+ "type": "text",
1643
+ "primaryKey": false,
1644
+ "notNull": true,
1645
+ "autoincrement": false
1646
+ },
1647
+ "description": {
1648
+ "name": "description",
1649
+ "type": "text",
1650
+ "primaryKey": false,
1651
+ "notNull": false,
1652
+ "autoincrement": false
1653
+ },
1654
+ "definition": {
1655
+ "name": "definition",
1656
+ "type": "text",
1657
+ "primaryKey": false,
1658
+ "notNull": true,
1659
+ "autoincrement": false
1660
+ },
1661
+ "input_schema": {
1662
+ "name": "input_schema",
1663
+ "type": "text",
1664
+ "primaryKey": false,
1665
+ "notNull": false,
1666
+ "autoincrement": false
1667
+ },
1668
+ "tags": {
1669
+ "name": "tags",
1670
+ "type": "text",
1671
+ "primaryKey": false,
1672
+ "notNull": true,
1673
+ "autoincrement": false,
1674
+ "default": "'[]'"
1675
+ },
1676
+ "source_path": {
1677
+ "name": "source_path",
1678
+ "type": "text",
1679
+ "primaryKey": false,
1680
+ "notNull": false,
1681
+ "autoincrement": false
1682
+ },
1683
+ "is_active": {
1684
+ "name": "is_active",
1685
+ "type": "integer",
1686
+ "primaryKey": false,
1687
+ "notNull": true,
1688
+ "autoincrement": false,
1689
+ "default": "1"
1690
+ },
1691
+ "deleted_at": {
1692
+ "name": "deleted_at",
1693
+ "type": "integer",
1694
+ "primaryKey": false,
1695
+ "notNull": false,
1696
+ "autoincrement": false
1697
+ },
1698
+ "created_at": {
1699
+ "name": "created_at",
1700
+ "type": "integer",
1701
+ "primaryKey": false,
1702
+ "notNull": true,
1703
+ "autoincrement": false
1704
+ },
1705
+ "updated_at": {
1706
+ "name": "updated_at",
1707
+ "type": "integer",
1708
+ "primaryKey": false,
1709
+ "notNull": true,
1710
+ "autoincrement": false
1711
+ }
1712
+ },
1713
+ "indexes": {
1714
+ "idx_workflows_slug": {
1715
+ "name": "idx_workflows_slug",
1716
+ "columns": [
1717
+ "slug"
1718
+ ],
1719
+ "isUnique": true,
1720
+ "where": "\"workflows\".\"deleted_at\" is null"
1721
+ },
1722
+ "idx_workflows_active": {
1723
+ "name": "idx_workflows_active",
1724
+ "columns": [
1725
+ "is_active",
1726
+ "\"updated_at\" desc"
1727
+ ],
1728
+ "isUnique": false,
1729
+ "where": "\"workflows\".\"deleted_at\" is null"
1730
+ }
1731
+ },
1732
+ "foreignKeys": {},
1733
+ "compositePrimaryKeys": {},
1734
+ "uniqueConstraints": {},
1735
+ "checkConstraints": {}
1736
+ }
1737
+ },
1738
+ "views": {},
1739
+ "enums": {},
1740
+ "_meta": {
1741
+ "schemas": {},
1742
+ "tables": {},
1743
+ "columns": {}
1744
+ },
1745
+ "internal": {
1746
+ "indexes": {
1747
+ "idx_agent_sessions_status": {
1748
+ "columns": {
1749
+ "\"updated_at\" desc": {
1750
+ "isExpression": true
1751
+ }
1752
+ }
1753
+ },
1754
+ "idx_agent_sessions_agent": {
1755
+ "columns": {
1756
+ "\"created_at\" desc": {
1757
+ "isExpression": true
1758
+ }
1759
+ }
1760
+ },
1761
+ "idx_agents_active": {
1762
+ "columns": {
1763
+ "\"created_at\" desc": {
1764
+ "isExpression": true
1765
+ }
1766
+ }
1767
+ },
1768
+ "idx_runs_workflow": {
1769
+ "columns": {
1770
+ "\"created_at\" desc": {
1771
+ "isExpression": true
1772
+ }
1773
+ }
1774
+ },
1775
+ "idx_runs_status": {
1776
+ "columns": {
1777
+ "\"created_at\" desc": {
1778
+ "isExpression": true
1779
+ }
1780
+ }
1781
+ },
1782
+ "idx_step_exec_agent": {
1783
+ "columns": {
1784
+ "\"created_at\" desc": {
1785
+ "isExpression": true
1786
+ }
1787
+ }
1788
+ },
1789
+ "idx_step_exec_model": {
1790
+ "columns": {
1791
+ "\"created_at\" desc": {
1792
+ "isExpression": true
1793
+ }
1794
+ }
1795
+ },
1796
+ "idx_workflows_active": {
1797
+ "columns": {
1798
+ "\"updated_at\" desc": {
1799
+ "isExpression": true
1800
+ }
1801
+ }
1802
+ }
1803
+ }
1804
+ }
1805
+ }