opencode-swarm 7.147.0 → 7.147.1

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 (94) hide show
  1. package/dist/cli/{ast-diff-665tewz6.js → ast-diff-ekd9v10f.js} +2 -2
  2. package/dist/cli/{config-doctor-7a2z00qt.js → config-doctor-8nskdpgd.js} +2 -2
  3. package/dist/cli/{core-50jqqm4g.js → core-9rt6kbk1.js} +2 -2
  4. package/dist/cli/{curation-policy-g353f457.js → curation-policy-9d7jx7cg.js} +4 -4
  5. package/dist/cli/{curator-drift-r50x1rac.js → curator-drift-fv4rttf4.js} +2 -2
  6. package/dist/cli/curator-llm-factory-8xdxbmnz.js +64 -0
  7. package/dist/cli/{curator-3t7e3hf9.js → curator-xvymjgan.js} +31 -31
  8. package/dist/cli/{dispatch-ndxbsk98.js → dispatch-w0rzasz3.js} +2 -2
  9. package/dist/cli/{evidence-summary-service-8n16gxgm.js → evidence-summary-service-k7a2s8f8.js} +11 -11
  10. package/dist/cli/{gate-evidence-496qt72z.js → gate-evidence-bbpvx28c.js} +6 -6
  11. package/dist/cli/guardrail-explain-qz2hfyb2.js +65 -0
  12. package/dist/cli/{guardrail-log-dy9b5qtt.js → guardrail-log-6098jxes.js} +4 -4
  13. package/dist/cli/guardrail-reset-2bcccwmx.js +90 -0
  14. package/dist/cli/{hive-promoter-mspppqbp.js → hive-promoter-9xzf0r98.js} +31 -31
  15. package/dist/cli/{index-at1m1k5k.js → index-014mntpw.js} +6 -6
  16. package/dist/cli/{index-tya6ytex.js → index-1k41c7kt.js} +2 -2
  17. package/dist/cli/{index-p3k155dv.js → index-1xvxd02x.js} +1 -1
  18. package/dist/cli/{index-hmssmyvh.js → index-2qapn7fk.js} +1 -1
  19. package/dist/cli/{index-w8pgjr75.js → index-4cgee5vh.js} +1 -1
  20. package/dist/cli/{index-w4ybhzyg.js → index-59q7jma6.js} +6 -6
  21. package/dist/cli/{index-er61pycf.js → index-5qfp2kt4.js} +6 -6
  22. package/dist/cli/{index-ms46zgwb.js → index-6cxb7ng4.js} +4 -4
  23. package/dist/cli/{index-mfmegbz2.js → index-7tvbvecm.js} +1 -1
  24. package/dist/cli/{index-92r9z3yk.js → index-8861hfbt.js} +32239 -30875
  25. package/dist/cli/{index-argd4rp4.js → index-8k9hw17k.js} +4 -4
  26. package/dist/cli/{index-k5ng170v.js → index-9b50bt13.js} +2 -2
  27. package/dist/cli/{index-mdwvn7qe.js → index-aahyrzmm.js} +2 -2
  28. package/dist/cli/{index-tp5ytzzg.js → index-avcqq7xc.js} +1 -1
  29. package/dist/cli/{index-hw1yghpg.js → index-axcvb5kf.js} +1 -1
  30. package/dist/cli/{index-pna97bbk.js → index-b7qzwv3t.js} +3 -3
  31. package/dist/cli/{index-hcb25p12.js → index-b834mas0.js} +2 -2
  32. package/dist/cli/{index-15twmgzf.js → index-b99vp668.js} +33 -33
  33. package/dist/cli/{index-8py21zn6.js → index-bp5n93w5.js} +1 -1
  34. package/dist/cli/{index-yq1fxahj.js → index-by1f9ghd.js} +1 -1
  35. package/dist/cli/{index-rpy0bent.js → index-d3bdr78h.js} +2 -2
  36. package/dist/cli/{index-e1pxav9g.js → index-fxvgaeq4.js} +1 -1
  37. package/dist/cli/{index-z9yhhk6q.js → index-g8wwj0sz.js} +1 -1
  38. package/dist/cli/{index-a3fky5pd.js → index-gkhx2vkh.js} +1 -1
  39. package/dist/cli/{index-bgefx261.js → index-kbp4xssa.js} +4 -4
  40. package/dist/cli/{index-20ndbsmh.js → index-n5wzwz8x.js} +8 -5
  41. package/dist/cli/{index-abtrcs16.js → index-nj6rmyeh.js} +1 -1
  42. package/dist/cli/{index-3p4wgm0d.js → index-pgvx3rkq.js} +1 -1
  43. package/dist/cli/index-q7sjgr1y.js +52 -0
  44. package/dist/cli/{index-b67y7an8.js → index-q85xv7t6.js} +10 -2
  45. package/dist/cli/{index-sh8xbyca.js → index-qy5yz7fn.js} +10 -4
  46. package/dist/cli/{index-zj6t9zgx.js → index-r3mvsbtq.js} +8 -1
  47. package/dist/cli/{index-ddpkwdcb.js → index-r9wnyq0v.js} +1 -1
  48. package/dist/cli/{index-6c17bqbj.js → index-t4xa2yss.js} +5 -5
  49. package/dist/cli/{index-yjvtk1w2.js → index-vpzvmp21.js} +2 -2
  50. package/dist/cli/{index-f75qjtn5.js → index-zwc96x0a.js} +1 -1
  51. package/dist/cli/index.js +31 -31
  52. package/dist/cli/{knowledge-escalator-7gw36zj8.js → knowledge-escalator-300p0bvr.js} +11 -11
  53. package/dist/cli/{knowledge-events-r1xak0yw.js → knowledge-events-5ncg5xv1.js} +9 -9
  54. package/dist/cli/{knowledge-link-jkx8xjxp.js → knowledge-link-stzsjagk.js} +3 -3
  55. package/dist/cli/{knowledge-store-wzzke013.js → knowledge-store-mn75hsww.js} +4 -4
  56. package/dist/cli/{knowledge-validator-mma2bbgp.js → knowledge-validator-763r7qpn.js} +6 -6
  57. package/dist/cli/{pending-delegations-k2yqg1sj.js → pending-delegations-k4x00mqc.js} +3 -3
  58. package/dist/cli/{pr-subscriptions-js5v2xr6.js → pr-subscriptions-x2mqc3f1.js} +3 -3
  59. package/dist/cli/{runner-q7d22d1w.js → runner-26bc3x73.js} +5 -5
  60. package/dist/cli/{runtime-x10qb3z1.js → runtime-wjwbpp9j.js} +2 -2
  61. package/dist/cli/{scan-cursor-0vcx58aa.js → scan-cursor-b7kyjefy.js} +5 -5
  62. package/dist/cli/{schema-qr135rxc.js → schema-zjhwka27.js} +1 -1
  63. package/dist/cli/{scope-persistence-x7v9mb9k.js → scope-persistence-aa7gkgz0.js} +7 -7
  64. package/dist/cli/{skill-generator-aee04dwa.js → skill-generator-nsa7ay0c.js} +14 -13
  65. package/dist/cli/{workspace-snapshot-kznz5e13.js → workspace-snapshot-nq25j94x.js} +2 -2
  66. package/dist/cli/{worktree-collision-ownership-xj0bsg92.js → worktree-collision-ownership-q2gswg16.js} +4 -4
  67. package/dist/cli/{worktree-isolation-ar52a7xr.js → worktree-isolation-3pw7nwnh.js} +31 -31
  68. package/dist/cli/{worktree-provisioning-owner-72cyddz5.js → worktree-provisioning-owner-cve95q4f.js} +3 -3
  69. package/dist/commands/guardrail-reset.d.ts +2 -0
  70. package/dist/commands/registry.d.ts +16 -3
  71. package/dist/config/schema.d.ts +2 -0
  72. package/dist/failures/action-circuit.d.ts +69 -0
  73. package/dist/failures/action-identity.d.ts +33 -0
  74. package/dist/failures/invocation-failure.d.ts +77 -0
  75. package/dist/full-auto/oversight.d.ts +21 -0
  76. package/dist/full-auto/policy.d.ts +22 -0
  77. package/dist/full-auto/recovery.d.ts +43 -0
  78. package/dist/full-auto/severe-result.d.ts +86 -0
  79. package/dist/full-auto/state.d.ts +18 -0
  80. package/dist/hooks/full-auto-intercept.d.ts +1 -1
  81. package/dist/hooks/gate-denial-tracker.d.ts +1 -1
  82. package/dist/hooks/guardrails/nontransient-circuit.d.ts +19 -5
  83. package/dist/index.js +2827 -2820
  84. package/dist/learning/admission.d.ts +1 -1
  85. package/dist/models/model-override-state.d.ts +47 -0
  86. package/dist/models/task-model-routing.d.ts +71 -0
  87. package/dist/services/diagnose-service.d.ts +2 -2
  88. package/dist/tools/dispatch-lanes.d.ts +8 -0
  89. package/dist/utils/model-dispatch-fallback.d.ts +31 -10
  90. package/dist/utils/timeout.d.ts +18 -4
  91. package/package.json +1 -1
  92. package/dist/cli/curator-llm-factory-7cm4494k.js +0 -64
  93. package/dist/cli/guardrail-explain-my9zj5pj.js +0 -65
  94. package/dist/cli/index-wx8zdh4a.js +0 -24
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  autoCommitDirty,
4
4
  cleanUntrackedFiles
