@skathio/somi 4.1.1 → 5.0.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 (372) hide show
  1. package/.claude-plugin/icon.png +0 -0
  2. package/.claude-plugin/marketplace.json +8 -3
  3. package/.claude-plugin/plugin.json +9 -10
  4. package/.copilot-extension/extension.json +32 -40
  5. package/.copilot-extension/marketplace.json +8 -3
  6. package/README.md +83 -228
  7. package/VERSION +1 -1
  8. package/agents/somi-reviewer.md +21 -40
  9. package/agents/somi-security-reviewer.md +16 -90
  10. package/agents/somi-worker-high.md +11 -0
  11. package/agents/somi-worker-low.md +11 -0
  12. package/agents/somi-worker-medium.md +11 -0
  13. package/agents/somi.md +8 -75
  14. package/commands/somi-config.md +5 -14
  15. package/commands/somi-deliver.md +11 -0
  16. package/commands/somi-quality.md +10 -0
  17. package/commands/somi-review.md +10 -0
  18. package/commands/somi-status.md +11 -0
  19. package/commands/somi.md +10 -0
  20. package/hooks/hooks.json +28 -23
  21. package/hooks/lib/common.mjs +45 -34
  22. package/hooks/pre-tool/apply-tier.mjs +31 -0
  23. package/hooks/pre-tool/block-dangerous-bash.mjs +15 -0
  24. package/hooks/pre-tool/gate-dep-install.mjs +2 -2
  25. package/hooks/pre-tool/guard-protected-paths.mjs +9 -16
  26. package/hooks/pre-tool/guard-tier-config.mjs +17 -0
  27. package/hooks/pre-tool/reviewers-read-only.mjs +11 -0
  28. package/hooks/session-start/inject-digest.mjs +51 -0
  29. package/hooks/stop/review-due.mjs +40 -0
  30. package/hooks/user-prompt/capture-prompt.mjs +17 -0
  31. package/library/lenses/architecture.md +1 -0
  32. package/library/lenses/test-strategy.md +1 -0
  33. package/library/roles/accessibility.md +1 -0
  34. package/library/roles/answer.md +1 -0
  35. package/library/roles/atlas.md +1 -0
  36. package/library/roles/build.md +1 -0
  37. package/library/roles/debug.md +6 -0
  38. package/library/roles/design.md +1 -0
  39. package/library/roles/discover.md +1 -0
  40. package/library/roles/incident.md +1 -0
  41. package/library/roles/migrate.md +1 -0
  42. package/library/roles/perf.md +1 -0
  43. package/library/roles/plan.md +1 -0
  44. package/library/roles/refactor.md +1 -0
  45. package/library/roles/review.md +1 -0
  46. package/library/roles/security-review.md +1 -0
  47. package/library/roles/upgrade.md +1 -0
  48. package/library/skills/accessibility.md +16 -0
  49. package/library/skills/ci-infra-gotchas.md +12 -0
  50. package/library/skills/perf-method.md +10 -0
  51. package/library/skills/secure-coding.md +18 -0
  52. package/library/skills/testing-checklist.md +16 -0
  53. package/library/skills/threat-modeling.md +10 -0
  54. package/package.json +12 -17
  55. package/profiles/claude.json +21 -0
  56. package/profiles/copilot.json +5 -0
  57. package/rules/digest.md +40 -0
  58. package/scripts/check-links.mjs +65 -76
  59. package/scripts/lib/advisor.mjs +207 -0
  60. package/scripts/lib/check.mjs +165 -0
  61. package/scripts/lib/copilot-workflow.mjs +41 -0
  62. package/scripts/lib/doctor.mjs +91 -0
  63. package/scripts/lib/gates.mjs +69 -0
  64. package/scripts/lib/git-tree.mjs +201 -0
  65. package/scripts/lib/init.mjs +23 -0
  66. package/scripts/lib/ledger.mjs +38 -0
  67. package/scripts/lib/mcp-project-root.mjs +63 -67
  68. package/scripts/lib/migrate.mjs +73 -0
  69. package/scripts/lib/path-facts.mjs +2 -2
  70. package/scripts/lib/path-safety.mjs +6 -134
  71. package/scripts/lib/plan.mjs +69 -0
  72. package/scripts/lib/policy.mjs +103 -0
  73. package/scripts/lib/pr.mjs +28 -0
  74. package/scripts/lib/prompt.mjs +72 -0
  75. package/scripts/lib/quality/clones.mjs +76 -0
  76. package/scripts/lib/quality/css.mjs +43 -0
  77. package/scripts/lib/quality/gate.mjs +230 -0
  78. package/scripts/lib/quality/limits.mjs +73 -0
  79. package/scripts/lib/quality/metrics.mjs +159 -0
  80. package/scripts/lib/quality/parse.mjs +73 -0
  81. package/scripts/lib/quality/repo.mjs +69 -0
  82. package/scripts/lib/quality/run.mjs +38 -0
  83. package/scripts/lib/reviews.mjs +132 -0
  84. package/scripts/lib/routes.mjs +108 -0
  85. package/scripts/lib/setup.mjs +34 -0
  86. package/scripts/lib/shards.mjs +166 -0
  87. package/scripts/lib/signals.mjs +110 -0
  88. package/scripts/lib/state.mjs +42 -0
  89. package/scripts/lib/tiers.mjs +42 -0
  90. package/scripts/lib/update-notice.mjs +48 -0
  91. package/scripts/lib/views.mjs +62 -0
  92. package/scripts/lib/workflows.mjs +56 -0
  93. package/scripts/somi-mcp.mjs +181 -323
  94. package/scripts/somi.mjs +208 -0
  95. package/scripts/vendor/tree-sitter/LICENSE.vscode-tree-sitter-wasm +21 -0
  96. package/scripts/vendor/tree-sitter/LICENSE.web-tree-sitter +21 -0
  97. package/scripts/vendor/tree-sitter/cgmanifest.vscode-tree-sitter-wasm.json +16 -0
  98. package/scripts/vendor/tree-sitter/manifest.json +59 -0
  99. package/scripts/vendor/tree-sitter/package.json +3 -0
  100. package/scripts/vendor/tree-sitter/tree-sitter-css.wasm +0 -0
  101. package/scripts/vendor/tree-sitter/tree-sitter-javascript.wasm +0 -0
  102. package/scripts/vendor/tree-sitter/tree-sitter-tsx.wasm +0 -0
  103. package/scripts/vendor/tree-sitter/tree-sitter-typescript.wasm +0 -0
  104. package/scripts/vendor/tree-sitter/web-tree-sitter.js +4081 -0
  105. package/scripts/vendor/tree-sitter/web-tree-sitter.wasm +0 -0
  106. package/skills/somi-expertise/SKILL.md +6 -0
  107. package/workflows/deliver-stages.js +81 -0
  108. package/.claude/settings.json +0 -131
  109. package/agents/somi-architecture-reviewer.md +0 -101
  110. package/agents/somi-atlas.md +0 -100
  111. package/agents/somi-coder.md +0 -60
  112. package/agents/somi-designer.md +0 -36
  113. package/agents/somi-discovery-analyst.md +0 -57
  114. package/agents/somi-flow.md +0 -47
  115. package/agents/somi-general.md +0 -36
  116. package/agents/somi-impact.md +0 -95
  117. package/agents/somi-incident.md +0 -94
  118. package/agents/somi-plan-reviewer.md +0 -68
  119. package/agents/somi-planner.md +0 -57
  120. package/agents/somi-pr.md +0 -99
  121. package/agents/somi-refactor-designer.md +0 -81
  122. package/agents/somi-refactorer.md +0 -99
  123. package/agents/somi-sdlc-reviewer.md +0 -67
  124. package/agents/somi-test-strategist.md +0 -87
  125. package/commands/adopt.md +0 -14
  126. package/commands/architecture-review.md +0 -19
  127. package/commands/atlas.md +0 -19
  128. package/commands/code-loop.md +0 -19
  129. package/commands/code-parallel.md +0 -19
  130. package/commands/code.md +0 -19
  131. package/commands/debug.md +0 -19
  132. package/commands/design.md +0 -19
  133. package/commands/discover.md +0 -19
  134. package/commands/impact.md +0 -19
  135. package/commands/incident.md +0 -19
  136. package/commands/plan-loop.md +0 -19
  137. package/commands/plan.md +0 -19
  138. package/commands/pr.md +0 -19
  139. package/commands/refactor-design.md +0 -19
  140. package/commands/refactor.md +0 -19
  141. package/commands/release-readiness.md +0 -19
  142. package/commands/review-panel.md +0 -19
  143. package/commands/review.md +0 -19
  144. package/commands/security-review.md +0 -19
  145. package/commands/ship-loop.md +0 -19
  146. package/commands/ship.md +0 -19
  147. package/commands/test-strategy.md +0 -19
  148. package/commands/upgrade.md +0 -19
  149. package/examples/README.md +0 -19
  150. package/examples/code-review-example.md +0 -88
  151. package/examples/discovery-example.md +0 -200
  152. package/examples/feature-plan-example.md +0 -377
  153. package/examples/full-pipeline-example.md +0 -188
  154. package/examples/sample-consumer/.claude/settings.json +0 -29
  155. package/examples/sample-consumer/CLAUDE.md +0 -78
  156. package/examples/sample-consumer/README.md +0 -102
  157. package/hooks/post-tool/lint-changed-files.mjs +0 -209
  158. package/hooks/pre-tool/guard-cost-lowering.mjs +0 -192
  159. package/hooks/session-start/detect-repo-instructions.mjs +0 -287
  160. package/hooks/session-start/ensure-default-config.mjs +0 -113
  161. package/hooks/user-prompt-submit/inject-workflow-context.mjs +0 -580
  162. package/rules/00-priorities.md +0 -48
  163. package/rules/10-solid.md +0 -87
  164. package/rules/20-clean-code.md +0 -62
  165. package/rules/30-security-owasp.md +0 -83
  166. package/rules/40-engineering-practices.md +0 -65
  167. package/rules/50-collaboration.md +0 -114
  168. package/rules/99-overrides.md +0 -52
  169. package/rules/CLAUDE.md +0 -200
  170. package/scripts/check-session-artefacts.mjs +0 -149
  171. package/scripts/check-size-budget.mjs +0 -137
  172. package/scripts/generate-digest.mjs +0 -176
  173. package/scripts/lib/agent-info.mjs +0 -85
  174. package/scripts/lib/agent-registry.mjs +0 -92
  175. package/scripts/lib/cost-ceiling.mjs +0 -328
  176. package/scripts/lib/cost-config-edit.mjs +0 -102
  177. package/scripts/lib/cost-config.mjs +0 -64
  178. package/scripts/lib/cost-defaults.mjs +0 -53
  179. package/scripts/lib/cost-lowering.mjs +0 -89
  180. package/scripts/lib/cost-model.mjs +0 -110
  181. package/scripts/lib/dispatch-resolver.mjs +0 -243
  182. package/scripts/lib/escalation-facts.mjs +0 -146
  183. package/scripts/lib/escalation.mjs +0 -129
  184. package/scripts/lib/findings-ledger.mjs +0 -241
  185. package/scripts/lib/install-text.mjs +0 -97
  186. package/scripts/lib/loop-caps.mjs +0 -140
  187. package/scripts/lib/loop-diff.mjs +0 -38
  188. package/scripts/lib/loop-dispatch.mjs +0 -19
  189. package/scripts/lib/loop-engine.mjs +0 -227
  190. package/scripts/lib/loop-escalate.mjs +0 -49
  191. package/scripts/lib/loop-exit.mjs +0 -47
  192. package/scripts/lib/loop-notes-compact.mjs +0 -72
  193. package/scripts/lib/loop-notes.mjs +0 -282
  194. package/scripts/lib/loop-review.mjs +0 -395
  195. package/scripts/lib/loop-state.mjs +0 -44
  196. package/scripts/lib/loop-step-close.mjs +0 -75
  197. package/scripts/lib/loop-step-kit.mjs +0 -179
  198. package/scripts/lib/loop-step-review.mjs +0 -140
  199. package/scripts/lib/loop-step-tool.mjs +0 -89
  200. package/scripts/lib/loop-step.mjs +0 -303
  201. package/scripts/lib/run-budget.mjs +0 -28
  202. package/scripts/lib/run-card.mjs +0 -73
  203. package/scripts/lib/size-tier.mjs +0 -184
  204. package/scripts/lib/tier-record.mjs +0 -82
  205. package/scripts/size-budget-overrides.json +0 -58
  206. package/scripts/somi-card.mjs +0 -39
  207. package/scripts/somi-check.mjs +0 -237
  208. package/scripts/somi-config.mjs +0 -421
  209. package/scripts/somi-dispatch.mjs +0 -141
  210. package/scripts/somi-findings.mjs +0 -100
  211. package/scripts/somi-loop.mjs +0 -139
  212. package/scripts/somi-tier.mjs +0 -393
  213. package/scripts/validate.sh +0 -653
  214. package/skills/api-design/SKILL.md +0 -147
  215. package/skills/clean-code/SKILL.md +0 -142
  216. package/skills/flow-adopt/SKILL.md +0 -92
  217. package/skills/flow-architecture-review/SKILL.md +0 -94
  218. package/skills/flow-atlas/SKILL.md +0 -34
  219. package/skills/flow-code/SKILL.md +0 -167
  220. package/skills/flow-code-loop/SKILL.md +0 -263
  221. package/skills/flow-code-parallel/SKILL.md +0 -160
  222. package/skills/flow-debug/SKILL.md +0 -141
  223. package/skills/flow-design/SKILL.md +0 -170
  224. package/skills/flow-discover/SKILL.md +0 -204
  225. package/skills/flow-impact/SKILL.md +0 -35
  226. package/skills/flow-incident/SKILL.md +0 -49
  227. package/skills/flow-plan/SKILL.md +0 -254
  228. package/skills/flow-plan-loop/SKILL.md +0 -254
  229. package/skills/flow-pr/SKILL.md +0 -34
  230. package/skills/flow-refactor/SKILL.md +0 -58
  231. package/skills/flow-refactor-design/SKILL.md +0 -97
  232. package/skills/flow-release-readiness/SKILL.md +0 -82
  233. package/skills/flow-review/SKILL.md +0 -193
  234. package/skills/flow-review-panel/SKILL.md +0 -154
  235. package/skills/flow-security-review/SKILL.md +0 -83
  236. package/skills/flow-ship/SKILL.md +0 -125
  237. package/skills/flow-ship-loop/SKILL.md +0 -274
  238. package/skills/flow-somi-config/SKILL.md +0 -142
  239. package/skills/flow-status/SKILL.md +0 -43
  240. package/skills/flow-test-strategy/SKILL.md +0 -83
  241. package/skills/flow-upgrade/SKILL.md +0 -82
  242. package/skills/market-research/SKILL.md +0 -125
  243. package/skills/observability/SKILL.md +0 -133
  244. package/skills/owasp-defense/SKILL.md +0 -141
  245. package/skills/plan-review/SKILL.md +0 -83
  246. package/skills/reasoning-craft/SKILL.md +0 -213
  247. package/skills/requirements-engineering/SKILL.md +0 -137
  248. package/skills/role-coder/SKILL.md +0 -247
  249. package/skills/role-designer/SKILL.md +0 -172
  250. package/skills/role-discovery-analyst/SKILL.md +0 -288
  251. package/skills/role-planner/SKILL.md +0 -353
  252. package/skills/role-reviewer/SKILL.md +0 -218
  253. package/skills/rules/SKILL.md +0 -47
  254. package/skills/sdlc-process/SKILL.md +0 -74
  255. package/skills/solid-principles/SKILL.md +0 -143
  256. package/skills/somi-checkpoint/SKILL.md +0 -95
  257. package/skills/somi-dispatch/SKILL.md +0 -259
  258. package/skills/somi-routing/SKILL.md +0 -158
  259. package/skills/testing-playbook/SKILL.md +0 -133
  260. package/skills/threat-modeling/SKILL.md +0 -117
  261. package/templates/ADR.md.tmpl +0 -73
  262. package/templates/ATLAS.md.tmpl +0 -75
  263. package/templates/BRD.md.tmpl +0 -68
  264. package/templates/BRIEF.md.tmpl +0 -119
  265. package/templates/CONTEXT.md.tmpl +0 -74
  266. package/templates/DECISIONS.md.tmpl +0 -105
  267. package/templates/DESIGN.md.tmpl +0 -83
  268. package/templates/DIARY.md.tmpl +0 -70
  269. package/templates/DOD.md.tmpl +0 -90
  270. package/templates/FRD.md.tmpl +0 -64
  271. package/templates/PHASE.md.tmpl +0 -80
  272. package/templates/PROGRESS.md.tmpl +0 -63
  273. package/templates/RCA.md.tmpl +0 -53
  274. package/templates/RD-README.md.tmpl +0 -70
  275. package/templates/RESEARCH.md.tmpl +0 -96
  276. package/templates/REVIEW.md.tmpl +0 -82
  277. package/templates/SDD.md.tmpl +0 -82
  278. package/templates/SOMI-README.md.tmpl +0 -83
  279. package/templates/SPEC.md.tmpl +0 -123
  280. package/templates/SRS.md.tmpl +0 -85
  281. package/templates/TDD.md.tmpl +0 -77
  282. package/tests/hooks/cases/audit-log.json +0 -21
  283. package/tests/hooks/cases/block-dangerous-bash.json +0 -166
  284. package/tests/hooks/cases/block-secret-writes.json +0 -140
  285. package/tests/hooks/cases/detect-repo-instructions.json +0 -105
  286. package/tests/hooks/cases/gate-dep-install.json +0 -42
  287. package/tests/hooks/cases/guard-protected-paths.json +0 -222
  288. package/tests/hooks/cases/inject-workflow-context.json +0 -239
  289. package/tests/hooks/cases/lint-changed-files.json +0 -120
  290. package/tests/hooks/run.sh +0 -392
  291. package/tests/scripts/agent-model-frontmatter.sh +0 -38
  292. package/tests/scripts/agent-names.sh +0 -77
  293. package/tests/scripts/check-frontmatter.sh +0 -37
  294. package/tests/scripts/check-links.sh +0 -105
  295. package/tests/scripts/check-session-artefacts.sh +0 -60
  296. package/tests/scripts/check-size-budget.sh +0 -71
  297. package/tests/scripts/checkpoint-gate.sh +0 -131
  298. package/tests/scripts/convergence-runner.sh +0 -1514
  299. package/tests/scripts/cost-ceiling.sh +0 -255
  300. package/tests/scripts/cost-defaults.sh +0 -130
  301. package/tests/scripts/cost-hardcap.sh +0 -338
  302. package/tests/scripts/cost-lowering.sh +0 -261
  303. package/tests/scripts/cost-model.sh +0 -196
  304. package/tests/scripts/dispatch-guard.sh +0 -108
  305. package/tests/scripts/dispatch-line-gate.sh +0 -61
  306. package/tests/scripts/dispatch-reference-gate.sh +0 -173
  307. package/tests/scripts/ensure-default-config.sh +0 -162
  308. package/tests/scripts/escalation.sh +0 -409
  309. package/tests/scripts/eval-runner.sh +0 -3692
  310. package/tests/scripts/evals-packaging.sh +0 -224
  311. package/tests/scripts/fact-sheet.sh +0 -296
  312. package/tests/scripts/fixtures/legacy-shard-no-schema.json +0 -50
  313. package/tests/scripts/fixtures/mock-stdin-read-throw.cjs +0 -18
  314. package/tests/scripts/fixtures/size-tier-cases.json +0 -87
  315. package/tests/scripts/generate-digest.sh +0 -180
  316. package/tests/scripts/global-config.sh +0 -167
  317. package/tests/scripts/goldens/loop-state-breach.json +0 -1
  318. package/tests/scripts/goldens/loop-state-done.json +0 -1
  319. package/tests/scripts/goldens/somi-findings.json +0 -336
  320. package/tests/scripts/goldens/somi-loop.json +0 -168
  321. package/tests/scripts/lib/adr-shape.mjs +0 -41
  322. package/tests/scripts/lib/agent-registry-tests.mjs +0 -95
  323. package/tests/scripts/lib/brief-only-guard.mjs +0 -27
  324. package/tests/scripts/lib/checkpoint-gate.mjs +0 -91
  325. package/tests/scripts/lib/digest-marker-coupling.mjs +0 -52
  326. package/tests/scripts/lib/dispatch-reference-gate.mjs +0 -121
  327. package/tests/scripts/lib/escalation-facts-tests.mjs +0 -140
  328. package/tests/scripts/lib/escalation-tests.mjs +0 -154
  329. package/tests/scripts/lib/findings-ledger-tests.mjs +0 -118
  330. package/tests/scripts/lib/loop-engine-tests.mjs +0 -287
  331. package/tests/scripts/lib/loop-escalate-tests.mjs +0 -356
  332. package/tests/scripts/lib/loop-flow-gate.mjs +0 -173
  333. package/tests/scripts/lib/loop-notes-tests.mjs +0 -384
  334. package/tests/scripts/lib/loop-step-cli-tests.mjs +0 -156
  335. package/tests/scripts/lib/loop-step-close-tests.mjs +0 -351
  336. package/tests/scripts/lib/loop-step-lenient-tests.mjs +0 -114
  337. package/tests/scripts/lib/loop-step-state-tests.mjs +0 -127
  338. package/tests/scripts/lib/loop-step-tests.mjs +0 -499
  339. package/tests/scripts/lib/loop-step-unwritten-tests.mjs +0 -55
  340. package/tests/scripts/lib/multipass-dependence.mjs +0 -192
  341. package/tests/scripts/lib/multipass-source-identity.mjs +0 -243
  342. package/tests/scripts/lib/path-facts-tests.mjs +0 -198
  343. package/tests/scripts/lib/path-safety-tests.mjs +0 -201
  344. package/tests/scripts/lib/reference-pair.mjs +0 -61
  345. package/tests/scripts/lib/retirement-gate.mjs +0 -172
  346. package/tests/scripts/lib/run-suites.mjs +0 -139
  347. package/tests/scripts/lib/shell-embedded-js.mjs +0 -47
  348. package/tests/scripts/lib/ship-loop-sizing-guard.mjs +0 -52
  349. package/tests/scripts/lib/site-roadmap-gate.mjs +0 -64
  350. package/tests/scripts/lib/size-tier-drift.mjs +0 -74
  351. package/tests/scripts/lib/sizing-score-tests.mjs +0 -210
  352. package/tests/scripts/lib/sizing-set-tests.mjs +0 -131
  353. package/tests/scripts/lib/somi-mcp-client.mjs +0 -102
  354. package/tests/scripts/lib/somi-mcp-config-tests.mjs +0 -92
  355. package/tests/scripts/lib/somi-mcp-loop-tests.mjs +0 -226
  356. package/tests/scripts/lib/somi-mcp-tests.mjs +0 -491
  357. package/tests/scripts/lib/somi-mcp-tier-tests.mjs +0 -64
  358. package/tests/scripts/lib/somi-mcp-tool-schema.mjs +0 -38
  359. package/tests/scripts/loop-engine.sh +0 -22
  360. package/tests/scripts/loop-flow-gate.sh +0 -11
  361. package/tests/scripts/retirement-gate.sh +0 -306
  362. package/tests/scripts/review-panel-seats.sh +0 -32
  363. package/tests/scripts/run-card.sh +0 -57
  364. package/tests/scripts/run-suites.sh +0 -74
  365. package/tests/scripts/run.sh +0 -689
  366. package/tests/scripts/site-roadmap-gate.sh +0 -76
  367. package/tests/scripts/size-tier.sh +0 -562
  368. package/tests/scripts/somi-agent-dispatch-contract.sh +0 -224
  369. package/tests/scripts/somi-config.sh +0 -286
  370. package/tests/scripts/somi-dispatch.sh +0 -465
  371. package/tests/scripts/somi-mcp.sh +0 -15
  372. package/tests/scripts/suite-plan.json +0 -20
