opencode-swarm 7.118.0 → 7.119.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/dist/cli/{core-zg8s1jwx.js → core-gf1t2jmn.js} +2 -1
- package/dist/cli/{curator-920swpnk.js → curator-5xfkejsq.js} +6 -5
- package/dist/cli/{curator-drift-7p2ky1th.js → curator-drift-nn71xfz6.js} +2 -1
- package/dist/cli/{curator-llm-factory-kqt1f4sw.js → curator-llm-factory-rwwnmdvk.js} +6 -5
- package/dist/cli/{evidence-summary-service-bwt6drb3.js → evidence-summary-service-cy3k37je.js} +3 -2
- package/dist/cli/{guardrail-explain-bycz51b0.js → guardrail-explain-kacpc2zm.js} +7 -6
- package/dist/cli/{hive-promoter-w9pgfs6w.js → hive-promoter-03m8pwg6.js} +6 -5
- package/dist/cli/{index-k83hebh1.js → index-05ee8pws.js} +7 -6
- package/dist/cli/{index-470tykwx.js → index-7pspktns.js} +1 -1
- package/dist/cli/{index-34tsqvqb.js → index-mr3pnc4h.js} +59 -47
- package/dist/cli/{index-xdsd2hma.js → index-p45sshb5.js} +7 -5
- package/dist/cli/{index-rdwfqhp7.js → index-q4kgsvdd.js} +7 -4
- package/dist/cli/{index-sb9x6xjj.js → index-r2ysfdet.js} +4 -26
- package/dist/cli/{index-scww5b77.js → index-vwvkpg0d.js} +4 -1
- package/dist/cli/index-ye3fndsw.js +30 -0
- package/dist/cli/index.js +6 -5
- package/dist/cli/{skill-generator-t47xyfps.js → skill-generator-3f8dqjj2.js} +2 -1
- package/dist/diff/semantic-classifier.d.ts +1 -1
- package/dist/hooks/knowledge-curator.d.ts +4 -5
- package/dist/index.js +43 -43
- package/package.json +1 -1
|
@@ -14,7 +14,8 @@ import {
|
|
|
14
14
|
resolveWorktreeBaseDir,
|
|
15
15
|
shortenWorktreePath,
|
|
16
16
|
writeLaneProfileToDiskReal
|
|
17
|
-
} from "./index-
|
|
17
|
+
} from "./index-q4kgsvdd.js";
|
|
18
|
+
import"./index-ye3fndsw.js";
|
|
18
19
|
import"./index-5e4e2hvv.js";
|
|
19
20
|
import"./index-p0arc26j.js";
|
|
20
21
|
import"./index-zgwm4ryv.js";
|
|
@@ -14,17 +14,17 @@ import {
|
|
|
14
14
|
runCuratorInit,
|
|
15
15
|
runCuratorPhase,
|
|
16
16
|
writeCuratorSummary
|
|
17
|
-
} from "./index-
|
|
17
|
+
} from "./index-mr3pnc4h.js";
|
|
18
18
|
import"./index-nprawcc0.js";
|
|
19
19
|
import"./index-g2wrs7jy.js";
|
|
20
20
|
import"./index-c8s9a3zh.js";
|
|
21
21
|
import"./index-11q1t6g0.js";
|
|
22
22
|
import"./index-pdk1n8yh.js";
|
|
23
|
-
import"./index-
|
|
24
|
-
import"./index-
|
|
23
|
+
import"./index-p45sshb5.js";
|
|
24
|
+
import"./index-vwvkpg0d.js";
|
|
25
25
|
import"./index-4905hd2m.js";
|
|
26
26
|
import"./index-5bcrp3bc.js";
|
|
27
|
-
import"./index-
|
|
27
|
+
import"./index-r2ysfdet.js";
|
|
28
28
|
import"./index-pjhfe7c3.js";
|
|
29
29
|
import"./index-jbdgpqpj.js";
|
|
30
30
|
import"./index-5hze8ztj.js";
|
|
@@ -35,7 +35,8 @@ import"./index-vxv732ex.js";
|
|
|
35
35
|
import"./index-8fwhhayc.js";
|
|
36
36
|
import"./index-q1exe2b3.js";
|
|
37
37
|
import"./index-n6fa2hhk.js";
|
|
38
|
-
import"./index-
|
|
38
|
+
import"./index-q4kgsvdd.js";
|
|
39
|
+
import"./index-ye3fndsw.js";
|
|
39
40
|
import"./index-kzj3fp7c.js";
|
|
40
41
|
import"./index-5e4e2hvv.js";
|
|
41
42
|
import"./index-p0arc26j.js";
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
createCuratorLLMDelegate
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-mr3pnc4h.js";
|
|
5
5
|
import"./index-nprawcc0.js";
|
|
6
6
|
import"./index-g2wrs7jy.js";
|
|
7
7
|
import"./index-c8s9a3zh.js";
|
|
8
8
|
import"./index-11q1t6g0.js";
|
|
9
9
|
import"./index-pdk1n8yh.js";
|
|
10
|
-
import"./index-
|
|
11
|
-
import"./index-
|
|
10
|
+
import"./index-p45sshb5.js";
|
|
11
|
+
import"./index-vwvkpg0d.js";
|
|
12
12
|
import"./index-4905hd2m.js";
|
|
13
13
|
import"./index-5bcrp3bc.js";
|
|
14
|
-
import"./index-
|
|
14
|
+
import"./index-r2ysfdet.js";
|
|
15
15
|
import"./index-pjhfe7c3.js";
|
|
16
16
|
import"./index-jbdgpqpj.js";
|
|
17
17
|
import"./index-5hze8ztj.js";
|
|
@@ -22,7 +22,8 @@ import"./index-vxv732ex.js";
|
|
|
22
22
|
import"./index-8fwhhayc.js";
|
|
23
23
|
import"./index-q1exe2b3.js";
|
|
24
24
|
import"./index-n6fa2hhk.js";
|
|
25
|
-
import"./index-
|
|
25
|
+
import"./index-q4kgsvdd.js";
|
|
26
|
+
import"./index-ye3fndsw.js";
|
|
26
27
|
import"./index-kzj3fp7c.js";
|
|
27
28
|
import"./index-5e4e2hvv.js";
|
|
28
29
|
import"./index-p0arc26j.js";
|
package/dist/cli/{evidence-summary-service-bwt6drb3.js → evidence-summary-service-cy3k37je.js}
RENAMED
|
@@ -6,9 +6,10 @@ import {
|
|
|
6
6
|
loadPlanJsonOnly,
|
|
7
7
|
mergeDurableGateEntriesFromEvidence,
|
|
8
8
|
readDurableGateEvidence
|
|
9
|
-
} from "./index-
|
|
10
|
-
import"./index-
|
|
9
|
+
} from "./index-p45sshb5.js";
|
|
10
|
+
import"./index-vwvkpg0d.js";
|
|
11
11
|
import"./index-q1exe2b3.js";
|
|
12
|
+
import"./index-ye3fndsw.js";
|
|
12
13
|
import"./index-kzj3fp7c.js";
|
|
13
14
|
import"./index-5e4e2hvv.js";
|
|
14
15
|
import"./index-p0arc26j.js";
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
handleGuardrailExplain
|
|
4
|
-
} from "./index-
|
|
5
|
-
import"./index-
|
|
4
|
+
} from "./index-7pspktns.js";
|
|
5
|
+
import"./index-mr3pnc4h.js";
|
|
6
6
|
import"./index-nprawcc0.js";
|
|
7
7
|
import"./index-g2wrs7jy.js";
|
|
8
8
|
import"./index-c8s9a3zh.js";
|
|
9
9
|
import"./index-11q1t6g0.js";
|
|
10
10
|
import"./index-pdk1n8yh.js";
|
|
11
|
-
import"./index-
|
|
12
|
-
import"./index-
|
|
11
|
+
import"./index-p45sshb5.js";
|
|
12
|
+
import"./index-vwvkpg0d.js";
|
|
13
13
|
import"./index-4905hd2m.js";
|
|
14
14
|
import"./index-5bcrp3bc.js";
|
|
15
|
-
import"./index-
|
|
15
|
+
import"./index-r2ysfdet.js";
|
|
16
16
|
import"./index-pjhfe7c3.js";
|
|
17
17
|
import"./index-jbdgpqpj.js";
|
|
18
18
|
import"./index-5hze8ztj.js";
|
|
@@ -23,7 +23,8 @@ import"./index-vxv732ex.js";
|
|
|
23
23
|
import"./index-8fwhhayc.js";
|
|
24
24
|
import"./index-q1exe2b3.js";
|
|
25
25
|
import"./index-n6fa2hhk.js";
|
|
26
|
-
import"./index-
|
|
26
|
+
import"./index-q4kgsvdd.js";
|
|
27
|
+
import"./index-ye3fndsw.js";
|
|
27
28
|
import"./index-kzj3fp7c.js";
|
|
28
29
|
import"./index-5e4e2hvv.js";
|
|
29
30
|
import"./index-p0arc26j.js";
|
|
@@ -7,17 +7,17 @@ import {
|
|
|
7
7
|
isHiveEligible,
|
|
8
8
|
promoteFromSwarm,
|
|
9
9
|
promoteToHive
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-mr3pnc4h.js";
|
|
11
11
|
import"./index-nprawcc0.js";
|
|
12
12
|
import"./index-g2wrs7jy.js";
|
|
13
13
|
import"./index-c8s9a3zh.js";
|
|
14
14
|
import"./index-11q1t6g0.js";
|
|
15
15
|
import"./index-pdk1n8yh.js";
|
|
16
|
-
import"./index-
|
|
17
|
-
import"./index-
|
|
16
|
+
import"./index-p45sshb5.js";
|
|
17
|
+
import"./index-vwvkpg0d.js";
|
|
18
18
|
import"./index-4905hd2m.js";
|
|
19
19
|
import"./index-5bcrp3bc.js";
|
|
20
|
-
import"./index-
|
|
20
|
+
import"./index-r2ysfdet.js";
|
|
21
21
|
import"./index-pjhfe7c3.js";
|
|
22
22
|
import"./index-jbdgpqpj.js";
|
|
23
23
|
import"./index-5hze8ztj.js";
|
|
@@ -30,7 +30,8 @@ import"./index-vxv732ex.js";
|
|
|
30
30
|
import"./index-8fwhhayc.js";
|
|
31
31
|
import"./index-q1exe2b3.js";
|
|
32
32
|
import"./index-n6fa2hhk.js";
|
|
33
|
-
import"./index-
|
|
33
|
+
import"./index-q4kgsvdd.js";
|
|
34
|
+
import"./index-ye3fndsw.js";
|
|
34
35
|
import"./index-kzj3fp7c.js";
|
|
35
36
|
import"./index-5e4e2hvv.js";
|
|
36
37
|
import"./index-p0arc26j.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
handleGuardrailExplain
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-7pspktns.js";
|
|
5
5
|
import {
|
|
6
6
|
handleGuardrailLog
|
|
7
7
|
} from "./index-bcg89pt8.js";
|
|
@@ -83,7 +83,7 @@ import {
|
|
|
83
83
|
handleWriteRetroCommand,
|
|
84
84
|
normalizeSwarmCommandInput,
|
|
85
85
|
resolveCommand
|
|
86
|
-
} from "./index-
|
|
86
|
+
} from "./index-mr3pnc4h.js";
|
|
87
87
|
import"./index-nprawcc0.js";
|
|
88
88
|
import"./index-g2wrs7jy.js";
|
|
89
89
|
import"./index-c8s9a3zh.js";
|
|
@@ -93,11 +93,11 @@ import {
|
|
|
93
93
|
ORCHESTRATOR_NAME,
|
|
94
94
|
stripKnownSwarmPrefix
|
|
95
95
|
} from "./index-pdk1n8yh.js";
|
|
96
|
-
import"./index-
|
|
97
|
-
import"./index-
|
|
96
|
+
import"./index-p45sshb5.js";
|
|
97
|
+
import"./index-vwvkpg0d.js";
|
|
98
98
|
import"./index-4905hd2m.js";
|
|
99
99
|
import"./index-5bcrp3bc.js";
|
|
100
|
-
import"./index-
|
|
100
|
+
import"./index-r2ysfdet.js";
|
|
101
101
|
import"./index-pjhfe7c3.js";
|
|
102
102
|
import"./index-jbdgpqpj.js";
|
|
103
103
|
import"./index-5hze8ztj.js";
|
|
@@ -108,7 +108,8 @@ import"./index-vxv732ex.js";
|
|
|
108
108
|
import"./index-8fwhhayc.js";
|
|
109
109
|
import"./index-q1exe2b3.js";
|
|
110
110
|
import"./index-n6fa2hhk.js";
|
|
111
|
-
import"./index-
|
|
111
|
+
import"./index-q4kgsvdd.js";
|
|
112
|
+
import"./index-ye3fndsw.js";
|
|
112
113
|
import"./index-kzj3fp7c.js";
|
|
113
114
|
import"./index-5e4e2hvv.js";
|
|
114
115
|
import"./index-p0arc26j.js";
|
|
@@ -93,7 +93,7 @@ import {
|
|
|
93
93
|
saveTaskSetSnapshot,
|
|
94
94
|
transientBackoff,
|
|
95
95
|
validateProjectRoot
|
|
96
|
-
} from "./index-
|
|
96
|
+
} from "./index-p45sshb5.js";
|
|
97
97
|
import {
|
|
98
98
|
buildOpenSpecProjectionSync,
|
|
99
99
|
detectSpeckit,
|
|
@@ -102,7 +102,7 @@ import {
|
|
|
102
102
|
resolveSpeckitProjection,
|
|
103
103
|
validateSpeckit,
|
|
104
104
|
writeProjectedSpecSync
|
|
105
|
-
} from "./index-
|
|
105
|
+
} from "./index-vwvkpg0d.js";
|
|
106
106
|
import {
|
|
107
107
|
withTimeout
|
|
108
108
|
} from "./index-4905hd2m.js";
|
|
@@ -116,7 +116,6 @@ import {
|
|
|
116
116
|
BUNDLED_PROJECT_SKILL_ROOT,
|
|
117
117
|
DEFAULT_SKILL_MIN_CONFIDENCE,
|
|
118
118
|
DEFAULT_SKILL_MIN_CONFIRMATIONS,
|
|
119
|
-
advisoryWarn,
|
|
120
119
|
appendRejectedSkillEdit,
|
|
121
120
|
appendSkillChangelog,
|
|
122
121
|
autoApplyProposals,
|
|
@@ -125,7 +124,6 @@ import {
|
|
|
125
124
|
findSkillsBySourceKnowledgeId,
|
|
126
125
|
findStaleSkillsBySourceKnowledgeId,
|
|
127
126
|
generateSkills,
|
|
128
|
-
getDeferredWarnings,
|
|
129
127
|
listSkills,
|
|
130
128
|
parseDraftFrontmatter,
|
|
131
129
|
regenerateSkill,
|
|
@@ -133,7 +131,7 @@ import {
|
|
|
133
131
|
retireSkill,
|
|
134
132
|
selectCandidateEntries,
|
|
135
133
|
syncBundledProjectSkillsIfMissingAsync
|
|
136
|
-
} from "./index-
|
|
134
|
+
} from "./index-r2ysfdet.js";
|
|
137
135
|
import {
|
|
138
136
|
appendUnactionable,
|
|
139
137
|
quarantineEntry,
|
|
@@ -214,6 +212,10 @@ import {
|
|
|
214
212
|
import {
|
|
215
213
|
clearAllScopes
|
|
216
214
|
} from "./index-n6fa2hhk.js";
|
|
215
|
+
import {
|
|
216
|
+
advisoryWarn,
|
|
217
|
+
getDeferredWarnings
|
|
218
|
+
} from "./index-ye3fndsw.js";
|
|
217
219
|
import {
|
|
218
220
|
readSwarmFileAsync,
|
|
219
221
|
safeHook,
|
|
@@ -602,7 +604,7 @@ async function startupOrphanRecovery(directory, activeSessionIds = []) {
|
|
|
602
604
|
}
|
|
603
605
|
}
|
|
604
606
|
for (const warning of warnings) {
|
|
605
|
-
|
|
607
|
+
log(warning);
|
|
606
608
|
}
|
|
607
609
|
return {
|
|
608
610
|
prunedWorktrees: pruneResult.exitCode === 0,
|
|
@@ -5110,12 +5112,16 @@ function loadPluginConfigWithMeta(directory) {
|
|
|
5110
5112
|
const config = loadPluginConfig(directory);
|
|
5111
5113
|
return { config, loadedFromFile, configHadErrors };
|
|
5112
5114
|
}
|
|
5115
|
+
// src/agents/index.ts
|
|
5116
|
+
init_logger();
|
|
5117
|
+
|
|
5113
5118
|
// src/commands/registry.ts
|
|
5114
5119
|
init_logger();
|
|
5115
5120
|
|
|
5116
5121
|
// src/commands/acknowledge-spec-drift.ts
|
|
5117
5122
|
import { promises as fsPromises } from "fs";
|
|
5118
5123
|
import * as path8 from "path";
|
|
5124
|
+
init_logger();
|
|
5119
5125
|
async function handleAcknowledgeSpecDriftCommand(directory, _args, acknowledgedBy = "unknown") {
|
|
5120
5126
|
const specStalenessPath = validateSwarmPath(directory, "spec-staleness.json");
|
|
5121
5127
|
let stalenessContent;
|
|
@@ -5158,7 +5164,7 @@ Please re-run the relevant phase to detect current drift status.`;
|
|
|
5158
5164
|
} catch {}
|
|
5159
5165
|
}
|
|
5160
5166
|
} catch (planError) {
|
|
5161
|
-
|
|
5167
|
+
log("[acknowledge-spec-drift] Failed to update plan specHash:", planError instanceof Error ? planError.message : String(planError));
|
|
5162
5168
|
planUpdateSkipped = true;
|
|
5163
5169
|
}
|
|
5164
5170
|
if (!planUpdateSkipped) {
|
|
@@ -5179,7 +5185,7 @@ Please re-run the relevant phase to detect current drift status.`;
|
|
|
5179
5185
|
await fsPromises.appendFile(eventsPath, `${JSON.stringify(acknowledgmentEvent)}
|
|
5180
5186
|
`, "utf-8");
|
|
5181
5187
|
} catch (appendError) {
|
|
5182
|
-
|
|
5188
|
+
log("[acknowledge-spec-drift] Failed to write acknowledgment event:", appendError instanceof Error ? appendError.message : String(appendError));
|
|
5183
5189
|
eventWriteFailed = true;
|
|
5184
5190
|
}
|
|
5185
5191
|
const warnings = [];
|
|
@@ -7372,6 +7378,7 @@ var _internals10 = {
|
|
|
7372
7378
|
};
|
|
7373
7379
|
|
|
7374
7380
|
// src/commands/ci-simulate.ts
|
|
7381
|
+
init_logger();
|
|
7375
7382
|
var GIT_TIMEOUT_MS2 = 30000;
|
|
7376
7383
|
var VALIDATION_TIMEOUT_MS = 5 * 60 * 1000;
|
|
7377
7384
|
var OUTPUT_LIMIT_BYTES = 12000;
|
|
@@ -7455,7 +7462,7 @@ async function cleanupWorktree(worktreePath, projectRoot) {
|
|
|
7455
7462
|
}
|
|
7456
7463
|
} catch {}
|
|
7457
7464
|
if (removeResult.exitCode !== 0) {
|
|
7458
|
-
|
|
7465
|
+
log(`[ci-simulate] git worktree remove failed: ${removeResult.stderr.trim() || removeResult.stdout.trim()}`);
|
|
7459
7466
|
}
|
|
7460
7467
|
}
|
|
7461
7468
|
async function runValidationSuite(worktreePath) {
|
|
@@ -9995,7 +10002,7 @@ async function runCuratorPhase(directory, phase, agentsDispatched, config, knowl
|
|
|
9995
10002
|
}
|
|
9996
10003
|
if (config.skill_generation_enabled === true && skillCandidates.length > 0) {
|
|
9997
10004
|
try {
|
|
9998
|
-
const skillModule = await import("./skill-generator-
|
|
10005
|
+
const skillModule = await import("./skill-generator-3f8dqjj2.js");
|
|
9999
10006
|
for (const cand of skillCandidates) {
|
|
10000
10007
|
if (cand.confidence < (config.min_skill_confidence ?? DEFAULT_SKILL_MIN_CONFIDENCE)) {
|
|
10001
10008
|
continue;
|
|
@@ -11237,11 +11244,11 @@ var _internals15 = {
|
|
|
11237
11244
|
return KnowledgeConfigSchema2.parse({});
|
|
11238
11245
|
},
|
|
11239
11246
|
applyCuratorKnowledgeUpdates: async (directory, recommendations, knowledgeConfig) => {
|
|
11240
|
-
const { applyCuratorKnowledgeUpdates: applyCuratorKnowledgeUpdates2 } = await import("./curator-
|
|
11247
|
+
const { applyCuratorKnowledgeUpdates: applyCuratorKnowledgeUpdates2 } = await import("./curator-5xfkejsq.js");
|
|
11241
11248
|
return applyCuratorKnowledgeUpdates2(directory, recommendations, knowledgeConfig);
|
|
11242
11249
|
},
|
|
11243
11250
|
checkHivePromotions: async (entries, knowledgeConfig, directory) => {
|
|
11244
|
-
const { checkHivePromotions } = await import("./hive-promoter-
|
|
11251
|
+
const { checkHivePromotions } = await import("./hive-promoter-03m8pwg6.js");
|
|
11245
11252
|
return checkHivePromotions(entries, knowledgeConfig, directory);
|
|
11246
11253
|
},
|
|
11247
11254
|
applyProposalTriage: async (directory, triage) => {
|
|
@@ -11250,7 +11257,7 @@ var _internals15 = {
|
|
|
11250
11257
|
activateProposal,
|
|
11251
11258
|
listSkills: listSkills2,
|
|
11252
11259
|
sanitizeSlug
|
|
11253
|
-
} = await import("./skill-generator-
|
|
11260
|
+
} = await import("./skill-generator-3f8dqjj2.js");
|
|
11254
11261
|
const result = {
|
|
11255
11262
|
approved: [],
|
|
11256
11263
|
rejected: [],
|
|
@@ -11292,7 +11299,7 @@ var _internals15 = {
|
|
|
11292
11299
|
return result;
|
|
11293
11300
|
},
|
|
11294
11301
|
readPriorDriftReports: async (directory) => {
|
|
11295
|
-
const { readPriorDriftReports } = await import("./curator-drift-
|
|
11302
|
+
const { readPriorDriftReports } = await import("./curator-drift-nn71xfz6.js");
|
|
11296
11303
|
return readPriorDriftReports(directory);
|
|
11297
11304
|
},
|
|
11298
11305
|
readSwarmKnowledge: (directory) => readKnowledge(resolveSwarmKnowledgePath(directory))
|
|
@@ -14057,19 +14064,19 @@ var ENRICHMENT_ALLOWED_FIELDS = [
|
|
|
14057
14064
|
function buildV3EnrichmentPrompt(lesson, category, tags) {
|
|
14058
14065
|
return [
|
|
14059
14066
|
"Convert this prose lesson into an actionable knowledge directive.",
|
|
14060
|
-
"Output ONLY a single JSON object \
|
|
14067
|
+
"Output ONLY a single JSON object \xE2\u20AC\u201D no code fences, no commentary.",
|
|
14061
14068
|
"",
|
|
14062
14069
|
"MANDATORY fields (the directive is rejected without them):",
|
|
14063
14070
|
"- At least ONE scope field non-empty:",
|
|
14064
|
-
' "applies_to_agents": string[] \
|
|
14065
|
-
' "applies_to_tools": string[] \
|
|
14071
|
+
' "applies_to_agents": string[] \xE2\u20AC\u201D roles from: architect, coder, reviewer, test_engineer, sme, docs, designer, critic, curator',
|
|
14072
|
+
' "applies_to_tools": string[] \xE2\u20AC\u201D tool names from: edit, write, patch, bash, read, grep, glob',
|
|
14066
14073
|
"- At least ONE predicate field non-empty:",
|
|
14067
|
-
' "forbidden_actions": string[] \
|
|
14068
|
-
' "required_actions": string[] \
|
|
14069
|
-
' "verification_checks": string[] \
|
|
14074
|
+
' "forbidden_actions": string[] \xE2\u20AC\u201D concrete actions to never take',
|
|
14075
|
+
' "required_actions": string[] \xE2\u20AC\u201D concrete actions to always take',
|
|
14076
|
+
' "verification_checks": string[] \xE2\u20AC\u201D checks a reviewer can run',
|
|
14070
14077
|
"",
|
|
14071
14078
|
"OPTIONAL fields:",
|
|
14072
|
-
' "triggers": string[] \
|
|
14079
|
+
' "triggers": string[] \xE2\u20AC\u201D short phrases that should surface this lesson',
|
|
14073
14080
|
' "directive_priority": "low" | "medium" | "high" | "critical"',
|
|
14074
14081
|
"",
|
|
14075
14082
|
"Example output:",
|
|
@@ -14094,8 +14101,8 @@ function buildV3BatchEnrichmentPrompt(lessons) {
|
|
|
14094
14101
|
"",
|
|
14095
14102
|
"For EACH element, mandatory requirements:",
|
|
14096
14103
|
"- At least ONE scope field non-empty:",
|
|
14097
|
-
' "applies_to_agents": string[] \
|
|
14098
|
-
' "applies_to_tools": string[] \
|
|
14104
|
+
' "applies_to_agents": string[] \xE2\u20AC\u201D roles from: architect, coder, reviewer, test_engineer, sme, docs, designer, critic, curator',
|
|
14105
|
+
' "applies_to_tools": string[] \xE2\u20AC\u201D tool names from: edit, write, patch, bash, read, grep, glob',
|
|
14099
14106
|
"- At least ONE predicate field non-empty:",
|
|
14100
14107
|
' "forbidden_actions": string[] | "required_actions": string[] | "verification_checks": string[]',
|
|
14101
14108
|
"",
|
|
@@ -16544,6 +16551,7 @@ var _internals24 = {
|
|
|
16544
16551
|
};
|
|
16545
16552
|
|
|
16546
16553
|
// src/commands/close.ts
|
|
16554
|
+
init_logger();
|
|
16547
16555
|
var CLOSE_SKILL_REVIEW_TIMEOUT_MS = 120000;
|
|
16548
16556
|
var CLOSE_REFLECTION_TIMEOUT_MS = 90000;
|
|
16549
16557
|
async function runAbortableReflection(input, timeoutMs) {
|
|
@@ -16854,7 +16862,7 @@ async function runFinalizeStage(ctx) {
|
|
|
16854
16862
|
} catch (error2) {
|
|
16855
16863
|
const msg = error2 instanceof Error ? error2.message : String(error2);
|
|
16856
16864
|
ctx.warnings.push(`Lessons curation failed: ${msg}`);
|
|
16857
|
-
|
|
16865
|
+
log("[close-command] curateAndStoreSwarm error:", error2);
|
|
16858
16866
|
}
|
|
16859
16867
|
if (ctx.curationSucceeded && ctx.allLessons.length > 0) {
|
|
16860
16868
|
await fs12.unlink(lessonsFilePath).catch(() => {});
|
|
@@ -16955,7 +16963,7 @@ async function runFinalizeStage(ctx) {
|
|
|
16955
16963
|
} catch (error2) {
|
|
16956
16964
|
const msg = error2 instanceof Error ? error2.message : String(error2);
|
|
16957
16965
|
ctx.warnings.push(`Failed to persist terminal plan state: ${msg}`);
|
|
16958
|
-
|
|
16966
|
+
log("[close-command] Failed to write terminal plan state:", error2);
|
|
16959
16967
|
ctx.planData = planDataSnapshot;
|
|
16960
16968
|
ctx.closedPhases.length = closedPhasesLenBefore;
|
|
16961
16969
|
ctx.closedTasks.length = closedTasksLenBefore;
|
|
@@ -17175,7 +17183,7 @@ async function runArchiveEvidenceRetention(ctx) {
|
|
|
17175
17183
|
} catch (error2) {
|
|
17176
17184
|
const msg = error2 instanceof Error ? error2.message : String(error2);
|
|
17177
17185
|
ctx.warnings.push(`Evidence retention archive failed: ${msg}`);
|
|
17178
|
-
|
|
17186
|
+
log("[close-command] archiveEvidence error:", error2);
|
|
17179
17187
|
}
|
|
17180
17188
|
}
|
|
17181
17189
|
async function runCleanStage(ctx) {
|
|
@@ -17361,7 +17369,7 @@ async function runCleanStage(ctx) {
|
|
|
17361
17369
|
} catch {}
|
|
17362
17370
|
const msg = error2 instanceof Error ? error2.message : String(error2);
|
|
17363
17371
|
ctx.warnings.push(`Failed to reset context.md: ${msg}`);
|
|
17364
|
-
|
|
17372
|
+
log("[close-command] Failed to write context.md:", error2);
|
|
17365
17373
|
}
|
|
17366
17374
|
return {
|
|
17367
17375
|
cleanedFiles,
|
|
@@ -17653,7 +17661,7 @@ This project was already finalized in a previous /swarm close run. The plan has
|
|
|
17653
17661
|
} catch {}
|
|
17654
17662
|
const msg = error2 instanceof Error ? error2.message : String(error2);
|
|
17655
17663
|
ctx.warnings.push(`Failed to write close-summary.md: ${msg}`);
|
|
17656
|
-
|
|
17664
|
+
log("[close-command] Failed to write close-summary.md:", error2);
|
|
17657
17665
|
}
|
|
17658
17666
|
try {
|
|
17659
17667
|
const sessionIdsToEnd = [...swarmState.agentSessions.keys()];
|
|
@@ -17664,7 +17672,7 @@ This project was already finalized in a previous /swarm close run. The plan has
|
|
|
17664
17672
|
} catch (teardownError) {
|
|
17665
17673
|
const msg = teardownError instanceof Error ? teardownError.message : String(teardownError);
|
|
17666
17674
|
ctx.warnings.push(`Session teardown encountered an error after finalization completed (state may not be fully reset): ${msg}`);
|
|
17667
|
-
|
|
17675
|
+
log("[close-command] teardown error:", teardownError);
|
|
17668
17676
|
}
|
|
17669
17677
|
const retroWarnings = ctx.warnings.filter((w) => w.includes("Retrospective write") || w.includes("retrospective write") || w.includes("Session retrospective"));
|
|
17670
17678
|
const otherWarnings = ctx.warnings.filter((w) => !w.includes("Retrospective write") && !w.includes("retrospective write") && !w.includes("Session retrospective"));
|
|
@@ -19115,8 +19123,8 @@ var _internals29 = {
|
|
|
19115
19123
|
loadCuratorDeps: async () => {
|
|
19116
19124
|
const [{ CuratorConfigSchema }, curator, { createCuratorLLMDelegate: createCuratorLLMDelegate2 }] = await Promise.all([
|
|
19117
19125
|
import("./schema-7c484wjz.js"),
|
|
19118
|
-
import("./curator-
|
|
19119
|
-
import("./curator-llm-factory-
|
|
19126
|
+
import("./curator-5xfkejsq.js"),
|
|
19127
|
+
import("./curator-llm-factory-rwwnmdvk.js")
|
|
19120
19128
|
]);
|
|
19121
19129
|
return { CuratorConfigSchema, curator, createCuratorLLMDelegate: createCuratorLLMDelegate2 };
|
|
19122
19130
|
}
|
|
@@ -19209,6 +19217,7 @@ function formatCurationSummary(summary) {
|
|
|
19209
19217
|
|
|
19210
19218
|
// src/commands/dark-matter.ts
|
|
19211
19219
|
import path38 from "path";
|
|
19220
|
+
init_logger();
|
|
19212
19221
|
async function handleDarkMatterCommand(directory, args) {
|
|
19213
19222
|
const options = {};
|
|
19214
19223
|
for (let i = 0;i < args.length; i++) {
|
|
@@ -19252,7 +19261,7 @@ Ensure this is a git repository with commit history.`;
|
|
|
19252
19261
|
[${entries.length} dark matter finding(s) saved to .swarm/knowledge.jsonl]`;
|
|
19253
19262
|
}
|
|
19254
19263
|
} catch (err) {
|
|
19255
|
-
|
|
19264
|
+
log("dark-matter: failed to save knowledge entries:", err);
|
|
19256
19265
|
return output;
|
|
19257
19266
|
}
|
|
19258
19267
|
}
|
|
@@ -19491,6 +19500,7 @@ ${USAGE5}`;
|
|
|
19491
19500
|
}
|
|
19492
19501
|
|
|
19493
19502
|
// src/commands/design-docs.ts
|
|
19503
|
+
init_logger();
|
|
19494
19504
|
var MAX_DESC_LEN = 2000;
|
|
19495
19505
|
var USAGE6 = `Usage: /swarm design-docs <description> [--out <dir>] [--lang <name>] [--update]
|
|
19496
19506
|
|
|
@@ -19594,7 +19604,7 @@ ${USAGE6}`;
|
|
|
19594
19604
|
` + USAGE6;
|
|
19595
19605
|
}
|
|
19596
19606
|
} catch (configErr) {
|
|
19597
|
-
|
|
19607
|
+
log(`[design-docs] Could not read opencode-swarm.json (${String(configErr)}). ` + "Falling through \u2014 the architect will abort if docs_design is not registered.");
|
|
19598
19608
|
}
|
|
19599
19609
|
const description = sanitizeDescription(parsed.rest.join(" "));
|
|
19600
19610
|
if (!description && !parsed.update) {
|
|
@@ -19612,7 +19622,7 @@ import { fileURLToPath } from "url";
|
|
|
19612
19622
|
// package.json
|
|
19613
19623
|
var package_default = {
|
|
19614
19624
|
name: "opencode-swarm",
|
|
19615
|
-
version: "7.
|
|
19625
|
+
version: "7.119.0",
|
|
19616
19626
|
description: "Architect-centric agentic swarm plugin for OpenCode - hub-and-spoke orchestration with SME consultation, code generation, and QA review",
|
|
19617
19627
|
main: "dist/index.js",
|
|
19618
19628
|
types: "dist/index.d.ts",
|
|
@@ -21972,7 +21982,7 @@ async function handleEvidenceCommand(directory, args) {
|
|
|
21972
21982
|
return formatTaskEvidenceMarkdown(evidenceData);
|
|
21973
21983
|
}
|
|
21974
21984
|
async function handleEvidenceSummaryCommand(directory) {
|
|
21975
|
-
const { buildEvidenceSummary } = await import("./evidence-summary-service-
|
|
21985
|
+
const { buildEvidenceSummary } = await import("./evidence-summary-service-cy3k37je.js");
|
|
21976
21986
|
const artifact = await buildEvidenceSummary(directory);
|
|
21977
21987
|
if (!artifact) {
|
|
21978
21988
|
return "No plan found. Run `/swarm plan` to check plan status.";
|
|
@@ -28279,6 +28289,7 @@ function resolveLegacyHiveKnowledgePath() {
|
|
|
28279
28289
|
}
|
|
28280
28290
|
|
|
28281
28291
|
// src/commands/knowledge.ts
|
|
28292
|
+
init_logger();
|
|
28282
28293
|
function resolveEntryByPrefix(entries, inputId) {
|
|
28283
28294
|
const exact = entries.find((e) => e.id === inputId);
|
|
28284
28295
|
if (exact)
|
|
@@ -28316,7 +28327,7 @@ async function handleKnowledgeQuarantineCommand(directory, args) {
|
|
|
28316
28327
|
await quarantineEntry(directory, fullId, reason, "user");
|
|
28317
28328
|
return `\u2705 Entry ${fullId} quarantined successfully.`;
|
|
28318
28329
|
} catch (error2) {
|
|
28319
|
-
|
|
28330
|
+
log("[knowledge-command] quarantineEntry error:", error2 instanceof Error ? error2.message : String(error2));
|
|
28320
28331
|
return `\u274C Failed to quarantine entry. Check the entry ID and try again.`;
|
|
28321
28332
|
}
|
|
28322
28333
|
}
|
|
@@ -28352,7 +28363,7 @@ async function handleKnowledgeRestoreCommand(directory, args) {
|
|
|
28352
28363
|
await restoreEntry(directory, fullId);
|
|
28353
28364
|
return `\u2705 Entry ${fullId} restored successfully.`;
|
|
28354
28365
|
} catch (error2) {
|
|
28355
|
-
|
|
28366
|
+
log("[knowledge-command] restoreEntry error:", error2 instanceof Error ? error2.message : String(error2));
|
|
28356
28367
|
return `\u274C Failed to restore entry. Check the entry ID and try again.`;
|
|
28357
28368
|
}
|
|
28358
28369
|
}
|
|
@@ -28393,7 +28404,7 @@ async function handleKnowledgeMigrateCommand(directory, args) {
|
|
|
28393
28404
|
return messages.join(`
|
|
28394
28405
|
`);
|
|
28395
28406
|
} catch (error2) {
|
|
28396
|
-
|
|
28407
|
+
log("[knowledge-command] migration error:", error2 instanceof Error ? error2.message : String(error2));
|
|
28397
28408
|
return "\u274C Migration failed. Check that knowledge source files are readable.";
|
|
28398
28409
|
}
|
|
28399
28410
|
}
|
|
@@ -28420,7 +28431,7 @@ async function handleKnowledgeListCommand(directory, _args) {
|
|
|
28420
28431
|
return lines.join(`
|
|
28421
28432
|
`);
|
|
28422
28433
|
} catch (error2) {
|
|
28423
|
-
|
|
28434
|
+
log("[knowledge-command] list error:", error2 instanceof Error ? error2.message : String(error2));
|
|
28424
28435
|
return "\u274C Failed to list knowledge entries. Ensure .swarm/knowledge.jsonl exists.";
|
|
28425
28436
|
}
|
|
28426
28437
|
}
|
|
@@ -28456,7 +28467,7 @@ async function handleKnowledgeUnactionableCommand(directory, _args) {
|
|
|
28456
28467
|
return lines.join(`
|
|
28457
28468
|
`);
|
|
28458
28469
|
} catch (error2) {
|
|
28459
|
-
|
|
28470
|
+
log("[knowledge-command] unactionable list error:", error2 instanceof Error ? error2.message : String(error2));
|
|
28460
28471
|
return "Failed to list unactionable entries.";
|
|
28461
28472
|
}
|
|
28462
28473
|
}
|
|
@@ -28497,7 +28508,7 @@ async function handleKnowledgeRetryHardeningCommand(directory, args) {
|
|
|
28497
28508
|
}
|
|
28498
28509
|
return `Reset ${resetCount} retire candidate(s). They will be re-processed on the next scheduled hardening pass.`;
|
|
28499
28510
|
} catch (error2) {
|
|
28500
|
-
|
|
28511
|
+
log("[knowledge-command] retry-hardening error:", error2 instanceof Error ? error2.message : String(error2));
|
|
28501
28512
|
return "Failed to reset retire candidates.";
|
|
28502
28513
|
}
|
|
28503
28514
|
}
|
|
@@ -37317,6 +37328,7 @@ ${error2 instanceof Error ? error2.message : String(error2)}`;
|
|
|
37317
37328
|
// src/commands/rollback.ts
|
|
37318
37329
|
import * as fs38 from "fs";
|
|
37319
37330
|
import * as path74 from "path";
|
|
37331
|
+
init_logger();
|
|
37320
37332
|
function safeParseToolJson(result) {
|
|
37321
37333
|
try {
|
|
37322
37334
|
const jsonStr = typeof result === "string" ? result : result.output;
|
|
@@ -37382,7 +37394,7 @@ async function restoreGitCheckpoint(directory, selected) {
|
|
|
37382
37394
|
fs38.appendFileSync(eventsPath, `${JSON.stringify(rollbackEvent)}
|
|
37383
37395
|
`);
|
|
37384
37396
|
} catch (error2) {
|
|
37385
|
-
|
|
37397
|
+
log("Failed to write rollback event:", error2 instanceof Error ? error2.message : String(error2));
|
|
37386
37398
|
}
|
|
37387
37399
|
return `Rolled back to checkpoint "${selected.label}" (${selected.sha.slice(0, 12)})`;
|
|
37388
37400
|
}
|
|
@@ -37537,7 +37549,7 @@ async function handleRollbackCommand(directory, args) {
|
|
|
37537
37549
|
fs38.appendFileSync(eventsPath, `${JSON.stringify(rollbackEvent)}
|
|
37538
37550
|
`);
|
|
37539
37551
|
} catch (error2) {
|
|
37540
|
-
|
|
37552
|
+
log("Failed to write rollback event:", error2 instanceof Error ? error2.message : String(error2));
|
|
37541
37553
|
}
|
|
37542
37554
|
if (warnings.length > 0) {
|
|
37543
37555
|
return [
|
|
@@ -39180,7 +39192,7 @@ function buildDetailedHelp(commandName, entry) {
|
|
|
39180
39192
|
async function handleHelpCommand(ctx) {
|
|
39181
39193
|
const targetCommand = ctx.args.join(" ");
|
|
39182
39194
|
if (!targetCommand) {
|
|
39183
|
-
const { buildHelpText } = await import("./index-
|
|
39195
|
+
const { buildHelpText } = await import("./index-05ee8pws.js");
|
|
39184
39196
|
return buildHelpText();
|
|
39185
39197
|
}
|
|
39186
39198
|
const tokens = targetCommand.split(/\s+/);
|
|
@@ -39189,7 +39201,7 @@ async function handleHelpCommand(ctx) {
|
|
|
39189
39201
|
return _internals61.buildDetailedHelp(resolved.key, resolved.entry);
|
|
39190
39202
|
}
|
|
39191
39203
|
const similar = _internals61.findSimilarCommands(targetCommand);
|
|
39192
|
-
const { buildHelpText: fullHelp } = await import("./index-
|
|
39204
|
+
const { buildHelpText: fullHelp } = await import("./index-05ee8pws.js");
|
|
39193
39205
|
if (similar.length > 0) {
|
|
39194
39206
|
return `Command '/swarm ${targetCommand}' not found.
|
|
39195
39207
|
|
|
@@ -39322,7 +39334,7 @@ var COMMAND_REGISTRY = {
|
|
|
39322
39334
|
},
|
|
39323
39335
|
"guardrail explain": {
|
|
39324
39336
|
handler: async (ctx) => {
|
|
39325
|
-
const { handleGuardrailExplain } = await import("./guardrail-explain-
|
|
39337
|
+
const { handleGuardrailExplain } = await import("./guardrail-explain-kacpc2zm.js");
|
|
39326
39338
|
return handleGuardrailExplain(ctx.directory, ctx.args);
|
|
39327
39339
|
},
|
|
39328
39340
|
description: "Dry-run: show what the guardrails would do to a command or write target (executes nothing)",
|
|
@@ -39332,7 +39344,7 @@ var COMMAND_REGISTRY = {
|
|
|
39332
39344
|
},
|
|
39333
39345
|
"guardrail-explain": {
|
|
39334
39346
|
handler: async (ctx) => {
|
|
39335
|
-
const { handleGuardrailExplain } = await import("./guardrail-explain-
|
|
39347
|
+
const { handleGuardrailExplain } = await import("./guardrail-explain-kacpc2zm.js");
|
|
39336
39348
|
return handleGuardrailExplain(ctx.directory, ctx.args);
|
|
39337
39349
|
},
|
|
39338
39350
|
description: "Dry-run: show what the guardrails would do to a command or write target (executes nothing)",
|