5
- } from "./index-k5ng170v.js";
5
+ } from "./index-9b50bt13.js";
6
6
  import {
7
7
  isPathWithinDeclaredScope,
8
8
  unsafePathTextReason
@@ -17,16 +17,16 @@ import {
17
17
  } from "./index-4rhhvd1a.js";
18
18
  import {
19
19
  validateSwarmPath
20
- } from "./index-w8pgjr75.js";
20
+ } from "./index-4cgee5vh.js";
21
21
  import {
22
22
  bunSpawn,
23
23
  classifySpawnFailure
24
- } from "./index-zj6t9zgx.js";
24
+ } from "./index-r3mvsbtq.js";
25
25
  import {
26
26
  atomicWriteFile,
27
27
  taskEvidencePath,
28
28
  withTaskEvidenceLock
29
- } from "./index-8py21zn6.js";
29
+ } from "./index-bp5n93w5.js";
30
30
  import {
31
31
  assertProjectRoot
32
32
  } from "./index-6q35swn2.js";
@@ -13,7 +13,7 @@ import {
13
13
  } from "./index-4rhhvd1a.js";
14
14
  import {
15
15
  bunSpawn
16
- } from "./index-zj6t9zgx.js";
16
+ } from "./index-r3mvsbtq.js";
17
17
  import {
18
18
  log
19
19
  } from "./index-zgwm4ryv.js";
