@claudexor/schema 2.1.3 → 3.0.1

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 (174) hide show
  1. package/dist/agent-capabilities.d.ts +32 -24
  2. package/dist/agent-capabilities.d.ts.map +1 -1
  3. package/dist/agent-capabilities.js +20 -11
  4. package/dist/agent-capabilities.js.map +1 -1
  5. package/dist/apply-eligibility.d.ts +166 -0
  6. package/dist/apply-eligibility.d.ts.map +1 -1
  7. package/dist/apply-eligibility.js +63 -2
  8. package/dist/apply-eligibility.js.map +1 -1
  9. package/dist/attachment.d.ts +5 -5
  10. package/dist/budget.d.ts +4 -4
  11. package/dist/config.d.ts +59 -41
  12. package/dist/config.d.ts.map +1 -1
  13. package/dist/config.js +16 -6
  14. package/dist/config.js.map +1 -1
  15. package/dist/context.d.ts +6 -6
  16. package/dist/control-operation-responses.d.ts +190 -97
  17. package/dist/control-operation-responses.d.ts.map +1 -1
  18. package/dist/control-operation-responses.js +14 -1
  19. package/dist/control-operation-responses.js.map +1 -1
  20. package/dist/control-run-detail.d.ts +347 -215
  21. package/dist/control-run-detail.d.ts.map +1 -1
  22. package/dist/control-run-detail.js +34 -7
  23. package/dist/control-run-detail.js.map +1 -1
  24. package/dist/control-thread-apply.d.ts +5 -5
  25. package/dist/control-trust.d.ts +6 -6
  26. package/dist/control.d.ts +769 -306
  27. package/dist/control.d.ts.map +1 -1
  28. package/dist/control.js +164 -61
  29. package/dist/control.js.map +1 -1
  30. package/dist/credential-profile.d.ts +400 -1
  31. package/dist/credential-profile.d.ts.map +1 -1
  32. package/dist/credential-profile.js +109 -4
  33. package/dist/credential-profile.js.map +1 -1
  34. package/dist/decision.d.ts +78 -14
  35. package/dist/decision.d.ts.map +1 -1
  36. package/dist/decision.js +53 -20
  37. package/dist/decision.js.map +1 -1
  38. package/dist/delivery.d.ts +3 -3
  39. package/dist/delivery.js +1 -1
  40. package/dist/delivery.js.map +1 -1
  41. package/dist/events.d.ts +32 -6
  42. package/dist/events.d.ts.map +1 -1
  43. package/dist/events.js +45 -11
  44. package/dist/events.js.map +1 -1
  45. package/dist/gate.d.ts +4 -4
  46. package/dist/gate.d.ts.map +1 -1
  47. package/dist/gate.js +2 -2
  48. package/dist/gate.js.map +1 -1
  49. package/dist/harness.d.ts +137 -47
  50. package/dist/harness.d.ts.map +1 -1
  51. package/dist/harness.js +65 -16
  52. package/dist/harness.js.map +1 -1
  53. package/dist/index.d.ts +4 -3
  54. package/dist/index.d.ts.map +1 -1
  55. package/dist/index.js +4 -3
  56. package/dist/index.js.map +1 -1
  57. package/dist/operation.d.ts +66 -7
  58. package/dist/operation.d.ts.map +1 -1
  59. package/dist/operation.js +29 -2
  60. package/dist/operation.js.map +1 -1
  61. package/dist/output-schema.d.ts +40 -0
  62. package/dist/output-schema.d.ts.map +1 -0
  63. package/dist/output-schema.js +109 -0
  64. package/dist/output-schema.js.map +1 -0
  65. package/dist/plan.d.ts +206 -0
  66. package/dist/plan.d.ts.map +1 -0
  67. package/dist/plan.js +107 -0
  68. package/dist/plan.js.map +1 -0
  69. package/dist/primitives.d.ts +14 -10
  70. package/dist/primitives.d.ts.map +1 -1
  71. package/dist/primitives.js +14 -11
  72. package/dist/primitives.js.map +1 -1
  73. package/dist/project.d.ts +75 -0
  74. package/dist/project.d.ts.map +1 -1
  75. package/dist/project.js +17 -0
  76. package/dist/project.js.map +1 -1
  77. package/dist/quota.d.ts +119 -0
  78. package/dist/quota.d.ts.map +1 -1
  79. package/dist/quota.js +22 -0
  80. package/dist/quota.js.map +1 -1
  81. package/dist/raw.d.ts +4 -4
  82. package/dist/readiness.d.ts +14 -7
  83. package/dist/readiness.d.ts.map +1 -1
  84. package/dist/run-strategy.d.ts +17 -0
  85. package/dist/run-strategy.d.ts.map +1 -0
  86. package/dist/run-strategy.js +47 -0
  87. package/dist/run-strategy.js.map +1 -0
  88. package/dist/setup.d.ts +160 -160
  89. package/dist/status-projection.d.ts +78 -0
  90. package/dist/status-projection.d.ts.map +1 -0
  91. package/dist/status-projection.js +171 -0
  92. package/dist/status-projection.js.map +1 -0
  93. package/dist/task.d.ts +48 -316
  94. package/dist/task.d.ts.map +1 -1
  95. package/dist/task.js +3 -60
  96. package/dist/task.js.map +1 -1
  97. package/dist/telemetry.d.ts +89 -89
  98. package/dist/thread.d.ts +167 -32
  99. package/dist/thread.d.ts.map +1 -1
  100. package/dist/thread.js +92 -28
  101. package/dist/thread.js.map +1 -1
  102. package/dist/tool-ref.d.ts +1 -1
  103. package/generated/AgentCapabilityCatalog.schema.json +4 -6
  104. package/generated/ApplyEligibility.schema.json +1 -1
  105. package/generated/BudgetLease.schema.json +1 -2
  106. package/generated/ConformanceReport.schema.json +1 -2
  107. package/generated/ContinuityDisclosure.schema.json +74 -0
  108. package/generated/ControlApplyRequest.schema.json +1 -2
  109. package/generated/ControlCredentialProfileUpdateRequest.schema.json +20 -0
  110. package/generated/ControlCredentialProfileUpdateResponse.schema.json +142 -0
  111. package/generated/ControlCredentialProfilesResponse.schema.json +126 -2
  112. package/generated/ControlDeliveryResponse.schema.json +0 -1
  113. package/generated/ControlHandshakeResponse.schema.json +31 -3
  114. package/generated/ControlHarnessListResponse.schema.json +11 -6
  115. package/generated/ControlHarnessSettingsPatch.schema.json +4 -0
  116. package/generated/ControlOperationCatalog.schema.json +16 -1
  117. package/generated/ControlOperationDescriptor.schema.json +15 -0
  118. package/generated/ControlProject.schema.json +35 -0
  119. package/generated/ControlProjectListResponse.schema.json +35 -0
  120. package/generated/ControlProjectOutputsResponse.schema.json +57 -0
  121. package/generated/ControlQueuedRunInfo.schema.json +2 -11
  122. package/generated/ControlQuotaResponse.schema.json +42 -0
  123. package/generated/ControlRunAgainDraft.schema.json +37 -35
  124. package/generated/ControlRunDecisionRequest.schema.json +0 -1
  125. package/generated/ControlRunDetail.schema.json +292 -213
  126. package/generated/ControlRunListResponse.schema.json +88 -27
  127. package/generated/ControlRunStartRequest.schema.json +37 -35
  128. package/generated/ControlRunStartResponse.schema.json +2 -11
  129. package/generated/ControlRunSummary.schema.json +88 -27
  130. package/generated/ControlSettingsSnapshot.schema.json +6 -11
  131. package/generated/ControlSettingsUpdateRequest.schema.json +5 -10
  132. package/generated/ControlThread.schema.json +21 -3
  133. package/generated/ControlThreadApplyResponse.schema.json +0 -1
  134. package/generated/ControlThreadCreateRequest.schema.json +12 -3
  135. package/generated/ControlThreadDetail.schema.json +174 -16
  136. package/generated/ControlThreadListResponse.schema.json +60 -3
  137. package/generated/ControlThreadTurnRequest.schema.json +40 -34
  138. package/generated/ControlThreadUpdateRequest.schema.json +19 -0
  139. package/generated/DecisionRecord.schema.json +73 -33
  140. package/generated/GateResult.schema.json +1 -2
  141. package/generated/GlobalConfig.schema.json +7 -12
  142. package/generated/HarnessManifest.schema.json +11 -6
  143. package/generated/HarnessStatusDto.schema.json +11 -6
  144. package/generated/LaneCheckpoint.schema.json +59 -0
  145. package/generated/McpRunHandleResult.schema.json +234 -0
  146. package/generated/McpRunToolResult.schema.json +124 -2
  147. package/generated/RoutePrimaryDivergedPayload.schema.json +56 -0
  148. package/generated/RunEvent.schema.json +9 -5
  149. package/generated/RunTelemetry.schema.json +2 -4
  150. package/generated/TaskContract.schema.json +3 -135
  151. package/generated/Thread.schema.json +21 -3
  152. package/generated/ThreadTurn.schema.json +88 -0
  153. package/package.json +2 -2
  154. package/dist/control-spec.d.ts +0 -603
  155. package/dist/control-spec.d.ts.map +0 -1
  156. package/dist/control-spec.js +0 -87
  157. package/dist/control-spec.js.map +0 -1
  158. package/dist/orchestrate.d.ts +0 -556
  159. package/dist/orchestrate.d.ts.map +0 -1
  160. package/dist/orchestrate.js +0 -356
  161. package/dist/orchestrate.js.map +0 -1
  162. package/dist/spec.d.ts +0 -678
  163. package/dist/spec.d.ts.map +0 -1
  164. package/dist/spec.js +0 -186
  165. package/dist/spec.js.map +0 -1
  166. package/generated/ControlSpecAnswersRequest.schema.json +0 -74
  167. package/generated/ControlSpecQuestionsRequest.schema.json +0 -209
  168. package/generated/ControlSpecSession.schema.json +0 -261
  169. package/generated/ControlSpecSessionListResponse.schema.json +0 -273
  170. package/generated/OrchestrateContract.schema.json +0 -119
  171. package/generated/OrchestratePlan.schema.json +0 -264
  172. package/generated/OrchestratePlanProgress.schema.json +0 -164
  173. package/generated/SessionReboundLineage.schema.json +0 -73
  174. package/generated/SpecPack.schema.json +0 -483
