bigpowers 2.87.3 → 2.87.5

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 (259) hide show
  1. package/.cursor/rules/align-grid.mdc +109 -0
  2. package/.cursor/rules/assess-impact.mdc +90 -0
  3. package/.cursor/rules/audit-code.mdc +183 -0
  4. package/.cursor/rules/audit-plan.mdc +88 -0
  5. package/.cursor/rules/build-epic.mdc +104 -0
  6. package/.cursor/rules/change-request.mdc +120 -0
  7. package/.cursor/rules/commit-message.mdc +139 -0
  8. package/.cursor/rules/compose-workflow.mdc +81 -0
  9. package/.cursor/rules/context7-mcp.mdc +54 -0
  10. package/.cursor/rules/craft-skill.mdc +195 -0
  11. package/.cursor/rules/deepen-architecture.mdc +259 -0
  12. package/.cursor/rules/define-language.mdc +79 -0
  13. package/.cursor/rules/define-success.mdc +11 -0
  14. package/.cursor/rules/delegate-task.mdc +90 -0
  15. package/.cursor/rules/deploy.mdc +197 -0
  16. package/.cursor/rules/design-interface.mdc +96 -0
  17. package/.cursor/rules/develop-tdd.mdc +415 -0
  18. package/.cursor/rules/diagnose-root.mdc +23 -0
  19. package/.cursor/rules/diagnose-stall.mdc +53 -0
  20. package/.cursor/rules/dispatch-agents.mdc +117 -0
  21. package/.cursor/rules/edit-document.mdc +22 -0
  22. package/.cursor/rules/elaborate-spec.mdc +100 -0
  23. package/.cursor/rules/enforce-first.mdc +44 -0
  24. package/.cursor/rules/evolve-skill.mdc +54 -0
  25. package/.cursor/rules/execute-plan.mdc +60 -0
  26. package/.cursor/rules/extract-design.mdc +131 -0
  27. package/.cursor/rules/find-way.mdc +190 -0
  28. package/.cursor/rules/fix-bug.mdc +66 -0
  29. package/.cursor/rules/gate-trace.mdc +91 -0
  30. package/.cursor/rules/generate-allure-report.mdc +284 -0
  31. package/.cursor/rules/grill-me.mdc +107 -0
  32. package/.cursor/rules/grill-with-docs.mdc +52 -0
  33. package/.cursor/rules/guard-git.mdc +230 -0
  34. package/.cursor/rules/harden-vps.mdc +290 -0
  35. package/.cursor/rules/hook-commits.mdc +93 -0
  36. package/.cursor/rules/inspect-quality.mdc +105 -0
  37. package/.cursor/rules/investigate-bug.mdc +126 -0
  38. package/.cursor/rules/kickoff-branch.mdc +142 -0
  39. package/.cursor/rules/maintain-wiki.mdc +63 -0
  40. package/.cursor/rules/map-codebase.mdc +70 -0
  41. package/.cursor/rules/migrate-spec.mdc +907 -0
  42. package/.cursor/rules/model-domain.mdc +231 -0
  43. package/.cursor/rules/orchestrate-project.mdc +173 -0
  44. package/.cursor/rules/organize-workspace.mdc +163 -0
  45. package/.cursor/rules/plan-refactor.mdc +86 -0
  46. package/.cursor/rules/plan-release.mdc +144 -0
  47. package/.cursor/rules/plan-tests.mdc +74 -0
  48. package/.cursor/rules/plan-work.mdc +271 -0
  49. package/.cursor/rules/publish-package.mdc +337 -0
  50. package/.cursor/rules/quick-fix.mdc +113 -0
  51. package/.cursor/rules/release-branch.mdc +301 -0
  52. package/.cursor/rules/request-review.mdc +112 -0
  53. package/.cursor/rules/research-first.mdc +86 -0
  54. package/.cursor/rules/reset-baseline.mdc +20 -0
  55. package/.cursor/rules/respond-review.mdc +70 -0
  56. package/.cursor/rules/run-benchmark.mdc +84 -0
  57. package/.cursor/rules/run-evals.mdc +79 -0
  58. package/.cursor/rules/run-planning.mdc +100 -0
  59. package/.cursor/rules/scope-work.mdc +62 -0
  60. package/.cursor/rules/search-skills.mdc +72 -0
  61. package/.cursor/rules/security-review.mdc +383 -0
  62. package/.cursor/rules/seed-conventions.mdc +311 -0
  63. package/.cursor/rules/session-state.mdc +145 -0
  64. package/.cursor/rules/setup-environment.mdc +38 -0
  65. package/.cursor/rules/simple-english.mdc +345 -0
  66. package/.cursor/rules/simulate-agents.mdc +25 -0
  67. package/.cursor/rules/slice-tasks.mdc +67 -0
  68. package/.cursor/rules/smoke-test.mdc +260 -0
  69. package/.cursor/rules/spike-prototype.mdc +94 -0
  70. package/.cursor/rules/stocktake-skills.mdc +73 -0
  71. package/.cursor/rules/survey-context.mdc +134 -0
  72. package/.cursor/rules/terse-mode.mdc +41 -0
  73. package/.cursor/rules/trace-requirement.mdc +68 -0
  74. package/.cursor/rules/using-bigpowers.mdc +110 -0
  75. package/.cursor/rules/validate-contracts.mdc +285 -0
  76. package/.cursor/rules/validate-fix.mdc +146 -0
  77. package/.cursor/rules/verify-work.mdc +190 -0
  78. package/.cursor/rules/visual-dashboard.mdc +49 -0
  79. package/.cursor/rules/wire-ci.mdc +380 -0
  80. package/.cursor/rules/wire-observability.mdc +96 -0
  81. package/.cursor/rules/write-document.mdc +280 -0
  82. package/.gemini/extensions/bigpowers/commands/prompts/align-grid.md +109 -0
  83. package/.gemini/extensions/bigpowers/commands/prompts/assess-impact.md +90 -0
  84. package/.gemini/extensions/bigpowers/commands/prompts/audit-code.md +183 -0
  85. package/.gemini/extensions/bigpowers/commands/prompts/audit-plan.md +88 -0
  86. package/.gemini/extensions/bigpowers/commands/prompts/build-epic.md +104 -0
  87. package/.gemini/extensions/bigpowers/commands/prompts/change-request.md +120 -0
  88. package/.gemini/extensions/bigpowers/commands/prompts/commit-message.md +139 -0
  89. package/.gemini/extensions/bigpowers/commands/prompts/compose-workflow.md +81 -0
  90. package/.gemini/extensions/bigpowers/commands/prompts/context7-mcp.md +54 -0
  91. package/.gemini/extensions/bigpowers/commands/prompts/craft-skill.md +195 -0
  92. package/.gemini/extensions/bigpowers/commands/prompts/deepen-architecture.md +259 -0
  93. package/.gemini/extensions/bigpowers/commands/prompts/define-language.md +79 -0
  94. package/.gemini/extensions/bigpowers/commands/prompts/define-success.md +11 -0
  95. package/.gemini/extensions/bigpowers/commands/prompts/delegate-task.md +90 -0
  96. package/.gemini/extensions/bigpowers/commands/prompts/deploy.md +197 -0
  97. package/.gemini/extensions/bigpowers/commands/prompts/design-interface.md +96 -0
  98. package/.gemini/extensions/bigpowers/commands/prompts/develop-tdd.md +415 -0
  99. package/.gemini/extensions/bigpowers/commands/prompts/diagnose-root.md +23 -0
  100. package/.gemini/extensions/bigpowers/commands/prompts/diagnose-stall.md +53 -0
  101. package/.gemini/extensions/bigpowers/commands/prompts/dispatch-agents.md +117 -0
  102. package/.gemini/extensions/bigpowers/commands/prompts/edit-document.md +22 -0
  103. package/.gemini/extensions/bigpowers/commands/prompts/elaborate-spec.md +100 -0
  104. package/.gemini/extensions/bigpowers/commands/prompts/enforce-first.md +44 -0
  105. package/.gemini/extensions/bigpowers/commands/prompts/evolve-skill.md +54 -0
  106. package/.gemini/extensions/bigpowers/commands/prompts/execute-plan.md +60 -0
  107. package/.gemini/extensions/bigpowers/commands/prompts/extract-design.md +131 -0
  108. package/.gemini/extensions/bigpowers/commands/prompts/find-way.md +190 -0
  109. package/.gemini/extensions/bigpowers/commands/prompts/fix-bug.md +66 -0
  110. package/.gemini/extensions/bigpowers/commands/prompts/gate-trace.md +91 -0
  111. package/.gemini/extensions/bigpowers/commands/prompts/generate-allure-report.md +284 -0
  112. package/.gemini/extensions/bigpowers/commands/prompts/grill-me.md +107 -0
  113. package/.gemini/extensions/bigpowers/commands/prompts/grill-with-docs.md +52 -0
  114. package/.gemini/extensions/bigpowers/commands/prompts/guard-git.md +230 -0
  115. package/.gemini/extensions/bigpowers/commands/prompts/harden-vps.md +290 -0
  116. package/.gemini/extensions/bigpowers/commands/prompts/hook-commits.md +93 -0
  117. package/.gemini/extensions/bigpowers/commands/prompts/inspect-quality.md +105 -0
  118. package/.gemini/extensions/bigpowers/commands/prompts/investigate-bug.md +126 -0
  119. package/.gemini/extensions/bigpowers/commands/prompts/kickoff-branch.md +142 -0
  120. package/.gemini/extensions/bigpowers/commands/prompts/maintain-wiki.md +63 -0
  121. package/.gemini/extensions/bigpowers/commands/prompts/map-codebase.md +70 -0
  122. package/.gemini/extensions/bigpowers/commands/prompts/migrate-spec.md +907 -0
  123. package/.gemini/extensions/bigpowers/commands/prompts/model-domain.md +231 -0
  124. package/.gemini/extensions/bigpowers/commands/prompts/orchestrate-project.md +173 -0
  125. package/.gemini/extensions/bigpowers/commands/prompts/organize-workspace.md +163 -0
  126. package/.gemini/extensions/bigpowers/commands/prompts/plan-refactor.md +86 -0
  127. package/.gemini/extensions/bigpowers/commands/prompts/plan-release.md +144 -0
  128. package/.gemini/extensions/bigpowers/commands/prompts/plan-tests.md +74 -0
  129. package/.gemini/extensions/bigpowers/commands/prompts/plan-work.md +271 -0
  130. package/.gemini/extensions/bigpowers/commands/prompts/publish-package.md +337 -0
  131. package/.gemini/extensions/bigpowers/commands/prompts/quick-fix.md +113 -0
  132. package/.gemini/extensions/bigpowers/commands/prompts/release-branch.md +301 -0
  133. package/.gemini/extensions/bigpowers/commands/prompts/request-review.md +112 -0
  134. package/.gemini/extensions/bigpowers/commands/prompts/research-first.md +86 -0
  135. package/.gemini/extensions/bigpowers/commands/prompts/reset-baseline.md +20 -0
  136. package/.gemini/extensions/bigpowers/commands/prompts/respond-review.md +70 -0
  137. package/.gemini/extensions/bigpowers/commands/prompts/run-benchmark.md +84 -0
  138. package/.gemini/extensions/bigpowers/commands/prompts/run-evals.md +79 -0
  139. package/.gemini/extensions/bigpowers/commands/prompts/run-planning.md +100 -0
  140. package/.gemini/extensions/bigpowers/commands/prompts/scope-work.md +62 -0
  141. package/.gemini/extensions/bigpowers/commands/prompts/search-skills.md +72 -0
  142. package/.gemini/extensions/bigpowers/commands/prompts/security-review.md +383 -0
  143. package/.gemini/extensions/bigpowers/commands/prompts/seed-conventions.md +311 -0
  144. package/.gemini/extensions/bigpowers/commands/prompts/session-state.md +145 -0
  145. package/.gemini/extensions/bigpowers/commands/prompts/setup-environment.md +38 -0
  146. package/.gemini/extensions/bigpowers/commands/prompts/simple-english.md +345 -0
  147. package/.gemini/extensions/bigpowers/commands/prompts/simulate-agents.md +25 -0
  148. package/.gemini/extensions/bigpowers/commands/prompts/slice-tasks.md +67 -0
  149. package/.gemini/extensions/bigpowers/commands/prompts/smoke-test.md +260 -0
  150. package/.gemini/extensions/bigpowers/commands/prompts/spike-prototype.md +94 -0
  151. package/.gemini/extensions/bigpowers/commands/prompts/stocktake-skills.md +73 -0
  152. package/.gemini/extensions/bigpowers/commands/prompts/survey-context.md +134 -0
  153. package/.gemini/extensions/bigpowers/commands/prompts/terse-mode.md +41 -0
  154. package/.gemini/extensions/bigpowers/commands/prompts/trace-requirement.md +68 -0
  155. package/.gemini/extensions/bigpowers/commands/prompts/using-bigpowers.md +110 -0
  156. package/.gemini/extensions/bigpowers/commands/prompts/validate-contracts.md +285 -0
  157. package/.gemini/extensions/bigpowers/commands/prompts/validate-fix.md +146 -0
  158. package/.gemini/extensions/bigpowers/commands/prompts/verify-work.md +190 -0
  159. package/.gemini/extensions/bigpowers/commands/prompts/visual-dashboard.md +49 -0
  160. package/.gemini/extensions/bigpowers/commands/prompts/wire-ci.md +380 -0
  161. package/.gemini/extensions/bigpowers/commands/prompts/wire-observability.md +96 -0
  162. package/.gemini/extensions/bigpowers/commands/prompts/write-document.md +280 -0
  163. package/.gemini/extensions/bigpowers/gemini-extension.json +16 -0
  164. package/.gemini/extensions/bigpowers/hooks/HOOKS.md +43 -0
  165. package/.gemini/extensions/bigpowers/hooks/before-tool-git-guard.sh +26 -0
  166. package/.gemini/extensions/bigpowers/hooks/before-tool-rtk.sh +14 -0
  167. package/.gemini/extensions/bigpowers/hooks/before-tool-token-mgmt.sh +19 -0
  168. package/.gemini/extensions/bigpowers/hooks/hooks-manifest.json +36 -0
  169. package/.gemini/extensions/bigpowers/hooks/run-hook.cmd +29 -0
  170. package/.gemini/extensions/bigpowers/hooks/session-start +48 -0
  171. package/.gemini/extensions/bigpowers/hooks/settings.json.example +41 -0
  172. package/.gemini/extensions/bigpowers/skills/align-grid/SKILL.md +111 -0
  173. package/.gemini/extensions/bigpowers/skills/assess-impact/SKILL.md +92 -0
  174. package/.gemini/extensions/bigpowers/skills/audit-code/SKILL.md +185 -0
  175. package/.gemini/extensions/bigpowers/skills/audit-plan/SKILL.md +90 -0
  176. package/.gemini/extensions/bigpowers/skills/build-epic/SKILL.md +106 -0
  177. package/.gemini/extensions/bigpowers/skills/change-request/SKILL.md +122 -0
  178. package/.gemini/extensions/bigpowers/skills/commit-message/SKILL.md +141 -0
  179. package/.gemini/extensions/bigpowers/skills/compose-workflow/SKILL.md +83 -0
  180. package/.gemini/extensions/bigpowers/skills/context7-mcp/SKILL.md +56 -0
  181. package/.gemini/extensions/bigpowers/skills/craft-skill/SKILL.md +197 -0
  182. package/.gemini/extensions/bigpowers/skills/deepen-architecture/SKILL.md +261 -0
  183. package/.gemini/extensions/bigpowers/skills/define-language/SKILL.md +81 -0
  184. package/.gemini/extensions/bigpowers/skills/define-success/SKILL.md +13 -0
  185. package/.gemini/extensions/bigpowers/skills/delegate-task/SKILL.md +92 -0
  186. package/.gemini/extensions/bigpowers/skills/deploy/SKILL.md +199 -0
  187. package/.gemini/extensions/bigpowers/skills/design-interface/SKILL.md +98 -0
  188. package/.gemini/extensions/bigpowers/skills/develop-tdd/SKILL.md +417 -0
  189. package/.gemini/extensions/bigpowers/skills/diagnose-root/SKILL.md +25 -0
  190. package/.gemini/extensions/bigpowers/skills/diagnose-stall/SKILL.md +55 -0
  191. package/.gemini/extensions/bigpowers/skills/dispatch-agents/SKILL.md +119 -0
  192. package/.gemini/extensions/bigpowers/skills/edit-document/SKILL.md +24 -0
  193. package/.gemini/extensions/bigpowers/skills/elaborate-spec/SKILL.md +102 -0
  194. package/.gemini/extensions/bigpowers/skills/enforce-first/SKILL.md +46 -0
  195. package/.gemini/extensions/bigpowers/skills/evolve-skill/SKILL.md +56 -0
  196. package/.gemini/extensions/bigpowers/skills/execute-plan/SKILL.md +62 -0
  197. package/.gemini/extensions/bigpowers/skills/extract-design/SKILL.md +133 -0
  198. package/.gemini/extensions/bigpowers/skills/find-way/SKILL.md +192 -0
  199. package/.gemini/extensions/bigpowers/skills/fix-bug/SKILL.md +68 -0
  200. package/.gemini/extensions/bigpowers/skills/gate-trace/SKILL.md +93 -0
  201. package/.gemini/extensions/bigpowers/skills/generate-allure-report/SKILL.md +286 -0
  202. package/.gemini/extensions/bigpowers/skills/grill-me/SKILL.md +109 -0
  203. package/.gemini/extensions/bigpowers/skills/grill-with-docs/SKILL.md +54 -0
  204. package/.gemini/extensions/bigpowers/skills/guard-git/SKILL.md +232 -0
  205. package/.gemini/extensions/bigpowers/skills/harden-vps/SKILL.md +292 -0
  206. package/.gemini/extensions/bigpowers/skills/hook-commits/SKILL.md +95 -0
  207. package/.gemini/extensions/bigpowers/skills/inspect-quality/SKILL.md +107 -0
  208. package/.gemini/extensions/bigpowers/skills/investigate-bug/SKILL.md +128 -0
  209. package/.gemini/extensions/bigpowers/skills/kickoff-branch/SKILL.md +144 -0
  210. package/.gemini/extensions/bigpowers/skills/maintain-wiki/SKILL.md +65 -0
  211. package/.gemini/extensions/bigpowers/skills/map-codebase/SKILL.md +72 -0
  212. package/.gemini/extensions/bigpowers/skills/migrate-spec/SKILL.md +909 -0
  213. package/.gemini/extensions/bigpowers/skills/model-domain/SKILL.md +233 -0
  214. package/.gemini/extensions/bigpowers/skills/orchestrate-project/SKILL.md +175 -0
  215. package/.gemini/extensions/bigpowers/skills/organize-workspace/SKILL.md +165 -0
  216. package/.gemini/extensions/bigpowers/skills/plan-refactor/SKILL.md +88 -0
  217. package/.gemini/extensions/bigpowers/skills/plan-release/SKILL.md +146 -0
  218. package/.gemini/extensions/bigpowers/skills/plan-tests/SKILL.md +76 -0
  219. package/.gemini/extensions/bigpowers/skills/plan-work/SKILL.md +273 -0
  220. package/.gemini/extensions/bigpowers/skills/publish-package/SKILL.md +339 -0
  221. package/.gemini/extensions/bigpowers/skills/quick-fix/SKILL.md +115 -0
  222. package/.gemini/extensions/bigpowers/skills/release-branch/SKILL.md +303 -0
  223. package/.gemini/extensions/bigpowers/skills/request-review/SKILL.md +114 -0
  224. package/.gemini/extensions/bigpowers/skills/research-first/SKILL.md +88 -0
  225. package/.gemini/extensions/bigpowers/skills/reset-baseline/SKILL.md +22 -0
  226. package/.gemini/extensions/bigpowers/skills/respond-review/SKILL.md +72 -0
  227. package/.gemini/extensions/bigpowers/skills/run-benchmark/SKILL.md +86 -0
  228. package/.gemini/extensions/bigpowers/skills/run-evals/SKILL.md +81 -0
  229. package/.gemini/extensions/bigpowers/skills/run-planning/SKILL.md +102 -0
  230. package/.gemini/extensions/bigpowers/skills/scope-work/SKILL.md +64 -0
  231. package/.gemini/extensions/bigpowers/skills/search-skills/SKILL.md +74 -0
  232. package/.gemini/extensions/bigpowers/skills/security-review/SKILL.md +385 -0
  233. package/.gemini/extensions/bigpowers/skills/seed-conventions/SKILL.md +313 -0
  234. package/.gemini/extensions/bigpowers/skills/session-state/SKILL.md +147 -0
  235. package/.gemini/extensions/bigpowers/skills/setup-environment/SKILL.md +40 -0
  236. package/.gemini/extensions/bigpowers/skills/simple-english/SKILL.md +347 -0
  237. package/.gemini/extensions/bigpowers/skills/simulate-agents/SKILL.md +27 -0
  238. package/.gemini/extensions/bigpowers/skills/slice-tasks/SKILL.md +69 -0
  239. package/.gemini/extensions/bigpowers/skills/smoke-test/SKILL.md +262 -0
  240. package/.gemini/extensions/bigpowers/skills/spike-prototype/SKILL.md +96 -0
  241. package/.gemini/extensions/bigpowers/skills/stocktake-skills/SKILL.md +75 -0
  242. package/.gemini/extensions/bigpowers/skills/survey-context/SKILL.md +136 -0
  243. package/.gemini/extensions/bigpowers/skills/terse-mode/SKILL.md +43 -0
  244. package/.gemini/extensions/bigpowers/skills/trace-requirement/SKILL.md +70 -0
  245. package/.gemini/extensions/bigpowers/skills/using-bigpowers/SKILL.md +112 -0
  246. package/.gemini/extensions/bigpowers/skills/validate-contracts/SKILL.md +287 -0
  247. package/.gemini/extensions/bigpowers/skills/validate-fix/SKILL.md +148 -0
  248. package/.gemini/extensions/bigpowers/skills/verify-work/SKILL.md +192 -0
  249. package/.gemini/extensions/bigpowers/skills/visual-dashboard/SKILL.md +51 -0
  250. package/.gemini/extensions/bigpowers/skills/wire-ci/SKILL.md +382 -0
  251. package/.gemini/extensions/bigpowers/skills/wire-observability/SKILL.md +98 -0
  252. package/.gemini/extensions/bigpowers/skills/write-document/SKILL.md +282 -0
  253. package/.pi/package.json +1 -1
  254. package/CHANGELOG.md +14 -0
  255. package/package.json +1 -1
  256. package/scripts/lib/__pycache__/link_utils.cpython-312.pyc +0 -0
  257. package/scripts/lib/__pycache__/srp_engine_links.cpython-312.pyc +0 -0
  258. package/scripts/lib/install-helpers.js +147 -20
  259. package/scripts/test-install-helpers.js +141 -0