@@ -92,7 +92,7 @@ var _internals = {
92
92
  symlinkSync: fs.symlinkSync
93
93
  },
94
94
  writeScopeToDisk: async (directory, taskId, files) => {
95
- const { writeScopeToDisk: realWrite } = await import("./scope-persistence-x7v9mb9k.js");
95
+ const { writeScopeToDisk: realWrite } = await import("./scope-persistence-aa7gkgz0.js");
96
96
  return realWrite(directory, taskId, files);
97
97
  },
98
98
  writeLaneProfileToDisk: async (_worktreePath, _laneIndex, _envOverrides) => {
@@ -12,14 +12,14 @@ import {
12
12
  detectPosixWrites,
13
13
  detectWindowsWrites,
14
14
  resolveWriteTargets
15
- } from "./index-92r9z3yk.js";
15
+ } from "./index-8861hfbt.js";
16
16
  import {
17
17
  checkFileAuthority,
18
18
  classifyFile,
19
19
  isInDeclaredScope,
20
20
  redactPath,
21
21
  redactShellCommand
22
- } from "./index-b67y7an8.js";
22
+ } from "./index-q85xv7t6.js";
23
23
 
24
24
  // src/services/guardrail-explain-service.ts
25
25
  import path from "path";
@@ -7,7 +7,7 @@ import {
7
7
  readLinkPointer,
8
8
  resolveKnowledgeStoreDir,
9
9
  resolveLinkDir
10
- } from "./index-f75qjtn5.js";
10
+ } from "./index-zwc96x0a.js";
11
11
 
12
12
  // src/knowledge/curation-policy.ts
13
13
  import { appendFile, mkdir as mkdir2, readFile as readFile2 } from "fs/promises";