@@ -93,15 +93,120 @@ export const CredentialProfileStatus = z
93
93
  })
94
94
  .strict()
95
95
  .describe("Doctor-owned readiness projection for one credential profile; never durable config.");
96
- /** Control response: every registered profile with its doctor projection. */
96
+ /**
97
+ * NON-SECRET account identity projection (INV-067/INV-135): the email and plan
98
+ * label derived DAEMON-SIDE from the account's OWN Claudexor-owned store — the
99
+ * codex `auth.json` id_token claims or the claude `.claude.json` oauthAccount,
100
+ * never the ordinary vendor home (`~/.codex`, `~/.claude`). Only these two
101
+ * allowlisted, non-token fields ever cross the wire; token material stays inside
102
+ * the daemon. A macOS surface MUST render this projection, never re-read the
103
+ * store (the removed app-side reader was the INV-067/INV-002 violation). Both
104
+ * fields are optional so a store that discloses only one still projects.
105
+ */
106
+ export const AccountIdentity = z
107
+ .object({
108
+ email: z
109
+ .string()
110
+ .min(1)
111
+ .optional()
112
+ .describe("Login email of the account (codex id_token `email` / claude oauthAccount `emailAddress`)."),
113
+ plan: z
114
+ .string()
115
+ .min(1)
116
+ .optional()
117
+ .describe("Subscription/plan label (codex `chatgpt_plan_type` / claude oauthAccount `organizationType`)."),
118
+ })
119
+ .strict()
120
+ .describe("Non-secret {email, plan} identity of one account, derived daemon-side from its OWN Claudexor-owned store; never carries token material.");
121
+ /**
122
+ * The identity routing WOULD pick next for a harness's UNPINNED run (INV-135) —
123
+ * purely informational, never user-set. Server-computed by the routing owner
124
+ * from enabled profiles + native readiness + quota so no surface re-derives it:
125
+ * `profile` names the enabled credential profile a quota-rotation would land on;
126
+ * `native` is the CLI login (the default subject of an unpinned run); `none`
127
+ * means an unpinned run has nothing routable (the CLI login is disabled and no
128
+ * account is pinned) with a human reason. Explicit control stays a per-run
129
+ * `--profile` pin or a per-thread pin — this field never gates routing.
130
+ */
131
+ export const ControlNextUpIdentity = z
132
+ .discriminatedUnion("kind", [
133
+ z
134
+ .object({ kind: z.literal("profile"), profileId: Id })
135
+ .strict()
136
+ .describe("An enabled credential profile is who an unpinned run routes to next."),
137
+ z
138
+ .object({ kind: z.literal("native") })
139
+ .strict()
140
+ .describe("The native/CLI login is the default subject of an unpinned run."),
141
+ z
142
+ .object({ kind: z.literal("none"), reason: z.string() })
143
+ .strict()
144
+ .describe("An unpinned run has nothing routable (the CLI login is disabled and no account is pinned)."),
145
+ ])
146
+ .describe("Server-computed identity an unpinned run of this harness would route to next.");
147
+ /**
148
+ * Per-harness ACCOUNTS AUTHORITY projection (INV-135, the accounts symmetry):
149
+ * the native "CLI login" pseudo-row state and the informational `next_up`
150
+ * identity, computed ONCE on the server so no client re-derives the symmetry.
151
+ * Every credential profile of this harness appears in the top-level `profiles`
152
+ * list with its own `enabled` flag — the only user-settable routing control.
153
+ * This row adds the authority the profile rows cannot carry.
154
+ */
155
+ export const ControlHarnessAccounts = z
156
+ .object({
157
+ harness_id: Id.describe("Harness family these accounts belong to."),
158
+ native_credentials_enabled: z
159
+ .boolean()
160
+ .describe("Whether the native/CLI login participates in this harness's credential ladder."),
161
+ native_login_detected: z
162
+ .boolean()
163
+ .describe("Whether a native/default vendor login is currently detected available (the CLI login pseudo-row state)."),
164
+ identity: AccountIdentity.nullable()
165
+ .default(null)
166
+ .describe("Non-secret {email, plan} of the native/CLI login, derived daemon-side from the Claudexor-owned native store; null when absent/undisclosed."),
167
+ next_up: ControlNextUpIdentity,
168
+ })
169
+ .strict()
170
+ .describe("Per-harness accounts authority: native CLI-login state + the informational next-up identity.");
171
+ /** Control response: every registered profile with its doctor projection, plus
172
+ * the per-harness accounts authority (native CLI-login row + next-up identity). */
97
173
  export const ControlCredentialProfilesResponse = z
