opencode-swarm 7.152.1 → 7.153.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 (87) hide show
  1. package/.opencode/skills/swarm-pr-review/SKILL.md +10 -10
  2. package/dist/cli/{capability-probe-va4kk8vg.js → capability-probe-5wa7mcp6.js} +3 -2
  3. package/dist/cli/{config-doctor-bbqmye7a.js → config-doctor-7s7xga6f.js} +3 -3
  4. package/dist/cli/{core-fh4e6ex0.js → core-vkpy14vv.js} +2 -2
  5. package/dist/cli/{curation-policy-nem98yc9.js → curation-policy-xy7tm4ad.js} +4 -4
  6. package/dist/cli/{curator-909s9dvs.js → curator-6freqnhf.js} +25 -26
  7. package/dist/cli/{curator-llm-factory-462rysph.js → curator-llm-factory-q5cjk7mt.js} +25 -26
  8. package/dist/cli/{evidence-summary-service-kqw4y0yr.js → evidence-summary-service-engtgjww.js} +11 -11
  9. package/dist/cli/{gate-evidence-ycts62pj.js → gate-evidence-6bzzz8kq.js} +5 -5
  10. package/dist/cli/{guardrail-explain-7620hasq.js → guardrail-explain-vsck39dh.js} +26 -27
  11. package/dist/cli/{guardrail-log-e1tmdxxa.js → guardrail-log-0dn8m3k6.js} +4 -4
  12. package/dist/cli/{guardrail-reset-gdnaxxvb.js → guardrail-reset-6e2vyfn9.js} +25 -26
  13. package/dist/cli/{hive-promoter-d0xydg6r.js → hive-promoter-021abs6z.js} +25 -26
  14. package/dist/cli/{index-mken64yj.js → index-0n7nm9e8.js} +1 -1
  15. package/dist/cli/{index-pvrap7xg.js → index-1yfpw7w0.js} +1 -1
  16. package/dist/cli/{index-2e1294d1.js → index-3z2f1cy8.js} +16 -10
  17. package/dist/cli/{index-n0vc5b5t.js → index-3z5jtyan.js} +14 -6
  18. package/dist/cli/{index-85gkedsf.js → index-4fwbbad3.js} +521 -15
  19. package/dist/cli/{index-nd8tkb3g.js → index-4gn111h3.js} +5 -5
  20. package/dist/cli/{index-rq6aetkv.js → index-5w915x8b.js} +4 -4
  21. package/dist/cli/{index-q77e475x.js → index-5x67858f.js} +3 -3
  22. package/dist/cli/{index-k3d919yf.js → index-6v77adf7.js} +84 -23
  23. package/dist/cli/{index-0tfgn5x0.js → index-77xy577c.js} +6 -6
  24. package/dist/cli/{index-02ajc6d1.js → index-7q56f3se.js} +2 -2
  25. package/dist/cli/{index-xyfdmrv7.js → index-80ekaf5b.js} +1 -1
  26. package/dist/cli/{index-sg2sx2q7.js → index-95qra69h.js} +3826 -2018
  27. package/dist/cli/{index-73pmnsjg.js → index-9gjbe4e4.js} +1 -1
  28. package/dist/cli/{index-z8s2asdk.js → index-9vdh4kdx.js} +22 -150
  29. package/dist/cli/{index-z9fyd0d6.js → index-babtfqa0.js} +2 -2
  30. package/dist/cli/{index-4tvvh7pn.js → index-dh1gk5c5.js} +29 -28
  31. package/dist/cli/{index-3djxegsc.js → index-e2hs0bh7.js} +1 -1
  32. package/dist/cli/{index-qqrdmaxq.js → index-eajfs7v4.js} +2 -2
  33. package/dist/cli/{index-26vyr198.js → index-eqh3t8eh.js} +6 -6
  34. package/dist/cli/{index-29vd7v3e.js → index-g0m6kypc.js} +1 -1
  35. package/dist/cli/{index-96m8ckpq.js → index-hexhzq5j.js} +4 -4
  36. package/dist/cli/{index-ryecg2st.js → index-hkmgzesw.js} +3 -3
  37. package/dist/cli/{index-x6803sxh.js → index-hw49515c.js} +2 -2
  38. package/dist/cli/{index-7fh82sm1.js → index-k2ydsqs7.js} +2 -2
  39. package/dist/cli/{index-cpg98bh1.js → index-myt57pht.js} +1 -1
  40. package/dist/cli/{index-79g6edht.js → index-qgfnd206.js} +1 -1
  41. package/dist/cli/{index-44xdtqz8.js → index-x6zy6veh.js} +1 -1
  42. package/dist/cli/{index-dn6yt0xg.js → index-xv881ahz.js} +5 -5
  43. package/dist/cli/index.js +25 -26
  44. package/dist/cli/{knowledge-escalator-4egcr928.js → knowledge-escalator-79zbhpz5.js} +10 -10
  45. package/dist/cli/{knowledge-events-kdyv4jzn.js → knowledge-events-79cak7eb.js} +8 -8
  46. package/dist/cli/{knowledge-link-h8cwj7af.js → knowledge-link-40zsr5ja.js} +3 -3
  47. package/dist/cli/{knowledge-store-dq3cvg53.js → knowledge-store-w29aw5w0.js} +4 -4
  48. package/dist/cli/{knowledge-validator-4bhtden9.js → knowledge-validator-qsecnt2d.js} +6 -6
  49. package/dist/cli/{model-preflight-7ea00h34.js → model-preflight-b95w8wxy.js} +1 -1
  50. package/dist/cli/{runner-w81n9js3.js → runner-fbgsxs74.js} +4 -4
  51. package/dist/cli/{scan-cursor-2eezv81a.js → scan-cursor-1r3pcdqp.js} +5 -5
  52. package/dist/cli/{schema-v4qcqhek.js → schema-19qsv6fw.js} +2 -2
  53. package/dist/cli/{scope-persistence-y2r227r0.js → scope-persistence-ypcrvqtt.js} +6 -6
  54. package/dist/cli/{skill-generator-hhzxvb3h.js → skill-generator-wpp9kpa0.js} +12 -12
  55. package/dist/cli/{worktree-isolation-ve338ez6.js → worktree-isolation-wcry8qnn.js} +25 -26
  56. package/dist/commands/approve-write.d.ts +1 -0
  57. package/dist/commands/index.d.ts +1 -0
  58. package/dist/commands/registry.d.ts +7 -0
  59. package/dist/config/schema.d.ts +39 -4
  60. package/dist/consensus/contracts.d.ts +14 -0
  61. package/dist/hooks/full-auto-permission.d.ts +7 -0
  62. package/dist/hooks/guardrails/index.d.ts +2 -1
  63. package/dist/hooks/guardrails/tool-before.d.ts +4 -0
  64. package/dist/hooks/pr-workflow-gate.d.ts +12 -0
  65. package/dist/hooks/scope-guard.d.ts +1 -3
  66. package/dist/index.js +624 -606
  67. package/dist/learning/provenance.d.ts +9 -0
  68. package/dist/sandbox/capability-probe.d.ts +40 -1
  69. package/dist/sandbox/executor.d.ts +26 -1
  70. package/dist/sandbox/linux/bubblewrap-executor.d.ts +3 -1
  71. package/dist/sandbox/macos/sandbox-exec-executor.d.ts +3 -1
  72. package/dist/sandbox/skip-state.d.ts +24 -0
  73. package/dist/sandbox/win32/native-sandbox-executor.d.ts +5 -1
  74. package/dist/security/command-classifier.d.ts +22 -0
  75. package/dist/security/protected-input-integrity.d.ts +19 -0
  76. package/dist/security/protected-path-policy.d.ts +9 -0
  77. package/dist/security/write-authority.d.ts +46 -0
  78. package/dist/services/diagnose-service.d.ts +1 -1
  79. package/dist/services/skill-generator.d.ts +2 -0
  80. package/dist/services/skill-improver.d.ts +69 -0
  81. package/dist/tools/dispatch-lanes.d.ts +47 -0
  82. package/dist/tools/repo-graph/query.d.ts +2 -1
  83. package/dist/tools/repo-graph/types.d.ts +64 -0
  84. package/dist/tools/repo-graph.d.ts +1 -1
  85. package/dist/tools/skill-improve.d.ts +7 -0
  86. package/package.json +1 -1
  87. package/dist/cli/index-3g0xk6tk.js +0 -219
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  import {
3
3
  atomicWriteFileAnyRoot
4
- } from "./index-7fh82sm1.js";
4
+ } from "./index-k2ydsqs7.js";
5
5
  import {
6
6
  withEvidenceLock
7
7
  } from "./index-txbd25bc.js";
