@inkeep/agents-core 0.27.0 → 0.28.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,2988 @@
1
+ {
2
+ "version": "6",
3
+ "dialect": "sqlite",
4
+ "id": "d867a89b-5b2a-47cc-9ffb-7bdd69688bdf",
5
+ "prevId": "b8d51551-95dd-4f36-a5e0-cb7956c1565a",
6
+ "tables": {
7
+ "agent": {
8
+ "name": "agent",
9
+ "columns": {
10
+ "tenant_id": {
11
+ "name": "tenant_id",
12
+ "type": "text",
13
+ "primaryKey": false,
14
+ "notNull": true,
15
+ "autoincrement": false
16
+ },
17
+ "id": {
18
+ "name": "id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true,
22
+ "autoincrement": false
23
+ },
24
+ "project_id": {
25
+ "name": "project_id",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true,
29
+ "autoincrement": false
30
+ },
31
+ "name": {
32
+ "name": "name",
33
+ "type": "text",
34
+ "primaryKey": false,
35
+ "notNull": true,
36
+ "autoincrement": false
37
+ },
38
+ "description": {
39
+ "name": "description",
40
+ "type": "text",
41
+ "primaryKey": false,
42
+ "notNull": false,
43
+ "autoincrement": false
44
+ },
45
+ "default_sub_agent_id": {
46
+ "name": "default_sub_agent_id",
47
+ "type": "text",
48
+ "primaryKey": false,
49
+ "notNull": false,
50
+ "autoincrement": false
51
+ },
52
+ "context_config_id": {
53
+ "name": "context_config_id",
54
+ "type": "text",
55
+ "primaryKey": false,
56
+ "notNull": false,
57
+ "autoincrement": false
58
+ },
59
+ "models": {
60
+ "name": "models",
61
+ "type": "text",
62
+ "primaryKey": false,
63
+ "notNull": false,
64
+ "autoincrement": false
65
+ },
66
+ "status_updates": {
67
+ "name": "status_updates",
68
+ "type": "text",
69
+ "primaryKey": false,
70
+ "notNull": false,
71
+ "autoincrement": false
72
+ },
73
+ "prompt": {
74
+ "name": "prompt",
75
+ "type": "text",
76
+ "primaryKey": false,
77
+ "notNull": false,
78
+ "autoincrement": false
79
+ },
80
+ "stop_when": {
81
+ "name": "stop_when",
82
+ "type": "text",
83
+ "primaryKey": false,
84
+ "notNull": false,
85
+ "autoincrement": false
86
+ },
87
+ "created_at": {
88
+ "name": "created_at",
89
+ "type": "text",
90
+ "primaryKey": false,
91
+ "notNull": true,
92
+ "autoincrement": false,
93
+ "default": "CURRENT_TIMESTAMP"
94
+ },
95
+ "updated_at": {
96
+ "name": "updated_at",
97
+ "type": "text",
98
+ "primaryKey": false,
99
+ "notNull": true,
100
+ "autoincrement": false,
101
+ "default": "CURRENT_TIMESTAMP"
102
+ }
103
+ },
104
+ "indexes": {},
105
+ "foreignKeys": {
106
+ "agent_project_fk": {
107
+ "name": "agent_project_fk",
108
+ "tableFrom": "agent",
109
+ "tableTo": "projects",
110
+ "columnsFrom": [
111
+ "tenant_id",
112
+ "project_id"
113
+ ],
114
+ "columnsTo": [
115
+ "tenant_id",
116
+ "id"
117
+ ],
118
+ "onDelete": "cascade",
119
+ "onUpdate": "no action"
120
+ }
121
+ },
122
+ "compositePrimaryKeys": {
123
+ "agent_tenant_id_project_id_id_pk": {
124
+ "columns": [
125
+ "tenant_id",
126
+ "project_id",
127
+ "id"
128
+ ],
129
+ "name": "agent_tenant_id_project_id_id_pk"
130
+ }
131
+ },
132
+ "uniqueConstraints": {},
133
+ "checkConstraints": {}
134
+ },
135
+ "api_keys": {
136
+ "name": "api_keys",
137
+ "columns": {
138
+ "tenant_id": {
139
+ "name": "tenant_id",
140
+ "type": "text",
141
+ "primaryKey": false,
142
+ "notNull": true,
143
+ "autoincrement": false
144
+ },
145
+ "id": {
146
+ "name": "id",
147
+ "type": "text",
148
+ "primaryKey": false,
149
+ "notNull": true,
150
+ "autoincrement": false
151
+ },
152
+ "project_id": {
153
+ "name": "project_id",
154
+ "type": "text",
155
+ "primaryKey": false,
156
+ "notNull": true,
157
+ "autoincrement": false
158
+ },
159
+ "agent_id": {
160
+ "name": "agent_id",
161
+ "type": "text",
162
+ "primaryKey": false,
163
+ "notNull": true,
164
+ "autoincrement": false
165
+ },
166
+ "public_id": {
167
+ "name": "public_id",
168
+ "type": "text",
169
+ "primaryKey": false,
170
+ "notNull": true,
171
+ "autoincrement": false
172
+ },
173
+ "key_hash": {
174
+ "name": "key_hash",
175
+ "type": "text",
176
+ "primaryKey": false,
177
+ "notNull": true,
178
+ "autoincrement": false
179
+ },
180
+ "key_prefix": {
181
+ "name": "key_prefix",
182
+ "type": "text",
183
+ "primaryKey": false,
184
+ "notNull": true,
185
+ "autoincrement": false
186
+ },
187
+ "name": {
188
+ "name": "name",
189
+ "type": "text",
190
+ "primaryKey": false,
191
+ "notNull": false,
192
+ "autoincrement": false
193
+ },
194
+ "last_used_at": {
195
+ "name": "last_used_at",
196
+ "type": "text",
197
+ "primaryKey": false,
198
+ "notNull": false,
199
+ "autoincrement": false
200
+ },
201
+ "expires_at": {
202
+ "name": "expires_at",
203
+ "type": "text",
204
+ "primaryKey": false,
205
+ "notNull": false,
206
+ "autoincrement": false
207
+ },
208
+ "created_at": {
209
+ "name": "created_at",
210
+ "type": "text",
211
+ "primaryKey": false,
212
+ "notNull": true,
213
+ "autoincrement": false,
214
+ "default": "CURRENT_TIMESTAMP"
215
+ },
216
+ "updated_at": {
217
+ "name": "updated_at",
218
+ "type": "text",
219
+ "primaryKey": false,
220
+ "notNull": true,
221
+ "autoincrement": false,
222
+ "default": "CURRENT_TIMESTAMP"
223
+ }
224
+ },
225
+ "indexes": {
226
+ "api_keys_public_id_unique": {
227
+ "name": "api_keys_public_id_unique",
228
+ "columns": [
229
+ "public_id"
230
+ ],
231
+ "isUnique": true
232
+ },
233
+ "api_keys_tenant_agent_idx": {
234
+ "name": "api_keys_tenant_agent_idx",
235
+ "columns": [
236
+ "tenant_id",
237
+ "agent_id"
238
+ ],
239
+ "isUnique": false
240
+ },
241
+ "api_keys_prefix_idx": {
242
+ "name": "api_keys_prefix_idx",
243
+ "columns": [
244
+ "key_prefix"
245
+ ],
246
+ "isUnique": false
247
+ },
248
+ "api_keys_public_id_idx": {
249
+ "name": "api_keys_public_id_idx",
250
+ "columns": [
251
+ "public_id"
252
+ ],
253
+ "isUnique": false
254
+ }
255
+ },
256
+ "foreignKeys": {
257
+ "api_keys_project_fk": {
258
+ "name": "api_keys_project_fk",
259
+ "tableFrom": "api_keys",
260
+ "tableTo": "projects",
261
+ "columnsFrom": [
262
+ "tenant_id",
263
+ "project_id"
264
+ ],
265
+ "columnsTo": [
266
+ "tenant_id",
267
+ "id"
268
+ ],
269
+ "onDelete": "cascade",
270
+ "onUpdate": "no action"
271
+ },
272
+ "api_keys_agent_fk": {
273
+ "name": "api_keys_agent_fk",
274
+ "tableFrom": "api_keys",
275
+ "tableTo": "agent",
276
+ "columnsFrom": [
277
+ "tenant_id",
278
+ "project_id",
279
+ "agent_id"
280
+ ],
281
+ "columnsTo": [
282
+ "tenant_id",
283
+ "project_id",
284
+ "id"
285
+ ],
286
+ "onDelete": "cascade",
287
+ "onUpdate": "no action"
288
+ }
289
+ },
290
+ "compositePrimaryKeys": {},
291
+ "uniqueConstraints": {},
292
+ "checkConstraints": {}
293
+ },
294
+ "artifact_components": {
295
+ "name": "artifact_components",
296
+ "columns": {
297
+ "tenant_id": {
298
+ "name": "tenant_id",
299
+ "type": "text",
300
+ "primaryKey": false,
301
+ "notNull": true,
302
+ "autoincrement": false
303
+ },
304
+ "id": {
305
+ "name": "id",
306
+ "type": "text",
307
+ "primaryKey": false,
308
+ "notNull": true,
309
+ "autoincrement": false
310
+ },
311
+ "project_id": {
312
+ "name": "project_id",
313
+ "type": "text",
314
+ "primaryKey": false,
315
+ "notNull": true,
316
+ "autoincrement": false
317
+ },
318
+ "name": {
319
+ "name": "name",
320
+ "type": "text",
321
+ "primaryKey": false,
322
+ "notNull": true,
323
+ "autoincrement": false
324
+ },
325
+ "description": {
326
+ "name": "description",
327
+ "type": "text",
328
+ "primaryKey": false,
329
+ "notNull": true,
330
+ "autoincrement": false
331
+ },
332
+ "props": {
333
+ "name": "props",
334
+ "type": "blob",
335
+ "primaryKey": false,
336
+ "notNull": false,
337
+ "autoincrement": false
338
+ },
339
+ "created_at": {
340
+ "name": "created_at",
341
+ "type": "text",
342
+ "primaryKey": false,
343
+ "notNull": true,
344
+ "autoincrement": false,
345
+ "default": "CURRENT_TIMESTAMP"
346
+ },
347
+ "updated_at": {
348
+ "name": "updated_at",
349
+ "type": "text",
350
+ "primaryKey": false,
351
+ "notNull": true,
352
+ "autoincrement": false,
353
+ "default": "CURRENT_TIMESTAMP"
354
+ }
355
+ },
356
+ "indexes": {},
357
+ "foreignKeys": {
358
+ "artifact_components_project_fk": {
359
+ "name": "artifact_components_project_fk",
360
+ "tableFrom": "artifact_components",
361
+ "tableTo": "projects",
362
+ "columnsFrom": [
363
+ "tenant_id",
364
+ "project_id"
365
+ ],
366
+ "columnsTo": [
367
+ "tenant_id",
368
+ "id"
369
+ ],
370
+ "onDelete": "cascade",
371
+ "onUpdate": "no action"
372
+ }
373
+ },
374
+ "compositePrimaryKeys": {
375
+ "artifact_components_tenant_id_project_id_id_pk": {
376
+ "columns": [
377
+ "tenant_id",
378
+ "project_id",
379
+ "id"
380
+ ],
381
+ "name": "artifact_components_tenant_id_project_id_id_pk"
382
+ }
383
+ },
384
+ "uniqueConstraints": {},
385
+ "checkConstraints": {}
386
+ },
387
+ "context_cache": {
388
+ "name": "context_cache",
389
+ "columns": {
390
+ "tenant_id": {
391
+ "name": "tenant_id",
392
+ "type": "text",
393
+ "primaryKey": false,
394
+ "notNull": true,
395
+ "autoincrement": false
396
+ },
397
+ "id": {
398
+ "name": "id",
399
+ "type": "text",
400
+ "primaryKey": false,
401
+ "notNull": true,
402
+ "autoincrement": false
403
+ },
404
+ "project_id": {
405
+ "name": "project_id",
406
+ "type": "text",
407
+ "primaryKey": false,
408
+ "notNull": true,
409
+ "autoincrement": false
410
+ },
411
+ "conversation_id": {
412
+ "name": "conversation_id",
413
+ "type": "text",
414
+ "primaryKey": false,
415
+ "notNull": true,
416
+ "autoincrement": false
417
+ },
418
+ "context_config_id": {
419
+ "name": "context_config_id",
420
+ "type": "text",
421
+ "primaryKey": false,
422
+ "notNull": true,
423
+ "autoincrement": false
424
+ },
425
+ "context_variable_key": {
426
+ "name": "context_variable_key",
427
+ "type": "text",
428
+ "primaryKey": false,
429
+ "notNull": true,
430
+ "autoincrement": false
431
+ },
432
+ "value": {
433
+ "name": "value",
434
+ "type": "blob",
435
+ "primaryKey": false,
436
+ "notNull": true,
437
+ "autoincrement": false
438
+ },
439
+ "request_hash": {
440
+ "name": "request_hash",
441
+ "type": "text",
442
+ "primaryKey": false,
443
+ "notNull": false,
444
+ "autoincrement": false
445
+ },
446
+ "fetched_at": {
447
+ "name": "fetched_at",
448
+ "type": "text",
449
+ "primaryKey": false,
450
+ "notNull": true,
451
+ "autoincrement": false
452
+ },
453
+ "fetch_source": {
454
+ "name": "fetch_source",
455
+ "type": "text",
456
+ "primaryKey": false,
457
+ "notNull": false,
458
+ "autoincrement": false
459
+ },
460
+ "fetch_duration_ms": {
461
+ "name": "fetch_duration_ms",
462
+ "type": "integer",
463
+ "primaryKey": false,
464
+ "notNull": false,
465
+ "autoincrement": false
466
+ },
467
+ "created_at": {
468
+ "name": "created_at",
469
+ "type": "text",
470
+ "primaryKey": false,
471
+ "notNull": true,
472
+ "autoincrement": false,
473
+ "default": "CURRENT_TIMESTAMP"
474
+ },
475
+ "updated_at": {
476
+ "name": "updated_at",
477
+ "type": "text",
478
+ "primaryKey": false,
479
+ "notNull": true,
480
+ "autoincrement": false,
481
+ "default": "CURRENT_TIMESTAMP"
482
+ }
483
+ },
484
+ "indexes": {
485
+ "context_cache_lookup_idx": {
486
+ "name": "context_cache_lookup_idx",
487
+ "columns": [
488
+ "conversation_id",
489
+ "context_config_id",
490
+ "context_variable_key"
491
+ ],
492
+ "isUnique": false
493
+ }
494
+ },
495
+ "foreignKeys": {
496
+ "context_cache_project_fk": {
497
+ "name": "context_cache_project_fk",
498
+ "tableFrom": "context_cache",
499
+ "tableTo": "projects",
500
+ "columnsFrom": [
501
+ "tenant_id",
502
+ "project_id"
503
+ ],
504
+ "columnsTo": [
505
+ "tenant_id",
506
+ "id"
507
+ ],
508
+ "onDelete": "cascade",
509
+ "onUpdate": "no action"
510
+ }
511
+ },
512
+ "compositePrimaryKeys": {
513
+ "context_cache_tenant_id_project_id_id_pk": {
514
+ "columns": [
515
+ "tenant_id",
516
+ "project_id",
517
+ "id"
518
+ ],
519
+ "name": "context_cache_tenant_id_project_id_id_pk"
520
+ }
521
+ },
522
+ "uniqueConstraints": {},
523
+ "checkConstraints": {}
524
+ },
525
+ "context_configs": {
526
+ "name": "context_configs",
527
+ "columns": {
528
+ "tenant_id": {
529
+ "name": "tenant_id",
530
+ "type": "text",
531
+ "primaryKey": false,
532
+ "notNull": true,
533
+ "autoincrement": false
534
+ },
535
+ "id": {
536
+ "name": "id",
537
+ "type": "text",
538
+ "primaryKey": false,
539
+ "notNull": true,
540
+ "autoincrement": false
541
+ },
542
+ "project_id": {
543
+ "name": "project_id",
544
+ "type": "text",
545
+ "primaryKey": false,
546
+ "notNull": true,
547
+ "autoincrement": false
548
+ },
549
+ "agent_id": {
550
+ "name": "agent_id",
551
+ "type": "text",
552
+ "primaryKey": false,
553
+ "notNull": true,
554
+ "autoincrement": false
555
+ },
556
+ "headers_schema": {
557
+ "name": "headers_schema",
558
+ "type": "blob",
559
+ "primaryKey": false,
560
+ "notNull": false,
561
+ "autoincrement": false
562
+ },
563
+ "context_variables": {
564
+ "name": "context_variables",
565
+ "type": "blob",
566
+ "primaryKey": false,
567
+ "notNull": false,
568
+ "autoincrement": false
569
+ },
570
+ "created_at": {
571
+ "name": "created_at",
572
+ "type": "text",
573
+ "primaryKey": false,
574
+ "notNull": true,
575
+ "autoincrement": false,
576
+ "default": "CURRENT_TIMESTAMP"
577
+ },
578
+ "updated_at": {
579
+ "name": "updated_at",
580
+ "type": "text",
581
+ "primaryKey": false,
582
+ "notNull": true,
583
+ "autoincrement": false,
584
+ "default": "CURRENT_TIMESTAMP"
585
+ }
586
+ },
587
+ "indexes": {},
588
+ "foreignKeys": {
589
+ "context_configs_agent_fk": {
590
+ "name": "context_configs_agent_fk",
591
+ "tableFrom": "context_configs",
592
+ "tableTo": "agent",
593
+ "columnsFrom": [
594
+ "tenant_id",
595
+ "project_id",
596
+ "agent_id"
597
+ ],
598
+ "columnsTo": [
599
+ "tenant_id",
600
+ "project_id",
601
+ "id"
602
+ ],
603
+ "onDelete": "cascade",
604
+ "onUpdate": "no action"
605
+ }
606
+ },
607
+ "compositePrimaryKeys": {
608
+ "context_configs_tenant_id_project_id_agent_id_id_pk": {
609
+ "columns": [
610
+ "tenant_id",
611
+ "project_id",
612
+ "agent_id",
613
+ "id"
614
+ ],
615
+ "name": "context_configs_tenant_id_project_id_agent_id_id_pk"
616
+ }
617
+ },
618
+ "uniqueConstraints": {},
619
+ "checkConstraints": {}
620
+ },
621
+ "conversations": {
622
+ "name": "conversations",
623
+ "columns": {
624
+ "tenant_id": {
625
+ "name": "tenant_id",
626
+ "type": "text",
627
+ "primaryKey": false,
628
+ "notNull": true,
629
+ "autoincrement": false
630
+ },
631
+ "id": {
632
+ "name": "id",
633
+ "type": "text",
634
+ "primaryKey": false,
635
+ "notNull": true,
636
+ "autoincrement": false
637
+ },
638
+ "project_id": {
639
+ "name": "project_id",
640
+ "type": "text",
641
+ "primaryKey": false,
642
+ "notNull": true,
643
+ "autoincrement": false
644
+ },
645
+ "user_id": {
646
+ "name": "user_id",
647
+ "type": "text",
648
+ "primaryKey": false,
649
+ "notNull": false,
650
+ "autoincrement": false
651
+ },
652
+ "active_sub_agent_id": {
653
+ "name": "active_sub_agent_id",
654
+ "type": "text",
655
+ "primaryKey": false,
656
+ "notNull": true,
657
+ "autoincrement": false
658
+ },
659
+ "title": {
660
+ "name": "title",
661
+ "type": "text",
662
+ "primaryKey": false,
663
+ "notNull": false,
664
+ "autoincrement": false
665
+ },
666
+ "last_context_resolution": {
667
+ "name": "last_context_resolution",
668
+ "type": "text",
669
+ "primaryKey": false,
670
+ "notNull": false,
671
+ "autoincrement": false
672
+ },
673
+ "metadata": {
674
+ "name": "metadata",
675
+ "type": "blob",
676
+ "primaryKey": false,
677
+ "notNull": false,
678
+ "autoincrement": false
679
+ },
680
+ "created_at": {
681
+ "name": "created_at",
682
+ "type": "text",
683
+ "primaryKey": false,
684
+ "notNull": true,
685
+ "autoincrement": false,
686
+ "default": "CURRENT_TIMESTAMP"
687
+ },
688
+ "updated_at": {
689
+ "name": "updated_at",
690
+ "type": "text",
691
+ "primaryKey": false,
692
+ "notNull": true,
693
+ "autoincrement": false,
694
+ "default": "CURRENT_TIMESTAMP"
695
+ }
696
+ },
697
+ "indexes": {},
698
+ "foreignKeys": {
699
+ "conversations_project_fk": {
700
+ "name": "conversations_project_fk",
701
+ "tableFrom": "conversations",
702
+ "tableTo": "projects",
703
+ "columnsFrom": [
704
+ "tenant_id",
705
+ "project_id"
706
+ ],
707
+ "columnsTo": [
708
+ "tenant_id",
709
+ "id"
710
+ ],
711
+ "onDelete": "cascade",
712
+ "onUpdate": "no action"
713
+ }
714
+ },
715
+ "compositePrimaryKeys": {
716
+ "conversations_tenant_id_project_id_id_pk": {
717
+ "columns": [
718
+ "tenant_id",
719
+ "project_id",
720
+ "id"
721
+ ],
722
+ "name": "conversations_tenant_id_project_id_id_pk"
723
+ }
724
+ },
725
+ "uniqueConstraints": {},
726
+ "checkConstraints": {}
727
+ },
728
+ "credential_references": {
729
+ "name": "credential_references",
730
+ "columns": {
731
+ "tenant_id": {
732
+ "name": "tenant_id",
733
+ "type": "text",
734
+ "primaryKey": false,
735
+ "notNull": true,
736
+ "autoincrement": false
737
+ },
738
+ "id": {
739
+ "name": "id",
740
+ "type": "text",
741
+ "primaryKey": false,
742
+ "notNull": true,
743
+ "autoincrement": false
744
+ },
745
+ "project_id": {
746
+ "name": "project_id",
747
+ "type": "text",
748
+ "primaryKey": false,
749
+ "notNull": true,
750
+ "autoincrement": false
751
+ },
752
+ "type": {
753
+ "name": "type",
754
+ "type": "text",
755
+ "primaryKey": false,
756
+ "notNull": true,
757
+ "autoincrement": false
758
+ },
759
+ "credential_store_id": {
760
+ "name": "credential_store_id",
761
+ "type": "text",
762
+ "primaryKey": false,
763
+ "notNull": true,
764
+ "autoincrement": false
765
+ },
766
+ "retrieval_params": {
767
+ "name": "retrieval_params",
768
+ "type": "blob",
769
+ "primaryKey": false,
770
+ "notNull": false,
771
+ "autoincrement": false
772
+ },
773
+ "created_at": {
774
+ "name": "created_at",
775
+ "type": "text",
776
+ "primaryKey": false,
777
+ "notNull": true,
778
+ "autoincrement": false,
779
+ "default": "CURRENT_TIMESTAMP"
780
+ },
781
+ "updated_at": {
782
+ "name": "updated_at",
783
+ "type": "text",
784
+ "primaryKey": false,
785
+ "notNull": true,
786
+ "autoincrement": false,
787
+ "default": "CURRENT_TIMESTAMP"
788
+ }
789
+ },
790
+ "indexes": {},
791
+ "foreignKeys": {
792
+ "credential_references_project_fk": {
793
+ "name": "credential_references_project_fk",
794
+ "tableFrom": "credential_references",
795
+ "tableTo": "projects",
796
+ "columnsFrom": [
797
+ "tenant_id",
798
+ "project_id"
799
+ ],
800
+ "columnsTo": [
801
+ "tenant_id",
802
+ "id"
803
+ ],
804
+ "onDelete": "cascade",
805
+ "onUpdate": "no action"
806
+ }
807
+ },
808
+ "compositePrimaryKeys": {
809
+ "credential_references_tenant_id_project_id_id_pk": {
810
+ "columns": [
811
+ "tenant_id",
812
+ "project_id",
813
+ "id"
814
+ ],
815
+ "name": "credential_references_tenant_id_project_id_id_pk"
816
+ }
817
+ },
818
+ "uniqueConstraints": {},
819
+ "checkConstraints": {}
820
+ },
821
+ "data_components": {
822
+ "name": "data_components",
823
+ "columns": {
824
+ "tenant_id": {
825
+ "name": "tenant_id",
826
+ "type": "text",
827
+ "primaryKey": false,
828
+ "notNull": true,
829
+ "autoincrement": false
830
+ },
831
+ "id": {
832
+ "name": "id",
833
+ "type": "text",
834
+ "primaryKey": false,
835
+ "notNull": true,
836
+ "autoincrement": false
837
+ },
838
+ "project_id": {
839
+ "name": "project_id",
840
+ "type": "text",
841
+ "primaryKey": false,
842
+ "notNull": true,
843
+ "autoincrement": false
844
+ },
845
+ "name": {
846
+ "name": "name",
847
+ "type": "text",
848
+ "primaryKey": false,
849
+ "notNull": true,
850
+ "autoincrement": false
851
+ },
852
+ "description": {
853
+ "name": "description",
854
+ "type": "text",
855
+ "primaryKey": false,
856
+ "notNull": true,
857
+ "autoincrement": false
858
+ },
859
+ "props": {
860
+ "name": "props",
861
+ "type": "blob",
862
+ "primaryKey": false,
863
+ "notNull": false,
864
+ "autoincrement": false
865
+ },
866
+ "render": {
867
+ "name": "render",
868
+ "type": "blob",
869
+ "primaryKey": false,
870
+ "notNull": false,
871
+ "autoincrement": false,
872
+ "default": "'null'"
873
+ },
874
+ "created_at": {
875
+ "name": "created_at",
876
+ "type": "text",
877
+ "primaryKey": false,
878
+ "notNull": true,
879
+ "autoincrement": false,
880
+ "default": "CURRENT_TIMESTAMP"
881
+ },
882
+ "updated_at": {
883
+ "name": "updated_at",
884
+ "type": "text",
885
+ "primaryKey": false,
886
+ "notNull": true,
887
+ "autoincrement": false,
888
+ "default": "CURRENT_TIMESTAMP"
889
+ }
890
+ },
891
+ "indexes": {},
892
+ "foreignKeys": {
893
+ "data_components_project_fk": {
894
+ "name": "data_components_project_fk",
895
+ "tableFrom": "data_components",
896
+ "tableTo": "projects",
897
+ "columnsFrom": [
898
+ "tenant_id",
899
+ "project_id"
900
+ ],
901
+ "columnsTo": [
902
+ "tenant_id",
903
+ "id"
904
+ ],
905
+ "onDelete": "cascade",
906
+ "onUpdate": "no action"
907
+ }
908
+ },
909
+ "compositePrimaryKeys": {
910
+ "data_components_tenant_id_project_id_id_pk": {
911
+ "columns": [
912
+ "tenant_id",
913
+ "project_id",
914
+ "id"
915
+ ],
916
+ "name": "data_components_tenant_id_project_id_id_pk"
917
+ }
918
+ },
919
+ "uniqueConstraints": {},
920
+ "checkConstraints": {}
921
+ },
922
+ "external_agents": {
923
+ "name": "external_agents",
924
+ "columns": {
925
+ "tenant_id": {
926
+ "name": "tenant_id",
927
+ "type": "text",
928
+ "primaryKey": false,
929
+ "notNull": true,
930
+ "autoincrement": false
931
+ },
932
+ "id": {
933
+ "name": "id",
934
+ "type": "text",
935
+ "primaryKey": false,
936
+ "notNull": true,
937
+ "autoincrement": false
938
+ },
939
+ "project_id": {
940
+ "name": "project_id",
941
+ "type": "text",
942
+ "primaryKey": false,
943
+ "notNull": true,
944
+ "autoincrement": false
945
+ },
946
+ "name": {
947
+ "name": "name",
948
+ "type": "text",
949
+ "primaryKey": false,
950
+ "notNull": true,
951
+ "autoincrement": false
952
+ },
953
+ "description": {
954
+ "name": "description",
955
+ "type": "text",
956
+ "primaryKey": false,
957
+ "notNull": true,
958
+ "autoincrement": false
959
+ },
960
+ "base_url": {
961
+ "name": "base_url",
962
+ "type": "text",
963
+ "primaryKey": false,
964
+ "notNull": true,
965
+ "autoincrement": false
966
+ },
967
+ "credential_reference_id": {
968
+ "name": "credential_reference_id",
969
+ "type": "text",
970
+ "primaryKey": false,
971
+ "notNull": false,
972
+ "autoincrement": false
973
+ },
974
+ "created_at": {
975
+ "name": "created_at",
976
+ "type": "text",
977
+ "primaryKey": false,
978
+ "notNull": true,
979
+ "autoincrement": false,
980
+ "default": "CURRENT_TIMESTAMP"
981
+ },
982
+ "updated_at": {
983
+ "name": "updated_at",
984
+ "type": "text",
985
+ "primaryKey": false,
986
+ "notNull": true,
987
+ "autoincrement": false,
988
+ "default": "CURRENT_TIMESTAMP"
989
+ }
990
+ },
991
+ "indexes": {},
992
+ "foreignKeys": {
993
+ "external_agents_project_fk": {
994
+ "name": "external_agents_project_fk",
995
+ "tableFrom": "external_agents",
996
+ "tableTo": "projects",
997
+ "columnsFrom": [
998
+ "tenant_id",
999
+ "project_id"
1000
+ ],
1001
+ "columnsTo": [
1002
+ "tenant_id",
1003
+ "id"
1004
+ ],
1005
+ "onDelete": "cascade",
1006
+ "onUpdate": "no action"
1007
+ },
1008
+ "external_agents_credential_reference_fk": {
1009
+ "name": "external_agents_credential_reference_fk",
1010
+ "tableFrom": "external_agents",
1011
+ "tableTo": "credential_references",
1012
+ "columnsFrom": [
1013
+ "tenant_id",
1014
+ "project_id",
1015
+ "credential_reference_id"
1016
+ ],
1017
+ "columnsTo": [
1018
+ "tenant_id",
1019
+ "project_id",
1020
+ "id"
1021
+ ],
1022
+ "onDelete": "set null",
1023
+ "onUpdate": "no action"
1024
+ }
1025
+ },
1026
+ "compositePrimaryKeys": {
1027
+ "external_agents_tenant_id_project_id_id_pk": {
1028
+ "columns": [
1029
+ "tenant_id",
1030
+ "project_id",
1031
+ "id"
1032
+ ],
1033
+ "name": "external_agents_tenant_id_project_id_id_pk"
1034
+ }
1035
+ },
1036
+ "uniqueConstraints": {},
1037
+ "checkConstraints": {}
1038
+ },
1039
+ "function_tools": {
1040
+ "name": "function_tools",
1041
+ "columns": {
1042
+ "tenant_id": {
1043
+ "name": "tenant_id",
1044
+ "type": "text",
1045
+ "primaryKey": false,
1046
+ "notNull": true,
1047
+ "autoincrement": false
1048
+ },
1049
+ "id": {
1050
+ "name": "id",
1051
+ "type": "text",
1052
+ "primaryKey": false,
1053
+ "notNull": true,
1054
+ "autoincrement": false
1055
+ },
1056
+ "project_id": {
1057
+ "name": "project_id",
1058
+ "type": "text",
1059
+ "primaryKey": false,
1060
+ "notNull": true,
1061
+ "autoincrement": false
1062
+ },
1063
+ "agent_id": {
1064
+ "name": "agent_id",
1065
+ "type": "text",
1066
+ "primaryKey": false,
1067
+ "notNull": true,
1068
+ "autoincrement": false
1069
+ },
1070
+ "name": {
1071
+ "name": "name",
1072
+ "type": "text",
1073
+ "primaryKey": false,
1074
+ "notNull": true,
1075
+ "autoincrement": false
1076
+ },
1077
+ "description": {
1078
+ "name": "description",
1079
+ "type": "text",
1080
+ "primaryKey": false,
1081
+ "notNull": false,
1082
+ "autoincrement": false
1083
+ },
1084
+ "function_id": {
1085
+ "name": "function_id",
1086
+ "type": "text",
1087
+ "primaryKey": false,
1088
+ "notNull": true,
1089
+ "autoincrement": false
1090
+ },
1091
+ "created_at": {
1092
+ "name": "created_at",
1093
+ "type": "text",
1094
+ "primaryKey": false,
1095
+ "notNull": true,
1096
+ "autoincrement": false,
1097
+ "default": "CURRENT_TIMESTAMP"
1098
+ },
1099
+ "updated_at": {
1100
+ "name": "updated_at",
1101
+ "type": "text",
1102
+ "primaryKey": false,
1103
+ "notNull": true,
1104
+ "autoincrement": false,
1105
+ "default": "CURRENT_TIMESTAMP"
1106
+ }
1107
+ },
1108
+ "indexes": {},
1109
+ "foreignKeys": {
1110
+ "function_tools_agent_fk": {
1111
+ "name": "function_tools_agent_fk",
1112
+ "tableFrom": "function_tools",
1113
+ "tableTo": "agent",
1114
+ "columnsFrom": [
1115
+ "tenant_id",
1116
+ "project_id",
1117
+ "agent_id"
1118
+ ],
1119
+ "columnsTo": [
1120
+ "tenant_id",
1121
+ "project_id",
1122
+ "id"
1123
+ ],
1124
+ "onDelete": "cascade",
1125
+ "onUpdate": "no action"
1126
+ },
1127
+ "function_tools_function_fk": {
1128
+ "name": "function_tools_function_fk",
1129
+ "tableFrom": "function_tools",
1130
+ "tableTo": "functions",
1131
+ "columnsFrom": [
1132
+ "tenant_id",
1133
+ "project_id",
1134
+ "function_id"
1135
+ ],
1136
+ "columnsTo": [
1137
+ "tenant_id",
1138
+ "project_id",
1139
+ "id"
1140
+ ],
1141
+ "onDelete": "cascade",
1142
+ "onUpdate": "no action"
1143
+ }
1144
+ },
1145
+ "compositePrimaryKeys": {
1146
+ "function_tools_tenant_id_project_id_agent_id_id_pk": {
1147
+ "columns": [
1148
+ "tenant_id",
1149
+ "project_id",
1150
+ "agent_id",
1151
+ "id"
1152
+ ],
1153
+ "name": "function_tools_tenant_id_project_id_agent_id_id_pk"
1154
+ }
1155
+ },
1156
+ "uniqueConstraints": {},
1157
+ "checkConstraints": {}
1158
+ },
1159
+ "functions": {
1160
+ "name": "functions",
1161
+ "columns": {
1162
+ "tenant_id": {
1163
+ "name": "tenant_id",
1164
+ "type": "text",
1165
+ "primaryKey": false,
1166
+ "notNull": true,
1167
+ "autoincrement": false
1168
+ },
1169
+ "id": {
1170
+ "name": "id",
1171
+ "type": "text",
1172
+ "primaryKey": false,
1173
+ "notNull": true,
1174
+ "autoincrement": false
1175
+ },
1176
+ "project_id": {
1177
+ "name": "project_id",
1178
+ "type": "text",
1179
+ "primaryKey": false,
1180
+ "notNull": true,
1181
+ "autoincrement": false
1182
+ },
1183
+ "input_schema": {
1184
+ "name": "input_schema",
1185
+ "type": "blob",
1186
+ "primaryKey": false,
1187
+ "notNull": false,
1188
+ "autoincrement": false
1189
+ },
1190
+ "execute_code": {
1191
+ "name": "execute_code",
1192
+ "type": "text",
1193
+ "primaryKey": false,
1194
+ "notNull": true,
1195
+ "autoincrement": false
1196
+ },
1197
+ "dependencies": {
1198
+ "name": "dependencies",
1199
+ "type": "blob",
1200
+ "primaryKey": false,
1201
+ "notNull": false,
1202
+ "autoincrement": false
1203
+ },
1204
+ "created_at": {
1205
+ "name": "created_at",
1206
+ "type": "text",
1207
+ "primaryKey": false,
1208
+ "notNull": true,
1209
+ "autoincrement": false,
1210
+ "default": "CURRENT_TIMESTAMP"
1211
+ },
1212
+ "updated_at": {
1213
+ "name": "updated_at",
1214
+ "type": "text",
1215
+ "primaryKey": false,
1216
+ "notNull": true,
1217
+ "autoincrement": false,
1218
+ "default": "CURRENT_TIMESTAMP"
1219
+ }
1220
+ },
1221
+ "indexes": {},
1222
+ "foreignKeys": {
1223
+ "functions_project_fk": {
1224
+ "name": "functions_project_fk",
1225
+ "tableFrom": "functions",
1226
+ "tableTo": "projects",
1227
+ "columnsFrom": [
1228
+ "tenant_id",
1229
+ "project_id"
1230
+ ],
1231
+ "columnsTo": [
1232
+ "tenant_id",
1233
+ "id"
1234
+ ],
1235
+ "onDelete": "cascade",
1236
+ "onUpdate": "no action"
1237
+ }
1238
+ },
1239
+ "compositePrimaryKeys": {
1240
+ "functions_tenant_id_project_id_id_pk": {
1241
+ "columns": [
1242
+ "tenant_id",
1243
+ "project_id",
1244
+ "id"
1245
+ ],
1246
+ "name": "functions_tenant_id_project_id_id_pk"
1247
+ }
1248
+ },
1249
+ "uniqueConstraints": {},
1250
+ "checkConstraints": {}
1251
+ },
1252
+ "ledger_artifacts": {
1253
+ "name": "ledger_artifacts",
1254
+ "columns": {
1255
+ "tenant_id": {
1256
+ "name": "tenant_id",
1257
+ "type": "text",
1258
+ "primaryKey": false,
1259
+ "notNull": true,
1260
+ "autoincrement": false
1261
+ },
1262
+ "id": {
1263
+ "name": "id",
1264
+ "type": "text",
1265
+ "primaryKey": false,
1266
+ "notNull": true,
1267
+ "autoincrement": false
1268
+ },
1269
+ "project_id": {
1270
+ "name": "project_id",
1271
+ "type": "text",
1272
+ "primaryKey": false,
1273
+ "notNull": true,
1274
+ "autoincrement": false
1275
+ },
1276
+ "task_id": {
1277
+ "name": "task_id",
1278
+ "type": "text",
1279
+ "primaryKey": false,
1280
+ "notNull": true,
1281
+ "autoincrement": false
1282
+ },
1283
+ "tool_call_id": {
1284
+ "name": "tool_call_id",
1285
+ "type": "text",
1286
+ "primaryKey": false,
1287
+ "notNull": false,
1288
+ "autoincrement": false
1289
+ },
1290
+ "context_id": {
1291
+ "name": "context_id",
1292
+ "type": "text",
1293
+ "primaryKey": false,
1294
+ "notNull": true,
1295
+ "autoincrement": false
1296
+ },
1297
+ "type": {
1298
+ "name": "type",
1299
+ "type": "text",
1300
+ "primaryKey": false,
1301
+ "notNull": true,
1302
+ "autoincrement": false,
1303
+ "default": "'source'"
1304
+ },
1305
+ "name": {
1306
+ "name": "name",
1307
+ "type": "text",
1308
+ "primaryKey": false,
1309
+ "notNull": false,
1310
+ "autoincrement": false
1311
+ },
1312
+ "description": {
1313
+ "name": "description",
1314
+ "type": "text",
1315
+ "primaryKey": false,
1316
+ "notNull": false,
1317
+ "autoincrement": false
1318
+ },
1319
+ "parts": {
1320
+ "name": "parts",
1321
+ "type": "blob",
1322
+ "primaryKey": false,
1323
+ "notNull": false,
1324
+ "autoincrement": false
1325
+ },
1326
+ "metadata": {
1327
+ "name": "metadata",
1328
+ "type": "blob",
1329
+ "primaryKey": false,
1330
+ "notNull": false,
1331
+ "autoincrement": false
1332
+ },
1333
+ "summary": {
1334
+ "name": "summary",
1335
+ "type": "text",
1336
+ "primaryKey": false,
1337
+ "notNull": false,
1338
+ "autoincrement": false
1339
+ },
1340
+ "mime": {
1341
+ "name": "mime",
1342
+ "type": "blob",
1343
+ "primaryKey": false,
1344
+ "notNull": false,
1345
+ "autoincrement": false
1346
+ },
1347
+ "visibility": {
1348
+ "name": "visibility",
1349
+ "type": "text",
1350
+ "primaryKey": false,
1351
+ "notNull": false,
1352
+ "autoincrement": false,
1353
+ "default": "'context'"
1354
+ },
1355
+ "allowed_agents": {
1356
+ "name": "allowed_agents",
1357
+ "type": "blob",
1358
+ "primaryKey": false,
1359
+ "notNull": false,
1360
+ "autoincrement": false
1361
+ },
1362
+ "derived_from": {
1363
+ "name": "derived_from",
1364
+ "type": "text",
1365
+ "primaryKey": false,
1366
+ "notNull": false,
1367
+ "autoincrement": false
1368
+ },
1369
+ "created_at": {
1370
+ "name": "created_at",
1371
+ "type": "text",
1372
+ "primaryKey": false,
1373
+ "notNull": true,
1374
+ "autoincrement": false,
1375
+ "default": "CURRENT_TIMESTAMP"
1376
+ },
1377
+ "updated_at": {
1378
+ "name": "updated_at",
1379
+ "type": "text",
1380
+ "primaryKey": false,
1381
+ "notNull": true,
1382
+ "autoincrement": false,
1383
+ "default": "CURRENT_TIMESTAMP"
1384
+ }
1385
+ },
1386
+ "indexes": {
1387
+ "ledger_artifacts_task_id_idx": {
1388
+ "name": "ledger_artifacts_task_id_idx",
1389
+ "columns": [
1390
+ "task_id"
1391
+ ],
1392
+ "isUnique": false
1393
+ },
1394
+ "ledger_artifacts_tool_call_id_idx": {
1395
+ "name": "ledger_artifacts_tool_call_id_idx",
1396
+ "columns": [
1397
+ "tool_call_id"
1398
+ ],
1399
+ "isUnique": false
1400
+ },
1401
+ "ledger_artifacts_context_id_idx": {
1402
+ "name": "ledger_artifacts_context_id_idx",
1403
+ "columns": [
1404
+ "context_id"
1405
+ ],
1406
+ "isUnique": false
1407
+ },
1408
+ "ledger_artifacts_task_context_name_unique": {
1409
+ "name": "ledger_artifacts_task_context_name_unique",
1410
+ "columns": [
1411
+ "task_id",
1412
+ "context_id",
1413
+ "name"
1414
+ ],
1415
+ "isUnique": true
1416
+ }
1417
+ },
1418
+ "foreignKeys": {
1419
+ "ledger_artifacts_project_fk": {
1420
+ "name": "ledger_artifacts_project_fk",
1421
+ "tableFrom": "ledger_artifacts",
1422
+ "tableTo": "projects",
1423
+ "columnsFrom": [
1424
+ "tenant_id",
1425
+ "project_id"
1426
+ ],
1427
+ "columnsTo": [
1428
+ "tenant_id",
1429
+ "id"
1430
+ ],
1431
+ "onDelete": "cascade",
1432
+ "onUpdate": "no action"
1433
+ }
1434
+ },
1435
+ "compositePrimaryKeys": {
1436
+ "ledger_artifacts_tenant_id_project_id_id_task_id_pk": {
1437
+ "columns": [
1438
+ "tenant_id",
1439
+ "project_id",
1440
+ "id",
1441
+ "task_id"
1442
+ ],
1443
+ "name": "ledger_artifacts_tenant_id_project_id_id_task_id_pk"
1444
+ }
1445
+ },
1446
+ "uniqueConstraints": {},
1447
+ "checkConstraints": {}
1448
+ },
1449
+ "messages": {
1450
+ "name": "messages",
1451
+ "columns": {
1452
+ "tenant_id": {
1453
+ "name": "tenant_id",
1454
+ "type": "text",
1455
+ "primaryKey": false,
1456
+ "notNull": true,
1457
+ "autoincrement": false
1458
+ },
1459
+ "id": {
1460
+ "name": "id",
1461
+ "type": "text",
1462
+ "primaryKey": false,
1463
+ "notNull": true,
1464
+ "autoincrement": false
1465
+ },
1466
+ "project_id": {
1467
+ "name": "project_id",
1468
+ "type": "text",
1469
+ "primaryKey": false,
1470
+ "notNull": true,
1471
+ "autoincrement": false
1472
+ },
1473
+ "conversation_id": {
1474
+ "name": "conversation_id",
1475
+ "type": "text",
1476
+ "primaryKey": false,
1477
+ "notNull": true,
1478
+ "autoincrement": false
1479
+ },
1480
+ "role": {
1481
+ "name": "role",
1482
+ "type": "text",
1483
+ "primaryKey": false,
1484
+ "notNull": true,
1485
+ "autoincrement": false
1486
+ },
1487
+ "from_sub_agent_id": {
1488
+ "name": "from_sub_agent_id",
1489
+ "type": "text",
1490
+ "primaryKey": false,
1491
+ "notNull": false,
1492
+ "autoincrement": false
1493
+ },
1494
+ "to_sub_agent_id": {
1495
+ "name": "to_sub_agent_id",
1496
+ "type": "text",
1497
+ "primaryKey": false,
1498
+ "notNull": false,
1499
+ "autoincrement": false
1500
+ },
1501
+ "from_external_sub_agent_id": {
1502
+ "name": "from_external_sub_agent_id",
1503
+ "type": "text",
1504
+ "primaryKey": false,
1505
+ "notNull": false,
1506
+ "autoincrement": false
1507
+ },
1508
+ "to_external_sub_agent_id": {
1509
+ "name": "to_external_sub_agent_id",
1510
+ "type": "text",
1511
+ "primaryKey": false,
1512
+ "notNull": false,
1513
+ "autoincrement": false
1514
+ },
1515
+ "from_team_agent_id": {
1516
+ "name": "from_team_agent_id",
1517
+ "type": "text",
1518
+ "primaryKey": false,
1519
+ "notNull": false,
1520
+ "autoincrement": false
1521
+ },
1522
+ "to_team_agent_id": {
1523
+ "name": "to_team_agent_id",
1524
+ "type": "text",
1525
+ "primaryKey": false,
1526
+ "notNull": false,
1527
+ "autoincrement": false
1528
+ },
1529
+ "content": {
1530
+ "name": "content",
1531
+ "type": "blob",
1532
+ "primaryKey": false,
1533
+ "notNull": true,
1534
+ "autoincrement": false
1535
+ },
1536
+ "visibility": {
1537
+ "name": "visibility",
1538
+ "type": "text",
1539
+ "primaryKey": false,
1540
+ "notNull": true,
1541
+ "autoincrement": false,
1542
+ "default": "'user-facing'"
1543
+ },
1544
+ "message_type": {
1545
+ "name": "message_type",
1546
+ "type": "text",
1547
+ "primaryKey": false,
1548
+ "notNull": true,
1549
+ "autoincrement": false,
1550
+ "default": "'chat'"
1551
+ },
1552
+ "task_id": {
1553
+ "name": "task_id",
1554
+ "type": "text",
1555
+ "primaryKey": false,
1556
+ "notNull": false,
1557
+ "autoincrement": false
1558
+ },
1559
+ "parent_message_id": {
1560
+ "name": "parent_message_id",
1561
+ "type": "text",
1562
+ "primaryKey": false,
1563
+ "notNull": false,
1564
+ "autoincrement": false
1565
+ },
1566
+ "a2a_task_id": {
1567
+ "name": "a2a_task_id",
1568
+ "type": "text",
1569
+ "primaryKey": false,
1570
+ "notNull": false,
1571
+ "autoincrement": false
1572
+ },
1573
+ "a2a_session_id": {
1574
+ "name": "a2a_session_id",
1575
+ "type": "text",
1576
+ "primaryKey": false,
1577
+ "notNull": false,
1578
+ "autoincrement": false
1579
+ },
1580
+ "metadata": {
1581
+ "name": "metadata",
1582
+ "type": "blob",
1583
+ "primaryKey": false,
1584
+ "notNull": false,
1585
+ "autoincrement": false
1586
+ },
1587
+ "created_at": {
1588
+ "name": "created_at",
1589
+ "type": "text",
1590
+ "primaryKey": false,
1591
+ "notNull": true,
1592
+ "autoincrement": false,
1593
+ "default": "CURRENT_TIMESTAMP"
1594
+ },
1595
+ "updated_at": {
1596
+ "name": "updated_at",
1597
+ "type": "text",
1598
+ "primaryKey": false,
1599
+ "notNull": true,
1600
+ "autoincrement": false,
1601
+ "default": "CURRENT_TIMESTAMP"
1602
+ }
1603
+ },
1604
+ "indexes": {},
1605
+ "foreignKeys": {
1606
+ "messages_project_fk": {
1607
+ "name": "messages_project_fk",
1608
+ "tableFrom": "messages",
1609
+ "tableTo": "projects",
1610
+ "columnsFrom": [
1611
+ "tenant_id",
1612
+ "project_id"
1613
+ ],
1614
+ "columnsTo": [
1615
+ "tenant_id",
1616
+ "id"
1617
+ ],
1618
+ "onDelete": "cascade",
1619
+ "onUpdate": "no action"
1620
+ }
1621
+ },
1622
+ "compositePrimaryKeys": {
1623
+ "messages_tenant_id_project_id_id_pk": {
1624
+ "columns": [
1625
+ "tenant_id",
1626
+ "project_id",
1627
+ "id"
1628
+ ],
1629
+ "name": "messages_tenant_id_project_id_id_pk"
1630
+ }
1631
+ },
1632
+ "uniqueConstraints": {},
1633
+ "checkConstraints": {}
1634
+ },
1635
+ "projects": {
1636
+ "name": "projects",
1637
+ "columns": {
1638
+ "tenant_id": {
1639
+ "name": "tenant_id",
1640
+ "type": "text",
1641
+ "primaryKey": false,
1642
+ "notNull": true,
1643
+ "autoincrement": false
1644
+ },
1645
+ "id": {
1646
+ "name": "id",
1647
+ "type": "text",
1648
+ "primaryKey": false,
1649
+ "notNull": true,
1650
+ "autoincrement": false
1651
+ },
1652
+ "name": {
1653
+ "name": "name",
1654
+ "type": "text",
1655
+ "primaryKey": false,
1656
+ "notNull": true,
1657
+ "autoincrement": false
1658
+ },
1659
+ "description": {
1660
+ "name": "description",
1661
+ "type": "text",
1662
+ "primaryKey": false,
1663
+ "notNull": true,
1664
+ "autoincrement": false
1665
+ },
1666
+ "models": {
1667
+ "name": "models",
1668
+ "type": "text",
1669
+ "primaryKey": false,
1670
+ "notNull": false,
1671
+ "autoincrement": false
1672
+ },
1673
+ "stop_when": {
1674
+ "name": "stop_when",
1675
+ "type": "text",
1676
+ "primaryKey": false,
1677
+ "notNull": false,
1678
+ "autoincrement": false
1679
+ },
1680
+ "created_at": {
1681
+ "name": "created_at",
1682
+ "type": "text",
1683
+ "primaryKey": false,
1684
+ "notNull": true,
1685
+ "autoincrement": false,
1686
+ "default": "CURRENT_TIMESTAMP"
1687
+ },
1688
+ "updated_at": {
1689
+ "name": "updated_at",
1690
+ "type": "text",
1691
+ "primaryKey": false,
1692
+ "notNull": true,
1693
+ "autoincrement": false,
1694
+ "default": "CURRENT_TIMESTAMP"
1695
+ }
1696
+ },
1697
+ "indexes": {},
1698
+ "foreignKeys": {},
1699
+ "compositePrimaryKeys": {
1700
+ "projects_tenant_id_id_pk": {
1701
+ "columns": [
1702
+ "tenant_id",
1703
+ "id"
1704
+ ],
1705
+ "name": "projects_tenant_id_id_pk"
1706
+ }
1707
+ },
1708
+ "uniqueConstraints": {},
1709
+ "checkConstraints": {}
1710
+ },
1711
+ "sub_agent_artifact_components": {
1712
+ "name": "sub_agent_artifact_components",
1713
+ "columns": {
1714
+ "tenant_id": {
1715
+ "name": "tenant_id",
1716
+ "type": "text",
1717
+ "primaryKey": false,
1718
+ "notNull": true,
1719
+ "autoincrement": false
1720
+ },
1721
+ "id": {
1722
+ "name": "id",
1723
+ "type": "text",
1724
+ "primaryKey": false,
1725
+ "notNull": true,
1726
+ "autoincrement": false
1727
+ },
1728
+ "project_id": {
1729
+ "name": "project_id",
1730
+ "type": "text",
1731
+ "primaryKey": false,
1732
+ "notNull": true,
1733
+ "autoincrement": false
1734
+ },
1735
+ "agent_id": {
1736
+ "name": "agent_id",
1737
+ "type": "text",
1738
+ "primaryKey": false,
1739
+ "notNull": true,
1740
+ "autoincrement": false
1741
+ },
1742
+ "sub_agent_id": {
1743
+ "name": "sub_agent_id",
1744
+ "type": "text",
1745
+ "primaryKey": false,
1746
+ "notNull": true,
1747
+ "autoincrement": false
1748
+ },
1749
+ "artifact_component_id": {
1750
+ "name": "artifact_component_id",
1751
+ "type": "text",
1752
+ "primaryKey": false,
1753
+ "notNull": true,
1754
+ "autoincrement": false
1755
+ },
1756
+ "created_at": {
1757
+ "name": "created_at",
1758
+ "type": "text",
1759
+ "primaryKey": false,
1760
+ "notNull": true,
1761
+ "autoincrement": false,
1762
+ "default": "CURRENT_TIMESTAMP"
1763
+ }
1764
+ },
1765
+ "indexes": {},
1766
+ "foreignKeys": {
1767
+ "sub_agent_artifact_components_sub_agent_fk": {
1768
+ "name": "sub_agent_artifact_components_sub_agent_fk",
1769
+ "tableFrom": "sub_agent_artifact_components",
1770
+ "tableTo": "sub_agents",
1771
+ "columnsFrom": [
1772
+ "tenant_id",
1773
+ "project_id",
1774
+ "agent_id",
1775
+ "sub_agent_id"
1776
+ ],
1777
+ "columnsTo": [
1778
+ "tenant_id",
1779
+ "project_id",
1780
+ "agent_id",
1781
+ "id"
1782
+ ],
1783
+ "onDelete": "cascade",
1784
+ "onUpdate": "no action"
1785
+ },
1786
+ "sub_agent_artifact_components_artifact_component_fk": {
1787
+ "name": "sub_agent_artifact_components_artifact_component_fk",
1788
+ "tableFrom": "sub_agent_artifact_components",
1789
+ "tableTo": "artifact_components",
1790
+ "columnsFrom": [
1791
+ "tenant_id",
1792
+ "project_id",
1793
+ "artifact_component_id"
1794
+ ],
1795
+ "columnsTo": [
1796
+ "tenant_id",
1797
+ "project_id",
1798
+ "id"
1799
+ ],
1800
+ "onDelete": "cascade",
1801
+ "onUpdate": "no action"
1802
+ }
1803
+ },
1804
+ "compositePrimaryKeys": {
1805
+ "sub_agent_artifact_components_tenant_id_project_id_agent_id_sub_agent_id_id_pk": {
1806
+ "columns": [
1807
+ "tenant_id",
1808
+ "project_id",
1809
+ "agent_id",
1810
+ "sub_agent_id",
1811
+ "id"
1812
+ ],
1813
+ "name": "sub_agent_artifact_components_tenant_id_project_id_agent_id_sub_agent_id_id_pk"
1814
+ }
1815
+ },
1816
+ "uniqueConstraints": {},
1817
+ "checkConstraints": {}
1818
+ },
1819
+ "sub_agent_data_components": {
1820
+ "name": "sub_agent_data_components",
1821
+ "columns": {
1822
+ "tenant_id": {
1823
+ "name": "tenant_id",
1824
+ "type": "text",
1825
+ "primaryKey": false,
1826
+ "notNull": true,
1827
+ "autoincrement": false
1828
+ },
1829
+ "id": {
1830
+ "name": "id",
1831
+ "type": "text",
1832
+ "primaryKey": false,
1833
+ "notNull": true,
1834
+ "autoincrement": false
1835
+ },
1836
+ "project_id": {
1837
+ "name": "project_id",
1838
+ "type": "text",
1839
+ "primaryKey": false,
1840
+ "notNull": true,
1841
+ "autoincrement": false
1842
+ },
1843
+ "agent_id": {
1844
+ "name": "agent_id",
1845
+ "type": "text",
1846
+ "primaryKey": false,
1847
+ "notNull": true,
1848
+ "autoincrement": false
1849
+ },
1850
+ "sub_agent_id": {
1851
+ "name": "sub_agent_id",
1852
+ "type": "text",
1853
+ "primaryKey": false,
1854
+ "notNull": true,
1855
+ "autoincrement": false
1856
+ },
1857
+ "data_component_id": {
1858
+ "name": "data_component_id",
1859
+ "type": "text",
1860
+ "primaryKey": false,
1861
+ "notNull": true,
1862
+ "autoincrement": false
1863
+ },
1864
+ "created_at": {
1865
+ "name": "created_at",
1866
+ "type": "text",
1867
+ "primaryKey": false,
1868
+ "notNull": true,
1869
+ "autoincrement": false,
1870
+ "default": "CURRENT_TIMESTAMP"
1871
+ }
1872
+ },
1873
+ "indexes": {},
1874
+ "foreignKeys": {
1875
+ "sub_agent_data_components_sub_agent_fk": {
1876
+ "name": "sub_agent_data_components_sub_agent_fk",
1877
+ "tableFrom": "sub_agent_data_components",
1878
+ "tableTo": "sub_agents",
1879
+ "columnsFrom": [
1880
+ "tenant_id",
1881
+ "project_id",
1882
+ "agent_id",
1883
+ "sub_agent_id"
1884
+ ],
1885
+ "columnsTo": [
1886
+ "tenant_id",
1887
+ "project_id",
1888
+ "agent_id",
1889
+ "id"
1890
+ ],
1891
+ "onDelete": "cascade",
1892
+ "onUpdate": "no action"
1893
+ },
1894
+ "sub_agent_data_components_data_component_fk": {
1895
+ "name": "sub_agent_data_components_data_component_fk",
1896
+ "tableFrom": "sub_agent_data_components",
1897
+ "tableTo": "data_components",
1898
+ "columnsFrom": [
1899
+ "tenant_id",
1900
+ "project_id",
1901
+ "data_component_id"
1902
+ ],
1903
+ "columnsTo": [
1904
+ "tenant_id",
1905
+ "project_id",
1906
+ "id"
1907
+ ],
1908
+ "onDelete": "cascade",
1909
+ "onUpdate": "no action"
1910
+ }
1911
+ },
1912
+ "compositePrimaryKeys": {
1913
+ "sub_agent_data_components_tenant_id_project_id_id_pk": {
1914
+ "columns": [
1915
+ "tenant_id",
1916
+ "project_id",
1917
+ "id"
1918
+ ],
1919
+ "name": "sub_agent_data_components_tenant_id_project_id_id_pk"
1920
+ }
1921
+ },
1922
+ "uniqueConstraints": {},
1923
+ "checkConstraints": {}
1924
+ },
1925
+ "sub_agent_external_agent_relations": {
1926
+ "name": "sub_agent_external_agent_relations",
1927
+ "columns": {
1928
+ "tenant_id": {
1929
+ "name": "tenant_id",
1930
+ "type": "text",
1931
+ "primaryKey": false,
1932
+ "notNull": true,
1933
+ "autoincrement": false
1934
+ },
1935
+ "id": {
1936
+ "name": "id",
1937
+ "type": "text",
1938
+ "primaryKey": false,
1939
+ "notNull": true,
1940
+ "autoincrement": false
1941
+ },
1942
+ "project_id": {
1943
+ "name": "project_id",
1944
+ "type": "text",
1945
+ "primaryKey": false,
1946
+ "notNull": true,
1947
+ "autoincrement": false
1948
+ },
1949
+ "agent_id": {
1950
+ "name": "agent_id",
1951
+ "type": "text",
1952
+ "primaryKey": false,
1953
+ "notNull": true,
1954
+ "autoincrement": false
1955
+ },
1956
+ "sub_agent_id": {
1957
+ "name": "sub_agent_id",
1958
+ "type": "text",
1959
+ "primaryKey": false,
1960
+ "notNull": true,
1961
+ "autoincrement": false
1962
+ },
1963
+ "external_agent_id": {
1964
+ "name": "external_agent_id",
1965
+ "type": "text",
1966
+ "primaryKey": false,
1967
+ "notNull": true,
1968
+ "autoincrement": false
1969
+ },
1970
+ "headers": {
1971
+ "name": "headers",
1972
+ "type": "blob",
1973
+ "primaryKey": false,
1974
+ "notNull": false,
1975
+ "autoincrement": false
1976
+ },
1977
+ "created_at": {
1978
+ "name": "created_at",
1979
+ "type": "text",
1980
+ "primaryKey": false,
1981
+ "notNull": true,
1982
+ "autoincrement": false,
1983
+ "default": "CURRENT_TIMESTAMP"
1984
+ },
1985
+ "updated_at": {
1986
+ "name": "updated_at",
1987
+ "type": "text",
1988
+ "primaryKey": false,
1989
+ "notNull": true,
1990
+ "autoincrement": false,
1991
+ "default": "CURRENT_TIMESTAMP"
1992
+ }
1993
+ },
1994
+ "indexes": {},
1995
+ "foreignKeys": {
1996
+ "sub_agent_external_agent_relations_sub_agent_fk": {
1997
+ "name": "sub_agent_external_agent_relations_sub_agent_fk",
1998
+ "tableFrom": "sub_agent_external_agent_relations",
1999
+ "tableTo": "sub_agents",
2000
+ "columnsFrom": [
2001
+ "tenant_id",
2002
+ "project_id",
2003
+ "agent_id",
2004
+ "sub_agent_id"
2005
+ ],
2006
+ "columnsTo": [
2007
+ "tenant_id",
2008
+ "project_id",
2009
+ "agent_id",
2010
+ "id"
2011
+ ],
2012
+ "onDelete": "cascade",
2013
+ "onUpdate": "no action"
2014
+ },
2015
+ "sub_agent_external_agent_relations_external_agent_fk": {
2016
+ "name": "sub_agent_external_agent_relations_external_agent_fk",
2017
+ "tableFrom": "sub_agent_external_agent_relations",
2018
+ "tableTo": "external_agents",
2019
+ "columnsFrom": [
2020
+ "tenant_id",
2021
+ "project_id",
2022
+ "external_agent_id"
2023
+ ],
2024
+ "columnsTo": [
2025
+ "tenant_id",
2026
+ "project_id",
2027
+ "id"
2028
+ ],
2029
+ "onDelete": "cascade",
2030
+ "onUpdate": "no action"
2031
+ }
2032
+ },
2033
+ "compositePrimaryKeys": {
2034
+ "sub_agent_external_agent_relations_tenant_id_project_id_agent_id_id_pk": {
2035
+ "columns": [
2036
+ "tenant_id",
2037
+ "project_id",
2038
+ "agent_id",
2039
+ "id"
2040
+ ],
2041
+ "name": "sub_agent_external_agent_relations_tenant_id_project_id_agent_id_id_pk"
2042
+ }
2043
+ },
2044
+ "uniqueConstraints": {},
2045
+ "checkConstraints": {}
2046
+ },
2047
+ "sub_agent_function_tool_relations": {
2048
+ "name": "sub_agent_function_tool_relations",
2049
+ "columns": {
2050
+ "tenant_id": {
2051
+ "name": "tenant_id",
2052
+ "type": "text",
2053
+ "primaryKey": false,
2054
+ "notNull": true,
2055
+ "autoincrement": false
2056
+ },
2057
+ "id": {
2058
+ "name": "id",
2059
+ "type": "text",
2060
+ "primaryKey": false,
2061
+ "notNull": true,
2062
+ "autoincrement": false
2063
+ },
2064
+ "project_id": {
2065
+ "name": "project_id",
2066
+ "type": "text",
2067
+ "primaryKey": false,
2068
+ "notNull": true,
2069
+ "autoincrement": false
2070
+ },
2071
+ "agent_id": {
2072
+ "name": "agent_id",
2073
+ "type": "text",
2074
+ "primaryKey": false,
2075
+ "notNull": true,
2076
+ "autoincrement": false
2077
+ },
2078
+ "sub_agent_id": {
2079
+ "name": "sub_agent_id",
2080
+ "type": "text",
2081
+ "primaryKey": false,
2082
+ "notNull": true,
2083
+ "autoincrement": false
2084
+ },
2085
+ "function_tool_id": {
2086
+ "name": "function_tool_id",
2087
+ "type": "text",
2088
+ "primaryKey": false,
2089
+ "notNull": true,
2090
+ "autoincrement": false
2091
+ },
2092
+ "created_at": {
2093
+ "name": "created_at",
2094
+ "type": "text",
2095
+ "primaryKey": false,
2096
+ "notNull": true,
2097
+ "autoincrement": false,
2098
+ "default": "CURRENT_TIMESTAMP"
2099
+ },
2100
+ "updated_at": {
2101
+ "name": "updated_at",
2102
+ "type": "text",
2103
+ "primaryKey": false,
2104
+ "notNull": true,
2105
+ "autoincrement": false,
2106
+ "default": "CURRENT_TIMESTAMP"
2107
+ }
2108
+ },
2109
+ "indexes": {},
2110
+ "foreignKeys": {
2111
+ "sub_agent_function_tool_relations_sub_agent_fk": {
2112
+ "name": "sub_agent_function_tool_relations_sub_agent_fk",
2113
+ "tableFrom": "sub_agent_function_tool_relations",
2114
+ "tableTo": "sub_agents",
2115
+ "columnsFrom": [
2116
+ "tenant_id",
2117
+ "project_id",
2118
+ "agent_id",
2119
+ "sub_agent_id"
2120
+ ],
2121
+ "columnsTo": [
2122
+ "tenant_id",
2123
+ "project_id",
2124
+ "agent_id",
2125
+ "id"
2126
+ ],
2127
+ "onDelete": "cascade",
2128
+ "onUpdate": "no action"
2129
+ },
2130
+ "sub_agent_function_tool_relations_function_tool_fk": {
2131
+ "name": "sub_agent_function_tool_relations_function_tool_fk",
2132
+ "tableFrom": "sub_agent_function_tool_relations",
2133
+ "tableTo": "function_tools",
2134
+ "columnsFrom": [
2135
+ "tenant_id",
2136
+ "project_id",
2137
+ "agent_id",
2138
+ "function_tool_id"
2139
+ ],
2140
+ "columnsTo": [
2141
+ "tenant_id",
2142
+ "project_id",
2143
+ "agent_id",
2144
+ "id"
2145
+ ],
2146
+ "onDelete": "cascade",
2147
+ "onUpdate": "no action"
2148
+ }
2149
+ },
2150
+ "compositePrimaryKeys": {
2151
+ "sub_agent_function_tool_relations_tenant_id_project_id_agent_id_id_pk": {
2152
+ "columns": [
2153
+ "tenant_id",
2154
+ "project_id",
2155
+ "agent_id",
2156
+ "id"
2157
+ ],
2158
+ "name": "sub_agent_function_tool_relations_tenant_id_project_id_agent_id_id_pk"
2159
+ }
2160
+ },
2161
+ "uniqueConstraints": {},
2162
+ "checkConstraints": {}
2163
+ },
2164
+ "sub_agent_relations": {
2165
+ "name": "sub_agent_relations",
2166
+ "columns": {
2167
+ "tenant_id": {
2168
+ "name": "tenant_id",
2169
+ "type": "text",
2170
+ "primaryKey": false,
2171
+ "notNull": true,
2172
+ "autoincrement": false
2173
+ },
2174
+ "id": {
2175
+ "name": "id",
2176
+ "type": "text",
2177
+ "primaryKey": false,
2178
+ "notNull": true,
2179
+ "autoincrement": false
2180
+ },
2181
+ "project_id": {
2182
+ "name": "project_id",
2183
+ "type": "text",
2184
+ "primaryKey": false,
2185
+ "notNull": true,
2186
+ "autoincrement": false
2187
+ },
2188
+ "agent_id": {
2189
+ "name": "agent_id",
2190
+ "type": "text",
2191
+ "primaryKey": false,
2192
+ "notNull": true,
2193
+ "autoincrement": false
2194
+ },
2195
+ "source_sub_agent_id": {
2196
+ "name": "source_sub_agent_id",
2197
+ "type": "text",
2198
+ "primaryKey": false,
2199
+ "notNull": true,
2200
+ "autoincrement": false
2201
+ },
2202
+ "target_sub_agent_id": {
2203
+ "name": "target_sub_agent_id",
2204
+ "type": "text",
2205
+ "primaryKey": false,
2206
+ "notNull": false,
2207
+ "autoincrement": false
2208
+ },
2209
+ "relation_type": {
2210
+ "name": "relation_type",
2211
+ "type": "text",
2212
+ "primaryKey": false,
2213
+ "notNull": false,
2214
+ "autoincrement": false
2215
+ },
2216
+ "created_at": {
2217
+ "name": "created_at",
2218
+ "type": "text",
2219
+ "primaryKey": false,
2220
+ "notNull": true,
2221
+ "autoincrement": false,
2222
+ "default": "CURRENT_TIMESTAMP"
2223
+ },
2224
+ "updated_at": {
2225
+ "name": "updated_at",
2226
+ "type": "text",
2227
+ "primaryKey": false,
2228
+ "notNull": true,
2229
+ "autoincrement": false,
2230
+ "default": "CURRENT_TIMESTAMP"
2231
+ }
2232
+ },
2233
+ "indexes": {},
2234
+ "foreignKeys": {
2235
+ "sub_agent_relations_agent_fk": {
2236
+ "name": "sub_agent_relations_agent_fk",
2237
+ "tableFrom": "sub_agent_relations",
2238
+ "tableTo": "agent",
2239
+ "columnsFrom": [
2240
+ "tenant_id",
2241
+ "project_id",
2242
+ "agent_id"
2243
+ ],
2244
+ "columnsTo": [
2245
+ "tenant_id",
2246
+ "project_id",
2247
+ "id"
2248
+ ],
2249
+ "onDelete": "cascade",
2250
+ "onUpdate": "no action"
2251
+ }
2252
+ },
2253
+ "compositePrimaryKeys": {
2254
+ "sub_agent_relations_tenant_id_project_id_agent_id_id_pk": {
2255
+ "columns": [
2256
+ "tenant_id",
2257
+ "project_id",
2258
+ "agent_id",
2259
+ "id"
2260
+ ],
2261
+ "name": "sub_agent_relations_tenant_id_project_id_agent_id_id_pk"
2262
+ }
2263
+ },
2264
+ "uniqueConstraints": {},
2265
+ "checkConstraints": {}
2266
+ },
2267
+ "sub_agent_team_agent_relations": {
2268
+ "name": "sub_agent_team_agent_relations",
2269
+ "columns": {
2270
+ "tenant_id": {
2271
+ "name": "tenant_id",
2272
+ "type": "text",
2273
+ "primaryKey": false,
2274
+ "notNull": true,
2275
+ "autoincrement": false
2276
+ },
2277
+ "id": {
2278
+ "name": "id",
2279
+ "type": "text",
2280
+ "primaryKey": false,
2281
+ "notNull": true,
2282
+ "autoincrement": false
2283
+ },
2284
+ "project_id": {
2285
+ "name": "project_id",
2286
+ "type": "text",
2287
+ "primaryKey": false,
2288
+ "notNull": true,
2289
+ "autoincrement": false
2290
+ },
2291
+ "agent_id": {
2292
+ "name": "agent_id",
2293
+ "type": "text",
2294
+ "primaryKey": false,
2295
+ "notNull": true,
2296
+ "autoincrement": false
2297
+ },
2298
+ "sub_agent_id": {
2299
+ "name": "sub_agent_id",
2300
+ "type": "text",
2301
+ "primaryKey": false,
2302
+ "notNull": true,
2303
+ "autoincrement": false
2304
+ },
2305
+ "target_agent_id": {
2306
+ "name": "target_agent_id",
2307
+ "type": "text",
2308
+ "primaryKey": false,
2309
+ "notNull": true,
2310
+ "autoincrement": false
2311
+ },
2312
+ "headers": {
2313
+ "name": "headers",
2314
+ "type": "blob",
2315
+ "primaryKey": false,
2316
+ "notNull": false,
2317
+ "autoincrement": false
2318
+ },
2319
+ "created_at": {
2320
+ "name": "created_at",
2321
+ "type": "text",
2322
+ "primaryKey": false,
2323
+ "notNull": true,
2324
+ "autoincrement": false,
2325
+ "default": "CURRENT_TIMESTAMP"
2326
+ },
2327
+ "updated_at": {
2328
+ "name": "updated_at",
2329
+ "type": "text",
2330
+ "primaryKey": false,
2331
+ "notNull": true,
2332
+ "autoincrement": false,
2333
+ "default": "CURRENT_TIMESTAMP"
2334
+ }
2335
+ },
2336
+ "indexes": {},
2337
+ "foreignKeys": {
2338
+ "sub_agent_team_agent_relations_sub_agent_fk": {
2339
+ "name": "sub_agent_team_agent_relations_sub_agent_fk",
2340
+ "tableFrom": "sub_agent_team_agent_relations",
2341
+ "tableTo": "sub_agents",
2342
+ "columnsFrom": [
2343
+ "tenant_id",
2344
+ "project_id",
2345
+ "agent_id",
2346
+ "sub_agent_id"
2347
+ ],
2348
+ "columnsTo": [
2349
+ "tenant_id",
2350
+ "project_id",
2351
+ "agent_id",
2352
+ "id"
2353
+ ],
2354
+ "onDelete": "cascade",
2355
+ "onUpdate": "no action"
2356
+ },
2357
+ "sub_agent_team_agent_relations_target_agent_fk": {
2358
+ "name": "sub_agent_team_agent_relations_target_agent_fk",
2359
+ "tableFrom": "sub_agent_team_agent_relations",
2360
+ "tableTo": "agent",
2361
+ "columnsFrom": [
2362
+ "tenant_id",
2363
+ "project_id",
2364
+ "target_agent_id"
2365
+ ],
2366
+ "columnsTo": [
2367
+ "tenant_id",
2368
+ "project_id",
2369
+ "id"
2370
+ ],
2371
+ "onDelete": "cascade",
2372
+ "onUpdate": "no action"
2373
+ }
2374
+ },
2375
+ "compositePrimaryKeys": {
2376
+ "sub_agent_team_agent_relations_tenant_id_project_id_agent_id_id_pk": {
2377
+ "columns": [
2378
+ "tenant_id",
2379
+ "project_id",
2380
+ "agent_id",
2381
+ "id"
2382
+ ],
2383
+ "name": "sub_agent_team_agent_relations_tenant_id_project_id_agent_id_id_pk"
2384
+ }
2385
+ },
2386
+ "uniqueConstraints": {},
2387
+ "checkConstraints": {}
2388
+ },
2389
+ "sub_agent_tool_relations": {
2390
+ "name": "sub_agent_tool_relations",
2391
+ "columns": {
2392
+ "tenant_id": {
2393
+ "name": "tenant_id",
2394
+ "type": "text",
2395
+ "primaryKey": false,
2396
+ "notNull": true,
2397
+ "autoincrement": false
2398
+ },
2399
+ "id": {
2400
+ "name": "id",
2401
+ "type": "text",
2402
+ "primaryKey": false,
2403
+ "notNull": true,
2404
+ "autoincrement": false
2405
+ },
2406
+ "project_id": {
2407
+ "name": "project_id",
2408
+ "type": "text",
2409
+ "primaryKey": false,
2410
+ "notNull": true,
2411
+ "autoincrement": false
2412
+ },
2413
+ "agent_id": {
2414
+ "name": "agent_id",
2415
+ "type": "text",
2416
+ "primaryKey": false,
2417
+ "notNull": true,
2418
+ "autoincrement": false
2419
+ },
2420
+ "sub_agent_id": {
2421
+ "name": "sub_agent_id",
2422
+ "type": "text",
2423
+ "primaryKey": false,
2424
+ "notNull": true,
2425
+ "autoincrement": false
2426
+ },
2427
+ "tool_id": {
2428
+ "name": "tool_id",
2429
+ "type": "text",
2430
+ "primaryKey": false,
2431
+ "notNull": true,
2432
+ "autoincrement": false
2433
+ },
2434
+ "selected_tools": {
2435
+ "name": "selected_tools",
2436
+ "type": "blob",
2437
+ "primaryKey": false,
2438
+ "notNull": false,
2439
+ "autoincrement": false
2440
+ },
2441
+ "headers": {
2442
+ "name": "headers",
2443
+ "type": "blob",
2444
+ "primaryKey": false,
2445
+ "notNull": false,
2446
+ "autoincrement": false
2447
+ },
2448
+ "created_at": {
2449
+ "name": "created_at",
2450
+ "type": "text",
2451
+ "primaryKey": false,
2452
+ "notNull": true,
2453
+ "autoincrement": false,
2454
+ "default": "CURRENT_TIMESTAMP"
2455
+ },
2456
+ "updated_at": {
2457
+ "name": "updated_at",
2458
+ "type": "text",
2459
+ "primaryKey": false,
2460
+ "notNull": true,
2461
+ "autoincrement": false,
2462
+ "default": "CURRENT_TIMESTAMP"
2463
+ }
2464
+ },
2465
+ "indexes": {},
2466
+ "foreignKeys": {
2467
+ "sub_agent_tool_relations_agent_fk": {
2468
+ "name": "sub_agent_tool_relations_agent_fk",
2469
+ "tableFrom": "sub_agent_tool_relations",
2470
+ "tableTo": "sub_agents",
2471
+ "columnsFrom": [
2472
+ "tenant_id",
2473
+ "project_id",
2474
+ "agent_id",
2475
+ "sub_agent_id"
2476
+ ],
2477
+ "columnsTo": [
2478
+ "tenant_id",
2479
+ "project_id",
2480
+ "agent_id",
2481
+ "id"
2482
+ ],
2483
+ "onDelete": "cascade",
2484
+ "onUpdate": "no action"
2485
+ },
2486
+ "sub_agent_tool_relations_tool_fk": {
2487
+ "name": "sub_agent_tool_relations_tool_fk",
2488
+ "tableFrom": "sub_agent_tool_relations",
2489
+ "tableTo": "tools",
2490
+ "columnsFrom": [
2491
+ "tenant_id",
2492
+ "project_id",
2493
+ "tool_id"
2494
+ ],
2495
+ "columnsTo": [
2496
+ "tenant_id",
2497
+ "project_id",
2498
+ "id"
2499
+ ],
2500
+ "onDelete": "cascade",
2501
+ "onUpdate": "no action"
2502
+ }
2503
+ },
2504
+ "compositePrimaryKeys": {
2505
+ "sub_agent_tool_relations_tenant_id_project_id_agent_id_id_pk": {
2506
+ "columns": [
2507
+ "tenant_id",
2508
+ "project_id",
2509
+ "agent_id",
2510
+ "id"
2511
+ ],
2512
+ "name": "sub_agent_tool_relations_tenant_id_project_id_agent_id_id_pk"
2513
+ }
2514
+ },
2515
+ "uniqueConstraints": {},
2516
+ "checkConstraints": {}
2517
+ },
2518
+ "sub_agents": {
2519
+ "name": "sub_agents",
2520
+ "columns": {
2521
+ "tenant_id": {
2522
+ "name": "tenant_id",
2523
+ "type": "text",
2524
+ "primaryKey": false,
2525
+ "notNull": true,
2526
+ "autoincrement": false
2527
+ },
2528
+ "id": {
2529
+ "name": "id",
2530
+ "type": "text",
2531
+ "primaryKey": false,
2532
+ "notNull": true,
2533
+ "autoincrement": false
2534
+ },
2535
+ "project_id": {
2536
+ "name": "project_id",
2537
+ "type": "text",
2538
+ "primaryKey": false,
2539
+ "notNull": true,
2540
+ "autoincrement": false
2541
+ },
2542
+ "agent_id": {
2543
+ "name": "agent_id",
2544
+ "type": "text",
2545
+ "primaryKey": false,
2546
+ "notNull": true,
2547
+ "autoincrement": false
2548
+ },
2549
+ "name": {
2550
+ "name": "name",
2551
+ "type": "text",
2552
+ "primaryKey": false,
2553
+ "notNull": true,
2554
+ "autoincrement": false
2555
+ },
2556
+ "description": {
2557
+ "name": "description",
2558
+ "type": "text",
2559
+ "primaryKey": false,
2560
+ "notNull": true,
2561
+ "autoincrement": false
2562
+ },
2563
+ "prompt": {
2564
+ "name": "prompt",
2565
+ "type": "text",
2566
+ "primaryKey": false,
2567
+ "notNull": true,
2568
+ "autoincrement": false
2569
+ },
2570
+ "conversation_history_config": {
2571
+ "name": "conversation_history_config",
2572
+ "type": "text",
2573
+ "primaryKey": false,
2574
+ "notNull": false,
2575
+ "autoincrement": false
2576
+ },
2577
+ "models": {
2578
+ "name": "models",
2579
+ "type": "text",
2580
+ "primaryKey": false,
2581
+ "notNull": false,
2582
+ "autoincrement": false
2583
+ },
2584
+ "stop_when": {
2585
+ "name": "stop_when",
2586
+ "type": "text",
2587
+ "primaryKey": false,
2588
+ "notNull": false,
2589
+ "autoincrement": false
2590
+ },
2591
+ "created_at": {
2592
+ "name": "created_at",
2593
+ "type": "text",
2594
+ "primaryKey": false,
2595
+ "notNull": true,
2596
+ "autoincrement": false,
2597
+ "default": "CURRENT_TIMESTAMP"
2598
+ },
2599
+ "updated_at": {
2600
+ "name": "updated_at",
2601
+ "type": "text",
2602
+ "primaryKey": false,
2603
+ "notNull": true,
2604
+ "autoincrement": false,
2605
+ "default": "CURRENT_TIMESTAMP"
2606
+ }
2607
+ },
2608
+ "indexes": {},
2609
+ "foreignKeys": {
2610
+ "sub_agents_agents_fk": {
2611
+ "name": "sub_agents_agents_fk",
2612
+ "tableFrom": "sub_agents",
2613
+ "tableTo": "agent",
2614
+ "columnsFrom": [
2615
+ "tenant_id",
2616
+ "project_id",
2617
+ "agent_id"
2618
+ ],
2619
+ "columnsTo": [
2620
+ "tenant_id",
2621
+ "project_id",
2622
+ "id"
2623
+ ],
2624
+ "onDelete": "cascade",
2625
+ "onUpdate": "no action"
2626
+ }
2627
+ },
2628
+ "compositePrimaryKeys": {
2629
+ "sub_agents_tenant_id_project_id_agent_id_id_pk": {
2630
+ "columns": [
2631
+ "tenant_id",
2632
+ "project_id",
2633
+ "agent_id",
2634
+ "id"
2635
+ ],
2636
+ "name": "sub_agents_tenant_id_project_id_agent_id_id_pk"
2637
+ }
2638
+ },
2639
+ "uniqueConstraints": {},
2640
+ "checkConstraints": {}
2641
+ },
2642
+ "task_relations": {
2643
+ "name": "task_relations",
2644
+ "columns": {
2645
+ "tenant_id": {
2646
+ "name": "tenant_id",
2647
+ "type": "text",
2648
+ "primaryKey": false,
2649
+ "notNull": true,
2650
+ "autoincrement": false
2651
+ },
2652
+ "id": {
2653
+ "name": "id",
2654
+ "type": "text",
2655
+ "primaryKey": false,
2656
+ "notNull": true,
2657
+ "autoincrement": false
2658
+ },
2659
+ "project_id": {
2660
+ "name": "project_id",
2661
+ "type": "text",
2662
+ "primaryKey": false,
2663
+ "notNull": true,
2664
+ "autoincrement": false
2665
+ },
2666
+ "parent_task_id": {
2667
+ "name": "parent_task_id",
2668
+ "type": "text",
2669
+ "primaryKey": false,
2670
+ "notNull": true,
2671
+ "autoincrement": false
2672
+ },
2673
+ "child_task_id": {
2674
+ "name": "child_task_id",
2675
+ "type": "text",
2676
+ "primaryKey": false,
2677
+ "notNull": true,
2678
+ "autoincrement": false
2679
+ },
2680
+ "relation_type": {
2681
+ "name": "relation_type",
2682
+ "type": "text",
2683
+ "primaryKey": false,
2684
+ "notNull": false,
2685
+ "autoincrement": false,
2686
+ "default": "'parent_child'"
2687
+ },
2688
+ "created_at": {
2689
+ "name": "created_at",
2690
+ "type": "text",
2691
+ "primaryKey": false,
2692
+ "notNull": true,
2693
+ "autoincrement": false,
2694
+ "default": "CURRENT_TIMESTAMP"
2695
+ },
2696
+ "updated_at": {
2697
+ "name": "updated_at",
2698
+ "type": "text",
2699
+ "primaryKey": false,
2700
+ "notNull": true,
2701
+ "autoincrement": false,
2702
+ "default": "CURRENT_TIMESTAMP"
2703
+ }
2704
+ },
2705
+ "indexes": {},
2706
+ "foreignKeys": {
2707
+ "task_relations_project_fk": {
2708
+ "name": "task_relations_project_fk",
2709
+ "tableFrom": "task_relations",
2710
+ "tableTo": "projects",
2711
+ "columnsFrom": [
2712
+ "tenant_id",
2713
+ "project_id"
2714
+ ],
2715
+ "columnsTo": [
2716
+ "tenant_id",
2717
+ "id"
2718
+ ],
2719
+ "onDelete": "cascade",
2720
+ "onUpdate": "no action"
2721
+ }
2722
+ },
2723
+ "compositePrimaryKeys": {
2724
+ "task_relations_tenant_id_project_id_id_pk": {
2725
+ "columns": [
2726
+ "tenant_id",
2727
+ "project_id",
2728
+ "id"
2729
+ ],
2730
+ "name": "task_relations_tenant_id_project_id_id_pk"
2731
+ }
2732
+ },
2733
+ "uniqueConstraints": {},
2734
+ "checkConstraints": {}
2735
+ },
2736
+ "tasks": {
2737
+ "name": "tasks",
2738
+ "columns": {
2739
+ "tenant_id": {
2740
+ "name": "tenant_id",
2741
+ "type": "text",
2742
+ "primaryKey": false,
2743
+ "notNull": true,
2744
+ "autoincrement": false
2745
+ },
2746
+ "id": {
2747
+ "name": "id",
2748
+ "type": "text",
2749
+ "primaryKey": false,
2750
+ "notNull": true,
2751
+ "autoincrement": false
2752
+ },
2753
+ "project_id": {
2754
+ "name": "project_id",
2755
+ "type": "text",
2756
+ "primaryKey": false,
2757
+ "notNull": true,
2758
+ "autoincrement": false
2759
+ },
2760
+ "agent_id": {
2761
+ "name": "agent_id",
2762
+ "type": "text",
2763
+ "primaryKey": false,
2764
+ "notNull": true,
2765
+ "autoincrement": false
2766
+ },
2767
+ "sub_agent_id": {
2768
+ "name": "sub_agent_id",
2769
+ "type": "text",
2770
+ "primaryKey": false,
2771
+ "notNull": true,
2772
+ "autoincrement": false
2773
+ },
2774
+ "context_id": {
2775
+ "name": "context_id",
2776
+ "type": "text",
2777
+ "primaryKey": false,
2778
+ "notNull": true,
2779
+ "autoincrement": false
2780
+ },
2781
+ "status": {
2782
+ "name": "status",
2783
+ "type": "text",
2784
+ "primaryKey": false,
2785
+ "notNull": true,
2786
+ "autoincrement": false
2787
+ },
2788
+ "metadata": {
2789
+ "name": "metadata",
2790
+ "type": "blob",
2791
+ "primaryKey": false,
2792
+ "notNull": false,
2793
+ "autoincrement": false
2794
+ },
2795
+ "created_at": {
2796
+ "name": "created_at",
2797
+ "type": "text",
2798
+ "primaryKey": false,
2799
+ "notNull": true,
2800
+ "autoincrement": false,
2801
+ "default": "CURRENT_TIMESTAMP"
2802
+ },
2803
+ "updated_at": {
2804
+ "name": "updated_at",
2805
+ "type": "text",
2806
+ "primaryKey": false,
2807
+ "notNull": true,
2808
+ "autoincrement": false,
2809
+ "default": "CURRENT_TIMESTAMP"
2810
+ }
2811
+ },
2812
+ "indexes": {},
2813
+ "foreignKeys": {
2814
+ "tasks_sub_agent_fk": {
2815
+ "name": "tasks_sub_agent_fk",
2816
+ "tableFrom": "tasks",
2817
+ "tableTo": "sub_agents",
2818
+ "columnsFrom": [
2819
+ "tenant_id",
2820
+ "project_id",
2821
+ "agent_id",
2822
+ "sub_agent_id"
2823
+ ],
2824
+ "columnsTo": [
2825
+ "tenant_id",
2826
+ "project_id",
2827
+ "agent_id",
2828
+ "id"
2829
+ ],
2830
+ "onDelete": "cascade",
2831
+ "onUpdate": "no action"
2832
+ }
2833
+ },
2834
+ "compositePrimaryKeys": {
2835
+ "tasks_tenant_id_project_id_id_pk": {
2836
+ "columns": [
2837
+ "tenant_id",
2838
+ "project_id",
2839
+ "id"
2840
+ ],
2841
+ "name": "tasks_tenant_id_project_id_id_pk"
2842
+ }
2843
+ },
2844
+ "uniqueConstraints": {},
2845
+ "checkConstraints": {}
2846
+ },
2847
+ "tools": {
2848
+ "name": "tools",
2849
+ "columns": {
2850
+ "tenant_id": {
2851
+ "name": "tenant_id",
2852
+ "type": "text",
2853
+ "primaryKey": false,
2854
+ "notNull": true,
2855
+ "autoincrement": false
2856
+ },
2857
+ "id": {
2858
+ "name": "id",
2859
+ "type": "text",
2860
+ "primaryKey": false,
2861
+ "notNull": true,
2862
+ "autoincrement": false
2863
+ },
2864
+ "project_id": {
2865
+ "name": "project_id",
2866
+ "type": "text",
2867
+ "primaryKey": false,
2868
+ "notNull": true,
2869
+ "autoincrement": false
2870
+ },
2871
+ "name": {
2872
+ "name": "name",
2873
+ "type": "text",
2874
+ "primaryKey": false,
2875
+ "notNull": true,
2876
+ "autoincrement": false
2877
+ },
2878
+ "description": {
2879
+ "name": "description",
2880
+ "type": "text",
2881
+ "primaryKey": false,
2882
+ "notNull": false,
2883
+ "autoincrement": false
2884
+ },
2885
+ "config": {
2886
+ "name": "config",
2887
+ "type": "blob",
2888
+ "primaryKey": false,
2889
+ "notNull": true,
2890
+ "autoincrement": false
2891
+ },
2892
+ "credential_reference_id": {
2893
+ "name": "credential_reference_id",
2894
+ "type": "text",
2895
+ "primaryKey": false,
2896
+ "notNull": false,
2897
+ "autoincrement": false
2898
+ },
2899
+ "headers": {
2900
+ "name": "headers",
2901
+ "type": "blob",
2902
+ "primaryKey": false,
2903
+ "notNull": false,
2904
+ "autoincrement": false
2905
+ },
2906
+ "image_url": {
2907
+ "name": "image_url",
2908
+ "type": "text",
2909
+ "primaryKey": false,
2910
+ "notNull": false,
2911
+ "autoincrement": false
2912
+ },
2913
+ "capabilities": {
2914
+ "name": "capabilities",
2915
+ "type": "blob",
2916
+ "primaryKey": false,
2917
+ "notNull": false,
2918
+ "autoincrement": false
2919
+ },
2920
+ "last_error": {
2921
+ "name": "last_error",
2922
+ "type": "text",
2923
+ "primaryKey": false,
2924
+ "notNull": false,
2925
+ "autoincrement": false
2926
+ },
2927
+ "created_at": {
2928
+ "name": "created_at",
2929
+ "type": "text",
2930
+ "primaryKey": false,
2931
+ "notNull": true,
2932
+ "autoincrement": false,
2933
+ "default": "CURRENT_TIMESTAMP"
2934
+ },
2935
+ "updated_at": {
2936
+ "name": "updated_at",
2937
+ "type": "text",
2938
+ "primaryKey": false,
2939
+ "notNull": true,
2940
+ "autoincrement": false,
2941
+ "default": "CURRENT_TIMESTAMP"
2942
+ }
2943
+ },
2944
+ "indexes": {},
2945
+ "foreignKeys": {
2946
+ "tools_project_fk": {
2947
+ "name": "tools_project_fk",
2948
+ "tableFrom": "tools",
2949
+ "tableTo": "projects",
2950
+ "columnsFrom": [
2951
+ "tenant_id",
2952
+ "project_id"
2953
+ ],
2954
+ "columnsTo": [
2955
+ "tenant_id",
2956
+ "id"
2957
+ ],
2958
+ "onDelete": "cascade",
2959
+ "onUpdate": "no action"
2960
+ }
2961
+ },
2962
+ "compositePrimaryKeys": {
2963
+ "tools_tenant_id_project_id_id_pk": {
2964
+ "columns": [
2965
+ "tenant_id",
2966
+ "project_id",
2967
+ "id"
2968
+ ],
2969
+ "name": "tools_tenant_id_project_id_id_pk"
2970
+ }
2971
+ },
2972
+ "uniqueConstraints": {},
2973
+ "checkConstraints": {}
2974
+ }
2975
+ },
2976
+ "views": {},
2977
+ "enums": {},
2978
+ "_meta": {
2979
+ "schemas": {},
2980
+ "tables": {},
2981
+ "columns": {
2982
+ "\"data_components\".\"preview\"": "\"data_components\".\"render\""
2983
+ }
2984
+ },
2985
+ "internal": {
2986
+ "indexes": {}
2987
+ }
2988
+ }