runwarden 0.0.0-stage → 0.2.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,720 @@
1
+ {
2
+ "id": "ccda8d23-bb0e-4828-8930-dbe70db5ab2d",
3
+ "prevId": "00000000-0000-0000-0000-000000000000",
4
+ "version": "7",
5
+ "dialect": "postgresql",
6
+ "tables": {
7
+ "agent_runtime.invocations": {
8
+ "name": "invocations",
9
+ "schema": "agent_runtime",
10
+ "columns": {
11
+ "id": {
12
+ "name": "id",
13
+ "type": "bigint",
14
+ "primaryKey": true,
15
+ "notNull": true,
16
+ "identity": {
17
+ "type": "always",
18
+ "name": "invocations_id_seq",
19
+ "schema": "agent_runtime",
20
+ "increment": "1",
21
+ "startWith": "1",
22
+ "minValue": "1",
23
+ "maxValue": "9223372036854775807",
24
+ "cache": "1",
25
+ "cycle": false
26
+ }
27
+ },
28
+ "scope": {
29
+ "name": "scope",
30
+ "type": "text",
31
+ "primaryKey": false,
32
+ "notNull": true
33
+ },
34
+ "conversation_id": {
35
+ "name": "conversation_id",
36
+ "type": "text",
37
+ "primaryKey": false,
38
+ "notNull": false
39
+ },
40
+ "ordering_key": {
41
+ "name": "ordering_key",
42
+ "type": "text",
43
+ "primaryKey": false,
44
+ "notNull": false
45
+ },
46
+ "input": {
47
+ "name": "input",
48
+ "type": "jsonb",
49
+ "primaryKey": false,
50
+ "notNull": true
51
+ },
52
+ "result_text": {
53
+ "name": "result_text",
54
+ "type": "text",
55
+ "primaryKey": false,
56
+ "notNull": false
57
+ },
58
+ "idempotency_key": {
59
+ "name": "idempotency_key",
60
+ "type": "text",
61
+ "primaryKey": false,
62
+ "notNull": false
63
+ },
64
+ "status": {
65
+ "name": "status",
66
+ "type": "invocation_status",
67
+ "typeSchema": "agent_runtime",
68
+ "primaryKey": false,
69
+ "notNull": true,
70
+ "default": "'pending'"
71
+ },
72
+ "attempt_count": {
73
+ "name": "attempt_count",
74
+ "type": "integer",
75
+ "primaryKey": false,
76
+ "notNull": true,
77
+ "default": 0
78
+ },
79
+ "max_attempts": {
80
+ "name": "max_attempts",
81
+ "type": "integer",
82
+ "primaryKey": false,
83
+ "notNull": true,
84
+ "default": 3
85
+ },
86
+ "next_attempt_at": {
87
+ "name": "next_attempt_at",
88
+ "type": "timestamp with time zone",
89
+ "primaryKey": false,
90
+ "notNull": true,
91
+ "default": "now()"
92
+ },
93
+ "claimed_at": {
94
+ "name": "claimed_at",
95
+ "type": "timestamp with time zone",
96
+ "primaryKey": false,
97
+ "notNull": false
98
+ },
99
+ "claimed_by": {
100
+ "name": "claimed_by",
101
+ "type": "text",
102
+ "primaryKey": false,
103
+ "notNull": false
104
+ },
105
+ "lease_heartbeat_at": {
106
+ "name": "lease_heartbeat_at",
107
+ "type": "timestamp with time zone",
108
+ "primaryKey": false,
109
+ "notNull": false
110
+ },
111
+ "lease_expires_at": {
112
+ "name": "lease_expires_at",
113
+ "type": "timestamp with time zone",
114
+ "primaryKey": false,
115
+ "notNull": false
116
+ },
117
+ "active_run_id": {
118
+ "name": "active_run_id",
119
+ "type": "uuid",
120
+ "primaryKey": false,
121
+ "notNull": false
122
+ },
123
+ "active_run_registered_at": {
124
+ "name": "active_run_registered_at",
125
+ "type": "timestamp with time zone",
126
+ "primaryKey": false,
127
+ "notNull": false
128
+ },
129
+ "pending_tool_call": {
130
+ "name": "pending_tool_call",
131
+ "type": "jsonb",
132
+ "primaryKey": false,
133
+ "notNull": false
134
+ },
135
+ "started_at": {
136
+ "name": "started_at",
137
+ "type": "timestamp with time zone",
138
+ "primaryKey": false,
139
+ "notNull": false
140
+ },
141
+ "completed_at": {
142
+ "name": "completed_at",
143
+ "type": "timestamp with time zone",
144
+ "primaryKey": false,
145
+ "notNull": false
146
+ },
147
+ "failed_at": {
148
+ "name": "failed_at",
149
+ "type": "timestamp with time zone",
150
+ "primaryKey": false,
151
+ "notNull": false
152
+ },
153
+ "provider": {
154
+ "name": "provider",
155
+ "type": "text",
156
+ "primaryKey": false,
157
+ "notNull": false
158
+ },
159
+ "model": {
160
+ "name": "model",
161
+ "type": "text",
162
+ "primaryKey": false,
163
+ "notNull": false
164
+ },
165
+ "last_error_code": {
166
+ "name": "last_error_code",
167
+ "type": "text",
168
+ "primaryKey": false,
169
+ "notNull": false
170
+ },
171
+ "last_error_message": {
172
+ "name": "last_error_message",
173
+ "type": "text",
174
+ "primaryKey": false,
175
+ "notNull": false
176
+ },
177
+ "metadata": {
178
+ "name": "metadata",
179
+ "type": "jsonb",
180
+ "primaryKey": false,
181
+ "notNull": false
182
+ },
183
+ "created_at": {
184
+ "name": "created_at",
185
+ "type": "timestamp with time zone",
186
+ "primaryKey": false,
187
+ "notNull": true,
188
+ "default": "now()"
189
+ },
190
+ "updated_at": {
191
+ "name": "updated_at",
192
+ "type": "timestamp with time zone",
193
+ "primaryKey": false,
194
+ "notNull": true,
195
+ "default": "now()"
196
+ }
197
+ },
198
+ "indexes": {
199
+ "invocations_scope_idempotency_key_unique": {
200
+ "name": "invocations_scope_idempotency_key_unique",
201
+ "columns": [
202
+ {
203
+ "expression": "scope",
204
+ "isExpression": false,
205
+ "asc": true,
206
+ "nulls": "last"
207
+ },
208
+ {
209
+ "expression": "idempotency_key",
210
+ "isExpression": false,
211
+ "asc": true,
212
+ "nulls": "last"
213
+ }
214
+ ],
215
+ "isUnique": true,
216
+ "where": "\"agent_runtime\".\"invocations\".\"idempotency_key\" is not null",
217
+ "concurrently": false,
218
+ "method": "btree",
219
+ "with": {}
220
+ },
221
+ "invocations_active_run_id_unique": {
222
+ "name": "invocations_active_run_id_unique",
223
+ "columns": [
224
+ {
225
+ "expression": "active_run_id",
226
+ "isExpression": false,
227
+ "asc": true,
228
+ "nulls": "last"
229
+ }
230
+ ],
231
+ "isUnique": true,
232
+ "where": "\"agent_runtime\".\"invocations\".\"active_run_id\" is not null",
233
+ "concurrently": false,
234
+ "method": "btree",
235
+ "with": {}
236
+ },
237
+ "invocations_status_next_attempt_idx": {
238
+ "name": "invocations_status_next_attempt_idx",
239
+ "columns": [
240
+ {
241
+ "expression": "status",
242
+ "isExpression": false,
243
+ "asc": true,
244
+ "nulls": "last"
245
+ },
246
+ {
247
+ "expression": "next_attempt_at",
248
+ "isExpression": false,
249
+ "asc": true,
250
+ "nulls": "last"
251
+ }
252
+ ],
253
+ "isUnique": false,
254
+ "concurrently": false,
255
+ "method": "btree",
256
+ "with": {}
257
+ },
258
+ "invocations_status_lease_expires_idx": {
259
+ "name": "invocations_status_lease_expires_idx",
260
+ "columns": [
261
+ {
262
+ "expression": "status",
263
+ "isExpression": false,
264
+ "asc": true,
265
+ "nulls": "last"
266
+ },
267
+ {
268
+ "expression": "lease_expires_at",
269
+ "isExpression": false,
270
+ "asc": true,
271
+ "nulls": "last"
272
+ }
273
+ ],
274
+ "isUnique": false,
275
+ "concurrently": false,
276
+ "method": "btree",
277
+ "with": {}
278
+ },
279
+ "invocations_scope_status_next_attempt_idx": {
280
+ "name": "invocations_scope_status_next_attempt_idx",
281
+ "columns": [
282
+ {
283
+ "expression": "scope",
284
+ "isExpression": false,
285
+ "asc": true,
286
+ "nulls": "last"
287
+ },
288
+ {
289
+ "expression": "status",
290
+ "isExpression": false,
291
+ "asc": true,
292
+ "nulls": "last"
293
+ },
294
+ {
295
+ "expression": "next_attempt_at",
296
+ "isExpression": false,
297
+ "asc": true,
298
+ "nulls": "last"
299
+ }
300
+ ],
301
+ "isUnique": false,
302
+ "concurrently": false,
303
+ "method": "btree",
304
+ "with": {}
305
+ },
306
+ "invocations_scope_created_idx": {
307
+ "name": "invocations_scope_created_idx",
308
+ "columns": [
309
+ {
310
+ "expression": "scope",
311
+ "isExpression": false,
312
+ "asc": true,
313
+ "nulls": "last"
314
+ },
315
+ {
316
+ "expression": "created_at",
317
+ "isExpression": false,
318
+ "asc": true,
319
+ "nulls": "last"
320
+ }
321
+ ],
322
+ "isUnique": false,
323
+ "concurrently": false,
324
+ "method": "btree",
325
+ "with": {}
326
+ }
327
+ },
328
+ "foreignKeys": {},
329
+ "compositePrimaryKeys": {},
330
+ "uniqueConstraints": {},
331
+ "policies": {},
332
+ "checkConstraints": {},
333
+ "isRLSEnabled": false
334
+ },
335
+ "agent_runtime.policy_decisions": {
336
+ "name": "policy_decisions",
337
+ "schema": "agent_runtime",
338
+ "columns": {
339
+ "id": {
340
+ "name": "id",
341
+ "type": "bigint",
342
+ "primaryKey": true,
343
+ "notNull": true,
344
+ "identity": {
345
+ "type": "always",
346
+ "name": "policy_decisions_id_seq",
347
+ "schema": "agent_runtime",
348
+ "increment": "1",
349
+ "startWith": "1",
350
+ "minValue": "1",
351
+ "maxValue": "9223372036854775807",
352
+ "cache": "1",
353
+ "cycle": false
354
+ }
355
+ },
356
+ "scope": {
357
+ "name": "scope",
358
+ "type": "text",
359
+ "primaryKey": false,
360
+ "notNull": true
361
+ },
362
+ "invocation_id": {
363
+ "name": "invocation_id",
364
+ "type": "bigint",
365
+ "primaryKey": false,
366
+ "notNull": true
367
+ },
368
+ "run_id": {
369
+ "name": "run_id",
370
+ "type": "uuid",
371
+ "primaryKey": false,
372
+ "notNull": true
373
+ },
374
+ "tool_name": {
375
+ "name": "tool_name",
376
+ "type": "text",
377
+ "primaryKey": false,
378
+ "notNull": false
379
+ },
380
+ "rule": {
381
+ "name": "rule",
382
+ "type": "text",
383
+ "primaryKey": false,
384
+ "notNull": true
385
+ },
386
+ "decision": {
387
+ "name": "decision",
388
+ "type": "text",
389
+ "primaryKey": false,
390
+ "notNull": true
391
+ },
392
+ "detail": {
393
+ "name": "detail",
394
+ "type": "jsonb",
395
+ "primaryKey": false,
396
+ "notNull": false
397
+ },
398
+ "created_at": {
399
+ "name": "created_at",
400
+ "type": "timestamp with time zone",
401
+ "primaryKey": false,
402
+ "notNull": true,
403
+ "default": "now()"
404
+ }
405
+ },
406
+ "indexes": {
407
+ "policy_decisions_invocation_idx": {
408
+ "name": "policy_decisions_invocation_idx",
409
+ "columns": [
410
+ {
411
+ "expression": "invocation_id",
412
+ "isExpression": false,
413
+ "asc": true,
414
+ "nulls": "last"
415
+ }
416
+ ],
417
+ "isUnique": false,
418
+ "concurrently": false,
419
+ "method": "btree",
420
+ "with": {}
421
+ },
422
+ "policy_decisions_run_idx": {
423
+ "name": "policy_decisions_run_idx",
424
+ "columns": [
425
+ {
426
+ "expression": "run_id",
427
+ "isExpression": false,
428
+ "asc": true,
429
+ "nulls": "last"
430
+ }
431
+ ],
432
+ "isUnique": false,
433
+ "concurrently": false,
434
+ "method": "btree",
435
+ "with": {}
436
+ }
437
+ },
438
+ "foreignKeys": {
439
+ "policy_decisions_invocation_id_invocations_id_fk": {
440
+ "name": "policy_decisions_invocation_id_invocations_id_fk",
441
+ "tableFrom": "policy_decisions",
442
+ "tableTo": "invocations",
443
+ "schemaTo": "agent_runtime",
444
+ "columnsFrom": [
445
+ "invocation_id"
446
+ ],
447
+ "columnsTo": [
448
+ "id"
449
+ ],
450
+ "onDelete": "no action",
451
+ "onUpdate": "no action"
452
+ }
453
+ },
454
+ "compositePrimaryKeys": {},
455
+ "uniqueConstraints": {},
456
+ "policies": {},
457
+ "checkConstraints": {},
458
+ "isRLSEnabled": false
459
+ },
460
+ "agent_runtime.tool_call_audits": {
461
+ "name": "tool_call_audits",
462
+ "schema": "agent_runtime",
463
+ "columns": {
464
+ "id": {
465
+ "name": "id",
466
+ "type": "bigint",
467
+ "primaryKey": true,
468
+ "notNull": true,
469
+ "identity": {
470
+ "type": "always",
471
+ "name": "tool_call_audits_id_seq",
472
+ "schema": "agent_runtime",
473
+ "increment": "1",
474
+ "startWith": "1",
475
+ "minValue": "1",
476
+ "maxValue": "9223372036854775807",
477
+ "cache": "1",
478
+ "cycle": false
479
+ }
480
+ },
481
+ "invocation_id": {
482
+ "name": "invocation_id",
483
+ "type": "bigint",
484
+ "primaryKey": false,
485
+ "notNull": true
486
+ },
487
+ "scope": {
488
+ "name": "scope",
489
+ "type": "text",
490
+ "primaryKey": false,
491
+ "notNull": true
492
+ },
493
+ "run_id": {
494
+ "name": "run_id",
495
+ "type": "uuid",
496
+ "primaryKey": false,
497
+ "notNull": false
498
+ },
499
+ "tool_name": {
500
+ "name": "tool_name",
501
+ "type": "text",
502
+ "primaryKey": false,
503
+ "notNull": true
504
+ },
505
+ "idempotency_key": {
506
+ "name": "idempotency_key",
507
+ "type": "text",
508
+ "primaryKey": false,
509
+ "notNull": false
510
+ },
511
+ "status": {
512
+ "name": "status",
513
+ "type": "tool_call_status",
514
+ "typeSchema": "agent_runtime",
515
+ "primaryKey": false,
516
+ "notNull": true
517
+ },
518
+ "requested_at": {
519
+ "name": "requested_at",
520
+ "type": "timestamp with time zone",
521
+ "primaryKey": false,
522
+ "notNull": true,
523
+ "default": "now()"
524
+ },
525
+ "completed_at": {
526
+ "name": "completed_at",
527
+ "type": "timestamp with time zone",
528
+ "primaryKey": false,
529
+ "notNull": false
530
+ },
531
+ "error_code": {
532
+ "name": "error_code",
533
+ "type": "text",
534
+ "primaryKey": false,
535
+ "notNull": false
536
+ },
537
+ "request_snapshot": {
538
+ "name": "request_snapshot",
539
+ "type": "jsonb",
540
+ "primaryKey": false,
541
+ "notNull": false
542
+ },
543
+ "metadata": {
544
+ "name": "metadata",
545
+ "type": "jsonb",
546
+ "primaryKey": false,
547
+ "notNull": false
548
+ },
549
+ "created_at": {
550
+ "name": "created_at",
551
+ "type": "timestamp with time zone",
552
+ "primaryKey": false,
553
+ "notNull": true,
554
+ "default": "now()"
555
+ }
556
+ },
557
+ "indexes": {
558
+ "tool_call_audits_scope_tool_idempotency_unique": {
559
+ "name": "tool_call_audits_scope_tool_idempotency_unique",
560
+ "columns": [
561
+ {
562
+ "expression": "scope",
563
+ "isExpression": false,
564
+ "asc": true,
565
+ "nulls": "last"
566
+ },
567
+ {
568
+ "expression": "tool_name",
569
+ "isExpression": false,
570
+ "asc": true,
571
+ "nulls": "last"
572
+ },
573
+ {
574
+ "expression": "idempotency_key",
575
+ "isExpression": false,
576
+ "asc": true,
577
+ "nulls": "last"
578
+ }
579
+ ],
580
+ "isUnique": true,
581
+ "where": "\"agent_runtime\".\"tool_call_audits\".\"idempotency_key\" is not null",
582
+ "concurrently": false,
583
+ "method": "btree",
584
+ "with": {}
585
+ },
586
+ "tool_call_audits_invocation_idx": {
587
+ "name": "tool_call_audits_invocation_idx",
588
+ "columns": [
589
+ {
590
+ "expression": "invocation_id",
591
+ "isExpression": false,
592
+ "asc": true,
593
+ "nulls": "last"
594
+ }
595
+ ],
596
+ "isUnique": false,
597
+ "concurrently": false,
598
+ "method": "btree",
599
+ "with": {}
600
+ },
601
+ "tool_call_audits_run_idx": {
602
+ "name": "tool_call_audits_run_idx",
603
+ "columns": [
604
+ {
605
+ "expression": "run_id",
606
+ "isExpression": false,
607
+ "asc": true,
608
+ "nulls": "last"
609
+ }
610
+ ],
611
+ "isUnique": false,
612
+ "concurrently": false,
613
+ "method": "btree",
614
+ "with": {}
615
+ }
616
+ },
617
+ "foreignKeys": {
618
+ "tool_call_audits_invocation_id_invocations_id_fk": {
619
+ "name": "tool_call_audits_invocation_id_invocations_id_fk",
620
+ "tableFrom": "tool_call_audits",
621
+ "tableTo": "invocations",
622
+ "schemaTo": "agent_runtime",
623
+ "columnsFrom": [
624
+ "invocation_id"
625
+ ],
626
+ "columnsTo": [
627
+ "id"
628
+ ],
629
+ "onDelete": "no action",
630
+ "onUpdate": "no action"
631
+ }
632
+ },
633
+ "compositePrimaryKeys": {},
634
+ "uniqueConstraints": {},
635
+ "policies": {},
636
+ "checkConstraints": {},
637
+ "isRLSEnabled": false
638
+ },
639
+ "agent_runtime.worker_leases": {
640
+ "name": "worker_leases",
641
+ "schema": "agent_runtime",
642
+ "columns": {
643
+ "name": {
644
+ "name": "name",
645
+ "type": "text",
646
+ "primaryKey": true,
647
+ "notNull": true
648
+ },
649
+ "holder_id": {
650
+ "name": "holder_id",
651
+ "type": "text",
652
+ "primaryKey": false,
653
+ "notNull": true
654
+ },
655
+ "acquired_at": {
656
+ "name": "acquired_at",
657
+ "type": "timestamp with time zone",
658
+ "primaryKey": false,
659
+ "notNull": true,
660
+ "default": "now()"
661
+ },
662
+ "heartbeat_at": {
663
+ "name": "heartbeat_at",
664
+ "type": "timestamp with time zone",
665
+ "primaryKey": false,
666
+ "notNull": true,
667
+ "default": "now()"
668
+ },
669
+ "expires_at": {
670
+ "name": "expires_at",
671
+ "type": "timestamp with time zone",
672
+ "primaryKey": false,
673
+ "notNull": true
674
+ }
675
+ },
676
+ "indexes": {},
677
+ "foreignKeys": {},
678
+ "compositePrimaryKeys": {},
679
+ "uniqueConstraints": {},
680
+ "policies": {},
681
+ "checkConstraints": {},
682
+ "isRLSEnabled": false
683
+ }
684
+ },
685
+ "enums": {
686
+ "agent_runtime.invocation_status": {
687
+ "name": "invocation_status",
688
+ "schema": "agent_runtime",
689
+ "values": [
690
+ "pending",
691
+ "running",
692
+ "awaiting_approval",
693
+ "succeeded",
694
+ "failed",
695
+ "cancelled"
696
+ ]
697
+ },
698
+ "agent_runtime.tool_call_status": {
699
+ "name": "tool_call_status",
700
+ "schema": "agent_runtime",
701
+ "values": [
702
+ "started",
703
+ "succeeded",
704
+ "failed"
705
+ ]
706
+ }
707
+ },
708
+ "schemas": {
709
+ "agent_runtime": "agent_runtime"
710
+ },
711
+ "sequences": {},
712
+ "roles": {},
713
+ "policies": {},
714
+ "views": {},
715
+ "_meta": {
716
+ "columns": {},
717
+ "schemas": {},
718
+ "tables": {}
719
+ }
720
+ }