@@ -7,7 +7,7 @@ import {
7
7
  readLinkPointer,
8
8
  resolveKnowledgeStoreDir,
9
9
  resolveLinkDir
10
- } from "./index-79g6edht.js";
10
+ } from "./index-qgfnd206.js";
11
11
 
12
12
  // src/knowledge/curation-policy.ts
13
13
  import { appendFile, mkdir as mkdir2, readFile as readFile2 } from "fs/promises";
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  ALLOWED_SKILL_PATH_PREFIXES,
4
4
  validateSkillPath
5
- } from "./index-rq6aetkv.js";
5
+ } from "./index-5w915x8b.js";
6
6
  import {
7
7
  withTimeoutSignal
8
8
  } from "./index-q7sjgr1y.js";
@@ -12,11 +12,11 @@ import {
12
12
  resolveHiveKnowledgePath,
13
13
  resolveSwarmKnowledgePath,
14
14
  transactKnowledge
15
- } from "./index-0tfgn5x0.js";
15
+ } from "./index-77xy577c.js";
16
16
  import {
17
17
  effectiveRetrievalOutcomes,
18
18
  readAuthoritativeKnowledgeCounterRollups
19
- } from "./index-dn6yt0xg.js";
19
+ } from "./index-xv881ahz.js";
20
20
  import {
21
21
  advisoryWarn,
22
22
  init_warning_buffer
@@ -28,7 +28,7 @@ import {
28
28
  import {
29
29
  atomicWriteFileAnyRoot,
30
30
  atomicWriteSwarmFile
31
- } from "./index-7fh82sm1.js";
31
+ } from "./index-k2ydsqs7.js";
32
32
  import {
33
33
  init_logger,
34
34
  log,
@@ -1083,6 +1083,7 @@ async function atomicWrite2(p, content) {
1083
1083
  await atomicWriteFileAnyRoot(p, content);
1084
1084
  }
1085
1085
  async function generateSkills(req) {
1086
+ const preview = req.preview === true;
1086
1087
  const minConfidence = req.minConfidence ?? DEFAULT_SKILL_MIN_CONFIDENCE;
1087
1088
  const minConfirmations = req.minConfirmations ?? DEFAULT_SKILL_MIN_CONFIRMATIONS;
1088
1089
  const candidates = await selectCandidateEntries(req.directory, {
@@ -1158,7 +1159,9 @@ async function generateSkills(req) {
1158
1159
  }
1159
1160
  }
1160
1161
  let content = renderSkillMarkdown(cluster, req.mode);
1161
- await writeEvalStub(req.directory, cluster.slug, generateEvalStub(cluster));
1162
+ if (!preview) {
1163
+ await writeEvalStub(req.directory, cluster.slug, generateEvalStub(cluster));
1164
+ }
1162
1165
  if (await isRejectedSkillContent(req.directory, cluster.slug, content)) {
1163
1166
  result.skipped.push({
1164
1167
  slug: cluster.slug,
@@ -1167,7 +1170,7 @@ async function generateSkills(req) {
1167
1170
  continue;
1168
1171
  }
1169
1172
  let evaluation;
1170
- if (req.evaluate) {
1173
+ if (req.evaluate && !preview) {
1171
1174
  let incumbentContent;
1172
1175
  const existingActivePath = activePath(req.directory, cluster.slug);
1173
1176
  if (existsSync2(existingActivePath)) {
@@ -1201,18 +1204,20 @@ async function generateSkills(req) {
1201
1204
  }
1202
1205
  }
1203
1206
  let missingSourceIds = [];
1204
- if (req.mode === "active") {
1207
+ if (!preview && req.mode === "active") {
1205
1208
  const idsToStamp = req.sourceKnowledgeIds?.length ? req.sourceKnowledgeIds : cluster.entries.map((e) => e.id);
1206
1209
  const { missing } = await stampSourceEntries(req.directory, cluster.slug, idsToStamp);
1207
1210
  missingSourceIds = missing;
1208
1211
  if (missingSourceIds.length > 0) {
1209
1212
  content = injectMissingIdsIntoFrontmatter(content, missingSourceIds);
1210
1213
  }
1211
- } else if (req.mode === "draft") {
1214
+ } else if (!preview && req.mode === "draft") {
1212
1215
  const idsToStamp = req.sourceKnowledgeIds?.length ? req.sourceKnowledgeIds : cluster.entries.map((e) => e.id);
1213
1216
  await stampSourceEntries(req.directory, cluster.slug, idsToStamp, "draft");
1214
1217
  }
1215
- await atomicWrite2(targetPath, content);
1218
+ if (!preview) {
1219
+ await atomicWrite2(targetPath, content);
1220
+ }
1216
1221
  result.written.push({
1217
1222
  slug: cluster.slug,
1218
1223
  path: targetPath,
@@ -1220,7 +1225,8 @@ async function generateSkills(req) {
1220
1225
  sourceKnowledgeIds: cluster.entries.map((e) => e.id),
1221
1226
  missingSourceKnowledgeIds: missingSourceIds,
1222
1227
  preserved,
1223
- evaluation
1228
+ evaluation,
1229
+ ...preview ? { content } : {}
1224
1230
  });
1225
1231
  }
1226
1232
  return result;
@@ -3,7 +3,7 @@ import {
3
3
  ALL_AGENT_NAMES,
4
4
  SUMMARIZER_EXEMPT_TOOL_NAMES,
5
5
  init_constants
6
- } from "./index-cpg98bh1.js";
6
+ } from "./index-myt57pht.js";
7
7
  import {
8
8
  OUTCOME_BLOCK_THRESHOLD,
9
9
  init_knowledge_types
@@ -21,7 +21,7 @@ var package_default;
21
21
  var init_package = __esm(() => {
22
22
  package_default = {
23
23
  name: "opencode-swarm",
24
- version: "7.152.1",
24
+ version: "7.153.0",
25
25
  description: "Architect-centric agentic swarm plugin for OpenCode - hub-and-spoke orchestration with SME consultation, code generation, and QA review",
26
26
  main: "dist/index.js",
27
27
  types: "dist/index.d.ts",
@@ -784,11 +784,19 @@ var init_schema = __esm(() => {
784
784
  execution_stall_warn_calls: exports_external.number().int().min(1).default(30),
785
785
  execution_stall_stop_calls: exports_external.number().int().min(1).default(60),
786
786
  execution_stall_episode_minutes: exports_external.number().int().min(1).default(30),
787
- sandbox_macos_enabled: exports_external.boolean().optional()
787
+ sandbox_macos_enabled: exports_external.boolean().optional(),
788
+ sandbox: exports_external.object({
789
+ mode: exports_external.enum(["advisory", "required"]).default("advisory"),
790
+ require_filesystem: exports_external.boolean().default(false),
791
+ require_network: exports_external.boolean().default(false),
792
+ require_process: exports_external.boolean().default(false),
793
+ network_mode: exports_external.enum(["off", "on"]).default("off"),
794
+ network_allowlist: exports_external.array(exports_external.string().min(1)).max(128).default([]),
795
+ writable_roots: exports_external.array(exports_external.string().min(1)).max(128).default([])
796
+ }).optional()
788
797
  });
789
798
  WatchdogConfigSchema = exports_external.object({
790
799
  scope_guard: exports_external.boolean().default(true),
791
- skip_in_turbo: exports_external.boolean().default(false),
792
800
  delegation_ledger: exports_external.boolean().default(true)
793
801
  });
794
802
  SelfReviewConfigSchema = exports_external.object({
@@ -1601,14 +1609,14 @@ var init_schema = __esm(() => {
1601
1609
  enabled: false
1602
1610
  };
1603
1611
  DEFAULT_PR_REVIEW_RESILIENCE_CONFIG = {
1604
- enabled: true,
1612
+ enabled: false,
1605
1613
  canary_probe_ms: 300000,
1606
1614
  status_probe_timeout_ms: 2000,
1607
1615
  correlated_failure_threshold: 2,
1608
1616
  max_retry_attempts_after_initial: 2
1609
1617
  };
1610
1618
  PrReviewResilienceConfigSchema = exports_external.object({
1611
- enabled: exports_external.boolean().default(true),
1619
+ enabled: exports_external.boolean().default(false),
1612
1620
  canary_probe_ms: exports_external.number().int().min(1).max(3600000).default(300000),
1613
1621
  status_probe_timeout_ms: exports_external.number().int().min(1).max(60000).default(2000),
1614
1622
  correlated_failure_threshold: exports_external.number().int().min(2).max(8).default(2),