opencode-swarm 7.173.1 → 7.175.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.opencode/skills/swarm-pr-review/references/findings-persistence-contract.md +37 -0
- package/binaries/win32-arm64/swarm-sandbox-runner.exe +0 -0
- package/binaries/win32-x64/swarm-sandbox-runner.exe +0 -0
- package/dist/agents/critic.d.ts +44 -2
- package/dist/background/pending-delegations.d.ts +10 -0
- package/dist/background/pr-review-contract.d.ts +27 -0
- package/dist/background/stage-b-gates.d.ts +29 -0
- package/dist/background/status-artifact.d.ts +24 -1
- package/dist/cli/{coder-settlement-kxxmd9jt.js → coder-settlement-f2n9yp7a.js} +11 -11
- package/dist/cli/{config-doctor-nzcya5zr.js → config-doctor-zcyz614n.js} +2 -2
- package/dist/cli/{core-s9a9kmcc.js → core-jar8cmzf.js} +3 -3
- package/dist/cli/{curation-policy-tx4kb30e.js → curation-policy-e5p147bb.js} +5 -5
- package/dist/cli/{curator-jkp8558s.js → curator-3xfz7wdp.js} +36 -36
- package/dist/cli/{curator-drift-047n8fjw.js → curator-drift-x3tt8apf.js} +4 -4
- package/dist/cli/curator-llm-factory-rc7cqtx8.js +72 -0
- package/dist/cli/{evidence-summary-service-ek50h5b3.js → evidence-summary-service-bpe04ngj.js} +15 -15
- package/dist/cli/{gate-evidence-8dk50ten.js → gate-evidence-pyzzafp3.js} +6 -6
- package/dist/cli/guardrail-explain-ncrw7k8h.js +73 -0
- package/dist/cli/{guardrail-log-hq5xpm7g.js → guardrail-log-nn2t8xyd.js} +7 -7
- package/dist/cli/{guardrail-reset-gttz1y0h.js → guardrail-reset-3c3c7e5e.js} +36 -36
- package/dist/cli/{hive-promoter-44p7ng87.js → hive-promoter-xfbabpnm.js} +36 -36
- package/dist/cli/{index-53c0ajk4.js → index-20q20gpd.js} +1 -1
- package/dist/cli/{index-m51cmzxt.js → index-2dv07mw2.js} +1 -1
- package/dist/cli/{index-fnx0jzf7.js → index-2xwavnbg.js} +1 -1
- package/dist/cli/{index-62pcs7jg.js → index-4rm5saxs.js} +3 -3
- package/dist/cli/{index-za1kvsa0.js → index-5t71wd7j.js} +2 -2
- package/dist/cli/{index-dktpzjy9.js → index-6tbnev6y.js} +1 -1
- package/dist/cli/{index-1xfxzjq9.js → index-6yqszgky.js} +2 -2
- package/dist/cli/{index-pynk60z5.js → index-8bbhh3kx.js} +8 -8
- package/dist/cli/{index-bsnpv4xd.js → index-8tn4yx8b.js} +2 -2
- package/dist/cli/{index-mt8pbzda.js → index-96hz14wr.js} +12 -12
- package/dist/cli/{index-z35ynvj4.js → index-98r0bh1c.js} +1 -1
- package/dist/cli/{index-psb9rxt8.js → index-9gpe25nr.js} +5 -5
- package/dist/cli/{index-wf3s2t1t.js → index-ar3ve24w.js} +3005 -2328
- package/dist/cli/{index-dx9pz5n6.js → index-bmk77mpq.js} +7 -7
- package/dist/cli/{index-ndvgkxpf.js → index-c60t3sw6.js} +2 -2
- package/dist/cli/{index-43dmpa9w.js → index-cpgh76bk.js} +2 -2
- package/dist/cli/{index-evf5r7bk.js → index-czhbsgdh.js} +1 -1
- package/dist/cli/{index-j0vvq8se.js → index-d0wq7paf.js} +7 -7
- package/dist/cli/{index-cm0339fe.js → index-ddvva9fn.js} +4 -4
- package/dist/cli/{index-mjqjbq94.js → index-fzvh6trw.js} +11 -11
- package/dist/cli/{index-pjw95rxm.js → index-gtej1br8.js} +65 -10
- package/dist/cli/{index-c5nrcde1.js → index-hdwdapp6.js} +38 -38
- package/dist/cli/{index-m53v442a.js → index-hej0z0sm.js} +36 -36
- package/dist/cli/{index-r93ptj7j.js → index-hqmr21qx.js} +19 -1
- package/dist/cli/{index-18b9snn6.js → index-j1yd2gbz.js} +6 -6
- package/dist/cli/{index-kdyvk541.js → index-jgkva4r4.js} +2 -2
- package/dist/cli/{index-0dfhahxm.js → index-jj09bfnn.js} +2 -2
- package/dist/cli/{index-hhws1xkc.js → index-jn3m9s61.js} +1 -1
- package/dist/cli/{index-wr4m11x4.js → index-kj7h2yfv.js} +1 -1
- package/dist/cli/{index-6z404f7y.js → index-m6bsy0jb.js} +4 -4
- package/dist/cli/{index-90qbc4rp.js → index-mat5rawf.js} +11 -3
- package/dist/cli/{index-samx6zgc.js → index-n5jac8z9.js} +1 -1
- package/dist/cli/{index-r8g2meas.js → index-nr96hbpy.js} +5 -3
- package/dist/cli/{index-yeehyat1.js → index-ppb5krpy.js} +2 -2
- package/dist/cli/{index-jmn35na4.js → index-qz6ee73z.js} +3 -3
- package/dist/cli/{index-7gkdxs00.js → index-tr9jz898.js} +7 -7
- package/dist/cli/{index-yzwb6ja4.js → index-vqjkr1kd.js} +1 -1
- package/dist/cli/{index-p36b6t7w.js → index-vt9a5rbg.js} +16 -9
- package/dist/cli/{index-vwnd2szd.js → index-yk3es7m2.js} +22 -13
- package/dist/cli/{index-gwtb07gc.js → index-zpygn1tn.js} +3 -3
- package/dist/cli/{index-gwz9p53s.js → index-zz40vfbz.js} +2 -2
- package/dist/cli/index.js +37 -37
- package/dist/cli/{knowledge-escalator-ttp4x29h.js → knowledge-escalator-2zjpwg0q.js} +12 -12
- package/dist/cli/{knowledge-events-dx9mjgqb.js → knowledge-events-gp2ckzqm.js} +10 -10
- package/dist/cli/{knowledge-link-f7bhq7cx.js → knowledge-link-s77cyqxk.js} +4 -4
- package/dist/cli/{knowledge-store-6sq9rxma.js → knowledge-store-kd88k067.js} +5 -5
- package/dist/cli/{knowledge-validator-h49dkw2z.js → knowledge-validator-22t16mba.js} +7 -7
- package/dist/cli/{mcp-kd7w2572.js → mcp-1fjc89yp.js} +1 -1
- package/dist/cli/{pending-delegations-n4qyymj2.js → pending-delegations-k4hfqz12.js} +11 -11
- package/dist/cli/{pr-subscriptions-n8vkm5mv.js → pr-subscriptions-8g6w41vz.js} +11 -11
- package/dist/cli/{pr-workflow-gate-j67jhtzt.js → pr-workflow-gate-kb3e709n.js} +42 -36
- package/dist/cli/{runner-58k70bnr.js → runner-nzppg2ky.js} +5 -5
- package/dist/cli/{scan-cursor-sz8ncpw2.js → scan-cursor-erm49azh.js} +6 -6
- package/dist/cli/{schema-70c0yw8p.js → schema-kts10txe.js} +5 -1
- package/dist/cli/{scope-persistence-0dzyv0vt.js → scope-persistence-krnvsmsz.js} +14 -14
- package/dist/cli/{server-njmemwbm.js → server-9bqh036q.js} +36 -36
- package/dist/cli/{skill-generator-kf5yqmvk.js → skill-generator-7q75h2kr.js} +14 -14
- package/dist/cli/{snapshot-coordination-init-ezf5xqy2.js → snapshot-coordination-init-bw9mn21x.js} +36 -36
- package/dist/cli/{telemetry-zed80n86.js → telemetry-7bk8ps5p.js} +1 -1
- package/dist/cli/{workspace-snapshot-62be4368.js → workspace-snapshot-6aw002e8.js} +3 -3
- package/dist/cli/{worktree-collision-ownership-fe176vyv.js → worktree-collision-ownership-ajagwzh8.js} +12 -12
- package/dist/cli/{worktree-isolation-c0b1h3f1.js → worktree-isolation-rmqp04fx.js} +36 -36
- package/dist/commands/registry.d.ts +1 -1
- package/dist/config/index.d.ts +2 -2
- package/dist/config/schema.d.ts +22 -8
- package/dist/events/core-events.d.ts +2 -0
- package/dist/evidence/task-gate-requirements.d.ts +24 -0
- package/dist/gate-evidence.d.ts +12 -0
- package/dist/hooks/pr-workflow-gate.d.ts +28 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.js +501 -488
- package/dist/parallel/review-router.d.ts +8 -2
- package/dist/pr-review/completion.d.ts +2 -1
- package/dist/pr-review/finding-policy.d.ts +194 -0
- package/dist/pr-review/types.d.ts +8 -0
- package/dist/review/routing-enforcement.d.ts +163 -0
- package/dist/session/snapshot-writer.d.ts +2 -0
- package/dist/state.d.ts +28 -0
- package/dist/tools/complete-pr-workflow.d.ts +2 -1
- package/dist/tools/dispatch-lanes.d.ts +29 -0
- package/dist/tools/tool-metadata.d.ts +16 -16
- package/dist/tools/update-task-status.d.ts +0 -10
- package/dist/tools/write-pr-review-artifact.d.ts +7 -0
- package/dist/workflow/coder-settlement.d.ts +7 -0
- package/dist/workflow/recovery-invocation.d.ts +35 -0
- package/dist/workflow/stage-a-repair.d.ts +17 -0
- package/dist/workflow/task-recovery-status.d.ts +61 -0
- package/opencode-swarm.schema.json +11 -0
- package/package.json +2 -1
- package/dist/cli/curator-llm-factory-dza1qtwr.js +0 -72
- package/dist/cli/guardrail-explain-s29vngen.js +0 -73
|
@@ -35,7 +35,7 @@ export interface ToolMeta {
|
|
|
35
35
|
export declare const TOOL_METADATA: {
|
|
36
36
|
diff: {
|
|
37
37
|
description: string;
|
|
38
|
-
agents: ("
|
|
38
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic_oversight" | "critic_finding_validator" | "architect")[];
|
|
39
39
|
prWorkflow: {
|
|
40
40
|
modes: ("PR_REVIEW" | "PR_FEEDBACK")[];
|
|
41
41
|
capability: "observe";
|
|
@@ -51,7 +51,7 @@ export declare const TOOL_METADATA: {
|
|
|
51
51
|
};
|
|
52
52
|
syntax_check: {
|
|
53
53
|
description: string;
|
|
54
|
-
agents: ("
|
|
54
|
+
agents: ("test_engineer" | "coder" | "architect")[];
|
|
55
55
|
prWorkflow: {
|
|
56
56
|
modes: "PR_REVIEW"[];
|
|
57
57
|
capability: "validate";
|
|
@@ -67,7 +67,7 @@ export declare const TOOL_METADATA: {
|
|
|
67
67
|
};
|
|
68
68
|
imports: {
|
|
69
69
|
description: string;
|
|
70
|
-
agents: ("
|
|
70
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic" | "critic_finding_validator" | "architect" | "sme" | "researcher" | "docs" | "docs_design" | "critic_sounding_board" | "critic_drift_verifier" | "critic_hallucination_verifier")[];
|
|
71
71
|
prWorkflow: {
|
|
72
72
|
modes: ("PR_REVIEW" | "PR_FEEDBACK")[];
|
|
73
73
|
capability: "observe";
|
|
@@ -75,7 +75,7 @@ export declare const TOOL_METADATA: {
|
|
|
75
75
|
};
|
|
76
76
|
lint: {
|
|
77
77
|
description: string;
|
|
78
|
-
agents: ("
|
|
78
|
+
agents: ("reviewer" | "coder" | "critic_finding_validator" | "architect")[];
|
|
79
79
|
prWorkflow: {
|
|
80
80
|
modes: "PR_REVIEW"[];
|
|
81
81
|
capability: "validate";
|
|
@@ -99,7 +99,7 @@ export declare const TOOL_METADATA: {
|
|
|
99
99
|
};
|
|
100
100
|
build_check: {
|
|
101
101
|
description: string;
|
|
102
|
-
agents: ("
|
|
102
|
+
agents: ("test_engineer" | "coder" | "architect")[];
|
|
103
103
|
};
|
|
104
104
|
pre_check_batch: {
|
|
105
105
|
description: string;
|
|
@@ -115,7 +115,7 @@ export declare const TOOL_METADATA: {
|
|
|
115
115
|
};
|
|
116
116
|
symbols: {
|
|
117
117
|
description: string;
|
|
118
|
-
agents: ("
|
|
118
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic" | "critic_finding_validator" | "architect" | "sme" | "researcher" | "docs" | "docs_design" | "designer" | "critic_sounding_board" | "critic_drift_verifier" | "critic_hallucination_verifier" | "spec_writer")[];
|
|
119
119
|
};
|
|
120
120
|
complexity_hotspots: {
|
|
121
121
|
description: string;
|
|
@@ -299,7 +299,7 @@ export declare const TOOL_METADATA: {
|
|
|
299
299
|
};
|
|
300
300
|
retrieve_summary: {
|
|
301
301
|
description: string;
|
|
302
|
-
agents: ("
|
|
302
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic" | "critic_finding_validator" | "architect" | "sme" | "docs" | "docs_design" | "designer" | "critic_sounding_board" | "critic_drift_verifier" | "critic_hallucination_verifier" | "critic_architecture_supervisor" | "spec_writer")[];
|
|
303
303
|
prWorkflow: {
|
|
304
304
|
modes: ("PR_REVIEW" | "PR_FEEDBACK")[];
|
|
305
305
|
capability: "observe";
|
|
@@ -315,7 +315,7 @@ export declare const TOOL_METADATA: {
|
|
|
315
315
|
};
|
|
316
316
|
extract_code_blocks: {
|
|
317
317
|
description: string;
|
|
318
|
-
agents: ("
|
|
318
|
+
agents: ("test_engineer" | "coder" | "docs" | "docs_design" | "designer" | "spec_writer")[];
|
|
319
319
|
};
|
|
320
320
|
phase_complete: {
|
|
321
321
|
description: string;
|
|
@@ -395,7 +395,7 @@ export declare const TOOL_METADATA: {
|
|
|
395
395
|
};
|
|
396
396
|
knowledge_recall: {
|
|
397
397
|
description: string;
|
|
398
|
-
agents: ("
|
|
398
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic" | "critic_oversight" | "critic_finding_validator" | "explorer" | "architect" | "sme" | "docs" | "docs_design" | "designer" | "critic_sounding_board" | "critic_drift_verifier" | "critic_hallucination_verifier" | "critic_architecture_supervisor" | "curator_init" | "curator_phase" | "skill_improver" | "spec_writer")[];
|
|
399
399
|
};
|
|
400
400
|
knowledge_remove: {
|
|
401
401
|
description: string;
|
|
@@ -411,11 +411,11 @@ export declare const TOOL_METADATA: {
|
|
|
411
411
|
};
|
|
412
412
|
search: {
|
|
413
413
|
description: string;
|
|
414
|
-
agents: ("
|
|
414
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic_oversight" | "critic_finding_validator" | "explorer" | "architect" | "sme" | "researcher" | "docs" | "docs_design" | "designer" | "critic_hallucination_verifier" | "skill_improver" | "spec_writer")[];
|
|
415
415
|
};
|
|
416
416
|
ast_grep: {
|
|
417
417
|
description: string;
|
|
418
|
-
agents: ("
|
|
418
|
+
agents: ("test_engineer" | "coder" | "explorer" | "architect" | "sme" | "researcher" | "docs" | "docs_design" | "critic_hallucination_verifier" | "spec_writer")[];
|
|
419
419
|
};
|
|
420
420
|
actionlint_scan: {
|
|
421
421
|
description: string;
|
|
@@ -467,7 +467,7 @@ export declare const TOOL_METADATA: {
|
|
|
467
467
|
};
|
|
468
468
|
repo_map: {
|
|
469
469
|
description: string;
|
|
470
|
-
agents: ("
|
|
470
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic" | "critic_oversight" | "critic_finding_validator" | "explorer" | "architect" | "critic_sounding_board" | "critic_drift_verifier" | "critic_hallucination_verifier" | "critic_architecture_supervisor")[];
|
|
471
471
|
prWorkflow: {
|
|
472
472
|
modes: ("PR_REVIEW" | "PR_FEEDBACK")[];
|
|
473
473
|
capability: "observe";
|
|
@@ -535,7 +535,7 @@ export declare const TOOL_METADATA: {
|
|
|
535
535
|
};
|
|
536
536
|
knowledge_receipt: {
|
|
537
537
|
description: string;
|
|
538
|
-
agents: ("
|
|
538
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic" | "critic_finding_validator" | "architect" | "sme" | "docs" | "docs_design" | "designer" | "critic_sounding_board" | "critic_drift_verifier" | "critic_hallucination_verifier" | "critic_architecture_supervisor" | "curator_init" | "curator_phase" | "skill_improver" | "spec_writer")[];
|
|
539
539
|
};
|
|
540
540
|
knowledge_archive: {
|
|
541
541
|
description: string;
|
|
@@ -555,7 +555,7 @@ export declare const TOOL_METADATA: {
|
|
|
555
555
|
};
|
|
556
556
|
swarm_command: {
|
|
557
557
|
description: string;
|
|
558
|
-
agents: ("
|
|
558
|
+
agents: ("reviewer" | "test_engineer" | "coder" | "critic" | "critic_finding_validator" | "explorer" | "architect" | "sme" | "researcher" | "docs" | "docs_design" | "designer")[];
|
|
559
559
|
};
|
|
560
560
|
dispatch_lanes: {
|
|
561
561
|
description: string;
|
|
@@ -571,7 +571,7 @@ export declare const TOOL_METADATA: {
|
|
|
571
571
|
};
|
|
572
572
|
summarize_work: {
|
|
573
573
|
description: string;
|
|
574
|
-
agents: ("
|
|
574
|
+
agents: ("test_engineer" | "coder" | "explorer" | "architect" | "sme" | "researcher" | "docs" | "docs_design" | "designer")[];
|
|
575
575
|
};
|
|
576
576
|
write_architecture_supervisor_evidence: {
|
|
577
577
|
description: string;
|
|
@@ -607,7 +607,7 @@ export declare const TOOL_METADATA: {
|
|
|
607
607
|
};
|
|
608
608
|
swarm_apply_patch: {
|
|
609
609
|
description: string;
|
|
610
|
-
agents: ("
|
|
610
|
+
agents: ("test_engineer" | "coder")[];
|
|
611
611
|
};
|
|
612
612
|
external_skill_discover: {
|
|
613
613
|
description: string;
|
|
@@ -84,16 +84,6 @@ export interface ReviewerGateResult {
|
|
|
84
84
|
nextAction?: string;
|
|
85
85
|
}
|
|
86
86
|
declare function hasPassedDurableGateEvidence(workingDirectory: string, taskId: string): boolean;
|
|
87
|
-
/**
|
|
88
|
-
* Check if a task has passed required QA gates using the state machine.
|
|
89
|
-
* Requires the task to be in 'tests_run' or 'complete' state, which means
|
|
90
|
-
* both reviewer delegation and test_engineer runs have been recorded.
|
|
91
|
-
* @param taskId - The task ID to check gate state for
|
|
92
|
-
* @param workingDirectory - Optional working directory for plan.json fallback
|
|
93
|
-
* @param stageBParallelEnabled - When true, also accept both-markers-present as passing (PR 2 barrier)
|
|
94
|
-
* @param sessionID - Optional session ID to scope Lean Turbo bypass to the current tool-execution context
|
|
95
|
-
* @returns ReviewerGateResult indicating whether the gate is blocked
|
|
96
|
-
*/
|
|
97
87
|
export declare function checkReviewerGate(taskId: string, workingDirectory?: string, stageBParallelEnabled?: boolean, sessionID?: string, fallbackDir?: string): ReviewerGateResult;
|
|
98
88
|
/**
|
|
99
89
|
* Wrapper around checkReviewerGate that appends a diff-scope advisory warning.
|
|
@@ -2,6 +2,7 @@ import { z } from 'zod';
|
|
|
2
2
|
import type { FindingsSeverity } from '../background/candidate-contract.js';
|
|
3
3
|
import { PrReviewFindingSchema } from '../background/pr-review-contract.js';
|
|
4
4
|
import { assertPrReviewArtifactBoundary } from '../hooks/pr-workflow-gate.js';
|
|
5
|
+
import { type CriticSettlementRecord } from '../pr-review/finding-policy.js';
|
|
5
6
|
import { createSwarmTool } from './create-tool.js';
|
|
6
7
|
/**
|
|
7
8
|
* READ shape. Deliberately tolerant of a missing `severity`: `readFindings`
|
|
@@ -22,9 +23,15 @@ export declare const _internals: {
|
|
|
22
23
|
atomicWrite: typeof atomicWrite;
|
|
23
24
|
atomicCreate: typeof atomicCreate;
|
|
24
25
|
assertBoundary: typeof assertPrReviewArtifactBoundary;
|
|
26
|
+
assertCriticSettlements: typeof assertCriticSettlements;
|
|
25
27
|
/** Exposed so the #2383 read/migration boundary is testable directly. */
|
|
26
28
|
readFindings: typeof readFindings;
|
|
27
29
|
};
|
|
30
|
+
type FindingsRecord = z.infer<typeof PrReviewFindingSchema>;
|
|
31
|
+
declare function assertCriticSettlements(records: readonly FindingsRecord[], existing: readonly PersistedFinding[], authoritativeCriticVerdicts: ReadonlyMap<string, {
|
|
32
|
+
status: string;
|
|
33
|
+
severity: string;
|
|
34
|
+
}>): CriticSettlementRecord[];
|
|
28
35
|
export declare function executeWritePrReviewArtifact(args: unknown, directory: string, context?: {
|
|
29
36
|
sessionID?: string;
|
|
30
37
|
}): Promise<string>;
|
|
@@ -114,6 +114,13 @@ export interface CoderSettlementWalState {
|
|
|
114
114
|
ownedInProcess: boolean;
|
|
115
115
|
/** A different, still-alive host process owns the dispatch. Never force-releasable from here. */
|
|
116
116
|
ownedByLiveForeignPid: boolean;
|
|
117
|
+
/**
|
|
118
|
+
* Generation fence the dispatch declared on its WAL (issue #2665): the
|
|
119
|
+
* workflow generation the owning transition expected to CAS against.
|
|
120
|
+
* Retained through recovery status so a stale-generation receipt is
|
|
121
|
+
* visible without re-reading the WAL bytes.
|
|
122
|
+
*/
|
|
123
|
+
expectedGeneration?: number;
|
|
117
124
|
}
|
|
118
125
|
/**
|
|
119
126
|
* Bounded inventory of durable coder-settlement WALs for diagnostics and
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Static recovery-invocation guidance (issue #2665).
|
|
3
|
+
*
|
|
4
|
+
* One shell-correct form per supported shell for the recovery entry points,
|
|
5
|
+
* plus the category glossary and the deterministic-repair boundary text the
|
|
6
|
+
* operator runbook publishes. Everything here is a module constant: this
|
|
7
|
+
* module MUST NOT read environment variables or the host platform, or any
|
|
8
|
+
* environment signal to choose an invocation string — the contract is
|
|
9
|
+
* documented per shell, never sniffed (issue #2665 AC3: "without introducing
|
|
10
|
+
* a new heuristic path detector"; the anti-detection source scan lives in
|
|
11
|
+
* tests/unit/workflow/task-recovery-status.test.ts).
|
|
12
|
+
*/
|
|
13
|
+
/** The compact operator runbook that carries the full guidance. */
|
|
14
|
+
export declare const RECOVERY_RUNBOOK_DOC_PATH = "docs/troubleshooting/recovery-runbook.md";
|
|
15
|
+
export interface RecoveryInvocationForm {
|
|
16
|
+
/** Shell or entry surface the form is correct for. */
|
|
17
|
+
surface: 'host' | 'powershell' | 'git-bash' | 'cli';
|
|
18
|
+
/** Shell-correct invocation string (placeholders in angle brackets). */
|
|
19
|
+
invocation: string;
|
|
20
|
+
/** One-line explanation, including the known friction where relevant. */
|
|
21
|
+
note: string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Shell-correct invocations for `/swarm recover <task_id>`.
|
|
25
|
+
*
|
|
26
|
+
* The Git Bash form doubles the leading slash of the `/swarm ...` message
|
|
27
|
+
* argument: MSYS path conversion rewrites a single leading-slash argument to
|
|
28
|
+
* a path under the Git install root (`C:/Program Files/Git/swarm ...`) before
|
|
29
|
+
* the host ever sees it. Setting `MSYS_NO_PATHCONV=1` for the whole
|
|
30
|
+
* invocation is NOT shell-correct because `--dir /c/...` arguments then stop
|
|
31
|
+
* converting too.
|
|
32
|
+
*/
|
|
33
|
+
export declare const RECOVERY_INVOCATIONS: readonly RecoveryInvocationForm[];
|
|
34
|
+
/** One-line per-shell quick forms for operator-facing output surfaces. */
|
|
35
|
+
export declare function renderRecoveryInvocationQuickForms(docPath?: string): string;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type TaskRecoveryStatus } from './task-recovery-status.js';
|
|
1
2
|
export type StageARepairOutcome = {
|
|
2
3
|
taskId: string;
|
|
3
4
|
outcome: 'repaired';
|
|
@@ -26,6 +27,22 @@ export type PreCheckGreennessResult = {
|
|
|
26
27
|
green: false;
|
|
27
28
|
reason: 'no_pre_check_bundles' | 'pre_check_failed_or_stale';
|
|
28
29
|
};
|
|
30
|
+
export interface StageAScanResult {
|
|
31
|
+
/** One entry per enumerated task, classified in the shared #2665 vocabulary. */
|
|
32
|
+
results: TaskRecoveryStatus[];
|
|
33
|
+
truncated: boolean;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Read-only wedge scan (issue #2665): classifies every enumerated task via
|
|
37
|
+
* the shared recovery vocabulary WITHOUT emitting transitions, writing
|
|
38
|
+
* evidence, or appending events. Tasks whose evidence cannot be read are
|
|
39
|
+
* skipped (their failure surfaces through the repair path's per-task error
|
|
40
|
+
* outcomes and the diagnose evidence checks). `repairAllowed` is true only
|
|
41
|
+
* for the `live_wedge` category with green post-settlement pre-check proof.
|
|
42
|
+
*/
|
|
43
|
+
export declare function scanWedgedStageA(directory: string, options?: {
|
|
44
|
+
taskIds?: string[];
|
|
45
|
+
}): Promise<StageAScanResult>;
|
|
29
46
|
/**
|
|
30
47
|
* Repair path for tasks already wedged at `coder_delegated`
|
|
31
48
|
* (TASK_WORKFLOW_STAGE_A_REQUIRED post-reset wedge). For each flat task
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Task recovery status classification (issue #2665).
|
|
3
|
+
*
|
|
4
|
+
* Pure classification over facts the durable receipts already carry: the
|
|
5
|
+
* coder-settlement WAL inventory (`CoderSettlementWalState`), the per-task
|
|
6
|
+
* evidence workflow snapshot, and (for the wedge class) the Stage A scan.
|
|
7
|
+
* This module never reads the filesystem, never writes state, and never
|
|
8
|
+
* repairs anything — it is the "task/generation-specific missing explanation"
|
|
9
|
+
* that connects status and repair to the same transition receipts
|
|
10
|
+
* (`transitionId` + `generation`), per the issue's scope quote: add the
|
|
11
|
+
* explanation, not another recovery engine.
|
|
12
|
+
*/
|
|
13
|
+
import type { TaskEvidence, TaskWorkflowSnapshot } from '../gate-evidence.js';
|
|
14
|
+
import type { CoderSettlementWalState } from './coder-settlement.js';
|
|
15
|
+
export type TaskRecoveryCategory = 'healthy' | 'missing' | 'stale' | 'ambiguous' | 'corrupt' | 'live_wedge';
|
|
16
|
+
export interface TaskRecoveryStatus {
|
|
17
|
+
taskId: string;
|
|
18
|
+
category: TaskRecoveryCategory;
|
|
19
|
+
/** Workflow generation from the durable evidence snapshot, when one exists. */
|
|
20
|
+
generation?: number;
|
|
21
|
+
/** Owning transition id from the settlement WAL / evidence chain tip. */
|
|
22
|
+
transitionId?: string;
|
|
23
|
+
/** Deterministic repair allowed without an operator assertion? */
|
|
24
|
+
repairAllowed: boolean;
|
|
25
|
+
/** An external (process/provider) effect may still be in flight or unresolved. */
|
|
26
|
+
uncertainExternalEffect: boolean;
|
|
27
|
+
explanation: string;
|
|
28
|
+
/** Host-command-path form; per-shell forms live in recovery-invocation.ts. */
|
|
29
|
+
suggestedNextCommand: string;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Classify one settlement-WAL entry against the task's workflow snapshot.
|
|
33
|
+
*
|
|
34
|
+
* Category mapping (issue #2665 AC1 vocabulary):
|
|
35
|
+
* - `unreadable` → corrupt (facts corrupt; recovery refuses, never rewrites)
|
|
36
|
+
* - owned in this process / by a live foreign pid → ambiguous (external
|
|
37
|
+
* effect stays uncertain; never force a foreign owner)
|
|
38
|
+
* - `DISPATCHED`/`PREPARED` with a dead owner → stale (deterministic repair)
|
|
39
|
+
* - terminal → healthy
|
|
40
|
+
*
|
|
41
|
+
* When the WAL records an `expectedGeneration` that disagrees with the
|
|
42
|
+
* workflow snapshot's generation, the stale explanation names the generation
|
|
43
|
+
* conflict explicitly — the settle path's CAS already refuses stale and
|
|
44
|
+
* foreign receipts; this makes that refusal visible in status.
|
|
45
|
+
*/
|
|
46
|
+
export declare function classifySettlementWalState(entry: CoderSettlementWalState, workflow: TaskWorkflowSnapshot | null): TaskRecoveryStatus;
|
|
47
|
+
/**
|
|
48
|
+
* Classify a task's evidence-workflow state for recovery purposes. The
|
|
49
|
+
* `live_wedge` class is the "live-shaped task wedge" of issue #2665 AC2:
|
|
50
|
+
* the workflow sits at `coder_delegated` with no pre_check gate proof —
|
|
51
|
+
* deterministically repairable by the Stage A repair (which never re-runs
|
|
52
|
+
* the coder and never edits evidence speculatively) when green
|
|
53
|
+
* post-settlement pre-check proof exists.
|
|
54
|
+
*/
|
|
55
|
+
export declare function classifyEvidenceRecoveryTask(taskId: string, evidence: TaskEvidence | null, greenPreCheck: boolean | null): TaskRecoveryStatus;
|
|
56
|
+
/**
|
|
57
|
+
* One diagnose-detail line per non-healthy task. Healthy tasks are rendered
|
|
58
|
+
* by their COUNT only (never a per-task line) so no category token can
|
|
59
|
+
* attach to a healthy task id (plan-critic B1).
|
|
60
|
+
*/
|
|
61
|
+
export declare function renderTaskRecoveryLine(status: TaskRecoveryStatus): string;
|
|
@@ -351,6 +351,17 @@
|
|
|
351
351
|
},
|
|
352
352
|
"additionalProperties": false
|
|
353
353
|
},
|
|
354
|
+
"review_routing": {
|
|
355
|
+
"description": "Semantic review routing receipt enforcement for Stage B (default on; set enforce_receipts=false only as a one-release rollback).",
|
|
356
|
+
"type": "object",
|
|
357
|
+
"properties": {
|
|
358
|
+
"enforce_receipts": {
|
|
359
|
+
"default": true,
|
|
360
|
+
"type": "boolean"
|
|
361
|
+
}
|
|
362
|
+
},
|
|
363
|
+
"additionalProperties": false
|
|
364
|
+
},
|
|
354
365
|
"lane_liveness_watchdog": {
|
|
355
366
|
"description": "Lane liveness watchdog: execution deadline and stall escalation for PR workflow lanes.",
|
|
356
367
|
"type": "object",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "opencode-swarm",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.175.0",
|
|
4
4
|
"description": "Architect-centric agentic swarm plugin for OpenCode - hub-and-spoke orchestration with SME consultation, code generation, and QA review",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -111,6 +111,7 @@
|
|
|
111
111
|
"package:smoke": "node scripts/package-smoke.mjs",
|
|
112
112
|
"prepare": "bun run build",
|
|
113
113
|
"repro:704": "node scripts/repro-704.mjs",
|
|
114
|
+
"repro:2669": "node scripts/repro-2669.mjs",
|
|
114
115
|
"repro:1144": "bun scripts/repro-1144.mjs",
|
|
115
116
|
"repro:1873": "bun build scripts/repro-1873-entry.ts --outdir dist-build-test/repro-1873 --target node --format esm && node scripts/repro-1873.mjs",
|
|
116
117
|
"repro:2487": "bun build scripts/repro-2487-parity-entry.ts --outdir dist-build-test/repro-2487 --target node --format esm && node scripts/repro-2487-parity.mjs",
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import {
|
|
3
|
-
createCuratorLLMDelegate
|
|
4
|
-
} from "./index-wf3s2t1t.js";
|
|
5
|
-
import"./index-hnvmj9wx.js";
|
|
6
|
-
import"./index-hhws1xkc.js";
|
|
7
|
-
import"./index-62pcs7jg.js";
|
|
8
|
-
import"./index-wr4m11x4.js";
|
|
9
|
-
import"./index-r93ptj7j.js";
|
|
10
|
-
import"./index-mjqjbq94.js";
|
|
11
|
-
import"./index-z35ynvj4.js";
|
|
12
|
-
import"./index-txdagbh7.js";
|
|
13
|
-
import"./index-z2deqhpp.js";
|
|
14
|
-
import"./index-fpbcxykc.js";
|
|
15
|
-
import"./index-6z404f7y.js";
|
|
16
|
-
import"./index-psb9rxt8.js";
|
|
17
|
-
import"./index-1xfxzjq9.js";
|
|
18
|
-
import"./index-fyfbpz4f.js";
|
|
19
|
-
import"./index-7gkdxs00.js";
|
|
20
|
-
import"./index-0hgmsyfp.js";
|
|
21
|
-
import"./index-zsrtt42s.js";
|
|
22
|
-
import"./index-p36b6t7w.js";
|
|
23
|
-
import"./index-ndvgkxpf.js";
|
|
24
|
-
import"./index-0dfhahxm.js";
|
|
25
|
-
import"./index-pt7h91zc.js";
|
|
26
|
-
import"./index-q7sjgr1y.js";
|
|
27
|
-
import"./index-pjw95rxm.js";
|
|
28
|
-
import"./index-gwtb07gc.js";
|
|
29
|
-
import"./index-vwnd2szd.js";
|
|
30
|
-
import"./index-pynk60z5.js";
|
|
31
|
-
import"./index-evf5r7bk.js";
|
|
32
|
-
import"./index-2s7dvzff.js";
|
|
33
|
-
import"./index-cm0339fe.js";
|
|
34
|
-
import"./index-m51cmzxt.js";
|
|
35
|
-
import"./index-rtry5xyf.js";
|
|
36
|
-
import"./index-gwz9p53s.js";
|
|
37
|
-
import"./index-frcemc0b.js";
|
|
38
|
-
import"./index-wrt875kh.js";
|
|
39
|
-
import"./index-dx9pz5n6.js";
|
|
40
|
-
import"./index-18b9snn6.js";
|
|
41
|
-
import"./index-mt8pbzda.js";
|
|
42
|
-
import"./index-za1kvsa0.js";
|
|
43
|
-
import"./index-fnx0jzf7.js";
|
|
44
|
-
import"./index-dktpzjy9.js";
|
|
45
|
-
import"./index-rdm3px0g.js";
|
|
46
|
-
import"./index-ry16d01s.js";
|
|
47
|
-
import"./index-43dmpa9w.js";
|
|
48
|
-
import"./index-j0vvq8se.js";
|
|
49
|
-
import"./index-vzm6zre7.js";
|
|
50
|
-
import"./index-ae75rja9.js";
|
|
51
|
-
import"./index-yzwb6ja4.js";
|
|
52
|
-
import"./index-kdyvk541.js";
|
|
53
|
-
import"./index-7g4c7s5r.js";
|
|
54
|
-
import"./index-jmn35na4.js";
|
|
55
|
-
import"./index-bsnpv4xd.js";
|
|
56
|
-
import"./index-1xnse449.js";
|
|
57
|
-
import"./index-c1ggtmpm.js";
|
|
58
|
-
import"./index-53c0ajk4.js";
|
|
59
|
-
import"./index-0mhftbpp.js";
|
|
60
|
-
import"./index-a1w58b47.js";
|
|
61
|
-
import"./index-90qbc4rp.js";
|
|
62
|
-
import"./index-5frh43fj.js";
|
|
63
|
-
import"./index-bk5tah7q.js";
|
|
64
|
-
import"./index-gknz3bv1.js";
|
|
65
|
-
import"./index-zpsr8rpc.js";
|
|
66
|
-
import"./index-76qm2c2y.js";
|
|
67
|
-
import"./index-yzjaj53h.js";
|
|
68
|
-
import"./index-zgwm4ryv.js";
|
|
69
|
-
import"./index-a76rekgs.js";
|
|
70
|
-
export {
|
|
71
|
-
createCuratorLLMDelegate
|
|
72
|
-
};
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import {
|
|
3
|
-
handleGuardrailExplain
|
|
4
|
-
} from "./index-yeehyat1.js";
|
|
5
|
-
import"./index-wf3s2t1t.js";
|
|
6
|
-
import"./index-hnvmj9wx.js";
|
|
7
|
-
import"./index-hhws1xkc.js";
|
|
8
|
-
import"./index-62pcs7jg.js";
|
|
9
|
-
import"./index-wr4m11x4.js";
|
|
10
|
-
import"./index-r93ptj7j.js";
|
|
11
|
-
import"./index-mjqjbq94.js";
|
|
12
|
-
import"./index-z35ynvj4.js";
|
|
13
|
-
import"./index-txdagbh7.js";
|
|
14
|
-
import"./index-z2deqhpp.js";
|
|
15
|
-
import"./index-fpbcxykc.js";
|
|
16
|
-
import"./index-6z404f7y.js";
|
|
17
|
-
import"./index-psb9rxt8.js";
|
|
18
|
-
import"./index-1xfxzjq9.js";
|
|
19
|
-
import"./index-fyfbpz4f.js";
|
|
20
|
-
import"./index-7gkdxs00.js";
|
|
21
|
-
import"./index-0hgmsyfp.js";
|
|
22
|
-
import"./index-zsrtt42s.js";
|
|
23
|
-
import"./index-p36b6t7w.js";
|
|
24
|
-
import"./index-ndvgkxpf.js";
|
|
25
|
-
import"./index-0dfhahxm.js";
|
|
26
|
-
import"./index-pt7h91zc.js";
|
|
27
|
-
import"./index-q7sjgr1y.js";
|
|
28
|
-
import"./index-pjw95rxm.js";
|
|
29
|
-
import"./index-gwtb07gc.js";
|
|
30
|
-
import"./index-vwnd2szd.js";
|
|
31
|
-
import"./index-pynk60z5.js";
|
|
32
|
-
import"./index-evf5r7bk.js";
|
|
33
|
-
import"./index-2s7dvzff.js";
|
|
34
|
-
import"./index-cm0339fe.js";
|
|
35
|
-
import"./index-m51cmzxt.js";
|
|
36
|
-
import"./index-rtry5xyf.js";
|
|
37
|
-
import"./index-gwz9p53s.js";
|
|
38
|
-
import"./index-frcemc0b.js";
|
|
39
|
-
import"./index-wrt875kh.js";
|
|
40
|
-
import"./index-dx9pz5n6.js";
|
|
41
|
-
import"./index-18b9snn6.js";
|
|
42
|
-
import"./index-mt8pbzda.js";
|
|
43
|
-
import"./index-za1kvsa0.js";
|
|
44
|
-
import"./index-fnx0jzf7.js";
|
|
45
|
-
import"./index-dktpzjy9.js";
|
|
46
|
-
import"./index-rdm3px0g.js";
|
|
47
|
-
import"./index-ry16d01s.js";
|
|
48
|
-
import"./index-43dmpa9w.js";
|
|
49
|
-
import"./index-j0vvq8se.js";
|
|
50
|
-
import"./index-vzm6zre7.js";
|
|
51
|
-
import"./index-ae75rja9.js";
|
|
52
|
-
import"./index-yzwb6ja4.js";
|
|
53
|
-
import"./index-kdyvk541.js";
|
|
54
|
-
import"./index-7g4c7s5r.js";
|
|
55
|
-
import"./index-jmn35na4.js";
|
|
56
|
-
import"./index-bsnpv4xd.js";
|
|
57
|
-
import"./index-1xnse449.js";
|
|
58
|
-
import"./index-c1ggtmpm.js";
|
|
59
|
-
import"./index-53c0ajk4.js";
|
|
60
|
-
import"./index-0mhftbpp.js";
|
|
61
|
-
import"./index-a1w58b47.js";
|
|
62
|
-
import"./index-90qbc4rp.js";
|
|
63
|
-
import"./index-5frh43fj.js";
|
|
64
|
-
import"./index-bk5tah7q.js";
|
|
65
|
-
import"./index-gknz3bv1.js";
|
|
66
|
-
import"./index-zpsr8rpc.js";
|
|
67
|
-
import"./index-76qm2c2y.js";
|
|
68
|
-
import"./index-yzjaj53h.js";
|
|
69
|
-
import"./index-zgwm4ryv.js";
|
|
70
|
-
import"./index-a76rekgs.js";
|
|
71
|
-
export {
|
|
72
|
-
handleGuardrailExplain
|
|
73
|
-
};
|