98
174
  .object({
99
175
  profiles: z
100
- .array(z.object({ profile: CredentialProfile, status: CredentialProfileStatus }).strict())
101
- .describe("Every registered credential profile paired with its doctor readiness projection."),
176
+ .array(z
177
+ .object({
178
+ profile: CredentialProfile,
179
+ status: CredentialProfileStatus,
180
+ identity: AccountIdentity.nullable()
181
+ .default(null)
182
+ .describe("Non-secret {email, plan} of this profile, derived daemon-side from its OWN isolation-locator store; null when absent/undisclosed."),
183
+ })
184
+ .strict())
185
+ .describe("Every registered credential profile paired with its doctor readiness projection and non-secret identity."),
186
+ harnessAccounts: z
187
+ .array(ControlHarnessAccounts)
188
+ .default([])
189
+ .describe("Per-harness accounts authority (INV-135): the native CLI-login pseudo-row state and the server-computed Active identity, so no surface re-derives the accounts symmetry."),
190
+ })
191
+ .strict()
192
+ .describe("Credential-profile registry listing with per-profile doctor readiness and per-harness accounts authority.");
193
+ /** PATCH /credential-profiles/:harness/:id — toggle a profile's `enabled`
194
+ * (the Enabled row of the accounts symmetry). The native CLI login has the same
195
+ * toggle semantics via the harness settings surface, not this route. */
196
+ export const ControlCredentialProfileUpdateRequest = z
197
+ .object({
198
+ enabled: z
199
+ .boolean()
200
+ .describe("Whether this credential profile is routable (the Enabled toggle)."),
102
201
  })
103
202
  .strict()
104
- .describe("Credential-profile registry listing with per-profile doctor readiness.");
203
+ .describe("Request body for PATCH /credential-profiles/:harness/:id.");
204
+ /** Receipt for a credential-profile update: the updated registry entry with its
205
+ * refreshed doctor projection. */
206
+ export const ControlCredentialProfileUpdateResponse = z
207
+ .object({ profile: CredentialProfile, status: CredentialProfileStatus })
208
+ .strict()
209
+ .describe("The updated credential profile with its doctor readiness projection.");
105
210
  /** Register a config-dir login profile (claude/codex) from a UI surface —
106
211
  * the same ONE locked registration owner `claudexor profiles add` uses. */
107
212
  export const ControlCredentialProfileCreateRequest = z
@@ -1 +1 @@
1
- {"version":3,"file":"credential-profile.js","sourceRoot":"","sources":["../src/credential-profile.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC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,CAAC;IACxB,iBAAiB,EAAE,CAAC;SACjB,IAAI,CAAC,CAAC,oBAAoB,EAAE,gBAAgB,EAAE,MAAM,CAAC,CAAC;SACtD,QAAQ,CAAC,oEAAoE,CAAC;IACjF,cAAc,EAAE,CAAC;SACd,MAAM,EAAE;SACR,QAAQ,EAAE;SACV,QAAQ,CAAC,+EAA+E,CAAC;CAC7F,CAAC;KACD,MAAM,EAAE;KACR,QAAQ,CAAC,2CAA2C,CAAC,CAAC;AAKzD,MAAM,CAAC,MAAM,sCAAsC,GAAG,CAAC;KACpD,MAAM,CAAC,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,EAAE,uBAAuB,EAAE,CAAC;KACvE,MAAM,EAAE;KACR,QAAQ,CAAC,sEAAsE,CAAC,CAAC"}
@@ -28,12 +28,46 @@ export declare const PairwiseComparison: z.ZodObject<{
28
28
  }>;
29
29
  }>;
30
30
  export type PairwiseComparison = z.infer<typeof PairwiseComparison>;
31
- export declare const RunStatus: z.ZodEnum<["success", "no_op", "ungated", "review_not_run", "blocked", "failed", "interrupted_unknown", "cost_unverifiable", "exhausted_overshoot", "exhausted", "not_converged", "stuck_no_progress", "cancelled"]>;
32
- export type RunStatus = z.infer<typeof RunStatus>;
33
- export declare const ApplyRecommendation: z.ZodEnum<["apply", "inspect", "continue", "split_task", "human_review"]>;
31
+ /** Deterministic-checks axis (D18: "Checks", the ex-"gates" vocabulary).
32
+ * not_configured is a NAMED state — the old "ungated" collapse (which hid
33
+ * accepted review blockers behind one word) is unrepresentable now. */
34
+ export declare const ChecksState: z.ZodEnum<["passed", "failed", "not_configured"]>;
35
+ export type ChecksState = z.infer<typeof ChecksState>;
36
+ /** Review axis (D18): the cross-family review's verdict, independent of
37
+ * checks and lifecycle. Accepted blockers are ALWAYS `blocked` here. */
38
+ export declare const ReviewState: z.ZodEnum<["approved", "blocked", "not_run"]>;
39
+ export type ReviewState = z.infer<typeof ReviewState>;
40
+ /** Typed reason on non-clean terminals (replaces the old reason-as-status
41
+ * values exhausted/not_converged/stuck_no_progress/...). Null on a clean
42
+ * success. */
43
+ export declare const RunReason: z.ZodEnum<["harness_failed", "no_changes", "review_blocked", "checks_failed", "budget_exhausted", "budget_overshoot", "cost_unverifiable", "not_converged", "stuck_no_progress", "wall_clock_exceeded", "user_cancelled", "crash_interrupted"]>;
44
+ export type RunReason = z.infer<typeof RunReason>;
45
+ /** The v3 terminal truth (D8): independent axes instead of one mixed enum.
46
+ * lifecycle says how far the PROCESS got; noChanges/checks/review say what
47
+ * the work amounted to; reason qualifies; delivery lives separately on
48
+ * RunApplyState. Every surface projects these through status-projection.ts. */
49
+ export declare const RunOutcomeFacts: z.ZodObject<{
50
+ lifecycle: z.ZodEnum<["succeeded", "failed", "cancelled", "interrupted"]>;
51
+ noChanges: z.ZodDefault<z.ZodBoolean>;
52
+ checks: z.ZodDefault<z.ZodEnum<["passed", "failed", "not_configured"]>>;
53
+ review: z.ZodDefault<z.ZodEnum<["approved", "blocked", "not_run"]>>;
54
+ reason: z.ZodDefault<z.ZodNullable<z.ZodEnum<["harness_failed", "no_changes", "review_blocked", "checks_failed", "budget_exhausted", "budget_overshoot", "cost_unverifiable", "not_converged", "stuck_no_progress", "wall_clock_exceeded", "user_cancelled", "crash_interrupted"]>>>;
55
+ }, "strict", z.ZodTypeAny, {
56
+ review: "not_run" | "approved" | "blocked";
57
+ reason: "harness_failed" | "no_changes" | "review_blocked" | "checks_failed" | "budget_exhausted" | "budget_overshoot" | "cost_unverifiable" | "not_converged" | "stuck_no_progress" | "wall_clock_exceeded" | "user_cancelled" | "crash_interrupted" | null;
58
+ checks: "passed" | "failed" | "not_configured";
59
+ lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
60
+ noChanges: boolean;
61
+ }, {
62
+ lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
63
+ review?: "not_run" | "approved" | "blocked" | undefined;
64
+ reason?: "harness_failed" | "no_changes" | "review_blocked" | "checks_failed" | "budget_exhausted" | "budget_overshoot" | "cost_unverifiable" | "not_converged" | "stuck_no_progress" | "wall_clock_exceeded" | "user_cancelled" | "crash_interrupted" | null | undefined;
65
+ checks?: "passed" | "failed" | "not_configured" | undefined;
66
+ noChanges?: boolean | undefined;
67
+ }>;
68
+ export type RunOutcomeFacts = z.infer<typeof RunOutcomeFacts>;
69
+ export declare const ApplyRecommendation: z.ZodEnum<["apply", "inspect", "continue", "human_review"]>;
34
70
  export type ApplyRecommendation = z.infer<typeof ApplyRecommendation>;
