opencode-swarm 7.87.2 → 7.88.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.
Files changed (28) hide show
  1. package/.opencode/skills/swarm-pr-review/SKILL.md +304 -9
  2. package/README.md +1 -0
  3. package/dist/background/candidate-parser.d.ts +189 -0
  4. package/dist/background/candidate-sidecar-store.d.ts +56 -0
  5. package/dist/cli/{config-doctor-6h64pn8n.js → config-doctor-jzbgpbdh.js} +2 -2
  6. package/dist/cli/{guardrail-explain-9fngqx80.js → guardrail-explain-sw5bjxtk.js} +6 -6
  7. package/dist/cli/{guardrail-log-eegabqcp.js → guardrail-log-c7egm5km.js} +3 -3
  8. package/dist/cli/{index-q9h0wb04.js → index-0asbrmdx.js} +4 -0
  9. package/dist/cli/{index-s8bj492g.js → index-32axfg6h.js} +23 -7
  10. package/dist/cli/{index-1cb4wxnm.js → index-819xp49y.js} +1 -1
  11. package/dist/cli/{index-gjdq4na6.js → index-dkytd370.js} +7 -7
  12. package/dist/cli/{index-f41fa3f0.js → index-fwb5f2gr.js} +2 -2
  13. package/dist/cli/{index-5hvbw5xh.js → index-g00qm2gf.js} +1 -1
  14. package/dist/cli/{index-6qkwgdsg.js → index-jch711dq.js} +246 -169
  15. package/dist/cli/{index-5vpe6vq9.js → index-vjsr9bqt.js} +1 -1
  16. package/dist/cli/index.js +5 -5
  17. package/dist/cli/{schema-84146tvk.js → schema-vb6jkxgg.js} +1 -1
  18. package/dist/cli/{skill-generator-3pvpk4y2.js → skill-generator-kz4q8e49.js} +3 -1
  19. package/dist/hooks/knowledge-reader.d.ts +2 -0
  20. package/dist/hooks/knowledge-types.d.ts +3 -0
  21. package/dist/index.js +1640 -797
  22. package/dist/services/skill-generator.d.ts +10 -0
  23. package/dist/services/skill-improver.d.ts +25 -1
  24. package/dist/tools/index.d.ts +1 -0
  25. package/dist/tools/manifest.d.ts +1 -0
  26. package/dist/tools/parse-lane-candidates.d.ts +2 -0
  27. package/dist/tools/tool-metadata.d.ts +4 -0
  28. package/package.json +1 -1