@@ -245,7 +245,7 @@ var SWARM_TEMP_GRAMMARS = [
245
245
  parsesTarget: false,
246
246
  producers: [
247
247
  "src/tools/checkpoint.ts:194",
248
- "src/full-auto/state.ts:448",
248
+ "src/full-auto/state.ts:460",
249
249
  "src/context-map/persistence.ts:119",
250
250
  "src/context-map/capsule-persistence.ts:107",
251
251
  "src/test-impact/history-store.ts:225",
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  _internals,
4
4
  resolveWorktreeIsolationConfig
5
- } from "./index-yjvtk1w2.js";
5
+ } from "./index-vpzvmp21.js";
6
6
  import {
7
7
  ApprovalEvidenceSchema,
8
8
  BaseEvidenceSchema,
@@ -42,7 +42,7 @@ import {
42
42
  loadPluginConfig,
43
43
  loadPluginConfigWithMeta,
44
44
  loadPluginConfigWithMetaAsync
45
- } from "./index-mfmegbz2.js";
45
+ } from "./index-7tvbvecm.js";
46
46
  import {
47
47
  AUTO_REVIEW_V8_BURN_IN_DECISION,
48
48
  AgentOverrideConfigSchema,
@@ -64,7 +64,7 @@ import {
64
64
  TurboConfigSchema,
65
65
  WorktreeIsolationConfigSchema,
66
66
  resolveAutoReviewConfig
67
- } from "./index-sh8xbyca.js";
67
+ } from "./index-qy5yz7fn.js";
68
68
  import {
69
69
  ALL_AGENT_NAMES,
70
70
  ALL_SUBAGENT_NAMES,
@@ -9,7 +9,7 @@ import {
9
9
  readEvaluationRun,
10
10
  saveEvaluationRun,
11
11
  saveTaskSetSnapshot
12
- } from "./index-p3k155dv.js";
12
+ } from "./index-1xvxd02x.js";
13
13
  import {
14
14
  canonicalHash,
15
15
  computeCandidateInputContentHash,
@@ -20,7 +20,7 @@ import {
20
20
  } from "./index-y8552snf.js";
21
21
  import {
22
22
  bunSpawn
23
- } from "./index-zj6t9zgx.js";
23
+ } from "./index-r3mvsbtq.js";
24
24
  import {
25
25
  exports_external,
26
26
  init_zod
@@ -1,10 +1,10 @@
1
1
  // @bun
2
2
  import {
3
3
  handleGuardrailExplain
4
- } from "./index-mdwvn7qe.js";
4
+ } from "./index-aahyrzmm.js";
5
5
  import {
6
6
  handleGuardrailLog
7
- } from "./index-a3fky5pd.js";
7
+ } from "./index-gkhx2vkh.js";
8
8
  import {
9
9
  COMMAND_REGISTRY,
10
10
  SWARM_COMMAND_TOOL_ALLOWLIST,
@@ -85,48 +85,48 @@ import {
85
85
  handleWriteRetroCommand,
86
86
  normalizeSwarmCommandInput,
87
87
  resolveCommand
88
- } from "./index-92r9z3yk.js";
89
- import"./index-hcb25p12.js";
90
- import"./index-b67y7an8.js";
91
- import"./index-yq1fxahj.js";
92
- import"./index-at1m1k5k.js";
93
- import"./index-p3k155dv.js";
88
+ } from "./index-8861hfbt.js";
89
+ import"./index-b834mas0.js";
90
+ import"./index-q85xv7t6.js";
91
+ import"./index-by1f9ghd.js";
92
+ import"./index-014mntpw.js";
93
+ import"./index-1xvxd02x.js";
94
94
  import"./index-134d35c1.js";
95
- import"./index-abtrcs16.js";
95
+ import"./index-nj6rmyeh.js";
96
96
  import"./index-y8552snf.js";
97
- import"./index-6c17bqbj.js";
98
- import"./index-tya6ytex.js";
97
+ import"./index-t4xa2yss.js";
98
+ import"./index-1k41c7kt.js";
99
99
  import"./index-70ha9e09.js";
100
100
  import"./index-c8s9a3zh.js";
101
101
  import"./index-9ss2m4rs.js";
102
- import"./index-z9yhhk6q.js";
103
- import"./index-3p4wgm0d.js";
104
- import"./index-20ndbsmh.js";
105
- import"./index-bgefx261.js";
106
- import"./index-tp5ytzzg.js";
102
+ import"./index-g8wwj0sz.js";
103
+ import"./index-pgvx3rkq.js";
104
+ import"./index-n5wzwz8x.js";
105
+ import"./index-kbp4xssa.js";
106
+ import"./index-avcqq7xc.js";
107
107
  import"./index-rtry5xyf.js";
108
108
  import"./index-zsrtt42s.js";
