@hearsay-tools/squawk 0.18.0-dev.7406 → 0.18.0-dev.7412

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.
Files changed (94) hide show
  1. package/dist/ci-wait/controller.d.ts +46 -46
  2. package/dist/ci-wait/tools.d.ts +4 -4
  3. package/dist/contract/delegation.d.ts +30 -0
  4. package/dist/contract/index.js +10 -0
  5. package/dist/contract/runs.d.ts +48 -0
  6. package/dist/delegation/capacity.d.ts +7 -1
  7. package/dist/delegation/capacity.js +21 -12
  8. package/dist/delegation/capacity.js.map +1 -1
  9. package/dist/delegation/conversation-send.d.ts +3 -10
  10. package/dist/delegation/conversation-send.js +4 -3
  11. package/dist/delegation/conversation-send.js.map +1 -1
  12. package/dist/delegation/conversations.d.ts +18 -2175
  13. package/dist/delegation/conversations.js +47 -62
  14. package/dist/delegation/conversations.js.map +1 -1
  15. package/dist/delegation/policy.d.ts +7 -4
  16. package/dist/delegation/policy.js +29 -27
  17. package/dist/delegation/policy.js.map +1 -1
  18. package/dist/delegation/readiness.js +3 -2
  19. package/dist/delegation/readiness.js.map +1 -1
  20. package/dist/delegation/routes.d.ts +75 -75
  21. package/dist/delegation/service.d.ts +4 -9
  22. package/dist/delegation/service.js +65 -78
  23. package/dist/delegation/service.js.map +1 -1
  24. package/dist/delegation/task-discovery.js +3 -3
  25. package/dist/delegation/task-discovery.js.map +1 -1
  26. package/dist/delegation/transport.d.ts +79 -79
  27. package/dist/runs/delegation-state.d.ts +16 -0
  28. package/dist/runs/run-exits.d.ts +60 -0
  29. package/dist/runs/store.d.ts +98 -72
  30. package/dist/runs/task-rights.d.ts +68 -0
  31. package/dist/runs/task-rights.js +108 -0
  32. package/dist/runs/task-rights.js.map +1 -0
  33. package/dist/server/activity-routes.d.ts +23 -23
  34. package/dist/server/live-routes.d.ts +6 -6
  35. package/dist/server/reports-api.d.ts +2 -2
  36. package/dist/server/server.d.ts +3088 -2908
  37. package/dist/server/workspace-live-routes.d.ts +6 -6
  38. package/dist/workflows/continuation-admission.d.ts +10 -0
  39. package/dist/workflows/input-acknowledgement.d.ts +24 -24
  40. package/dist/workflows/run/completion-gate.js +9 -10
  41. package/dist/workflows/run/completion-gate.js.map +1 -1
  42. package/dist/workflows/run/run-finish.js +4 -3
  43. package/dist/workflows/run/run-finish.js.map +1 -1
  44. package/dist/workflows/run/wait-engine.d.ts +82 -72
  45. package/dist/workflows/run/wait-registry.js +2 -2
  46. package/dist/workflows/run/wait-registry.js.map +1 -1
  47. package/dist/workflows/wait-scope.d.ts +6 -8
  48. package/dist/workflows/wait-scope.js +13 -14
  49. package/dist/workflows/wait-scope.js.map +1 -1
  50. package/package.json +4 -4
  51. package/web/dist/assets/{activity-motion-GWiNidwF.js → activity-motion-CjiZJB7H.js} +1 -1
  52. package/web/dist/assets/{activity-route-ByFh99Eo.js → activity-route-1W0U2NqM.js} +1 -1
  53. package/web/dist/assets/{agent-accounts-BDB73Hg9.js → agent-accounts-DJbSC2sB.js} +1 -1
  54. package/web/dist/assets/attention-BdI3xSwD.js +1 -0
  55. package/web/dist/assets/{cez-idle-DreV5r0B.js → cez-idle-CKE0WtrH.js} +1 -1
  56. package/web/dist/assets/{commit-diff-panel-CM6ogknc.js → commit-diff-panel-DkvsBvlr.js} +1 -1
  57. package/web/dist/assets/{diff-BU25IR0d.js → diff-BCSgE1l6.js} +2 -2
  58. package/web/dist/assets/{diff-view-CnGdaz-L.js → diff-view-B3eMq9Uw.js} +1 -1
  59. package/web/dist/assets/{file-preview-COpe5-X0.js → file-preview-BIHQ0YTn.js} +1 -1
  60. package/web/dist/assets/{git-toolbar-CMH0kDal.js → git-toolbar-BtU7xtmD.js} +1 -1
  61. package/web/dist/assets/{github-JeDKhIAK.js → github-INQcTy36.js} +1 -1
  62. package/web/dist/assets/{global-activity-route-x2Xn5g2h.js → global-activity-route-B3-2eIFG.js} +1 -1
  63. package/web/dist/assets/{index-3JtARe0j.js → index-DUuc-42H.js} +4 -4
  64. package/web/dist/assets/{live-protocol-kUxhOnN1.js → live-protocol-B5jzpJgG.js} +1 -1
  65. package/web/dist/assets/{markdown-BDuLh9lK.js → markdown-DcRzCfVU.js} +1 -1
  66. package/web/dist/assets/{picker-pill-DpZKt_In.js → picker-pill-x0hXGTLP.js} +1 -1
  67. package/web/dist/assets/{preview-pane-connected-CwYbRQfS.js → preview-pane-connected-CCHDk6rz.js} +1 -1
  68. package/web/dist/assets/{project-router-DNqfLxdJ.js → project-router-_V9XDi3p.js} +1 -1
  69. package/web/dist/assets/{project-scope-context-CFEoNQTg.js → project-scope-context-VENshCVj.js} +1 -1
  70. package/web/dist/assets/{prompt-template-menu-DPEauS3z.js → prompt-template-menu-C60uqznw.js} +1 -1
  71. package/web/dist/assets/{queries-mk7hUEKT.js → queries-r1Fc1fWN.js} +1 -1
  72. package/web/dist/assets/{reference-chip-DQtQZJaX.js → reference-chip-GElOouoU.js} +1 -1
  73. package/web/dist/assets/{repo-git-CcfbTImd.js → repo-git-B09hWAxY.js} +1 -1
  74. package/web/dist/assets/{report-reader-CWXDg8JE.js → report-reader-y4t2Prir.js} +1 -1
  75. package/web/dist/assets/{reports-Bau_TxUs.js → reports-BU3a_4kU.js} +1 -1
  76. package/web/dist/assets/{run-header-C5wDUTls.js → run-header-BZukpHEK.js} +1 -1
  77. package/web/dist/assets/{skills-CFl4V447.js → skills-C6V0Yo95.js} +1 -1
  78. package/web/dist/assets/{tab-link-B7SjdDeU.js → tab-link-CuL027Wh.js} +1 -1
  79. package/web/dist/assets/{task-changes-Dnprgwc1.js → task-changes-Dx9OTRkk.js} +1 -1
  80. package/web/dist/assets/{task-commits-B0SApZKn.js → task-commits-ClWR4wQR.js} +1 -1
  81. package/web/dist/assets/{task-files-B_mLju-K.js → task-files-DCkrdsrz.js} +1 -1
  82. package/web/dist/assets/{task-github-item-BUoUh8t0.js → task-github-item-C3D4vDw7.js} +1 -1
  83. package/web/dist/assets/{task-thread-BQi3cH3M.js → task-thread-D0sTMg9h.js} +1 -1
  84. package/web/dist/assets/{thread-state-BOUrIjKm.js → thread-state-BHSYtS79.js} +1 -1
  85. package/web/dist/assets/{use-desktop-CkqdpZt0.js → use-desktop-BnWAyH1e.js} +1 -1
  86. package/web/dist/assets/{use-hand-to-agent-state-PCPwKRR0.js → use-hand-to-agent-state-VmvgZIh6.js} +1 -1
  87. package/web/dist/assets/{useInfiniteQuery-BL1dhFBm.js → useInfiniteQuery-DbCUWSLK.js} +1 -1
  88. package/web/dist/assets/useQuery-CxWGWuW4.js +1 -0
  89. package/web/dist/assets/{workflows-BRZR4pVb.js → workflows-B_HWC2FT.js} +1 -1
  90. package/web/dist/assets/{ws-DX0R2MDS.js → ws-jytXIi1s.js} +1 -1
  91. package/web/dist/index.html +15 -15
  92. package/web/dist/live-worker.js +1 -1
  93. package/web/dist/assets/attention-FrfXSNio.js +0 -1
  94. package/web/dist/assets/useQuery-B12MHZfS.js +0 -1