@@ -0,0 +1,303 @@
1
+ ---
2
+ name: release-branch
3
+ model: haiku
4
+ description: "Make the merge/PR/keep/discard decision for a feature branch, verify coverage gates, create the PR with gh, and clean up the worktree. Use when a feature is done and ready to ship, or when user says \"release\", \"merge\", or \"open a PR\"."
5
+ disable-model-invocation: true
6
+ ---
7
+
8
+ <!-- story: e38s07 -->
9
+ <!-- story: e45s15 -->
10
+ <!-- story: e45s32 -->
11
+ <!-- story: e45s39 -->
12
+ <!-- story: e20s02 -->
13
+
14
+
15
+ # Release Branch
16
+
17
+ > **HARD GATE** — Do NOT merge or release if tests fail or if coverage gates are not met. If the branch is red, return to `develop-tdd` to fix regressions or add missing tests before proceeding.
18
+
19
+ Finalize a completed feature branch: verify coverage gates, integrate onto `main`, and clean up the worktree.
20
+
21
+ ## Additional modes
22
+ - `--hotfix`: Cherry-pick to main + tag. Skip PR in solo.
23
+ - `--squash-state`: Squash `chore(state):` commits before merge.
24
+
25
+ ## Integrate mode
26
+
27
+ Read `specs/state.yaml` key `workflow_mode` (`team-pr` | `solo-git`). Fall back to `profiles/solo-git.md`.
28
+
29
+ | Mode | When | Ship path |
30
+ |------|------|-----------|
31
+ | **solo-local** | `workflow_mode: solo-git` | Auto: `scripts/land-branch.sh` if present, else fallback (Step 5) |
32
+ | **team-pr** | `workflow_mode: team-pr` (default) | `gh pr create` → `gh pr merge --squash` |
33
+
34
+ If unsure, prefer **solo-local**.
35
+
36
+ ## Process
37
+
38
+ > **Timing:** `bash scripts/bp-timing.sh start release-branch` at invocation; `bash scripts/bp-timing.sh end release-branch` before handoff.
39
+
40
+ ### 1. Final verification
41
+
42
+ ```bash
43
+ <full test command> && <typecheck command> && <lint command>
44
+ git log main...HEAD --oneline | grep -vE "^[a-f0-9]+ (feat|fix|docs|style|refactor|perf|test|build|ci|chore|revert)(\(.+\))?!?: .+$" && echo "❌ Non-conventional commits found" || echo "✅ Commits verified"
45
+ # Block AI agent attribution (P1)
46
+ git log main...HEAD --format="%B" | grep -qiE 'co[- ]authored[- ]by' && echo "❌ Co-authored-by footer found — blocked" || echo "✅ No AI attribution"
47
+ ```
48
+
49
+ - [ ] All tests pass, no type errors, no lint violations, all commits follow Conventional Commits
50
+ - [ ] **NO `Co-authored-by` or `Co-Authored-By`** in any commit body — P1 rule (CONVENTIONS.md § Git Attribution). `land-branch.sh` blocks the merge if found.
51
+
52
+ ### 2. Coverage check
53
+
54
+ - [ ] Overall coverage ≥ 80%; business logic coverage ≥ 95%
55
+
56
+ ### 2a. Security gate
57
+
58
+ - [ ] `specs/security/REVIEW.md` exists and is fresh (matches current branch diff)
59
+ - [ ] No unresolved HIGH findings with confidence ≥ 8 (or all documented in `specs/security/EXCEPTIONS.md` with sign-off rationale)
60
+
61
+ If REVIEW.md is missing or stale → run `security-review` inline. Findings block the merge unless documented in EXCEPTIONS.md.
62
+
63
+ ### 2b. Traceability gate
64
+
65
+ Run `gate-trace` before merge. FAIL blocks merge; CONCERNS requires explicit override in `specs/state.yaml` (`traceability_override: CONCERNS accepted, reason: <explanation>`). WAIVED if no matrix available.
66
+
67
+ > **Adversarial refute framing (e45s32):** The final pre-merge check is **refute, not rubber-stamp**. Before declaring ready, actively try to disprove traceability completeness — missing story tags, absent verify evidence, stale security review. Only proceed when refutation fails.
68
+
69
+ ### 3. Diff review
70
+
71
+ - [ ] All commits intentional, no secrets, CONVENTIONS.md compliance
72
+
73
+ ### 4. Decision
74
+
75
+ Options: **Release (solo-local)** / **Open PR** / **Keep branch** / **Discard**
76
+
77
+ ### 5. Solo-local integrate
78
+
79
+ Run `commit-message` for the squash subject, then land:
80
+
81
+ ```bash
82
+ # Path A (preferred):
83
+ bash scripts/land-branch.sh <task-slug> "feat(scope): description"
84
+ # Path B (fallback if land-branch.sh missing): see REFERENCE.md
85
+ ```
86
+
87
+ ### 6. Create PR (team-pr only)
88
+
89
+ Create the pull request with a **literal provenance marker** in the body so agent-generated PRs are identifiable and do not rot silently:
90
+
91
+ ```markdown
92
+ <!-- bigpowers-provenance: agent-generated -->
93
+ ```
94
+
95
+ Place the marker on its own line immediately after the `## Summary` heading. Then merge via `gh`:
96
+
97
+ ```bash
98
+ gh pr create --title "..." --body "$(cat <<'EOF'
99
+ ## Summary
100
+ <!-- bigpowers-provenance: agent-generated -->
101
+
102
+ - ...
103
+
104
+ ## Test plan
105
+ - [ ] ...
106
+
107
+ EOF
108
+ )"
109
+ gh pr merge --squash --delete-branch
110
+ ```
111
+
112
+ `semantic-release` auto-detects the commit, bumps SemVer, tags the repo, generates release notes.
113
+
114
+ ### 7a. Archive completed epic capsule
115
+
116
+ > **HARD GATE** — When all epic stories are done (all `done` in `execution-status.yaml`), archive the capsule:
117
+
118
+ ```bash
119
+ mv specs/epics/eNN-slug specs/epics/archive/
120
+ ```
121
+
122
+ ### 7b. CI verification & agent lock release (e39s02)
123
+
124
+ > **HARD GATE** — Do NOT declare success until CI completes. **Three-independent-facts** (e45s15): commit landed, workflow green, registry visible — see [REFERENCE.md](REFERENCE.md#three-independent-facts-release).
125
+
126
+ ```bash
127
+ bash scripts/wait-for-ci.sh --timeout 600 --interval 30
128
+ ```
129
+
130
+ - [ ] CI passes; `release.ci_verified: true` in state.yaml
131
+ - On failure: `handoff.next_skill = fix-bug`
132
+
133
+ ### 8. Clean up & return
134
+
135
+ Worktree prune, branch delete, `git checkout main`. Cycle-time: see [REFERENCE.md](REFERENCE.md#cycle-time).
136
+
137
+ Report: "Branch released."
138
+
139
+ ## Verify
140
+
141
+ → verify: `command -v gh >/dev/null 2>&1 && test -f specs/state.yaml && test -d skills/verify-work`
142
+
143
+ ---
144
+
145
+ # Release Branch — Reference
146
+
147
+ ## Navigation
148
+
149
+ | Lines | Section |
150
+ |-------|---------|
151
+ | 1 | Title |
152
+ | 3–22 | Navigation |
153
+ | 23–31 | PR body template (team-pr mode) |
154
+ | 32–35 | Summary |
155
+ | 36–41 | Verify |
156
+ | 42–47 | specs/ artifacts |
157
+ | 48–58 | Worktree cleanup details |
158
+ | 59–81 | Cycle-time recording |
159
+ | 82–100 | Why not story_start minus story_end? |
160
+ | 101–121 | CI verification |
161
+ | 122–127 | Solo-local fallback detail |
162
+ | 128–134 | Handoff |
163
+ | 135–159 | Reference block 1 |
164
+
165
+ # Release Branch — Reference
166
+
167
+ ## PR body template (team-pr mode)
168
+
169
+ ```bash
170
+ PR_TITLE="<type>(<scope>): <description>"
171
+ echo "$PR_TITLE" | grep -vE "^(feat|fix|docs|style|refactor|perf|test|build|ci|chore|revert)(\(.+\))?!?: .+$" && echo "❌ ERROR: PR Title must follow Conventional Commits"
172
+
173
+ gh pr create \
174
+ --title "$PR_TITLE" \
175
+ --body "$(cat <<'EOF'
176
+ ## Summary
177
+ - [What this PR does]
178
+ - [Key decisions made]
179
+
180
+ ## Verify
181
+ - [ ] All tests pass
182
+ - [ ] Coverage gates met (≥80% overall, ≥95% business logic)
183
+ - [ ] CONVENTIONS.md compliance verified
184
+ - [ ] PR Title follows Conventional Commits (for automated release)
185
+
186
+ ## specs/ artifacts
187
+ - [List any specs/ files produced or updated]
188
+ EOF
189
+ )"
190
+ ```
191
+
192
+ ## Worktree cleanup details
193
+
194
+ ```bash
195
+ # From the main repo root
196
+ git worktree prune
197
+ git worktree remove ../<branch-name> 2>/dev/null || true
198
+ git branch -d <branch-name>
199
+ ```
200
+
201
+ If `git worktree remove` fails due to uncommitted changes, ask: "There are uncommitted changes in the worktree. Force remove? (y/n)". If yes: `git worktree remove -f ../<branch-name>`.
202
+
203
+ ## Cycle-time recording
204
+
205
+ After landing the branch, record delivery metrics using the git-derived,
206
+ additive script (replaces hand-arithmetic):
207
+
208
+ ```bash
209
+ bash scripts/record-cycle-time.sh append \
210
+ --story <story_id> --bcps <bcps> \
211
+ --range "$(git merge-base main HEAD)..HEAD" \
212
+ --file specs/metrics/cycle-times.yaml
213
+ ```
214
+
215
+ This appends a row to the cycle-times ledger with two separated metrics:
216
+
217
+ - **effort_hours** — ADDITIVE. Idle-stripped estimated effort from git commit
218
+ history (git-hours model: 120-min session threshold, 120-min first-commit pad).
219
+ Sums exactly to whole-repo effort. NO hand-arithmetic, NO wall-clock includes.
220
+ - **lead_time_minutes** — calendar latency from first commit to merge.
221
+ Median-aggregated across stories; NEVER summed.
222
+
223
+ The script also runs an additivity self-check: Σ(story effort) == whole-repo effort
224
+ within rounding tolerance.
225
+
226
+ ### Why not story_start minus story_end?
227
+
228
+ The previous hand-arithmetic approach (survey-context writes `story_start`,
229
+ release-branch writes `story_end`, agent hand-computes `cycle_minutes`) was
230
+ retired because:
231
+
232
+ 1. It was **agent-self-reported** — trivially fabricated or mis-subtracted.
233
+ 2. Wall-clock included **overnight/weekend/UAT gaps** — calendar latency,
234
+ not coding effort.
235
+ 3. The `bcp_per_hour` metric was **computationally meaningless** (velocity
236
+ derived from a latency measurement).
237
+
238
+ The new approach derives effort from commit history (objective, reproducible)
239
+ and lead time from first commit → merge (honest calendar latency). See
240
+ `docs/references/bcp.md` for BCP sizing context and
241
+ `scripts/record-cycle-time.sh` for the full algorithm.
242
+
243
+ ---
244
+
245
+ ## CI verification
246
+
247
+ The CI polling logic has been extracted to `scripts/wait-for-ci.sh`.
248
+ See the script's `--help` for usage. Step 7b of the main SKILL.md invokes it directly:
249
+
250
+ ```bash
251
+ bash scripts/wait-for-ci.sh --timeout 600 --interval 30
252
+ ```
253
+
254
+ **Exit codes:**
255
+ - **0** — all workflows green. Set `release.ci_verified: true` in state.yaml.
256
+ - **1** — at least one workflow failed. Prints failure URLs. Set `handoff.next_skill = fix-bug`.
257
+ - **2** — timeout. CI did not complete. Retry or investigate.
258
+ - **0 with warning** — `gh` CLI not available, git-only fallback confirmed push landed but CI status unverified.
259
+
260
+ The script handles: auto-discovery of all workflows for the current
261
+ branch/commit, polling until completion, success/failure/timeout exit codes,
262
+ and git-only fallback when `gh` CLI is unavailable.
263
+
264
+ ---
265
+
266
+ ## Solo-local fallback detail
267
+
268
+ The fallback sequence (Path B above) handles the "remote has moved" case with `git pull --rebase`. Use when `scripts/land-branch.sh` is absent.
269
+
270
+ **Acceptance:** When fallback runs, main is updated, feature branch is deleted locally, and output states `"used fallback merge (land-branch.sh not found)"`.
271
+
272
+ ## Handoff
273
+
274
+ Gate: READY -> next: survey-context
275
+ Writes: state.yaml handoff.next_skill = survey-context
276
+
277
+ ---
278
+
279
+ ## Reference block 1
280
+
281
+ ```bash
282
+ # Fallback: manual squash-merge when land-branch.sh is absent
283
+ FEATURE_BRANCH=<task-slug>
284
+ DEFAULT_BRANCH=$(git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's@^refs/remotes/origin/@@' || echo main)
285
+
286
+ # Ensure we're on the feature branch
287
+ if [ "$(git branch --show-current)" != "$FEATURE_BRANCH" ]; then
288
+ git checkout "$FEATURE_BRANCH"
289
+ fi
290
+
291
+ # Checkout default branch and update
292
+ git checkout "$DEFAULT_BRANCH"
293
+ git pull --rebase origin "$DEFAULT_BRANCH" 2>/dev/null || git pull origin "$DEFAULT_BRANCH"
294
+
295
+ # Squash-merge the feature branch
296
+ git merge --no-ff "$FEATURE_BRANCH" -m "<conventional-commit-message>"
297
+
298
+ # Push
299
+ git push origin "$DEFAULT_BRANCH"
300
+
301
+ # Clean up local feature branch
302
+ git branch -d "$FEATURE_BRANCH"
303
+ ```
@@ -0,0 +1,114 @@
1
+ ---
2
+ name: request-review
3
+ model: opus
4
+ description: "Dispatch a fresh reviewer agent with a clean context to critique the code after audit-code passes. The reviewer has no shared state with the coding agent and gives a genuine second opinion. Use after audit-code passes, before committing, or when user wants an independent code review."
5
+ disable-model-invocation: true
6
+ ---
7
+
8
+ # story: e45s28
9
+
10
+ # Request Review
11
+
12
+ Dispatch fresh reviewer agents with clean contexts. Reviewers have no shared state — they find what the coding agent missed.
13
+
14
+ **Distinct from `audit-code`:** `audit-code` is self-review (internal). This skill dispatches external agents.
15
+
16
+ **Solo developer note:** Reviewer agents replace the human reviewer.
17
+
18
+ **Run `audit-code` first.** Don't waste reviewer attention on hygiene issues you could have caught yourself.
19
+
20
+ ## Santa Method — Dual-Blind AND Gate (e45s07)
21
+
22
+ Use **two independent reviewers** (Reviewer A and Reviewer B) with **no shared context** between them or the coding agent.
23
+
24
+ | Parameter | Value |
25
+ |-----------|-------|
26
+ | Reviewers | 2 (mandatory) |
27
+ | `MAX_REVIEW_ITERATIONS` | **5** (hard cap — e45s28; iteration 6 forbidden) |
28
+ | Pass rule | **AND-gate** — both reviewers must pass independently |
29
+ | Blindness | Neither reviewer sees the other's report until both complete |
30
+
31
+ **Iteration loop (max `MAX_REVIEW_ITERATIONS`):**
32
+
33
+ 1. Dispatch Reviewer A and Reviewer B in parallel with identical briefs but separate contexts.
34
+ 2. Collect both reports. Each categorizes findings: must-fix / should-fix / consider.
35
+ 3. **AND-gate:** If **either** reviewer has must-fix findings → FAIL round. Run `respond-review`, fix, re-dispatch both reviewers.
36
+ 4. If both pass (zero must-fix, score ≥ 94% each) → review complete.
37
+ 5. After **5** iterations without dual pass → **stop**; report "Review cap exhausted (5/5). Human decision required." Do not merge.
38
+
39
+ > **HARD GATE** — Single-reviewer pass is insufficient. Partial agreement does not satisfy the AND-gate.
40
+
41
+ ## Process
42
+
43
+ ### 1. Prepare the review brief
44
+
45
+ Write a self-contained brief for each reviewer. Include:
46
+
47
+ - What was built (feature description, not implementation)
48
+ - Which files changed (the diff context)
49
+ - What `specs/` artifacts are relevant (active `epics/eNN-*.yaml`, `requirements/SCOPE_LATEST.yaml`, `bugs/BUG-*.md`)
50
+ - What CONVENTIONS.md requires
51
+ - What the verify command is
52
+ - What you're most uncertain about (where you want fresh eyes)
53
+ - **Security focus** — If the epic has a `specs/security/epics/<id>/THREAT_MODEL.md`, include the relevant vulnerability categories as reviewer focal points. Also include the false-positive exclusion rules so the reviewer avoids known-safe patterns. Tag the review as `security-sensitive: true` if THREAT_MODEL risk is HIGH+.
54
+
55
+ ### 2. Fan-out parallel reviewers (e45s17)
56
+
57
+ Beyond the mandatory dual-blind pair (e45s07), optionally dispatch **N dimension-specific subagents in one message** — one check per agent for broader coverage (OpenAI Codex `code-review-*` pattern):
58
+
59
+ | Agent | Focus |
60
+ |-------|-------|
61
+ | R-correctness | Logic, edge cases, verify command result |
62
+ | R-conventions | CONVENTIONS.md, test quality (F.I.R.S.T) |
63
+ | R-security | Injection, auth, secrets (when `security-sensitive`) |
64
+ | R-design | Simpler alternatives, API shape |
65
+
66
+ Santa Method still applies: each agent is blind; AND-gate uses Reviewer A + B scores. Fan-out agents feed findings into `respond-review` but do not replace the dual-blind pair.
67
+
68
+ ### 2b. Dispatch both reviewer agents (parallel)
69
+
70
+ Use the Agent tool twice with completely fresh contexts. Each prompt must be self-contained — no references to "our conversation" or "what we discussed."
71
+
72
+ ```
73
+ You are code reviewer [A|B]. Review the following code changes independently.
74
+
75
+ Context: [feature description]
76
+ CONVENTIONS.md rules: [paste relevant sections]
77
+ Active epic shard: [paste or summarize from specs/epics/]
78
+
79
+ Diff: [paste git diff or describe changed files]
80
+
81
+ Verify command: [runnable command]
82
+
83
+ Review for:
84
+ 1. Correctness — does the code do what was intended?
85
+ 2. CONVENTIONS.md compliance — are all rules followed?
86
+ 3. Test quality — do tests verify behavior (not implementation)?
87
+ 4. Design — are there simpler or more robust approaches?
88
+ 5. Edge cases — what inputs or states could cause failures?
89
+ 6. Security — any injection, auth, or data exposure risks?
90
+ 7. Refactoring smells — explicitly name any detected Fowler smells: Mysterious Name, Duplicated Code, Feature Envy, Data Clumps, Primitive Obsession, Message Chains, Middle Man
91
+
92
+ For each finding, categorize as: must-fix / should-fix / consider.
93
+ Run the verify command and report the result.
94
+ ```
95
+
96
+ ### 3. Collect both reports
97
+
98
+ When reviewers return:
99
+ - Read every finding from **both** reports before acting on any
100
+ - Note each verify command result
101
+ - Compute quality score per reviewer: `100 × (total_items − must_fix − should_fix) / total_items`
102
+ - **AND-gate check:** both scores ≥ 94% and zero must-fix from **both**?
103
+
104
+ > **HARD GATE** — If either score < 94% or either has must-fix → FAIL round. Run `respond-review` first. The 94% threshold also applies to `npm run compliance` (scripts/audit-compliance.sh).
105
+
106
+ ### 4. Hand off to respond-review
107
+
108
+ Pass combined findings to `respond-review` to categorize and apply fixes. Increment iteration counter. Re-dispatch both reviewers until AND-gate passes or iteration 3 exhausted.
109
+
110
+ Report to user: "Review round [N/3]. Reviewer A: [score], Reviewer B: [score]. AND-gate: [PASS|FAIL]."
111
+
112
+ ## Verify
113
+
114
+ → verify: `test -f scripts/lib/parallel-review-worktrees.sh && test -f skills/request-review/SKILL.md`
@@ -0,0 +1,88 @@
1
+ ---
2
+ name: research-first
3
+ model: sonnet
4
+ description: "Look-before-build — search registries, repo, existing skills, and web for prior art before implementing. Appends Prior Art to the spec. Use after survey-context and before elaborate-spec, when adding dependencies, or when the task may already be solved."
5
+ disable-model-invocation: true
6
+ ---
7
+
8
+ # story: e03s01
9
+ # story: e21s02
10
+
11
+ # Research First
12
+
13
+ > **HARD GATE** — Do NOT implement until prior art is searched. Minimum outcome: adopt, extend, compose, or build — with evidence.
14
+
15
+ ## Process
16
+
17
+ 1. Read `specs/product/SCOPE_LATEST.yaml`, `specs/release-plan.yaml + epic shards`, and the current task statement.
18
+ 2. Search in order: this repo → bigpowers skills (`search-skills`) → package registries → web docs.
19
+ 3. **Check opensrc cache** — if the task integrates an external library, run `bash scripts/bp-opensrc-check.sh` (or `npx opensrc search <pkg>`) to find locally-cached source. Read the `src/` directory for API shapes before writing any integration code.
20
+ 4. For each candidate: note name, URL/path, fit (adopt | extend | compose | build).
21
+ 5. Append `## Prior Art` to `requirements/SCOPE_LATEST.yaml` notes or the active epic story.
22
+
23
+ ## opensrc Integration
24
+
25
+ `opensrc` is a local cache of 200+ open-source repos and npm/PyPI packages. Query it before building any external integration to avoid re-inventing documented API shapes.
26
+
27
+ ```bash
28
+ # Check if a package is cached
29
+ npx opensrc search <package-name>
30
+
31
+ # Or use the bundled helper (checks all deps from package.json or requirements.txt)
32
+ bash scripts/bp-opensrc-check.sh [package.json|requirements.txt]
33
+ ```
34
+
35
+ If opensrc finds a match, read its `src/` or source directory and append findings to the **Prior Art** section:
36
+
37
+ ```
38
+ opensrc: found <pkg> v<version> — exports <key classes/functions>
39
+ ```
40
+
41
+ If opensrc is not installed or the package is not cached, fall through to web docs normally.
42
+
43
+ ## Outcome matrix
44
+
45
+ | Verdict | Action |
46
+ |---------|--------|
47
+ | **adopt** | Use as-is; link in plan; no new code |
48
+ | **extend** | Wrap or configure existing solution |
49
+ | **compose** | Chain existing skills/modules |
50
+ | **build** | New implementation — justify why others failed |
51
+
52
+ ## Verify
53
+
54
+ → verify: `grep -rq 'Prior Art' specs/product specs/release-plan.yaml specs/epics 2>/dev/null`
55
+
56
+ See [REFERENCE.md](REFERENCE.md) for search commands and registry checklist.
57
+
58
+ ---
59
+
60
+ # Research First — Reference
61
+
62
+ ## Search commands
63
+
64
+ ```bash
65
+ # Repo prior art
66
+ rg -l "<keyword>" --glob '!node_modules' .
67
+ find . -maxdepth 3 -name "SKILL.md" | xargs grep -l "<intent>"
68
+
69
+ # Installed packages (if package.json exists)
70
+ cat package.json | jq '.dependencies,.devDependencies' 2>/dev/null
71
+ ```
72
+
73
+ ## Registry checklist
74
+
75
+ - [ ] npm / PyPI / crates.io (if applicable)
76
+ - [ ] Existing bigpowers skill (`bash scripts/build-skill-index.sh && rg "<intent>" specs/SKILL-SEARCH-INDEX_LATEST.md`)
77
+ - [ ] Project `docs/` and `specs/adr/`
78
+ - [ ] Official library documentation (quote one API detail)
79
+
80
+ ## Prior Art template
81
+
82
+ ```markdown
83
+ ## Prior Art
84
+
85
+ | Candidate | Source | Verdict | Notes |
86
+ |-----------|--------|---------|-------|
87
+ | ... | ... | adopt/extend/compose/build | ... |
88
+ ```
@@ -0,0 +1,22 @@
1
+ ---
2
+ name: reset-baseline
3
+ model: haiku
4
+ description: "Restore the project to a known clean state between agent runs or experiments. Use between benchmark runs, after a failed spike, or when user wants a clean working tree."
5
+ disable-model-invocation: true
6
+ ---
7
+
8
+ # Reset Baseline
9
+
10
+ > **HARD GATE** — Confirm with user before any destructive git operation. Never `reset --hard` without explicit approval.
11
+
12
+ ## Process
13
+
14
+ 1. `git status` — list uncommitted and untracked files.
15
+ 2. Ask: stash, discard, or keep each category.
16
+ 3. Safe defaults: `git stash push -u -m "reset-baseline"` for WIP; never force-push.
17
+ 4. Re-run `setup-environment` after reset.
18
+ 5. Run test baseline from `kickoff-branch` verify command.
19
+
20
+ ## Verify
21
+
22
+ → verify: `git rev-parse --git-dir >/dev/null 2>&1 && test -f skills/reset-baseline/SKILL.md`
@@ -0,0 +1,72 @@
1
+ ---
2
+ name: respond-review
3
+ model: sonnet
4
+ description: "Act on a reviewer agent's feedback systematically — categorize findings, apply fixes, verify tests still pass. Use after request-review returns a report, or when user wants to work through code review findings."
5
+ disable-model-invocation: true
6
+ ---
7
+
8
+ # Respond Review
9
+ > **HARD GATE** — **HARD GATE** — Every reviewer comment must be addressed (fix, disagree + document reason, or ask clarification). Do NOT ignore feedback and merge.
10
+
11
+
12
+ Work through reviewer findings systematically. Don't apply changes blindly — categorize first, then decide, then fix, then verify.
13
+
14
+ ## Process
15
+
16
+ ### 1. Read the full review report
17
+
18
+ Read every finding before acting on any of them. Get the full picture first.
19
+
20
+ ### 2. Categorize findings
21
+
22
+ For each finding, assign a category:
23
+
24
+ | Category | Meaning | Action |
25
+ |----------|---------|--------|
26
+ | **must-fix** | Correctness bug, security issue, test failure, CONVENTIONS.md violation | Fix before proceeding |
27
+ | **should-fix** | Code quality issue, naming, clarity — worth fixing but not blocking | Fix if time allows |
28
+ | **consider** | Architectural suggestion, alternative approach — may or may not apply | Discuss with user |
29
+
30
+ Create a numbered list of all findings with their categories.
31
+
32
+ ### 3. Confirm with user (for consider-category items)
33
+
34
+ For each "consider" item, briefly describe the trade-off and ask: "Apply, skip, or discuss?"
35
+
36
+ ### 4. Apply must-fix items first
37
+
38
+ Fix every must-fix item. For each one:
39
+ - Describe what you're changing and why
40
+ - Make the change
41
+ - Run the verify command if one exists for this area
42
+
43
+ ### 5. Apply should-fix items
44
+
45
+ Apply should-fix items. If any are large enough to warrant their own commit, note them separately.
46
+
47
+ ### 6. Run the full suite
48
+
49
+ After all changes are applied:
50
+
51
+ ```bash
52
+ <full test command>
53
+ <typecheck command>
54
+ <lint command>
55
+ ```
56
+
57
+ - [ ] All tests pass
58
+ - [ ] No type errors
59
+ - [ ] No lint violations
60
+
61
+ ### 7. Report
62
+
63
+ Summarize what was applied and what was skipped:
64
+
65
+ ```
66
+ Applied (must-fix): #1, #2, #3
67
+ Applied (should-fix): #4
68
+ Skipped (consider): #5 — agreed with user to defer
69
+ All tests pass.
70
+ ```
71
+
72
+ Suggest next skill: `commit-message`.
@@ -0,0 +1,86 @@
1
+ ---
2
+ name: run-benchmark
3
+ model: haiku
4
+ description: "Run skill quality benchmarks from specs/benchmarks/ definitions — N-run with/without-skill delta grading, train/validation split, pass@k + benchmark.json reports. Use before and after evolve-skill to prove quality changes are improvements, not regressions."
5
+ disable-model-invocation: true
6
+ ---
7
+
8
+ # Run Benchmark
9
+
10
+ > **HARD GATE** — Do NOT use benchmark scores to declare a skill "good" or "bad" in isolation. Benchmarks measure relative quality vs. a baseline — they catch regressions, they do not certify correctness.
11
+
12
+ Reads benchmark definitions from `specs/benchmarks/`, executes each scenario's grader with and without the skill loaded, and writes a structured `pass@k` report with delta grading that `evolve-skill` consumes.
13
+
14
+ ## With/Without-Skill Delta Grading
15
+
16
+ Every scenario runs N times (default 3) in two modes: **with** the skill loaded and **without** (bare agent with only CLAUDE.md). The delta `Δ = pass@k_with − pass@k_without` isolates the skill's causal contribution. A negative delta is a regression flag.
17
+
18
+ ## Train/Validation Split
19
+
20
+ Benchmark definitions partition scenarios into two sets:
21
+
22
+ | Set | Tag | Purpose |
23
+ |-----|-----|---------|
24
+ | **Train** | `split: train` | Development scenarios — used while iterating. Hitting 100% on train is expected. |
25
+ | **Validation** | `split: validation` | Held-out scenarios — the real quality signal. Overfitting train while validation stagnates is a design smell. |
26
+
27
+ `pass@k` is reported separately for train and validation. Validation score is authoritative; train score is iteration guidance only.
28
+
29
+ ## Usage
30
+
31
+ ```bash
32
+ bash scripts/run-benchmark.sh <skill-name> # benchmark single skill
33
+ bash scripts/run-benchmark.sh --all # benchmark all with definitions
34
+ bash scripts/run-benchmark.sh <skill-name> --baseline # pin results as baseline
35
+ ```
36
+
37
+ ## Process
38
+
39
+ 1. **Locate definition** — Read `specs/benchmarks/<skill>.yaml`. If absent, stop with message.
40
+
41
+ 2. **Partition scenarios** — Split by `split` field (`train` → iteration, `validation` → authoritative, default: `validation`).
42
+
43
+ 3. **Run each scenario (N-run delta)** — For each scenario, run grader N times (default 3, configurable via `runs:`):
44
+ - **Without skill:** Agent with only CLAUDE.md/CONVENTIONS.md
45
+ - **With skill:** Agent with the skill under test active
46
+ - Code grader: `bash -c <command>`, exit 0 → PASS. Timeout: 15s.
47
+ - Rubric grader: yes/no per criterion, ≥ 80% yes → PASS.
48
+ - Record: `{scenario_id: {with: [P/F,...], without: [P/F,...]}}`
49
+
50
+ 4. **Calculate scores** — Per split (train, validation) and mode (with, without):
51
+ - `pass@k = sum(weight × pass_rate) / sum(weights)` where `pass_rate = passes/runs`
52
+ - `Δ = pass@k_with − pass@k_without` — causal contribution
53
+ - Round to 2 decimal places
54
+
55
+ 5. **Write benchmark.json** to `specs/benchmarks/reports/benchmark-<skill>.json`:
56
+ ```json
57
+ {"skill":"survey-context","run_date":"2026-06-22","runs_per_scenario":3,"train":{"with_skill":0.92,"without_skill":0.67,"delta":0.25,"scenarios":["s01","s02"]},"validation":{"with_skill":0.83,"without_skill":0.60,"delta":0.23,"scenarios":["s03","s04","s05"]}}
58
+ ```
59
+
60
+ 6. **Write YAML report** to `specs/benchmarks/reports/BENCHMARK-<skill>-<YYYY-MM-DD>.yaml`:
61
+ ```yaml
62
+ skill: survey-context
63
+ run_date: "2026-06-22"
64
+ runs_per_scenario: 3
65
+ train:
66
+ pass_at_k_with: 0.92
67
+ pass_at_k_without: 0.67
68
+ delta: 0.25
69
+ validation:
70
+ pass_at_k_with: 0.83
71
+ pass_at_k_without: 0.60
72
+ delta: 0.23
73
+ scenarios:
74
+ - id: s01
75
+ split: train
76
+ with_pass_rate: 1.0
77
+ without_pass_rate: 0.67
78
+ delta: 0.33
79
+ weight: 1.0
80
+ ```
81
+
82
+ 7. **Baseline** (`--baseline`) — Copy to `BASELINE-<skill>.yaml` + `baseline-<skill>.json`.
83
+
84
+ 8. **Compare to baseline** — `IMPROVED: Δ 0.17 → 0.25` / `REGRESSION: Δ 0.25 → 0.17 — do NOT ship` / `STABLE`.
85
+
86
+ 9. **Delta threshold gate** — Validation Δ < 0.0 blocks release. Δ < 0.05 warns (marginal). Min meaningful threshold: 0.05.