35
- export declare const DecisionOutcome: z.ZodEnum<["ready", "no_op", "ungated", "review_not_run", "blocked"]>;
36
- export type DecisionOutcome = z.infer<typeof DecisionOutcome>;
37
71
  export declare const VerificationBasis: z.ZodEnum<["none", "cross_family_review", "both"]>;
38
72
  export type VerificationBasis = z.infer<typeof VerificationBasis>;
39
73
  /**
@@ -88,8 +122,28 @@ export declare const FinalVerifyRecord: z.ZodObject<{
88
122
  export type FinalVerifyRecord = z.infer<typeof FinalVerifyRecord>;
89
123
  export declare const DecisionRecord: z.ZodObject<{
90
124
  winner: z.ZodNullable<z.ZodString>;
91
- status: z.ZodEnum<["success", "no_op", "ungated", "review_not_run", "blocked", "failed", "interrupted_unknown", "cost_unverifiable", "exhausted_overshoot", "exhausted", "not_converged", "stuck_no_progress", "cancelled"]>;
92
- outcome: z.ZodDefault<z.ZodEnum<["ready", "no_op", "ungated", "review_not_run", "blocked"]>>;
125
+ /** The independent terminal axes (D8) — replaces the old mixed
126
+ * status/outcome pair; the collapse classes (`ungated`, gate failures
127
+ * masked by `review_not_run`) are unrepresentable. */
128
+ facts: z.ZodObject<{
129
+ lifecycle: z.ZodEnum<["succeeded", "failed", "cancelled", "interrupted"]>;
130
+ noChanges: z.ZodDefault<z.ZodBoolean>;
131
+ checks: z.ZodDefault<z.ZodEnum<["passed", "failed", "not_configured"]>>;
132
+ review: z.ZodDefault<z.ZodEnum<["approved", "blocked", "not_run"]>>;
133
+ reason: z.ZodDefault<z.ZodNullable<z.ZodEnum<["harness_failed", "no_changes", "review_blocked", "checks_failed", "budget_exhausted", "budget_overshoot", "cost_unverifiable", "not_converged", "stuck_no_progress", "wall_clock_exceeded", "user_cancelled", "crash_interrupted"]>>>;
134
+ }, "strict", z.ZodTypeAny, {
135
+ review: "not_run" | "approved" | "blocked";
136
+ reason: "harness_failed" | "no_changes" | "review_blocked" | "checks_failed" | "budget_exhausted" | "budget_overshoot" | "cost_unverifiable" | "not_converged" | "stuck_no_progress" | "wall_clock_exceeded" | "user_cancelled" | "crash_interrupted" | null;
137
+ checks: "passed" | "failed" | "not_configured";
138
+ lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
139
+ noChanges: boolean;
140
+ }, {
141
+ lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
142
+ review?: "not_run" | "approved" | "blocked" | undefined;
143
+ reason?: "harness_failed" | "no_changes" | "review_blocked" | "checks_failed" | "budget_exhausted" | "budget_overshoot" | "cost_unverifiable" | "not_converged" | "stuck_no_progress" | "wall_clock_exceeded" | "user_cancelled" | "crash_interrupted" | null | undefined;
144
+ checks?: "passed" | "failed" | "not_configured" | undefined;
145
+ noChanges?: boolean | undefined;
146
+ }>;
93
147
  why_winner: z.ZodDefault<z.ZodString>;
94
148
  why_not_others: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>;
95
149
  accepted_risks: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
@@ -105,7 +159,7 @@ export declare const DecisionRecord: z.ZodObject<{
105
159
  estimated?: boolean | undefined;
106
160
  spend_usd?: number | null | undefined;
107
161
  }>>;
108
- apply_recommendation: z.ZodDefault<z.ZodEnum<["apply", "inspect", "continue", "split_task", "human_review"]>>;
162
+ apply_recommendation: z.ZodDefault<z.ZodEnum<["apply", "inspect", "continue", "human_review"]>>;
109
163
  verification_basis: z.ZodDefault<z.ZodEnum<["none", "cross_family_review", "both"]>>;
110
164
  final_verify: z.ZodDefault<z.ZodNullable<z.ZodObject<{
111
165
  attempted: z.ZodBoolean;
@@ -150,9 +204,14 @@ export declare const DecisionRecord: z.ZodObject<{
150
204
  }[] | undefined;
151
205
  }>>>;
152
206
  }, "strip", z.ZodTypeAny, {
153
- status: "failed" | "cancelled" | "interrupted_unknown" | "success" | "no_op" | "ungated" | "review_not_run" | "blocked" | "cost_unverifiable" | "exhausted_overshoot" | "exhausted" | "not_converged" | "stuck_no_progress";
154
207
  winner: string | null;
155
- outcome: "ready" | "no_op" | "ungated" | "review_not_run" | "blocked";
208
+ facts: {
209
+ review: "not_run" | "approved" | "blocked";
210
+ reason: "harness_failed" | "no_changes" | "review_blocked" | "checks_failed" | "budget_exhausted" | "budget_overshoot" | "cost_unverifiable" | "not_converged" | "stuck_no_progress" | "wall_clock_exceeded" | "user_cancelled" | "crash_interrupted" | null;
211
+ checks: "passed" | "failed" | "not_configured";
212
+ lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
213
+ noChanges: boolean;
214
+ };
156
215
  why_winner: string;
157
216
  why_not_others: Record<string, string>;
158
217
  accepted_risks: string[];
@@ -162,7 +221,7 @@ export declare const DecisionRecord: z.ZodObject<{
162
221
  estimated: boolean;
163
222
  spend_usd: number | null;
164
223
  };
165
- apply_recommendation: "apply" | "inspect" | "continue" | "split_task" | "human_review";
224
+ apply_recommendation: "apply" | "inspect" | "continue" | "human_review";
166
225
  verification_basis: "none" | "cross_family_review" | "both";
167
226
  final_verify: {
168
227
  reason: string | null;
@@ -177,9 +236,14 @@ export declare const DecisionRecord: z.ZodObject<{
177
236
  }[];
178
237
  } | null;
179
238
  }, {
180
- status: "failed" | "cancelled" | "interrupted_unknown" | "success" | "no_op" | "ungated" | "review_not_run" | "blocked" | "cost_unverifiable" | "exhausted_overshoot" | "exhausted" | "not_converged" | "stuck_no_progress";
181
239
  winner: string | null;
182
- outcome?: "ready" | "no_op" | "ungated" | "review_not_run" | "blocked" | undefined;
240
+ facts: {
241
+ lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
242
+ review?: "not_run" | "approved" | "blocked" | undefined;
243
+ reason?: "harness_failed" | "no_changes" | "review_blocked" | "checks_failed" | "budget_exhausted" | "budget_overshoot" | "cost_unverifiable" | "not_converged" | "stuck_no_progress" | "wall_clock_exceeded" | "user_cancelled" | "crash_interrupted" | null | undefined;
244
+ checks?: "passed" | "failed" | "not_configured" | undefined;
245
+ noChanges?: boolean | undefined;
246
+ };
183
247
  why_winner?: string | undefined;
184
248
  why_not_others?: Record<string, string> | undefined;
185
249
  accepted_risks?: string[] | undefined;
@@ -189,7 +253,7 @@ export declare const DecisionRecord: z.ZodObject<{
189
253
  estimated?: boolean | undefined;
190
254
  spend_usd?: number | null | undefined;
191
255
  } | undefined;
192
- apply_recommendation?: "apply" | "inspect" | "continue" | "split_task" | "human_review" | undefined;
256
+ apply_recommendation?: "apply" | "inspect" | "continue" | "human_review" | undefined;
193
257
  verification_basis?: "none" | "cross_family_review" | "both" | undefined;
194
258
  final_verify?: {
195
259
  attempted: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"decision.d.ts","sourceRoot":"","sources":["../src/decision.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;EAciD,CAAC;AACjF,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAEpE,eAAO,MAAM,SAAS,sNAkBnB,CAAC;AACJ,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAElD,eAAO,MAAM,mBAAmB,2EAI7B,CAAC;AACJ,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,eAAO,MAAM,eAAe,uEAIzB,CAAC;AACJ,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAS9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SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAElD;;;+EAG+E;AAC/E,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;EAgBuC,CAAC;AACpE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAE9D,eAAO,MAAM,mBAAmB,6DAI7B,CAAC;AACJ,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAStE,eAAO,MAAM,iBAAiB,oDAI3B,CAAC;AACJ,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB;;IAG1B,8EAA8E;;;;;;;;;;;;;;;IAgC9E,0FAA0F;;;;;;;;;;;;;;;;;;;;;;;;EAW3F,CAAC;AACJ,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,eAAO,MAAM,cAAc;;IAGvB;;0DAEsD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAnDtD,8EAA8E;;;;;;;;;;;;;;;QAgC9E,0FAA0F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAoE3F,CAAC;AACJ,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC"}
package/dist/decision.js CHANGED
@@ -12,29 +12,60 @@ export const PairwiseComparison = z
12
12
  .describe("Per-criterion verdicts keyed by criterion name."),
13
13
  })