109
- import"./index-rpy0bent.js";
110
- import"./index-e1pxav9g.js";
111
- import"./index-argd4rp4.js";
112
- import"./index-k5ng170v.js";
113
- import"./index-ms46zgwb.js";
114
- import"./index-hmssmyvh.js";
109
+ import"./index-d3bdr78h.js";
110
+ import"./index-fxvgaeq4.js";
111
+ import"./index-8k9hw17k.js";
112
+ import"./index-9b50bt13.js";
113
+ import"./index-6cxb7ng4.js";
114
+ import"./index-2qapn7fk.js";
115
115
  import"./index-556ja8an.js";
116
116
  import"./index-b43rt5ph.js";
117
- import"./index-wx8zdh4a.js";
117
+ import"./index-q7sjgr1y.js";
118
118
  import"./index-3g0xk6tk.js";
119
119
  import"./index-85gkedsf.js";
120
- import"./index-er61pycf.js";
121
- import"./index-w4ybhzyg.js";
122
- import"./index-yjvtk1w2.js";
120
+ import"./index-5qfp2kt4.js";
121
+ import"./index-59q7jma6.js";
122
+ import"./index-vpzvmp21.js";
123
123
  import"./index-gprxjmm7.js";
124
124
  import"./index-n832052r.js";
125
- import"./index-mfmegbz2.js";
125
+ import"./index-7tvbvecm.js";
126
126
  import {
127
127
  init_schema,
128
128
  stripKnownSwarmPrefix
129
- } from "./index-sh8xbyca.js";
129
+ } from "./index-qy5yz7fn.js";
130
130
  import {
131
131
  AGENT_TOOL_MAP,
132
132
  ORCHESTRATOR_NAME,
@@ -134,15 +134,15 @@ import {
134
134
  } from "./index-cpg98bh1.js";
135
135
  import"./index-9e6fdz2h.js";
136
136
  import"./index-4rhhvd1a.js";
137
- import"./index-w8pgjr75.js";
137
+ import"./index-4cgee5vh.js";
138
138
  import"./index-z6xqpmqg.js";
139
- import"./index-zj6t9zgx.js";
139
+ import"./index-r3mvsbtq.js";
140
140
  import"./index-zjygnfay.js";
141
141
  import"./index-ae75rja9.js";
142
- import"./index-f75qjtn5.js";
143
- import"./index-8py21zn6.js";
142
+ import"./index-zwc96x0a.js";
143
+ import"./index-bp5n93w5.js";
144
144
  import"./index-bk5tah7q.js";
145
- import"./index-hw1yghpg.js";
145
+ import"./index-axcvb5kf.js";
146
146
  import"./index-6q35swn2.js";
147
147
  import"./index-q81s0m8k.js";
148
148
  import"./index-7g4c7s5r.js";
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  import {
3
3
  atomicWriteFileAnyRoot
4
- } from "./index-hw1yghpg.js";
4
+ } from "./index-axcvb5kf.js";
5
5
  import {
6
6
  withEvidenceLock
7
7
  } from "./index-6q35swn2.js";
@@ -6,7 +6,7 @@ import {
6
6
  PluginConfigSchema,
7
7
  init_schema,
8
8
  stripKnownSwarmPrefix
9
- } from "./index-sh8xbyca.js";
9
+ } from "./index-qy5yz7fn.js";
10
10
  import {
11
11
  ALL_AGENT_NAMES,
12
12
  init_constants
@@ -1,10 +1,10 @@
1
1
  // @bun
2
2
  import {
3
3
  validateSwarmPath
4
- } from "./index-w8pgjr75.js";
4
+ } from "./index-4cgee5vh.js";
5
5
  import {
6
6
  bunWrite
7
- } from "./index-zj6t9zgx.js";
7
+ } from "./index-r3mvsbtq.js";
8
8
  import {
9
9
  withEvidenceLock
10
10
  } from "./index-6q35swn2.js";
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  import {
3
3
  validateSwarmPath
4
- } from "./index-w8pgjr75.js";
4
+ } from "./index-4cgee5vh.js";
5
5
 
6
6
  // src/hooks/delegation-gate/worktree-provisioning-owner.ts
7
7
  import { createHash, randomBytes } from "crypto";
@@ -5,7 +5,7 @@ import {
5
5
  } from "./index-9e6fdz2h.js";
6
6
  import {
7
7
  bunSpawn
8
- } from "./index-zj6t9zgx.js";
8
+ } from "./index-r3mvsbtq.js";
9
9
 
10
10
  // src/background/workspace-snapshot.ts
11
11
  import * as child_process from "child_process";
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  redactPath,
4
4
  redactShellCommand