Binary file
@@ -12,9 +12,14 @@
12
12
  "source": "url",
13
13
  "url": "https://github.com/skathio/somi.git"
14
14
  },
15
- "description": "Multi-agent engineering workflow: discover/design → plan → code → review. Each agent has a default cost tier and a per-session ceiling caps it; SOLID, OWASP and clean-code guardrails.",
16
- "version": "4.1.1",
17
- "tags": ["workflow", "agents", "review", "security"],
15
+ "description": "A workflow plugin for coding agents: say what you want or pass a ticket, and it picks the right workflow and keeps the cost down, while your agent stays in charge.",
16
+ "version": "5.0.0",
17
+ "tags": [
18
+ "workflow",
19
+ "agents",
20
+ "review",
21
+ "security"
22
+ ],
18
23
  "homepage": "https://github.com/skathio/somi"
19
24
  }
20
25
  ]
@@ -1,18 +1,15 @@
1
1
  {
2
2
  "name": "somi",
3
- "version": "4.1.1",
3
+ "version": "5.0.0",
4
4
  "displayName": "SoMi",
5
- "description": "Multi-agent engineering workflow system: plan, code, review — with SOLID/OWASP guardrails, deterministic hooks, and a global ruleset.",
5
+ "description": "A workflow plugin for coding agents: say what you want or pass a ticket, and it picks the right workflow and keeps the cost down, while your agent stays in charge.",
6
6
  "keywords": [
7
7
  "workflow",
8
- "agents",
9
- "planning",
10
- "code-review",
8
+ "review",
11
9
  "security",
12
- "owasp",
13
- "solid",
14
- "clean-code",
15
- "engineering"
10
+ "sandbox",
11
+ "claude-code",
12
+ "copilot"
16
13
  ],
17
14
  "author": {
18
15
  "name": "Skathi",
@@ -24,7 +21,9 @@
24
21
  "mcpServers": {
25
22
  "somi": {
26
23
  "command": "node",
27
- "args": ["${CLAUDE_PLUGIN_ROOT}/scripts/somi-mcp.mjs"]
24
+ "args": [
25
+ "${CLAUDE_PLUGIN_ROOT}/scripts/somi-mcp.mjs"
26
+ ]
28
27
  }
29
28
  }
30
29
  }
@@ -1,18 +1,15 @@
1
1
  {
2
2
  "name": "somi",
3
3
  "displayName": "SoMi",
4
- "version": "4.1.1",
5
- "description": "Multi-agent engineering workflow system: plan, code, review — with SOLID/OWASP guardrails, deterministic hooks, and a global ruleset.",
4
+ "version": "5.0.0",
5
+ "description": "A workflow plugin for coding agents: say what you want or pass a ticket, and it picks the right workflow and keeps the cost down, while your agent stays in charge.",
6
6
  "keywords": [
7
7
  "workflow",
8
- "agents",
9
- "planning",
10
- "code-review",
8
+ "review",
11
9
  "security",
12
- "owasp",
13
- "solid",
14
- "clean-code",
15
- "engineering"
10
+ "sandbox",
11
+ "claude-code",
12
+ "copilot"
16
13
  ],
17
14
  "author": {
18
15
  "name": "Skathi",
@@ -25,37 +22,32 @@
25
22
  "components": {
26
23
  "agents": "./agents",
27
24
  "commands": "./commands",
28
- "skills": "./skills",
29
- "hooks": "./hooks"
25
+ "skills": "./skills"
30
26
  },
31
- "rules": "./rules/CLAUDE.md",
32
27
  "commands": [
33
- { "name": "discover", "description": "Pre-development discovery (cost: high): research competition + author the requirements & design foundation (BRD/SRS/FRD/SDD/TDD) + a dense brief.md for a new product. Feeds /plan." },
34
- { "name": "design", "description": "Feature/user-story design: settle a brownfield feature's architecture against the codebase (the designer agent runs at high) and compile the brief.md that planning and coding execute against. Feeds /plan." },
35
- { "name": "atlas", "description": "Build or refresh the Repo Atlas (.somi/atlas.md): one deep codebase read by the atlas agent (high) — module map, dependency rules, conventions digest, hotspots, test topology — SHA-stamped and amortized across every later /design, cold /plan, /refactor-design, and /impact." },
36
- { "name": "plan", "description": "Sequence the design (brief) into a structured engineering plan (phases, risks, DoD, test strategy)" },
37
- { "name": "plan-loop", "description": "Bounded plan → review → revise loop. Stops on approve, cap, divergence, or user stop." },
38
- { "name": "code", "description": "Implement against an approved plan with senior-engineer judgment" },
39
- { "name": "debug", "description": "Debug a bug whose cause isn't isolated: reproduce first (failing test as the gate), isolate under a bounded hypothesis budget, fix under /code-loop, keep the repro as the regression guard. Writes rca.md." },
40
- { "name": "code-loop", "description": "Bounded code → review → fix loop on a single iteration. Stops on approve, cap, diff cap, circuit breaker, or user stop." },
41
- { "name": "code-parallel", "description": "Fan out provably-independent iterations into isolated git worktrees, then integrate them sequentially behind a gate. Falls back to sequential /code-loop on hosts without worktrees/concurrent sub-agents." },
42
- { "name": "review", "description": "Strict, fresh-context code / plan / design review with severity-graded findings (use `plan <slug>` or `design <slug>`)" },
43
- { "name": "review-panel", "description": "Parallel multi-lens review: seats reviewer + security/architecture/test lenses as the diff warrants, merges and de-duplicates findings into one verdict. Runs sequentially on Copilot (no concurrent sub-agents)." },
44
- { "name": "ship", "description": "Full plan → code → review pipeline against a problem statement. Code iterations run under /code-loop's caps." },
45
- { "name": "ship-loop", "description": "Continuous design→execution pipeline: optional design front-load → [single gate at the brief handoff] → /plan-loop → /code-loop, run under bounded caps." },
46
- { "name": "security-review", "description": "Security-focused review: auth, crypto, input validation, injection risks" },
47
- { "name": "architecture-review", "description": "Architectural review: boundaries, contracts, dependency direction, reversibility" },
48
- { "name": "test-strategy", "description": "Test-strategy review: risk-driven coverage, level selection, mock policy, determinism" },
49
- { "name": "refactor", "description": "Surgical, behavior-preserving refactor of a named smell that fits one safe diff" },
50
- { "name": "refactor-design", "description": "Scope design for a refactor too big for one diff (the refactor-designer agent runs at high): destination shape, seam/risk map, brief.md for /plan-loop → /code-loop" },
51
- { "name": "impact", "description": "Read-only change-impact analysis: blast radius (callers, contracts, test coverage, migration surface) before committing to /design or /plan. Sometimes the honest output is 'reconsider'." },
52
- { "name": "adopt", "description": "One-time SoMi onboarding for an existing repo: builds the Atlas, confirms detected conventions into 99-overrides, produces a gap report, suggests a calibration work item." },
53
- { "name": "upgrade", "description": "Dependency upgrade validation: cited research into changelog/breaking-changes/CVE by the discovery-analyst agent (high), scans actual API usage, compiles a mini-brief, then migrates under /code-loop. Integrates with the dep-install gate." },
54
- { "name": "release-readiness", "description": "Pre-release gate: deterministic checklist over the artifacts (done? open Blockers? DoD? rollback real?) + one fresh-eyes review of the integration surface. Verdict + draft release notes." },
55
- { "name": "incident", "description": "The sanctioned emergency lane: mitigate fast (flag/revert/scoped patch) with hooks still enforcing, then MANDATORY postmortem note + seeded /debug follow-up. Less ceremony now, enforced accounting after." },
56
- { "name": "pr", "description": "Compose a PR title + description from a work item's .somi/ artifacts (spec, decisions, reviews, diary) and optionally open it via gh after confirmation." }
57
- ],
58
- "compatibility": {
59
- "copilot": ">=1.0.0"
60
- }
28
+ {
29
+ "name": "somi-config",
30
+ "description": "Show and change the models each tier uses, the quality limits, and check the setup."
31
+ },
32
+ {
33
+ "name": "somi-deliver",
34
+ "description": "Run a piece of work as SoMi's staged workflow: scout, build, verify and review, each on its cost tier, through to the end."
35
+ },
36
+ {
37
+ "name": "somi-quality",
38
+ "description": "Check code against SoMi's quality limits: this branch by default, or the whole codebase."
39
+ },
40
+ {
41
+ "name": "somi-review",
42
+ "description": "Review the current changes or a named diff once."
43
+ },
44
+ {
45
+ "name": "somi-status",
46
+ "description": "Show open work, findings and decisions."
47
+ },
48
+ {
49
+ "name": "somi",
50
+ "description": "Give SoMi any request or ticket, and it routes the work to the right workflow."
51
+ }
52
+ ]
61
53
  }
@@ -10,9 +10,14 @@
10
10
  {
11
11
  "name": "somi",
12
12
  "source": "github:skathio/somi",
13
- "description": "Multi-agent engineering workflow: discover/design → plan → code → review. Each agent has a default cost tier and a per-session ceiling caps it; SOLID, OWASP and clean-code guardrails.",
14
- "version": "4.1.1",
15
- "tags": ["workflow", "agents", "review", "security"],
13
+ "description": "A workflow plugin for coding agents: say what you want or pass a ticket, and it picks the right workflow and keeps the cost down, while your agent stays in charge.",
14
+ "version": "5.0.0",
15
+ "tags": [
16
+ "workflow",
17
+ "agents",
18
+ "review",
19
+ "security"
20
+ ],
16
21
  "homepage": "https://github.com/skathio/somi"
17
22
  }
18
23
  ]