14
14
  .describe("Pairwise comparison of two race candidates across named criteria.");
15
- export const RunStatus = z
15
+ /** Deterministic-checks axis (D18: "Checks", the ex-"gates" vocabulary).
16
+ * not_configured is a NAMED state — the old "ungated" collapse (which hid
17
+ * accepted review blockers behind one word) is unrepresentable now. */
18
+ export const ChecksState = z
19
+ .enum(["passed", "failed", "not_configured"])
20
+ .describe("Deterministic checks axis: configured project checks passed, failed, or none are configured (a named state, never a stand-in for review results).");
21
+ /** Review axis (D18): the cross-family review's verdict, independent of
22
+ * checks and lifecycle. Accepted blockers are ALWAYS `blocked` here. */
23
+ export const ReviewState = z
24
+ .enum(["approved", "blocked", "not_run"])
25
+ .describe("Review axis: approved (clean cross-family verified review), blocked (open accepted findings), or not_run.");
26
+ /** Typed reason on non-clean terminals (replaces the old reason-as-status
27
+ * values exhausted/not_converged/stuck_no_progress/...). Null on a clean
28
+ * success. */
29
+ export const RunReason = z
16
30
  .enum([
17
- "success",
18
- "no_op",
19
- "ungated",
20
- "review_not_run",
21
- "blocked",
22
- "failed",
23
- "interrupted_unknown",
31
+ "harness_failed",
32
+ "no_changes",
33
+ "review_blocked",
34
+ "checks_failed",
35
+ "budget_exhausted",
36
+ "budget_overshoot",
24
37
  "cost_unverifiable",
25
- "exhausted_overshoot",
26
- "exhausted",
27
38
  "not_converged",
28
39
  "stuck_no_progress",
29
- "cancelled",
40
+ "wall_clock_exceeded",
41
+ "user_cancelled",
42
+ "crash_interrupted",
30
43
  ])
31
- .describe("Terminal status of a run, including truthful blocked, interrupted-unknown, cost-unverifiable, overshoot, exhaustion, non-convergence, failure, and cancellation outcomes.");
44
+ .describe("Typed reason qualifying a non-clean terminal; null on a clean success.");
45
+ /** The v3 terminal truth (D8): independent axes instead of one mixed enum.
46
+ * lifecycle says how far the PROCESS got; noChanges/checks/review say what
47
+ * the work amounted to; reason qualifies; delivery lives separately on
48
+ * RunApplyState. Every surface projects these through status-projection.ts. */
49
+ export const RunOutcomeFacts = z
50
+ .object({
51
+ lifecycle: z
52
+ .enum(["succeeded", "failed", "cancelled", "interrupted"])
53
+ .describe("Terminal lifecycle of the run."),
54
+ noChanges: z
55
+ .boolean()
56
+ .default(false)
57
+ .describe("True when the run finished without changing any files (the ex no_op fact)."),
58
+ checks: ChecksState.default("not_configured"),
59
+ review: ReviewState.default("not_run"),
60
+ reason: RunReason.nullable()
61
+ .default(null)
62
+ .describe("Typed reason qualifying a non-clean terminal; null on a clean success."),
63
+ })
64
+ .strict()
65
+ .describe("Independent terminal outcome axes of a run (D8/D18).");
32
66
  export const ApplyRecommendation = z
33
- .enum(["apply", "inspect", "continue", "split_task", "human_review"])
34
- .describe("Recommended next action for the run's work product: apply it, inspect first, continue working, split the task, or get human review.");
35
- export const DecisionOutcome = z
36
- .enum(["ready", "no_op", "ungated", "review_not_run", "blocked"])
37
- .describe("Arbitration outcome for the winning candidate: ready (verified applyable), no_op (no changes), ungated (no gates configured), review_not_run, or blocked.");
67
+ .enum(["apply", "inspect", "continue", "human_review"])
68
+ .describe("Recommended next action for the run's work product: apply it, inspect first, continue working, or get human review.");
38
69
  // What backed a `ready`/applyable outcome: a clean cross-family verified review,
39
70
  // or both deterministic gates AND that review. `none` for non-applyable outcomes.
40
71
  // Surfaced honestly so a no-test run adopted on review evidence never reads as
@@ -96,8 +127,10 @@ export const FinalVerifyRecord = z
96
127
  export const DecisionRecord = z
97
128
  .object({
98
129
  winner: Id.nullable().describe("Winning attempt/candidate id; null when nothing won."),
99
- status: RunStatus,
100
- outcome: DecisionOutcome.default("blocked"),
130
+ /** The independent terminal axes (D8) — replaces the old mixed
131
+ * status/outcome pair; the collapse classes (`ungated`, gate failures
132
+ * masked by `review_not_run`) are unrepresentable. */
133
+ facts: RunOutcomeFacts,
101
134
  why_winner: z.string().default("").describe("Why the winner was chosen."),
102
135
  why_not_others: z
103
136
  .record(z.string(), z.string())
@@ -141,5 +174,5 @@ export const DecisionRecord = z
141
174
  .default(null)
142
175
  .describe("Final verify record; present only for write runs with a patch (or a recorded reason why the verifier did not run)."),
143
176
  })