5
- } from "./index-b67y7an8.js";
5
+ } from "./index-q85xv7t6.js";
6
6
 
7
7
  // src/services/guardrail-log-service.ts
8
8
  import * as fs from "fs/promises";
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  import {
3
3
  authorizeCuration
4
- } from "./index-tp5ytzzg.js";
4
+ } from "./index-avcqq7xc.js";
5
5
  import {
6
6
  findNearDuplicate,
7
7
  inferTags,
@@ -9,13 +9,13 @@ import {
9
9
  resolveSwarmKnowledgePath,
10
10
  resolveSwarmRejectedPath,
11
11
  transactKnowledge
12
- } from "./index-er61pycf.js";
12
+ } from "./index-5qfp2kt4.js";
13
13
  import {
14
14
  resolveKnowledgeStoreDir
15
- } from "./index-f75qjtn5.js";
15
+ } from "./index-zwc96x0a.js";
16
16
  import {
17
17
  atomicWriteFile
18
- } from "./index-8py21zn6.js";
18
+ } from "./index-bp5n93w5.js";
19
19
  import {
20
20
  require_proper_lockfile
21
21
  } from "./index-7g4c7s5r.js";
@@ -2,18 +2,21 @@
2
2
  import {
3
3
  ALLOWED_SKILL_PATH_PREFIXES,
4
4
  validateSkillPath
5
- } from "./index-bgefx261.js";
5
+ } from "./index-kbp4xssa.js";
6
+ import {
7
+ withTimeoutSignal
8
+ } from "./index-q7sjgr1y.js";
6
9
  import {
7
10
  computeOutcomeSignal,
8
11
  readKnowledge,
9
12
  resolveHiveKnowledgePath,
10
13
  resolveSwarmKnowledgePath,
11
14
  transactKnowledge
12
- } from "./index-er61pycf.js";
15
+ } from "./index-5qfp2kt4.js";
13
16
  import {
14
17
  effectiveRetrievalOutcomes,
15
18
  readAuthoritativeKnowledgeCounterRollups
16
- } from "./index-w4ybhzyg.js";
19
+ } from "./index-59q7jma6.js";
17
20
  import {
18
21
  advisoryWarn,
19
22
  init_warning_buffer
@@ -25,7 +28,7 @@ import {
25
28
  import {
26
29
  atomicWriteFileAnyRoot,
27
30
  atomicWriteSwarmFile
28
- } from "./index-hw1yghpg.js";
31
+ } from "./index-axcvb5kf.js";
29
32
  import {
30
33
  init_logger,
31
34
  log,
@@ -1685,7 +1688,7 @@ async function autoApplyProposals(directory, llmDelegate) {
1685
1688
  ].join(`
1686
1689
  `);
1687
1690
  try {
1688
- const response = await llmDelegate("", prompt, AbortSignal.timeout(30000));
1691
+ const response = await withTimeoutSignal((signal) => llmDelegate("", prompt, signal), 30000, new Error("Skill proposal evaluation timed out after 30000ms"));
1689
1692
  const verdict = response.trim().toUpperCase();
1690
1693
  if (verdict === "APPROVE") {
1691
1694
  const activation = await activateProposal(directory, proposal.slug, false, {
@@ -4,7 +4,7 @@ import {
4
4
  } from "./index-z6xqpmqg.js";
5
5
  import {
6
6
  bunSpawnSync
7
- } from "./index-zj6t9zgx.js";
7
+ } from "./index-r3mvsbtq.js";
8
8
  import {
9
9
  warn
10
10
  } from "./index-zgwm4ryv.js";
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  import {
3
3
  validateSwarmPath
4
- } from "./index-w8pgjr75.js";
4
+ } from "./index-4cgee5vh.js";
5
5
  import {
6
6
  withEvidenceLock
7
7
  } from "./index-6q35swn2.js";
@@ -0,0 +1,52 @@
1
+ // @bun
2
+ // src/utils/timeout.ts
3
+ async function withTimeout(promise, ms, timeoutError) {
4
+ let timer;
5
+ const timeoutPromise = new Promise((_, reject) => {
6
+ timer = setTimeout(() => reject(timeoutError), ms);
7
+ });
8
+ try {
9
+ return await Promise.race([promise, timeoutPromise]);
10
+ } finally {
11
+ if (timer !== undefined)
12
+ clearTimeout(timer);
13
+ }
14
+ }
15
+ async function withTimeoutSignal(operation, ms, timeoutError) {
16
+ if (!Number.isFinite(ms) || ms < 0) {
17
+ throw new RangeError("timeout must be a finite non-negative number");
18
+ }
19
+ if (timeoutError.name === "Error") {
20
+ try {
21
+ timeoutError.name = "TimeoutError";
22
+ } catch {}
23
+ }
24
+ const controller = new AbortController;
25
+ let timer;
26
+ const timeoutPromise = new Promise((_, reject) => {
27
+ timer = _internals.setTimeout(() => {
28
+ controller.abort(timeoutError);
29
+ reject(timeoutError);
30
+ }, ms);
31
+ });
32
+ try {
33
+ return await Promise.race([
34
+ Promise.resolve().then(() => operation(controller.signal)),
35
+ timeoutPromise
36
+ ]);
37
+ } finally {
38
+ if (timer !== undefined)
39
+ _internals.clearTimeout(timer);
40
+ }
41
+ }
42
+ var _internals = {
43
+ setTimeout,
44
+ clearTimeout
45
+ };
46
+ function yieldToEventLoop() {
47
+ return new Promise((resolve) => {
48
+ setTimeout(resolve, 0);
49
+ });
50
+ }
51
+
52
+ export { withTimeout, withTimeoutSignal, yieldToEventLoop };
@@ -11,7 +11,7 @@ import {
11
11
  import {
12
12
  init_schema,
13
13
  stripKnownSwarmPrefix
14
- } from "./index-sh8xbyca.js";
14
+ } from "./index-qy5yz7fn.js";
15
15
  import {
16
16
  init_constants
17
17
  } from "./index-cpg98bh1.js";
@@ -2574,6 +2574,14 @@ function checkFileAuthority(agentName, filePath, cwd, authorityConfig, options =
2574
2574
 
2575
2575
  // src/hooks/guardrails/helpers.ts
2576
2576
  init_constants();
2577
+
2578
+ // src/hooks/normalize-tool-name.ts
2579
+ var NAMESPACE_PREFIX_PATTERN = /^[^:]+[:.]/;
2580
+ function normalizeToolNameLowerCase(toolName) {
2581
+ return toolName.replace(NAMESPACE_PREFIX_PATTERN, "").toLowerCase();
2582
+ }
2583
+
2584
+ // src/hooks/guardrails/helpers.ts
2577
2585
  function isInDeclaredScope(filePath, scopeEntries, cwd) {
2578
2586
  return isPathWithinDeclaredScope(filePath, scopeEntries, cwd);
2579
2587
  }
@@ -2615,4 +2623,4 @@ function redactPath(filePath) {
2615
2623
  return normalized;
2616
2624
  }
2617
2625
 
2618
- export { classifyFile, stableCanonicalStringify, checkFileAuthority, isInDeclaredScope, redactShellCommand, redactPath };
2626
+ export { classifyFile, stableCanonicalStringify, checkFileAuthority, normalizeToolNameLowerCase, isInDeclaredScope, redactShellCommand, redactPath };
@@ -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.147.0",
24
+ version: "7.147.1",
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",
@@ -1782,7 +1782,9 @@ var init_schema = __esm(() => {
1782
1782
  every_architect_turns: exports_external.number().int().min(0).max(1000).default(5),
1783
1783
  every_minutes: exports_external.number().int().min(0).max(1440).default(20),
1784
1784
  max_dispatch_retries: exports_external.number().int().min(0).max(10).default(2),
1785
- max_consecutive_dispatch_failures: exports_external.number().int().min(0).max(50).default(3)
1785
+ max_consecutive_dispatch_failures: exports_external.number().int().min(0).max(50).default(3),
1786
+ total_timeout_ms: exports_external.number().int().min(1000).max(300000).default(120000),
1787
+ cleanup_timeout_ms: exports_external.number().int().min(100).max(1e4).default(2000)
1786
1788
  }).default(() => ({
1787
1789
  on_plan_change: true,
1788
1790
  on_task_completion: false,
@@ -1793,7 +1795,9 @@ var init_schema = __esm(() => {
1793
1795
  every_architect_turns: 5,
1794
1796
  every_minutes: 20,
1795
1797
  max_dispatch_retries: 2,
1796
- max_consecutive_dispatch_failures: 3
1798
+ max_consecutive_dispatch_failures: 3,
1799
+ total_timeout_ms: 120000,
1800
+ cleanup_timeout_ms: 2000
1797
1801
  }))
1798
1802
  }).optional().default(() => ({
1799
1803
  enabled: false,
@@ -1847,7 +1851,9 @@ var init_schema = __esm(() => {
1847
1851
  every_architect_turns: 5,
1848
1852
  every_minutes: 20,
1849
1853
  max_dispatch_retries: 2,
1850
- max_consecutive_dispatch_failures: 3
1854
+ max_consecutive_dispatch_failures: 3,
1855
+ total_timeout_ms: 120000,
1856
+ cleanup_timeout_ms: 2000
1851
1857
  }
1852
1858
  })),
1853
1859
  pr_monitor: PrMonitorConfigSchema.optional(),
@@ -104,6 +104,13 @@ async function bunWrite(filePath, data) {
104
104
  const stats = await fsPromises.stat(filePath);
105
105
  return stats.size;
106
106
  }
107
+ function sleep(ms) {
108
+ const bun = getBun();
109
+ if (bun?.sleep) {
110
+ return bun.sleep(ms);
111
+ }
112
+ return new Promise((resolve) => setTimeout(resolve, ms));
113
+ }
107
114
  function bunHash(input) {
108
115
  const bun = getBun();
109
116
  if (bun?.hash) {
@@ -639,4 +646,4 @@ function bunSpawnSync(cmd, options) {
639
646
  };
640
647
  }
641
648
 
642
- export { bunFile, bunWrite, bunHash, classifySpawnFailure, mergeEnvForChild, bunSpawn, bunSpawnSync };
649
+ export { bunFile, bunWrite, sleep, bunHash, classifySpawnFailure, mergeEnvForChild, bunSpawn, bunSpawnSync };
@@ -5,7 +5,7 @@ import {
5
5
  } from "./index-7ryh498h.js";
6
6
  import {
7
7
  withTimeout
8
- } from "./index-wx8zdh4a.js";
8
+ } from "./index-q7sjgr1y.js";
9
9
 
10
10
  // src/lang/runtime.ts
11
11
  import { existsSync, statSync } from "fs";
@@ -6,12 +6,12 @@ import {
6
6
  resolveSwarmKnowledgePath,
7
7
  transactKnowledge,
8
8
  wordBigrams
9
- } from "./index-er61pycf.js";
9
+ } from "./index-5qfp2kt4.js";
10
10
  import {
11
11
  queryHistoricalOutcomes,
12
12
  readKnowledgeEvents,
13
13
  recordKnowledgeEvent
14
- } from "./index-w4ybhzyg.js";
14
+ } from "./index-59q7jma6.js";
15
15
  import {
16
16
  init_knowledge_types,
17
17
  isActiveStatus
@@ -224,11 +224,11 @@ async function maybeQuarantineOnContradiction(directory, entryId, threshold, win
224
224
  alreadyInactive: true
225
225
  };
226
226
  }
227
- const { quarantineEntry } = await import("./knowledge-validator-mma2bbgp.js");
227
+ const { quarantineEntry } = await import("./knowledge-validator-763r7qpn.js");
228
228
  let policyConfig;
229
229
  try {
230
- const { KnowledgeConfigSchema } = await import("./schema-qr135rxc.js");
231
- const { loadPluginConfigWithMeta } = await import("./index-pna97bbk.js");
230
+ const { KnowledgeConfigSchema } = await import("./schema-zjhwka27.js");
231
+ const { loadPluginConfigWithMeta } = await import("./index-b7qzwv3t.js");
232
232
  const { config: loadedConfig } = loadPluginConfigWithMeta(directory);
233
233
  policyConfig = KnowledgeConfigSchema.parse(loadedConfig.knowledge ?? {});
234
234
  } catch {
@@ -2,10 +2,10 @@
2
2
  import {
3
3
  init_loader,
4
4
  loadPluginConfigWithMeta
5
- } from "./index-mfmegbz2.js";
5
+ } from "./index-7tvbvecm.js";
6
6
  import {
7
7
  init_schema
8
- } from "./index-sh8xbyca.js";
8
+ } from "./index-qy5yz7fn.js";
9
9
  import {
10
10
  DEFAULT_WORKTREE_ISOLATION_CONFIG,
11
11
  init_constants
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  import {
3
3
  atomicWriteFile
4
- } from "./index-8py21zn6.js";
4
+ } from "./index-bp5n93w5.js";
5
5
  import {
6
6
  init_logger,
7
7
  warn