@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.
- package/dist/agent-capabilities.d.ts +32 -24
- package/dist/agent-capabilities.d.ts.map +1 -1
- package/dist/agent-capabilities.js +20 -11
- package/dist/agent-capabilities.js.map +1 -1
- package/dist/apply-eligibility.d.ts +166 -0
- package/dist/apply-eligibility.d.ts.map +1 -1
- package/dist/apply-eligibility.js +63 -2
- package/dist/apply-eligibility.js.map +1 -1
- package/dist/attachment.d.ts +5 -5
- package/dist/budget.d.ts +4 -4
- package/dist/config.d.ts +59 -41
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +16 -6
- package/dist/config.js.map +1 -1
- package/dist/context.d.ts +6 -6
- package/dist/control-operation-responses.d.ts +190 -97
- package/dist/control-operation-responses.d.ts.map +1 -1
- package/dist/control-operation-responses.js +14 -1
- package/dist/control-operation-responses.js.map +1 -1
- package/dist/control-run-detail.d.ts +347 -215
- package/dist/control-run-detail.d.ts.map +1 -1
- package/dist/control-run-detail.js +34 -7
- package/dist/control-run-detail.js.map +1 -1
- package/dist/control-thread-apply.d.ts +5 -5
- package/dist/control-trust.d.ts +6 -6
- package/dist/control.d.ts +769 -306
- package/dist/control.d.ts.map +1 -1
- package/dist/control.js +164 -61
- package/dist/control.js.map +1 -1
- package/dist/credential-profile.d.ts +400 -1
- package/dist/credential-profile.d.ts.map +1 -1
- package/dist/credential-profile.js +109 -4
- package/dist/credential-profile.js.map +1 -1
- package/dist/decision.d.ts +78 -14
- package/dist/decision.d.ts.map +1 -1
- package/dist/decision.js +53 -20
- package/dist/decision.js.map +1 -1
- package/dist/delivery.d.ts +3 -3
- package/dist/delivery.js +1 -1
- package/dist/delivery.js.map +1 -1
- package/dist/events.d.ts +32 -6
- package/dist/events.d.ts.map +1 -1
- package/dist/events.js +45 -11
- package/dist/events.js.map +1 -1
- package/dist/gate.d.ts +4 -4
- package/dist/gate.d.ts.map +1 -1
- package/dist/gate.js +2 -2
- package/dist/gate.js.map +1 -1
- package/dist/harness.d.ts +137 -47
- package/dist/harness.d.ts.map +1 -1
- package/dist/harness.js +65 -16
- package/dist/harness.js.map +1 -1
- package/dist/index.d.ts +4 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -3
- package/dist/index.js.map +1 -1
- package/dist/operation.d.ts +66 -7
- package/dist/operation.d.ts.map +1 -1
- package/dist/operation.js +29 -2
- package/dist/operation.js.map +1 -1
- package/dist/output-schema.d.ts +40 -0
- package/dist/output-schema.d.ts.map +1 -0
- package/dist/output-schema.js +109 -0
- package/dist/output-schema.js.map +1 -0
- package/dist/plan.d.ts +206 -0
- package/dist/plan.d.ts.map +1 -0
- package/dist/plan.js +107 -0
- package/dist/plan.js.map +1 -0
- package/dist/primitives.d.ts +14 -10
- package/dist/primitives.d.ts.map +1 -1
- package/dist/primitives.js +14 -11
- package/dist/primitives.js.map +1 -1
- package/dist/project.d.ts +75 -0
- package/dist/project.d.ts.map +1 -1
- package/dist/project.js +17 -0
- package/dist/project.js.map +1 -1
- package/dist/quota.d.ts +119 -0
- package/dist/quota.d.ts.map +1 -1
- package/dist/quota.js +22 -0
- package/dist/quota.js.map +1 -1
- package/dist/raw.d.ts +4 -4
- package/dist/readiness.d.ts +14 -7
- package/dist/readiness.d.ts.map +1 -1
- package/dist/run-strategy.d.ts +17 -0
- package/dist/run-strategy.d.ts.map +1 -0
- package/dist/run-strategy.js +47 -0
- package/dist/run-strategy.js.map +1 -0
- package/dist/setup.d.ts +160 -160
- package/dist/status-projection.d.ts +78 -0
- package/dist/status-projection.d.ts.map +1 -0
- package/dist/status-projection.js +171 -0
- package/dist/status-projection.js.map +1 -0
- package/dist/task.d.ts +48 -316
- package/dist/task.d.ts.map +1 -1
- package/dist/task.js +3 -60
- package/dist/task.js.map +1 -1
- package/dist/telemetry.d.ts +89 -89
- package/dist/thread.d.ts +167 -32
- package/dist/thread.d.ts.map +1 -1
- package/dist/thread.js +92 -28
- package/dist/thread.js.map +1 -1
- package/dist/tool-ref.d.ts +1 -1
- package/generated/AgentCapabilityCatalog.schema.json +4 -6
- package/generated/ApplyEligibility.schema.json +1 -1
- package/generated/BudgetLease.schema.json +1 -2
- package/generated/ConformanceReport.schema.json +1 -2
- package/generated/ContinuityDisclosure.schema.json +74 -0
- package/generated/ControlApplyRequest.schema.json +1 -2
- package/generated/ControlCredentialProfileUpdateRequest.schema.json +20 -0
- package/generated/ControlCredentialProfileUpdateResponse.schema.json +142 -0
- package/generated/ControlCredentialProfilesResponse.schema.json +126 -2
- package/generated/ControlDeliveryResponse.schema.json +0 -1
- package/generated/ControlHandshakeResponse.schema.json +31 -3
- package/generated/ControlHarnessListResponse.schema.json +11 -6
- package/generated/ControlHarnessSettingsPatch.schema.json +4 -0
- package/generated/ControlOperationCatalog.schema.json +16 -1
- package/generated/ControlOperationDescriptor.schema.json +15 -0
- package/generated/ControlProject.schema.json +35 -0
- package/generated/ControlProjectListResponse.schema.json +35 -0
- package/generated/ControlProjectOutputsResponse.schema.json +57 -0
- package/generated/ControlQueuedRunInfo.schema.json +2 -11
- package/generated/ControlQuotaResponse.schema.json +42 -0
- package/generated/ControlRunAgainDraft.schema.json +37 -35
- package/generated/ControlRunDecisionRequest.schema.json +0 -1
- package/generated/ControlRunDetail.schema.json +292 -213
- package/generated/ControlRunListResponse.schema.json +88 -27
- package/generated/ControlRunStartRequest.schema.json +37 -35
- package/generated/ControlRunStartResponse.schema.json +2 -11
- package/generated/ControlRunSummary.schema.json +88 -27
- package/generated/ControlSettingsSnapshot.schema.json +6 -11
- package/generated/ControlSettingsUpdateRequest.schema.json +5 -10
- package/generated/ControlThread.schema.json +21 -3
- package/generated/ControlThreadApplyResponse.schema.json +0 -1
- package/generated/ControlThreadCreateRequest.schema.json +12 -3
- package/generated/ControlThreadDetail.schema.json +174 -16
- package/generated/ControlThreadListResponse.schema.json +60 -3
- package/generated/ControlThreadTurnRequest.schema.json +40 -34
- package/generated/ControlThreadUpdateRequest.schema.json +19 -0
- package/generated/DecisionRecord.schema.json +73 -33
- package/generated/GateResult.schema.json +1 -2
- package/generated/GlobalConfig.schema.json +7 -12
- package/generated/HarnessManifest.schema.json +11 -6
- package/generated/HarnessStatusDto.schema.json +11 -6
- package/generated/LaneCheckpoint.schema.json +59 -0
- package/generated/McpRunHandleResult.schema.json +234 -0
- package/generated/McpRunToolResult.schema.json +124 -2
- package/generated/RoutePrimaryDivergedPayload.schema.json +56 -0
- package/generated/RunEvent.schema.json +9 -5
- package/generated/RunTelemetry.schema.json +2 -4
- package/generated/TaskContract.schema.json +3 -135
- package/generated/Thread.schema.json +21 -3
- package/generated/ThreadTurn.schema.json +88 -0
- package/package.json +2 -2
- package/dist/control-spec.d.ts +0 -603
- package/dist/control-spec.d.ts.map +0 -1
- package/dist/control-spec.js +0 -87
- package/dist/control-spec.js.map +0 -1
- package/dist/orchestrate.d.ts +0 -556
- package/dist/orchestrate.d.ts.map +0 -1
- package/dist/orchestrate.js +0 -356
- package/dist/orchestrate.js.map +0 -1
- package/dist/spec.d.ts +0 -678
- package/dist/spec.d.ts.map +0 -1
- package/dist/spec.js +0 -186
- package/dist/spec.js.map +0 -1
- package/generated/ControlSpecAnswersRequest.schema.json +0 -74
- package/generated/ControlSpecQuestionsRequest.schema.json +0 -209
- package/generated/ControlSpecSession.schema.json +0 -261
- package/generated/ControlSpecSessionListResponse.schema.json +0 -273
- package/generated/OrchestrateContract.schema.json +0 -119
- package/generated/OrchestratePlan.schema.json +0 -264
- package/generated/OrchestratePlanProgress.schema.json +0 -164
- package/generated/SessionReboundLineage.schema.json +0 -73
- package/generated/SpecPack.schema.json +0 -483
|
@@ -16,13 +16,21 @@ import { ModeKind } from "./primitives.js";
|
|
|
16
16
|
* daemon-server 400-guards these; the capability catalog must exclude them
|
|
17
17
|
* from the advertised run-control keys, or the catalog would lie to agents.
|
|
18
18
|
* ONE list, two consumers — keep them in lockstep here.
|
|
19
|
+
*
|
|
20
|
+
* `threadId` is server-owned like `turnId` (D10): a thread turn is ALWAYS
|
|
21
|
+
* created through POST /threads/:id/turns (the route owns scope resolution,
|
|
22
|
+
* lineage, and the continuation packet). POST /runs is for one-shot,
|
|
23
|
+
* thread-less runs only — a threadId there would smuggle a turn past the
|
|
24
|
+
* continuity pipeline, so it is refused. The field stays on the schema
|
|
25
|
+
* because the daemon-internal enqueue params still carry it (the turn route
|
|
26
|
+
* fills it in), exactly like turnId.
|
|
19
27
|
*/
|
|
20
|
-
export declare const RUN_START_CLIENT_REJECTED_KEYS: readonly ["turnId", "planRunId"];
|
|
28
|
+
export declare const RUN_START_CLIENT_REJECTED_KEYS: readonly ["threadId", "turnId", "planRunId", "planRef"];
|
|
21
29
|
/**
|
|
22
|
-
* Mode -> tree mutability. ask/plan
|
|
23
|
-
* (Bible invariant); agent writes
|
|
24
|
-
*
|
|
25
|
-
*
|
|
30
|
+
* Mode -> tree mutability. ask/plan are read-only BY CONSTRUCTION
|
|
31
|
+
* (Bible invariant); agent writes. The catalog derives its
|
|
32
|
+
* readOnlyModes/writeModes split from this single map instead of re-encoding
|
|
33
|
+
* the split at each consumer.
|
|
26
34
|
*/
|
|
27
35
|
export declare const MODE_MUTABILITY: Record<z.infer<typeof ModeKind>, "read" | "write">;
|
|
28
36
|
export declare const CatalogModelSummary: z.ZodObject<{
|
|
@@ -160,22 +168,22 @@ export declare const CatalogCliCommand: z.ZodObject<{
|
|
|
160
168
|
}>;
|
|
161
169
|
export type CatalogCliCommand = z.infer<typeof CatalogCliCommand>;
|
|
162
170
|
export declare const CatalogMutabilityMatrix: z.ZodObject<{
|
|
163
|
-
readOnlyModes: z.ZodArray<z.ZodEnum<["ask", "plan", "
|
|
164
|
-
writeModes: z.ZodArray<z.ZodEnum<["ask", "plan", "
|
|
171
|
+
readOnlyModes: z.ZodArray<z.ZodEnum<["ask", "plan", "agent"]>, "many">;
|
|
172
|
+
writeModes: z.ZodArray<z.ZodEnum<["ask", "plan", "agent"]>, "many">;
|
|
165
173
|
isolationKinds: z.ZodArray<z.ZodEnum<["envelope", "live"]>, "many">;
|
|
166
174
|
workspaceModes: z.ZodArray<z.ZodEnum<["in_place", "isolated"]>, "many">;
|
|
167
175
|
accessProfiles: z.ZodArray<z.ZodEnum<["readonly", "workspace_write", "full", "external_sandbox_full", "inherit_native"]>, "many">;
|
|
168
176
|
applyModes: z.ZodArray<z.ZodEnum<["apply", "commit", "branch", "pr"]>, "many">;
|
|
169
177
|
}, "strip", z.ZodTypeAny, {
|
|
170
|
-
readOnlyModes: ("ask" | "plan" | "
|
|
171
|
-
writeModes: ("ask" | "plan" | "
|
|
178
|
+
readOnlyModes: ("ask" | "plan" | "agent")[];
|
|
179
|
+
writeModes: ("ask" | "plan" | "agent")[];
|
|
172
180
|
isolationKinds: ("live" | "envelope")[];
|
|
173
181
|
workspaceModes: ("in_place" | "isolated")[];
|
|
174
182
|
accessProfiles: ("readonly" | "workspace_write" | "full" | "external_sandbox_full" | "inherit_native")[];
|
|
175
183
|
applyModes: ("apply" | "commit" | "branch" | "pr")[];
|
|
176
184
|
}, {
|
|
177
|
-
readOnlyModes: ("ask" | "plan" | "
|
|
178
|
-
writeModes: ("ask" | "plan" | "
|
|
185
|
+
readOnlyModes: ("ask" | "plan" | "agent")[];
|
|
186
|
+
writeModes: ("ask" | "plan" | "agent")[];
|
|
179
187
|
isolationKinds: ("live" | "envelope")[];
|
|
180
188
|
workspaceModes: ("in_place" | "isolated")[];
|
|
181
189
|
accessProfiles: ("readonly" | "workspace_write" | "full" | "external_sandbox_full" | "inherit_native")[];
|
|
@@ -289,25 +297,25 @@ export declare const AgentCapabilityCatalog: z.ZodObject<{
|
|
|
289
297
|
readonlyMechanism: "none" | "fs_sandbox" | "permission_deny" | "tool_allowlist";
|
|
290
298
|
}>, "many">;
|
|
291
299
|
availableHarnesses: z.ZodArray<z.ZodString, "many">;
|
|
292
|
-
modes: z.ZodArray<z.ZodEnum<["ask", "plan", "
|
|
300
|
+
modes: z.ZodArray<z.ZodEnum<["ask", "plan", "agent"]>, "many">;
|
|
293
301
|
runControlKeys: z.ZodArray<z.ZodString, "many">;
|
|
294
302
|
mutability: z.ZodObject<{
|
|
295
|
-
readOnlyModes: z.ZodArray<z.ZodEnum<["ask", "plan", "
|
|
296
|
-
writeModes: z.ZodArray<z.ZodEnum<["ask", "plan", "
|
|
303
|
+
readOnlyModes: z.ZodArray<z.ZodEnum<["ask", "plan", "agent"]>, "many">;
|
|
304
|
+
writeModes: z.ZodArray<z.ZodEnum<["ask", "plan", "agent"]>, "many">;
|
|
297
305
|
isolationKinds: z.ZodArray<z.ZodEnum<["envelope", "live"]>, "many">;
|
|
298
306
|
workspaceModes: z.ZodArray<z.ZodEnum<["in_place", "isolated"]>, "many">;
|
|
299
307
|
accessProfiles: z.ZodArray<z.ZodEnum<["readonly", "workspace_write", "full", "external_sandbox_full", "inherit_native"]>, "many">;
|
|
300
308
|
applyModes: z.ZodArray<z.ZodEnum<["apply", "commit", "branch", "pr"]>, "many">;
|
|
301
309
|
}, "strip", z.ZodTypeAny, {
|
|
302
|
-
readOnlyModes: ("ask" | "plan" | "
|
|
303
|
-
writeModes: ("ask" | "plan" | "
|
|
310
|
+
readOnlyModes: ("ask" | "plan" | "agent")[];
|
|
311
|
+
writeModes: ("ask" | "plan" | "agent")[];
|
|
304
312
|
isolationKinds: ("live" | "envelope")[];
|
|
305
313
|
workspaceModes: ("in_place" | "isolated")[];
|
|
306
314
|
accessProfiles: ("readonly" | "workspace_write" | "full" | "external_sandbox_full" | "inherit_native")[];
|
|
307
315
|
applyModes: ("apply" | "commit" | "branch" | "pr")[];
|
|
308
316
|
}, {
|
|
309
|
-
readOnlyModes: ("ask" | "plan" | "
|
|
310
|
-
writeModes: ("ask" | "plan" | "
|
|
317
|
+
readOnlyModes: ("ask" | "plan" | "agent")[];
|
|
318
|
+
writeModes: ("ask" | "plan" | "agent")[];
|
|
311
319
|
isolationKinds: ("live" | "envelope")[];
|
|
312
320
|
workspaceModes: ("in_place" | "isolated")[];
|
|
313
321
|
accessProfiles: ("readonly" | "workspace_write" | "full" | "external_sandbox_full" | "inherit_native")[];
|
|
@@ -336,8 +344,8 @@ export declare const AgentCapabilityCatalog: z.ZodObject<{
|
|
|
336
344
|
ok: true;
|
|
337
345
|
version: string;
|
|
338
346
|
mutability: {
|
|
339
|
-
readOnlyModes: ("ask" | "plan" | "
|
|
340
|
-
writeModes: ("ask" | "plan" | "
|
|
347
|
+
readOnlyModes: ("ask" | "plan" | "agent")[];
|
|
348
|
+
writeModes: ("ask" | "plan" | "agent")[];
|
|
341
349
|
isolationKinds: ("live" | "envelope")[];
|
|
342
350
|
workspaceModes: ("in_place" | "isolated")[];
|
|
343
351
|
accessProfiles: ("readonly" | "workspace_write" | "full" | "external_sandbox_full" | "inherit_native")[];
|
|
@@ -372,7 +380,7 @@ export declare const AgentCapabilityCatalog: z.ZodObject<{
|
|
|
372
380
|
readonlyMechanism: "none" | "fs_sandbox" | "permission_deny" | "tool_allowlist";
|
|
373
381
|
}[];
|
|
374
382
|
availableHarnesses: string[];
|
|
375
|
-
modes: ("ask" | "plan" | "
|
|
383
|
+
modes: ("ask" | "plan" | "agent")[];
|
|
376
384
|
runControlKeys: string[];
|
|
377
385
|
cliCommands: {
|
|
378
386
|
id: string;
|
|
@@ -387,8 +395,8 @@ export declare const AgentCapabilityCatalog: z.ZodObject<{
|
|
|
387
395
|
ok: true;
|
|
388
396
|
version: string;
|
|
389
397
|
mutability: {
|
|
390
|
-
readOnlyModes: ("ask" | "plan" | "
|
|
391
|
-
writeModes: ("ask" | "plan" | "
|
|
398
|
+
readOnlyModes: ("ask" | "plan" | "agent")[];
|
|
399
|
+
writeModes: ("ask" | "plan" | "agent")[];
|
|
392
400
|
isolationKinds: ("live" | "envelope")[];
|
|
393
401
|
workspaceModes: ("in_place" | "isolated")[];
|
|
394
402
|
accessProfiles: ("readonly" | "workspace_write" | "full" | "external_sandbox_full" | "inherit_native")[];
|
|
@@ -423,7 +431,7 @@ export declare const AgentCapabilityCatalog: z.ZodObject<{
|
|
|
423
431
|
readonlyMechanism: "none" | "fs_sandbox" | "permission_deny" | "tool_allowlist";
|
|
424
432
|
}[];
|
|
425
433
|
availableHarnesses: string[];
|
|
426
|
-
modes: ("ask" | "plan" | "
|
|
434
|
+
modes: ("ask" | "plan" | "agent")[];
|
|
427
435
|
runControlKeys: string[];
|
|
428
436
|
cliCommands: {
|
|
429
437
|
id: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-capabilities.d.ts","sourceRoot":"","sources":["../src/agent-capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAiB,QAAQ,EAAkB,MAAM,iBAAiB,CAAC;AAK1E;;;;;;;;GAQG;AAEH
|
|
1
|
+
{"version":3,"file":"agent-capabilities.d.ts","sourceRoot":"","sources":["../src/agent-capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAiB,QAAQ,EAAkB,MAAM,iBAAiB,CAAC;AAK1E;;;;;;;;GAQG;AAEH;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,8BAA8B,yDAKjC,CAAC;AAEX;;;;;GAKG;AACH,eAAO,MAAM,eAAe,EAAE,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO,CAI9E,CAAC;AAEF,eAAO,MAAM,mBAAmB;;;;;;;;;;;;EAmBkE,CAAC;AACnG,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmDsD,CAAC;AAClF,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAE5D,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;EAe3B,CAAC;AACJ,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;EAyBjC,CAAC;AACJ,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAE9E,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAoChC,CAAC;AACJ,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC"}
|
|
@@ -19,20 +19,31 @@ import { AttachmentInputClass } from "./attachment.js";
|
|
|
19
19
|
* daemon-server 400-guards these; the capability catalog must exclude them
|
|
20
20
|
* from the advertised run-control keys, or the catalog would lie to agents.
|
|
21
21
|
* ONE list, two consumers — keep them in lockstep here.
|
|
22
|
+
*
|
|
23
|
+
* `threadId` is server-owned like `turnId` (D10): a thread turn is ALWAYS
|
|
24
|
+
* created through POST /threads/:id/turns (the route owns scope resolution,
|
|
25
|
+
* lineage, and the continuation packet). POST /runs is for one-shot,
|
|
26
|
+
* thread-less runs only — a threadId there would smuggle a turn past the
|
|
27
|
+
* continuity pipeline, so it is refused. The field stays on the schema
|
|
28
|
+
* because the daemon-internal enqueue params still carry it (the turn route
|
|
29
|
+
* fills it in), exactly like turnId.
|
|
22
30
|
*/
|
|
23
|
-
export const RUN_START_CLIENT_REJECTED_KEYS = [
|
|
31
|
+
export const RUN_START_CLIENT_REJECTED_KEYS = [
|
|
32
|
+
"threadId",
|
|
33
|
+
"turnId",
|
|
34
|
+
"planRunId",
|
|
35
|
+
"planRef",
|
|
36
|
+
];
|
|
24
37
|
/**
|
|
25
|
-
* Mode -> tree mutability. ask/plan
|
|
26
|
-
* (Bible invariant); agent writes
|
|
27
|
-
*
|
|
28
|
-
*
|
|
38
|
+
* Mode -> tree mutability. ask/plan are read-only BY CONSTRUCTION
|
|
39
|
+
* (Bible invariant); agent writes. The catalog derives its
|
|
40
|
+
* readOnlyModes/writeModes split from this single map instead of re-encoding
|
|
41
|
+
* the split at each consumer.
|
|
29
42
|
*/
|
|
30
43
|
export const MODE_MUTABILITY = {
|
|
31
44
|
ask: "read",
|
|
32
45
|
plan: "read",
|
|
33
|
-
audit: "read",
|
|
34
46
|
agent: "write",
|
|
35
|
-
orchestrate: "write",
|
|
36
47
|
};
|
|
37
48
|
export const CatalogModelSummary = z
|
|
38
49
|
.object({
|
|
@@ -110,10 +121,8 @@ export const CatalogMutabilityMatrix = z
|
|
|
110
121
|
.object({
|
|
111
122
|
readOnlyModes: z
|
|
112
123
|
.array(ModeKind)
|
|
113
|
-
.describe("Canonical modes that never mutate the project tree (ask/plan
|
|
114
|
-
writeModes: z
|
|
115
|
-
.array(ModeKind)
|
|
116
|
-
.describe("Canonical modes that may mutate a tree (agent always; orchestrate only above suggest autonomy)."),
|
|
124
|
+
.describe("Canonical modes that never mutate the project tree (ask/plan)."),
|
|
125
|
+
writeModes: z.array(ModeKind).describe("Canonical modes that may mutate a tree (agent)."),
|
|
117
126
|
isolationKinds: z
|
|
118
127
|
.array(z.enum(["envelope", "live"]))
|
|
119
128
|
.describe("Run isolation: envelope = isolated worktree in the external per-project runtime namespace (default), live = the project tree itself."),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-capabilities.js","sourceRoot":"","sources":["../src/agent-capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAC1E,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAC5E,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAEvD;;;;;;;;GAQG;AAEH
|
|
1
|
+
{"version":3,"file":"agent-capabilities.js","sourceRoot":"","sources":["../src/agent-capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAC1E,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAC5E,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAEvD;;;;;;;;GAQG;AAEH;;;;;;;;;;;;;;;GAeG;AACH,MAAM,CAAC,MAAM,8BAA8B,GAAG;IAC5C,UAAU;IACV,QAAQ;IACR,WAAW;IACX,SAAS;CACD,CAAC;AAEX;;;;;GAKG;AACH,MAAM,CAAC,MAAM,eAAe,GAAuD;IACjF,GAAG,EAAE,MAAM;IACX,IAAI,EAAE,MAAM;IACZ,KAAK,EAAE,OAAO;CACf,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC;KACjC,MAAM,CAAC;IACN,MAAM,EAAE,CAAC;SACN,IAAI,CAAC,CAAC,KAAK,EAAE,UAAU,EAAE,MAAM,CAAC,CAAC;SACjC,QAAQ,CACP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,EAAE,uBAAuB;IACnC,WAAW,EAAE,CAAC;SACX,KAAK,CAAC,iBAAiB,CAAC;SACxB,QAAQ,CACP,qFAAqF,CACtF;IACH,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,CAAC,+CAA+C,CAAC;IACvF,cAAc,EAAE,CAAC;SACd,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;SACjB,QAAQ,CACP,gMAAgM,CACjM;CACJ,CAAC;KACD,QAAQ,CACP,2FAA2F,CAC5F,CAAC"}
|
|
@@ -33,6 +33,25 @@ export declare const McpRunToolResult: z.ZodObject<{
|
|
|
33
33
|
runId: z.ZodNullable<z.ZodString>;
|
|
34
34
|
runDir: z.ZodNullable<z.ZodString>;
|
|
35
35
|
status: z.ZodNullable<z.ZodString>;
|
|
36
|
+
outcomeFacts: z.ZodDefault<z.ZodNullable<z.ZodObject<{
|
|
37
|
+
lifecycle: z.ZodEnum<["succeeded", "failed", "cancelled", "interrupted"]>;
|
|
38
|
+
noChanges: z.ZodDefault<z.ZodBoolean>;
|
|
39
|
+
checks: z.ZodDefault<z.ZodEnum<["passed", "failed", "not_configured"]>>;
|
|
40
|
+
review: z.ZodDefault<z.ZodEnum<["approved", "blocked", "not_run"]>>;
|
|
41
|
+
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"]>>>;
|
|
42
|
+
}, "strict", z.ZodTypeAny, {
|
|
43
|
+
review: "not_run" | "approved" | "blocked";
|
|
44
|
+
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;
|
|
45
|
+
checks: "passed" | "failed" | "not_configured";
|
|
46
|
+
lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
|
|
47
|
+
noChanges: boolean;
|
|
48
|
+
}, {
|
|
49
|
+
lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
|
|
50
|
+
review?: "not_run" | "approved" | "blocked" | undefined;
|
|
51
|
+
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;
|
|
52
|
+
checks?: "passed" | "failed" | "not_configured" | undefined;
|
|
53
|
+
noChanges?: boolean | undefined;
|
|
54
|
+
}>>>;
|
|
36
55
|
applyEligibility: z.ZodNullable<z.ZodObject<{
|
|
37
56
|
eligible: z.ZodBoolean;
|
|
38
57
|
state: z.ZodNullable<z.ZodString>;
|
|
@@ -49,17 +68,40 @@ export declare const McpRunToolResult: z.ZodObject<{
|
|
|
49
68
|
eligible: boolean;
|
|
50
69
|
requiredAction: string | null;
|
|
51
70
|
}>>;
|
|
71
|
+
outcomeBanner: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
72
|
+
planReadiness: z.ZodDefault<z.ZodNullable<z.ZodObject<{
|
|
73
|
+
state: z.ZodEnum<["ready", "needs_answers", "unverified"]>;
|
|
74
|
+
questionCount: z.ZodDefault<z.ZodNumber>;
|
|
75
|
+
}, "strict", z.ZodTypeAny, {
|
|
76
|
+
state: "ready" | "needs_answers" | "unverified";
|
|
77
|
+
questionCount: number;
|
|
78
|
+
}, {
|
|
79
|
+
state: "ready" | "needs_answers" | "unverified";
|
|
80
|
+
questionCount?: number | undefined;
|
|
81
|
+
}>>>;
|
|
52
82
|
}, "strip", z.ZodTypeAny, {
|
|
53
83
|
status: string | null;
|
|
54
84
|
summary: string;
|
|
55
85
|
runId: string | null;
|
|
56
86
|
runDir: string | null;
|
|
87
|
+
outcomeFacts: {
|
|
88
|
+
review: "not_run" | "approved" | "blocked";
|
|
89
|
+
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;
|
|
90
|
+
checks: "passed" | "failed" | "not_configured";
|
|
91
|
+
lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
|
|
92
|
+
noChanges: boolean;
|
|
93
|
+
} | null;
|
|
57
94
|
applyEligibility: {
|
|
58
95
|
state: string | null;
|
|
59
96
|
reason: string | null;
|
|
60
97
|
eligible: boolean;
|
|
61
98
|
requiredAction: string | null;
|
|
62
99
|
} | null;
|
|
100
|
+
outcomeBanner: string | null;
|
|
101
|
+
planReadiness: {
|
|
102
|
+
state: "ready" | "needs_answers" | "unverified";
|
|
103
|
+
questionCount: number;
|
|
104
|
+
} | null;
|
|
63
105
|
}, {
|
|
64
106
|
status: string | null;
|
|
65
107
|
summary: string;
|
|
@@ -71,6 +113,130 @@ export declare const McpRunToolResult: z.ZodObject<{
|
|
|
71
113
|
eligible: boolean;
|
|
72
114
|
requiredAction: string | null;
|
|
73
115
|
} | null;
|
|
116
|
+
outcomeFacts?: {
|
|
117
|
+
lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
|
|
118
|
+
review?: "not_run" | "approved" | "blocked" | undefined;
|
|
119
|
+
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;
|
|
120
|
+
checks?: "passed" | "failed" | "not_configured" | undefined;
|
|
121
|
+
noChanges?: boolean | undefined;
|
|
122
|
+
} | null | undefined;
|
|
123
|
+
outcomeBanner?: string | null | undefined;
|
|
124
|
+
planReadiness?: {
|
|
125
|
+
state: "ready" | "needs_answers" | "unverified";
|
|
126
|
+
questionCount?: number | undefined;
|
|
127
|
+
} | null | undefined;
|
|
74
128
|
}>;
|
|
75
129
|
export type McpRunToolResult = z.infer<typeof McpRunToolResult>;
|
|
130
|
+
/**
|
|
131
|
+
* The structured result shape the MCP READ tools (claudexor_inspect /
|
|
132
|
+
* claudexor_run_status / claudexor_run_result) return: a durable run handle
|
|
133
|
+
* projected from GET /runs/:id through the SAME axes every surface reads.
|
|
134
|
+
* Strict — the read tools emit exactly these keys so hosts can branch on a
|
|
135
|
+
* declared shape instead of a free-text blob (v3: no legacy extra fields).
|
|
136
|
+
*/
|
|
137
|
+
export declare const McpRunHandleResult: z.ZodObject<{
|
|
138
|
+
summary: z.ZodString;
|
|
139
|
+
runId: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
140
|
+
runDir: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
141
|
+
status: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
142
|
+
decisionStatus: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
143
|
+
pendingInteractions: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
144
|
+
outcomeFacts: z.ZodDefault<z.ZodNullable<z.ZodObject<{
|
|
145
|
+
lifecycle: z.ZodEnum<["succeeded", "failed", "cancelled", "interrupted"]>;
|
|
146
|
+
noChanges: z.ZodDefault<z.ZodBoolean>;
|
|
147
|
+
checks: z.ZodDefault<z.ZodEnum<["passed", "failed", "not_configured"]>>;
|
|
148
|
+
review: z.ZodDefault<z.ZodEnum<["approved", "blocked", "not_run"]>>;
|
|
149
|
+
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"]>>>;
|
|
150
|
+
}, "strict", z.ZodTypeAny, {
|
|
151
|
+
review: "not_run" | "approved" | "blocked";
|
|
152
|
+
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;
|
|
153
|
+
checks: "passed" | "failed" | "not_configured";
|
|
154
|
+
lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
|
|
155
|
+
noChanges: boolean;
|
|
156
|
+
}, {
|
|
157
|
+
lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
|
|
158
|
+
review?: "not_run" | "approved" | "blocked" | undefined;
|
|
159
|
+
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;
|
|
160
|
+
checks?: "passed" | "failed" | "not_configured" | undefined;
|
|
161
|
+
noChanges?: boolean | undefined;
|
|
162
|
+
}>>>;
|
|
163
|
+
outcomeBanner: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
164
|
+
applyEligibility: z.ZodDefault<z.ZodNullable<z.ZodObject<{
|
|
165
|
+
eligible: z.ZodBoolean;
|
|
166
|
+
state: z.ZodNullable<z.ZodString>;
|
|
167
|
+
reason: z.ZodNullable<z.ZodString>;
|
|
168
|
+
requiredAction: z.ZodNullable<z.ZodString>;
|
|
169
|
+
}, "strip", z.ZodTypeAny, {
|
|
170
|
+
state: string | null;
|
|
171
|
+
reason: string | null;
|
|
172
|
+
eligible: boolean;
|
|
173
|
+
requiredAction: string | null;
|
|
174
|
+
}, {
|
|
175
|
+
state: string | null;
|
|
176
|
+
reason: string | null;
|
|
177
|
+
eligible: boolean;
|
|
178
|
+
requiredAction: string | null;
|
|
179
|
+
}>>>;
|
|
180
|
+
planReadiness: z.ZodDefault<z.ZodNullable<z.ZodObject<{
|
|
181
|
+
state: z.ZodEnum<["ready", "needs_answers", "unverified"]>;
|
|
182
|
+
questionCount: z.ZodDefault<z.ZodNumber>;
|
|
183
|
+
}, "strict", z.ZodTypeAny, {
|
|
184
|
+
state: "ready" | "needs_answers" | "unverified";
|
|
185
|
+
questionCount: number;
|
|
186
|
+
}, {
|
|
187
|
+
state: "ready" | "needs_answers" | "unverified";
|
|
188
|
+
questionCount?: number | undefined;
|
|
189
|
+
}>>>;
|
|
190
|
+
}, "strict", z.ZodTypeAny, {
|
|
191
|
+
status: string | null;
|
|
192
|
+
summary: string;
|
|
193
|
+
runId: string | null;
|
|
194
|
+
runDir: string | null;
|
|
195
|
+
outcomeFacts: {
|
|
196
|
+
review: "not_run" | "approved" | "blocked";
|
|
197
|
+
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;
|
|
198
|
+
checks: "passed" | "failed" | "not_configured";
|
|
199
|
+
lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
|
|
200
|
+
noChanges: boolean;
|
|
201
|
+
} | null;
|
|
202
|
+
applyEligibility: {
|
|
203
|
+
state: string | null;
|
|
204
|
+
reason: string | null;
|
|
205
|
+
eligible: boolean;
|
|
206
|
+
requiredAction: string | null;
|
|
207
|
+
} | null;
|
|
208
|
+
outcomeBanner: string | null;
|
|
209
|
+
planReadiness: {
|
|
210
|
+
state: "ready" | "needs_answers" | "unverified";
|
|
211
|
+
questionCount: number;
|
|
212
|
+
} | null;
|
|
213
|
+
decisionStatus: string | null;
|
|
214
|
+
pendingInteractions: number | null;
|
|
215
|
+
}, {
|
|
216
|
+
summary: string;
|
|
217
|
+
status?: string | null | undefined;
|
|
218
|
+
runId?: string | null | undefined;
|
|
219
|
+
runDir?: string | null | undefined;
|
|
220
|
+
outcomeFacts?: {
|
|
221
|
+
lifecycle: "failed" | "cancelled" | "succeeded" | "interrupted";
|
|
222
|
+
review?: "not_run" | "approved" | "blocked" | undefined;
|
|
223
|
+
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;
|
|
224
|
+
checks?: "passed" | "failed" | "not_configured" | undefined;
|
|
225
|
+
noChanges?: boolean | undefined;
|
|
226
|
+
} | null | undefined;
|
|
227
|
+
applyEligibility?: {
|
|
228
|
+
state: string | null;
|
|
229
|
+
reason: string | null;
|
|
230
|
+
eligible: boolean;
|
|
231
|
+
requiredAction: string | null;
|
|
232
|
+
} | null | undefined;
|
|
233
|
+
outcomeBanner?: string | null | undefined;
|
|
234
|
+
planReadiness?: {
|
|
235
|
+
state: "ready" | "needs_answers" | "unverified";
|
|
236
|
+
questionCount?: number | undefined;
|
|
237
|
+
} | null | undefined;
|
|
238
|
+
decisionStatus?: string | null | undefined;
|
|
239
|
+
pendingInteractions?: number | null | undefined;
|
|
240
|
+
}>;
|
|
241
|
+
export type McpRunHandleResult = z.infer<typeof McpRunHandleResult>;
|
|
76
242
|
//# sourceMappingURL=apply-eligibility.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apply-eligibility.d.ts","sourceRoot":"","sources":["../src/apply-eligibility.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"apply-eligibility.d.ts","sourceRoot":"","sources":["../src/apply-eligibility.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;EAwB1B,CAAC;AACJ,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE;;;GAGG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsCqC,CAAC;AACnE,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE;;;;;;GAMG;AACH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAwCmE,CAAC;AACnG,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC"}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
+
import { RunOutcomeFacts } from "./decision.js";
|
|
3
|
+
import { PlanReadiness } from "./plan.js";
|
|
2
4
|
/**
|
|
3
5
|
* ApplyEligibility — the derived "can this run's WorkProduct be applied RIGHT
|
|
4
6
|
* NOW, and if not, what unblocks it" verdict. ONE producer (the delivery
|
|
@@ -15,7 +17,7 @@ export const ApplyEligibility = z
|
|
|
15
17
|
state: z
|
|
16
18
|
.string()
|
|
17
19
|
.nullable()
|
|
18
|
-
.describe("The gate's
|
|
20
|
+
.describe("The gate's apply-eligibility classification (e.g. needs_review | not_verified | no_changes | ok) when known."),
|
|
19
21
|
reason: z
|
|
20
22
|
.string()
|
|
21
23
|
.nullable()
|
|
@@ -46,8 +48,67 @@ export const McpRunToolResult = z
|
|
|
46
48
|
status: z
|
|
47
49
|
.string()
|
|
48
50
|
.nullable()
|
|
49
|
-
.describe("Terminal run
|
|
51
|
+
.describe("Terminal run LIFECYCLE (succeeded | failed | cancelled | interrupted)."),
|
|
52
|
+
outcomeFacts: RunOutcomeFacts.nullable()
|
|
53
|
+
.default(null)
|
|
54
|
+
.describe("The D8 terminal outcome axes (checks/review/reason/noChanges); null for non-terminal or read-only routes."),
|
|
50
55
|
applyEligibility: ApplyEligibility.nullable().describe("Apply-gate verdict for mutating runs; null for read-only routes or when no patch exists."),
|
|
56
|
+
outcomeBanner: z
|
|
57
|
+
.string()
|
|
58
|
+
.nullable()
|
|
59
|
+
.default(null)
|
|
60
|
+
.describe("Server-owned outcome headline (D18); the single honest one-line verdict, null while non-terminal or unavailable."),
|
|
61
|
+
planReadiness: PlanReadiness.nullable()
|
|
62
|
+
.default(null)
|
|
63
|
+
.describe("Derived plan readiness for plan tools (D17); null for non-plan tools."),
|
|
51
64
|
})
|
|
52
65
|
.describe("Structured MCP tool result for Claudexor run tools.");
|
|
66
|
+
/**
|
|
67
|
+
* The structured result shape the MCP READ tools (claudexor_inspect /
|
|
68
|
+
* claudexor_run_status / claudexor_run_result) return: a durable run handle
|
|
69
|
+
* projected from GET /runs/:id through the SAME axes every surface reads.
|
|
70
|
+
* Strict — the read tools emit exactly these keys so hosts can branch on a
|
|
71
|
+
* declared shape instead of a free-text blob (v3: no legacy extra fields).
|
|
72
|
+
*/
|
|
73
|
+
export const McpRunHandleResult = z
|
|
74
|
+
.object({
|
|
75
|
+
summary: z
|
|
76
|
+
.string()
|
|
77
|
+
.describe("Human-readable outcome/status text (same as the tool's text content)."),
|
|
78
|
+
runId: z.string().nullable().default(null).describe("The daemon run id, when known."),
|
|
79
|
+
runDir: z.string().nullable().default(null).describe("Artifact directory; null when absent."),
|
|
80
|
+
status: z
|
|
81
|
+
.string()
|
|
82
|
+
.nullable()
|
|
83
|
+
.default(null)
|
|
84
|
+
.describe("The run's terminal or in-flight lifecycle state, when known."),
|
|
85
|
+
decisionStatus: z
|
|
86
|
+
.string()
|
|
87
|
+
.nullable()
|
|
88
|
+
.default(null)
|
|
89
|
+
.describe("The arbitration decision status, when the run reached arbitration."),
|
|
90
|
+
pendingInteractions: z
|
|
91
|
+
.number()
|
|
92
|
+
.int()
|
|
93
|
+
.nonnegative()
|
|
94
|
+
.nullable()
|
|
95
|
+
.default(null)
|
|
96
|
+
.describe("Count of questions still awaiting answers, when known."),
|
|
97
|
+
outcomeFacts: RunOutcomeFacts.nullable()
|
|
98
|
+
.default(null)
|
|
99
|
+
.describe("The D8 terminal outcome axes (checks/review/reason/noChanges), when terminal."),
|
|
100
|
+
outcomeBanner: z
|
|
101
|
+
.string()
|
|
102
|
+
.nullable()
|
|
103
|
+
.default(null)
|
|
104
|
+
.describe("Server-owned outcome headline (D18); null while non-terminal."),
|
|
105
|
+
applyEligibility: ApplyEligibility.nullable()
|
|
106
|
+
.default(null)
|
|
107
|
+
.describe("Derived apply-gate verdict; null for read-only runs or when no patch exists."),
|
|
108
|
+
planReadiness: PlanReadiness.nullable()
|
|
109
|
+
.default(null)
|
|
110
|
+
.describe("Derived plan readiness (plan runs only, D17); null otherwise."),
|
|
111
|
+
})
|
|
112
|
+
.strict()
|
|
113
|
+
.describe("Structured MCP result for Claudexor durable-run read tools (inspect/status/result).");
|
|
53
114
|
//# sourceMappingURL=apply-eligibility.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apply-eligibility.js","sourceRoot":"","sources":["../src/apply-eligibility.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"apply-eligibility.js","sourceRoot":"","sources":["../src/apply-eligibility.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAE1C;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC;KAC9B,MAAM,CAAC;IACN,QAAQ,EAAE,CAAC;SACR,OAAO,EAAE;SACT,QAAQ,CAAC,mEAAmE,CAAC;IAChF,KAAK,EAAE,CAAC;SACL,MAAM,EAAE;SACR,QAAQ,EAAE;SACV,QAAQ,CACP,8GAA8G,CAC/G;IACH,MAAM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16 +21,16 @@ export declare const Attachment: z.ZodObject<{
|
|
|
21
21
|
path: z.ZodString;
|
|
22
22
|
}, "strict", z.ZodTypeAny, {
|
|
23
23
|
path: string;
|
|
24
|
-
name: string;
|
|
25
24
|
kind: "file" | "image";
|
|
25
|
+
name: string;
|
|
26
26
|
resource_id: string;
|
|
27
27
|
mime: string;
|
|
28
28
|
sha256: string;
|
|
29
29
|
size_bytes: number;
|
|
30
30
|
}, {
|
|
31
31
|
path: string;
|
|
32
|
-
name: string;
|
|
33
32
|
kind: "file" | "image";
|
|
33
|
+
name: string;
|
|
34
34
|
resource_id: string;
|
|
35
35
|
mime: string;
|
|
36
36
|
sha256: string;
|
|
@@ -66,8 +66,8 @@ export declare const ControlUploadCreateRequest: z.ZodObject<{
|
|
|
66
66
|
name: z.ZodDefault<z.ZodString>;
|
|
67
67
|
sizeBytes: z.ZodNumber;
|
|
68
68
|
}, "strict", z.ZodTypeAny, {
|
|
69
|
-
name: string;
|
|
70
69
|
kind: "file" | "image";
|
|
70
|
+
name: string;
|
|
71
71
|
mime: string;
|
|
72
72
|
sizeBytes: number;
|
|
73
73
|
}, {
|
|
@@ -104,8 +104,8 @@ export declare const ControlResource: z.ZodObject<{
|
|
|
104
104
|
createdAt: z.ZodString;
|
|
105
105
|
deduplicated: z.ZodBoolean;
|
|
106
106
|
}, "strict", z.ZodTypeAny, {
|
|
107
|
-
name: string;
|
|
108
107
|
kind: "file" | "image";
|
|
108
|
+
name: string;
|
|
109
109
|
resourceId: string;
|
|
110
110
|
mime: string;
|
|
111
111
|
sha256: string;
|
|
@@ -113,8 +113,8 @@ export declare const ControlResource: z.ZodObject<{
|
|
|
113
113
|
createdAt: string;
|
|
114
114
|
deduplicated: boolean;
|
|
115
115
|
}, {
|
|
116
|
-
name: string;
|
|
117
116
|
kind: "file" | "image";
|
|
117
|
+
name: string;
|
|
118
118
|
resourceId: string;
|
|
119
119
|
mime: string;
|
|
120
120
|
sha256: string;
|
package/dist/budget.d.ts
CHANGED
|
@@ -70,7 +70,7 @@ export declare const QualityTier: z.ZodArray<z.ZodObject<{
|
|
|
70
70
|
effort: "low" | "medium" | "high" | "xhigh" | "max";
|
|
71
71
|
}>, "many">;
|
|
72
72
|
export type QualityTier = z.infer<typeof QualityTier>;
|
|
73
|
-
export declare const QualityTierSet: z.ZodDefault<z.ZodRecord<z.ZodEnum<["plan", "spec", "implement", "create_from_scratch", "repair", "review", "verify", "synthesize", "explain", "audit"
|
|
73
|
+
export declare const QualityTierSet: z.ZodDefault<z.ZodRecord<z.ZodEnum<["plan", "spec", "implement", "create_from_scratch", "repair", "review", "verify", "synthesize", "explain", "audit"]>, z.ZodArray<z.ZodArray<z.ZodObject<{
|
|
74
74
|
harness: z.ZodString;
|
|
75
75
|
model: z.ZodString;
|
|
76
76
|
effort: z.ZodEnum<["low", "medium", "high", "xhigh", "max"]>;
|
|
@@ -89,7 +89,7 @@ export declare const BudgetLease: z.ZodObject<{
|
|
|
89
89
|
lease_id: z.ZodString;
|
|
90
90
|
task_id: z.ZodString;
|
|
91
91
|
attempt_id: z.ZodOptional<z.ZodString>;
|
|
92
|
-
intent: z.ZodEnum<["plan", "spec", "implement", "create_from_scratch", "repair", "review", "verify", "synthesize", "explain", "audit"
|
|
92
|
+
intent: z.ZodEnum<["plan", "spec", "implement", "create_from_scratch", "repair", "review", "verify", "synthesize", "explain", "audit"]>;
|
|
93
93
|
harness_id: z.ZodString;
|
|
94
94
|
model_hint: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
95
95
|
cost: z.ZodObject<{
|
|
@@ -119,7 +119,7 @@ export declare const BudgetLease: z.ZodObject<{
|
|
|
119
119
|
harness_id: string;
|
|
120
120
|
created_at: string;
|
|
121
121
|
reason: string[];
|
|
122
|
-
intent: "plan" | "
|
|
122
|
+
intent: "plan" | "spec" | "implement" | "create_from_scratch" | "repair" | "review" | "verify" | "synthesize" | "explain" | "audit";
|
|
123
123
|
model_hint: string | null;
|
|
124
124
|
lease_id: string;
|
|
125
125
|
task_id: string;
|
|
@@ -134,7 +134,7 @@ export declare const BudgetLease: z.ZodObject<{
|
|
|
134
134
|
}, {
|
|
135
135
|
harness_id: string;
|
|
136
136
|
created_at: string;
|
|
137
|
-
intent: "plan" | "
|
|
137
|
+
intent: "plan" | "spec" | "implement" | "create_from_scratch" | "repair" | "review" | "verify" | "synthesize" | "explain" | "audit";
|
|
138
138
|
lease_id: string;
|
|
139
139
|
task_id: string;
|
|
140
140
|
cost: {
|