144
- .describe("The arbitration decision for a run: winner, status/outcome, reasons, spend, and the verification that backs applyability.");
177
+ .describe("The arbitration decision for a run: winner, outcome axes, reasons, spend, and the verification that backs applyability.");
145
178
  //# sourceMappingURL=decision.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"decision.js","sourceRoot":"","sources":["../src/decision.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,EAAE,EAAE,MAAM,iBAAiB,CAAC;AAErC,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC;KAChC,MAAM,CAAC;IACN,WAAW,EAAE,EAAE,CAAC,QAAQ,CAAC,oCAAoC,CAAC;IAC9D,WAAW,EAAE,EAAE,CAAC,QAAQ,CAAC,qCAAqC,CAAC;IAC/D,QAAQ,EAAE,CAAC;SACR,MAAM,CACL,CAAC,CAAC,MAAM,EAAE,EACV,CAAC,CAAC,MAAM,CAAC;QACP,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC,CAAC,QAAQ,CAAC,6CAA6C,CAAC;QACzF,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,0CAA0C,CAAC;KACxE,CAAC,CACH;SACA,QAAQ,CAAC,iDAAiD,CAAC;CAC/D,CAAC;KACD,QAAQ,CAAC,mEAAmE,CAAC,CAAC;AAGjF,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC;KACvB,IAAI,CAAC;IACJ,SAAS;IACT,OAAO;IACP,SAAS;IACT,gBAAgB;IAChB,SAAS;IACT,QAAQ;IACR,qBAAqB;IACrB,mBAAmB;IACnB,qBAAqB;IACrB,WAAW;IACX,eAAe;IACf,mBAAmB;IACnB,WAAW;CACZ,CAAC;KACD,QAAQ,CACP,2KAA2K,CAC5K,CAAC;AAGJ,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC;KACjC,IAAI,CAAC,CAAC,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,YAAY,EAAE,cAAc,CAAC,CAAC;KACpE,QAAQ,CACP,qIAAqI,CAC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,CAAC;IACzD,YAAY,EAAE,CAAC;SACZ,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;SACjB,OAAO,CAAC,EAAE,CAAC;SACX,QAAQ,CAAC,6CAA6C,CAAC;IAC1D,cAAc,EAAE,CAAC;SACd,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;SACjB,OAAO,CAAC,EAAE,CAAC;SACX,QAAQ,CAAC,uCAAuC,CAAC;IACpD,cAAc,EAAE,CAAC;SACd,MAAM,CAAC;QACN,2EAA2E;QAC3E,mFAAmF;QACnF,SAAS,EAAE,CAAC;aACT,MAAM,EAAE;aACR,QAAQ,EAAE;aACV,OAAO,CAAC,IAAI,CAAC;aACb,QAAQ,CAAC,gDAAgD,CAAC;QAC7D,SAAS,EAAE,CAAC;aACT,OAAO,EAAE;aACT,OAAO,CAAC,KAAK,CAAC;aACd,QAAQ,CAAC,4EAA4E,CAAC;KAC1F,CAAC;SACD,OAAO,CAAC,EAAE,SAAS,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;SAC9C,QAAQ,CAAC,+EAA+E,CAAC;IAC5F,oBAAoB,EAAE,mBAAmB,CAAC,OAAO,CAAC,SAAS,CAAC;IAC5D,2EAA2E;IAC3E,8EAA8E;IAC9E,kBAAkB,EAAE,iBAAiB,CAAC,OAAO,CAAC,MAAM,CAAC;IACrD,sEAAsE;IACtE,kEAAkE;IAClE,YAAY,EAAE,iBAAiB,CAAC,QAAQ,EAAE;SACvC,OAAO,CAAC,IAAI,CAAC;SACb,QAAQ,CACP,oHAAoH,CACrH;CACJ,CAAC;KACD,QAAQ,CACP,yHAAyH,CAC1H,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import { z } from "zod";
2
2
  /** Immutable evidence for one DeliveryService attempt, shared by every apply surface. */