@@ -216,6 +216,11 @@ export declare const RUN_EXITS: {
216
216
  }[];
217
217
  } | undefined;
218
218
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
219
+ spawnGrant?: {
220
+ kinds: ("owned-isolated" | "shared")[];
221
+ live: number;
222
+ children?: /*elided*/ any | undefined;
223
+ } | undefined;
219
224
  receipts: {
220
225
  requestId: string;
221
226
  workerId: string;
@@ -356,6 +361,11 @@ export declare const RUN_EXITS: {
356
361
  wakeId?: string | undefined;
357
362
  } | undefined;
358
363
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
364
+ spawnGrant?: {
365
+ kinds: ("owned-isolated" | "shared")[];
366
+ live: number;
367
+ children?: any | undefined;
368
+ } | undefined;
359
369
  parentRunId: string;
360
370
  workspace: {
361
371
  ownerRunId: string;
@@ -943,6 +953,11 @@ export declare const RUN_EXITS: {
943
953
  }[];
944
954
  } | undefined;
945
955
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
956
+ spawnGrant?: {
957
+ kinds: ("owned-isolated" | "shared")[];
958
+ live: number;
959
+ children?: /*elided*/ any | undefined;
960
+ } | undefined;
946
961
  receipts: {
947
962
  requestId: string;
948
963
  workerId: string;
@@ -1083,6 +1098,11 @@ export declare const RUN_EXITS: {
1083
1098
  wakeId?: string | undefined;
1084
1099
  } | undefined;
1085
1100
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
1101
+ spawnGrant?: {
1102
+ kinds: ("owned-isolated" | "shared")[];
1103
+ live: number;
1104
+ children?: any | undefined;
1105
+ } | undefined;
1086
1106
  parentRunId: string;
1087
1107
  workspace: {
1088
1108
  ownerRunId: string;
@@ -1711,6 +1731,11 @@ export declare const RUN_EXITS: {
1711
1731
  }[];
1712
1732
  } | undefined;
1713
1733
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
1734
+ spawnGrant?: {
1735
+ kinds: ("owned-isolated" | "shared")[];
1736
+ live: number;
1737
+ children?: /*elided*/ any | undefined;
1738
+ } | undefined;
1714
1739
  receipts: {
1715
1740
  requestId: string;
1716
1741
  workerId: string;
@@ -1851,6 +1876,11 @@ export declare const RUN_EXITS: {
1851
1876
  wakeId?: string | undefined;
1852
1877
  } | undefined;
1853
1878
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
1879
+ spawnGrant?: {
1880
+ kinds: ("owned-isolated" | "shared")[];
1881
+ live: number;
1882
+ children?: any | undefined;
1883
+ } | undefined;
1854
1884
  parentRunId: string;
1855
1885
  workspace: {
1856
1886
  ownerRunId: string;
@@ -2788,6 +2818,11 @@ export declare const RUN_EXITS: {
2788
2818
  }[];
2789
2819
  } | undefined;
2790
2820
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
2821
+ spawnGrant?: {
2822
+ kinds: ("owned-isolated" | "shared")[];
2823
+ live: number;
2824
+ children?: any | undefined;
2825
+ } | undefined;
2791
2826
  receipts: {
2792
2827
  requestId: string;
2793
2828
  workerId: string;
@@ -2928,6 +2963,11 @@ export declare const RUN_EXITS: {
2928
2963
  wakeId?: string | undefined;
2929
2964
  } | undefined;
2930
2965
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
2966
+ spawnGrant?: {
2967
+ kinds: ("owned-isolated" | "shared")[];
2968
+ live: number;
2969
+ children?: any | undefined;
2970
+ } | undefined;
2931
2971
  parentRunId: string;
2932
2972
  workspace: {
2933
2973
  ownerRunId: string;
@@ -3879,6 +3919,11 @@ export declare const RUN_EXITS: {
3879
3919
  }[];
3880
3920
  } | undefined;
3881
3921
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
3922
+ spawnGrant?: {
3923
+ kinds: ("owned-isolated" | "shared")[];
3924
+ live: number;
3925
+ children?: /*elided*/ any | undefined;
3926
+ } | undefined;
3882
3927
  receipts: {
3883
3928
  requestId: string;
3884
3929
  workerId: string;
@@ -4019,6 +4064,11 @@ export declare const RUN_EXITS: {
4019
4064
  wakeId?: string | undefined;
4020
4065
  } | undefined;
4021
4066
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
4067
+ spawnGrant?: {
4068
+ kinds: ("owned-isolated" | "shared")[];
4069
+ live: number;
4070
+ children?: any | undefined;
4071
+ } | undefined;
4022
4072
  parentRunId: string;
4023
4073
  workspace: {
4024
4074
  ownerRunId: string;
@@ -4964,6 +5014,11 @@ export declare const RUN_EXITS: {
4964
5014
  }[];
4965
5015
  } | undefined;
4966
5016
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
5017
+ spawnGrant?: {
5018
+ kinds: ("owned-isolated" | "shared")[];
5019
+ live: number;
5020
+ children?: /*elided*/ any | undefined;
5021
+ } | undefined;
4967
5022
  receipts: {
4968
5023
  requestId: string;
4969
5024
  workerId: string;
@@ -5104,6 +5159,11 @@ export declare const RUN_EXITS: {
5104
5159
  wakeId?: string | undefined;
5105
5160
  } | undefined;
5106
5161
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
5162
+ spawnGrant?: {
5163
+ kinds: ("owned-isolated" | "shared")[];
5164
+ live: number;
5165
+ children?: any | undefined;
5166
+ } | undefined;
5107
5167
  parentRunId: string;
5108
5168
  workspace: {
5109
5169
  ownerRunId: string;
@@ -1516,6 +1516,14 @@ export declare const runRecordSchema: z.ZodObject<{
1516
1516
  stop: "stop";
1517
1517
  wait: "wait";
1518
1518
  }>>;
1519
+ spawnGrant: z.ZodOptional<z.ZodObject<{
1520
+ kinds: z.ZodArray<z.ZodEnum<{
1521
+ "owned-isolated": "owned-isolated";
1522
+ shared: "shared";
1523
+ }>>;
1524
+ live: z.ZodNumber;
1525
+ children: z.ZodOptional<z.ZodObject</*elided*/ any, z.core.$strict>>;
1526
+ }, z.core.$strict>>;
1519
1527
  receipts: z.ZodArray<z.ZodObject<{
1520
1528
  requestId: z.ZodUUID;
1521
1529
  workerId: z.ZodUUID;
@@ -1798,6 +1806,14 @@ export declare const runRecordSchema: z.ZodObject<{
1798
1806
  stop: "stop";
1799
1807
  wait: "wait";
1800
1808
  }>>;
1809
+ spawnGrant: z.ZodOptional<z.ZodObject<{
1810
+ kinds: z.ZodArray<z.ZodEnum<{
1811
+ "owned-isolated": "owned-isolated";
1812
+ shared: "shared";
1813
+ }>>;
1814
+ live: z.ZodNumber;
1815
+ children: z.ZodOptional<z.ZodObject<any, z.core.$strict>>;
1816
+ }, z.core.$strict>>;
1801
1817
  parentRunId: z.ZodUUID;
1802
1818
  workspace: z.ZodDiscriminatedUnion<[z.ZodObject<{
1803
1819
  ownerRunId: z.ZodUUID;
@@ -2172,6 +2188,30 @@ export declare function parseRunRecords(raw: unknown): z.ZodSafeParseResult<{
2172
2188
  deadline: string;
2173
2189
  seconds: number;
2174
2190
  note?: string | undefined;
2191
+ } | {
2192
+ id: string;
2193
+ source: "agent" | "cezar";
2194
+ via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
2195
+ registeredAt: string;
2196
+ phase: "cancelled" | "delivered" | "open" | "resolved";
2197
+ resolvedAt?: string | undefined;
2198
+ deliveredAt?: string | undefined;
2199
+ cancelledAt?: string | undefined;
2200
+ turnId: string;
2201
+ kind: "process";
2202
+ deadline: string;
2203
+ timeoutSeconds: number;
2204
+ pid: number;
2205
+ startToken?: string | undefined;
2206
+ exitFile?: string | undefined;
2207
+ note?: string | undefined;
2208
+ result?: {
2209
+ outcome: "deadline" | "error" | "exit_file" | "exited";
2210
+ observedAt: string;
2211
+ exitCode?: number | undefined;
2212
+ exitFileNote?: "not-an-exit-code" | undefined;
2213
+ diagnostic?: string | undefined;
2214
+ } | undefined;
2175
2215
  } | {
2176
2216
  id: string;
2177
2217
  source: "agent" | "cezar";
@@ -2232,30 +2272,6 @@ export declare function parseRunRecords(raw: unknown): z.ZodSafeParseResult<{
2232
2272
  reason: "outcome" | "timeout";
2233
2273
  } | undefined;
2234
2274
  wakeInputId?: string | undefined;
2235
- } | {
2236
- id: string;
2237
- source: "agent" | "cezar";
2238
- via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
2239
- registeredAt: string;
2240
- phase: "cancelled" | "delivered" | "open" | "resolved";
2241
- resolvedAt?: string | undefined;
2242
- deliveredAt?: string | undefined;
2243
- cancelledAt?: string | undefined;
2244
- turnId: string;
2245
- kind: "process";
2246
- deadline: string;
2247
- timeoutSeconds: number;
2248
- pid: number;
2249
- startToken?: string | undefined;
2250
- exitFile?: string | undefined;
2251
- note?: string | undefined;
2252
- result?: {
2253
- outcome: "deadline" | "error" | "exit_file" | "exited";
2254
- observedAt: string;
2255
- exitCode?: number | undefined;
2256
- exitFileNote?: "not-an-exit-code" | undefined;
2257
- diagnostic?: string | undefined;
2258
- } | undefined;
2259
2275
  } | {
2260
2276
  id: string;
2261
2277
  source: "agent" | "cezar";
@@ -2366,6 +2382,30 @@ export declare function parseRunRecords(raw: unknown): z.ZodSafeParseResult<{
2366
2382
  deadline: string;
2367
2383
  seconds: number;
2368
2384
  note?: string | undefined;
2385
+ } | {
2386
+ id: string;
2387
+ source: "agent" | "cezar";
2388
+ via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
2389
+ registeredAt: string;
2390
+ phase: "cancelled" | "delivered" | "open" | "resolved";
2391
+ resolvedAt?: string | undefined;
2392
+ deliveredAt?: string | undefined;
2393
+ cancelledAt?: string | undefined;
2394
+ turnId: string;
2395
+ kind: "process";
2396
+ deadline: string;
2397
+ timeoutSeconds: number;
2398
+ pid: number;
2399
+ startToken?: string | undefined;
2400
+ exitFile?: string | undefined;
2401
+ note?: string | undefined;
2402
+ result?: {
2403
+ outcome: "deadline" | "error" | "exit_file" | "exited";
2404
+ observedAt: string;
2405
+ exitCode?: number | undefined;
2406
+ exitFileNote?: "not-an-exit-code" | undefined;
2407
+ diagnostic?: string | undefined;
2408
+ } | undefined;
2369
2409
  } | {
2370
2410
  id: string;
2371
2411
  source: "agent" | "cezar";
@@ -2426,30 +2466,6 @@ export declare function parseRunRecords(raw: unknown): z.ZodSafeParseResult<{
2426
2466
  reason: "outcome" | "timeout";
2427
2467
  } | undefined;
2428
2468
  wakeInputId?: string | undefined;
2429
- } | {
2430
- id: string;
2431
- source: "agent" | "cezar";
2432
- via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
2433
- registeredAt: string;
2434
- phase: "cancelled" | "delivered" | "open" | "resolved";
2435
- resolvedAt?: string | undefined;
2436
- deliveredAt?: string | undefined;
2437
- cancelledAt?: string | undefined;
2438
- turnId: string;
2439
- kind: "process";
2440
- deadline: string;
2441
- timeoutSeconds: number;
2442
- pid: number;
2443
- startToken?: string | undefined;
2444
- exitFile?: string | undefined;
2445
- note?: string | undefined;
2446
- result?: {
2447
- outcome: "deadline" | "error" | "exit_file" | "exited";
2448
- observedAt: string;
2449
- exitCode?: number | undefined;
2450
- exitFileNote?: "not-an-exit-code" | undefined;
2451
- diagnostic?: string | undefined;
2452
- } | undefined;
2453
2469
  } | {
2454
2470
  id: string;
2455
2471
  source: "agent" | "cezar";
@@ -2559,6 +2575,30 @@ export declare function parseRunRecords(raw: unknown): z.ZodSafeParseResult<{
2559
2575
  deadline: string;
2560
2576
  seconds: number;
2561
2577
  note?: string | undefined;
2578
+ } | {
2579
+ id: string;
2580
+ source: "agent" | "cezar";
2581
+ via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
2582
+ registeredAt: string;
2583
+ phase: "cancelled" | "delivered" | "open" | "resolved";
2584
+ resolvedAt?: string | undefined;
2585
+ deliveredAt?: string | undefined;
2586
+ cancelledAt?: string | undefined;
2587
+ turnId: string;
2588
+ kind: "process";
2589
+ deadline: string;
2590
+ timeoutSeconds: number;
2591
+ pid: number;
2592
+ startToken?: string | undefined;
2593
+ exitFile?: string | undefined;
2594
+ note?: string | undefined;
2595
+ result?: {
2596
+ outcome: "deadline" | "error" | "exit_file" | "exited";
2597
+ observedAt: string;
2598
+ exitCode?: number | undefined;
2599
+ exitFileNote?: "not-an-exit-code" | undefined;
2600
+ diagnostic?: string | undefined;
2601
+ } | undefined;
2562
2602
  } | {
2563
2603
  id: string;
2564
2604
  source: "agent" | "cezar";
@@ -2619,30 +2659,6 @@ export declare function parseRunRecords(raw: unknown): z.ZodSafeParseResult<{
2619
2659
  reason: "outcome" | "timeout";
2620
2660
  } | undefined;
2621
2661
  wakeInputId?: string | undefined;
2622
- } | {
2623
- id: string;
2624
- source: "agent" | "cezar";
2625
- via: "ask-line" | "budget" | "cez-message-wait" | "cez-worker-wait" | "cezar_ask" | "cezar_wait" | "cezar_wait_for_ci" | "completion" | "monitoring-line" | "native-ask" | "native-subagents" | "no-wait" | "schedule-wakeup";
2626
- registeredAt: string;
2627
- phase: "cancelled" | "delivered" | "open" | "resolved";
2628
- resolvedAt?: string | undefined;
2629
- deliveredAt?: string | undefined;
2630
- cancelledAt?: string | undefined;
2631
- turnId: string;
2632
- kind: "process";
2633
- deadline: string;
2634
- timeoutSeconds: number;
2635
- pid: number;
2636
- startToken?: string | undefined;
2637
- exitFile?: string | undefined;
2638
- note?: string | undefined;
2639
- result?: {
2640
- outcome: "deadline" | "error" | "exit_file" | "exited";
2641
- observedAt: string;
2642
- exitCode?: number | undefined;
2643
- exitFileNote?: "not-an-exit-code" | undefined;
2644
- diagnostic?: string | undefined;
2645
- } | undefined;
2646
2662
  } | {
2647
2663
  id: string;
2648
2664
  source: "agent" | "cezar";
@@ -2804,6 +2820,11 @@ export declare function parseRunRecords(raw: unknown): z.ZodSafeParseResult<{
2804
2820
  }[];
2805
2821
  } | undefined;
2806
2822
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
2823
+ spawnGrant?: {
2824
+ kinds: ("owned-isolated" | "shared")[];
2825
+ live: number;
2826
+ children?: /*elided*/ any | undefined;
2827
+ } | undefined;
2807
2828
  receipts: {
2808
2829
  requestId: string;
2809
2830
  workerId: string;
@@ -2944,6 +2965,11 @@ export declare function parseRunRecords(raw: unknown): z.ZodSafeParseResult<{
2944
2965
  wakeId?: string | undefined;
2945
2966
  } | undefined;
2946
2967
  permissions: ("destroy" | "diff" | "inspect" | "spawn" | "steer" | "stop" | "wait")[];
2968
+ spawnGrant?: {
2969
+ kinds: ("owned-isolated" | "shared")[];
2970
+ live: number;
2971
+ children?: any | undefined;
2972
+ } | undefined;
2947
2973
  parentRunId: string;
2948
2974
  workspace: {
2949
2975
  ownerRunId: string;
@@ -0,0 +1,68 @@
1
+ import type { ConversationState, DelegationState, WorkerOperation } from '../contract/index.js';
2
+ import { type SpawnGrant, type WorkerWorkspace } from '../contract/index.js';
3
+ import type { RunRecord } from './store.ts';
4
+ /**
5
+ * Who may do what to whom (hearsay-tools/squawk#3819). A relation is a fact read from two records;
6
+ * a grant is data on the acting task's record. A spawn, an operation on a worker or a message is
7
+ * allowed when the relation exists and the actor's grant holds it. Lifecycle state (a parent that
8
+ * is not active, a pending Finish) is the caller's check; the per-task switches stay outside.
9
+ */
10
+ type RootDelegation = Extract<DelegationState, {
11
+ role: 'root';
12
+ }>;
13
+ /** The run that holds a family's receipts and its conversation ledger. */
14
+ export type FamilyRecord = RunRecord & {
15
+ delegation: RootDelegation;
16
+ };
17
+ export type Lookup = (id: string) => RunRecord | undefined;
18
+ /** `supervisor`: the other task supervises this one. `supervised`: this task supervises the other.
19
+ * `peer`: two root tasks of one project. */
20
+ export type TaskRelation = 'supervisor' | 'supervised' | 'peer';
21
+ export type TaskGrants = {
22
+ /** What the task may spawn; undefined when it may spawn nothing. */
23
+ readonly spawn: SpawnGrant | undefined;
24
+ /** The operations the task may apply to workers it supervises. */
25
+ readonly operate: readonly WorkerOperation[];
26
+ /** The relations the task may use to send a message. */
27
+ readonly message: readonly TaskRelation[];
28
+ };
29
+ /** What a record of each role holds when it stores no grant of its own. */
30
+ export declare const DEFAULT_GRANTS: Readonly<Record<'root' | 'worker', TaskGrants>>;
31
+ /** The grants a task holds: its stored ones, else its role's defaults. A task with no record, or
32
+ * a quarantined one, holds none. */
33
+ export declare function grantsOf(run: RunRecord | undefined): TaskGrants;
34
+ /** The spawn grant a worker of `parent` gets at its creation. */
35
+ export declare function childSpawnGrant(parent: RunRecord | undefined): SpawnGrant | undefined;
36
+ export declare function isFamilyRecord(run: RunRecord | undefined): run is FamilyRecord;
37
+ /** A root task: a family record, or a top-level run with no record yet, which has not opened a
38
+ * delegation session yet (spec 2026-10-27-task-communication-protocol § 2). */
39
+ export declare function isRootTask(run: RunRecord | undefined): run is RunRecord;
40
+ /** The run that supervises this one; undefined for a task nobody supervises. */
41
+ export declare function supervisorIdOf(run: RunRecord | undefined): string | undefined;
42
+ /** The run that holds this task's family record: a root holds its own. */
43
+ export declare function familyRecordIdOf(run: RunRecord | undefined): string | undefined;
44
+ export declare function familyRecordOf(run: RunRecord | undefined, getRun: Lookup): FamilyRecord | undefined;
45
+ /** The receipts a record holds; a run that is not a family record holds none. */
46
+ export declare function receiptsOf(run: RunRecord | undefined): RootDelegation['receipts'];
47
+ /** The ledger a record holds, once its first message is written. */
48
+ export declare function conversationOf(run: RunRecord | undefined): ConversationState | undefined;
49
+ /** A family record whose history deletion is pending. */
50
+ export declare function historyDeleting(run: RunRecord | undefined): boolean;
51
+ /** A task whose human pressed Finish, which has not settled yet. */
52
+ export declare function finishing(run: RunRecord | undefined): boolean;
53
+ /** The relation of `from` to `to`, from the two records alone. */
54
+ export declare function relationOf(from: RunRecord | undefined, to: RunRecord | undefined): TaskRelation | undefined;
55
+ export declare function holdsOperation(actor: RunRecord | undefined, operation: WorkerOperation): boolean;
56
+ /** `actor` supervises `target` and holds `operation`. */
57
+ export declare function mayOperate(actor: RunRecord | undefined, target: RunRecord | undefined, operation: WorkerOperation): boolean;
58
+ /** `actor` holds `spawn` and a spawn grant for `kind`; with no kind, for any kind. */
59
+ export declare function maySpawn(actor: RunRecord | undefined, kind?: WorkerWorkspace['kind']): boolean;
60
+ /** `actor`'s own limit: `outstanding` counts the workers it supervises that hold a slot. */
61
+ export declare function hasSpawnRoom(actor: RunRecord | undefined, outstanding: number): boolean;
62
+ /**
63
+ * The relation `from` may use to message `to`, or undefined. The message grant of `from` holds the
64
+ * relation, neither task's family record is deleting its history, and a supervised worker has a
65
+ * live receipt on its own family record. `getRun` finds a family record that neither task is.
66
+ */
67
+ export declare function messageRelation(from: RunRecord | undefined, to: RunRecord | undefined, getRun: Lookup): TaskRelation | undefined;
68
+ export {};
@@ -0,0 +1,108 @@
1
+ import { workerOperationSchema } from '../contract/index.js';
2
+ const NO_GRANTS = { spawn: undefined, operate: [], message: [] };
3
+ /** What a record of each role holds when it stores no grant of its own. */
4
+ export const DEFAULT_GRANTS = {
5
+ root: { spawn: { kinds: ['owned-isolated', 'shared'], live: 32 }, operate: workerOperationSchema.options, message: ['supervised', 'peer'] },
6
+ worker: { spawn: undefined, operate: [], message: ['supervisor', 'supervised'] },
7
+ };
8
+ /** The grants a task holds: its stored ones, else its role's defaults. A task with no record, or
9
+ * a quarantined one, holds none. */
10
+ export function grantsOf(run) {
11
+ const record = run?.delegation;
12
+ if (!record || record.role === 'invalid')
13
+ return NO_GRANTS;
14
+ const defaults = DEFAULT_GRANTS[record.role];
15
+ return { spawn: record.spawnGrant ?? defaults.spawn, operate: record.permissions, message: defaults.message };
16
+ }
17
+ /** The spawn grant a worker of `parent` gets at its creation. */
18
+ export function childSpawnGrant(parent) {
19
+ return grantsOf(parent).spawn?.children;
20
+ }
21
+ export function isFamilyRecord(run) {
22
+ return run?.delegation?.role === 'root';
23
+ }
24
+ /** A root task: a family record, or a top-level run with no record yet, which has not opened a
25
+ * delegation session yet (spec 2026-10-27-task-communication-protocol § 2). */
26
+ export function isRootTask(run) {
27
+ return !!run && (run.delegation === undefined || isFamilyRecord(run));
28
+ }
29
+ /** The run that supervises this one; undefined for a task nobody supervises. */
30
+ export function supervisorIdOf(run) {
31
+ return run?.delegation?.role === 'worker' ? run.delegation.parentRunId : undefined;
32
+ }
33
+ /** The run that holds this task's family record: a root holds its own. */
34
+ export function familyRecordIdOf(run) {
35
+ if (isFamilyRecord(run))
36
+ return run.id;
37
+ return run?.delegation?.role === 'worker' ? run.delegation.parentRunId : undefined;
38
+ }
39
+ export function familyRecordOf(run, getRun) {
40
+ if (isFamilyRecord(run))
41
+ return run;
42
+ const id = familyRecordIdOf(run);
43
+ const record = id === undefined ? undefined : getRun(id);
44
+ return isFamilyRecord(record) ? record : undefined;
45
+ }
46
+ /** The receipts a record holds; a run that is not a family record holds none. */
47
+ export function receiptsOf(run) {
48
+ return isFamilyRecord(run) ? run.delegation.receipts : [];
49
+ }
50
+ /** The ledger a record holds, once its first message is written. */
51
+ export function conversationOf(run) {
52
+ return isFamilyRecord(run) ? run.delegation.conversation : undefined;
53
+ }
54
+ /** A family record whose history deletion is pending. */
55
+ export function historyDeleting(run) {
56
+ return isFamilyRecord(run) && !!run.delegation.historyDeletion;
57
+ }
58
+ /** A task whose human pressed Finish, which has not settled yet. */
59
+ export function finishing(run) {
60
+ return isFamilyRecord(run) && !!run.delegation.finishRequestedAt;
61
+ }
62
+ function supervises(supervisor, worker) {
63
+ return supervisorIdOf(worker) === supervisor.id && worker.delegation?.role === 'worker' &&
64
+ worker.delegation.workspace?.ownerRunId === worker.id;
65
+ }
66
+ /** The relation of `from` to `to`, from the two records alone. */
67
+ export function relationOf(from, to) {
68
+ if (!from || !to || from.id === to.id)
69
+ return undefined;
70
+ if (supervises(to, from))
71
+ return 'supervisor';
72
+ if (supervises(from, to))
73
+ return 'supervised';
74
+ return isRootTask(from) && isRootTask(to) ? 'peer' : undefined;
75
+ }
76
+ export function holdsOperation(actor, operation) {
77
+ return grantsOf(actor).operate.includes(operation);
78
+ }
79
+ /** `actor` supervises `target` and holds `operation`. */
80
+ export function mayOperate(actor, target, operation) {
81
+ return relationOf(actor, target) === 'supervised' && holdsOperation(actor, operation);
82
+ }
83
+ /** `actor` holds `spawn` and a spawn grant for `kind`; with no kind, for any kind. */
84
+ export function maySpawn(actor, kind) {
85
+ const kinds = grantsOf(actor).spawn?.kinds ?? [];
86
+ return holdsOperation(actor, 'spawn') && (kind === undefined ? kinds.length > 0 : kinds.includes(kind));
87
+ }
88
+ /** `actor`'s own limit: `outstanding` counts the workers it supervises that hold a slot. */
89
+ export function hasSpawnRoom(actor, outstanding) {
90
+ return outstanding < (grantsOf(actor).spawn?.live ?? 0);
91
+ }
92
+ /**
93
+ * The relation `from` may use to message `to`, or undefined. The message grant of `from` holds the
94
+ * relation, neither task's family record is deleting its history, and a supervised worker has a
95
+ * live receipt on its own family record. `getRun` finds a family record that neither task is.
96
+ */
97
+ export function messageRelation(from, to, getRun) {
98
+ const relation = relationOf(from, to);
99
+ if (!relation || !grantsOf(from).message.includes(relation))
100
+ return undefined;
101
+ if ([from, to].some(run => historyDeleting(familyRecordOf(run, getRun))))
102
+ return undefined;
103
+ if (relation === 'peer')
104
+ return relation;
105
+ const worker = relation === 'supervised' ? to : from;
106
+ return receiptsOf(familyRecordOf(worker, getRun)).some(receipt => receipt.workerId === worker.id && !receipt.deletion) ? relation : undefined;
107
+ }
108
+ //# sourceMappingURL=task-rights.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"task-rights.js","sourceRoot":"","sources":["../../src/runs/task-rights.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,qBAAqB,EAAyC,MAAM,yCAAyC,CAAC;AAyBvH,MAAM,SAAS,GAAe,EAAE,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;AAC7E,2EAA2E;AAC3E,MAAM,CAAC,MAAM,cAAc,GAAoD;IAC7E,IAAI,EAAE,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,CAAC,gBAAgB,EAAE,QAAQ,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,EAAE,OAAO,EAAE,qBAAqB,CAAC,OAAO,EAAE,OAAO,EAAE,CAAC,YAAY,EAAE,MAAM,CAAC,EAAE;IAC3I,MAAM,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE,EAAE,OAAO,EAAE,CAAC,YAAY,EAAE,YAAY,CAAC,EAAE;CACjF,CAAC;AAEF;qCACqC;AACrC,MAAM,UAA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,CAAC,IAAI,CAAC,CAAC,CAAC;AAC1G,CAAC;AAED,4FAA4F;AAC5F,MAAM,UAAU,YAAY,CAAC,KAA4B,EAAE,WAAmB;IAC5E,OAAO,WAAW,GAAG,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,IAAI,IAAI,CAAC,CAAC,CAAC;AAC1D,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,eAAe,CAAC,IAA2B,EAAE,EAAyB,EAAE,MAAc;IACpG,MAAM,QAAQ,GAAG,UAAU,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;IACtC,IAAI,CAAC,QAAQ,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAC;QAAE,OAAO,SAAS,CAAC;IAC9E,IAAI,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,eAAe,CAAC,cAAc,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC,CAAC;QAAE,OAAO,SAAS,CAAC;IAC3F,IAAI,QAAQ,KAAK,MAAM;QAAE,OAAO,QAAQ,CAAC;IACzC,MAAM,MAAM,GAAG,QAAQ,KAAK,YAAY,CAAC,CAAC,CAAC,EAAG,CAAC,CAAC,CAAC,IAAK,CAAC;IACvD,OAAO,UAAU,CAAC,cAAc,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC,OAAO,CAAC,QAAQ,KAAK,MAAM,CAAC,EAAE,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC;AAChJ,CAAC"}
@@ -59,29 +59,6 @@ export declare function ciProgressPlugs(demand: ActivityDemand): {
59
59
  export declare function createActivityRoutes(routeDeps: ActivityRouteDeps): import("hono/hono-base").HonoBase<import("hono/types").BlankEnv, {
60
60
  "/workspace/activity": {
61
61
  $get: {
62
- output: {
63
- error: string;
64
- code?: "invalid_input" | undefined;
65
- };
66
- outputFormat: "json";
67
- status: 400;
68
- input: {
69
- query: {
70
- project?: string | undefined;
71
- };
72
- };
73
- } | {
74
- output: {
75
- error: string;
76
- };
77
- outputFormat: "json";
78
- status: 404 | 409 | 503;
79
- input: {
80
- query: {
81
- project?: string | undefined;
82
- };
83
- };
84
- } | {
85
62
  output: {
86
63
  generatedAt: string;
87
64
  projects: {
@@ -312,6 +289,29 @@ export declare function createActivityRoutes(routeDeps: ActivityRouteDeps): impo
312
289
  project?: string | undefined;
313
290
  };
314
291
  };
292
+ } | {
293
+ output: {
294
+ error: string;
295
+ code?: "invalid_input" | undefined;
296
+ };
297
+ outputFormat: "json";
298
+ status: 400;
299
+ input: {
300
+ query: {
301
+ project?: string | undefined;
302
+ };
303
+ };
304
+ } | {
305
+ output: {
306
+ error: string;
307
+ };
308
+ outputFormat: "json";
309
+ status: 404 | 409 | 503;
310
+ input: {
311
+ query: {
312
+ project?: string | undefined;
313
+ };
314
+ };
315
315
  };
316
316
  };
317
317
  }, "/", "/workspace/activity">;
@@ -16,6 +16,12 @@ export declare function createLiveRoutes({ resolveProject, serverGeneration, res
16
16
  output: {
17
17
  generation: string;
18
18
  results: ({
19
+ projectId: string;
20
+ runId: string;
21
+ type: "error" | "reset";
22
+ status: 400 | 404 | 409 | 413 | 503;
23
+ error: string;
24
+ } | {
19
25
  projectId: string;
20
26
  runId: string;
21
27
  type: "batch";
@@ -29,12 +35,6 @@ export declare function createLiveRoutes({ resolveProject, serverGeneration, res
29
35
  cursor: string;
30
36
  afterSeq: number;
31
37
  hasMore: boolean;
32
- } | {
33
- projectId: string;
34
- runId: string;
35
- type: "error" | "reset";
36
- status: 400 | 404 | 409 | 413 | 503;
37
- error: string;
38
38
  })[];
39
39
  };
40
40
  outputFormat: "json";
@@ -40,7 +40,7 @@ export declare const reportsRoutes: import("hono/hono-base").HonoBase<ProjectApi
40
40
  error: string;
41
41
  };
42
42
  outputFormat: "json";
43
- status: 409;
43
+ status: 400;
44
44
  input: {
45
45
  query: {
46
46
  q?: string | undefined;
@@ -53,7 +53,7 @@ export declare const reportsRoutes: import("hono/hono-base").HonoBase<ProjectApi
53
53
  error: string;
54
54
  };
55
55
  outputFormat: "json";
56
- status: 400;
56
+ status: 409;
57
57
  input: {
58
58
  query: {
59
59
  q?: string | undefined;