bigpowers 2.87.4 → 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 (258) 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 +7 -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/test-install-helpers.js +31 -0
@@ -0,0 +1,105 @@
1
+ ---
2
+ name: inspect-quality
3
+ description: "Interactive QA session where user reports bugs or issues conversationally, and the agent logs them to specs/bugs/registry.yaml with a structured audit schema. Explores the codebase in the background for context and domain language. Use when user wants to report bugs, do QA, or mentions \"QA session\"."
4
+ ---
5
+
6
+ # Inspect Quality
7
+ > **HARD GATE** — **HARD GATE** — Quality metrics (coverage, lint, cyclomatic complexity, security scans) must be monitored. If a metric degrades, surface it as a blocker. Do NOT accept regressions.
8
+
9
+
10
+ Run an interactive QA session. The user describes problems they're encountering. You clarify, explore the codebase for context, and log each issue to `specs/bugs/registry.yaml` with a structured, durable format.
11
+
12
+ ## For each issue the user raises
13
+
14
+ ### 1. Listen and lightly clarify
15
+
16
+ Let the user describe the problem in their own words. Ask **at most 2–3 short clarifying questions** focused on:
17
+
18
+ - What they expected vs what actually happened
19
+ - Steps to reproduce (if not obvious)
20
+ - Whether it's consistent or intermittent
21
+
22
+ Do NOT over-interview. If the description is clear enough to log, move on.
23
+
24
+ ### 2. Explore the codebase in the background
25
+
26
+ Kick off an Agent (subagent_type=Explore) to understand the relevant area. The goal is NOT to find a fix — it's to:
27
+
28
+ - Learn the domain language used in that area (check `specs/UBIQUITOUS_LANGUAGE_LATEST.md` if present)
29
+ - Understand what the feature is supposed to do
30
+ - Identify the user-facing behavior boundary
31
+
32
+ ### 3. Assess scope: single issue or breakdown?
33
+
34
+ Break down when:
35
+
36
+ - The fix spans multiple independent areas
37
+ - There are clearly separable concerns that could be worked on in parallel
38
+ - The user describes something with multiple distinct failure modes
39
+
40
+ Keep as a single issue when:
41
+
42
+ - It's one behavior that's wrong in one place
43
+ - The symptoms are all caused by the same root behavior
44
+
45
+ ### 4. Log to specs/bugs/registry.yaml
46
+
47
+ Append the issue to `specs/bugs/registry.yaml`. Create the `specs/bugs/` directory if it doesn't exist.
48
+
49
+ #### registry.yaml format
50
+
51
+ The file maintains a Markdown table with the following columns (derived from structured audit practice):
52
+
53
+ | Field | Description |
54
+ |-------|-------------|
55
+ | `bug_id` | `BUG-YYYY-MM-DDTHHMMSS` |
56
+ | `date` | `YYYY-MM-DD` |
57
+ | `severity` | `critical` / `high` / `medium` / `low` |
58
+ | `priority` | `p0` / `p1` / `p2` / `p3` |
59
+ | `scope` | kebab-case area (e.g. `auth`, `checkout`) |
60
+ | `what_happened` | actual behavior (user-facing terms) |
61
+ | `what_expected` | expected behavior |
62
+ | `steps_to_reproduce` | numbered steps |
63
+ | `root_cause` | one-line hypothesis |
64
+ | `files_changed` | filled in after fix |
65
+ | `approach` | filled in after fix |
66
+ | `risk_level` | `low` / `medium` / `high` |
67
+ | `new_tests` | count (filled in after fix) |
68
+ | `type_check` | `pass` / `fail` (filled in after fix) |
69
+ | `lint` | `pass` / `fail` (filled in after fix) |
70
+ | `commit_type` | `fix` / `fix!` / `feat` (filled in after fix) |
71
+ | `release_type` | `patch` / `minor` / `major` (filled in after fix) |
72
+ | `commit_message` | Conventional Commits message (filled in after fix) |
73
+ | `follow_ups` | semicolon-separated follow-up items |
74
+ | `file` | path to detailed `specs/bugs/BUG-*.md` (filled in by investigate-bug) |
75
+ | `status` | `open` / `in-progress` / `fixed` / `wont-fix` |
76
+
77
+ When a bug is fixed (via `validate-fix`), update the relevant row with the resolution fields.
78
+
79
+ #### Issue body (for context below the table)
80
+
81
+ For each bug, also append a detail section:
82
+
83
+ ```markdown
84
+ ### BUG-YYYY-MM-DDTHHMMSS: [short title]
85
+
86
+ **What happened:** [actual behavior, plain language]
87
+ **What I expected:** [expected behavior]
88
+ **Steps to reproduce:**
89
+ 1. [Step 1]
90
+ 2. [Step 2]
91
+
92
+ **Additional context:** [domain-language observations, no file paths]
93
+ ```
94
+
95
+ #### Rules for all entries
96
+
97
+ - **bug_id** uses full timestamp: `BUG-YYYY-MM-DDTHHMMSS` — matches the individual bug file name in `specs/bugs/`
98
+ - **No file paths or line numbers** — these go stale
99
+ - **Use the project's domain language** (check `specs/UBIQUITOUS_LANGUAGE_LATEST.md` if it exists)
100
+ - **Describe behaviors, not code** — "the sync service fails to apply the patch" not "applyPatch() throws"
101
+ - **Reproduction steps are mandatory** — if you can't determine them, ask the user
102
+
103
+ ### 5. Continue the session
104
+
105
+ After logging, ask: "Next issue, or are we done?" Keep going until the user says done. Each issue is independent — don't batch them.
@@ -0,0 +1,126 @@
1
+ ---
2
+ name: investigate-bug
3
+ description: "Investigate a bug or issue by exploring the codebase to find root cause, then write a TDD-based fix plan to specs/bugs/BUG-*.md. Use when user reports a bug, wants to investigate a problem, mentions \"triage\", or wants to plan a fix."
4
+ ---
5
+
6
+ # Investigate Bug
7
+
8
+ **Boundary**: End-to-end bug entry point — history check → RCA (via `diagnose-root`) → fix approach → TDD plan → bug file. Delegates the 4-phase RCA to `diagnose-root`; does not re-implement it.
9
+
10
+ Investigate a reported problem, find its root cause, and write a TDD fix plan to `specs/bugs/BUG-*.md`. This is a mostly hands-off workflow — minimize questions to the user.
11
+
12
+ ## Process
13
+
14
+ ### 0. Read previous bug history
15
+
16
+ Before starting diagnosis:
17
+
18
+ 1. Read `specs/bugs/registry.yaml` (if it exists) — check for prior bugs in the same `scope` or with similar symptoms.
19
+ 2. If a relevant prior bug is found, read the corresponding `specs/bugs/BUG-*.md` file to understand previous root cause analysis and fix approach.
20
+ 3. Note in your investigation whether this is a recurrence, a related issue, or novel.
21
+
22
+ ### 1. Capture the problem
23
+
24
+ Get a brief description of the issue from the user. If they haven't provided one, ask ONE question: "What's the problem you're seeing?"
25
+
26
+ Do NOT ask follow-up questions yet. Start investigating immediately.
27
+
28
+ > **Security-impact assessment** — After capturing the problem, assess and document: `Security impact: NONE / LOW / MEDIUM / HIGH / CRITICAL`. If HIGH or CRITICAL, assign bug severity HIGH and document the exploit path in findings. If MEDIUM+, include exploit path in the bug file. Document "no security exploit path identified" for NONE/LOW.
29
+
30
+ ### 2. Explore and diagnose (4-phase RCA)
31
+
32
+ Run the 4-phase root-cause analysis via the `diagnose-root` skill (Reproduce → Isolate → Hypothesize → Verify). That skill is the canonical RCA engine — do not re-implement the phases here.
33
+
34
+ Also look at:
35
+ - Recent changes to affected files (`git log --oneline <file>`)
36
+ - Existing tests (what's tested, what's missing)
37
+ - Similar patterns elsewhere in the codebase that work correctly
38
+
39
+ > **HARD GATE** — Do NOT proceed to Step 3 (Fix Approach) until `diagnose-root` Phase 4 produces a verified root cause. "It probably is X" is not verified.
40
+
41
+ ### 3. Identify the fix approach
42
+
43
+ Based on your investigation, determine:
44
+
45
+ - The minimal change needed to fix the root cause
46
+ - Which modules/interfaces are affected
47
+ - What behaviors need to be verified via tests
48
+ - Whether this is a regression, missing feature, or design flaw
49
+ - Risk level: Low / Medium / High
50
+
51
+ ### 4. Design TDD fix plan
52
+
53
+ Create a concrete, ordered list of RED-GREEN cycles. Each cycle is one vertical slice:
54
+
55
+ - **RED**: Describe a specific test that captures the broken/missing behavior
56
+ - **GREEN**: Describe the minimal code change to make that test pass
57
+
58
+ Rules:
59
+ - Tests verify behavior through public interfaces, not implementation details
60
+ - One test at a time, vertical slices (NOT all tests first, then all code)
61
+ - Each test should survive internal refactors
62
+ - Include a final refactor step if needed
63
+ - **Durability**: Only suggest fixes that would survive radical codebase changes. Tests assert on observable outcomes (API responses, UI state, user-visible effects), not internal state.
64
+
65
+ ### 5. Write the bug file
66
+
67
+ Save the investigation and fix plan to `specs/bugs/BUG-NNN-slug.md`. Create the `specs/bugs/` directory if it doesn't exist.
68
+
69
+ After writing, append a row to `specs/bugs/registry.yaml` with: bug_id (same timestamp), date, severity, priority, scope, summary, and file path. Create `specs/bugs/registry.yaml` if it doesn't exist.
70
+
71
+ <diagnosis-template>
72
+
73
+ # BUG-YYYY-MM-DDTHHMMSS: [short title]
74
+
75
+ ## Problem
76
+
77
+ A clear description of the bug or issue, including:
78
+ - What happens (actual behavior)
79
+ - What should happen (expected behavior)
80
+ - How to reproduce (if applicable)
81
+
82
+ ## Root Cause Analysis
83
+
84
+ Describe what you found during investigation:
85
+ - The code path involved
86
+ - Why the current code fails
87
+ - Any contributing factors
88
+ - Risk level: Low / Medium / High
89
+
90
+ Do NOT include specific file paths, line numbers, or implementation details that couple to current code layout. Describe modules, behaviors, and contracts instead.
91
+
92
+ ## TDD Fix Plan
93
+
94
+ A numbered list of RED-GREEN cycles:
95
+
96
+ 1. **RED**: Write a test that [describes expected behavior]
97
+ **GREEN**: [Minimal change to make it pass]
98
+ **verify**: [runnable command]
99
+
100
+ 2. **RED**: Write a test that [describes next behavior]
101
+ **GREEN**: [Minimal change to make it pass]
102
+ **verify**: [runnable command]
103
+
104
+ **REFACTOR**: [Any cleanup needed after all tests pass]
105
+
106
+ ## Acceptance Criteria
107
+
108
+ - [ ] Criterion 1
109
+ - [ ] Criterion 2
110
+ - [ ] All new tests pass
111
+ - [ ] Existing tests still pass
112
+
113
+ ## Resolution
114
+
115
+ <!-- filled in by validate-fix -->
116
+
117
+ </diagnosis-template>
118
+
119
+ After writing the bug file, print a one-line summary of the root cause and suggest running `kickoff-branch` next to create a fix branch.
120
+
121
+ ## References
122
+
123
+ <!-- story: e35s10 -->
124
+
125
+ - [Feathers' Seams & Characterization Tests](../../docs/references/feathers.md) — seam types, characterization tests, and the legacy code change algorithm
126
+ - [Fowler's Code Smells](../../docs/references/fowler.md) — identifying structural problems by smell before investigating
@@ -0,0 +1,142 @@
1
+ ---
2
+ name: kickoff-branch
3
+ description: "Create a git worktree and feature branch, then verify a clean test baseline before any code is written. Use when starting a new feature or task, when user wants to work in isolation from main, or mentions \"start a branch\" or \"new worktree\"."
4
+ ---
5
+
6
+ # story: e51s03
7
+ # story: e20s03
8
+
9
+
10
+ # Kickoff Branch
11
+
12
+ > **HARD GATE** — Direct work on `main` or `master` is PROHIBITED. Every task MUST start with this skill to create a feature branch or worktree.
13
+ >
14
+ > **HARD GATE** — Do NOT proceed with development until **Preflight** passes on the default branch. Red Preflight blocks branch creation and all forward work — invoke `quick-fix` or `fix-bug` per CONVENTIONS § Discovered Defects.
15
+
16
+ Create an isolated working environment before touching any code. **Preflight must be green** before you write feature code — solo-default owns the whole tree, not just the current task diff.
17
+
18
+ ## Process
19
+
20
+ ### 1. Confirm task name
21
+
22
+ Ask if not already known: "What's the name of this feature or task?" Use it as the branch name slug (kebab-case, max 40 chars).
23
+
24
+ ### 2. Anchor on default branch (main or master)
25
+
26
+ > **HARD GATE** — Kickoff MUST start from an updated, clean default branch in the **primary** repository root (not a linked worktree).
27
+
28
+ ```bash
29
+ # Detect default branch
30
+ DEFAULT=$(git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's@^refs/remotes/origin/@@' || echo main)
31
+
32
+ git checkout "$DEFAULT"
33
+ git pull --ff-only origin "$DEFAULT" # skip if no remote
34
+ git status # working tree MUST be clean
35
+ git log --oneline -5
36
+ ```
37
+
38
+ **Spec-only pre-kickoff** — before enforcing the clean-tree gate, check whether dirty files are spec artifacts:
39
+
40
+ ```bash
41
+ DIRTY=$(git status --porcelain | awk '{print $2}')
42
+ NON_SPEC=$(echo "$DIRTY" | grep -v '^specs/' || true)
43
+
44
+ if [ -z "$DIRTY" ]; then
45
+ : # clean — proceed
46
+ elif [ -z "$NON_SPEC" ]; then
47
+ # spec-only dirty tree — offer auto-commit
48
+ echo "Dirty spec artifacts: $(echo $DIRTY | tr '\n' ' ')"
49
+ read -p "Commit spec artifacts before kickoff? [Y/n]: " CONFIRM
50
+ CONFIRM=${CONFIRM:-Y}
51
+ if [[ "$CONFIRM" =~ ^[Yy] ]]; then
52
+ git add specs/
53
+ git commit -m "chore(state): checkpoint before kickoff"
54
+ fi
55
+ else
56
+ echo "Dirty tree: $NON_SPEC (not a spec artifact). Stash or commit before proceeding."
57
+ exit 1
58
+ fi
59
+ ```
60
+
61
+ - **Spec artifacts** match `specs/` — state.yaml, epics YAMLs, execution-status.yaml, etc.
62
+ - **Non-spec dirty files** (src/, scripts/, SKILL.md, …) still enforce the full clean-tree gate.
63
+ - If not on `$DEFAULT` after checkout, stop and fix before continuing.
64
+
65
+ ### 3. Pre-flight & Conflict Resolution
66
+
67
+ Before creating the worktree, verify the target environment is clean:
68
+
69
+ ```bash
70
+ # 1. Check for existing directory
71
+ ls -d ../<task-slug> 2>/dev/null
72
+
73
+ # 2. Check for existing branch
74
+ git branch --list <task-slug>
75
+
76
+ # 3. Check for "ghost" worktrees (metadata exists but directory is gone)
77
+ git worktree list | grep "<task-slug>"
78
+ ```
79
+
80
+ **Handling Conflicts:**
81
+ - **Directory exists:** If `../<task-slug>` already exists, ask the user if they want to use it or delete it.
82
+ - **Branch exists:** If the branch exists but no worktree is attached, ask to use the existing branch (`git worktree add ../<task-slug> <task-slug>`) or delete it.
83
+ - **Ghost worktree:** If `git worktree list` shows the path but the directory is missing, run `git worktree prune` to clear the stale metadata. `bash scripts/cleanup-worktrees.sh` does this plus reports any worktree whose branch is already merged or deleted — advisory only, it prints the `git worktree remove`/`git branch -d` commands rather than running them, so review before acting.
84
+
85
+ ### 4. Create worktree + branch
86
+
87
+ ```bash
88
+ # From the main repo root (not another worktree)
89
+ git worktree add ../<task-slug> -b <task-slug>
90
+ cd ../<task-slug>
91
+ ```
92
+
93
+ If the user prefers a branch without a worktree:
94
+ ```bash
95
+ git checkout -b <task-slug>
96
+ ```
97
+
98
+ ### 4. Verify clean baseline
99
+
100
+ > **HARD GATE (e39s02):** Acquire story lock in `specs/agent-locks.yaml` before running tests.
101
+
102
+ ```bash
103
+ LOCK="specs/agent-locks.yaml"; STORY="<story-id>"
104
+ if [ -f "$LOCK" ]; then
105
+ python3 -c "
106
+ import yaml,sys,datetime
107
+ d=yaml.safe_load(open('$LOCK'))or{'locks':[]}
108
+ for l in d['locks']:
109
+ if l['story_id']=='$STORY':print(f'LOCKED by {l[\"locked_by\"]} at {l[\"locked_at\"]}');sys.exit(1)
110
+ d['locks'].append({'story_id':'$STORY','locked_by':'agent: build-epic','locked_at':datetime.datetime.utcnow().strftime('%Y-%m-%dT%H:%M:%SZ'),'files_touched':[]})
111
+ yaml.dump(d,open('$LOCK','w'),default_flow_style=False)
112
+ print(f'LOCK ACQUIRED: $STORY')
113
+ "
114
+ fi
115
+ ```
116
+
117
+ If locked: abort. If unlocked: entry added, proceed.
118
+
119
+ Run **Preflight** (from `CLAUDE.md` Commands table, or `BP_PREFLIGHT` from `bash scripts/bp-read-agents.sh`) and confirm green before writing any code:
120
+
121
+ ```bash
122
+ # Preflight — project's full local verification stack
123
+ # bigpowers example:
124
+ npm run compliance && bash scripts/run-verification-gates.sh
125
+
126
+ # Or project-specific from CLAUDE.md / AGENTS.md
127
+ ```
128
+
129
+ - [ ] Preflight passes (all chained gates green)
130
+ - [ ] No type errors (`npm run typecheck` or equivalent, if not in Preflight)
131
+ - [ ] No lint errors (`npm run lint` or equivalent, if not in Preflight)
132
+
133
+ If Preflight is red, **stop** — route to `quick-fix` or `fix-bug`. Fix before kickoff continues.
134
+
135
+ ### 5. Confirm readiness
136
+
137
+ Report: `✓ Preflight green` + branch + worktree. Suggest next: `develop-tdd` or `execute-plan`.
138
+
139
+ ## Handoff
140
+
141
+ Gate: READY -> next: develop-tdd
142
+ Writes: state.yaml handoff.next_skill = develop-tdd
@@ -0,0 +1,63 @@
1
+ ---
2
+ name: maintain-wiki
3
+ description: "Agent-maintained OKF wiki — INGEST source docs, LINT for issues, QUERY across concept pages. Run as part of build-epic Step 8 and verify-work Phase 3."
4
+ ---
5
+
6
+ # Maintain Wiki
7
+
8
+ Three operations for keeping the OKF wiki bundle consistent with its source docs.
9
+
10
+ ## INGEST
11
+
12
+ Read source doc (CLAUDE.md, CONVENTIONS.md, or SKILL.md) and write/update OKF concept pages:
13
+
14
+ ```bash
15
+ # Regenerate skills-wiki from SKILL.md files
16
+ bash scripts/sync-skills.sh --okf
17
+
18
+ # Regenerate conventions-wiki from CONVENTIONS.md
19
+ bash scripts/decompose-conventions.sh
20
+
21
+ # Regenerate agent-guide from CLAUDE.md
22
+ bash scripts/generate-agent-guide.sh
23
+ ```
24
+
25
+ ## LINT
26
+
27
+ Check for common OKF issues:
28
+
29
+ 1. **Stale concepts** — source file mtime vs concept page mtime. If source is newer, concept is stale.
30
+ 2. **Orphan concepts** — concept page exists but source doc section no longer exists.
31
+ 3. **Missing cross-references** — skill concept pages with no `enforced_by` or `references` links.
32
+ 4. **Contradictions** — two concept pages that make opposite claims about the same topic.
33
+ 5. **Broken links** — internal OKF links that point to non-existent concept pages.
34
+
35
+ ```bash
36
+ # Quick stale check: compare source vs concept mtimes
37
+ for page in specs/skills-wiki/skills/*.md; do
38
+ skill=$(basename "$page" .md)
39
+ source="skills/$skill/SKILL.md"
40
+ if [ -f "$source" ] && [ "$page" -ot "$source" ]; then
41
+ echo "STALE: $skill (SKILL.md newer than concept page)"
42
+ fi
43
+ done
44
+ ```
45
+
46
+ ## QUERY
47
+
48
+ Search across OKF concept pages to answer questions:
49
+
50
+ ```bash
51
+ # Find all concepts about a topic
52
+ grep -rl "topic" specs/skills-wiki/ specs/conventions-wiki/ specs/agent-guide/
53
+
54
+ # Trace a convention → enforcing skills
55
+ grep -A1 "enforced_by" specs/conventions-wiki/*.md
56
+
57
+ # Find skill by description keyword
58
+ grep -ril "keyword" specs/skills-wiki/skills/*.md
59
+ ```
60
+
61
+ ## Verify
62
+
63
+ → verify: `test -d specs/skills-wiki && test -d specs/conventions-wiki && test -d specs/agent-guide`
@@ -0,0 +1,70 @@
1
+ ---
2
+ name: map-codebase
3
+ description: "Derives the tech-stack doc from scratch by scanning the codebase — analyzes stack, architecture, and gray areas (error handling, API shapes) and persists findings into specs/tech-architecture/tech-stack.md. Run when the tech doc doesn't exist yet; use survey-context to consume it once it does."
4
+ ---
5
+
6
+ # Map Codebase
7
+
8
+ Perform a deep architectural and structural analysis of the codebase. Unlike `survey-context` which identifies "where we are", `map-codebase` identifies "what we are dealing with" and "how things are done".
9
+
10
+ > **Use this vs survey-context:** `map-codebase` BUILDS the tech-stack doc by scanning the codebase from scratch. `survey-context` READS existing specs/tech-architecture docs without re-deriving them. Run `map-codebase` when `specs/tech-architecture/tech-stack.md` doesn't exist yet; run `survey-context` when it does.
11
+
12
+ > **HARD GATE** — Cold analysis only. Do NOT assume architectural patterns without reading the code. If the codebase structure surprises you, call out the delta.
13
+
14
+ ## Process
15
+
16
+ ### 1. Identify Core Stack & Dependencies
17
+ - Scan `package.json`, `Cargo.toml`, `requirements.txt`, etc.
18
+ - Identify primary framework, runtime, and critical libraries (ORM, Auth, State, UI).
19
+ - Note version constraints and any deprecated or unusual dependencies.
20
+
21
+ ### 2. Map High-Level Architecture
22
+ - Identify the entry points (CLI, Web, API).
23
+ - Map the primary data flow (e.g., Controller → Service → Repository).
24
+ - Identify where business logic lives vs. where I/O lives.
25
+ - Look for established patterns (e.g., hexagonal, layered, feature-folders).
26
+
27
+ ### 3. Analyze "Gray Areas" (The "How")
28
+ Search for patterns and anti-patterns in these categories:
29
+ - **Error Handling:** Are exceptions caught early or bubbled? Is there a global error handler? Are error messages structured?
30
+ - **API Shapes:** Is it REST, GraphQL, or RPC? What is the casing (camelCase, snake_case)? How are responses structured?
31
+ - **Type Safety:** Is it strictly typed? Are there many `any` or `unsafe` blocks? Are interfaces used for DIP?
32
+ - **Observability:** Is there structured logging? Are there health checks? Where do logs go?
33
+ - **Testing:** What is the test coverage strategy? Are mocks used? Where do tests live?
34
+
35
+ ### 4. Identify Planning "Signals"
36
+ Look for signals that will influence upcoming plans:
37
+ - **Consistency Gaps:** "Half the project uses async/await, the other half uses Promises."
38
+ - **Debt Hotspots:** "The `AuthManager` is 1500 lines and handles both JWT and session logic."
39
+ - **Integration Points:** "We need to talk to the Stripe API, but there's no wrapper yet."
40
+ - **Conventions:** "The team always uses functional components over classes."
41
+
42
+ ### 5. Persist to specs/tech-architecture/tech-stack.md
43
+ Compile all findings into `specs/tech-architecture/tech-stack.md`. This file serves as the project's "Long-Term Memory".
44
+
45
+ ```markdown
46
+ # Project Context
47
+
48
+ ## Stack
49
+ - [Framework/Language]
50
+ - [Key Libraries]
51
+
52
+ ## Architecture
53
+ - [Pattern Description]
54
+ - [Data Flow]
55
+
56
+ ## Conventions (Observed)
57
+ - [Error Handling Pattern]
58
+ - [API Design]
59
+ - [Type System]
60
+
61
+ ## Signals / Active Considerations
62
+ - [Gap 1]
63
+ - [Hotspot 2]
64
+ ```
65
+
66
+ ## When to Use
67
+ - When first joining a project.
68
+ - Before a major refactor or architectural change.
69
+ - When `survey-context` reveals a lack of domain knowledge.
70
+ - To refresh `specs/tech-architecture/tech-stack.md` after significant changes.