opencode-swarm 7.125.2 → 7.125.4
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/cli/{config-doctor-8df6hk58.js → config-doctor-rm1m07gz.js} +2 -2
- package/dist/cli/{core-d38hc85b.js → core-v1kp7anb.js} +2 -2
- package/dist/cli/{curation-policy-7pvghg6f.js → curation-policy-7pgdjt5w.js} +2 -2
- package/dist/cli/{curator-drift-h9a2sjvf.js → curator-drift-24bdacdc.js} +2 -2
- package/dist/cli/{curator-llm-factory-bntt6v8j.js → curator-llm-factory-0hncnz9t.js} +16 -16
- package/dist/cli/{curator-dw2zb74h.js → curator-n6whbm4r.js} +16 -16
- package/dist/cli/{evidence-summary-service-v4h2w487.js → evidence-summary-service-thx1c3me.js} +3 -3
- package/dist/cli/{guardrail-explain-vmr4db9n.js → guardrail-explain-8gknrsbb.js} +17 -17
- package/dist/cli/{guardrail-log-8prd6cnc.js → guardrail-log-6a2zxvtx.js} +3 -3
- package/dist/cli/{hive-promoter-xymt9vf2.js → hive-promoter-mpjq0fw9.js} +16 -16
- package/dist/cli/{index-ptmhxsaf.js → index-01n43w2p.js} +4 -4
- package/dist/cli/{index-qcrah1jk.js → index-414r47r7.js} +3 -3
- package/dist/cli/{index-pgya7cnn.js → index-45mvd5q7.js} +4 -4
- package/dist/cli/index-4rhhvd1a.js +62 -0
- package/dist/cli/{index-1s7jzcsy.js → index-4ycq2mrp.js} +1 -1
- package/dist/cli/{index-8ed9rz7y.js → index-7xg876np.js} +64 -49
- package/dist/cli/{index-39p1yyag.js → index-8tjbq2ej.js} +1 -1
- package/dist/cli/{index-s9mj4rb9.js → index-9ss2m4rs.js} +1 -1
- package/dist/cli/{index-j8ptbcxz.js → index-ambnwnmt.js} +15 -6
- package/dist/cli/{index-zbsxek49.js → index-emzes7sj.js} +3 -3
- package/dist/cli/{index-tdpct4cz.js → index-fm4zfxnr.js} +1 -1
- package/dist/cli/{index-v2rdhwx8.js → index-g4ef4v3m.js} +1 -1
- package/dist/cli/{index-yrk6hfp1.js → index-hr2kzcem.js} +18 -18
- package/dist/cli/{index-em4h33my.js → index-jkwyjr8x.js} +2 -2
- package/dist/cli/{index-fs02c7tz.js → index-kk1scggc.js} +1 -1
- package/dist/cli/{index-92xyawa7.js → index-pk099nqv.js} +87 -6
- package/dist/cli/{index-7ne6q2a0.js → index-rp5msv7n.js} +1 -1
- package/dist/cli/{index-7mtvvt8p.js → index-sa3dgpmc.js} +2 -2
- package/dist/cli/{index-v3f7jvm8.js → index-vdfewvn5.js} +5 -5
- package/dist/cli/{index-sxdh19nk.js → index-xezv6tdw.js} +1 -1
- package/dist/cli/index.js +16 -16
- package/dist/cli/{knowledge-escalator-47hfstmk.js → knowledge-escalator-gr8qd7kz.js} +3 -3
- package/dist/cli/{knowledge-events-j5dpp72w.js → knowledge-events-q83g3f8z.js} +1 -1
- package/dist/cli/{knowledge-store-58gt7m85.js → knowledge-store-qq3w5yt8.js} +1 -1
- package/dist/cli/{knowledge-validator-jjxw5mwc.js → knowledge-validator-7jhq8yam.js} +4 -4
- package/dist/cli/{scan-cursor-h8we8dfv.js → scan-cursor-fa5sy36q.js} +2 -2
- package/dist/cli/{schema-xpqbhcyp.js → schema-bw68my66.js} +3 -1
- package/dist/cli/{skill-generator-k8d0vff0.js → skill-generator-ffc1agyw.js} +6 -6
- package/dist/config/loader.d.ts +14 -0
- package/dist/config/schema.d.ts +6 -0
- package/dist/hooks/delegation-gate.d.ts +35 -0
- package/dist/hooks/shell-write-detect.d.ts +1 -1
- package/dist/index.js +34 -28
- package/dist/services/config-doctor.d.ts +14 -2
- package/dist/services/warning-buffer.d.ts +24 -5
- package/dist/session/snapshot-writer.d.ts +9 -0
- package/dist/state.d.ts +15 -0
- package/dist/turbo/lean/reviewer.d.ts +2 -1
- package/dist/turbo/lean/runner.d.ts +2 -1
- package/dist/utils/model-dispatch-fallback.d.ts +71 -0
- package/dist/utils/provider-error-classification.d.ts +52 -0
- package/package.json +1 -1
- package/dist/cli/index-gacm5s2n.js +0 -34
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
readDoctorArtifact,
|
|
5
5
|
removeStraySwarmDir,
|
|
6
6
|
runConfigDoctor
|
|
7
|
-
} from "./index-
|
|
7
|
+
} from "./index-pk099nqv.js";
|
|
8
8
|
import {
|
|
9
9
|
EvaluationTaskV1Schema,
|
|
10
10
|
GateAuditManifestV1Schema,
|
|
@@ -61,7 +61,7 @@ import {
|
|
|
61
61
|
saveTaskSetSnapshot,
|
|
62
62
|
transientBackoff,
|
|
63
63
|
validateProjectRoot
|
|
64
|
-
} from "./index-
|
|
64
|
+
} from "./index-kk1scggc.js";
|
|
65
65
|
import {
|
|
66
66
|
withTimeout
|
|
67
67
|
} from "./index-4905hd2m.js";
|
|
@@ -94,15 +94,15 @@ import {
|
|
|
94
94
|
retireSkill,
|
|
95
95
|
selectCandidateEntries,
|
|
96
96
|
syncBundledProjectSkillsIfMissingAsync
|
|
97
|
-
} from "./index-
|
|
97
|
+
} from "./index-01n43w2p.js";
|
|
98
98
|
import {
|
|
99
99
|
readRecentEscalations
|
|
100
|
-
} from "./index-
|
|
100
|
+
} from "./index-vdfewvn5.js";
|
|
101
101
|
import {
|
|
102
102
|
alreadyCuratedThisGeneration,
|
|
103
103
|
claimNextScanBatch,
|
|
104
104
|
resolveCohortId
|
|
105
|
-
} from "./index-
|
|
105
|
+
} from "./index-8tjbq2ej.js";
|
|
106
106
|
import {
|
|
107
107
|
CURATOR_INIT_PROMPT,
|
|
108
108
|
CURATOR_PHASE_PROMPT,
|
|
@@ -119,7 +119,7 @@ import {
|
|
|
119
119
|
resolveSpeckitProjection,
|
|
120
120
|
validateSpeckit,
|
|
121
121
|
writeProjectedSpecSync
|
|
122
|
-
} from "./index-
|
|
122
|
+
} from "./index-9ss2m4rs.js";
|
|
123
123
|
import {
|
|
124
124
|
buildCorrelationId,
|
|
125
125
|
listActive,
|
|
@@ -135,11 +135,11 @@ import {
|
|
|
135
135
|
validateActionability,
|
|
136
136
|
validateActionableFields,
|
|
137
137
|
validateLesson
|
|
138
|
-
} from "./index-
|
|
138
|
+
} from "./index-sa3dgpmc.js";
|
|
139
139
|
import {
|
|
140
140
|
authorizeCuration,
|
|
141
141
|
buildConfigFingerprintInput
|
|
142
|
-
} from "./index-
|
|
142
|
+
} from "./index-rp5msv7n.js";
|
|
143
143
|
import {
|
|
144
144
|
cohortConfigFingerprint
|
|
145
145
|
} from "./index-rtry5xyf.js";
|
|
@@ -169,7 +169,7 @@ import {
|
|
|
169
169
|
transactFile,
|
|
170
170
|
transactKnowledge,
|
|
171
171
|
wordBigrams
|
|
172
|
-
} from "./index-
|
|
172
|
+
} from "./index-45mvd5q7.js";
|
|
173
173
|
import {
|
|
174
174
|
MAX_EVENT_LOG_ENTRIES,
|
|
175
175
|
_internals,
|
|
@@ -179,7 +179,7 @@ import {
|
|
|
179
179
|
recordHiveKnowledgeEvent,
|
|
180
180
|
recordKnowledgeEvent,
|
|
181
181
|
resolveKnowledgeEventsPath
|
|
182
|
-
} from "./index-
|
|
182
|
+
} from "./index-fm4zfxnr.js";
|
|
183
183
|
import {
|
|
184
184
|
resolveHiveDataDir,
|
|
185
185
|
resolveHiveEventsPath,
|
|
@@ -201,7 +201,7 @@ import {
|
|
|
201
201
|
init_loader,
|
|
202
202
|
loadPluginConfig,
|
|
203
203
|
loadPluginConfigWithMeta
|
|
204
|
-
} from "./index-
|
|
204
|
+
} from "./index-ambnwnmt.js";
|
|
205
205
|
import {
|
|
206
206
|
RetrospectiveEvidenceSchema
|
|
207
207
|
} from "./index-k5jrywpr.js";
|
|
@@ -220,7 +220,7 @@ import {
|
|
|
220
220
|
init_schema,
|
|
221
221
|
init_tool_metadata,
|
|
222
222
|
stripKnownSwarmPrefix
|
|
223
|
-
} from "./index-
|
|
223
|
+
} from "./index-414r47r7.js";
|
|
224
224
|
import {
|
|
225
225
|
KNOWLEDGE_SCHEMA_VERSION,
|
|
226
226
|
OUTCOME_BLOCK_THRESHOLD,
|
|
@@ -250,7 +250,7 @@ import {
|
|
|
250
250
|
advisoryWarn,
|
|
251
251
|
getDeferredWarnings,
|
|
252
252
|
init_warning_buffer
|
|
253
|
-
} from "./index-
|
|
253
|
+
} from "./index-4rhhvd1a.js";
|
|
254
254
|
import {
|
|
255
255
|
readSwarmFileAsync,
|
|
256
256
|
safeHook,
|
|
@@ -10815,7 +10815,7 @@ async function runCuratorPhase(directory, phase, agentsDispatched, config, knowl
|
|
|
10815
10815
|
}
|
|
10816
10816
|
if (config.skill_generation_enabled === true && skillCandidates.length > 0) {
|
|
10817
10817
|
try {
|
|
10818
|
-
const skillModule = await import("./skill-generator-
|
|
10818
|
+
const skillModule = await import("./skill-generator-ffc1agyw.js");
|
|
10819
10819
|
for (const cand of skillCandidates) {
|
|
10820
10820
|
if (cand.confidence < (config.min_skill_confidence ?? DEFAULT_SKILL_MIN_CONFIDENCE)) {
|
|
10821
10821
|
continue;
|
|
@@ -11152,7 +11152,7 @@ async function applyCuratorKnowledgeUpdates(directory, recommendations, knowledg
|
|
|
11152
11152
|
} catch {}
|
|
11153
11153
|
}
|
|
11154
11154
|
if (contradictedEntries.length > 0 && knowledgeConfig.contradiction_threshold_action === "quarantine") {
|
|
11155
|
-
const { maybeQuarantineOnContradiction } = await import("./knowledge-escalator-
|
|
11155
|
+
const { maybeQuarantineOnContradiction } = await import("./knowledge-escalator-gr8qd7kz.js");
|
|
11156
11156
|
for (const { id } of contradictedEntries) {
|
|
11157
11157
|
try {
|
|
11158
11158
|
await maybeQuarantineOnContradiction(directory, id, knowledgeConfig.contradiction_quarantine_threshold, knowledgeConfig.contradiction_quarantine_window_days);
|
|
@@ -11951,7 +11951,7 @@ async function runCuratorPostMortem(directory, options = {}) {
|
|
|
11951
11951
|
warnings.push("Failed to collect knowledge summary.");
|
|
11952
11952
|
}
|
|
11953
11953
|
try {
|
|
11954
|
-
const { getScanStatus } = await import("./scan-cursor-
|
|
11954
|
+
const { getScanStatus } = await import("./scan-cursor-fa5sy36q.js");
|
|
11955
11955
|
const scanStatus = await getScanStatus(directory);
|
|
11956
11956
|
if (scanStatus.remaining_estimate > 0) {
|
|
11957
11957
|
warnings.push(`Fair scan: reviewed ${knowledgeSummary.length} entries this sweep (generation ${scanStatus.generation}); ${scanStatus.remaining_estimate} more eligible entries will be visited in future curation sweeps.`);
|
|
@@ -12123,9 +12123,9 @@ var _internals15 = {
|
|
|
12123
12123
|
verifyPostMortemKnowledgeActions,
|
|
12124
12124
|
repairPostMortemActions,
|
|
12125
12125
|
loadDefaultKnowledgeConfig: async (directory) => {
|
|
12126
|
-
const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-
|
|
12126
|
+
const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-bw68my66.js");
|
|
12127
12127
|
try {
|
|
12128
|
-
const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-
|
|
12128
|
+
const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-emzes7sj.js");
|
|
12129
12129
|
const loaded = loadPluginConfigWithMeta2(directory);
|
|
12130
12130
|
return KnowledgeConfigSchema2.parse(loaded.config.knowledge ?? {});
|
|
12131
12131
|
} catch {
|
|
@@ -12133,11 +12133,11 @@ var _internals15 = {
|
|
|
12133
12133
|
}
|
|
12134
12134
|
},
|
|
12135
12135
|
applyCuratorKnowledgeUpdates: async (directory, recommendations, knowledgeConfig, generation) => {
|
|
12136
|
-
const { applyCuratorKnowledgeUpdates: applyCuratorKnowledgeUpdates2 } = await import("./curator-
|
|
12136
|
+
const { applyCuratorKnowledgeUpdates: applyCuratorKnowledgeUpdates2 } = await import("./curator-n6whbm4r.js");
|
|
12137
12137
|
return applyCuratorKnowledgeUpdates2(directory, recommendations, knowledgeConfig, generation);
|
|
12138
12138
|
},
|
|
12139
12139
|
checkHivePromotions: async (entries, knowledgeConfig, directory) => {
|
|
12140
|
-
const { checkHivePromotions } = await import("./hive-promoter-
|
|
12140
|
+
const { checkHivePromotions } = await import("./hive-promoter-mpjq0fw9.js");
|
|
12141
12141
|
return checkHivePromotions(entries, knowledgeConfig, directory);
|
|
12142
12142
|
},
|
|
12143
12143
|
applyProposalTriage: async (directory, triage) => {
|
|
@@ -12146,7 +12146,7 @@ var _internals15 = {
|
|
|
12146
12146
|
activateProposal,
|
|
12147
12147
|
listSkills: listSkills2,
|
|
12148
12148
|
sanitizeSlug
|
|
12149
|
-
} = await import("./skill-generator-
|
|
12149
|
+
} = await import("./skill-generator-ffc1agyw.js");
|
|
12150
12150
|
const result = {
|
|
12151
12151
|
approved: [],
|
|
12152
12152
|
rejected: [],
|
|
@@ -12188,7 +12188,7 @@ var _internals15 = {
|
|
|
12188
12188
|
return result;
|
|
12189
12189
|
},
|
|
12190
12190
|
readPriorDriftReports: async (directory) => {
|
|
12191
|
-
const { readPriorDriftReports } = await import("./curator-drift-
|
|
12191
|
+
const { readPriorDriftReports } = await import("./curator-drift-24bdacdc.js");
|
|
12192
12192
|
return readPriorDriftReports(directory);
|
|
12193
12193
|
},
|
|
12194
12194
|
readSwarmKnowledge: (directory) => readKnowledge(resolveSwarmKnowledgePath(directory))
|
|
@@ -14671,9 +14671,9 @@ function hashContent(content) {
|
|
|
14671
14671
|
return createHash7("sha1").update(content).digest("hex");
|
|
14672
14672
|
}
|
|
14673
14673
|
async function loadConfigForPolicyCurator(directory) {
|
|
14674
|
-
const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-
|
|
14674
|
+
const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-bw68my66.js");
|
|
14675
14675
|
try {
|
|
14676
|
-
const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-
|
|
14676
|
+
const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-emzes7sj.js");
|
|
14677
14677
|
const { config: loadedConfig } = loadPluginConfigWithMeta2(directory);
|
|
14678
14678
|
return KnowledgeConfigSchema2.parse(loadedConfig.knowledge ?? {});
|
|
14679
14679
|
} catch {
|
|
@@ -17834,7 +17834,7 @@ async function runFinalizeStage(ctx) {
|
|
|
17834
17834
|
}
|
|
17835
17835
|
}
|
|
17836
17836
|
try {
|
|
17837
|
-
const { CuratorConfigSchema: CCS } = await import("./schema-
|
|
17837
|
+
const { CuratorConfigSchema: CCS } = await import("./schema-bw68my66.js");
|
|
17838
17838
|
const { config: pmLoadedConfig } = _internals24.loadPluginConfigWithMeta(ctx.directory);
|
|
17839
17839
|
const curatorCfg = CCS.parse(pmLoadedConfig.curator ?? {});
|
|
17840
17840
|
if (curatorCfg.enabled && curatorCfg.postmortem_enabled) {
|
|
@@ -20003,9 +20003,9 @@ var _internals28 = {
|
|
|
20003
20003
|
readSwarmFileAsync,
|
|
20004
20004
|
loadCuratorDeps: async () => {
|
|
20005
20005
|
const [{ CuratorConfigSchema }, curator, { createCuratorLLMDelegate: createCuratorLLMDelegate2 }] = await Promise.all([
|
|
20006
|
-
import("./schema-
|
|
20007
|
-
import("./curator-
|
|
20008
|
-
import("./curator-llm-factory-
|
|
20006
|
+
import("./schema-bw68my66.js"),
|
|
20007
|
+
import("./curator-n6whbm4r.js"),
|
|
20008
|
+
import("./curator-llm-factory-0hncnz9t.js")
|
|
20009
20009
|
]);
|
|
20010
20010
|
return { CuratorConfigSchema, curator, createCuratorLLMDelegate: createCuratorLLMDelegate2 };
|
|
20011
20011
|
}
|
|
@@ -20504,7 +20504,7 @@ import { fileURLToPath } from "url";
|
|
|
20504
20504
|
// package.json
|
|
20505
20505
|
var package_default = {
|
|
20506
20506
|
name: "opencode-swarm",
|
|
20507
|
-
version: "7.125.
|
|
20507
|
+
version: "7.125.4",
|
|
20508
20508
|
description: "Architect-centric agentic swarm plugin for OpenCode - hub-and-spoke orchestration with SME consultation, code generation, and QA review",
|
|
20509
20509
|
main: "dist/index.js",
|
|
20510
20510
|
types: "dist/index.d.ts",
|
|
@@ -21025,7 +21025,7 @@ async function computeCurationDiagnostics(directory, entries) {
|
|
|
21025
21025
|
let scanCompleted = false;
|
|
21026
21026
|
let scanRemaining = 0;
|
|
21027
21027
|
try {
|
|
21028
|
-
const { getScanStatus } = await import("./scan-cursor-
|
|
21028
|
+
const { getScanStatus } = await import("./scan-cursor-fa5sy36q.js");
|
|
21029
21029
|
const status = await getScanStatus(directory);
|
|
21030
21030
|
scanGeneration = status.generation;
|
|
21031
21031
|
scanCompleted = status.completed;
|
|
@@ -21035,17 +21035,17 @@ async function computeCurationDiagnostics(directory, entries) {
|
|
|
21035
21035
|
try {
|
|
21036
21036
|
const { isLinked: isLinked2 } = await import("./knowledge-link-4yd2z8ev.js");
|
|
21037
21037
|
if (isLinked2(directory)) {
|
|
21038
|
-
const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-
|
|
21038
|
+
const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-bw68my66.js");
|
|
21039
21039
|
let config;
|
|
21040
21040
|
try {
|
|
21041
|
-
const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-
|
|
21041
|
+
const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-emzes7sj.js");
|
|
21042
21042
|
const loaded = loadPluginConfigWithMeta2(directory);
|
|
21043
21043
|
config = KnowledgeConfigSchema2.parse(loaded.config.knowledge ?? {});
|
|
21044
21044
|
} catch {
|
|
21045
21045
|
config = KnowledgeConfigSchema2.parse({});
|
|
21046
21046
|
}
|
|
21047
21047
|
const { cohortConfigFingerprint: cohortConfigFingerprint2 } = await import("./config-fingerprint-v22xh5a2.js");
|
|
21048
|
-
const { buildConfigFingerprintInput: buildConfigFingerprintInput2, readCohortConfigFingerprint } = await import("./curation-policy-
|
|
21048
|
+
const { buildConfigFingerprintInput: buildConfigFingerprintInput2, readCohortConfigFingerprint } = await import("./curation-policy-7pgdjt5w.js");
|
|
21049
21049
|
const currentFp = cohortConfigFingerprint2(buildConfigFingerprintInput2(config));
|
|
21050
21050
|
const cohortFp = await readCohortConfigFingerprint(directory);
|
|
21051
21051
|
configMatch = cohortFp === null ? null : currentFp === cohortFp;
|
|
@@ -21985,7 +21985,7 @@ async function getDiagnoseData(directory) {
|
|
|
21985
21985
|
checks.push({
|
|
21986
21986
|
name: "Deferred Warnings",
|
|
21987
21987
|
status: "\u26A0\uFE0F",
|
|
21988
|
-
detail: `${getDeferredWarnings().length} warning(s) deferred from init (
|
|
21988
|
+
detail: `${getDeferredWarnings().length} warning(s) deferred from init \u2014 see the Deferred Warnings section below (or set OPENCODE_SWARM_DEBUG=1 for full detail)`
|
|
21989
21989
|
});
|
|
21990
21990
|
}
|
|
21991
21991
|
const cachePaths = getPluginCachePaths();
|
|
@@ -22233,8 +22233,10 @@ async function handleDoctorCommand(directory, args) {
|
|
|
22233
22233
|
const result = runConfigDoctor(config, directory);
|
|
22234
22234
|
let output;
|
|
22235
22235
|
if (enableAutoFix && result.hasAutoFixableIssues) {
|
|
22236
|
-
const { runConfigDoctorWithFixes } = await import("./config-doctor-
|
|
22237
|
-
const fixResult = await runConfigDoctorWithFixes(directory, config, true
|
|
22236
|
+
const { runConfigDoctorWithFixes } = await import("./config-doctor-rm1m07gz.js");
|
|
22237
|
+
const fixResult = await runConfigDoctorWithFixes(directory, config, true, {
|
|
22238
|
+
applyLossy: true
|
|
22239
|
+
});
|
|
22238
22240
|
output = formatDoctorMarkdown(fixResult.result);
|
|
22239
22241
|
} else {
|
|
22240
22242
|
const lastRun = readDoctorArtifact(directory);
|
|
@@ -23046,7 +23048,7 @@ async function handleEvidenceCommand(directory, args) {
|
|
|
23046
23048
|
return formatTaskEvidenceMarkdown(evidenceData);
|
|
23047
23049
|
}
|
|
23048
23050
|
async function handleEvidenceSummaryCommand(directory) {
|
|
23049
|
-
const { buildEvidenceSummary } = await import("./evidence-summary-service-
|
|
23051
|
+
const { buildEvidenceSummary } = await import("./evidence-summary-service-thx1c3me.js");
|
|
23050
23052
|
const artifact = await buildEvidenceSummary(directory);
|
|
23051
23053
|
if (!artifact) {
|
|
23052
23054
|
return "No plan found. Run `/swarm plan` to check plan status.";
|
|
@@ -28572,6 +28574,12 @@ function serializeAgentSession(s) {
|
|
|
28572
28574
|
},
|
|
28573
28575
|
...s.cachedCohortId !== undefined && {
|
|
28574
28576
|
cachedCohortId: s.cachedCohortId
|
|
28577
|
+
},
|
|
28578
|
+
...s.lastObservedModel !== undefined && {
|
|
28579
|
+
lastObservedModel: s.lastObservedModel
|
|
28580
|
+
},
|
|
28581
|
+
...s.lastObservedProviderID !== undefined && {
|
|
28582
|
+
lastObservedProviderID: s.lastObservedProviderID
|
|
28575
28583
|
}
|
|
28576
28584
|
};
|
|
28577
28585
|
}
|
|
@@ -41008,7 +41016,7 @@ function buildDetailedHelp(commandName, entry) {
|
|
|
41008
41016
|
async function handleHelpCommand(ctx) {
|
|
41009
41017
|
const targetCommand = ctx.args.join(" ");
|
|
41010
41018
|
if (!targetCommand) {
|
|
41011
|
-
const { buildHelpText } = await import("./index-
|
|
41019
|
+
const { buildHelpText } = await import("./index-hr2kzcem.js");
|
|
41012
41020
|
return buildHelpText();
|
|
41013
41021
|
}
|
|
41014
41022
|
const tokens = targetCommand.split(/\s+/);
|
|
@@ -41017,7 +41025,7 @@ async function handleHelpCommand(ctx) {
|
|
|
41017
41025
|
return _internals62.buildDetailedHelp(resolved.key, resolved.entry);
|
|
41018
41026
|
}
|
|
41019
41027
|
const similar = _internals62.findSimilarCommands(targetCommand);
|
|
41020
|
-
const { buildHelpText: fullHelp } = await import("./index-
|
|
41028
|
+
const { buildHelpText: fullHelp } = await import("./index-hr2kzcem.js");
|
|
41021
41029
|
if (similar.length > 0) {
|
|
41022
41030
|
return `Command '/swarm ${targetCommand}' not found.
|
|
41023
41031
|
|
|
@@ -41156,7 +41164,7 @@ var COMMAND_REGISTRY = {
|
|
|
41156
41164
|
},
|
|
41157
41165
|
"guardrail explain": {
|
|
41158
41166
|
handler: async (ctx) => {
|
|
41159
|
-
const { handleGuardrailExplain } = await import("./guardrail-explain-
|
|
41167
|
+
const { handleGuardrailExplain } = await import("./guardrail-explain-8gknrsbb.js");
|
|
41160
41168
|
return handleGuardrailExplain(ctx.directory, ctx.args);
|
|
41161
41169
|
},
|
|
41162
41170
|
description: "Dry-run: show what the guardrails would do to a command or write target (executes nothing)",
|
|
@@ -41166,7 +41174,7 @@ var COMMAND_REGISTRY = {
|
|
|
41166
41174
|
},
|
|
41167
41175
|
"guardrail-explain": {
|
|
41168
41176
|
handler: async (ctx) => {
|
|
41169
|
-
const { handleGuardrailExplain } = await import("./guardrail-explain-
|
|
41177
|
+
const { handleGuardrailExplain } = await import("./guardrail-explain-8gknrsbb.js");
|
|
41170
41178
|
return handleGuardrailExplain(ctx.directory, ctx.args);
|
|
41171
41179
|
},
|
|
41172
41180
|
description: "Dry-run: show what the guardrails would do to a command or write target (executes nothing)",
|
|
@@ -41176,7 +41184,7 @@ var COMMAND_REGISTRY = {
|
|
|
41176
41184
|
},
|
|
41177
41185
|
"guardrail-log": {
|
|
41178
41186
|
handler: async (ctx) => {
|
|
41179
|
-
const { handleGuardrailLog } = await import("./guardrail-log-
|
|
41187
|
+
const { handleGuardrailLog } = await import("./guardrail-log-6a2zxvtx.js");
|
|
41180
41188
|
return handleGuardrailLog(ctx.directory, ctx.args);
|
|
41181
41189
|
},
|
|
41182
41190
|
description: "Read the guardrail decision log (use --blocks-only for blocks)",
|
|
@@ -44445,6 +44453,17 @@ init_constants();
|
|
|
44445
44453
|
init_schema();
|
|
44446
44454
|
init_logger();
|
|
44447
44455
|
|
|
44456
|
+
// src/utils/provider-error-classification.ts
|
|
44457
|
+
var TRANSIENT_STATUS_CODES = new Set([
|
|
44458
|
+
408,
|
|
44459
|
+
429,
|
|
44460
|
+
500,
|
|
44461
|
+
502,
|
|
44462
|
+
503,
|
|
44463
|
+
504,
|
|
44464
|
+
529
|
|
44465
|
+
]);
|
|
44466
|
+
|
|
44448
44467
|
// src/hooks/guardrails/destructive-command.ts
|
|
44449
44468
|
import * as fsSync3 from "fs";
|
|
44450
44469
|
import * as path83 from "path";
|
|
@@ -44786,9 +44805,6 @@ init_schema();
|
|
|
44786
44805
|
// src/hooks/model-limits.ts
|
|
44787
44806
|
var loggedFirstCalls = new Set;
|
|
44788
44807
|
|
|
44789
|
-
// src/hooks/guardrails/messages-transform.ts
|
|
44790
|
-
var TRANSIENT_STATUS_CODES = new Set([408, 429, 500, 502, 503, 504, 529]);
|
|
44791
|
-
|
|
44792
44808
|
// src/hooks/guardrails/nontransient-circuit.ts
|
|
44793
44809
|
init_schema();
|
|
44794
44810
|
var IMMEDIATE_HARD_STOP_CATEGORIES = new Set([
|
|
@@ -45550,9 +45566,9 @@ function detectInterpreterEval(cmd) {
|
|
|
45550
45566
|
return [];
|
|
45551
45567
|
const suffixWords = getSuffixWords(cmd);
|
|
45552
45568
|
const evalFlags = {
|
|
45553
|
-
python: ["-c"
|
|
45554
|
-
python3: ["-c"
|
|
45555
|
-
python2: ["-c"
|
|
45569
|
+
python: ["-c"],
|
|
45570
|
+
python3: ["-c"],
|
|
45571
|
+
python2: ["-c"],
|
|
45556
45572
|
node: ["-e", "-p", "-pe"],
|
|
45557
45573
|
bun: ["-e", "-p", "-pe"],
|
|
45558
45574
|
ruby: ["-e"],
|
|
@@ -46495,7 +46511,6 @@ var SPEC_DRIFT_BLOCKED_TOOLS = new Set([
|
|
|
46495
46511
|
"lean_turbo_run_phase",
|
|
46496
46512
|
"lean_turbo_acquire_locks"
|
|
46497
46513
|
]);
|
|
46498
|
-
var TRANSIENT_STATUS_CODES2 = new Set([408, 429, 500, 502, 503, 504, 529]);
|
|
46499
46514
|
var toolCallsSinceLastWrite = new Map;
|
|
46500
46515
|
var noOpWarningIssued = new Set;
|
|
46501
46516
|
// src/hooks/delegation-gate.ts
|
|
@@ -8,11 +8,11 @@ import {
|
|
|
8
8
|
init_constants,
|
|
9
9
|
init_schema,
|
|
10
10
|
resolveExternalSkillsConfig
|
|
11
|
-
} from "./index-
|
|
11
|
+
} from "./index-414r47r7.js";
|
|
12
12
|
import {
|
|
13
13
|
advisoryWarn,
|
|
14
14
|
init_warning_buffer
|
|
15
|
-
} from "./index-
|
|
15
|
+
} from "./index-4rhhvd1a.js";
|
|
16
16
|
import {
|
|
17
17
|
MAX_MERGE_DEPTH,
|
|
18
18
|
deepMerge,
|
|
@@ -30,6 +30,7 @@ __export(exports_loader, {
|
|
|
30
30
|
loadPluginConfigWithMeta: () => loadPluginConfigWithMeta,
|
|
31
31
|
loadPluginConfig: () => loadPluginConfig,
|
|
32
32
|
loadAgentPrompt: () => loadAgentPrompt,
|
|
33
|
+
formatZodIssues: () => formatZodIssues,
|
|
33
34
|
deepMerge: () => deepMerge,
|
|
34
35
|
MAX_MERGE_DEPTH: () => MAX_MERGE_DEPTH,
|
|
35
36
|
MAX_CONFIG_FILE_BYTES: () => MAX_CONFIG_FILE_BYTES
|
|
@@ -108,7 +109,7 @@ function sanitizeExternalSkillsConfig(raw) {
|
|
|
108
109
|
external_skills: resolveExternalSkillsConfig(esResult.data)
|
|
109
110
|
};
|
|
110
111
|
}
|
|
111
|
-
advisoryWarn("[opencode-swarm] external_skills config validation failed:", esResult.error
|
|
112
|
+
advisoryWarn("[opencode-swarm] external_skills config validation failed:", formatZodIssues(esResult.error));
|
|
112
113
|
advisoryWarn("[opencode-swarm] External skills curation disabled due to invalid config. Fix the external_skills section to enable it.");
|
|
113
114
|
const cleaned = { ...raw };
|
|
114
115
|
delete cleaned.external_skills;
|
|
@@ -149,7 +150,7 @@ function sanitizeGatesConfig(raw) {
|
|
|
149
150
|
}
|
|
150
151
|
const sectionResult = schema.safeParse(sectionValue);
|
|
151
152
|
if (!sectionResult.success) {
|
|
152
|
-
advisoryWarn(`[opencode-swarm] gates.${key} config validation failed; that gate section will use defaults and other config sections remain active:`, sectionResult.error
|
|
153
|
+
advisoryWarn(`[opencode-swarm] gates.${key} config validation failed; that gate section will use defaults and other config sections remain active:`, formatZodIssues(sectionResult.error));
|
|
153
154
|
delete cleanedGates[key];
|
|
154
155
|
}
|
|
155
156
|
}
|
|
@@ -160,7 +161,7 @@ function sanitizeGatesConfig(raw) {
|
|
|
160
161
|
gates: gatesResult.data
|
|
161
162
|
};
|
|
162
163
|
}
|
|
163
|
-
advisoryWarn("[opencode-swarm] gates config validation failed after section cleanup; quality gates will use defaults and other config sections remain active:", gatesResult.error
|
|
164
|
+
advisoryWarn("[opencode-swarm] gates config validation failed after section cleanup; quality gates will use defaults and other config sections remain active:", formatZodIssues(gatesResult.error));
|
|
164
165
|
const cleaned = { ...raw };
|
|
165
166
|
delete cleaned.gates;
|
|
166
167
|
return cleaned;
|
|
@@ -168,6 +169,14 @@ function sanitizeGatesConfig(raw) {
|
|
|
168
169
|
function sanitizeSectionConfigs(raw) {
|
|
169
170
|
return sanitizeGatesConfig(sanitizeExternalSkillsConfig(raw));
|
|
170
171
|
}
|
|
172
|
+
function formatZodIssues(error) {
|
|
173
|
+
if (error.issues.length === 0)
|
|
174
|
+
return "";
|
|
175
|
+
return error.issues.map((issue) => {
|
|
176
|
+
const dotted = issue.path.map(String).join(".");
|
|
177
|
+
return dotted ? `${dotted}: ${issue.message}` : issue.message;
|
|
178
|
+
}).join("; ");
|
|
179
|
+
}
|
|
171
180
|
function stripUnrecognizedKeys(raw, error) {
|
|
172
181
|
const removed = [];
|
|
173
182
|
const cleaned = structuredClone(raw);
|
|
@@ -230,7 +239,7 @@ function parseConfigWithFallback(mergedRaw, rawUserConfig, failedResult, loadedF
|
|
|
230
239
|
if (offending.length > 0) {
|
|
231
240
|
advisoryWarn(`[opencode-swarm] Merged config validation failed. Unrecognized key(s): ${offending.join(", ")}.`);
|
|
232
241
|
} else {
|
|
233
|
-
advisoryWarn("[opencode-swarm] Merged config validation failed:", result.error
|
|
242
|
+
advisoryWarn("[opencode-swarm] Merged config validation failed:", formatZodIssues(result.error));
|
|
234
243
|
}
|
|
235
244
|
advisoryWarn("[opencode-swarm] \u26A0\uFE0F SECURITY: Falling back to conservative defaults with guardrails ENABLED. Fix the config file to restore custom configuration.");
|
|
236
245
|
return PluginConfigSchema.parse({ guardrails: { enabled: true } });
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
loadPluginConfigWithMeta,
|
|
7
7
|
loadPluginConfigWithMetaAsync,
|
|
8
8
|
resolveWorktreeIsolationConfig
|
|
9
|
-
} from "./index-
|
|
9
|
+
} from "./index-ambnwnmt.js";
|
|
10
10
|
import {
|
|
11
11
|
ApprovalEvidenceSchema,
|
|
12
12
|
BaseEvidenceSchema,
|
|
@@ -58,7 +58,7 @@ import {
|
|
|
58
58
|
WorktreeIsolationConfigSchema,
|
|
59
59
|
isQAAgent,
|
|
60
60
|
isSubagent
|
|
61
|
-
} from "./index-
|
|
61
|
+
} from "./index-414r47r7.js";
|
|
62
62
|
import"./index-bk5tah7q.js";
|
|
63
63
|
import {
|
|
64
64
|
MigrationStatusSchema,
|
|
@@ -69,7 +69,7 @@ import {
|
|
|
69
69
|
TaskSizeSchema,
|
|
70
70
|
TaskStatusSchema
|
|
71
71
|
} from "./index-1kz6da87.js";
|
|
72
|
-
import"./index-
|
|
72
|
+
import"./index-4rhhvd1a.js";
|
|
73
73
|
import"./index-zjygnfay.js";
|
|
74
74
|
import"./index-zgwm4ryv.js";
|
|
75
75
|
import"./index-bpmtbmy9.js";
|
|
@@ -608,7 +608,7 @@ async function applyKnowledgeVerdictFeedback(directory, options) {
|
|
|
608
608
|
deltas.push({ id, delta });
|
|
609
609
|
}
|
|
610
610
|
if (deltas.length > 0) {
|
|
611
|
-
const { bumpKnowledgeConfidenceBatch } = await import("./knowledge-store-
|
|
611
|
+
const { bumpKnowledgeConfidenceBatch } = await import("./knowledge-store-qq3w5yt8.js");
|
|
612
612
|
await bumpKnowledgeConfidenceBatch(directory, deltas, options?.floorOptions);
|
|
613
613
|
}
|
|
614
614
|
return {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
handleGuardrailExplain
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-jkwyjr8x.js";
|
|
5
5
|
import {
|
|
6
6
|
handleGuardrailLog
|
|
7
|
-
} from "./index-
|
|
7
|
+
} from "./index-4ycq2mrp.js";
|
|
8
8
|
import {
|
|
9
9
|
COMMAND_REGISTRY,
|
|
10
10
|
SWARM_COMMAND_TOOL_ALLOWLIST,
|
|
@@ -83,28 +83,28 @@ import {
|
|
|
83
83
|
handleWriteRetroCommand,
|
|
84
84
|
normalizeSwarmCommandInput,
|
|
85
85
|
resolveCommand
|
|
86
|
-
} from "./index-
|
|
87
|
-
import"./index-
|
|
88
|
-
import"./index-
|
|
89
|
-
import"./index-
|
|
86
|
+
} from "./index-7xg876np.js";
|
|
87
|
+
import"./index-xezv6tdw.js";
|
|
88
|
+
import"./index-pk099nqv.js";
|
|
89
|
+
import"./index-kk1scggc.js";
|
|
90
90
|
import"./index-4905hd2m.js";
|
|
91
91
|
import"./index-134d35c1.js";
|
|
92
92
|
import"./index-6n2jpz7x.js";
|
|
93
|
-
import"./index-
|
|
94
|
-
import"./index-
|
|
95
|
-
import"./index-
|
|
93
|
+
import"./index-01n43w2p.js";
|
|
94
|
+
import"./index-vdfewvn5.js";
|
|
95
|
+
import"./index-8tjbq2ej.js";
|
|
96
96
|
import"./index-vxv732ex.js";
|
|
97
97
|
import"./index-c8s9a3zh.js";
|
|
98
|
-
import"./index-
|
|
98
|
+
import"./index-9ss2m4rs.js";
|
|
99
99
|
import"./index-23zsx7dm.js";
|
|
100
|
-
import"./index-
|
|
101
|
-
import"./index-
|
|
100
|
+
import"./index-sa3dgpmc.js";
|
|
101
|
+
import"./index-rp5msv7n.js";
|
|
102
102
|
import"./index-rtry5xyf.js";
|
|
103
|
-
import"./index-
|
|
104
|
-
import"./index-
|
|
103
|
+
import"./index-45mvd5q7.js";
|
|
104
|
+
import"./index-fm4zfxnr.js";
|
|
105
105
|
import"./index-ae75rja9.js";
|
|
106
106
|
import"./index-q27bajqb.js";
|
|
107
|
-
import"./index-
|
|
107
|
+
import"./index-ambnwnmt.js";
|
|
108
108
|
import"./index-k5jrywpr.js";
|
|
109
109
|
import"./index-n832052r.js";
|
|
110
110
|
import {
|
|
@@ -113,15 +113,15 @@ import {
|
|
|
113
113
|
init_constants,
|
|
114
114
|
init_schema,
|
|
115
115
|
stripKnownSwarmPrefix
|
|
116
|
-
} from "./index-
|
|
116
|
+
} from "./index-414r47r7.js";
|
|
117
117
|
import"./index-bk5tah7q.js";
|
|
118
118
|
import"./index-8fwhhayc.js";
|
|
119
119
|
import"./index-q1exe2b3.js";
|
|
120
120
|
import"./index-gnvg72y1.js";
|
|
121
121
|
import"./index-2tn5h2zp.js";
|
|
122
122
|
import"./index-1kz6da87.js";
|
|
123
|
-
import"./index-
|
|
124
|
-
import"./index-
|
|
123
|
+
import"./index-g4ef4v3m.js";
|
|
124
|
+
import"./index-4rhhvd1a.js";
|
|
125
125
|
import"./index-0cz1ws47.js";
|
|
126
126
|
import"./index-2445sx3d.js";
|
|
127
127
|
import"./index-z6xqpmqg.js";
|
|
@@ -12,14 +12,14 @@ import {
|
|
|
12
12
|
detectPosixWrites,
|
|
13
13
|
detectWindowsWrites,
|
|
14
14
|
resolveWriteTargets
|
|
15
|
-
} from "./index-
|
|
15
|
+
} from "./index-7xg876np.js";
|
|
16
16
|
import {
|
|
17
17
|
checkFileAuthority,
|
|
18
18
|
classifyFile,
|
|
19
19
|
isInDeclaredScope,
|
|
20
20
|
redactPath,
|
|
21
21
|
redactShellCommand
|
|
22
|
-
} from "./index-
|
|
22
|
+
} from "./index-xezv6tdw.js";
|
|
23
23
|
|
|
24
24
|
// src/services/guardrail-explain-service.ts
|
|
25
25
|
import path from "path";
|