opencode-swarm 7.136.0 → 7.136.2
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-feedback/SKILL.md +41 -1
- package/.opencode/skills/swarm-pr-review/SKILL.md +83 -24
- package/README.md +18 -0
- package/dist/background/candidate-contract.d.ts +13 -0
- package/dist/background/workspace-snapshot.d.ts +54 -0
- package/dist/cli/{config-doctor-q0krbxwv.js → config-doctor-b67nb84b.js} +2 -2
- package/dist/cli/{curation-policy-v6ywe8qd.js → curation-policy-kvzhfaj1.js} +2 -2
- package/dist/cli/{curator-llm-factory-mhwje8rf.js → curator-llm-factory-x7kvry9x.js} +17 -14
- package/dist/cli/{curator-tqedvpy1.js → curator-nrmj8bds.js} +17 -14
- package/dist/cli/{evidence-summary-service-w006jnpg.js → evidence-summary-service-cf8sz2bq.js} +3 -1
- package/dist/cli/{guardrail-explain-m0m74hvr.js → guardrail-explain-5kd44rcj.js} +18 -15
- package/dist/cli/{guardrail-log-5g8x6qc6.js → guardrail-log-aksrzqdx.js} +3 -3
- package/dist/cli/hashing-mjwn6j4y.js +34 -0
- package/dist/cli/{hive-promoter-s804newd.js → hive-promoter-cy21rhnd.js} +17 -14
- package/dist/cli/{index-n8j0cnp1.js → index-0755132s.js} +4 -4
- package/dist/cli/{index-1kjg590p.js → index-1kn24ja0.js} +1 -1
- package/dist/cli/{index-j08trvny.js → index-21115szq.js} +5 -5
- package/dist/cli/{index-2cv1j3rf.js → index-37v2wxqe.js} +1 -1
- package/dist/cli/{index-cfz5750k.js → index-7ayaq27q.js} +5 -1
- package/dist/cli/{index-9bk16zkv.js → index-84nz7bhe.js} +1 -1
- package/dist/cli/{index-bwfzq91q.js → index-ad6j0m7k.js} +12 -6
- package/dist/cli/{index-qh9466j3.js → index-azghvnja.js} +2 -2
- package/dist/cli/{index-cxq1t7j1.js → index-ckybsn6p.js} +19 -16
- package/dist/cli/{index-cggqh2dz.js → index-kwwxevne.js} +53 -996
- package/dist/cli/{index-nw9cn84t.js → index-m5fw4mer.js} +19 -2
- package/dist/cli/{index-2w4tsmva.js → index-rw3f73aq.js} +1 -1
- package/dist/cli/{index-wpqypdge.js → index-s0rbdp61.js} +2 -2
- package/dist/cli/{index-bbejqagj.js → index-s0vahtdm.js} +1 -1
- package/dist/cli/{index-81dkzncr.js → index-sr2cynyw.js} +4535 -2325
- package/dist/cli/index-wjm896ey.js +1100 -0
- package/dist/cli/{index-w58bmwyq.js → index-wnz282j3.js} +2 -2
- package/dist/cli/{index-y6a7gjtj.js → index-wsdnttf4.js} +228 -81
- package/dist/cli/{index-m1hew17b.js → index-y0xaq4f3.js} +39 -4
- package/dist/cli/index-y8552snf.js +264 -0
- package/dist/cli/index-z1tm47nj.js +783 -0
- package/dist/cli/index.js +17 -14
- package/dist/cli/{knowledge-escalator-f1m2xp5x.js → knowledge-escalator-ta3xjrdj.js} +3 -3
- package/dist/cli/{knowledge-events-rksgem6f.js → knowledge-events-dk6banmz.js} +1 -1
- package/dist/cli/{knowledge-store-t6d6fr8b.js → knowledge-store-h3jz10bv.js} +1 -1
- package/dist/cli/{knowledge-validator-5ggzb3j1.js → knowledge-validator-jsz1dxkr.js} +4 -4
- package/dist/cli/runner-2v413r74.js +21 -0
- package/dist/cli/{scan-cursor-18fnwr58.js → scan-cursor-48gwzh9c.js} +2 -2
- package/dist/cli/{schema-jw15d8bt.js → schema-f937b9cs.js} +5 -1
- package/dist/cli/{skill-generator-3n5y902z.js → skill-generator-4p10ktw1.js} +5 -5
- package/dist/cli/{workspace-snapshot-jmyamqnv.js → workspace-snapshot-h5rzw37b.js} +5 -1
- package/dist/commands/registry.d.ts +72 -0
- package/dist/commands/skill-opt.d.ts +41 -0
- package/dist/config/schema.d.ts +47 -0
- package/dist/hooks/guardrails/file-authority.d.ts +11 -2
- package/dist/hooks/pr-workflow-gate.d.ts +261 -4
- package/dist/hooks/pr-workflow-response-gate.d.ts +27 -9
- package/dist/hooks/write-target-resolver.d.ts +19 -0
- package/dist/index.js +355 -320
- package/dist/services/skill-evaluator.d.ts +17 -0
- package/dist/services/skill-optimizer/activation.d.ts +58 -0
- package/dist/services/skill-optimizer/candidates.d.ts +88 -0
- package/dist/services/skill-optimizer/controller.d.ts +146 -0
- package/dist/services/skill-optimizer/deterministic-seed.d.ts +29 -0
- package/dist/services/skill-optimizer/lifecycle.d.ts +70 -0
- package/dist/services/skill-optimizer/promoted-external-staleness.d.ts +98 -0
- package/dist/services/skill-optimizer/retirement.d.ts +54 -0
- package/dist/services/skill-optimizer/skill-eval-tasks.d.ts +47 -0
- package/dist/services/skill-optimizer/smoke.d.ts +46 -0
- package/dist/services/skill-optimizer/store.d.ts +118 -0
- package/dist/tools/write-pr-review-trigger-eval.d.ts +2 -1
- package/dist/utils/stable-stringify.d.ts +46 -0
- package/evaluation-fixtures/skill-eval/scoring/score-skill-eval.cjs +97 -0
- package/package.json +1 -1
|
@@ -7,35 +7,38 @@ import {
|
|
|
7
7
|
isHiveEligible,
|
|
8
8
|
promoteFromSwarm,
|
|
9
9
|
promoteToHive
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-sr2cynyw.js";
|
|
11
11
|
import"./index-vm4xw9z3.js";
|
|
12
|
-
import"./index-
|
|
13
|
-
import"./index-
|
|
14
|
-
import"./index-
|
|
12
|
+
import"./index-wjm896ey.js";
|
|
13
|
+
import"./index-m5fw4mer.js";
|
|
14
|
+
import"./index-7ayaq27q.js";
|
|
15
|
+
import"./index-kwwxevne.js";
|
|
16
|
+
import"./index-z1tm47nj.js";
|
|
17
|
+
import"./index-y8552snf.js";
|
|
15
18
|
import"./index-4905hd2m.js";
|
|
16
19
|
import"./index-134d35c1.js";
|
|
17
|
-
import"./index-
|
|
18
|
-
import"./index-
|
|
19
|
-
import"./index-
|
|
20
|
+
import"./index-ad6j0m7k.js";
|
|
21
|
+
import"./index-21115szq.js";
|
|
22
|
+
import"./index-1kn24ja0.js";
|
|
20
23
|
import"./index-6mjf4vr1.js";
|
|
21
24
|
import"./index-c8s9a3zh.js";
|
|
22
25
|
import"./index-9ss2m4rs.js";
|
|
23
|
-
import"./index-
|
|
26
|
+
import"./index-wsdnttf4.js";
|
|
24
27
|
import"./index-mrtms113.js";
|
|
25
|
-
import"./index-
|
|
26
|
-
import"./index-
|
|
28
|
+
import"./index-s0rbdp61.js";
|
|
29
|
+
import"./index-rw3f73aq.js";
|
|
27
30
|
import"./index-rtry5xyf.js";
|
|
28
31
|
import {
|
|
29
32
|
resolveHiveKnowledgePath
|
|
30
|
-
} from "./index-
|
|
31
|
-
import"./index-
|
|
33
|
+
} from "./index-0755132s.js";
|
|
34
|
+
import"./index-84nz7bhe.js";
|
|
32
35
|
import"./index-ae75rja9.js";
|
|
33
36
|
import"./index-dzyjb33e.js";
|
|
34
37
|
import"./index-ey29aap6.js";
|
|
35
|
-
import"./index-
|
|
38
|
+
import"./index-s0vahtdm.js";
|
|
36
39
|
import"./index-k5jrywpr.js";
|
|
37
40
|
import"./index-n832052r.js";
|
|
38
|
-
import"./index-
|
|
41
|
+
import"./index-y0xaq4f3.js";
|
|
39
42
|
import"./index-bk5tah7q.js";
|
|
40
43
|
import"./index-8fwhhayc.js";
|
|
41
44
|
import"./index-q1exe2b3.js";
|
|
@@ -702,7 +702,7 @@ async function applyConfidenceFloorAction(directory, touched, options) {
|
|
|
702
702
|
const recovered = touched.filter((e) => e.confidence > CONFIDENCE_FLOOR + FLOOR_EPSILON && e.confidence_floor_demoted);
|
|
703
703
|
if (atFloor.length === 0 && recovered.length === 0)
|
|
704
704
|
return;
|
|
705
|
-
const { readKnowledgeCounterRollups, effectiveRetrievalOutcomes } = await import("./knowledge-events-
|
|
705
|
+
const { readKnowledgeCounterRollups, effectiveRetrievalOutcomes } = await import("./knowledge-events-dk6banmz.js");
|
|
706
706
|
const rollups = await readKnowledgeCounterRollups(directory);
|
|
707
707
|
const flagIds = new Set;
|
|
708
708
|
for (const e of atFloor) {
|
|
@@ -769,11 +769,11 @@ async function applyConfidenceFloorAction(directory, touched, options) {
|
|
|
769
769
|
});
|
|
770
770
|
}
|
|
771
771
|
if (action === "quarantine" && toQuarantine.length > 0) {
|
|
772
|
-
const { quarantineEntry } = await import("./knowledge-validator-
|
|
773
|
-
const { KnowledgeConfigSchema } = await import("./schema-
|
|
772
|
+
const { quarantineEntry } = await import("./knowledge-validator-jsz1dxkr.js");
|
|
773
|
+
const { KnowledgeConfigSchema } = await import("./schema-f937b9cs.js");
|
|
774
774
|
let config;
|
|
775
775
|
try {
|
|
776
|
-
const { loadPluginConfigWithMeta } = await import("./index-
|
|
776
|
+
const { loadPluginConfigWithMeta } = await import("./index-wnz282j3.js");
|
|
777
777
|
const { config: loadedConfig } = loadPluginConfigWithMeta(directory);
|
|
778
778
|
config = KnowledgeConfigSchema.parse(loadedConfig.knowledge ?? {});
|
|
779
779
|
} catch {
|
|
@@ -6,13 +6,13 @@ import {
|
|
|
6
6
|
resolveSwarmKnowledgePath,
|
|
7
7
|
transactKnowledge,
|
|
8
8
|
wordBigrams
|
|
9
|
-
} from "./index-
|
|
9
|
+
} from "./index-0755132s.js";
|
|
10
10
|
import {
|
|
11
11
|
countEntryContradictionsInWindow,
|
|
12
12
|
countEntryViolationsInWindow,
|
|
13
13
|
readKnowledgeEvents,
|
|
14
14
|
recordKnowledgeEvent
|
|
15
|
-
} from "./index-
|
|
15
|
+
} from "./index-84nz7bhe.js";
|
|
16
16
|
import {
|
|
17
17
|
init_knowledge_types,
|
|
18
18
|
isActiveStatus
|
|
@@ -190,11 +190,11 @@ async function maybeQuarantineOnContradiction(directory, entryId, threshold, win
|
|
|
190
190
|
alreadyInactive: true
|
|
191
191
|
};
|
|
192
192
|
}
|
|
193
|
-
const { quarantineEntry } = await import("./knowledge-validator-
|
|
193
|
+
const { quarantineEntry } = await import("./knowledge-validator-jsz1dxkr.js");
|
|
194
194
|
let policyConfig;
|
|
195
195
|
try {
|
|
196
|
-
const { KnowledgeConfigSchema } = await import("./schema-
|
|
197
|
-
const { loadPluginConfigWithMeta } = await import("./index-
|
|
196
|
+
const { KnowledgeConfigSchema } = await import("./schema-f937b9cs.js");
|
|
197
|
+
const { loadPluginConfigWithMeta } = await import("./index-wnz282j3.js");
|
|
198
198
|
const { config: loadedConfig } = loadPluginConfigWithMeta(directory);
|
|
199
199
|
policyConfig = KnowledgeConfigSchema.parse(loadedConfig.knowledge ?? {});
|
|
200
200
|
} catch {
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
PluginConfigSchema,
|
|
7
7
|
init_schema,
|
|
8
8
|
stripKnownSwarmPrefix
|
|
9
|
-
} from "./index-
|
|
9
|
+
} from "./index-y0xaq4f3.js";
|
|
10
10
|
import {
|
|
11
11
|
ALL_AGENT_NAMES,
|
|
12
12
|
init_constants
|
|
@@ -1110,6 +1110,10 @@ function validateConfigKey(path2, value) {
|
|
|
1110
1110
|
emitObjectTypeMismatch("external_skills", value, findings);
|
|
1111
1111
|
break;
|
|
1112
1112
|
}
|
|
1113
|
+
case "skill_opt": {
|
|
1114
|
+
emitObjectTypeMismatch("skill_opt", value, findings);
|
|
1115
|
+
break;
|
|
1116
|
+
}
|
|
1113
1117
|
default: {
|
|
1114
1118
|
const topLevel = path2.split(".")[0];
|
|
1115
1119
|
if (KNOWN_TOP_LEVEL_KEYS.has(topLevel)) {
|
|
@@ -625,7 +625,7 @@ async function applyKnowledgeVerdictFeedback(directory, options) {
|
|
|
625
625
|
deltas.push({ id, delta });
|
|
626
626
|
}
|
|
627
627
|
if (deltas.length > 0) {
|
|
628
|
-
const { bumpKnowledgeConfidenceBatch } = await import("./knowledge-store-
|
|
628
|
+
const { bumpKnowledgeConfidenceBatch } = await import("./knowledge-store-h3jz10bv.js");
|
|
629
629
|
await bumpKnowledgeConfidenceBatch(directory, deltas, options?.floorOptions);
|
|
630
630
|
}
|
|
631
631
|
return {
|
|
@@ -2,18 +2,18 @@
|
|
|
2
2
|
import {
|
|
3
3
|
ALLOWED_SKILL_PATH_PREFIXES,
|
|
4
4
|
validateSkillPath
|
|
5
|
-
} from "./index-
|
|
5
|
+
} from "./index-s0rbdp61.js";
|
|
6
6
|
import {
|
|
7
7
|
computeOutcomeSignal,
|
|
8
8
|
readKnowledge,
|
|
9
9
|
resolveHiveKnowledgePath,
|
|
10
10
|
resolveSwarmKnowledgePath,
|
|
11
11
|
transactKnowledge
|
|
12
|
-
} from "./index-
|
|
12
|
+
} from "./index-0755132s.js";
|
|
13
13
|
import {
|
|
14
14
|
effectiveRetrievalOutcomes,
|
|
15
15
|
readKnowledgeCounterRollups
|
|
16
|
-
} from "./index-
|
|
16
|
+
} from "./index-84nz7bhe.js";
|
|
17
17
|
import {
|
|
18
18
|
init_knowledge_types,
|
|
19
19
|
isActiveStatus
|
|
@@ -588,9 +588,15 @@ function includesPhrase(content, phrase) {
|
|
|
588
588
|
return content.toLowerCase().includes(phrase.toLowerCase());
|
|
589
589
|
}
|
|
590
590
|
function evaluateContent(content, testCase) {
|
|
591
|
+
return scoreSkillPhrases({
|
|
592
|
+
content,
|
|
593
|
+
required: testCase.required_phrases,
|
|
594
|
+
forbidden: testCase.forbidden_phrases
|
|
595
|
+
});
|
|
596
|
+
}
|
|
597
|
+
function scoreSkillPhrases(args) {
|
|
598
|
+
const { content, required = [], forbidden = [] } = args;
|
|
591
599
|
const failures = [];
|
|
592
|
-
const required = testCase.required_phrases ?? [];
|
|
593
|
-
const forbidden = testCase.forbidden_phrases ?? [];
|
|
594
600
|
let requiredHits = 0;
|
|
595
601
|
for (const phrase of required) {
|
|
596
602
|
if (includesPhrase(content, phrase)) {
|
|
@@ -2135,4 +2141,4 @@ var _internals = {
|
|
|
2135
2141
|
clearRetiredSkillLinks
|
|
2136
2142
|
};
|
|
2137
2143
|
|
|
2138
|
-
export { BUNDLED_PROJECT_SKILL_ROOT, bundledProjectSkillFileReference, syncBundledProjectSkillsIfMissingAsync, appendSkillChangelog, evaluateSkillChange, appendRejectedSkillEdit, sanitizeSlug, isValidSlug2 as isValidSlug, proposalPath, activePath, activeRepoRelativePath, proposalRepoRelativePath, generateEvalStub, writeEvalStub, DEFAULT_SKILL_MIN_CONFIDENCE, DEFAULT_SKILL_MIN_CONFIRMATIONS, STRONG_SKILL_OUTCOME_COUNT, HIGH_PRIORITY_SKILL_MIN_CONFIDENCE, selectCandidateEntries, isSkillMaturityEligible, clusterEntries, buildKnowledgeCluster, renderSkillMarkdown, generateSkills, parseDraftFrontmatter, activateProposal, findSkillsBySourceKnowledgeId, findStaleSkillsBySourceKnowledgeId, listSkills, autoApplyProposals, inspectSkill, retireSkill, clearDraftSkillLinks, clearRetiredSkillLinks, markSkillStale, clearSkillStale, retireOrMarkStale, regenerateSkill, _internals };
|
|
2144
|
+
export { BUNDLED_PROJECT_SKILL_ROOT, bundledProjectSkillFileReference, syncBundledProjectSkillsIfMissingAsync, appendSkillChangelog, evaluateSkillChange, appendRejectedSkillEdit, isRejectedSkillContent, sanitizeSlug, isValidSlug2 as isValidSlug, proposalPath, activePath, activeRepoRelativePath, proposalRepoRelativePath, generateEvalStub, writeEvalStub, DEFAULT_SKILL_MIN_CONFIDENCE, DEFAULT_SKILL_MIN_CONFIRMATIONS, STRONG_SKILL_OUTCOME_COUNT, HIGH_PRIORITY_SKILL_MIN_CONFIDENCE, selectCandidateEntries, isSkillMaturityEligible, clusterEntries, buildKnowledgeCluster, renderSkillMarkdown, generateSkills, parseDraftFrontmatter, activateProposal, findSkillsBySourceKnowledgeId, findStaleSkillsBySourceKnowledgeId, listSkills, autoApplyProposals, inspectSkill, retireSkill, clearDraftSkillLinks, clearRetiredSkillLinks, markSkillStale, clearSkillStale, retireOrMarkStale, regenerateSkill, _internals };
|
|
@@ -12,14 +12,14 @@ import {
|
|
|
12
12
|
detectPosixWrites,
|
|
13
13
|
detectWindowsWrites,
|
|
14
14
|
resolveWriteTargets
|
|
15
|
-
} from "./index-
|
|
15
|
+
} from "./index-sr2cynyw.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-m5fw4mer.js";
|
|
23
23
|
|
|
24
24
|
// src/services/guardrail-explain-service.ts
|
|
25
25
|
import path from "path";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
handleGuardrailExplain
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-azghvnja.js";
|
|
5
5
|
import {
|
|
6
6
|
handleGuardrailLog
|
|
7
|
-
} from "./index-
|
|
7
|
+
} from "./index-37v2wxqe.js";
|
|
8
8
|
import {
|
|
9
9
|
COMMAND_REGISTRY,
|
|
10
10
|
SWARM_COMMAND_TOOL_ALLOWLIST,
|
|
@@ -84,36 +84,39 @@ import {
|
|
|
84
84
|
handleWriteRetroCommand,
|
|
85
85
|
normalizeSwarmCommandInput,
|
|
86
86
|
resolveCommand
|
|
87
|
-
} from "./index-
|
|
87
|
+
} from "./index-sr2cynyw.js";
|
|
88
88
|
import"./index-vm4xw9z3.js";
|
|
89
|
-
import"./index-
|
|
90
|
-
import"./index-
|
|
91
|
-
import"./index-
|
|
89
|
+
import"./index-wjm896ey.js";
|
|
90
|
+
import"./index-m5fw4mer.js";
|
|
91
|
+
import"./index-7ayaq27q.js";
|
|
92
|
+
import"./index-kwwxevne.js";
|
|
93
|
+
import"./index-z1tm47nj.js";
|
|
94
|
+
import"./index-y8552snf.js";
|
|
92
95
|
import"./index-4905hd2m.js";
|
|
93
96
|
import"./index-134d35c1.js";
|
|
94
|
-
import"./index-
|
|
95
|
-
import"./index-
|
|
96
|
-
import"./index-
|
|
97
|
+
import"./index-ad6j0m7k.js";
|
|
98
|
+
import"./index-21115szq.js";
|
|
99
|
+
import"./index-1kn24ja0.js";
|
|
97
100
|
import"./index-6mjf4vr1.js";
|
|
98
101
|
import"./index-c8s9a3zh.js";
|
|
99
102
|
import"./index-9ss2m4rs.js";
|
|
100
|
-
import"./index-
|
|
103
|
+
import"./index-wsdnttf4.js";
|
|
101
104
|
import"./index-mrtms113.js";
|
|
102
|
-
import"./index-
|
|
103
|
-
import"./index-
|
|
105
|
+
import"./index-s0rbdp61.js";
|
|
106
|
+
import"./index-rw3f73aq.js";
|
|
104
107
|
import"./index-rtry5xyf.js";
|
|
105
|
-
import"./index-
|
|
106
|
-
import"./index-
|
|
108
|
+
import"./index-0755132s.js";
|
|
109
|
+
import"./index-84nz7bhe.js";
|
|
107
110
|
import"./index-ae75rja9.js";
|
|
108
111
|
import"./index-dzyjb33e.js";
|
|
109
112
|
import"./index-ey29aap6.js";
|
|
110
|
-
import"./index-
|
|
113
|
+
import"./index-s0vahtdm.js";
|
|
111
114
|
import"./index-k5jrywpr.js";
|
|
112
115
|
import"./index-n832052r.js";
|
|
113
116
|
import {
|
|
114
117
|
init_schema,
|
|
115
118
|
stripKnownSwarmPrefix
|
|
116
|
-
} from "./index-
|
|
119
|
+
} from "./index-y0xaq4f3.js";
|
|
117
120
|
import"./index-bk5tah7q.js";
|
|
118
121
|
import"./index-8fwhhayc.js";
|
|
119
122
|
import"./index-q1exe2b3.js";
|