package/README.md CHANGED
@@ -1,278 +1,133 @@
1
1
  # SoMi
2
2
 
3
- > An opinionated, reusable multi-agent engineering workflow system for Claude Code and GitHub Copilot.
4
-
5
- [![npm](https://img.shields.io/npm/v/@skathio/somi?logo=npm)](https://www.npmjs.com/package/@skathio/somi)
6
-
7
- **Overview page:** <https://skathio.github.io/somi/>: the roadmap, the workflow and the cost system on
8
- one page.
9
-
10
- The latest published version is on [npm](https://www.npmjs.com/package/@skathio/somi) and in the
11
- [GitHub Releases](https://github.com/skathio/somi/releases); see [CHANGELOG.md](CHANGELOG.md) for
12
- release notes.
13
-
14
- SoMi gives engineering teams a shared, version-controlled "operating system" for working with Claude:
15
- three first-class build workflows — **plan → code → review** — plus an upstream **discovery** workflow
16
- that turns a raw product idea into a research-grounded requirements & design foundation. All backed by
17
- specialised subagents, deterministic guardrail hooks, composable skills, and a global ruleset that
18
- enforces SOLID, clean code, and OWASP defenses.
19
-
20
- It is designed to be:
21
-
22
- - **Reusable** across many repositories and teams
23
- - **Installable** as a Claude Code plugin (via marketplace or npm) or as a GitHub Copilot chat extension
24
- - **Opinionated but extensible** — strong defaults, clean overrides
25
- - **Deterministic where possible** (hooks) and **judgment-heavy where needed** (agents)
26
-
27
- ---
28
-
29
- ## The workflows
30
-
31
- | Command | Agent cost | Agent | Purpose |
32
- |---------------|--------|---------------------|------------------------------------------------------------------------------------------|
33
- | `/discover` | high | `somi-discovery-analyst` | Research the competition, then author the requirements & design foundation (BRD/SRS/FRD/SDD/TDD) + a `brief.md` for a new product |
34
- | `/design` | high | `somi-designer` | Settle a brownfield feature's architecture against the codebase; compile the `brief.md` the cheap tier executes against |
35
- | `/plan` | medium | `somi-planner` | Sequence the design (brief) into phases, risks, slices, DoD, test & rollout strategy |
36
- | `/code` | medium | `somi-coder` | Execute against an approved plan + brief with senior-level design judgment |
37
- | `/debug` | medium | `somi-coder` | Reproduce first, isolate under a bounded hypothesis budget, fix under `/code-loop` (a `cost: high` hatch is available if isolation escalates), keep the repro test as the regression guard; writes a one-page `rca.md` |
38
- | `/review` | high | `somi-reviewer` | Strict, skeptical, **fresh-context** review of code / plans / designs with severity-graded findings |
39
- | `/ship` | per agent | planner+coder+reviewer | Full plan → code → review pipeline (optionally preceded by a `high`-tier front-load), gated at every stage |
40
-
41
- **Cost tiers in practice.** Default tiers belong to **agents**, not commands —
42
- a tier sizes an agent instance being spawned, and a command has none, running on
43
- whatever model the session is already using — so the tier above is the tier of the agent that
44
- command Tasks (the table is `scripts/lib/cost-defaults.mjs`; `cost.agents` overrides it). The **`cost: high`** tier front-loads expensive reasoning — research, design,
45
- decisions, complexity mapping, fresh-eyes review — into a dense, bounded `brief.md`. The
46
- **`cost: medium`** tier executes against that brief *without re-researching*, so the high-volume
47
- work (plan detail, iterative coding) runs cheaply. `/discover` (new product) and `/design`
48
- (brownfield feature) are the high-cost front-loads that feed `/plan`; `/ship-loop` runs the whole
49
- pipeline continuously, gating once at the brief handoff (before planning consumes the brief). Supporting agents invoked by
50
- handoff, at whichever default tier the table gives them: `somi-security-reviewer`,
51
- `somi-architecture-reviewer`, `somi-test-strategist`, `somi-refactor-designer` — see
52
- [`docs/AGENTS.md`](docs/AGENTS.md#cost-tiering) for the exact shape per agent.
53
-
54
- ---
3
+ Tell SoMi what you want, in plain words or as a ticket, and it picks the right workflow and keeps the cost down, on Claude Code and GitHub Copilot CLI. You keep talking to your agent the whole time: it can read, answer and change its mind, and SoMi advises instead of taking over.
55
4
 
56
- ## Install
57
-
58
- > **Runtime**: a current Node (LTS) on `PATH` — no `bash`, no `jq` required. Both Claude Code and
59
- > GitHub Copilot already bundle Node, so most installs need nothing extra; the Node runtime itself
60
- > is Windows-native (no bash/jq to install). The path guards' Windows coverage is tested on Linux
61
- > only: see [`docs/HOOKS.md`](docs/HOOKS.md).
5
+ > **5.0, measured.** On the pre-registered [benchmark](docs/BENCHMARK.md) (Sonnet, 16 tasks, 96 draws each), SoMi solved 90 draws against a bare agent's 72, met the quality limits on all 96 against 84, and cost 1.28 times as much per solved task, under the 1.5 the benchmark allows. On those single-change tasks the agent rarely routes, so the gain comes from the rules, the quality gate and the review; routing has not been measured on larger work yet.
62
6
 
63
- ### Option 1 — Claude Code plugin (marketplace)
7
+ ## How it works
64
8
 
65
9
  ```text
66
- # Add the SoMi marketplace and install the plugin:
67
- /plugin marketplace add https://github.com/skathio/somi
68
- /plugin install somi@somi
10
+ you talk to one agent, on the medium tier, the same as a bare agent
11
+ -> a question, a follow-up, a change of mind: it just answers
12
+ -> a small, clear change: it does it, as a bare agent would
13
+ -> a ticket, large work, or a request that fits no obvious workflow: it asks somi_route once, and gets the
14
+ workflow's steps: each one's tier, whether it runs here or on a subagent, and its brief
15
+ -> large work: it does it too, on medium, and tells you that /somi-deliver runs it in stages
16
+ -> /somi-deliver <work or ticket>: a scout, a build that steps up a tier if the checks fail, the checks, and
17
+ the reviews the diff needs, each on its tier, run in code through to the end
18
+ -> the diff touches a security sink: the security reviewer runs on high, and every fix stays here, on medium
19
+ -> work that needs more, such as design: it goes up to a worker on the high tier
20
+ -> a turn that changed code ends: the quality gate runs, anything over a limit goes back to be fixed,
21
+ and the diff decides if a review is due
22
+ -> somi_pr: refuses clean text for a change that needed a review and has none, or that fails the quality gate
69
23
  ```
70
24
 
71
- Updates flow through `/plugin update somi`.
25
+ SoMi keeps no workflow state, so nothing can be "still open" and nothing refuses your next request. A bare agent runs everything on medium. SoMi runs the conversation there too, and code is written on medium: on the low tier it broke rules and fell below the quality bar, and the fixes cost more than the low tier saved. The low tier does what needs no judgement, such as finding the files and running the checks. The deterministic parts are done by SoMi's tools, not left to the model: which reviewers a diff needs, the briefs workers and reviewers get, the plan file and the pull request text.
72
26
 
73
- ### Option 2 — npm (Claude Code)
27
+ | | 4.1 | 5.0 |
28
+ |---|---|---|
29
+ | Who is in charge | A workflow's procedure | Your agent, with SoMi advising and building the deterministic parts |
30
+ | When a review runs | Sized before coding | Decided from signals in the real diff when a turn ends, with one reviewer, and checked before the pull request text |
31
+ | Long work | Plan and progress files read by hand | One plan file, a small ledger put back after every compaction, and each milestone routed on its own |
32
+ | Model tiers | A lookup the agent could skip | The conversation on medium, workers and reviewers set by a hook |
33
+ | Listed entries | 91 | 14: 6 commands, 6 agents, one skill and one workflow, with a library behind them |
34
+ | Other plugins | No way in | Shards, connected from `/somi-config` |
74
35
 
75
- ```bash
76
- npm install -g @skathio/somi
77
- ```
36
+ ## Install
78
37
 
79
- Then in Claude Code: `/plugin install somi`.
38
+ On Claude Code:
80
39
 
81
- ### Option 3 — GitHub Copilot (extension marketplace)
40
+ ```text
41
+ /plugin marketplace add https://github.com/skathio/somi
42
+ /plugin install somi@somi
43
+ ```
82
44
 
83
- SoMi is also a GitHub Copilot extension, installable the same way as the Claude Code plugin:
45
+ On GitHub Copilot CLI:
84
46
 
85
- ```text
47
+ ```bash
86
48
  copilot plugin marketplace add https://github.com/skathio/somi
87
49
  copilot plugin install somi@somi
88
50
  ```
89
51
 
90
- Once installed, use `@somi` in GitHub Copilot chat:
52
+ ## Use
91
53
 
92
- ```text
93
- @somi /plan Add per-team rate limiting to the public webhook endpoint
94
- @somi /code rate-limiting-webhooks phase 1, iteration 1
95
- @somi /review rate-limiting-webhooks
96
- ```
97
-
98
- > On GitHub Copilot, select the **`somi`** agent as your session persona: a dispatcher that hands
99
- > each request to the `somi-flow` runner for the matching workflow (or to `somi-general` when none
100
- > fits), so you don't need to know which command to type. See
101
- > [`docs/PLUGIN.md`](docs/PLUGIN.md#github-copilot-extension).
102
-
103
- > **Parity caveat — Copilot is not feature-equivalent to Claude Code.** Three things do **not** carry
104
- > over, because they depend on Claude Code host capabilities Copilot doesn't expose:
105
- >
106
- > - **Of Copilot's surfaces, the guardrail hooks run on Copilot CLI only.** Copilot CLI (checked live on 1.0.103) runs
107
- > SoMi's hooks: SessionStart, the PreToolUse blocks for dangerous bash, secret-writes and protected
108
- > paths, and the audit log; an `ask` verdict becomes a refusal where it cannot prompt. Other Copilot
109
- > surfaces (VS Code Chat) are unverified, so don't count on the hard stops there.
110
- > - **Multi-agent orchestration degrades to sequential.** The loops (`/code-loop`, `/plan-loop`,
111
- > `/ship`) and the parallel commands (`/review-panel`, `/code-parallel`) drive Claude Code
112
- > sub-agents via the Task tool. Where the host can't spawn sub-agents concurrently, these run
113
- > **one lens / one iteration at a time** — same result, no parallelism.
114
- > - **Per-call model binding is not confirmed on every host.** The cost tiers themselves (the
115
- > `low`/`medium`/`high` axis, the session ceiling, the dispatch resolver) are host-agnostic — every
116
- > agent's tier comes from one default table plus `cost.agents`, resolved the same way everywhere it's
117
- > dispatched, whether that's through the `somi` front door or a command typed directly (both
118
- > follow [`skills/somi-dispatch`](skills/somi-dispatch/SKILL.md), the one canonical resolve-then-
119
- > start procedure), including on Copilot. What varies is only whether a *concrete model* can be
120
- > bound per `Task` call:
121
- > confirmed on Claude Code and on VS Code's Copilot; undocumented on Copilot CLI, where the
122
- > host's default model applies, because agents no longer declare a frontmatter `model:`. Where a model can't be
123
- > bound per call, the dispatcher still names the tier it selected and says plainly that its model
124
- > pick could not be applied — the tier decision itself is the same everywhere.
125
- > - **Agents start as the type the host registered.** Claude Code and Copilot CLI both register
126
- > SoMi's agents as `somi:somi-<name>`, and every dispatch starts that real agent. VS Code Copilot
127
- > Chat is not a supported dispatch host: if it refuses the type, SoMi stops and says so instead of
128
- > running a stand-in. See [Agent dispatch](docs/PLUGIN.md#agent-dispatch).
129
- >
130
- > The commands, agents, skills, rules, and templates are shared; **enforcement and concurrency are
131
- > Claude Code features**; cost tiering is shared, with per-call model binding confirmed on Claude
132
- > Code and VS Code and falling back to the host's default model elsewhere. Treat Copilot as
133
- > the portable subset, not a drop-in equal. See [`docs/HOOKS.md`](docs/HOOKS.md) and
134
- > [`docs/PLUGIN.md`](docs/PLUGIN.md).
135
-
136
- ---
137
-
138
- ## What's in the box
54
+ Start with SoMi as the session's agent and just talk to it:
139
55
 
140
- ```
141
- .claude-plugin/ Plugin + marketplace manifests (Claude Code plugin distribution)
142
- agents/ Subagent definitions (planner, coder, reviewer, + support)
143
- commands/ Slash-command entrypoints (/plan, /code, /review, /ship, /debug, ...)
144
- skills/ On-demand expert knowledge packs (OWASP, SOLID, test strategy, ...)
145
- rules/ Global ruleset composed into CLAUDE.md
146
- hooks/ Deterministic guardrails (block dangerous bash, secret writes, ...)
147
- scripts/ Runtime tooling: somi-loop (resumable loop state & caps), somi-findings
148
- (the findings ledger), somi-check (portable working-tree guard, npm bin)
149
- templates/ Artifact templates (BRIEF [design→execution handoff], ATLAS [repo map], DESIGN, RCA,
150
- CONTEXT, SPEC, DECISIONS, PHASE, PROGRESS, DIARY, REVIEW, ADR, DOD;
151
- R&D: RD-README, RESEARCH, BRD, SRS, FRD, SDD, TDD)
152
- tests/ Behavioral fixtures for hooks + end-to-end tests for the runtime scripts
153
- .copilot-extension/ Copilot extension + marketplace manifests (mirrors .claude-plugin/)
154
- examples/ Worked examples + a minimal consuming project
155
- docs/ Full documentation
156
- site/ The overview page (GitHub Pages; not in the npm package)
56
+ ```bash
57
+ claude --agent somi:somi # or: copilot --agent somi:somi
157
58
  ```
158
59
 
159
- When you use SoMi in a project, workflows write their artifacts into a `.somi/` directory
160
- at the project root. Discovery foundations live under `.somi/rd/<slug>/` (research report, BRD, SRS,
161
- FRD, SDD, TDD); plans live under `.somi/plans/<slug>/` (context, spec, decisions, progress, diary,
162
- phases — or a one-page `rca.md` for `/debug` items); reviews live under `.somi/reviews/<slug>/`
163
- (including the machine-readable findings ledger, `findings.json`); the repo-wide map lives at
164
- `.somi/atlas.md` (from `/atlas`); optional committed policy lives at `.somi/config.json`, merged over
165
- your [global config](docs/USAGE.md#the-global-config) —
166
- separate directories, no clutter. See [`docs/WORKFLOWS.md`](docs/WORKFLOWS.md) for the full layout.
60
+ Everything is done from the chat. Ask for a change, a bug fix, a refactor, a plan, a design, a review, an upgrade or the pull request text in plain words, or paste a ticket, and SoMi's agent picks the workflow. Outside SoMi's agent, plain prompts are not routed, and SoMi says so at session start. In a Copilot session already running, `/agent somi` switches to it. Six commands do the rest:
167
61
 
168
- ---
62
+ | Command | What it does |
63
+ |---|---|
64
+ | `/somi <anything>` | Routes anything, the way the agent does with plain words. Use it from another agent. |
65
+ | `/somi-deliver <work or ticket>` | Runs large work as SoMi's staged workflow. Only you can start it. On Copilot, ask `/somi-config` to register it once, and turn on `/experimental`. |
66
+ | `/somi-review` | Reviews the current changes, whether or not the diff calls for it. |
67
+ | `/somi-quality [commit \| repo]` | Checks the code against the quality limits: the branch, one commit, or the whole codebase. |
68
+ | `/somi-status` | Shows the open plan, decisions and findings. |
69
+ | `/somi-config` | Shows and changes the models each tier uses and the quality limits, and checks the setup. |
169
70
 
170
- ## Quick start (after install)
71
+ On Claude Code they also answer to `/somi:somi-review` and so on. On Copilot, SoMi's commands are listed as skills.
171
72
 
172
- For a **brand-new product**, start one step earlier with discovery:
173
-
174
- ```text
175
- > /discover A self-hosted alternative to Calendly for clinics, with HIPAA-aware
176
- scheduling, SMS reminders, and no per-seat pricing.
177
-
178
- # Claude proposes a slug ("clinic-scheduler"), researches competitors and real user
179
- # complaints (cited), pauses on each crossroads (persona, scope, build-vs-integrate,
180
- # expensive-to-reverse architecture), and writes a traceable requirements & design set
181
- # to .somi/rd/clinic-scheduler/ (research report, BRD, SRS, FRD, SDD, TDD). Then run
182
- # /plan clinic-scheduler — the planner consumes that foundation.
183
- ```
73
+ ## Set your tiers
184
74
 
185
- For a **design-heavy feature on an existing repo**, front-load the design (default `high`) so
186
- planning and coding run cheaply against it:
75
+ You choose the models for each environment in `~/.config/somi/config.json`. `main` is the tier your conversation runs on, medium by default. Code is written on medium, in the conversation or in `/somi-deliver`'s build, and work above the conversation's tier goes up to a worker. The low tier only gathers information and runs checks. When the diff shows security signals, the security reviewer runs on high, and any fix stays on `main`. Ask `/somi-config` to change any of it: after `main` changes, it writes `somi-main` to your own agent folder so the conversation runs on that tier's model.
187
76
 
188
- ```text
189
- > /design Add per-team rate limiting to the public webhook endpoint, sharing budget
190
- across replicas, with an emergency kill switch.
191
-
192
- # Claude reads the codebase, ingests the repo's own CLAUDE.md/AGENTS.md once,
193
- # resolves the expensive-to-reverse calls with you (storage backend, where the limiter
194
- # lives), maps the complexity hotspots, and compiles .somi/plans/rate-limiting-webhooks/
195
- # brief.md — the dense design→execution handoff. Then /plan rate-limiting-webhooks sequences it
196
- # into phases at the cheaper (cost: medium) tier, /code-loop implements against the brief.
77
+ ```json
78
+ { "tiers": { "main": "medium", "claude": { "low": "haiku", "medium": "sonnet", "high": "opus" }, "copilot": { "low": "<model>", "medium": "<model>", "high": "<model>" }, "ceiling": "high" } }
197
79
  ```
198
80
 
199
- For an **incremental change** with a settled design (the daily loop), start at planning:
200
-
201
- ```text
202
- > /plan Add per-team rate limiting to the public webhook ingestion endpoint
203
- with audit logging and an emergency kill switch.
81
+ Claude Code has those defaults. Copilot has none, because its models vary by plan, so a tier with no model runs on the session's. Three things to know on Copilot CLI:
204
82
 
205
- # Claude proposes a slug ("rate-limiting-webhooks"), reads the repo, drafts context.md,
206
- # then pauses inline on each architectural decision — presenting options with concrete
207
- # pros/cons, plus "Other" and "Discover" escape hatches. You decide. Verified decisions
208
- # land in decisions.md; the spec, phases, progress, and diary fill in. Review the
209
- # artifacts at .somi/plans/rate-limiting-webhooks/, edit if needed, approve.
83
+ - **Auto:** with the session model on Auto, every subagent gets the model Auto chose, so tiers do nothing. Pick a named model for the session; `/somi-config`'s setup check warns about Auto.
84
+ - **A model your plan cannot use:** it falls back to the session's model without an error.
85
+ - **VS Code:** it refuses a subagent above the main model's cost tier, so there the main agent needs to run on the strongest tier you want to use.
210
86
 
211
- > /code rate-limiting-webhooks phase 1, iteration 1
87
+ ## Set your quality limits
212
88
 
213
- # Claude implements with senior-engineer judgment, writes tests, updates docs, and
214
- # keeps the plan in sync — if implementation reveals the plan needs to change, it
215
- # updates spec/decisions/phases in place and appends a diary entry.
89
+ The quality gate checks what a change touched against limits on complexity, nesting, length, parameters, copied code and suppressions. The defaults are in [ARCHITECTURE.md](docs/ARCHITECTURE.md#quality-gate). Ask for it in the chat, or type `/somi-quality`. By default it scores the whole branch since it left the main branch, which is what goes into a pull request; `/somi-quality commit` scores what a commit adds to the last one. Both scopes share every limit except how much one change may add to a file: 25 in a commit and 100 in a pull request.
216
90
 
217
- > /review rate-limiting-webhooks
91
+ Ask `/somi-config` to change one, or set your own under `quality` in the same global file, and give either scope its own values under `quality.commit` or `quality.pr`:
218
92
 
219
- # Claude returns severity-graded findings (written under reviews/), rejects weak
220
- # solutions, flags plan-vs-code divergence.
93
+ ```json
94
+ { "quality": { "function": { "cognitive": 15, "depth": 4, "lines": 60, "params": 4 }, "commit": { "file": { "added_cognitive": 25 } }, "pr": { "file": { "added_cognitive": 100 } } } }
221
95
  ```
222
96
 
223
- For the all-in-one pipeline: `/ship <problem statement>`.
97
+ A project's `.somi/config.json` can only make a limit stricter: a looser value there is ignored, and the gate says so. SoMi asks before an agent changes a limit.
224
98
 
225
- **Lost?** On GitHub Copilot, select the `somi` agent — bare `@somi` renders a status dashboard of
226
- everything in flight (with a next action per item), and `@somi <what you want to do>` routes to
227
- the right command. When a work item is ready to merge, `/pr <slug>` turns its artifacts into the
228
- pull-request description. To see or change which cost tier each agent runs at, `/somi-config` shows the
229
- settings and asks before each change; lowering a tier needs your explicit confirmation.
99
+ For a cleanup or a refactor, `/somi-quality repo` reports on the whole codebase as it stands: every function and file over a limit, every copy in product code and every suppression with no reason. It lists the most complex functions and the files with the most findings first. Give it its own limits under `quality.repo`.
230
100
 
231
- ---
101
+ You do not need to run it yourself. When a turn that changed code ends, on Claude Code and Copilot CLI alike, SoMi runs the gate and sends anything over a limit back to the agent to fix, before any review. The agent never adds an exemption to get past it: that is yours to decide. No pull request text is written while the branch fails it, and `/somi-deliver` checks each build and steps the build up a tier with the findings.
232
102
 
233
- ## Why a shared OS, not per-project setups
103
+ ## Connect other plugins with shards
234
104
 
235
- - **Consistency** — every repo gets the same review bar, the same security posture, the same plan shape.
236
- - **Upgrade once** — update the plugin; every project benefits.
237
- - **Override locally** — projects keep their own `CLAUDE.md` and `.somi/rules/99-overrides.md`; SoMi never silently overrides them.
238
- - **Auditable** — hooks log denied actions; reviewers can see what the system blocked vs. what humans approved.
105
+ A shard slots another plugin's skill, agent or tool into a named step: `work-item.start`, `plan.approved`, `pr.open` or `review.done`. Ask `/somi-config` in the chat, for example "connect jira:fetch-ticket to work-item.start", and the agent runs `somi slot` for you, like this:
239
106
 
240
- ---
241
-
242
- ## Documentation
107
+ ```bash
108
+ somi slot work-item.start jira:fetch-ticket
109
+ somi slot pr.open github:open-pr --mode write
110
+ somi slot --list
111
+ ```
243
112
 
244
- - [Installation](docs/INSTALL.md) — Claude Code plugin, npm, or Copilot extension
245
- - [Usage](docs/USAGE.md) — running each workflow with examples
246
- - [Workflows](docs/WORKFLOWS.md) — plan / code / review semantics and handoffs
247
- - [Agents](docs/AGENTS.md) — full agent catalogue, escalation rules
248
- - [Hooks](docs/HOOKS.md) — guardrails and how to add your own
249
- - [Skills](docs/SKILLS.md) — on-demand expertise packs
250
- - [Rules](docs/RULES.md) — global ruleset philosophy and conflict resolution
251
- - [Commands](docs/COMMANDS.md) — slash-command reference
252
- - [Extending](docs/EXTENDING.md) — adding workflows, agents, skills
253
- - [Versioning](docs/VERSIONING.md) — SemVer policy, breaking-change rules
254
- - [Governance](docs/GOVERNANCE.md) — how teams adopt updates safely
255
- - [Plugin distribution](docs/PLUGIN.md) — marketplace and VS Code setup
256
- - [Architecture](docs/architecture.md) — how the pieces fit together
113
+ A shard keeps working when its plugin updates, and tells you it changed. What it returns is treated as data, never as instructions. Anything that writes outward asks first, and a changed write shard stays held until you confirm.
257
114
 
258
- ---
115
+ ## Turn on the sandbox
259
116
 
260
- ## Versioning
117
+ Hooks catch honest mistakes. They are not a security boundary. Ask `/somi-config` to check the setup: it runs `somi doctor` inside the agent's own shell, and when the sandbox is off it gives you the recommended settings from `somi doctor --profile` to merge into your host's settings. Check again from inside an agent session, because a command typed at a `!` prompt usually bypasses the sandbox.
261
118
 
262
- SoMi follows [Semantic Versioning](https://semver.org/). Releases are **automated from
263
- [Conventional Commits](https://www.conventionalcommits.org/)**: merging to `main` runs the publish
264
- workflow, which derives the next version, publishes to npm (with a signed provenance attestation via
265
- OIDC trusted publishing), pushes the `v<version>` git tag, and creates the matching GitHub Release.
119
+ `doctor` passes only when writing to your home directory and reaching the network directly both fail inside the agent's shell. See [the trust model](docs/ARCHITECTURE.md#trust-model).
266
120
 
267
- The **published git tags and the npm registry are the source of truth** for the released version —
268
- the in-repo `VERSION` / `package.json` are not committed back on each release, so don't rely on them
269
- for "what's published." Check the [npm page](https://www.npmjs.com/package/@skathio/somi) or
270
- [Releases](https://github.com/skathio/somi/releases) instead.
121
+ ## Upgrading from 4.1
271
122
 
272
- See [docs/VERSIONING.md](docs/VERSIONING.md) for the breaking-change policy and migration guide template.
123
+ This is a breaking release. See [the migration guide](docs/MIGRATING-TO-5.md). Remove a 4.x install first: if both load, both sets of hooks and skills run. On Copilot, `copilot plugin list` shows which version is installed, and a project that ran an earlier `somi init` should delete `.github/hooks/somi.json`, or every hook runs twice.
273
124
 
274
- ---
125
+ ## Docs
275
126
 
276
- ## License
127
+ - [Architecture and trust model](docs/ARCHITECTURE.md)
128
+ - [Benchmark and release decision](docs/BENCHMARK.md)
129
+ - [Migrating from 4.x](docs/MIGRATING-TO-5.md)
130
+ - [Versioning](docs/VERSIONING.md)
131
+ - [Changelog](CHANGELOG.md)
277
132
 
278
- MIT — see [LICENSE](LICENSE).
133
+ MIT licensed.
package/VERSION CHANGED
@@ -1 +1 @@
1
- 4.1.1
1
+ 5.0.0