opencode-swarm 7.109.2 → 7.109.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/.opencode/skills/ci-failure-batching/SKILL.md +39 -0
- package/.opencode/skills/gate-attribution/SKILL.md +31 -0
- package/.opencode/skills/merge-queue-readiness/SKILL.md +37 -0
- package/.opencode/skills/skill-edit-validation/SKILL.md +29 -0
- package/.opencode/skills/worktree-retry-cleanup/SKILL.md +24 -0
- package/dist/cli/{config-doctor-q354tb2w.js → config-doctor-9vjyj9m3.js} +2 -2
- package/dist/cli/{curator-llm-factory-wqbm9mwr.js → curator-llm-factory-3hf9xpnd.js} +9 -9
- package/dist/cli/{curator-6p9tpprq.js → curator-zn1kmwmz.js} +9 -9
- package/dist/cli/{guardrail-explain-ynge4ww3.js → guardrail-explain-hjz1k6w0.js} +10 -10
- package/dist/cli/{guardrail-log-8mqqsssq.js → guardrail-log-5240bawg.js} +3 -3
- package/dist/cli/{hive-promoter-qh2rh8x2.js → hive-promoter-j81yj97d.js} +9 -9
- package/dist/cli/{index-h4c4rrwx.js → index-18690p15.js} +23 -2
- package/dist/cli/{index-fz1jgbvw.js → index-41fgssqr.js} +22 -2
- package/dist/cli/{index-wg0665ft.js → index-8f10r7ay.js} +2 -2
- package/dist/cli/{index-9qxntjtx.js → index-b15qbvph.js} +190 -41
- package/dist/cli/{index-wj4jeavn.js → index-d3txrx5q.js} +1 -1
- package/dist/cli/{index-5gnp8fyw.js → index-mtzjbaaa.js} +3 -3
- package/dist/cli/{index-3qwaydq1.js → index-nvmy7xmj.js} +11 -11
- package/dist/cli/{index-vx76tcxe.js → index-p5vm9gy9.js} +1 -1
- package/dist/cli/{index-cqbqynzp.js → index-y3nx3ss0.js} +710 -557
- package/dist/cli/{index-mmny81g1.js → index-y5z2qdvk.js} +1 -1
- package/dist/cli/{index-8a8b5wjf.js → index-zh3qh6m7.js} +2 -2
- package/dist/cli/{index-fm7xz1ne.js → index-zjh648z4.js} +81 -1
- package/dist/cli/index.js +9 -9
- package/dist/cli/{knowledge-escalator-6v7sjprx.js → knowledge-escalator-9ksrgq7h.js} +3 -3
- package/dist/cli/{knowledge-events-6n3x3he2.js → knowledge-events-ymysgtrr.js} +1 -1
- package/dist/cli/{knowledge-store-exkw6yb1.js → knowledge-store-562fefjy.js} +1 -1
- package/dist/cli/{knowledge-validator-exymfcb9.js → knowledge-validator-b9nvmzjc.js} +4 -2
- package/dist/cli/{schema-x17zmd03.js → schema-5vmb5dh8.js} +3 -1
- package/dist/cli/{skill-generator-mx9br4ty.js → skill-generator-mjfqvnn0.js} +15 -5
- package/dist/config/bundled-skills.d.ts +1 -1
- package/dist/config/schema.d.ts +12 -4
- package/dist/hooks/knowledge-types.d.ts +6 -0
- package/dist/hooks/knowledge-validator.d.ts +5 -0
- package/dist/hooks/skill-invalidator.d.ts +48 -0
- package/dist/index.js +217 -216
- package/dist/services/skill-generator.d.ts +47 -2
- package/dist/tools/knowledge-remove.d.ts +3 -8
- package/package.json +6 -1
|
@@ -14,13 +14,39 @@
|
|
|
14
14
|
*/
|
|
15
15
|
import { unlinkSync } from 'node:fs';
|
|
16
16
|
import type { KnowledgeEntryBase } from '../hooks/knowledge-types.js';
|
|
17
|
-
import { type SkillEvaluationResult } from './skill-evaluator.js';
|
|
17
|
+
import { type SkillEvalCase, type SkillEvaluationResult } from './skill-evaluator.js';
|
|
18
18
|
export declare function sanitizeSlug(input: string): string;
|
|
19
19
|
export declare function isValidSlug(slug: string): boolean;
|
|
20
20
|
export declare function proposalPath(directory: string, slug: string): string;
|
|
21
21
|
export declare function activePath(directory: string, slug: string): string;
|
|
22
22
|
/** Repo-relative path used inside SKILLS: file: references and entry metadata. */
|
|
23
23
|
export declare function activeRepoRelativePath(slug: string): string;
|
|
24
|
+
/** G10 (issue #1717): repo-relative path of a draft proposal. */
|
|
25
|
+
export declare function proposalRepoRelativePath(slug: string): string;
|
|
26
|
+
/**
|
|
27
|
+
* G8 (issue #1717): derive an eval case from a cluster's directive fields.
|
|
28
|
+
* The stub verifies the generated SKILL.md actually contains the required
|
|
29
|
+
* procedure and omits the forbidden shortcuts it was compiled from. Returns
|
|
30
|
+
* [] when the cluster has no directive fields.
|
|
31
|
+
*
|
|
32
|
+
* Phrase truncation aligns with skill-evaluator.ts MAX_PHRASE_LENGTH=160: the
|
|
33
|
+
* evaluator's normalizePhrase re-truncates to 160 on load, so capping here at
|
|
34
|
+
* 160 guarantees the stub phrase is a prefix of the rendered directive (which
|
|
35
|
+
* escapeMarkdown truncates to 280). includesPhrase does case-insensitive
|
|
36
|
+
* substring matching, so a 160-char stub phrase always matches the first 160
|
|
37
|
+
* chars of the 280-char rendered directive — no false reject on long directives.
|
|
38
|
+
*/
|
|
39
|
+
export declare function generateEvalStub(cluster: KnowledgeCluster): SkillEvalCase[];
|
|
40
|
+
/**
|
|
41
|
+
* G8 (issue #1717): write an auto-derived eval stub to
|
|
42
|
+
* .swarm/skills/evals/<slug>/auto-stub.json. Idempotent (overwrites the prior
|
|
43
|
+
* stub). Never touches a human-authored fixture. Fail-open.
|
|
44
|
+
*/
|
|
45
|
+
export declare function writeEvalStub(directory: string, slug: string, cases: SkillEvalCase[]): Promise<{
|
|
46
|
+
written: boolean;
|
|
47
|
+
path: string;
|
|
48
|
+
reason?: string;
|
|
49
|
+
}>;
|
|
24
50
|
export interface CandidateSelectionOptions {
|
|
25
51
|
minConfidence: number;
|
|
26
52
|
minConfirmations: number;
|
|
@@ -100,7 +126,7 @@ export declare function generateSkills(req: GenerateRequest): Promise<GenerateRe
|
|
|
100
126
|
* Returns the IDs that were successfully stamped and the IDs that were not
|
|
101
127
|
* found in swarm/hive knowledge (so callers can surface staleness).
|
|
102
128
|
*/
|
|
103
|
-
declare function stampSourceEntries(directory: string, slug: string, ids: string[]): Promise<{
|
|
129
|
+
declare function stampSourceEntries(directory: string, slug: string, ids: string[], mode?: 'active' | 'draft'): Promise<{
|
|
104
130
|
stamped: string[];
|
|
105
131
|
missing: string[];
|
|
106
132
|
}>;
|
|
@@ -124,6 +150,7 @@ export declare function parseDraftFrontmatter(content: string): {
|
|
|
124
150
|
export declare function activateProposal(directory: string, slug: string, force?: boolean, options?: {
|
|
125
151
|
evaluate?: boolean;
|
|
126
152
|
operation?: string;
|
|
153
|
+
confirmUnevaluated?: boolean;
|
|
127
154
|
}): Promise<{
|
|
128
155
|
activated: boolean;
|
|
129
156
|
from: string;
|
|
@@ -183,7 +210,20 @@ export declare function retireSkill(directory: string, slug: string, reason?: st
|
|
|
183
210
|
path: string;
|
|
184
211
|
markerPath: string;
|
|
185
212
|
reason?: string;
|
|
213
|
+
clearedLinks?: string[];
|
|
186
214
|
}>;
|
|
215
|
+
/**
|
|
216
|
+
* G10 (issue #1717): clear draft_generated_skill_* on source entries pointing
|
|
217
|
+
* at a draft proposal. Used by autoApplyProposals REJECT so the cluster can be
|
|
218
|
+
* recompiled. Best-effort; never touches the active generated_skill_* stamp.
|
|
219
|
+
*/
|
|
220
|
+
export declare function clearDraftSkillLinks(directory: string, proposalFilePath: string, slug: string): Promise<string[]>;
|
|
221
|
+
/**
|
|
222
|
+
* G12 (issue #1717): clear generated_skill_* on source entries pointing at a
|
|
223
|
+
* retired skill, and record the slug in retired_skill_history (capped at 50).
|
|
224
|
+
* Called from retireSkill so all retire callers benefit. Best-effort.
|
|
225
|
+
*/
|
|
226
|
+
export declare function clearRetiredSkillLinks(directory: string, skillFilePath: string, slug: string): Promise<string[]>;
|
|
187
227
|
/**
|
|
188
228
|
* Mark a skill as stale by writing a stale.marker file in its directory.
|
|
189
229
|
*/
|
|
@@ -240,5 +280,10 @@ export declare const _internals: {
|
|
|
240
280
|
clearSkillStale: typeof clearSkillStale;
|
|
241
281
|
autoApplyProposals: typeof autoApplyProposals;
|
|
242
282
|
unlinkSync: typeof unlinkSync;
|
|
283
|
+
proposalRepoRelativePath: typeof proposalRepoRelativePath;
|
|
284
|
+
generateEvalStub: typeof generateEvalStub;
|
|
285
|
+
writeEvalStub: typeof writeEvalStub;
|
|
286
|
+
clearDraftSkillLinks: typeof clearDraftSkillLinks;
|
|
287
|
+
clearRetiredSkillLinks: typeof clearRetiredSkillLinks;
|
|
243
288
|
};
|
|
244
289
|
export {};
|
|
@@ -1,13 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { findSkillsBySourceKnowledgeId, findStaleSkillsBySourceKnowledgeId, retireOrMarkStale } from '../services/skill-generator.js';
|
|
1
|
+
import { transactKnowledge } from '../hooks/knowledge-store.js';
|
|
2
|
+
import { writeArchiveTombstoneAndInvalidateSkills } from '../hooks/skill-invalidator.js';
|
|
4
3
|
import { createSwarmTool } from './create-tool.js';
|
|
5
4
|
export declare const _internals: {
|
|
6
5
|
transactKnowledge: typeof transactKnowledge;
|
|
7
|
-
|
|
8
|
-
findSkillsBySourceKnowledgeId: typeof findSkillsBySourceKnowledgeId;
|
|
9
|
-
findStaleSkillsBySourceKnowledgeId: typeof findStaleSkillsBySourceKnowledgeId;
|
|
10
|
-
retireOrMarkStale: typeof retireOrMarkStale;
|
|
11
|
-
recordKnowledgeEvent: typeof recordKnowledgeEvent;
|
|
6
|
+
writeArchiveTombstoneAndInvalidateSkills: typeof writeArchiveTombstoneAndInvalidateSkills;
|
|
12
7
|
};
|
|
13
8
|
export declare const knowledge_remove: ReturnType<typeof createSwarmTool>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "opencode-swarm",
|
|
3
|
-
"version": "7.109.
|
|
3
|
+
"version": "7.109.4",
|
|
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",
|
|
@@ -67,6 +67,11 @@
|
|
|
67
67
|
".opencode/skills/running-tests",
|
|
68
68
|
".opencode/skills/engineering-conventions",
|
|
69
69
|
".opencode/skills/commit-pr",
|
|
70
|
+
".opencode/skills/worktree-retry-cleanup",
|
|
71
|
+
".opencode/skills/skill-edit-validation",
|
|
72
|
+
".opencode/skills/merge-queue-readiness",
|
|
73
|
+
".opencode/skills/gate-attribution",
|
|
74
|
+
".opencode/skills/ci-failure-batching",
|
|
70
75
|
"tests/fixtures/memory-recall",
|
|
71
76
|
"README.md",
|
|
72
77
|
"LICENSE"
|