3
3
  export declare const DeliveryReceipt: z.ZodObject<{
4
- mode: z.ZodEnum<["artifact_only", "apply", "branch", "commit", "pr"]>;
4
+ mode: z.ZodEnum<["apply", "branch", "commit", "pr"]>;
5
5
  applied: z.ZodBoolean;
6
6
  branch: z.ZodOptional<z.ZodString>;
7
7
  commit: z.ZodOptional<z.ZodString>;
@@ -51,7 +51,7 @@ export declare const DeliveryReceipt: z.ZodObject<{
51
51
  }>;
52
52
  targetPreimageSha: z.ZodString;
53
53
  }, "strict", z.ZodTypeAny, {
54
- mode: "apply" | "commit" | "branch" | "pr" | "artifact_only";
54
+ mode: "apply" | "commit" | "branch" | "pr";
55
55
  applied: boolean;
56
56
  finalVerify: {
57
57
  reason: string | null;
@@ -73,7 +73,7 @@ export declare const DeliveryReceipt: z.ZodObject<{
73
73
  treeMutated?: boolean | undefined;
74
74
  refused?: boolean | undefined;
75
75
  }, {
76
- mode: "apply" | "commit" | "branch" | "pr" | "artifact_only";
76
+ mode: "apply" | "commit" | "branch" | "pr";
77
77
  applied: boolean;
78
78
  finalVerify: {
79
79
  attempted: boolean;
package/dist/delivery.js CHANGED
@@ -3,7 +3,7 @@ import { FinalVerifyRecord } from "./decision.js";
3
3
  /** Immutable evidence for one DeliveryService attempt, shared by every apply surface. */
4
4
  export const DeliveryReceipt = z
5
5
  .object({
6
- mode: z.enum(["artifact_only", "apply", "branch", "commit", "pr"]),
6
+ mode: z.enum(["apply", "branch", "commit", "pr"]),
7
7
  applied: z.boolean(),
8
8
  branch: z.string().optional(),
9
9
  commit: z.string().optional(),
@@ -1 +1 @@
1
- {"version":3,"file":"delivery.js","sourceRoot":"","sources":["../src/delivery.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAElD,yFAAyF;AACzF,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC;KAC7B,MAAM,CAAC;IACN,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,eAAe,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,CAAC,CAAC;IAClE,OAAO,EAA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QAAQ,EAAE;IAC7B,WAAW,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IACnC,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IAC/B,WAAW,EAAE,iBAAiB,CAAC,QAAQ,CAAC,oDAAoD,CAAC;IAC7F,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,uDAAuD,CAAC;CAChG,CAAC;KACD,MAAM,EAAE;KACR,QAAQ,CAAC,4DAA4D,CAAC,CAAC"}
package/dist/events.d.ts CHANGED
@@ -36,7 +36,7 @@ export declare const ThreadHeadPing: z.ZodObject<{
36
36
  revision: number;
37
37
  }>;
38
38
  export type ThreadHeadPing = z.infer<typeof ThreadHeadPing>;
39
- export declare const RunEventType: z.ZodEnum<["run.created", "task.contract.created", "context.pack.created", "project.git.initialized", "budget.lease.created", "budget.observation", "budget.cash", "policy.web.upgraded", "harness.started", "harness.event", "harness.completed", "route.fallback.started", "route.fallback.completed", "route.fallback.exhausted", "route.transient.detected", "route.transient.retry_scheduled", "route.profile.headroom_exceeded", "route.profile.rotated", "route.profile.rotation_exhausted", "route.transient.exhausted", "route.fallback.auth_switched", "session.rebound", "interaction.requested", "interaction.answered", "interaction.timeout", "interaction.answer_discarded", "plan.progress", "budget.quota_pressure", "output.ready", "gate.started", "gate.completed", "review.started", "reviewer.started", "reviewer.first_event", "reviewer.auth_switched", "reviewer.completed", "reviewer.timed_out", "reviewer.failed", "finding.revalidated", "synthesis.started", "arbitration.completed", "work_product.emitted", "work_product.adopted", "orchestrate.subrun.started", "orchestrate.step.done", "orchestrate.step.blocked", "control.requested", "control.applied", "control.rejected", "run.blocked", "run.completed", "run.failed"]>;
39
+ export declare const RunEventType: z.ZodEnum<["run.created", "task.contract.created", "context.pack.created", "project.git.initialized", "budget.lease.created", "budget.observation", "budget.cash", "policy.web.upgraded", "harness.started", "harness.event", "harness.completed", "route.fallback.started", "route.fallback.completed", "route.fallback.exhausted", "route.transient.detected", "route.transient.retry_scheduled", "route.profile.headroom_exceeded", "route.profile.rotated", "route.profile.rotation_exhausted", "route.transient.exhausted", "route.fallback.auth_switched", "route.primary.diverged", "session.continuity", "interaction.requested", "interaction.answered", "interaction.timeout", "interaction.answer_discarded", "plan.progress", "plan.questions", "plan.brief.materialized", "council.started", "council.draft", "council.member.failed", "council.merged", "budget.quota_pressure", "output.ready", "gate.started", "gate.completed", "review.started", "reviewer.started", "reviewer.first_event", "reviewer.auth_switched", "reviewer.completed", "reviewer.timed_out", "reviewer.failed", "finding.revalidated", "synthesis.started", "arbitration.completed", "work_product.emitted", "work_product.adopted", "control.requested", "control.applied", "control.rejected", "run.blocked", "run.completed", "run.failed"]>;
40
40
  export type RunEventType = z.infer<typeof RunEventType>;
41
41
  /**
42
42
  * Typed payload for `route.fallback.*` events. The orchestrator validates this
@@ -53,16 +53,16 @@ export declare const RouteFallbackPayload: z.ZodObject<{
53
53
  attempt_id: z.ZodDefault<z.ZodNullable<z.ZodString>>;
54
54
  error_summary: z.ZodDefault<z.ZodNullable<z.ZodString>>;
55
55
  }, "strip", z.ZodTypeAny, {
56
- error_summary: string | null;
57
56
  reason: "quota_exhausted" | "money_exhausted" | "subscription_exhausted" | "rate_limited" | "harness_error" | "stall" | "web_evidence_unsatisfied" | "fallback_model" | "not_portable" | "auth_unavailable" | "readiness_preferred" | "manual";
57
+ error_summary: string | null;
58
58
  attempt_id: string | null;
59
59
  from_harness: string | null;
60
60
  to_harness: string | null;
61
61
  from_auth_mode: "unknown" | "api_key" | "local_session";
62
62
  to_auth_mode: "unknown" | "api_key" | "local_session";
63
63
  }, {
64
- error_summary?: string | null | undefined;
65
64
  reason?: "quota_exhausted" | "money_exhausted" | "subscription_exhausted" | "rate_limited" | "harness_error" | "stall" | "web_evidence_unsatisfied" | "fallback_model" | "not_portable" | "auth_unavailable" | "readiness_preferred" | "manual" | undefined;
65
+ error_summary?: string | null | undefined;
66
66
  attempt_id?: string | null | undefined;
67
67
  from_harness?: string | null | undefined;
68
68
  to_harness?: string | null | undefined;
@@ -70,6 +70,32 @@ export declare const RouteFallbackPayload: z.ZodObject<{
70
70
  to_auth_mode?: "unknown" | "api_key" | "local_session" | undefined;
71
71
  }>;
72
72
  export type RouteFallbackPayload = z.infer<typeof RouteFallbackPayload>;
73
+ /**
74
+ * Typed payload for the `route.primary.diverged` event. Emitted at route
75
+ * selection when a run's requested/sticky PRIMARY harness is not the harness
76
+ * that will actually run (its account was quota-exhausted / on cooldown, or the
77
+ * route was unavailable), so the composer's visible harness choice silently
78
+ * would not have applied. The orchestrator validates this before stamping it, so
79
+ * the divergence is always evidence-backed — the receipt discloses "requested
80
+ * <requested> → ran on <effective> (<reason>)" from real facts, never invented.
81
+ */
82
+ export declare const RoutePrimaryDivergedPayload: z.ZodObject<{
83
+ requested: z.ZodString;
84
+ effective: z.ZodDefault<z.ZodNullable<z.ZodString>>;
85
+ reason: z.ZodDefault<z.ZodEnum<["quota_exhausted", "money_exhausted", "subscription_exhausted", "rate_limited", "harness_error", "stall", "web_evidence_unsatisfied", "fallback_model", "not_portable", "auth_unavailable", "readiness_preferred", "manual"]>>;
86
+ detail: z.ZodDefault<z.ZodNullable<z.ZodString>>;
87
+ }, "strip", z.ZodTypeAny, {
88
+ detail: string | null;
89
+ requested: string;
90
+ effective: string | null;
91
+ reason: "quota_exhausted" | "money_exhausted" | "subscription_exhausted" | "rate_limited" | "harness_error" | "stall" | "web_evidence_unsatisfied" | "fallback_model" | "not_portable" | "auth_unavailable" | "readiness_preferred" | "manual";
92
+ }, {
93
+ requested: string;
94
+ detail?: string | null | undefined;
95
+ effective?: string | null | undefined;
96
+ reason?: "quota_exhausted" | "money_exhausted" | "subscription_exhausted" | "rate_limited" | "harness_error" | "stall" | "web_evidence_unsatisfied" | "fallback_model" | "not_portable" | "auth_unavailable" | "readiness_preferred" | "manual" | undefined;
97
+ }>;
98
+ export type RoutePrimaryDivergedPayload = z.infer<typeof RoutePrimaryDivergedPayload>;
73
99
  /** Append-only event record (one JSONL line). */
74
100
  export declare const RunEvent: z.ZodObject<{
75
101
  /**
@@ -84,10 +110,10 @@ export declare const RunEvent: z.ZodObject<{
84
110
  /** Thread this run is a turn of, when any. Lets the global event multiplex
85
111
  * route live progress to a chat surface without a reverse job lookup. */
86
112
  thread_id: z.ZodOptional<z.ZodString>;
87
- type: z.ZodEnum<["run.created", "task.contract.created", "context.pack.created", "project.git.initialized", "budget.lease.created", "budget.observation", "budget.cash", "policy.web.upgraded", "harness.started", "harness.event", "harness.completed", "route.fallback.started", "route.fallback.completed", "route.fallback.exhausted", "route.transient.detected", "route.transient.retry_scheduled", "route.profile.headroom_exceeded", "route.profile.rotated", "route.profile.rotation_exhausted", "route.transient.exhausted", "route.fallback.auth_switched", "session.rebound", "interaction.requested", "interaction.answered", "interaction.timeout", "interaction.answer_discarded", "plan.progress", "budget.quota_pressure", "output.ready", "gate.started", "gate.completed", "review.started", "reviewer.started", "reviewer.first_event", "reviewer.auth_switched", "reviewer.completed", "reviewer.timed_out", "reviewer.failed", "finding.revalidated", "synthesis.started", "arbitration.completed", "work_product.emitted", "work_product.adopted", "orchestrate.subrun.started", "orchestrate.step.done", "orchestrate.step.blocked", "control.requested", "control.applied", "control.rejected", "run.blocked", "run.completed", "run.failed"]>;
113
+ type: z.ZodEnum<["run.created", "task.contract.created", "context.pack.created", "project.git.initialized", "budget.lease.created", "budget.observation", "budget.cash", "policy.web.upgraded", "harness.started", "harness.event", "harness.completed", "route.fallback.started", "route.fallback.completed", "route.fallback.exhausted", "route.transient.detected", "route.transient.retry_scheduled", "route.profile.headroom_exceeded", "route.profile.rotated", "route.profile.rotation_exhausted", "route.transient.exhausted", "route.fallback.auth_switched", "route.primary.diverged", "session.continuity", "interaction.requested", "interaction.answered", "interaction.timeout", "interaction.answer_discarded", "plan.progress", "plan.questions", "plan.brief.materialized", "council.started", "council.draft", "council.member.failed", "council.merged", "budget.quota_pressure", "output.ready", "gate.started", "gate.completed", "review.started", "reviewer.started", "reviewer.first_event", "reviewer.auth_switched", "reviewer.completed", "reviewer.timed_out", "reviewer.failed", "finding.revalidated", "synthesis.started", "arbitration.completed", "work_product.emitted", "work_product.adopted", "control.requested", "control.applied", "control.rejected", "run.blocked", "run.completed", "run.failed"]>;
88
114
  payload: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
89
115
  }, "strip", z.ZodTypeAny, {
90
- type: "run.created" | "task.contract.created" | "context.pack.created" | "project.git.initialized" | "budget.lease.created" | "budget.observation" | "budget.cash" | "policy.web.upgraded" | "harness.started" | "harness.event" | "harness.completed" | "route.fallback.started" | "route.fallback.completed" | "route.fallback.exhausted" | "route.transient.detected" | "route.transient.retry_scheduled" | "route.profile.headroom_exceeded" | "route.profile.rotated" | "route.profile.rotation_exhausted" | "route.transient.exhausted" | "route.fallback.auth_switched" | "session.rebound" | "interaction.requested" | "interaction.answered" | "interaction.timeout" | "interaction.answer_discarded" | "plan.progress" | "budget.quota_pressure" | "output.ready" | "gate.started" | "gate.completed" | "review.started" | "reviewer.started" | "reviewer.first_event" | "reviewer.auth_switched" | "reviewer.completed" | "reviewer.timed_out" | "reviewer.failed" | "finding.revalidated" | "synthesis.started" | "arbitration.completed" | "work_product.emitted" | "work_product.adopted" | "orchestrate.subrun.started" | "orchestrate.step.done" | "orchestrate.step.blocked" | "control.requested" | "control.applied" | "control.rejected" | "run.blocked" | "run.completed" | "run.failed";
116
+ type: "run.created" | "task.contract.created" | "context.pack.created" | "project.git.initialized" | "budget.lease.created" | "budget.observation" | "budget.cash" | "policy.web.upgraded" | "harness.started" | "harness.event" | "harness.completed" | "route.fallback.started" | "route.fallback.completed" | "route.fallback.exhausted" | "route.transient.detected" | "route.transient.retry_scheduled" | "route.profile.headroom_exceeded" | "route.profile.rotated" | "route.profile.rotation_exhausted" | "route.transient.exhausted" | "route.fallback.auth_switched" | "route.primary.diverged" | "session.continuity" | "interaction.requested" | "interaction.answered" | "interaction.timeout" | "interaction.answer_discarded" | "plan.progress" | "plan.questions" | "plan.brief.materialized" | "council.started" | "council.draft" | "council.member.failed" | "council.merged" | "budget.quota_pressure" | "output.ready" | "gate.started" | "gate.completed" | "review.started" | "reviewer.started" | "reviewer.first_event" | "reviewer.auth_switched" | "reviewer.completed" | "reviewer.timed_out" | "reviewer.failed" | "finding.revalidated" | "synthesis.started" | "arbitration.completed" | "work_product.emitted" | "work_product.adopted" | "control.requested" | "control.applied" | "control.rejected" | "run.blocked" | "run.completed" | "run.failed";
91
117
  ts: string;
92
118
  payload: Record<string, unknown>;
93
119
  run_id: string;
@@ -95,7 +121,7 @@ export declare const RunEvent: z.ZodObject<{
95
121
  thread_id?: string | undefined;
96
122
  seq?: number | undefined;
97
123
  }, {
98
- type: "run.created" | "task.contract.created" | "context.pack.created" | "project.git.initialized" | "budget.lease.created" | "budget.observation" | "budget.cash" | "policy.web.upgraded" | "harness.started" | "harness.event" | "harness.completed" | "route.fallback.started" | "route.fallback.completed" | "route.fallback.exhausted" | "route.transient.detected" | "route.transient.retry_scheduled" | "route.profile.headroom_exceeded" | "route.profile.rotated" | "route.profile.rotation_exhausted" | "route.transient.exhausted" | "route.fallback.auth_switched" | "session.rebound" | "interaction.requested" | "interaction.answered" | "interaction.timeout" | "interaction.answer_discarded" | "plan.progress" | "budget.quota_pressure" | "output.ready" | "gate.started" | "gate.completed" | "review.started" | "reviewer.started" | "reviewer.first_event" | "reviewer.auth_switched" | "reviewer.completed" | "reviewer.timed_out" | "reviewer.failed" | "finding.revalidated" | "synthesis.started" | "arbitration.completed" | "work_product.emitted" | "work_product.adopted" | "orchestrate.subrun.started" | "orchestrate.step.done" | "orchestrate.step.blocked" | "control.requested" | "control.applied" | "control.rejected" | "run.blocked" | "run.completed" | "run.failed";
124
+ type: "run.created" | "task.contract.created" | "context.pack.created" | "project.git.initialized" | "budget.lease.created" | "budget.observation" | "budget.cash" | "policy.web.upgraded" | "harness.started" | "harness.event" | "harness.completed" | "route.fallback.started" | "route.fallback.completed" | "route.fallback.exhausted" | "route.transient.detected" | "route.transient.retry_scheduled" | "route.profile.headroom_exceeded" | "route.profile.rotated" | "route.profile.rotation_exhausted" | "route.transient.exhausted" | "route.fallback.auth_switched" | "route.primary.diverged" | "session.continuity" | "interaction.requested" | "interaction.answered" | "interaction.timeout" | "interaction.answer_discarded" | "plan.progress" | "plan.questions" | "plan.brief.materialized" | "council.started" | "council.draft" | "council.member.failed" | "council.merged" | "budget.quota_pressure" | "output.ready" | "gate.started" | "gate.completed" | "review.started" | "reviewer.started" | "reviewer.first_event" | "reviewer.auth_switched" | "reviewer.completed" | "reviewer.timed_out" | "reviewer.failed" | "finding.revalidated" | "synthesis.started" | "arbitration.completed" | "work_product.emitted" | "work_product.adopted" | "control.requested" | "control.applied" | "control.rejected" | "run.blocked" | "run.completed" | "run.failed";
99
125
  ts: string;
100
126
  run_id: string;
101
127
  task_id: string;
@@ -1 +1 @@
1
- {"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../src/events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;EAU4C,CAAC;AAC7E,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,eAAO,MAAM,cAAc;;;;;;;;;;;;EAoBxB,CAAC;AACJ,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAE5D,eAAO,MAAM,YAAY,msCAmEtB,CAAC;AACJ,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAExD;;;;;GAKG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;EAoB9B,CAAC;AACJ,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC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