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