@@ -28,6 +28,16 @@ export interface CandidateSelectionOptions {
28
28
  export declare const DEFAULT_SKILL_MIN_CONFIDENCE = 0.7;
29
29
  export declare const DEFAULT_SKILL_MIN_CONFIRMATIONS = 2;
30
30
  export declare const STRONG_SKILL_OUTCOME_COUNT = 3;
31
+ /**
32
+ * Confidence floor for the high-priority directive maturity path. `critical`/
33
+ * `high` directives confirmed in only one phase land at `computeConfidence(1,
34
+ * true) = 0.6`, which is below {@link DEFAULT_SKILL_MIN_CONFIDENCE}. That couples
35
+ * the confidence gate to the confirmation gate and permanently strands the
36
+ * highest-value knowledge (issue #1477). This floor gives those directives a
37
+ * defensible maturity path without lowering the gate for ordinary entries, while
38
+ * still rejecting sub-0.6 (e.g. single unverified) junk.
39
+ */
40
+ export declare const HIGH_PRIORITY_SKILL_MIN_CONFIDENCE = 0.6;
31
41
  export interface KnowledgeCluster {
32
42
  slug: string;
33
43
  title: string;
@@ -19,7 +19,7 @@
19
19
  import type { EnrichmentQuotaOptions } from '../hooks/knowledge-curator.js';
20
20
  import type { KnowledgeEntryBase } from '../hooks/knowledge-types.js';
21
21
  import { type SkillImproverLLMDelegate } from '../hooks/skill-improver-llm-factory.js';
22
- import { type AutoApplyResult } from './skill-generator.js';
22
+ import { type AutoApplyResult, regenerateSkill } from './skill-generator.js';
23
23
  import { type QuotaWindow } from './skill-improver-quota.js';
24
24
  export interface SkillImproverConfigInput {
25
25
  enabled: boolean;
@@ -89,6 +89,10 @@ export interface SkillImproveResult {
89
89
  motifs: number;
90
90
  proposalsWritten: number;
91
91
  };
92
+ /** Issue #1477: self-healing reconciliation of stale active generated skills
93
+ * (regenerate-or-retire). In proposal-only runs this is a dry run (the
94
+ * `retired` list holds retire-candidates that were not actually mutated). */
95
+ staleSkillReconciliation?: StaleSkillReconciliationResult;
92
96
  /** #1234 Part 3D: critic-gated auto-apply of proposals in full-auto mode. */
93
97
  autoApply?: AutoApplyResult;
94
98
  }
@@ -126,6 +130,24 @@ declare function buildLLMProposalFrame(args: {
126
130
  model: string | null;
127
131
  now: Date;
128
132
  }): string;
133
+ export interface StaleSkillReconciliationResult {
134
+ regenerated: string[];
135
+ retired: string[];
136
+ skipped: string[];
137
+ checked: number;
138
+ }
139
+ /**
140
+ * Self-healing reconciliation for active generated skills (issue #1477). Detects
141
+ * skills that are stale — no parseable frontmatter, or no `source_knowledge_ids`
142
+ * anchoring them to live knowledge — and either regenerates them from their
143
+ * source entries or retires them when no live source remains. Hand-authored
144
+ * shims (`skill_origin: shim`) are skipped. Deterministic: no LLM, no quota draw;
145
+ * intended to run on the skill_improver cadence. Fail-open per skill — one bad
146
+ * skill never aborts the sweep.
147
+ */
148
+ export declare function reconcileStaleActiveSkills(directory: string, options?: {
149
+ dryRun?: boolean;
150
+ }): Promise<StaleSkillReconciliationResult>;
129
151
  export declare function runSkillImprover(req: SkillImproveRequest): Promise<SkillImproveResult>;
130
152
  export declare const _internals: {
131
153
  runSkillImprover: typeof runSkillImprover;
@@ -134,5 +156,7 @@ export declare const _internals: {
134
156
  buildSystemPrompt: typeof buildSystemPrompt;
135
157
  buildUserPrompt: typeof buildUserPrompt;
136
158
  gatherInventory: typeof gatherInventory;
159
+ reconcileStaleActiveSkills: typeof reconcileStaleActiveSkills;
160
+ regenerateSkill: typeof regenerateSkill;
137
161
  };
138
162
  export {};
@@ -39,6 +39,7 @@ export { knowledge_recall } from './knowledge-recall';
39
39
  export { knowledge_receipt } from './knowledge-receipt';
40
40
  export { knowledge_remove } from './knowledge-remove';
41
41
  export { lint } from './lint';
42
+ export { parse_lane_candidates } from './parse-lane-candidates';
42
43
  export { phase_complete } from './phase-complete';
43
44
  export { pkg_audit } from './pkg-audit';
44
45
  export { type PlaceholderFinding, type PlaceholderScanInput, type PlaceholderScanResult, placeholder_scan, placeholderScan, } from './placeholder-scan';
@@ -48,6 +48,7 @@ export declare const TOOL_MANIFEST: {
48
48
  sbom_generate: () => ToolDefinition;
49
49
  checkpoint: () => ToolDefinition;
50
50
  pkg_audit: () => ToolDefinition;
51
+ parse_lane_candidates: () => ToolDefinition;
51
52
  test_runner: () => ToolDefinition;
52
53
  test_impact: () => ToolDefinition;
53
54
  mutation_test: () => ToolDefinition;
@@ -0,0 +1,2 @@
1
+ import { createSwarmTool } from './create-tool';
2
+ export declare const parse_lane_candidates: ReturnType<typeof createSwarmTool>;
@@ -123,6 +123,10 @@ export declare const TOOL_METADATA: {
123
123
  description: string;
124
124
  agents: ("reviewer" | "test_engineer" | "critic_hallucination_verifier" | "critic_oversight" | "architect")[];
125
125
  };
126
+ parse_lane_candidates: {
127
+ description: string;
128
+ agents: "architect"[];
129
+ };
126
130
  test_runner: {
127
131
  description: string;
128
132
  agents: ("reviewer" | "test_engineer" | "architect")[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-swarm",
3
- "version": "7.87.2",
3
+ "version": "7.88.0",
4
4
  "description": "Architect-centric agentic swarm plugin for OpenCode - hub-and-spoke orchestration with SME consultation, code generation, and QA review",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",