ma-agents 3.6.2 → 3.8.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 (951) hide show
  1. package/CONTRIBUTING.md +139 -0
  2. package/README.md +27 -11
  3. package/bin/cli.js +34 -10
  4. package/docs/deployment/vllm-nemotron.md +4 -2
  5. package/lib/.bmad-extension-plugin.build-1264-1777348888201/.claude-plugin/marketplace.json +109 -0
  6. package/lib/{bmad-extension → .bmad-extension-plugin.build-1264-1777348888201/skills}/module-help.csv +5 -5
  7. package/lib/.bmad-extension-plugin.build-1264-1777348888201/skills/module.yaml +20 -0
  8. package/lib/.bmad-extension-plugin.build-24696-1777348768444/.claude-plugin/marketplace.json +109 -0
  9. package/lib/.bmad-extension-plugin.build-24696-1777348768444/skills/module-help.csv +62 -0
  10. package/lib/.bmad-extension-plugin.build-24696-1777348768444/skills/module.yaml +20 -0
  11. package/lib/.bmad-extension-plugin.build-25428-1777348694953/.claude-plugin/marketplace.json +109 -0
  12. package/lib/.bmad-extension-plugin.build-25428-1777348694953/skills/module-help.csv +62 -0
  13. package/lib/.bmad-extension-plugin.build-25428-1777348694953/skills/module.yaml +20 -0
  14. package/lib/agents.js +36 -6
  15. package/lib/bmad-cache/bmb/.claude-plugin/marketplace.json +4 -11
  16. package/lib/bmad-cache/bmb/README.md +1 -1
  17. package/lib/bmad-cache/bmb/_git_preserved/index +0 -0
  18. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-6ecd9fc6445b1281449c5ec49a6c5794708e662e.idx +0 -0
  19. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/{pack-554778ad4e7254827618ebd2497c3f4bce9054a4.pack → pack-6ecd9fc6445b1281449c5ec49a6c5794708e662e.pack} +0 -0
  20. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-6ecd9fc6445b1281449c5ec49a6c5794708e662e.rev +0 -0
  21. package/lib/bmad-cache/bmb/_git_preserved/packed-refs +1 -1
  22. package/lib/bmad-cache/bmb/_git_preserved/refs/heads/main +1 -1
  23. package/lib/bmad-cache/bmb/_git_preserved/refs/tags/v1.7.0 +1 -0
  24. package/lib/bmad-cache/bmb/_git_preserved/shallow +1 -1
  25. package/lib/bmad-cache/bmb/package-lock.json +2 -2
  26. package/lib/bmad-cache/bmb/package.json +2 -7
  27. package/lib/bmad-cache/bmb/skills/bmad-agent-builder/assets/customize-template.toml +62 -0
  28. package/lib/bmad-cache/bmb/skills/bmad-agent-builder/assets/sample-customize-analyst.toml +87 -0
  29. package/lib/bmad-cache/bmb/skills/bmad-workflow-builder/assets/customize-template.toml +56 -0
  30. package/lib/bmad-cache/bmb/skills/bmad-workflow-builder/assets/sample-customize-product-brief.toml +51 -0
  31. package/lib/bmad-cache/bmb/tools/validate-doc-links.cjs +6 -1
  32. package/lib/bmad-cache/bmb/website/astro.config.mjs +5 -1
  33. package/lib/bmad-cache/cache-manifest.json +13 -11
  34. package/lib/bmad-cache/cis/.claude-plugin/marketplace.json +1 -1
  35. package/lib/bmad-cache/cis/README.md +1 -1
  36. package/lib/bmad-cache/cis/_git_preserved/index +0 -0
  37. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-cad8ff313ea5db860ddcc7780f03917dcba1da8d.idx +0 -0
  38. package/lib/bmad-cache/cis/_git_preserved/objects/pack/{pack-39c4fd66f4e0eb3f4d93665318df04cd356b0297.pack → pack-cad8ff313ea5db860ddcc7780f03917dcba1da8d.pack} +0 -0
  39. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-cad8ff313ea5db860ddcc7780f03917dcba1da8d.rev +0 -0
  40. package/lib/bmad-cache/cis/_git_preserved/packed-refs +1 -1
  41. package/lib/bmad-cache/cis/_git_preserved/refs/heads/main +1 -1
  42. package/lib/bmad-cache/cis/_git_preserved/shallow +1 -1
  43. package/lib/bmad-cache/cis/package.json +1 -1
  44. package/lib/bmad-cache/cis/src/module.yaml +49 -0
  45. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-brainstorming-coach/customize.toml +38 -0
  46. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-creative-problem-solver/customize.toml +38 -0
  47. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-design-thinking-coach/customize.toml +39 -0
  48. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-innovation-strategist/customize.toml +38 -0
  49. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-presentation-master/customize.toml +73 -0
  50. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-storyteller/customize.toml +60 -0
  51. package/lib/bmad-cache/cis/src/skills/bmad-cis-design-thinking/customize.toml +41 -0
  52. package/lib/bmad-cache/cis/src/skills/bmad-cis-innovation-strategy/customize.toml +41 -0
  53. package/lib/bmad-cache/cis/src/skills/bmad-cis-problem-solving/customize.toml +42 -0
  54. package/lib/bmad-cache/cis/src/skills/bmad-cis-storytelling/customize.toml +41 -0
  55. package/lib/bmad-cache/cis/tools/build-docs.mjs +8 -0
  56. package/lib/bmad-cache/cis/website/astro.config.mjs +34 -4
  57. package/lib/bmad-cache/cis/website/src/content/config.ts +2 -1
  58. package/lib/bmad-cache/cis/website/src/content/i18n/zh-CN.json +28 -0
  59. package/lib/bmad-cache/cis/website/src/lib/locales.mjs +27 -0
  60. package/lib/bmad-cache/gds/.claude-plugin/marketplace.json +7 -6
  61. package/lib/bmad-cache/gds/README.md +5 -3
  62. package/lib/bmad-cache/gds/_git_preserved/index +0 -0
  63. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-c1322f7c8531a89dc4f3f34c4955d194f286c1e6.idx +0 -0
  64. package/lib/bmad-cache/gds/_git_preserved/objects/pack/{pack-ac967149d58fba215d07238ad8881bdbdad5c9c3.pack → pack-c1322f7c8531a89dc4f3f34c4955d194f286c1e6.pack} +0 -0
  65. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-c1322f7c8531a89dc4f3f34c4955d194f286c1e6.rev +0 -0
  66. package/lib/bmad-cache/gds/_git_preserved/packed-refs +1 -1
  67. package/lib/bmad-cache/gds/_git_preserved/refs/heads/main +1 -1
  68. package/lib/bmad-cache/gds/_git_preserved/shallow +1 -1
  69. package/lib/bmad-cache/gds/package.json +1 -1
  70. package/lib/bmad-cache/gds/src/agents/gds-agent-game-architect/customize.toml +57 -0
  71. package/lib/bmad-cache/gds/src/agents/gds-agent-game-designer/customize.toml +59 -0
  72. package/lib/bmad-cache/gds/src/agents/gds-agent-game-dev/customize.toml +129 -0
  73. package/lib/bmad-cache/gds/src/agents/gds-agent-game-solo-dev/customize.toml +60 -0
  74. package/lib/bmad-cache/gds/src/agents/gds-agent-tech-writer/customize.toml +65 -0
  75. package/lib/bmad-cache/gds/src/module-help.csv +4 -4
  76. package/lib/bmad-cache/gds/src/module.yaml +43 -1
  77. package/lib/bmad-cache/gds/src/workflows/1-preproduction/gds-brainstorm-game/customize.toml +41 -0
  78. package/lib/bmad-cache/gds/src/workflows/1-preproduction/gds-create-game-brief/customize.toml +41 -0
  79. package/lib/bmad-cache/gds/src/workflows/1-preproduction/research/gds-domain-research/customize.toml +41 -0
  80. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-gdd/customize.toml +41 -0
  81. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-narrative/customize.toml +41 -0
  82. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-prd/customize.toml +41 -0
  83. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-ux-design/customize.toml +41 -0
  84. package/lib/bmad-cache/gds/src/workflows/2-design/gds-edit-gdd/customize.toml +41 -0
  85. package/lib/bmad-cache/gds/src/workflows/2-design/gds-edit-prd/customize.toml +41 -0
  86. package/lib/bmad-cache/gds/src/workflows/2-design/gds-validate-gdd/customize.toml +41 -0
  87. package/lib/bmad-cache/gds/src/workflows/2-design/gds-validate-gdd/data/genre-complexity.csv +26 -0
  88. package/lib/bmad-cache/gds/src/workflows/2-design/gds-validate-prd/customize.toml +41 -0
  89. package/lib/bmad-cache/gds/src/workflows/2-design/gds-validate-prd/data/domain-complexity.csv +15 -0
  90. package/lib/bmad-cache/gds/src/workflows/2-design/gds-validate-prd/data/project-types.csv +11 -0
  91. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-check-implementation-readiness/customize.toml +41 -0
  92. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-create-epics-and-stories/customize.toml +41 -0
  93. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-game-architecture/customize.toml +41 -0
  94. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-generate-project-context/customize.toml +41 -0
  95. package/lib/bmad-cache/gds/src/workflows/4-production/gds-code-review/customize.toml +41 -0
  96. package/lib/bmad-cache/gds/src/workflows/4-production/gds-correct-course/customize.toml +41 -0
  97. package/lib/bmad-cache/gds/src/workflows/4-production/gds-create-story/customize.toml +41 -0
  98. package/lib/bmad-cache/gds/src/workflows/4-production/gds-dev-story/customize.toml +41 -0
  99. package/lib/bmad-cache/gds/src/workflows/4-production/gds-retrospective/customize.toml +41 -0
  100. package/lib/bmad-cache/gds/src/workflows/4-production/gds-sprint-planning/customize.toml +41 -0
  101. package/lib/bmad-cache/gds/src/workflows/4-production/gds-sprint-status/customize.toml +41 -0
  102. package/lib/bmad-cache/gds/src/workflows/gametest/gds-e2e-scaffold/customize.toml +41 -0
  103. package/lib/bmad-cache/gds/src/workflows/gametest/gds-performance-test/customize.toml +41 -0
  104. package/lib/bmad-cache/gds/src/workflows/gametest/gds-playtest-plan/customize.toml +41 -0
  105. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-automate/customize.toml +41 -0
  106. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-design/customize.toml +41 -0
  107. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-framework/customize.toml +41 -0
  108. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-review/customize.toml +41 -0
  109. package/lib/bmad-cache/gds/src/workflows/gds-document-project/customize.toml +41 -0
  110. package/lib/bmad-cache/gds/src/workflows/gds-quick-flow/gds-quick-dev/customize.toml +41 -0
  111. package/lib/bmad-cache/tea/.claude-plugin/marketplace.json +1 -1
  112. package/lib/bmad-cache/tea/.github/CODE_OF_CONDUCT.md +128 -0
  113. package/lib/bmad-cache/tea/.github/FUNDING.yaml +15 -0
  114. package/lib/bmad-cache/tea/.github/ISSUE_TEMPLATE/config.yaml +11 -0
  115. package/lib/bmad-cache/tea/.github/ISSUE_TEMPLATE/feature_request.md +70 -0
  116. package/lib/bmad-cache/tea/.github/ISSUE_TEMPLATE/issue.md +61 -0
  117. package/lib/bmad-cache/tea/.github/workflows/docs.yaml +66 -0
  118. package/lib/bmad-cache/tea/.github/workflows/manual-release.yaml +216 -0
  119. package/lib/bmad-cache/tea/.github/workflows/quality.yaml +117 -0
  120. package/lib/bmad-cache/tea/.vscode/settings.json +47 -0
  121. package/lib/bmad-cache/tea/README.md +63 -55
  122. package/lib/bmad-cache/tea/_git_preserved/index +0 -0
  123. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-9b16db8eb5022c18cef1f0a27d63b6e0f4bc2b2a.idx +0 -0
  124. package/lib/bmad-cache/tea/_git_preserved/objects/pack/{pack-e75385cd52b693dbb8a3b2afb50058952543b3a2.pack → pack-9b16db8eb5022c18cef1f0a27d63b6e0f4bc2b2a.pack} +0 -0
  125. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-9b16db8eb5022c18cef1f0a27d63b6e0f4bc2b2a.rev +0 -0
  126. package/lib/bmad-cache/tea/_git_preserved/packed-refs +1 -1
  127. package/lib/bmad-cache/tea/_git_preserved/refs/heads/main +1 -1
  128. package/lib/bmad-cache/tea/_git_preserved/shallow +1 -1
  129. package/lib/bmad-cache/tea/docs/explanation/engagement-models.md +1 -1
  130. package/lib/bmad-cache/tea/docs/explanation/tea-overview.md +1 -1
  131. package/lib/bmad-cache/tea/docs/glossary/index.md +1 -1
  132. package/lib/bmad-cache/tea/docs/how-to/customization/extend-tea-with-custom-workflows.md +29 -0
  133. package/lib/bmad-cache/tea/docs/how-to/workflows/run-trace.md +27 -20
  134. package/lib/bmad-cache/tea/docs/how-to/workflows/teach-me-testing.md +2 -2
  135. package/lib/bmad-cache/tea/docs/reference/commands.md +3 -3
  136. package/lib/bmad-cache/tea/docs/reference/troubleshooting.md +36 -0
  137. package/lib/bmad-cache/tea/docs/tutorials/learn-testing-tea-academy.md +1 -1
  138. package/lib/bmad-cache/tea/package-lock.json +2 -2
  139. package/lib/bmad-cache/tea/package.json +3 -3
  140. package/lib/bmad-cache/tea/src/agents/bmad-tea/SKILL.md +54 -44
  141. package/lib/bmad-cache/tea/src/agents/bmad-tea/customize.toml +104 -0
  142. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/contract-testing.md +32 -15
  143. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/pact-broker-webhooks.md +237 -0
  144. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  145. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/pact-mcp.md +1 -0
  146. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  147. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/pactjs-utils-overview.md +15 -12
  148. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  149. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/pactjs-utils-zod-to-pact.md +262 -0
  150. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/webhook-module-setup.md +122 -0
  151. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/webhook-providers.md +155 -0
  152. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/webhook-risk-guidance.md +114 -0
  153. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/webhook-template-matchers.md +160 -0
  154. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  155. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/webhook-timeout-error.md +130 -0
  156. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/knowledge/webhook-waiting-querying.md +167 -0
  157. package/lib/bmad-cache/tea/src/agents/bmad-tea/resources/tea-index.csv +13 -4
  158. package/lib/bmad-cache/tea/src/module.yaml +8 -0
  159. package/lib/bmad-cache/tea/src/workflows/testarch/README.md +5 -3
  160. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/SKILL.md +124 -1
  161. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/checklist.md +3 -2
  162. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/customize.toml +40 -0
  163. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/instructions.md +7 -0
  164. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-01-init.md +1 -1
  165. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-01b-continue.md +1 -1
  166. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-02-assess.md +1 -1
  167. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-01.md +1 -1
  168. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-02.md +1 -1
  169. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-03.md +1 -1
  170. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-04.md +1 -1
  171. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-05.md +1 -1
  172. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-06.md +1 -1
  173. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-07.md +1 -1
  174. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-05-completion.md +8 -0
  175. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-e/step-e-01-assess-workflow.md +2 -2
  176. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-e/step-e-02-apply-edits.md +9 -1
  177. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-v/step-v-01-validate.md +12 -3
  178. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/SKILL.md +80 -1
  179. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/customize.toml +40 -0
  180. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/instructions.md +2 -2
  181. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/contract-testing.md +32 -15
  182. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/pact-broker-webhooks.md +237 -0
  183. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  184. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/pact-mcp.md +1 -0
  185. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  186. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/pactjs-utils-overview.md +15 -12
  187. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  188. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/pactjs-utils-zod-to-pact.md +262 -0
  189. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/webhook-module-setup.md +122 -0
  190. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/webhook-providers.md +155 -0
  191. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/webhook-risk-guidance.md +114 -0
  192. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/webhook-template-matchers.md +160 -0
  193. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  194. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/webhook-timeout-error.md +130 -0
  195. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/knowledge/webhook-waiting-querying.md +167 -0
  196. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/resources/tea-index.csv +13 -4
  197. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-01-preflight-and-context.md +3 -3
  198. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-02-generation-mode.md +1 -1
  199. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-03-test-strategy.md +1 -1
  200. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-04-generate-tests.md +1 -1
  201. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-04a-subagent-api-failing.md +1 -1
  202. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-04c-aggregate.md +1 -1
  203. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-05-validate-and-complete.md +8 -0
  204. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-e/step-01-assess.md +1 -1
  205. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-e/step-02-apply-edit.md +8 -0
  206. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-v/step-01-validate.md +9 -1
  207. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/SKILL.md +80 -1
  208. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/customize.toml +40 -0
  209. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/instructions.md +2 -2
  210. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/contract-testing.md +18 -2
  211. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/pact-broker-webhooks.md +237 -0
  212. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  213. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/pact-mcp.md +1 -0
  214. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  215. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  216. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/webhook-module-setup.md +122 -0
  217. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/webhook-providers.md +155 -0
  218. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/webhook-risk-guidance.md +114 -0
  219. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/webhook-template-matchers.md +160 -0
  220. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  221. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/webhook-timeout-error.md +130 -0
  222. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/knowledge/webhook-waiting-querying.md +167 -0
  223. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/resources/tea-index.csv +12 -4
  224. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-c/step-01-preflight-and-context.md +1 -1
  225. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-c/step-02-identify-targets.md +1 -1
  226. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-c/step-03-generate-tests.md +1 -1
  227. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-c/step-03a-subagent-api.md +9 -1
  228. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-c/step-03c-aggregate.md +1 -1
  229. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-c/step-04-validate-and-summarize.md +8 -0
  230. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-e/step-01-assess.md +1 -1
  231. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-e/step-02-apply-edit.md +8 -0
  232. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-v/step-01-validate.md +9 -1
  233. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/SKILL.md +80 -1
  234. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/customize.toml +40 -0
  235. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/instructions.md +2 -2
  236. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/contract-testing.md +18 -2
  237. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/pact-broker-webhooks.md +237 -0
  238. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  239. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/pact-mcp.md +1 -0
  240. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  241. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  242. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/webhook-module-setup.md +122 -0
  243. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/webhook-providers.md +155 -0
  244. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/webhook-risk-guidance.md +114 -0
  245. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/webhook-template-matchers.md +160 -0
  246. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  247. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/webhook-timeout-error.md +130 -0
  248. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/knowledge/webhook-waiting-querying.md +167 -0
  249. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/resources/tea-index.csv +12 -4
  250. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-c/step-01-preflight.md +1 -1
  251. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-c/step-02-generate-pipeline.md +15 -7
  252. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-c/step-03-configure-quality-gates.md +7 -2
  253. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-c/step-04-validate-and-summary.md +8 -0
  254. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-e/step-01-assess.md +1 -1
  255. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-e/step-02-apply-edit.md +8 -0
  256. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-v/step-01-validate.md +9 -1
  257. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/SKILL.md +80 -1
  258. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/customize.toml +40 -0
  259. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/instructions.md +2 -2
  260. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/contract-testing.md +18 -2
  261. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/pact-broker-webhooks.md +237 -0
  262. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  263. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/pact-mcp.md +1 -0
  264. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  265. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  266. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/webhook-module-setup.md +122 -0
  267. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/webhook-providers.md +155 -0
  268. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/webhook-risk-guidance.md +114 -0
  269. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/webhook-template-matchers.md +160 -0
  270. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  271. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/webhook-timeout-error.md +130 -0
  272. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/knowledge/webhook-waiting-querying.md +167 -0
  273. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/resources/tea-index.csv +12 -4
  274. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-c/step-01-preflight.md +1 -1
  275. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-c/step-02-select-framework.md +1 -1
  276. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-c/step-03-scaffold-framework.md +11 -7
  277. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-c/step-04-docs-and-scripts.md +1 -1
  278. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-c/step-05-validate-and-summary.md +8 -0
  279. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-e/step-01-assess.md +1 -1
  280. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-e/step-02-apply-edit.md +8 -0
  281. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-v/step-01-validate.md +9 -1
  282. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/SKILL.md +80 -1
  283. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/customize.toml +40 -0
  284. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/instructions.md +2 -2
  285. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/contract-testing.md +18 -2
  286. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/pact-broker-webhooks.md +237 -0
  287. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  288. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/pact-mcp.md +1 -0
  289. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  290. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  291. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/webhook-module-setup.md +122 -0
  292. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/webhook-providers.md +155 -0
  293. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/webhook-risk-guidance.md +114 -0
  294. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/webhook-template-matchers.md +160 -0
  295. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  296. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/webhook-timeout-error.md +130 -0
  297. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/knowledge/webhook-waiting-querying.md +167 -0
  298. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/resources/tea-index.csv +12 -4
  299. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-c/step-01-load-context.md +1 -1
  300. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-c/step-02-define-thresholds.md +1 -1
  301. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-c/step-03-gather-evidence.md +1 -1
  302. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-c/step-04-evaluate-and-score.md +1 -1
  303. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-c/step-04e-aggregate-nfr.md +1 -1
  304. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-c/step-05-generate-report.md +8 -0
  305. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-e/step-01-assess.md +1 -1
  306. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-e/step-02-apply-edit.md +8 -0
  307. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-v/step-01-validate.md +9 -1
  308. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/SKILL.md +82 -1
  309. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/customize.toml +40 -0
  310. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/instructions.md +2 -2
  311. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/contract-testing.md +18 -2
  312. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/pact-broker-webhooks.md +237 -0
  313. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  314. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/pact-mcp.md +1 -0
  315. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  316. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  317. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/webhook-module-setup.md +122 -0
  318. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/webhook-providers.md +155 -0
  319. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/webhook-risk-guidance.md +114 -0
  320. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/webhook-template-matchers.md +160 -0
  321. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  322. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/webhook-timeout-error.md +130 -0
  323. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/knowledge/webhook-waiting-querying.md +167 -0
  324. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/resources/tea-index.csv +12 -4
  325. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-c/step-01-detect-mode.md +7 -1
  326. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-c/step-01b-resume.md +29 -15
  327. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-c/step-02-load-context.md +7 -1
  328. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-c/step-03-risk-and-testability.md +7 -1
  329. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-c/step-04-coverage-plan.md +7 -1
  330. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-c/step-05-generate-output.md +14 -0
  331. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-e/step-01-assess.md +1 -1
  332. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-e/step-02-apply-edit.md +8 -0
  333. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-v/step-01-validate.md +9 -1
  334. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/test-design-architecture-template.md +3 -0
  335. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/test-design-qa-template.md +3 -0
  336. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/test-design-template.md +3 -0
  337. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/SKILL.md +80 -1
  338. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/customize.toml +40 -0
  339. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/instructions.md +2 -2
  340. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/contract-testing.md +18 -2
  341. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/pact-broker-webhooks.md +237 -0
  342. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  343. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/pact-mcp.md +1 -0
  344. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  345. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  346. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/webhook-module-setup.md +122 -0
  347. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/webhook-providers.md +155 -0
  348. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/webhook-risk-guidance.md +114 -0
  349. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/webhook-template-matchers.md +160 -0
  350. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  351. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/webhook-timeout-error.md +130 -0
  352. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/knowledge/webhook-waiting-querying.md +167 -0
  353. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/resources/tea-index.csv +12 -4
  354. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-c/step-01-load-context.md +3 -3
  355. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-c/step-02-discover-tests.md +1 -1
  356. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-c/step-03-quality-evaluation.md +1 -1
  357. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-c/step-03a-subagent-determinism.md +43 -0
  358. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-c/step-03f-aggregate-scores.md +1 -1
  359. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-c/step-04-generate-report.md +8 -0
  360. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-e/step-01-assess.md +1 -1
  361. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-e/step-02-apply-edit.md +8 -0
  362. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-v/step-01-validate.md +9 -1
  363. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/SKILL.md +82 -1
  364. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/checklist.md +42 -18
  365. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/customize.toml +40 -0
  366. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/instructions.md +6 -4
  367. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/contract-testing.md +18 -2
  368. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/pact-broker-webhooks.md +237 -0
  369. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/pact-consumer-framework-setup.md +134 -12
  370. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/pact-mcp.md +1 -0
  371. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/pactjs-utils-consumer-helpers.md +111 -1
  372. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/pactjs-utils-provider-verifier.md +83 -1
  373. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/webhook-module-setup.md +122 -0
  374. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/webhook-providers.md +155 -0
  375. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/webhook-risk-guidance.md +114 -0
  376. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/webhook-template-matchers.md +160 -0
  377. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/webhook-testing-fundamentals.md +42 -0
  378. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/webhook-timeout-error.md +130 -0
  379. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/knowledge/webhook-waiting-querying.md +167 -0
  380. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/resources/tea-index.csv +12 -4
  381. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-c/step-01-load-context.md +74 -13
  382. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-c/step-01b-resume.md +1 -1
  383. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-c/step-02-discover-tests.md +24 -4
  384. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-c/step-03-map-criteria.md +15 -11
  385. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-c/step-04-analyze-gaps.md +210 -3
  386. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-c/step-05-gate-decision.md +477 -62
  387. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-e/step-01-assess.md +1 -1
  388. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-e/step-02-apply-edit.md +8 -0
  389. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-v/step-01-validate.md +9 -1
  390. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/trace-template.md +10 -2
  391. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/workflow-plan.md +14 -11
  392. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/workflow.yaml +24 -0
  393. package/lib/bmad-cache/tea/test/test-installation-components.js +210 -66
  394. package/lib/bmad-cache/tea/test/test-knowledge-base.js +6 -1
  395. package/lib/bmad-cache/tea/test/test-release-metadata.js +71 -0
  396. package/lib/bmad-cache/tea/tools/validate-agent-schema.js +73 -0
  397. package/lib/bmad-customize/bmm-qa.customize.yaml +1 -1
  398. package/lib/bmad-extension/.claude-plugin/marketplace.json.template +117 -0
  399. package/lib/bmad-extension/skills/ma-agent-cyber/.gitkeep +0 -0
  400. package/lib/bmad-extension/skills/ma-agent-cyber/SKILL.md +49 -0
  401. package/lib/bmad-extension/skills/ma-agent-cyber/bmad-skill-manifest.yaml +11 -0
  402. package/lib/bmad-extension/skills/ma-agent-devops/.gitkeep +0 -0
  403. package/lib/bmad-extension/skills/ma-agent-devops/SKILL.md +49 -0
  404. package/lib/bmad-extension/skills/ma-agent-devops/bmad-skill-manifest.yaml +11 -0
  405. package/lib/bmad-extension/skills/ma-agent-ml/.gitkeep +0 -0
  406. package/lib/bmad-extension/skills/ma-agent-ml/SKILL.md +59 -0
  407. package/lib/bmad-extension/skills/ma-agent-ml/bmad-skill-manifest.yaml +11 -0
  408. package/lib/bmad-extension/skills/ma-agent-sqa/.gitkeep +0 -0
  409. package/lib/bmad-extension/skills/ma-agent-sqa/SKILL.md +59 -0
  410. package/lib/bmad-extension/skills/ma-agent-sqa/bmad-skill-manifest.yaml +11 -0
  411. package/lib/bmad-extension/skills/ma-agent-sre/.gitkeep +0 -0
  412. package/lib/bmad-extension/skills/ma-agent-sre/SKILL.md +49 -0
  413. package/lib/bmad-extension/skills/ma-agent-sre/bmad-skill-manifest.yaml +11 -0
  414. package/lib/bmad-extension/skills/module-help.csv +62 -0
  415. package/lib/bmad-extension/skills/module.yaml +20 -0
  416. package/lib/bmad-extension-plugin/.claude-plugin/marketplace.json +109 -0
  417. package/lib/bmad-extension-plugin/skills/add-sprint/SKILL.md +175 -0
  418. package/lib/bmad-extension-plugin/skills/add-sprint/bmad-skill-manifest.yaml +3 -0
  419. package/lib/bmad-extension-plugin/skills/add-to-sprint/SKILL.md +243 -0
  420. package/lib/bmad-extension-plugin/skills/add-to-sprint/bmad-skill-manifest.yaml +3 -0
  421. package/lib/bmad-extension-plugin/skills/bmad-dev-story/SKILL.md +6 -0
  422. package/lib/bmad-extension-plugin/skills/bmad-dev-story/bmad-skill-manifest.yaml +3 -0
  423. package/lib/bmad-extension-plugin/skills/bmad-dev-story/checklist.md +80 -0
  424. package/lib/bmad-extension-plugin/skills/bmad-dev-story/workflow.md +509 -0
  425. package/lib/bmad-extension-plugin/skills/bmad-sprint-planning/SKILL.md +6 -0
  426. package/lib/bmad-extension-plugin/skills/bmad-sprint-planning/bmad-skill-manifest.yaml +3 -0
  427. package/lib/bmad-extension-plugin/skills/bmad-sprint-planning/checklist.md +74 -0
  428. package/lib/bmad-extension-plugin/skills/bmad-sprint-planning/sprint-status-template.yaml +89 -0
  429. package/lib/bmad-extension-plugin/skills/bmad-sprint-planning/workflow.md +372 -0
  430. package/lib/bmad-extension-plugin/skills/bmad-sprint-status/SKILL.md +6 -0
  431. package/lib/bmad-extension-plugin/skills/bmad-sprint-status/bmad-skill-manifest.yaml +3 -0
  432. package/lib/bmad-extension-plugin/skills/bmad-sprint-status/workflow.md +434 -0
  433. package/lib/bmad-extension-plugin/skills/cleanup-done/.gitkeep +0 -0
  434. package/lib/bmad-extension-plugin/skills/cleanup-done/SKILL.md +215 -0
  435. package/lib/bmad-extension-plugin/skills/cleanup-done/bmad-skill-manifest.yaml +3 -0
  436. package/lib/bmad-extension-plugin/skills/close-sprint/.gitkeep +0 -0
  437. package/lib/bmad-extension-plugin/skills/close-sprint/SKILL.md +379 -0
  438. package/lib/bmad-extension-plugin/skills/close-sprint/bmad-skill-manifest.yaml +3 -0
  439. package/lib/bmad-extension-plugin/skills/create-bug-story/.gitkeep +0 -0
  440. package/lib/bmad-extension-plugin/skills/create-bug-story/SKILL.md +195 -0
  441. package/lib/bmad-extension-plugin/skills/create-bug-story/bmad-skill-manifest.yaml +3 -0
  442. package/lib/bmad-extension-plugin/skills/cyber-generate-certs/.gitkeep +0 -0
  443. package/lib/bmad-extension-plugin/skills/cyber-generate-certs/SKILL.md +27 -0
  444. package/lib/bmad-extension-plugin/skills/cyber-generate-certs/bmad-skill-manifest.yaml +3 -0
  445. package/lib/bmad-extension-plugin/skills/cyber-immunity-estimation/.gitkeep +0 -0
  446. package/lib/bmad-extension-plugin/skills/cyber-immunity-estimation/SKILL.md +29 -0
  447. package/lib/bmad-extension-plugin/skills/cyber-immunity-estimation/bmad-skill-manifest.yaml +3 -0
  448. package/lib/bmad-extension-plugin/skills/cyber-security-audit/.gitkeep +0 -0
  449. package/lib/bmad-extension-plugin/skills/cyber-security-audit/SKILL.md +27 -0
  450. package/lib/bmad-extension-plugin/skills/cyber-security-audit/bmad-skill-manifest.yaml +3 -0
  451. package/lib/bmad-extension-plugin/skills/cyber-vault-secrets/.gitkeep +0 -0
  452. package/lib/bmad-extension-plugin/skills/cyber-vault-secrets/SKILL.md +28 -0
  453. package/lib/bmad-extension-plugin/skills/cyber-vault-secrets/bmad-skill-manifest.yaml +3 -0
  454. package/lib/bmad-extension-plugin/skills/cyber-verify-docker-users/.gitkeep +0 -0
  455. package/lib/bmad-extension-plugin/skills/cyber-verify-docker-users/SKILL.md +23 -0
  456. package/lib/bmad-extension-plugin/skills/cyber-verify-docker-users/bmad-skill-manifest.yaml +3 -0
  457. package/lib/bmad-extension-plugin/skills/cyber-verify-image-signature/.gitkeep +0 -0
  458. package/lib/bmad-extension-plugin/skills/cyber-verify-image-signature/SKILL.md +22 -0
  459. package/lib/bmad-extension-plugin/skills/cyber-verify-image-signature/bmad-skill-manifest.yaml +3 -0
  460. package/lib/bmad-extension-plugin/skills/cyber-vulnerability-scan/.gitkeep +0 -0
  461. package/lib/bmad-extension-plugin/skills/cyber-vulnerability-scan/SKILL.md +28 -0
  462. package/lib/bmad-extension-plugin/skills/cyber-vulnerability-scan/bmad-skill-manifest.yaml +3 -0
  463. package/lib/bmad-extension-plugin/skills/devops-configure-infrastructure/.gitkeep +0 -0
  464. package/lib/bmad-extension-plugin/skills/devops-configure-infrastructure/SKILL.md +27 -0
  465. package/lib/bmad-extension-plugin/skills/devops-configure-infrastructure/bmad-skill-manifest.yaml +3 -0
  466. package/lib/bmad-extension-plugin/skills/devops-disconnected-deployment/.gitkeep +0 -0
  467. package/lib/bmad-extension-plugin/skills/devops-disconnected-deployment/SKILL.md +27 -0
  468. package/lib/bmad-extension-plugin/skills/devops-disconnected-deployment/bmad-skill-manifest.yaml +3 -0
  469. package/lib/bmad-extension-plugin/skills/devops-docker-compose-setup/.gitkeep +0 -0
  470. package/lib/bmad-extension-plugin/skills/devops-docker-compose-setup/SKILL.md +26 -0
  471. package/lib/bmad-extension-plugin/skills/devops-docker-compose-setup/bmad-skill-manifest.yaml +3 -0
  472. package/lib/bmad-extension-plugin/skills/devops-manage-helm/.gitkeep +0 -0
  473. package/lib/bmad-extension-plugin/skills/devops-manage-helm/SKILL.md +28 -0
  474. package/lib/bmad-extension-plugin/skills/devops-manage-helm/bmad-skill-manifest.yaml +3 -0
  475. package/lib/bmad-extension-plugin/skills/devops-sign-docker-image/.gitkeep +0 -0
  476. package/lib/bmad-extension-plugin/skills/devops-sign-docker-image/SKILL.md +24 -0
  477. package/lib/bmad-extension-plugin/skills/devops-sign-docker-image/bmad-skill-manifest.yaml +3 -0
  478. package/lib/bmad-extension-plugin/skills/generate-backlog/.gitkeep +0 -0
  479. package/lib/bmad-extension-plugin/skills/generate-backlog/SKILL.md +195 -0
  480. package/lib/bmad-extension-plugin/skills/generate-backlog/bmad-skill-manifest.yaml +3 -0
  481. package/lib/bmad-extension-plugin/skills/ma-agent-cyber/.gitkeep +0 -0
  482. package/lib/{bmad-extension/skills/bmad-ma-agent-cyber → bmad-extension-plugin/skills/ma-agent-cyber}/SKILL.md +1 -1
  483. package/lib/{bmad-extension/skills/bmad-ma-agent-cyber → bmad-extension-plugin/skills/ma-agent-cyber}/bmad-skill-manifest.yaml +1 -1
  484. package/lib/bmad-extension-plugin/skills/ma-agent-devops/.gitkeep +0 -0
  485. package/lib/{bmad-extension/skills/bmad-ma-agent-devops → bmad-extension-plugin/skills/ma-agent-devops}/SKILL.md +1 -1
  486. package/lib/{bmad-extension/skills/bmad-ma-agent-devops → bmad-extension-plugin/skills/ma-agent-devops}/bmad-skill-manifest.yaml +1 -1
  487. package/lib/bmad-extension-plugin/skills/ma-agent-ml/.gitkeep +0 -0
  488. package/lib/{bmad-extension/skills/bmad-ma-agent-ml → bmad-extension-plugin/skills/ma-agent-ml}/SKILL.md +1 -1
  489. package/lib/{bmad-extension/skills/bmad-ma-agent-ml → bmad-extension-plugin/skills/ma-agent-ml}/bmad-skill-manifest.yaml +1 -1
  490. package/lib/bmad-extension-plugin/skills/ma-agent-sqa/.gitkeep +0 -0
  491. package/lib/{bmad-extension/skills/bmad-ma-agent-sqa → bmad-extension-plugin/skills/ma-agent-sqa}/SKILL.md +1 -1
  492. package/lib/{bmad-extension/skills/bmad-ma-agent-sqa → bmad-extension-plugin/skills/ma-agent-sqa}/bmad-skill-manifest.yaml +1 -1
  493. package/lib/bmad-extension-plugin/skills/ma-agent-sre/.gitkeep +0 -0
  494. package/lib/{bmad-extension/skills/bmad-ma-agent-sre → bmad-extension-plugin/skills/ma-agent-sre}/SKILL.md +1 -1
  495. package/lib/{bmad-extension/skills/bmad-ma-agent-sre → bmad-extension-plugin/skills/ma-agent-sre}/bmad-skill-manifest.yaml +1 -1
  496. package/lib/bmad-extension-plugin/skills/mil498-ocd/.gitkeep +0 -0
  497. package/lib/bmad-extension-plugin/skills/mil498-ocd/SKILL.md +30 -0
  498. package/lib/bmad-extension-plugin/skills/mil498-ocd/bmad-skill-manifest.yaml +5 -0
  499. package/lib/bmad-extension-plugin/skills/mil498-ocd/prompts/01-discover-project-artifacts.md +26 -0
  500. package/lib/bmad-extension-plugin/skills/mil498-ocd/prompts/02-load-template.md +10 -0
  501. package/lib/bmad-extension-plugin/skills/mil498-ocd/prompts/03-generate-document.md +90 -0
  502. package/lib/bmad-extension-plugin/skills/mil498-ocd/prompts/04-validate.md +14 -0
  503. package/lib/bmad-extension-plugin/skills/mil498-ocd/prompts/05-review.md +15 -0
  504. package/lib/bmad-extension-plugin/skills/mil498-ocd/prompts/06-save.md +15 -0
  505. package/lib/bmad-extension-plugin/skills/mil498-ocd/template.md +169 -0
  506. package/lib/bmad-extension-plugin/skills/mil498-requirement-quality/.gitkeep +0 -0
  507. package/lib/bmad-extension-plugin/skills/mil498-requirement-quality/SKILL.md +105 -0
  508. package/lib/bmad-extension-plugin/skills/mil498-requirement-quality/bmad-skill-manifest.yaml +5 -0
  509. package/lib/bmad-extension-plugin/skills/mil498-sdd/.gitkeep +0 -0
  510. package/lib/bmad-extension-plugin/skills/mil498-sdd/SKILL.md +30 -0
  511. package/lib/bmad-extension-plugin/skills/mil498-sdd/bmad-skill-manifest.yaml +5 -0
  512. package/lib/bmad-extension-plugin/skills/mil498-sdd/prompts/01-discover-project-artifacts.md +50 -0
  513. package/lib/bmad-extension-plugin/skills/mil498-sdd/prompts/02-load-template.md +10 -0
  514. package/lib/bmad-extension-plugin/skills/mil498-sdd/prompts/03-generate-document.md +98 -0
  515. package/lib/bmad-extension-plugin/skills/mil498-sdd/prompts/04-validate.md +16 -0
  516. package/lib/bmad-extension-plugin/skills/mil498-sdd/prompts/05-review.md +15 -0
  517. package/lib/bmad-extension-plugin/skills/mil498-sdd/prompts/06-save.md +19 -0
  518. package/lib/bmad-extension-plugin/skills/mil498-sdd/template.md +163 -0
  519. package/lib/bmad-extension-plugin/skills/mil498-sdp/.gitkeep +0 -0
  520. package/lib/bmad-extension-plugin/skills/mil498-sdp/SKILL.md +30 -0
  521. package/lib/bmad-extension-plugin/skills/mil498-sdp/bmad-skill-manifest.yaml +5 -0
  522. package/lib/bmad-extension-plugin/skills/mil498-sdp/prompts/01-discover-project-artifacts.md +32 -0
  523. package/lib/bmad-extension-plugin/skills/mil498-sdp/prompts/02-load-template.md +10 -0
  524. package/lib/bmad-extension-plugin/skills/mil498-sdp/prompts/03-generate-document.md +187 -0
  525. package/lib/bmad-extension-plugin/skills/mil498-sdp/prompts/04-validate.md +13 -0
  526. package/lib/bmad-extension-plugin/skills/mil498-sdp/prompts/05-review.md +15 -0
  527. package/lib/bmad-extension-plugin/skills/mil498-sdp/prompts/06-save.md +14 -0
  528. package/lib/bmad-extension-plugin/skills/mil498-sdp/template.md +307 -0
  529. package/lib/bmad-extension-plugin/skills/mil498-srs/.gitkeep +0 -0
  530. package/lib/bmad-extension-plugin/skills/mil498-srs/SKILL.md +30 -0
  531. package/lib/bmad-extension-plugin/skills/mil498-srs/bmad-skill-manifest.yaml +5 -0
  532. package/lib/bmad-extension-plugin/skills/mil498-srs/prompts/01-discover-project-artifacts.md +42 -0
  533. package/lib/bmad-extension-plugin/skills/mil498-srs/prompts/02-load-template.md +10 -0
  534. package/lib/bmad-extension-plugin/skills/mil498-srs/prompts/03-generate-document.md +100 -0
  535. package/lib/bmad-extension-plugin/skills/mil498-srs/prompts/04-validate.md +16 -0
  536. package/lib/bmad-extension-plugin/skills/mil498-srs/prompts/05-review.md +15 -0
  537. package/lib/bmad-extension-plugin/skills/mil498-srs/prompts/06-save.md +18 -0
  538. package/lib/bmad-extension-plugin/skills/mil498-srs/template.md +219 -0
  539. package/lib/bmad-extension-plugin/skills/mil498-ssdd/.gitkeep +0 -0
  540. package/lib/bmad-extension-plugin/skills/mil498-ssdd/SKILL.md +32 -0
  541. package/lib/bmad-extension-plugin/skills/mil498-ssdd/bmad-skill-manifest.yaml +5 -0
  542. package/lib/bmad-extension-plugin/skills/mil498-ssdd/prompts/01-discover-project-artifacts.md +32 -0
  543. package/lib/bmad-extension-plugin/skills/mil498-ssdd/prompts/02-load-template.md +10 -0
  544. package/lib/bmad-extension-plugin/skills/mil498-ssdd/prompts/03-csci-discovery-interview.md +43 -0
  545. package/lib/bmad-extension-plugin/skills/mil498-ssdd/prompts/04-generate-document.md +96 -0
  546. package/lib/bmad-extension-plugin/skills/mil498-ssdd/prompts/05-validate.md +18 -0
  547. package/lib/bmad-extension-plugin/skills/mil498-ssdd/prompts/06-review.md +16 -0
  548. package/lib/bmad-extension-plugin/skills/mil498-ssdd/prompts/07-save.md +16 -0
  549. package/lib/bmad-extension-plugin/skills/mil498-ssdd/template.md +154 -0
  550. package/lib/bmad-extension-plugin/skills/mil498-sss/.gitkeep +0 -0
  551. package/lib/bmad-extension-plugin/skills/mil498-sss/SKILL.md +31 -0
  552. package/lib/bmad-extension-plugin/skills/mil498-sss/bmad-skill-manifest.yaml +5 -0
  553. package/lib/bmad-extension-plugin/skills/mil498-sss/prompts/01-discover-project-artifacts.md +31 -0
  554. package/lib/bmad-extension-plugin/skills/mil498-sss/prompts/02-load-template.md +10 -0
  555. package/lib/bmad-extension-plugin/skills/mil498-sss/prompts/03-generate-document.md +108 -0
  556. package/lib/bmad-extension-plugin/skills/mil498-sss/prompts/04-validate.md +16 -0
  557. package/lib/bmad-extension-plugin/skills/mil498-sss/prompts/05-review.md +15 -0
  558. package/lib/bmad-extension-plugin/skills/mil498-sss/prompts/06-save.md +15 -0
  559. package/lib/bmad-extension-plugin/skills/mil498-sss/template.md +225 -0
  560. package/lib/bmad-extension-plugin/skills/mil498-std/.gitkeep +0 -0
  561. package/lib/bmad-extension-plugin/skills/mil498-std/SKILL.md +30 -0
  562. package/lib/bmad-extension-plugin/skills/mil498-std/bmad-skill-manifest.yaml +5 -0
  563. package/lib/bmad-extension-plugin/skills/mil498-std/prompts/01-discover-project-artifacts.md +42 -0
  564. package/lib/bmad-extension-plugin/skills/mil498-std/prompts/02-load-template.md +10 -0
  565. package/lib/bmad-extension-plugin/skills/mil498-std/prompts/03-generate-document.md +117 -0
  566. package/lib/bmad-extension-plugin/skills/mil498-std/prompts/04-validate.md +15 -0
  567. package/lib/bmad-extension-plugin/skills/mil498-std/prompts/05-review.md +15 -0
  568. package/lib/bmad-extension-plugin/skills/mil498-std/prompts/06-save.md +15 -0
  569. package/lib/bmad-extension-plugin/skills/mil498-std/template.md +188 -0
  570. package/lib/bmad-extension-plugin/skills/ml-advise/.gitkeep +0 -0
  571. package/lib/bmad-extension-plugin/skills/ml-advise/SKILL.md +76 -0
  572. package/lib/bmad-extension-plugin/skills/ml-advise/bmad-skill-manifest.yaml +3 -0
  573. package/lib/bmad-extension-plugin/skills/ml-advise/skill.json +7 -0
  574. package/lib/bmad-extension-plugin/skills/ml-analysis/.gitkeep +0 -0
  575. package/lib/bmad-extension-plugin/skills/ml-analysis/SKILL.md +60 -0
  576. package/lib/bmad-extension-plugin/skills/ml-analysis/bmad-skill-manifest.yaml +3 -0
  577. package/lib/bmad-extension-plugin/skills/ml-analysis/skill.json +7 -0
  578. package/lib/bmad-extension-plugin/skills/ml-architecture/.gitkeep +0 -0
  579. package/lib/bmad-extension-plugin/skills/ml-architecture/SKILL.md +55 -0
  580. package/lib/bmad-extension-plugin/skills/ml-architecture/bmad-skill-manifest.yaml +3 -0
  581. package/lib/bmad-extension-plugin/skills/ml-architecture/skill.json +7 -0
  582. package/lib/bmad-extension-plugin/skills/ml-detailed-design/.gitkeep +0 -0
  583. package/lib/bmad-extension-plugin/skills/ml-detailed-design/SKILL.md +67 -0
  584. package/lib/bmad-extension-plugin/skills/ml-detailed-design/bmad-skill-manifest.yaml +3 -0
  585. package/lib/bmad-extension-plugin/skills/ml-detailed-design/skill.json +7 -0
  586. package/lib/bmad-extension-plugin/skills/ml-eda/.gitkeep +0 -0
  587. package/lib/bmad-extension-plugin/skills/ml-eda/SKILL.md +56 -0
  588. package/lib/bmad-extension-plugin/skills/ml-eda/bmad-skill-manifest.yaml +3 -0
  589. package/lib/bmad-extension-plugin/skills/ml-eda/scripts/baseline_classifier.py +522 -0
  590. package/lib/bmad-extension-plugin/skills/ml-eda/scripts/class_weights_calculator.py +295 -0
  591. package/lib/bmad-extension-plugin/skills/ml-eda/scripts/clustering_explorer.py +383 -0
  592. package/lib/bmad-extension-plugin/skills/ml-eda/scripts/eda_analyzer.py +654 -0
  593. package/lib/bmad-extension-plugin/skills/ml-eda/skill.json +7 -0
  594. package/lib/bmad-extension-plugin/skills/ml-experiment/.gitkeep +0 -0
  595. package/lib/bmad-extension-plugin/skills/ml-experiment/SKILL.md +74 -0
  596. package/lib/bmad-extension-plugin/skills/ml-experiment/assets/advanced_trainer_configs.py +430 -0
  597. package/lib/bmad-extension-plugin/skills/ml-experiment/assets/quick_trainer_setup.py +233 -0
  598. package/lib/bmad-extension-plugin/skills/ml-experiment/assets/template_datamodule.py +219 -0
  599. package/lib/bmad-extension-plugin/skills/ml-experiment/assets/template_gnn_module.py +341 -0
  600. package/lib/bmad-extension-plugin/skills/ml-experiment/assets/template_lightning_module.py +158 -0
  601. package/lib/bmad-extension-plugin/skills/ml-experiment/bmad-skill-manifest.yaml +3 -0
  602. package/lib/bmad-extension-plugin/skills/ml-experiment/skill.json +7 -0
  603. package/lib/bmad-extension-plugin/skills/ml-hparam/.gitkeep +0 -0
  604. package/lib/bmad-extension-plugin/skills/ml-hparam/SKILL.md +81 -0
  605. package/lib/bmad-extension-plugin/skills/ml-hparam/bmad-skill-manifest.yaml +3 -0
  606. package/lib/bmad-extension-plugin/skills/ml-hparam/skill.json +7 -0
  607. package/lib/bmad-extension-plugin/skills/ml-ideation/.gitkeep +0 -0
  608. package/lib/bmad-extension-plugin/skills/ml-ideation/SKILL.md +50 -0
  609. package/lib/bmad-extension-plugin/skills/ml-ideation/bmad-skill-manifest.yaml +3 -0
  610. package/lib/bmad-extension-plugin/skills/ml-ideation/scripts/validate_ml_prd.py +287 -0
  611. package/lib/bmad-extension-plugin/skills/ml-ideation/skill.json +7 -0
  612. package/lib/bmad-extension-plugin/skills/ml-infra/.gitkeep +0 -0
  613. package/lib/bmad-extension-plugin/skills/ml-infra/SKILL.md +58 -0
  614. package/lib/bmad-extension-plugin/skills/ml-infra/bmad-skill-manifest.yaml +3 -0
  615. package/lib/bmad-extension-plugin/skills/ml-infra/skill.json +7 -0
  616. package/lib/bmad-extension-plugin/skills/ml-retrospective/.gitkeep +0 -0
  617. package/lib/bmad-extension-plugin/skills/ml-retrospective/SKILL.md +63 -0
  618. package/lib/bmad-extension-plugin/skills/ml-retrospective/bmad-skill-manifest.yaml +3 -0
  619. package/lib/bmad-extension-plugin/skills/ml-retrospective/skill.json +7 -0
  620. package/lib/bmad-extension-plugin/skills/ml-revision/.gitkeep +0 -0
  621. package/lib/bmad-extension-plugin/skills/ml-revision/SKILL.md +82 -0
  622. package/lib/bmad-extension-plugin/skills/ml-revision/bmad-skill-manifest.yaml +3 -0
  623. package/lib/bmad-extension-plugin/skills/ml-revision/skill.json +7 -0
  624. package/lib/bmad-extension-plugin/skills/ml-techspec/.gitkeep +0 -0
  625. package/lib/bmad-extension-plugin/skills/ml-techspec/SKILL.md +80 -0
  626. package/lib/bmad-extension-plugin/skills/ml-techspec/bmad-skill-manifest.yaml +3 -0
  627. package/lib/bmad-extension-plugin/skills/ml-techspec/skill.json +7 -0
  628. package/lib/bmad-extension-plugin/skills/modify-sprint/.gitkeep +0 -0
  629. package/lib/bmad-extension-plugin/skills/modify-sprint/SKILL.md +311 -0
  630. package/lib/bmad-extension-plugin/skills/modify-sprint/bmad-skill-manifest.yaml +3 -0
  631. package/lib/bmad-extension-plugin/skills/module-help.csv +62 -0
  632. package/lib/bmad-extension-plugin/skills/module.yaml +20 -0
  633. package/lib/bmad-extension-plugin/skills/prioritize-backlog/.gitkeep +0 -0
  634. package/lib/bmad-extension-plugin/skills/prioritize-backlog/SKILL.md +217 -0
  635. package/lib/bmad-extension-plugin/skills/prioritize-backlog/bmad-skill-manifest.yaml +3 -0
  636. package/lib/bmad-extension-plugin/skills/project-context-expansion/.gitkeep +0 -0
  637. package/lib/bmad-extension-plugin/skills/project-context-expansion/SKILL.md +238 -0
  638. package/lib/bmad-extension-plugin/skills/project-context-expansion/bmad-skill-manifest.yaml +3 -0
  639. package/lib/bmad-extension-plugin/skills/remove-from-sprint/.gitkeep +0 -0
  640. package/lib/bmad-extension-plugin/skills/remove-from-sprint/SKILL.md +184 -0
  641. package/lib/bmad-extension-plugin/skills/remove-from-sprint/bmad-skill-manifest.yaml +3 -0
  642. package/lib/bmad-extension-plugin/skills/sprint-status-view/.gitkeep +0 -0
  643. package/lib/bmad-extension-plugin/skills/sprint-status-view/SKILL.md +177 -0
  644. package/lib/bmad-extension-plugin/skills/sprint-status-view/bmad-skill-manifest.yaml +3 -0
  645. package/lib/bmad-extension-plugin/skills/sqa-audit/.gitkeep +0 -0
  646. package/lib/bmad-extension-plugin/skills/sqa-audit/SKILL.md +279 -0
  647. package/lib/bmad-extension-plugin/skills/sqa-audit/bmad-skill-manifest.yaml +3 -0
  648. package/lib/bmad-extension-plugin/skills/sqa-ieee12207/.gitkeep +0 -0
  649. package/lib/bmad-extension-plugin/skills/sqa-ieee12207/SKILL.md +374 -0
  650. package/lib/bmad-extension-plugin/skills/sqa-ieee12207/bmad-skill-manifest.yaml +3 -0
  651. package/lib/bmad-extension-plugin/skills/sqa-requirements-quality/.gitkeep +0 -0
  652. package/lib/bmad-extension-plugin/skills/sqa-requirements-quality/SKILL.md +244 -0
  653. package/lib/bmad-extension-plugin/skills/sqa-requirements-quality/bmad-skill-manifest.yaml +3 -0
  654. package/lib/bmad-extension-plugin/skills/sre-check-deployment-status/.gitkeep +0 -0
  655. package/lib/bmad-extension-plugin/skills/sre-check-deployment-status/SKILL.md +32 -0
  656. package/lib/bmad-extension-plugin/skills/sre-check-deployment-status/bmad-skill-manifest.yaml +3 -0
  657. package/lib/bmad-extension-plugin/skills/sre-check-secrets/.gitkeep +0 -0
  658. package/lib/bmad-extension-plugin/skills/sre-check-secrets/SKILL.md +23 -0
  659. package/lib/bmad-extension-plugin/skills/sre-check-secrets/bmad-skill-manifest.yaml +3 -0
  660. package/lib/bmad-extension-plugin/skills/sre-check-system-status/.gitkeep +0 -0
  661. package/lib/bmad-extension-plugin/skills/sre-check-system-status/SKILL.md +27 -0
  662. package/lib/bmad-extension-plugin/skills/sre-check-system-status/bmad-skill-manifest.yaml +3 -0
  663. package/lib/bmad-extension-plugin/skills/sre-day-2-ops/.gitkeep +0 -0
  664. package/lib/bmad-extension-plugin/skills/sre-day-2-ops/SKILL.md +26 -0
  665. package/lib/bmad-extension-plugin/skills/sre-day-2-ops/bmad-skill-manifest.yaml +3 -0
  666. package/lib/bmad-extension-plugin/skills/sre-deployment-strategies/.gitkeep +0 -0
  667. package/lib/bmad-extension-plugin/skills/sre-deployment-strategies/SKILL.md +28 -0
  668. package/lib/bmad-extension-plugin/skills/sre-deployment-strategies/bmad-skill-manifest.yaml +3 -0
  669. package/lib/bmad-extension-plugin/skills/sre-fix-deployments/.gitkeep +0 -0
  670. package/lib/bmad-extension-plugin/skills/sre-fix-deployments/SKILL.md +25 -0
  671. package/lib/bmad-extension-plugin/skills/sre-fix-deployments/bmad-skill-manifest.yaml +3 -0
  672. package/lib/bmad-extension-plugin/skills/sre-gitops-status/.gitkeep +0 -0
  673. package/lib/bmad-extension-plugin/skills/sre-gitops-status/SKILL.md +25 -0
  674. package/lib/bmad-extension-plugin/skills/sre-gitops-status/bmad-skill-manifest.yaml +3 -0
  675. package/lib/bmad.js +1379 -372
  676. package/lib/installer.js +362 -2
  677. package/package.json +23 -5
  678. package/scripts/build-bmad-cache.js +250 -47
  679. package/scripts/build-plugin.js +574 -0
  680. package/.ma-agents.json +0 -10
  681. package/AGENTS.md +0 -97
  682. package/AiAudit.md +0 -12
  683. package/DEVELOPMENT.md +0 -173
  684. package/MANIFEST.yaml +0 -3
  685. package/_bmad-output/implementation-artifacts/16-4-validation-report.md +0 -79
  686. package/_bmad-output/implementation-artifacts/17-10-rework-generate-backlog.md +0 -237
  687. package/_bmad-output/implementation-artifacts/17-11-rework-add-to-sprint.md +0 -339
  688. package/_bmad-output/implementation-artifacts/17-12-rework-remove-from-sprint.md +0 -348
  689. package/_bmad-output/implementation-artifacts/17-13-rework-sprint-status-view.md +0 -383
  690. package/_bmad-output/implementation-artifacts/17-14-rework-cleanup-done.md +0 -348
  691. package/_bmad-output/implementation-artifacts/17-15-rework-bmad-sprint-planning.md +0 -385
  692. package/_bmad-output/implementation-artifacts/17-16-rework-add-sprint.md +0 -362
  693. package/_bmad-output/implementation-artifacts/17-17-rework-modify-sprint.md +0 -477
  694. package/_bmad-output/implementation-artifacts/17-18-rework-bmad-dev-story.md +0 -377
  695. package/_bmad-output/implementation-artifacts/17-19-rework-story-status-lookup.md +0 -301
  696. package/_bmad-output/implementation-artifacts/17-20-rework-bmad-sprint-status.md +0 -508
  697. package/_bmad-output/implementation-artifacts/17-21-new-close-sprint.md +0 -455
  698. package/_bmad-output/implementation-artifacts/17-22-jira-adapter-pattern.md +0 -325
  699. package/_bmad-output/implementation-artifacts/17-23-migration-deprecation-old-files.md +0 -403
  700. package/_bmad-output/implementation-artifacts/17-24-rework-prioritize-backlog.md +0 -344
  701. package/_bmad-output/implementation-artifacts/17-9-unified-sprint-status-schema.md +0 -279
  702. package/_bmad-output/implementation-artifacts/19-1-knowledge-graph-core-library.md +0 -239
  703. package/_bmad-output/implementation-artifacts/19-2-graph-emission-create-prd.md +0 -171
  704. package/_bmad-output/implementation-artifacts/19-3-graph-emission-create-architecture-epics.md +0 -179
  705. package/_bmad-output/implementation-artifacts/19-4-graph-emission-create-story-remaining.md +0 -190
  706. package/_bmad-output/implementation-artifacts/19-5-open-graph-skill.md +0 -213
  707. package/_bmad-output/implementation-artifacts/19-6-interactive-visualization-renderer.md +0 -259
  708. package/_bmad-output/implementation-artifacts/19-7-llm-writability-validation-tests.md +0 -280
  709. package/_bmad-output/implementation-artifacts/21-1-install-time-profile-prompt.md +0 -181
  710. package/_bmad-output/implementation-artifacts/21-10-profile-reconfigure.md +0 -161
  711. package/_bmad-output/implementation-artifacts/21-11-profile-uninstall.md +0 -150
  712. package/_bmad-output/implementation-artifacts/21-2-universal-instruction-block-expansion.md +0 -253
  713. package/_bmad-output/implementation-artifacts/21-3-roomodes-template-bmad-modes.md +0 -229
  714. package/_bmad-output/implementation-artifacts/21-4-agents-md-template-opencode.md +0 -275
  715. package/_bmad-output/implementation-artifacts/21-5-clinerules-template-extension.md +0 -221
  716. package/_bmad-output/implementation-artifacts/21-6-onprem-layered-guardrails.md +0 -287
  717. package/_bmad-output/implementation-artifacts/21-7-bmad-persona-phase-prefix.md +0 -258
  718. package/_bmad-output/implementation-artifacts/21-8-vllm-reference-doc-readme.md +0 -158
  719. package/_bmad-output/implementation-artifacts/21-9-tests-validation.md +0 -368
  720. package/_bmad-output/implementation-artifacts/4-1-vs-agent-registry-entry.md +0 -173
  721. package/_bmad-output/implementation-artifacts/4-2-vs-skill-template-format.md +0 -129
  722. package/_bmad-output/implementation-artifacts/5-5-explicit-parameter-passing.md +0 -274
  723. package/_bmad-output/implementation-artifacts/5-6-fix-space-in-path-bug.md +0 -186
  724. package/_bmad-output/implementation-artifacts/7-1-test-infrastructure-setup.md +0 -144
  725. package/_bmad-output/implementation-artifacts/7-2-installer-pipeline-tests.md +0 -132
  726. package/_bmad-output/implementation-artifacts/7-3-bmad-pipeline-tests.md +0 -119
  727. package/_bmad-output/implementation-artifacts/7-4-cli-command-routing-tests.md +0 -162
  728. package/_bmad-output/implementation-artifacts/bug-bmad-recompile-fails-on-airgapped-network.md +0 -112
  729. package/_bmad-output/implementation-artifacts/bug-experimentalwarning-about-commonjs-loading-es-module-during-install.md +0 -57
  730. package/_bmad-output/implementation-artifacts/deferred-work.md +0 -9
  731. package/_bmad-output/implementation-artifacts/done/1-1-ci-cd-yes-flag.md +0 -200
  732. package/_bmad-output/implementation-artifacts/done/10-1-ensure-bmad-output-not-gitignored.md +0 -172
  733. package/_bmad-output/implementation-artifacts/done/10-2-document-bmad-output-policy.md +0 -102
  734. package/_bmad-output/implementation-artifacts/done/11-1-auto-bug-detection-skill.md +0 -119
  735. package/_bmad-output/implementation-artifacts/done/11-2-bug-story-extension-workflow.md +0 -132
  736. package/_bmad-output/implementation-artifacts/done/11-3-integrate-bug-detection-code-review.md +0 -111
  737. package/_bmad-output/implementation-artifacts/done/12-1-add-sprint-workflow.md +0 -126
  738. package/_bmad-output/implementation-artifacts/done/12-2-add-to-sprint-workflow.md +0 -137
  739. package/_bmad-output/implementation-artifacts/done/12-3-modify-sprint-workflow.md +0 -127
  740. package/_bmad-output/implementation-artifacts/done/12-4-sprint-status-assigned-items.md +0 -129
  741. package/_bmad-output/implementation-artifacts/done/13-1-project-context-template-and-generator.md +0 -179
  742. package/_bmad-output/implementation-artifacts/done/13-2-install-pipeline-integration.md +0 -138
  743. package/_bmad-output/implementation-artifacts/done/13-3-bmad-critical-actions-update.md +0 -150
  744. package/_bmad-output/implementation-artifacts/done/13-4-retrospective-expansion-trigger.md +0 -128
  745. package/_bmad-output/implementation-artifacts/done/13-5-document-project-context-generation.md +0 -118
  746. package/_bmad-output/implementation-artifacts/done/15-1-bump-bmad-method-to-6-2-1.md +0 -132
  747. package/_bmad-output/implementation-artifacts/done/15-2-restructure-extension-module.md +0 -174
  748. package/_bmad-output/implementation-artifacts/done/15-3-convert-custom-agents-to-skill-folders.md +0 -183
  749. package/_bmad-output/implementation-artifacts/done/15-4-convert-mil498-workflows-to-skill-md.md +0 -252
  750. package/_bmad-output/implementation-artifacts/done/15-5-convert-sre-devops-cyber-workflows.md +0 -232
  751. package/_bmad-output/implementation-artifacts/done/15-6-separate-built-in-agent-customizations.md +0 -163
  752. package/_bmad-output/implementation-artifacts/done/15-7-migration-detection-and-upgrade-path.md +0 -133
  753. package/_bmad-output/implementation-artifacts/done/15-8-validate-migrated-agents-and-workflows.md +0 -172
  754. package/_bmad-output/implementation-artifacts/done/15-8-validation-report.md +0 -342
  755. package/_bmad-output/implementation-artifacts/done/16-1-repository-layout-wizard.md +0 -223
  756. package/_bmad-output/implementation-artifacts/done/16-2-config-storage-and-cross-reference.md +0 -180
  757. package/_bmad-output/implementation-artifacts/done/16-3-project-context-multi-repo-section.md +0 -136
  758. package/_bmad-output/implementation-artifacts/done/16-4-validate-cross-repo-path-resolution.md +0 -137
  759. package/_bmad-output/implementation-artifacts/done/16-4-validation-report.md +0 -79
  760. package/_bmad-output/implementation-artifacts/done/16-5-fix-config-lost-on-update.md +0 -110
  761. package/_bmad-output/implementation-artifacts/done/16-6-repo-sync-check-skill.md +0 -116
  762. package/_bmad-output/implementation-artifacts/done/16-7-portable-path-storage.md +0 -109
  763. package/_bmad-output/implementation-artifacts/done/16-8-cicd-remote-mode.md +0 -97
  764. package/_bmad-output/implementation-artifacts/done/16-9-reconfigure-layout-workflow.md +0 -125
  765. package/_bmad-output/implementation-artifacts/done/17-1-sprint-entity-model.md +0 -322
  766. package/_bmad-output/implementation-artifacts/done/17-2-flat-backlog-model.md +0 -264
  767. package/_bmad-output/implementation-artifacts/done/17-3-bug-as-story-type.md +0 -208
  768. package/_bmad-output/implementation-artifacts/done/17-4-backlog-to-sprint-workflow.md +0 -209
  769. package/_bmad-output/implementation-artifacts/done/17-5-sprint-to-backlog-workflow.md +0 -221
  770. package/_bmad-output/implementation-artifacts/done/17-6-done-item-cleanup.md +0 -273
  771. package/_bmad-output/implementation-artifacts/done/17-7-multi-criteria-prioritization.md +0 -235
  772. package/_bmad-output/implementation-artifacts/done/17-8-rework-sprint-status-display.md +0 -285
  773. package/_bmad-output/implementation-artifacts/done/2-1-cpp-coding-standards-skill.md +0 -188
  774. package/_bmad-output/implementation-artifacts/done/2-2-csharp-coding-standards-skill.md +0 -211
  775. package/_bmad-output/implementation-artifacts/done/2-3-python-coding-standards-skill.md +0 -189
  776. package/_bmad-output/implementation-artifacts/done/3-1-skill-scaffolding-tool.md +0 -184
  777. package/_bmad-output/implementation-artifacts/done/3-2-skill-validation-tool.md +0 -178
  778. package/_bmad-output/implementation-artifacts/done/3-3-mandatory-skill-designation.md +0 -136
  779. package/_bmad-output/implementation-artifacts/done/3-4-bmad-persona-customization-tooling.md +0 -141
  780. package/_bmad-output/implementation-artifacts/done/3-5-specialized-agent-development-tooling.md +0 -145
  781. package/_bmad-output/implementation-artifacts/done/5-1-bmad-method-direct-dependency.md +0 -188
  782. package/_bmad-output/implementation-artifacts/done/5-2-bmad-cache-build-script.md +0 -219
  783. package/_bmad-output/implementation-artifacts/done/5-3-pre-populate-bmad-cache.md +0 -234
  784. package/_bmad-output/implementation-artifacts/done/5-4-validate-bundled-installation.md +0 -274
  785. package/_bmad-output/implementation-artifacts/done/6-1-methodology-presentation-bundle.md +0 -173
  786. package/_bmad-output/implementation-artifacts/done/8-1-move-instruction-injection-to-top.md +0 -131
  787. package/_bmad-output/implementation-artifacts/done/8-2-agent-aware-injection-strategy.md +0 -124
  788. package/_bmad-output/implementation-artifacts/done/8-3-create-bmad-extension-module.md +0 -187
  789. package/_bmad-output/implementation-artifacts/done/8-4-integration-verification.md +0 -102
  790. package/_bmad-output/implementation-artifacts/done/8-5-per-agent-enforcement-hooks-research.md +0 -126
  791. package/_bmad-output/implementation-artifacts/done/8-6-context-persistence-research.md +0 -101
  792. package/_bmad-output/implementation-artifacts/done/9-1-register-opencode-agent.md +0 -73
  793. package/_bmad-output/implementation-artifacts/done/9-2-json-merge-injection.md +0 -91
  794. package/_bmad-output/implementation-artifacts/done/9-3-json-merge-existing.md +0 -113
  795. package/_bmad-output/implementation-artifacts/done/9-4-json-error-handling.md +0 -90
  796. package/_bmad-output/implementation-artifacts/epic-11-12-shared-guardrails.md +0 -53
  797. package/_bmad-output/implementation-artifacts/epic-15-adversarial-fixes.md +0 -287
  798. package/_bmad-output/implementation-artifacts/epic-16-adversarial-review.md +0 -49
  799. package/_bmad-output/implementation-artifacts/epic-16-edge-case-review.md +0 -230
  800. package/_bmad-output/implementation-artifacts/epic-17-adversarial-review.md +0 -37
  801. package/_bmad-output/implementation-artifacts/epic-17-edge-case-review.md +0 -140
  802. package/_bmad-output/implementation-artifacts/sprint-status.yaml +0 -139
  803. package/_bmad-output/planning-artifacts/adapter-pattern-spec.md +0 -508
  804. package/_bmad-output/planning-artifacts/architecture.md +0 -2023
  805. package/_bmad-output/planning-artifacts/domain-research-roocode-2026-03-31.md +0 -295
  806. package/_bmad-output/planning-artifacts/epics.md +0 -4232
  807. package/_bmad-output/planning-artifacts/mil498-workflow-audit.md +0 -290
  808. package/_bmad-output/planning-artifacts/prd.md +0 -811
  809. package/_bmad-output/planning-artifacts/product-brief-agents-2026-03-08.md +0 -214
  810. package/_bmad-output/planning-artifacts/sprint-status-schema.md +0 -506
  811. package/_bmad-output/planning-artifacts/validation-report-prd-2026-04-07.md +0 -330
  812. package/_bmad-output/project-context.md +0 -47
  813. package/agents.code-workspace +0 -11
  814. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-554778ad4e7254827618ebd2497c3f4bce9054a4.idx +0 -0
  815. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-554778ad4e7254827618ebd2497c3f4bce9054a4.rev +0 -0
  816. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-39c4fd66f4e0eb3f4d93665318df04cd356b0297.idx +0 -0
  817. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-39c4fd66f4e0eb3f4d93665318df04cd356b0297.rev +0 -0
  818. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-brainstorming-coach/bmad-skill-manifest.yaml +0 -11
  819. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-creative-problem-solver/bmad-skill-manifest.yaml +0 -11
  820. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-design-thinking-coach/bmad-skill-manifest.yaml +0 -11
  821. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-innovation-strategist/bmad-skill-manifest.yaml +0 -11
  822. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-presentation-master/bmad-skill-manifest.yaml +0 -11
  823. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-storyteller/bmad-skill-manifest.yaml +0 -11
  824. package/lib/bmad-cache/cis/src/skills/bmad-cis-design-thinking/bmad-skill-manifest.yaml +0 -1
  825. package/lib/bmad-cache/cis/src/skills/bmad-cis-innovation-strategy/bmad-skill-manifest.yaml +0 -1
  826. package/lib/bmad-cache/cis/src/skills/bmad-cis-problem-solving/bmad-skill-manifest.yaml +0 -1
  827. package/lib/bmad-cache/cis/src/skills/bmad-cis-storytelling/bmad-skill-manifest.yaml +0 -1
  828. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-ac967149d58fba215d07238ad8881bdbdad5c9c3.idx +0 -0
  829. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-ac967149d58fba215d07238ad8881bdbdad5c9c3.rev +0 -0
  830. package/lib/bmad-cache/gds/src/agents/gds-agent-game-architect/bmad-skill-manifest.yaml +0 -11
  831. package/lib/bmad-cache/gds/src/agents/gds-agent-game-designer/bmad-skill-manifest.yaml +0 -11
  832. package/lib/bmad-cache/gds/src/agents/gds-agent-game-dev/bmad-skill-manifest.yaml +0 -11
  833. package/lib/bmad-cache/gds/src/agents/gds-agent-game-qa/bmad-skill-manifest.yaml +0 -11
  834. package/lib/bmad-cache/gds/src/agents/gds-agent-game-scrum-master/bmad-skill-manifest.yaml +0 -11
  835. package/lib/bmad-cache/gds/src/agents/gds-agent-game-solo-dev/bmad-skill-manifest.yaml +0 -11
  836. package/lib/bmad-cache/gds/src/agents/gds-agent-tech-writer/bmad-skill-manifest.yaml +0 -11
  837. package/lib/bmad-cache/gds/src/workflows/1-preproduction/gds-brainstorm-game/bmad-skill-manifest.yaml +0 -1
  838. package/lib/bmad-cache/gds/src/workflows/1-preproduction/gds-create-game-brief/bmad-skill-manifest.yaml +0 -1
  839. package/lib/bmad-cache/gds/src/workflows/1-preproduction/research/bmad-skill-manifest.yaml +0 -9
  840. package/lib/bmad-cache/gds/src/workflows/1-preproduction/research/gds-domain-research/bmad-skill-manifest.yaml +0 -1
  841. package/lib/bmad-cache/gds/src/workflows/2-design/create-prd/bmad-skill-manifest.yaml +0 -14
  842. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-gdd/bmad-skill-manifest.yaml +0 -1
  843. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-narrative/bmad-skill-manifest.yaml +0 -1
  844. package/lib/bmad-cache/gds/src/workflows/2-design/gds-create-ux-design/bmad-skill-manifest.yaml +0 -1
  845. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-check-implementation-readiness/bmad-skill-manifest.yaml +0 -1
  846. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-create-epics-and-stories/bmad-skill-manifest.yaml +0 -1
  847. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-game-architecture/bmad-skill-manifest.yaml +0 -1
  848. package/lib/bmad-cache/gds/src/workflows/3-technical/gds-generate-project-context/bmad-skill-manifest.yaml +0 -1
  849. package/lib/bmad-cache/gds/src/workflows/4-production/gds-code-review/bmad-skill-manifest.yaml +0 -1
  850. package/lib/bmad-cache/gds/src/workflows/4-production/gds-correct-course/bmad-skill-manifest.yaml +0 -1
  851. package/lib/bmad-cache/gds/src/workflows/4-production/gds-create-story/bmad-skill-manifest.yaml +0 -1
  852. package/lib/bmad-cache/gds/src/workflows/4-production/gds-dev-story/bmad-skill-manifest.yaml +0 -1
  853. package/lib/bmad-cache/gds/src/workflows/4-production/gds-retrospective/bmad-skill-manifest.yaml +0 -1
  854. package/lib/bmad-cache/gds/src/workflows/4-production/gds-sprint-planning/bmad-skill-manifest.yaml +0 -1
  855. package/lib/bmad-cache/gds/src/workflows/4-production/gds-sprint-status/bmad-skill-manifest.yaml +0 -1
  856. package/lib/bmad-cache/gds/src/workflows/gametest/gds-e2e-scaffold/bmad-skill-manifest.yaml +0 -1
  857. package/lib/bmad-cache/gds/src/workflows/gametest/gds-performance-test/bmad-skill-manifest.yaml +0 -1
  858. package/lib/bmad-cache/gds/src/workflows/gametest/gds-playtest-plan/bmad-skill-manifest.yaml +0 -1
  859. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-automate/bmad-skill-manifest.yaml +0 -1
  860. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-design/bmad-skill-manifest.yaml +0 -1
  861. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-framework/bmad-skill-manifest.yaml +0 -1
  862. package/lib/bmad-cache/gds/src/workflows/gametest/gds-test-review/bmad-skill-manifest.yaml +0 -1
  863. package/lib/bmad-cache/gds/src/workflows/gds-document-project/bmad-skill-manifest.yaml +0 -1
  864. package/lib/bmad-cache/gds/src/workflows/gds-quick-flow/gds-quick-dev/bmad-skill-manifest.yaml +0 -1
  865. package/lib/bmad-cache/gds/src/workflows/gds-quick-flow/gds-quick-dev-new-preview/bmad-skill-manifest.yaml +0 -1
  866. package/lib/bmad-cache/gds/src/workflows/gds-quick-flow/gds-quick-spec/bmad-skill-manifest.yaml +0 -1
  867. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-e75385cd52b693dbb8a3b2afb50058952543b3a2.idx +0 -0
  868. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-e75385cd52b693dbb8a3b2afb50058952543b3a2.rev +0 -0
  869. package/lib/bmad-cache/tea/_git_preserved/refs/tags/v1.10.0 +0 -1
  870. package/lib/bmad-cache/tea/src/agents/bmad-tea/bmad-skill-manifest.yaml +0 -14
  871. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/bmad-skill-manifest.yaml +0 -1
  872. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/workflow.md +0 -90
  873. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/bmad-skill-manifest.yaml +0 -1
  874. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/workflow.md +0 -41
  875. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/bmad-skill-manifest.yaml +0 -1
  876. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/workflow.md +0 -41
  877. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/bmad-skill-manifest.yaml +0 -1
  878. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/workflow.md +0 -41
  879. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/bmad-skill-manifest.yaml +0 -1
  880. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/workflow.md +0 -41
  881. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/bmad-skill-manifest.yaml +0 -1
  882. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/workflow.md +0 -41
  883. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/bmad-skill-manifest.yaml +0 -1
  884. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/workflow.md +0 -41
  885. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/bmad-skill-manifest.yaml +0 -1
  886. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/workflow.md +0 -41
  887. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/bmad-skill-manifest.yaml +0 -1
  888. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/workflow.md +0 -41
  889. package/lib/bmad-customizations/bmm-demerzel.customize.yaml +0 -36
  890. package/lib/bmad-customizations/demerzel.md +0 -32
  891. package/lib/bmad-customize/bmm-quick-flow-solo-dev.customize.yaml +0 -8
  892. package/lib/bmad-extension/module.yaml +0 -5
  893. package/out.txt +0 -0
  894. package/test/agent-injection-strategy.test.js +0 -129
  895. package/test/agents-md.test.js +0 -398
  896. package/test/bmad-extension.test.js +0 -283
  897. package/test/bmad-output-policy.test.js +0 -119
  898. package/test/bmad-persona-phase-prefix.test.js +0 -271
  899. package/test/bmad-version-bump.test.js +0 -313
  900. package/test/build-bmad-args.test.js +0 -368
  901. package/test/cicd-remote-mode.test.js +0 -224
  902. package/test/clinerules.test.js +0 -339
  903. package/test/config-layout.test.js +0 -230
  904. package/test/config-lost-on-update.test.js +0 -363
  905. package/test/config-storage.test.js +0 -275
  906. package/test/convert-agents-to-skills.test.js +0 -255
  907. package/test/create-agent.test.js +0 -232
  908. package/test/cross-repo-validation.test.js +0 -201
  909. package/test/enforcement-hooks.test.js +0 -324
  910. package/test/experimental-warning.test.js +0 -314
  911. package/test/extension-module-restructure.test.js +0 -407
  912. package/test/fixtures/README.md +0 -74
  913. package/test/fixtures/empty-project/README.md +0 -5
  914. package/test/fixtures/empty-project/package.json +0 -5
  915. package/test/fixtures/onprem-profile-baseline/.gitkeep +0 -2
  916. package/test/fixtures/standard-profile-baseline/.gitkeep +0 -2
  917. package/test/generate-project-context.test.js +0 -483
  918. package/test/instruction-block.test.js +0 -388
  919. package/test/instruction-injection.test.js +0 -336
  920. package/test/integration-verification.test.js +0 -433
  921. package/test/migration-validation.test.js +0 -506
  922. package/test/migration.test.js +0 -832
  923. package/test/offline-recompile.test.js +0 -267
  924. package/test/onprem-injection.test.js +0 -441
  925. package/test/onprem-layer.test.js +0 -419
  926. package/test/opencode-agent.test.js +0 -150
  927. package/test/opencode-json-error.test.js +0 -260
  928. package/test/opencode-json-injection.test.js +0 -264
  929. package/test/opencode-json-merge.test.js +0 -318
  930. package/test/portable-paths.test.js +0 -268
  931. package/test/profile.test.js +0 -301
  932. package/test/reconfigure.test.js +0 -436
  933. package/test/repo-layout.test.js +0 -246
  934. package/test/roo-code-agent.test.js +0 -166
  935. package/test/roo-code-injection.test.js +0 -172
  936. package/test/roomodes.test.js +0 -343
  937. package/test/skill-authoring.test.js +0 -272
  938. package/test/skill-customize-agent.test.js +0 -253
  939. package/test/skill-mandatory.test.js +0 -235
  940. package/test/skill-validation.test.js +0 -378
  941. package/test/story-15-5-workflow-skills.test.js +0 -311
  942. package/test/uninstall.test.js +0 -402
  943. package/test/yes-flag.test.js +0 -200
  944. /package/lib/bmad-cache/gds/src/{gametest → agents/gds-agent-game-dev/gametest}/qa-index.csv +0 -0
  945. /package/lib/bmad-cache/gds/src/workflows/2-design/{create-prd → gds-create-prd}/data/domain-complexity.csv +0 -0
  946. /package/lib/bmad-cache/gds/src/workflows/2-design/{create-prd → gds-create-prd}/data/project-types.csv +0 -0
  947. /package/lib/{bmad-extension/skills/bmad-ma-agent-cyber → bmad-extension-plugin/skills/add-sprint}/.gitkeep +0 -0
  948. /package/lib/{bmad-extension/skills/bmad-ma-agent-devops → bmad-extension-plugin/skills/add-to-sprint}/.gitkeep +0 -0
  949. /package/lib/{bmad-extension/skills/bmad-ma-agent-ml → bmad-extension-plugin/skills/bmad-dev-story}/.gitkeep +0 -0
  950. /package/lib/{bmad-extension/skills/bmad-ma-agent-sqa → bmad-extension-plugin/skills/bmad-sprint-planning}/.gitkeep +0 -0
  951. /package/lib/{bmad-extension/skills/bmad-ma-agent-sre → bmad-extension-plugin/skills/bmad-sprint-status}/.gitkeep +0 -0
@@ -1,4232 +0,0 @@
1
- ---
2
- stepsCompleted: [1, 2, 3, 4, 'phase2-step-01', 'phase2-step-02', 'phase2-step-03', 'phase2-step-04']
3
- workflowStatus: 'complete'
4
- completedDate: '2026-03-08'
5
- lastEdited: '2026-04-07'
6
- phase3EditHistory:
7
- - date: '2026-04-14'
8
- changes: 'Added Story 21.11: Profile Uninstall. Adds `ma-agents uninstall --profile-artifacts` to remove ma-agents-owned profile content while preserving user content and audit trails. Adds FR181 and NFR49. Closes adversarial-review Finding #17 (no uninstall / rollback). Execution order: 21.11 runs after 21.10 (both depend on full profile-dependent stamping from 21.6).'
9
- - date: '2026-04-14'
10
- changes: 'Added Story 21.10: Profile Reconfigure. Adds `ma-agents reconfigure` subcommand to change a previously-persisted profile and re-stamp all profile-dependent artifacts. Adds FR180 and NFR48. Closes adversarial-review Findings #5 (CI-default silent-downgrade) and #7 (no escape hatch once persisted). Execution order updated: 21.10 runs after 21.6 (depends on profile-dependent artifacts being layered first).'
11
- - date: '2026-04-13'
12
- changes: 'Added Epic 21: On-Prem / Local-LLM Tuning (Phase 3). 9 stories (21.1-21.9): install-time profile prompt + persistence, universal per-tool guardrail expansion, .roomodes template with BMAD-mode file-regex restrictions, expanded AGENTS.md (OpenCode), expanded .clinerules, on-prem layered guardrails, BMAD persona phase-aware prompt prefixes, vLLM reference deployment doc. Added FR172-FR179 and NFR44-NFR47 to Requirements Inventory and FR Coverage Map. Architecture Decision P3-3 covers design.'
13
- - date: '2026-04-07'
14
- changes: 'Added Epic 19: BMAD Knowledge Graph (Phase 3). 7 stories (19.1-19.7): core emitToGraph() library, graph emission for 7 BMAD skills (create-prd, create-architecture, create-epics-and-stories, create-story, validate-prd, dev-story, bmad-sprint-planning), open-graph skill with VSCode/browser detection, and interactive HTML renderer. Added FR141-FR157 to Requirements Inventory and FR Coverage Map. Added NFR38-NFR41. Updated Epic List and Development Execution Order. Fixed duplicate FR141 entry in Epic 17 coverage map (was remove-from-sprint, correctly FR129). Updated Roo Code Epic 18 proposed FRs to FR156-FR159 to avoid conflict with new Knowledge Graph FRs.'
15
- phase2EditHistory:
16
- - date: '2026-04-03'
17
- changes: 'Major rework of Epic 17: Sprint Management Model Rework. Replaced 3-file model (backlog.yaml, sprints/sprint-N.yaml, sprint-status.yaml) with unified single sprint-status.yaml approach. Stories rewritten: 17.9 (unified schema), 17.10 (generate-backlog rework), 17.11 (add-to-sprint movement semantics), 17.12 (remove-from-sprint movement semantics), 17.13 (sprint-status-view single-source read), 17.14 (cleanup-done single-source), 17.15 (bmad-sprint-planning bootstrap), 17.16 (add-sprint section-based), 17.17 (modify-sprint section-based), 17.18 (bmad-dev-story cross-section update), 17.19 (story-status-lookup cross-section search), 17.20 (bmad-sprint-status structured sections), 17.21 (close-sprint new skill), 17.22 (Jira adapter pattern), 17.23 (migration/deprecation of old files). Added FR133-FR140. Updated FR Coverage Map. Updated Epic 17 description in Epic List. Updated Development Execution Order.'
18
- - date: '2026-03-26'
19
- changes: 'Added Stories 5.5 (explicit parameter passing) and 5.6 (space-in-path fix) to Epic 5. Added Epic 15: BMAD 6.2.1 Agent Architecture Migration (8 stories: version bump, module restructure, 4 agent conversions, 11 MIL-498 workflow conversions, 23 SRE/DevOps/Cyber conversions, built-in agent separation, migration detection, validation). Added Epic 16: Multi-Repository Project Layout (4 stories: wizard, config+cross-ref, project-context section, validation). Updated FR coverage map with FR87-FR127. Updated development execution order with Phase A/B/C priority grouping. Updated cross-epic bmad.js coordination for 4 epics.'
20
- - date: '2026-03-20'
21
- changes: 'Added Epic 14: External Tooling Integration (Phase 3). 5 stories: analyst research for Jira (14.1) and Confluence/knowledge (14.2), architect abstraction layer design (14.3), and stub stories for Jira (14.4) and Confluence (14.5) implementations blocked on 14.3. Proposed FRs to be added to PRD after architecture is approved.'
22
- - date: '2026-03-19'
23
- changes: 'Added Epic 13: Project Context Auto-Generation (FR77-FR84, NFR22-NFR24). 4 stories: template+generator, install pipeline integration, BMAD critical_actions update, retrospective expansion trigger. Added FR77-FR84 to FR Coverage Map.'
24
- - date: '2026-03-15'
25
- changes: 'Adversarial review fixes: Removed deleted FR77/FR78 strikethrough lines and standalone binary strikethrough. Added FR44/FR45 to FR Coverage Map. Updated Epic 6 dependency note to reference Epic 5. Added determinism/git-fetch acceptance criteria and technical note to Story 5.3.'
26
- - date: '2026-03-15'
27
- changes: 'Deleted old Epic 5 (Self-Contained Installer / standalone binary). Renumbered Epic 13 (Self-Contained BMAD Installation) to Epic 5, renamed to Bundled BMAD Installation. Removed --offline flag story (13.4). Reordered remaining stories to fix circular dependency. Added cross-epic bmad.js coordination and development execution order sections. Updated FR Coverage Map.'
28
- - date: '2026-03-15'
29
- changes: 'Adding Epic 13: Self-Contained BMAD Installation (FR74-FR78, NFR20-NFR21). Marked as highest priority — first epic to develop.'
30
- - date: '2026-03-12'
31
- changes: 'Adding Phase 2 epics for FR51-FR71 (Skill Enforcement, OpenCode, Project Knowledge, Bug Management, Sprint Management)'
32
- inputDocuments: ['_bmad-output/planning-artifacts/prd.md', '_bmad-output/planning-artifacts/architecture.md', '_bmad-output/planning-artifacts/implementation-readiness-report-2026-03-11.md']
33
- ---
34
-
35
- # agents - Epic Breakdown
36
-
37
- ## Overview
38
-
39
- This document provides the complete epic and story breakdown for agents, decomposing the requirements from the PRD and Architecture into implementable stories. Focus: implementation gaps identified in v2.19.2 gap analysis — Phase 1 remaining work and Phase 2 planned features.
40
-
41
- ## Requirements Inventory
42
-
43
- ### Functional Requirements
44
-
45
- - FR1: Engineers can install one or more skills into any supported AI agent with a single command
46
- - FR2: Engineers can uninstall previously installed skills from an agent
47
- - FR3: Engineers can view the list of all available skills with descriptions and categories
48
- - FR4: Engineers can view the installation status of skills for a specific agent
49
- - FR5: Engineers can upgrade skills when a newer version is available, with upgrade detection
50
- - FR6: Engineers can install skills in non-interactive mode for CI/CD pipeline automation
51
- - FR7: Engineers can install skills across multiple agents simultaneously from one manifest
52
- - FR8: Engineers can install the BMAD-METHOD framework alongside skills in a single workflow
53
- - FR9: Engineers can update an existing BMAD installation to a newer version
54
- - FR10: Engineers can apply organization-specific customizations to BMAD that persist across updates
55
- - FR11: Engineers can register MIL-STD-498 workflows into an existing BMAD installation
56
- - FR12: Engineers can trigger BMAD recompile after customization changes
57
- - FR13: Systems engineers can generate SSS (System/Subsystem Specification) documents from project artifacts
58
- - FR14: Systems engineers can generate SSDD (System/Subsystem Design Description) documents
59
- - FR15: Systems engineers can generate OCD (Operational Concept Description) documents
60
- - FR16: Project managers can generate SDP (Software Development Plan) documents
61
- - FR17: Product managers can generate SRS (Software Requirements Specification) documents
62
- - FR18: Product managers can generate SDD (Software Design Description) documents
63
- - FR19: Architects can generate IDD (Interface Design Description) documents
64
- - FR20: Architects can generate IRS (Interface Requirements Specification) documents
65
- - FR21: Architects can generate HRS (Hardware Requirements Specification) documents
66
- - FR22: Test engineers can generate STD (Software Test Description) documents
67
- - FR23: Test engineers can generate STR (Software Test Report) documents
68
- - FR24: Product managers can create PRDs through guided collaborative workflows
69
- - FR25: Product managers can break PRDs into epics and user stories
70
- - FR26: Product managers can run sprint planning from epics
71
- - FR27: Architects can create architecture documents through guided workflows
72
- - FR28: Architects can create UX design specifications
73
- - FR29: Engineers can check implementation readiness across PRD, architecture, and epics
74
- - FR30: Engineers can run code reviews against established standards
75
- - FR31: Test engineers can generate automated E2E tests from feature specifications
76
- - FR32: Project managers can track sprint status and surface risks
77
- - FR33: Teams can run retrospectives at epic boundaries
78
- - FR34: Engineers can target any of the supported IDE agents (Claude Code, Cursor, Cline, Copilot, Gemini, Kilocode, OpenCode) for skill installation
79
- - FR35: Engineers can target BMAD specialized agents (SRE, DevOps, Cyber, MIL-STD-498) for persona installation
80
- - FR36: Skills produce functionally equivalent behavior regardless of which agent they are installed into
81
- - FR37: Engineers can switch between AI agents and retain the same methodology framework
82
- - FR38: The system translates skill content into each agent's native configuration format automatically
83
- - FR39: The Chief Architect can author new skills using the skill format (skill.json + SKILL.md + agent templates)
84
- - FR40: The Chief Architect can designate skills as mandatory (`always_load: true`) for organizational enforcement
85
- - FR41: The Chief Architect can customize BMAD agent personas to fit organizational processes
86
- - FR42: The Chief Architect can develop new specialized agent personas for enterprise-specific roles
87
- - FR43: The system generates MANIFEST.yaml from installed skills for agent consumption
88
- - FR44: Engineers can install and use skills in air-gapped environments without internet access
89
- - FR45: Engineers can use ma-agents on Windows, macOS, and Linux
90
- - FR46: Engineers can use ma-agents with on-premise AI agents running against local models
91
- - FR47: The system tracks installed skill versions per agent via manifest for upgrade/downgrade detection
92
- - FR48: The system maintains an audit trail of AI agent activities via the ai-audit-trail skill
93
- - FR49: Document generation workflows maintain traceability across inter-role handoffs (SSS → SRS → SDD → STD)
94
- - FR50: Engineers can validate PRDs and other documents against established standards
95
-
96
- ### Functional Requirements (Phase 2 — added 2026-03-12)
97
-
98
- - FR51: The installer injects the planning instruction at the TOP of agent instruction files, not the bottom — ensuring highest priority during LLM context processing
99
- - FR52: The installer deploys a BMAD extension module (`extends-module: bmm`) that injects skill-loading `critical_actions` into BMAD agents — skills are loaded before any menu or workflow executes
100
- - FR53: All 11 BMAD agents (4 custom + 7 built-in) include skill-loading `critical_actions` in their `.customize.yaml` files
101
- - FR54: Per-agent enforcement mechanisms are implemented where the agent supports them (e.g., Claude Code hooks that verify manifest was read)
102
- - FR55: Context persistence strategies ensure skills survive LLM context compression and session restoration (via BMAD sidecar memory or equivalent)
103
- - FR56: Engineers can target OpenCode for skill installation with skills placed in `.opencode/skills/`
104
- - FR57: The installer injects skill references into `opencode.json` via the instructions array using JSON config merging (not replacement)
105
- - FR58: The installer does not add `_bmad-output` to `.gitignore` — this folder is tracked as version-controlled project knowledge
106
- - FR59: The `_bmad-output` policy is documented in README and installation guidance
107
- - FR60: Bugs are structured entities with required fields: problem description, reproduction steps, bug type, version found, environment constraints, severity, and status
108
- - FR61: A BMAD extension workflow (deployed via `extends-module: bmm`) generates a structured bug story from a bug report
109
- - FR62: The `auto-bug-detection` skill instructs coding agents to propose a bug issue to the user when they detect a problem in already-delivered code
110
- - FR63: During BMAD code-review workflows, agents suggest generating bug issues when relevant problems are found in delivered features
111
- - FR64: Bugs exist in the backlog as standalone items — never assigned to an epic
112
- - FR65: The backlog is a flat list containing both stories and bugs, not grouped by epic
113
- - FR66: Sprint capacity is defined by number of items (stories + bugs), configured by the Scrum Master during sprint planning
114
- - FR67: Story/bug prioritization supports multiple criteria beyond epic precedence
115
- - FR68: A BMAD extension workflow enables adding a new sprint with defined capacity and iteration identifier
116
- - FR69: A BMAD extension workflow enables adding stories and bugs to a sprint from the backlog
117
- - FR70: A BMAD extension workflow enables changing/modifying a sprint (reorder items, swap items, adjust capacity)
118
- - FR71: Sprint status displays real sprint definitions with assigned items, not just a list of epics
119
-
120
- ### Functional Requirements (Phase 2 — added 2026-03-15)
121
-
122
- - FR74: The ma-agents npm package bundles bmad-method v6.0.4 as a direct dependency — no `npx` download at install time
123
- - FR75: The ma-agents npm package bundles pre-cloned BMAD external modules (bmb, cis, tea, gds) under `lib/bmad-cache/` — no git clone at install time
124
- - FR76: Before invoking bmad-method install, the installer pre-populates `~/.bmad/cache/external-modules/` from the bundled cache so bmad-method finds modules locally
125
-
126
- ### Functional Requirements (Phase 2 — added 2026-03-26)
127
-
128
- #### Bundled Installation Update (FR123-FR127)
129
- - FR123: The installer passes all collected config to bmad-method as explicit CLI flags (`--tools`, `--modules`, `--directory`, `--user-name`, etc.)
130
- - FR124: bmad-method performs full configuration using explicit parameters — `--yes` suppresses prompts for already-supplied flags only
131
- - FR125: When bmad-method introduces new CLI params that ma-agents hasn't mapped, `--yes` causes bmad-method to apply defaults
132
- - FR126: Single unified wizard — no separate BMAD interactive prompt
133
- - FR127: CI/CD mode uses same explicit flag mechanism with pre-determined answers
134
-
135
- #### BMAD 6.2.0 Agent Architecture Migration (FR94-FR110)
136
- - FR94: Each custom agent (SRE, DevOps, Cyber, MIL-498) rebuilt as BMAD 6.2.0 skill-based agent (SKILL.md + bmad-skill-manifest.yaml)
137
- - FR95: Agent capabilities migrated from `.customize.yaml` critical_actions to internal commands in agent SKILL.md
138
- - FR96: Agent persona/identity defined in SKILL.md — replacing legacy XML `<agent>` definitions
139
- - FR97: Agent menu/routing via SKILL.md triggers and dynamic routing — replacing XML `<menu-handlers>`
140
- - FR98: All 11 MIL-498 DID workflows converted from YAML to SKILL.md Complex Workflow packages
141
- - FR99: MIL-498 instructions restructured as progressive disclosure step files in prompts/
142
- - FR100: MIL-498 template output checkpoints reimplemented as skill-level confirmation gates
143
- - FR101: 9 SRE playbooks packaged as SKILL.md skill packages
144
- - FR102: 6 DevOps playbooks packaged as SKILL.md skill packages
145
- - FR103: 8 Cyber playbooks packaged as SKILL.md skill packages
146
- - FR104: Extension module restructured with module.yaml `code` field
147
- - FR105: Module setup skill created for config management (anti-zombie pattern)
148
- - FR106: Dual-layer agent definition consolidated into single agent skill folder
149
- - FR107: Installer detects BMAD version and performs in-place migration during normal installation
150
- - FR108: Migration preserves user customizations
151
- - FR109: Legacy artifacts removed after successful migration
152
- - FR110: Fresh installations deploy directly in 6.2.0 format
153
-
154
- #### Multi-Repository Project Layout (FR111-FR122)
155
- - FR111: Installer asks where knowledgebase is managed (current repo / local / remote)
156
- - FR112: Installer asks where sprint management is managed
157
- - FR113: Remote option: ask git URL + local destination, confirm if exists
158
- - FR114: Remote: clone if destination doesn't exist
159
- - FR115: Local: validate path exists, alert if not
160
- - FR116: Same-repo default: no additional config
161
- - FR117: Paths stored in config.yaml (`knowledgebase_path`, `sprint_management_path`)
162
- - FR118: project-context.md includes configured paths as mandatory agent rules
163
- - FR119: Planning workflows resolve output from `{knowledgebase_path}`
164
- - FR120: Sprint workflows resolve paths from `{sprint_management_path}`
165
- - FR121: Dashboard (Phase 3) resolves from `{sprint_management_path}`
166
- - FR122: Multi-repo mode creates `project-layout.yaml` cross-reference file
167
-
168
- ### Functional Requirements (Phase 2 — added 2026-04-03)
169
-
170
- #### Unified Sprint-Status Management (FR133-FR140)
171
- - FR133: Sprint management uses a single unified `sprint-status.yaml` with three sections: `epics` (reference), `backlog` (unassigned items), and `sprints` (sprint definitions with assigned items)
172
- - FR134: Stories and bugs MOVE between the `backlog` and `sprints` sections — an item exists in exactly one location at any time
173
- - FR135: Each item carries its own `status` field, updated in-place within the section where it resides
174
- - FR136: Items reaching `done` status are removed from `sprint-status.yaml` and archived to `done/` folder
175
- - FR137: A close-sprint workflow transitions a sprint from `active` to `closed`, archiving all done items and returning incomplete items to backlog
176
- - FR138: When `tracking_system` is configured as `jira`, sprint management skills read/write from Jira API using the same data model (adapter pattern)
177
- - FR139: The unified schema replaces the previous three-file model (`backlog.yaml`, `sprints/sprint-N.yaml`, `sprint-status.yaml`) — deprecated files are migrated or removed
178
- - FR140: All 12 sprint-related skills are reworked to operate against the single unified file
179
-
180
- ### Functional Requirements (Phase 3 — added 2026-04-07)
181
-
182
- #### BMAD Knowledge Graph (FR141-FR157)
183
- - FR141: Each node in the knowledge graph is identified by `file-id#heading-anchor` where `file-id` is a short stable key that resolves to a file pointer via the `files` table
184
- - FR142: Each directed edge carries full provenance: `from` (node id), `to` (node id), `type` (edge type), `label` (human description), `created_by` (user), `agent` (AI agent identity), `created_at` (ISO timestamp); edge types include `implements`, `derives-from`, `validates`, `traces-to`, `refines`, `informed-by`
185
- - FR143: The graph maintains a bidirectional index — for each node, the system can resolve both inbound (nodes that reference it) and outbound (nodes it references) edges in O(1) time
186
- - FR144: The knowledge graph JSON file uses a flat four-section structure: `meta` (file statistics), `files` (file registry), `nodes` (node list), `edges` (edge list) — maximum two levels of nesting throughout
187
- - FR145: The `files` section maps each `file-id` to an object with `pointer` (the file reference), `title` (display name), and `pointer_type` (one of: `relative_path`, `absolute_path`, `url`) — enabling nodes in the same graph to address local files, files in other repos, and external URLs (Confluence, Jira, etc.) uniformly
188
- - FR146: Each node object carries: `id` (`file-id#anchor`), `file` (the `file-id` from the files table), `anchor` (the heading slug), `title` (human-readable heading text), `type` (document type: `prd`, `architecture`, `epic`, `story`, `decision`, `validation`)
189
- - FR147: Each edge object carries: `from`, `to`, `type`, `label`, `created_by`, `agent`, `created_at` — all fields required, no optional fields
190
- - FR148: The `meta` section carries: `schema_version`, `generated_at`, `project`, `file_count`, `node_count`, `edge_count`
191
- - FR149: BMAD skills emit nodes and edges automatically on artifact completion — no user prompt, no opt-in — as a silent post-artifact step
192
- - FR150: When emitting, if a file is not yet in the `files` table, it is registered automatically; external URLs (e.g., Confluence page) are registered with `pointer_type: url`
193
- - FR151: Any node may derive from multiple source documents simultaneously — a story AC can carry `informed-by` edges from both the architecture and a UX design doc, not just from its parent epic
194
- - FR152: The emit operation is additive-only: new nodes and edges are appended; existing nodes and edges are never deleted or overwritten; duplicate detection uses the full `(from, to, type)` triple for edges and `id` for nodes
195
- - FR153: The `open-graph` skill detects the execution environment (VSCode vs. terminal) and opens `knowledge-graph.html` via the appropriate mechanism — VSCode webview API when inside VSCode, `open`/`start` shell command otherwise
196
- - FR154: The visualization renders nodes as color-coded circles by document type and supports click-to-navigate (opens the source document at the specific heading anchor in the IDE or browser)
197
- - FR155: Hovering over an edge displays a tooltip with the full provenance record: type, label, created_by, agent, created_at
198
- - FR156: The visualization provides interactive filtering by node type and edge type, and highlights the immediate neighbors of any selected node
199
- - FR157: The visualization has no external CDN, font, or script dependencies — all rendering code and graph data are self-contained in a single HTML file suitable for air-gapped environments
200
-
201
- ### NonFunctional Requirements
202
-
203
- - NFR1: Skills must not transmit project data externally — all content is static instruction delivery, not data collection
204
- - NFR2: Installation process must function fully offline for air-gapped environments
205
- - NFR3: Skill content must be inspectable (plain text markdown/JSON) — no obfuscated or compiled instructions
206
- - NFR4: BMAD customizations must not be overwritten by updates without explicit user action
207
- - NFR5: Skill installation must not corrupt or remove existing agent configurations — additive-only operations
208
- - NFR6: Agent format translation must produce valid configuration for each target agent's expected format
209
- - NFR7: Manifest operations (read/write/update) must be atomic — no partial manifest states on failure
210
- - NFR8: BMAD install/update/customize pipeline must execute steps in strict order with rollback on failure
211
- - NFR9: CLI must produce identical results on Windows, macOS, and Linux for the same inputs
212
- - NFR10: Skills authored once must install without modification across all supported agents
213
- - NFR11: Adding a new agent target must not require changes to existing skills — only a new template mapping
214
- - NFR12: The tool must function with Node.js LTS versions (current and previous)
215
- - NFR13: Adding a new agent to the registry must require only a configuration entry, not code changes to the installer core
216
- - NFR14: Adding a new skill must require only the skill package files (skill.json + SKILL.md + templates), not installer modifications
217
- - NFR15: Skill format must remain backward-compatible — older skills must install correctly with newer tool versions
218
-
219
- ### NonFunctional Requirements (Phase 2 — added 2026-03-12)
220
-
221
- - NFR16: The BMAD extension module must survive `npx bmad-method install --action update` without losing functionality
222
- - NFR17: All BMAD-facing changes must use official BMAD Builder extension APIs only — zero bmad-method core modifications
223
- - NFR18: OpenCode JSON instruction injection must not corrupt existing `opencode.json` configuration — additive-only
224
- - NFR19: Bug and sprint extension workflows must function identically whether invoked via BMAD agent menu or direct slash command
225
- - NFR20: The bundled BMAD cache must be version-pinned (v6.0.4 initial) — upgrading the bundled version is a deliberate, tested release operation
226
- - NFR21: The bundled installation must produce a complete, deterministic `_bmad/` output from the bundled npm package
227
-
228
- ### NonFunctional Requirements (Phase 2 — added 2026-03-26)
229
-
230
- - NFR29: Migration from 6.0.4 to 6.2.0 must be atomic — all succeed or rollback
231
- - NFR30: Migrated agents must produce functionally equivalent behavior
232
- - NFR31: Migrated agent skill folders must pass BMAD Builder lint gate
233
- - NFR32: All 34 converted workflows must produce identical output artifacts
234
- - NFR33: Module setup skill anti-zombie cleanup must be idempotent
235
- - NFR34: Multi-repo config must be backward-compatible with single-repo mode
236
- - NFR35: Remote repo cloning must work with internal git URLs (air-gapped)
237
- - NFR36: project-layout.yaml must be deterministic
238
- - NFR37: All BMAD workflows must resolve paths through config, no hardcoded `_bmad-output/`
239
-
240
- ### NonFunctional Requirements (Phase 3 — added 2026-04-07)
241
-
242
- - NFR38: The `open-graph` skill must render the knowledge graph visualization within 3 seconds for graphs up to 500 nodes and 1000 edges, measured from skill invocation to first interactive frame
243
- - NFR39: The knowledge graph JSON format must be writable by any LLM without external schema — structure is self-describing; an LLM can add a new node or edge by copying an existing pattern with no external reference
244
- - NFR40: The `emitToGraph()` operation must never delete or overwrite existing graph data — additive-only semantics are enforced at the function level, verified by the absence of delete/overwrite operations during emission
245
- - NFR41: The knowledge graph visualization (`knowledge-graph.html`) must function fully without network access — verified by disabling network access and confirming the graph renders identically
246
-
247
- ### Functional Requirements (Phase 3 — added 2026-04-13)
248
-
249
- #### Local-LLM / On-Prem Agent Tuning (FR172-FR179)
250
- - FR172: Install-time profile prompt (on-prem vs standard) persisted as `"profile"` in `.ma-agents.json`
251
- - FR173: `--yes` defaults to `standard` for CI/CD; on-prem CI/CD served by committing `.ma-agents.json` with persisted profile — no per-invocation CLI flag
252
- - FR174: Universal per-tool guardrail templates shipped to all profiles — expanded `CLAUDE.md`/`.clinerules`/`.roo/rules/` injection, expanded `AGENTS.md` for OpenCode, new `.roomodes` for Roo Code with 4 BMAD modes
253
- - FR175: `.roomodes` template restricts file edit access by BMAD phase via `fileRegex` (planning modes can only edit `.md`); enforced by Roo Code's `FileRestrictionError` at the application layer
254
- - FR176: Per-tool template stamping is additive — merges via `<!-- MA-AGENTS-START -->` markers; preserves user content outside markers; `.roomodes` preserves non-conflicting user `customModes`
255
- - FR177: When profile=on-prem, layered local-LLM guardrails are added — no-home-dir-writes, no `str_replace_editor`, `/no_think` planning prefix, reasoning-mode/sampling guidance
256
- - FR178: When profile=on-prem, BMAD agent persona customizations gain a phase-aware system-prompt prefix (planning agents reasoning-OFF, implementation agents reasoning-ON); not applied when profile=standard
257
- - FR179: Reference deployment doc `docs/deployment/vllm-nemotron.md` ships in the repo (vLLM flags, tool-call-parser, max-model-len, quantization, per-phase sampling) — documentation only, installer does not manage the inference server
258
-
259
- ### NonFunctional Requirements (Phase 3 — added 2026-04-13)
260
-
261
- - NFR44: On-prem profile guardrails must not regress standard profile — when profile=standard, no on-prem-specific instructions appear in any generated file
262
- - NFR45: Profile prompt is non-blocking in CI/CD — `--yes` defaults to `standard`; persisted answer not re-prompted on subsequent installs; on-prem CI/CD served via committed `.ma-agents.json`, not a flag
263
- - NFR46: Per-tool template stamping is idempotent — re-running install with the same profile produces byte-identical content within marker blocks
264
- - NFR47: BMAD planning-mode file restrictions in `.roomodes` enforced at the application layer (Roo Code `FileRestrictionError`), verified by attempting a code-file edit in `bmad-architect` mode and confirming rejection
265
-
266
- ### Additional Requirements
267
-
268
- - Testing framework needs formalization — Node.js built-in test runner recommended per architecture
269
- - Visual Studio agent integration mechanism needs investigation (VS Copilot Chat, .vs/ directory)
270
- - Error code catalog — standardize currently ad-hoc error strings
271
- - Structured logging for diagnostic purposes beyond console output
272
- - Methodology presentation to be bundled with installation for team onboarding
273
- - `--yes` flag support for non-interactive CI/CD mode (currently only `--force` exists)
274
-
275
- ### FR Coverage Map
276
-
277
- | FR | Epic | Description |
278
- |----|------|-------------|
279
- | FR6 | Epic 1 | `--yes` flag for non-interactive CI/CD mode |
280
- | FR36 | Epic 2 | Equivalent behavior for new language skills across agents |
281
- | FR39 | Epic 2 & 3 | Skill authoring for new language skills + tooling |
282
- | FR10 | Epic 2 | New language skills install across all agents |
283
- | FR40 | Epic 3 | Mandatory skill designation for authored skills |
284
- | FR41 | Epic 3 | BMAD persona customization tooling |
285
- | FR42 | Epic 3 | Specialized agent development tooling |
286
- | FR43 | Epic 3 | MANIFEST.yaml generation validation |
287
- | FR34 (VS gap) | Epic 4 | Visual Studio agent target |
288
- | FR38 (VS) | Epic 4 | VS format translation |
289
- | All other Phase 1 FRs | Implemented | v2.19.2 baseline — no epic needed |
290
- | FR51 | Epic 8 | TOP injection placement |
291
- | FR52 | Epic 8 | BMAD extension module with critical_actions |
292
- | FR53 | Epic 8 | All 11 BMAD agent critical_actions |
293
- | FR54 | Epic 8 | Per-agent enforcement (Claude Code hooks) |
294
- | FR55 | Epic 8 | Context persistence research |
295
- | FR56 | Epic 9 | OpenCode skill installation path |
296
- | FR57 | Epic 9 | OpenCode JSON injection |
297
- | FR58 | Epic 10 | _bmad-output not gitignored |
298
- | FR59 | Epic 10 | _bmad-output policy documentation |
299
- | FR60 | Epic 11 | Bug entity structure |
300
- | FR61 | Epic 11 | Bug story workflow |
301
- | FR62 | Epic 11 | auto-bug-detection skill |
302
- | FR63 | Epic 11 | Code-review bug detection |
303
- | FR64 | Epic 11 | Bugs as standalone backlog items |
304
- | FR65 | Epic 12 | Flat backlog (stories + bugs) |
305
- | FR66 | Epic 12 | Sprint capacity by item count |
306
- | FR67 | Epic 12 | Multi-criteria prioritization |
307
- | FR68 | Epic 12 | Add sprint workflow |
308
- | FR69 | Epic 12 | Add to sprint workflow |
309
- | FR70 | Epic 12 | Modify sprint workflow |
310
- | FR71 | Epic 12 | Sprint status with assigned items |
311
- | FR72 | Epic 6 | Methodology presentation bundled with BMAD install |
312
- | FR73 | Epic 7 | Automated regression tests for 4 core modules |
313
- | FR74 | Epic 5 | Bundle bmad-method as dependency |
314
- | FR75 | Epic 5 | Bundle pre-cloned external modules |
315
- | FR76 | Epic 5 | Pre-populate bmad cache before install |
316
- | FR44 | Epic 5 | Air-gapped environment support via bundled installation |
317
- | FR45 | Implemented | Cross-platform support (Windows, macOS, Linux) |
318
- | FR79 | Epic 13 | Generate project-context.md at project-level install |
319
- | FR80 | Epic 13 | Mandatory rules: MANIFEST, always_load skills, git worktrees |
320
- | FR81 | Epic 13 | Platform-aware manifest path resolution (from full manifest) |
321
- | FR82 | Epic 13 | Multi-platform manifest path listing |
322
- | FR83 | Epic 13 | Full 8-step agent mission lifecycle documented |
323
- | FR84 | Epic 13 | Idempotent generation — skip if exists |
324
- | FR85 | Epic 13 | Inline expansion comments + template version comment |
325
- | FR86 | Epic 13 | BMAD critical_actions updated for 12 BMM+master agents |
326
- | FR87-FR93 | Phase 3 | Agent Activity Dashboard (deferred) |
327
- | FR94-FR97 | Epic 15 | Custom agent conversion to SKILL.md skill folders |
328
- | FR98-FR100 | Epic 15 | MIL-498 workflow conversion to SKILL.md |
329
- | FR101-FR103 | Epic 15 | SRE/DevOps/Cyber workflow conversion to SKILL.md |
330
- | FR104-FR106 | Epic 15 | Module architecture update (module.yaml code field, setup skill) |
331
- | FR107-FR110 | Epic 15 | Migration detection, upgrade path, legacy cleanup |
332
- | FR111-FR116 | Epic 16 | Multi-repo wizard (local/remote/same prompts) |
333
- | FR117-FR118 | Epic 16 | Config storage + project-context stamping |
334
- | FR119-FR122 | Epic 16 | Cross-repo path resolution + project-layout.yaml |
335
- | FR123-FR127 | Epic 5 | Explicit parameter passing replacing silent install |
336
- | FR65 (rework) | Epic 17 | Flat backlog model (not epic-grouped) |
337
- | FR66 (rework) | Epic 17 | Sprint capacity with first-class sprint entity |
338
- | FR67 (rework) | Epic 17 | Multi-criteria prioritization |
339
- | FR128 | Epic 17 | Bug as story type in backlog |
340
- | FR129 | Epic 17 | Move items from sprint back to backlog (remove-from-sprint skill) |
341
- | FR130 | Epic 17 | Done items removed from sprint status file |
342
- | FR131 | Epic 17 | Done story files moved to done/ subfolder |
343
- | FR132 | Epic 17 | Sprints as first-class YAML entities |
344
- | FR133 | Epic 17 | Unified sprint-status.yaml with three sections |
345
- | FR134 | Epic 17 | Movement semantics — items move between backlog and sprint sections |
346
- | FR135 | Epic 17 | In-place status updates on each item |
347
- | FR136 | Epic 17 | Done items removed from file, archived to done/ |
348
- | FR137 | Epic 17 | Close-sprint workflow for sprint lifecycle closure |
349
- | FR138 | Epic 17 / Epic 14 | Jira adapter pattern (tracking_system switch) |
350
- | FR139 | Epic 17 | Migration/removal of deprecated 3-file model |
351
- | FR140 | Epic 17 | All 12 sprint skills reworked for unified file |
352
- | FR141 | Epic 19 | Graph node identity: file-id#heading-anchor |
353
- | FR142 | Epic 19 | Directed typed edges with full provenance (6 edge types) |
354
- | FR143 | Epic 19 | Bidirectional index per node |
355
- | FR144 | Epic 19 | Flat four-section JSON structure (meta/files/nodes/edges) |
356
- | FR145 | Epic 19 | Files table with pointer_type (relative_path, absolute_path, url) |
357
- | FR146 | Epic 19 | Node schema (id, file, anchor, title, type) |
358
- | FR147 | Epic 19 | Edge schema (from, to, type, label, created_by, agent, created_at) |
359
- | FR148 | Epic 19 | Meta schema (schema_version, generated_at, project, counts) |
360
- | FR149 | Epic 19 | Automatic silent emission on artifact completion (7 BMAD skills) |
361
- | FR150 | Epic 19 | Auto-registration of new files; external URL support |
362
- | FR151 | Epic 19 | Non-hierarchical multi-source emission (any-to-any informed-by edges) |
363
- | FR152 | Epic 19 | Additive-only emit; duplicate detection by (from,to,type) for edges and id for nodes |
364
- | FR153 | Epic 19 | open-graph skill with VSCode/browser detection |
365
- | FR154 | Epic 19 | Interactive visualization: color-coded nodes by type, click-to-navigate |
366
- | FR155 | Epic 19 | Edge tooltip with full provenance record |
367
- | FR156 | Epic 19 | Interactive filtering by node/edge type; neighbor highlight |
368
- | FR157 | Epic 19 | No external dependencies — fully self-contained HTML (air-gap compatible) |
369
- | FR158 | Epic 18 | Roo Code custom modes from BMAD agents (proposed — pending PRD addition) |
370
- | FR159 | Epic 18 | Roo Code rules from BMAD instructions (proposed — pending PRD addition) |
371
- | FR160 | Epic 18 | Roo Code slash commands from BMAD workflows (proposed — pending PRD addition) |
372
- | FR161 | Epic 18 | Cline-to-Roo Code migration (proposed — pending PRD addition) |
373
- | FR172 | Epic 21 | Install-time profile prompt + persistence in `.ma-agents.json` |
374
- | FR173 | Epic 21 | `--yes` defaults to standard; on-prem CI/CD via committed `.ma-agents.json` (no CLI flag) |
375
- | FR174 | Epic 21 | Universal per-tool guardrail templates (all profiles) |
376
- | FR175 | Epic 21 | `.roomodes` BMAD-mode `fileRegex` restrictions enforced by Roo Code |
377
- | FR176 | Epic 21 | Additive marker-based stamping; `.roomodes` slug-isolation |
378
- | FR177 | Epic 21 | On-prem layered guardrails (`/no_think`, no-home-dir-writes, no `str_replace_editor`) |
379
- | FR178 | Epic 21 | BMAD persona phase-aware system-prompt prefix (on-prem only) |
380
- | FR179 | Epic 21 | vLLM reference deployment doc — documentation only |
381
- | FR180 | Epic 21 | `ma-agents reconfigure` subcommand — re-runs profile prompt and re-stamps all profile-dependent artifacts. Closes no-escape-hatch gap. |
382
- | FR181 | Epic 21 | `ma-agents uninstall --profile-artifacts` — removes ma-agents-owned profile content, preserves user content and audit trails. Closes no-uninstall gap. |
383
-
384
- ## Epic List
385
-
386
- ### Epic 1: CI/CD Non-Interactive Mode
387
- Engineers can run `npx ma-agents install --yes` for fully automated, non-interactive skill installation in CI/CD pipelines without human prompts.
388
- **FRs covered:** FR6
389
- **NFRs addressed:** NFR9 (cross-platform identical results)
390
-
391
- ### Epic 2: Language-Specific Skill Expansion
392
- Engineers working in C++, C#, and Python have dedicated coding standards and best practices skills installed through ma-agents, expanding the skill library with language-specific methodology content.
393
- **FRs covered:** FR36, FR39, FR10
394
- **NFRs addressed:** NFR10 (write-once skills), NFR14 (no installer changes for new skills)
395
-
396
- ### Epic 3: Skill Authoring Tooling
397
- The Chief Architect has tooling to scaffold, validate, and test new skills, lowering the barrier for organizational skill creators and ensuring consistency across the skill library.
398
- **FRs covered:** FR39, FR40, FR41, FR42, FR43
399
- **NFRs addressed:** NFR14 (skill format contract), NFR15 (backward compatibility)
400
-
401
- ### Epic 4: Visual Studio Agent Integration
402
- Engineers can target Visual Studio's AI assistant for skill installation, expanding agent coverage to the VS ecosystem and closing the last major agent gap.
403
- **FRs covered:** FR34 (VS gap), FR38 (VS format translation)
404
- **NFRs addressed:** NFR11 (new agent = template mapping only), NFR13 (config-driven registry)
405
-
406
- ### Epic 5: Bundled BMAD Installation
407
- The ma-agents npm package bundles bmad-method and all external BMAD modules (bmb, cis, tea, gds) so that `npx ma-agents install` never performs runtime git clone or npm registry fetch for BMAD components. Installation is deterministic and works in air-gapped environments where the npm package is available.
408
- **FRs covered:** FR74, FR75, FR76
409
- **NFRs addressed:** NFR2 (offline operation), NFR20 (version pinning), NFR21 (deterministic output)
410
- **Dependencies:** Coordination with Epics 6, 8 (shared `bmad.js` modifications). Epic 8 creates extension module deployment in `bmad.js`. Epic 6 adds methodology deployment step. All three epics modify `bmad.js` — implementation must coordinate merge order.
411
- **Version pin:** bmad-method v6.0.4
412
-
413
- ### Epic 6: Methodology Onboarding Package
414
- Teams receive a methodology presentation bundled with installation, enabling organizational onboarding to BMAD-METHOD without separate training materials.
415
- **FRs covered:** FR72
416
- **Standalone:** Adds content to existing install pipeline
417
- **Phase 2 dependencies:** Epic 5 modifies `bmad.js` invocation pattern (must ship first). Epic 8 modifies `bmad.js` for extension module deployment — coordinate insertion point for methodology deployment step.
418
-
419
- ### Epic 7: Test Suite Foundation
420
- Contributors have automated regression tests verifying architectural contracts across the 4 core modules (cli.js, installer.js, agents.js, bmad.js), catching pipeline ordering violations, registry inconsistencies, and template resolution bugs before release.
421
- **FRs covered:** FR73 (developer infrastructure)
422
- **NFRs verified:** NFR5 (additive-only), NFR7 (atomic manifests), NFR8 (strict pipeline ordering), NFR9 (cross-platform)
423
- **Dependencies:** Testing framework architectural decision must be finalized before Story 7.1
424
- **Test isolation:** All stories use temp directories for file operations; module-level tests use dependency injection or function-level mocking to avoid triggering real installs, BMAD operations, or file system side effects
425
- **Coverage targets:** All public functions in the 4 modules; minimum one happy-path and one error-path test per function; template resolution edge cases (missing template, all fallbacks fail)
426
-
427
- ### Epic 8: Skill Enforcement Architecture (Phase 2)
428
- Engineers' installed skills are reliably enforced by all agents — agents load and follow skills automatically without user reminders (zero-reminder workflow).
429
- **FRs covered:** FR51, FR52, FR53, FR54, FR55
430
- **NFRs addressed:** NFR16 (extension survives updates), NFR17 (zero core modifications)
431
- **Note:** FR53 scope is all 11 BMAD agents per architecture decision P2-4 (4 custom full + 7 built-in minimal)
432
-
433
- ### Epic 9: OpenCode Agent Support (Phase 2)
434
- Engineers can target OpenCode as the 12th supported agent for skill installation, with JSON-based instruction injection.
435
- **FRs covered:** FR56, FR57
436
- **NFRs addressed:** NFR18 (additive-only JSON merge), NFR13 (config-driven registry)
437
-
438
- ### Epic 10: Project Knowledge Preservation (Phase 2)
439
- Engineers' planning and implementation artifacts (`_bmad-output`) are version-controlled project knowledge, never gitignored.
440
- **FRs covered:** FR58, FR59
441
-
442
- ### Epic 11: Bug Management System (Phase 2)
443
- Agents detect defects in already-delivered code and generate structured bug reports that enter the backlog for sprint prioritization.
444
- **FRs covered:** FR60, FR61, FR62, FR63, FR64
445
- **NFRs addressed:** NFR19 (menu + slash command invocation)
446
- **Dependency:** Uses extension module from Epic 8 for workflow deployment
447
-
448
- ### Epic 12: Realistic Sprint Management (Phase 2) **[SUPERSEDED by Epic 17]**
449
- Project managers work with flat backlogs containing stories and bugs, capacity-based sprints, and multi-criteria prioritization.
450
- **FRs covered:** FR65, FR66, FR67, FR68, FR69, FR70, FR71
451
- **NFRs addressed:** NFR19 (menu + slash command invocation)
452
-
453
- ### Epic 13: Project Context Auto-Generation (Phase 2)
454
- At project-level installation, ma-agents generates `_bmad-output/project-context.md` — a platform-agnostic constitutional document that mandates skill loading, fresh-worktree git workflow, and the full agent mission lifecycle for all installed agents and BMAD workflows.
455
- **FRs covered:** FR79, FR80, FR81, FR82, FR83, FR84, FR85, FR86
456
- **NFRs addressed:** NFR22 (template has no hardcoded paths), NFR23 (additive-only), NFR24 (template as separate file), NFR25 (version comment for upgrade detection)
457
- **Dependency:** Uses extension module from Epic 8 for critical_actions update; `_bmad-output/` policy from Epic 10
458
- **Dependency:** Uses extension module from Epic 8 for workflow deployment
459
-
460
- ### Epic 17: Sprint Management Model Rework (Phase 2)
461
- Sprint management is redesigned around a **single unified `sprint-status.yaml`** file with three sections: `epics` (reference), `backlog` (unassigned items), and `sprints` (sprint definitions with assigned items). Stories and bugs MOVE between sections using movement semantics. Each item carries its own status, updated in-place. Done items are removed from the file and archived. A new close-sprint skill handles sprint lifecycle closure. A Jira adapter pattern enables the same data model to read/write from Jira API when `tracking_system` is configured as `jira`. All 12 sprint-related skills are reworked for the unified file, and the deprecated 3-file model is migrated/removed.
462
- **FRs covered:** FR65, FR66, FR67, FR128, FR129, FR130, FR131, FR132, FR133, FR134, FR135, FR136, FR137, FR138, FR139, FR140 (plus rework of FR68-FR71 workflows to work with new model)
463
- **NFRs addressed:** NFR19 (menu + slash command invocation)
464
- **Dependencies:** Epic 11 (bug entity structure). Reworks Epic 12's workflow shells to use the new model. Epic 14 (Jira adapter architecture — Story 14.3 must be approved before Story 17.22 implementation).
465
- **Note:** Epic 12 delivered workflow files but not the underlying sprint data model. This epic builds the unified model, rewires all workflows, and provides the Jira adapter pattern.
466
- **Skills affected:** Heavy rework (6): generate-backlog, add-to-sprint, remove-from-sprint, sprint-status-view, cleanup-done, bmad-sprint-planning. Moderate rework (3): add-sprint, modify-sprint, bmad-dev-story. Light rework (3): story-status-lookup, bmad-sprint-status, prioritize-backlog. New skill (1): close-sprint.
467
-
468
- ### Epic 21: On-Prem / Local-LLM Tuning (Phase 3)
469
- The primary deployment scenario for ma-agents — air-gapped enterprise networks running local non-Claude LLMs (e.g., Nemotron Super 49B) — is made first-class. An install-time profile prompt (on-prem vs standard) drives a two-layer tuning model: (1) **universal** per-tool guardrail templates shipped to every install (`.roomodes` with BMAD-mode `fileRegex` restrictions, expanded `AGENTS.md`/`.clinerules`/`CLAUDE.md` injection enforcing text-vs-file discipline and BMAD phase boundaries), and (2) **on-prem-only** layered guardrails (`/no_think` planning prefix, no-home-dir-writes, no `str_replace_editor`, BMAD persona phase-aware prompt prefixes). A reference vLLM deployment doc ships under `docs/deployment/`. Implements the field-validated playbook from `optimizing-local-llm-coding-agents-bmad.md`.
470
- **FRs covered:** FR172, FR173, FR174, FR175, FR176, FR177, FR178, FR179, FR180, FR181
471
- **NFRs addressed:** NFR44 (profile isolation), NFR45 (CI/CD compatibility), NFR46 (idempotency), NFR47 (application-layer phase enforcement), NFR48 (profile-history audit trail), NFR49 (content removal preservation contract)
472
- **Architecture:** Decision P3-3 (Local-LLM / On-Prem Agent Tuning Profile) in `_bmad-output/planning-artifacts/architecture.md`
473
- **Dependencies:** Epic 9 (OpenCode JSON-merge injection — reused for AGENTS.md). Epic 18 (Roo Code agent registration — `.roomodes` ships into `.roo/`). Epic 15 (BMAD 6.2.1 module restructure — phase prefix integrates with customize-loader). Epic 13 (project-context generator — pattern reused for template stamping).
474
- **New files:** `lib/profile.js`, `lib/templates/instruction-block-universal.template.md`, `lib/templates/instruction-block-onprem.template.md`, `lib/templates/roomodes.template.yaml`, `lib/templates/agents-md.template.md`, `lib/templates/clinerules.template.md`, `docs/deployment/vllm-nemotron.md`
475
- **Files modified:** `bin/cli.js`, `lib/installer.js`, `lib/agents.js`, `lib/bmad-customize/*.customize.yaml` (additive phase prefix), customize-loader, README.md
476
- **New tests:** `test/profile.test.js`, `test/onprem-injection.test.js`
477
-
478
- ### Epic 19: BMAD Knowledge Graph (Phase 3)
479
- Every planning and implementation artifact generated by BMAD skills is automatically woven into a non-hierarchical knowledge graph stored as `_bmad-output/knowledge-graph.json`. Any-to-any directed relationships (not just parent-child traceability) are captured with full provenance. Engineers can open an interactive visualization of the entire project knowledge graph — navigating to any document at the specific heading where a concept is defined — via the `open-graph` skill.
480
- **FRs covered:** FR141–FR157
481
- **NFRs addressed:** NFR38 (render performance), NFR39 (LLM-writability), NFR40 (additive-only), NFR41 (air-gapped)
482
- **Architecture:** Decision P3-1 (BMAD Knowledge Graph) in `_bmad-output/planning-artifacts/architecture.md`
483
- **Dependencies:** Epic 15 (extension module structure) must be complete — `open-graph` skill deploys as a BMAD extension skill. Epic 17 complete (sprint skill structure settled before wiring emission).
484
- **New skill:** `open-graph` (45th total skill) in `lib/bmad-extension/skills/open-graph/`
485
- **Skills modified:** create-prd, create-architecture, create-epics-and-stories, create-story, validate-prd, dev-story, bmad-sprint-planning — each gains a silent `emitToGraph()` post-artifact call
486
- **Output artifacts:** `_bmad-output/knowledge-graph.json` (graph data), `_bmad-output/knowledge-graph.html` (self-contained renderer)
487
-
488
- ### Epic 15: BMAD 6.2.1 Agent Architecture Migration (Phase 2)
489
- ma-agents upgrades from bmad-method 6.0.4 to 6.2.1, restructures the extension module to follow BMAD 6.2.0 module conventions (agents as skill folders, workflows as skill folders, module.yaml with code field), and provides an installer-driven migration path for existing installations.
490
- **FRs covered:** FR94, FR95, FR96, FR97, FR98, FR99, FR100, FR101, FR102, FR103, FR104, FR105, FR106, FR107, FR108, FR109, FR110
491
- **NFRs addressed:** NFR29 (atomic migration), NFR30 (functional equivalence), NFR31 (lint gate), NFR32 (output equivalence), NFR33 (anti-zombie idempotency)
492
- **Dependencies:** Epic 5 must be complete first (explicit param passing is the foundation). Epic 8's extension module concept is restructured by this epic.
493
-
494
- ### Epic 16: Multi-Repository Project Layout (Phase 2)
495
- Enterprise projects that separate planning knowledge, sprint management, and code across repositories are fully supported. The installer discovers repo locations, stores paths in config, and stamps them into project-context.md so agents resolve artifacts to the correct repository.
496
- **FRs covered:** FR111, FR112, FR113, FR114, FR115, FR116, FR117, FR118, FR119, FR120, FR121, FR122
497
- **NFRs addressed:** NFR34 (backward compat), NFR35 (air-gapped remote clone), NFR36 (deterministic), NFR37 (no hardcoded paths)
498
- **Dependencies:** Epic 15 must be complete (module restructure). Epic 13 (project-context) provides the template that gains multi-repo section.
499
-
500
- ### Cross-Epic Coordination: `bmad.js`
501
-
502
- Four epics modify `bmad.js`. Implementation order matters:
503
- 1. **Epic 5** (Bundled BMAD + Explicit Params) — changes invocation from `npx bmad-method` to vendored `node <resolved-path>` with explicit CLI flags, adds cache pre-population
504
- 2. **Epic 15** (6.2.1 Migration) — changes `--custom-content` deployment, adds migration detection, restructures extension module deployment
505
- 3. **Epic 6** (Methodology Onboarding) — adds methodology deployment step
506
- 4. **Epic 8** (Skill Enforcement) — adds extension module deployment (restructured by Epic 15)
507
-
508
- Stories in Epics 6, 8, and 15 that touch `bmad.js` must build on Epic 5's vendored invocation + explicit parameter pattern.
509
-
510
- ### Development Execution Order
511
-
512
- **Phase A — Installation Fixes (release version after completion):**
513
- 1. **Epic 5** (Bundled BMAD + Explicit Params) — fix installation bugs, explicit parameter passing → **release**
514
-
515
- **Phase B — BMAD 6.2.1 Alignment (release version after completion):**
516
- 2. **Epic 15** (BMAD 6.2.1 Migration) — version bump, module restructure, agent/workflow conversion → **release**
517
-
518
- **Phase C — Remaining Features:**
519
- 3. **Epic 17** (Sprint Management Model Rework) — unified sprint-status.yaml, reworks Epic 12 workflows, depends on Epic 11. Stories 17.9-17.24 can proceed independently (except 17.22). Story 17.22 (Jira adapter) blocked on Epic 14 Story 14.3 architecture approval.
520
- 4. **Epic 16** (Multi-Repo Layout) — depends on Epic 15 module restructure
521
- 5. **Epics 4, 7** (VS Integration, Test Suite) — on hold, can resume in parallel
522
- 6. **Epic 14** (External Tooling) — Phase 3, depends on Epics 12, 13. Story 14.3 architecture is prerequisite for Epic 17 Story 17.22 (Jira adapter).
523
-
524
- **Phase D — Phase 3 Features:**
525
- 7. **Epic 19** (BMAD Knowledge Graph) — depends on Epic 15 (extension module structure) and Epic 17 (sprint skill structure settled). Story execution order: 19.1 (core library) → 19.2 (PRD emission) → 19.3 (architecture + epics emission) → 19.4 (story + remaining emission) → 19.5 (open-graph skill) → 19.6 (visualization renderer) → 19.7 (LLM contract validation + tests). Stories 19.2-19.4 can proceed in parallel once 19.1 is done.
526
- 8. **Epic 18** (Roo Code IDE Support) — no dependencies, can proceed independently at any point in Phase C or D.
527
- 9. **Epic 21** (On-Prem / Local-LLM Tuning) — depends on Epics 9, 13, 15, 18 (OpenCode JSON-merge, project-context template stamping pattern, customize-loader, Roo Code agent registration). Story execution: 21.1 (profile prompt + persistence) → 21.2 (universal instruction-block expansion) → 21.3 (`.roomodes` template + Roo Code stamping) + 21.4 (`AGENTS.md` template + OpenCode merge) + 21.5 (`.clinerules` template extension) — these three can run in parallel after 21.2 → 21.6 (on-prem layered guardrails) → 21.7 (BMAD persona phase prefix) → 21.8 (vLLM reference doc + README on-prem section) → 21.9 (tests + validation).
528
-
529
- ---
530
-
531
- ## Epic 5: Bundled BMAD Installation (Phase 2)
532
-
533
- The ma-agents npm package bundles bmad-method and all external BMAD modules (bmb, cis, tea, gds) so that `npx ma-agents install` never performs runtime git clone or npm registry fetch for BMAD components. Installation is deterministic and works in air-gapped environments where the npm package is available.
534
-
535
- ### Story 5.1: Add bmad-method as Direct Dependency
536
-
537
- As a **DevOps engineer**,
538
- I want bmad-method included as a direct npm dependency in ma-agents,
539
- So that BMAD installation does not require fetching bmad-method from the npm registry at runtime.
540
-
541
- **Acceptance Criteria:**
542
-
543
- **Given** `package.json` includes `"bmad-method": "6.0.4"` as a dependency
544
- **When** `npm install` or `npm pack` is run
545
- **Then** bmad-method v6.0.4 is installed in `node_modules/bmad-method/`
546
-
547
- **Given** bmad-method is available in `node_modules/`
548
- **When** `bmad.js` needs to invoke bmad-method
549
- **Then** it uses `require.resolve('bmad-method/tools/bmad-npx-wrapper.js')` to find the local copy
550
- **And** invokes it via `execSync('node <resolved-path> install ...')` instead of `execSync('npx bmad-method install ...')`
551
-
552
- **Given** the vendored bmad-method is used
553
- **When** any install, update, or recompile operation runs
554
- **Then** the behavior is identical to the previous `npx bmad-method` invocation
555
- **And** no npm registry network call is made for bmad-method
556
-
557
- **Given** a project with an existing BMAD installation (installed via previous ma-agents version using `npx bmad-method`),
558
- **When** the project upgrades to this version and runs `npx ma-agents install` or update,
559
- **Then** existing `_bmad/` content is preserved, BMAD workflows continue to function, and no corruption occurs.
560
-
561
- **Technical notes:**
562
- - All 3 `execSync('npx bmad-method ...')` calls in `bmad.js` (lines 14, 37, 112) must be updated
563
- - The resolved path must work cross-platform (use `path.join()`)
564
-
565
- ### Story 5.2: Create BMAD Cache Build Script
566
-
567
- As a **Chief Architect**,
568
- I want a build script that clones all BMAD external modules and their dependencies into `lib/bmad-cache/`,
569
- So that the external modules can be bundled inside the ma-agents npm package for deterministic installation.
570
-
571
- **Acceptance Criteria:**
572
-
573
- **Given** the developer runs `npm run build:bmad-cache` on a connected machine
574
- **When** the script executes
575
- **Then** it clones each module listed in bmad-method's `external-official-modules.yaml` (bmb, cis, tea, gds) into `lib/bmad-cache/<module-code>/` using `git clone --depth 1`
576
- **And** runs `npm install --omit=dev` inside each cloned module directory
577
- **And** removes `.git/` directories from each cloned module to reduce package size
578
- **And** creates a `lib/bmad-cache/cache-manifest.json` recording module versions, clone date, and source URLs
579
-
580
- **Given** the script has already been run and `lib/bmad-cache/` exists
581
- **When** the script is run again with `--force`
582
- **Then** it removes the existing cache and rebuilds from scratch
583
-
584
- **Given** the script is run without `--force` and `lib/bmad-cache/` exists
585
- **When** a module's cached version matches the upstream HEAD
586
- **Then** that module is skipped (incremental update)
587
-
588
- **Given** the npm package is built with `npm pack`,
589
- **When** the resulting tarball is inspected,
590
- **Then** `lib/bmad-cache/` and all module directories are included in the package.
591
-
592
- **Technical notes:**
593
- - The script reads module definitions from bmad-method's `external-official-modules.yaml` (from the bmad-method npm dependency at `node_modules/bmad-method/`)
594
- - The `.npmignore` or `package.json` `files` field must include `lib/bmad-cache/` to ensure it ships with the npm package
595
- - Target bmad-method version: v6.0.4
596
-
597
- ### Story 5.3: Pre-populate BMAD External Module Cache
598
-
599
- As a **DevOps engineer**,
600
- I want the installer to pre-populate `~/.bmad/cache/external-modules/` from the bundled cache before invoking bmad-method,
601
- So that bmad-method finds the external modules locally and skips git clone.
602
-
603
- **Acceptance Criteria:**
604
-
605
- **Given** `lib/bmad-cache/` contains pre-cloned modules (bmb, cis, tea, gds)
606
- **When** the installer runs BMAD installation (install or update)
607
- **Then** before invoking bmad-method, it copies each module from `lib/bmad-cache/<code>/` to `~/.bmad/cache/external-modules/<code>/`
608
- **And** only copies if the target directory does not already exist (or `--force` is set)
609
-
610
- **Given** the target cache directory `~/.bmad/cache/external-modules/bmb/` already exists
611
- **When** the installer runs without `--force`
612
- **Then** the existing cache is preserved (no overwrite)
613
- **And** bmad-method uses the existing cached copy
614
-
615
- **Given** the target cache directory exists
616
- **When** the installer runs with `--force`
617
- **Then** the existing cache is replaced with the bundled version
618
-
619
- **Given** the cache is pre-populated from the bundled copy
620
- **When** bmad-method's `cloneExternalModule()` runs
621
- **Then** the installer sets `GIT_TERMINAL_PROMPT=0` in the child process environment to prevent interactive git prompts
622
- **And** even if `git fetch` succeeds on a connected machine, the installation result remains deterministic because bmad-method uses the existing cache directory without overwriting bundled content
623
-
624
- **Given** the cache is pre-populated
625
- **When** bmad-method's `cloneExternalModule()` runs
626
- **Then** it detects `fs.pathExists(moduleCacheDir)` is true
627
- **And** attempts `git fetch` internally (succeeds silently on connected machines, fails silently in air-gapped environments — either way, the pre-populated cache is used)
628
- **And** proceeds with the cached copy
629
-
630
- **Technical notes:**
631
- - Cache pre-population runs BEFORE any `bmad.installBmad()` or `bmad.updateBmad()` call
632
- - Use `fs.copy()` (from fs-extra) for directory copy
633
- - Create `~/.bmad/cache/external-modules/` directory structure if it doesn't exist
634
- - This is the critical step that makes air-gapped BMAD installation work
635
- - Note: bmad-method's internal git fetch on existing cache directories does a `git fetch` + `git reset --hard origin/main` only if fetch succeeds. To guarantee deterministic output per NFR20/NFR21, the pre-population step should set the cache directories as read-only or the installer should re-copy bundled cache after bmad-method completes. This is a design decision to resolve during implementation.
636
-
637
- ### Story 5.4: Validate Bundled Installation Completeness
638
-
639
- As a **Chief Architect**,
640
- I want to verify that installation from the bundled npm package produces a complete, functional BMAD environment,
641
- So that deterministic installation is validated (NFR21).
642
-
643
- **Acceptance Criteria:**
644
-
645
- **Given** the ma-agents npm package is installed (via `npm install` or `npx`)
646
- **When** `npx ma-agents install` is run with BMAD installation
647
- **Then** the resulting `_bmad/` directory structure is complete
648
- **And** all BMAD modules are present: core, bmm, bmb, cis, tea, gds
649
- **And** all BMAD workflows, agents, and tasks function correctly
650
- **And** all ma-agents customizations are applied (agent personas, MIL-STD-498 workflows, extension module)
651
-
652
- **Given** the installation is complete
653
- **When** the user runs any BMAD workflow (e.g., `/bmad-bmm-create-prd`)
654
- **Then** the workflow executes correctly
655
-
656
- **Given** the installation is complete
657
- **When** the user runs `npx ma-agents status`
658
- **Then** the status shows all installed skills and BMAD modules correctly
659
-
660
- **Technical notes:**
661
- - This is a validation/testing story, not a code implementation story
662
- - Create a test procedure document verifying installation completeness
663
- - Verify that no git clone or npm registry fetch occurs during BMAD installation
664
- - Document any environment-specific considerations (e.g., cache-manifest.json dates)
665
-
666
- ### Story 5.5: Explicit Parameter Passing to bmad-method
667
-
668
- As a **DevOps engineer**,
669
- I want ma-agents to pass all collected installation parameters to bmad-method as explicit CLI flags,
670
- So that BMAD is fully configured for all selected platforms (including OpenCode) without relying on the broken silent install mode.
671
-
672
- **Acceptance Criteria:**
673
-
674
- **Given** the user selects platforms during the ma-agents wizard (e.g., claude-code, cursor, opencode)
675
- **When** bmad.js invokes bmad-method
676
- **Then** it passes `--tools claude-code,cursor,opencode` explicitly
677
- **And** bmad-method configures all selected platforms correctly
678
-
679
- **Given** the user provides their name and language preference during the ma-agents wizard
680
- **When** bmad.js invokes bmad-method
681
- **Then** it passes `--user-name`, `--communication-language`, `--document-output-language`, and `--output-folder` as explicit flags
682
- **And** bmad-method uses these values without prompting
683
-
684
- **Given** all BMAD-relevant parameters are passed as explicit CLI flags
685
- **When** the `--yes` flag is also included
686
- **Then** bmad-method skips prompts only for parameters already supplied via flags
687
- **And** applies its own defaults for any new parameters ma-agents hasn't mapped (FR125)
688
- **And** no interactive BMAD prompt appears to the user (FR126)
689
-
690
- **Given** the installer runs in CI/CD mode (`--yes --force`)
691
- **When** bmad.js constructs the bmad-method command
692
- **Then** it uses the same `buildBmadArgs()` function with pre-determined default answers
693
- **And** produces identical BMAD configuration as interactive mode (FR127)
694
-
695
- **Given** the extension module exists at `lib/bmad-extension/`
696
- **When** bmad.js invokes bmad-method
697
- **Then** it passes `--custom-content` with the quoted path to the extension module
698
- **And** bmad-method validates the module.yaml and deploys the extension
699
-
700
- **Given** bmad-method is invoked with `--action update` for existing installations
701
- **When** the update completes
702
- **Then** all explicit parameters are applied to the update
703
- **And** existing customizations are preserved per bmad-method's update behavior
704
-
705
- **Technical notes:**
706
- - Create `buildBmadArgs(installContext)` function in `bmad.js` that constructs the full parameter list
707
- - All path arguments must be quoted: `--directory "${projectRoot}"` (fixes space-in-path bug)
708
- - The `--modules` flag always passes the full set: `bmm,bmb,cis,tea,gds`
709
- - The `--custom-content` flag points to the extension module: `lib/bmad-extension/`
710
- - Replaces all 3 existing `execSync('npx bmad-method ...')` calls
711
- - Must work with bmad-method v6.0.4 CLI flag interface
712
-
713
- ### Story 5.6: Fix Space-in-Path Bug
714
-
715
- As an **engineer**,
716
- I want ma-agents installation to work in directories containing spaces,
717
- So that I can install in any project location without path-related failures.
718
-
719
- **Acceptance Criteria:**
720
-
721
- **Given** the project is located at a path with spaces (e.g., `d:\My Projects\agents`)
722
- **When** `npx ma-agents install` is run
723
- **Then** the installation completes without errors
724
- **And** all file paths are properly quoted in `execSync` calls
725
-
726
- **Given** any `execSync` call in `bmad.js` that constructs shell commands with paths
727
- **When** the path contains spaces, parentheses, or other shell-special characters
728
- **Then** the path is enclosed in double quotes in the command string
729
-
730
- **Given** `require.resolve()` returns a path with spaces
731
- **When** the resolved path is used in an `execSync` call
732
- **Then** the path is quoted: `execSync('node "${resolvedPath}" install ...')`
733
-
734
- **Technical notes:**
735
- - Audit all `execSync` calls in `bmad.js` for unquoted path interpolation
736
- - The `buildBmadArgs()` function from Story 5.5 should handle quoting for all path arguments
737
- - Test on Windows with paths like `C:\Users\John Smith\Documents\project`
738
- - This is a bug fix — can be combined with Story 5.5 implementation since both touch the same code
739
-
740
- ---
741
-
742
- ## Epic 1: CI/CD Non-Interactive Mode
743
-
744
- Engineers can run `npx ma-agents install --yes` for fully automated, non-interactive skill installation in CI/CD pipelines without human prompts.
745
-
746
- ### Story 1.1: Add --yes Flag for Non-Interactive Skill Installation
747
-
748
- As a **DevOps engineer**,
749
- I want to run `npx ma-agents install --yes` to skip all interactive prompts,
750
- So that I can automate skill installation in CI/CD pipelines without human intervention.
751
-
752
- **Acceptance Criteria:**
753
-
754
- **Given** the CLI is invoked with `--yes` flag
755
- **When** the install command executes
756
- **Then** all interactive prompts (skill selection, agent selection, confirmations) are bypassed with default selections
757
- **And** the installation completes without requiring stdin input
758
- **And** exit code 0 is returned on success, non-zero on failure
759
-
760
- **Given** the CLI is invoked with `--yes --force` flags together
761
- **When** the install command executes
762
- **Then** prompts are skipped AND existing files are overwritten
763
- **And** the behavior is equivalent to answering "yes" to every prompt plus forcing overwrites
764
-
765
- **Given** the CLI is invoked with `--yes` and a specific agent target (e.g., `--agent claude-code`)
766
- **When** the install command executes
767
- **Then** only the specified agent is targeted without prompting for agent selection
768
- **And** all skills are installed to that agent without skill selection prompts
769
-
770
- ---
771
-
772
- ## Epic 2: Language-Specific Skill Expansion
773
-
774
- Engineers working in C++, C#, and Python have dedicated coding standards and best practices skills installed through ma-agents, expanding the skill library with language-specific methodology content.
775
-
776
- ### Story 2.1: Create C++ Best Practices Skill
777
-
778
- As a **C++ engineer**,
779
- I want a C++ coding standards and best practices skill available in ma-agents,
780
- So that my AI coding agent follows our organization's C++ methodology consistently.
781
-
782
- **Acceptance Criteria:**
783
-
784
- **Given** the C++ skill directory exists at `skills/cpp-best-practices/`
785
- **When** the skill is listed via `npx ma-agents list`
786
- **Then** it appears with category "language" and description referencing C++ standards
787
-
788
- **Given** the C++ skill is installed to any supported agent
789
- **When** the agent receives the skill content
790
- **Then** it contains C++ coding standards, naming conventions, memory management patterns, and best practices
791
- **And** the content is applicable to modern C++ (C++17/20/23)
792
-
793
- **Given** the skill directory contains `skill.json`, `SKILL.md`, and optionally `templates/`
794
- **When** no agent-specific template exists for a target agent
795
- **Then** the `SKILL.md` canonical content is used as fallback per template resolution priority
796
-
797
- ### Story 2.2: Create C# Best Practices Skill
798
-
799
- As a **C# engineer**,
800
- I want a C# coding standards and best practices skill available in ma-agents,
801
- So that my AI coding agent follows our organization's C# methodology consistently.
802
-
803
- **Acceptance Criteria:**
804
-
805
- **Given** the C# skill directory exists at `skills/csharp-best-practices/`
806
- **When** the skill is listed via `npx ma-agents list`
807
- **Then** it appears with category "language" and description referencing C# standards
808
-
809
- **Given** the C# skill is installed to any supported agent
810
- **When** the agent receives the skill content
811
- **Then** it contains C# coding standards, .NET patterns, async/await best practices, and LINQ guidelines
812
- **And** the content covers .NET 8+ modern patterns
813
-
814
- **Given** the skill follows the standard skill schema contract
815
- **When** installed across multiple agents
816
- **Then** it produces functionally equivalent behavior regardless of target agent (FR36)
817
-
818
- ### Story 2.3: Create Python Best Practices Skill
819
-
820
- As a **Python engineer**,
821
- I want a Python coding standards and best practices skill available in ma-agents,
822
- So that my AI coding agent follows our organization's Python methodology consistently.
823
-
824
- **Acceptance Criteria:**
825
-
826
- **Given** the Python skill directory exists at `skills/python-best-practices/`
827
- **When** the skill is listed via `npx ma-agents list`
828
- **Then** it appears with category "language" and description referencing Python standards
829
-
830
- **Given** the Python skill is installed to any supported agent
831
- **When** the agent receives the skill content
832
- **Then** it contains Python coding standards, PEP 8 conventions, type hinting patterns, and packaging best practices
833
- **And** the content covers Python 3.10+ modern patterns
834
-
835
- **Given** all three language skills (C++, C#, Python) are installed
836
- **When** the manifest is checked via `npx ma-agents status`
837
- **Then** all three appear with correct versions and installation status per agent
838
-
839
- ---
840
-
841
- ## Epic 3: Skill Authoring Tooling
842
-
843
- The Chief Architect has tooling to scaffold, validate, and test new skills, lowering the barrier for organizational skill creators and ensuring consistency across the skill library.
844
-
845
- ### Story 3.1: Skill Scaffolding Command
846
-
847
- As a **Chief Architect**,
848
- I want to run `npx ma-agents create-skill <skill-name>` to generate a new skill directory with all required files,
849
- So that I can author new skills quickly without manually creating the directory structure.
850
-
851
- **Acceptance Criteria:**
852
-
853
- **Given** the user runs `npx ma-agents create-skill my-new-skill`
854
- **When** the command executes
855
- **Then** a directory `skills/my-new-skill/` is created with:
856
- - `skill.json` populated with name, version "1.0.0", empty description, default category, empty tags, `always_load: false`
857
- - `SKILL.md` with a template structure including frontmatter and placeholder content sections
858
- - `templates/` directory (empty, ready for agent-specific templates)
859
- - `references/` directory (empty)
860
- - `assets/` directory (empty)
861
-
862
- **Given** a skill with the same name already exists
863
- **When** the create-skill command is run
864
- **Then** the command fails with an error message and does not overwrite the existing skill
865
- **And** a hint suggests using a different name or removing the existing skill first
866
-
867
- **Given** the skill name contains invalid characters (spaces, uppercase, special chars)
868
- **When** the create-skill command is run
869
- **Then** the command fails with an error explaining kebab-case naming requirement
870
-
871
- ### Story 3.2: Skill Validation Command
872
-
873
- As a **Chief Architect**,
874
- I want to run `npx ma-agents validate-skill <skill-name>` to check a skill for schema compliance,
875
- So that I can catch skill format errors before distribution.
876
-
877
- **Acceptance Criteria:**
878
-
879
- **Given** the user runs `npx ma-agents validate-skill my-skill`
880
- **When** the skill directory exists and contains valid files
881
- **Then** the command reports "VALID" with a summary of skill metadata
882
-
883
- **Given** the skill is missing `skill.json`
884
- **When** the validate command runs
885
- **Then** it reports "INVALID: missing required file skill.json"
886
-
887
- **Given** the skill is missing `SKILL.md`
888
- **When** the validate command runs
889
- **Then** it reports "INVALID: missing required file SKILL.md"
890
-
891
- **Given** the `skill.json` has missing or invalid fields (no name, no version, invalid category)
892
- **When** the validate command runs
893
- **Then** it reports each validation error with the field name and expected format
894
-
895
- **Given** the skill has agent-specific templates in `templates/`
896
- **When** the validate command runs
897
- **Then** it verifies each template filename matches a known agent registry key
898
- **And** warns about templates targeting unknown agents
899
-
900
- ### Story 3.3: Skill Test Install Command
901
-
902
- As a **Chief Architect**,
903
- I want to run `npx ma-agents test-skill <skill-name>` to perform a dry-run installation across all agents,
904
- So that I can verify the skill installs correctly before publishing.
905
-
906
- **Acceptance Criteria:**
907
-
908
- **Given** the user runs `npx ma-agents test-skill my-skill`
909
- **When** the command executes
910
- **Then** it simulates installation to each supported agent without writing files
911
- **And** reports which template would be used per agent (agent-specific, generic, or SKILL.md fallback)
912
- **And** shows the resolved content that would be installed (with frontmatter injection)
913
-
914
- **Given** a template has syntax errors or missing frontmatter
915
- **When** the test-skill command runs
916
- **Then** it reports the specific issue per agent target
917
-
918
- **Given** the `--write` flag is provided
919
- **When** the test-skill command runs
920
- **Then** it writes the resolved output to a `test-output/` directory within the skill (gitignored) for manual review
921
- **And** does NOT install to actual agent directories
922
-
923
- ---
924
-
925
- ## Epic 4: Visual Studio Agent Integration
926
-
927
- Engineers can target Visual Studio's AI assistant for skill installation, expanding agent coverage to the VS ecosystem and closing the last major agent gap.
928
-
929
- ### Story 4.1: Research Visual Studio AI Agent Configuration
930
-
931
- As a **Chief Architect**,
932
- I want to understand how Visual Studio exposes AI agent configuration,
933
- So that we can determine the correct injection mechanism for skill installation.
934
-
935
- **Acceptance Criteria:**
936
-
937
- **Given** Visual Studio has GitHub Copilot integration
938
- **When** the integration mechanism is investigated
939
- **Then** a technical note is produced documenting:
940
- - Where VS stores AI agent instructions (file paths, config directories)
941
- - What format VS expects (markdown, JSON, YAML, or other)
942
- - How VS Copilot Chat extensions handle custom instructions
943
- - Whether `.vs/` directory, `.editorconfig`, or another mechanism is used
944
- - Platform path differences (Windows-only or cross-platform VS Code distinction)
945
-
946
- **Given** the research is complete
947
- **When** the findings are documented
948
- **Then** a clear recommendation exists for the agent registry configuration object fields
949
-
950
- ### Story 4.2: Add Visual Studio Agent to Registry
951
-
952
- As an **engineer**,
953
- I want Visual Studio listed as a target agent in ma-agents,
954
- So that I can install skills into Visual Studio's AI assistant.
955
-
956
- **Acceptance Criteria:**
957
-
958
- **Given** the VS agent configuration is understood from Story 4.1
959
- **When** a new agent object is added to `lib/agents.js`
960
- **Then** it includes: name, category, platform paths, instruction file, and resource map
961
- **And** no changes are needed to `installer.js` or other modules (NFR13)
962
-
963
- **Given** the VS agent is registered
964
- **When** `npx ma-agents list --agents` is run
965
- **Then** Visual Studio appears in the agent list
966
-
967
- **Given** a skill is installed targeting the VS agent
968
- **When** the install completes
969
- **Then** skill content is placed in the correct VS configuration directory
970
- **And** the manifest tracks the VS agent installation
971
-
972
- ---
973
-
974
- ## Epic 6: Methodology Onboarding Package
975
-
976
- Teams receive a methodology presentation bundled with installation, enabling organizational onboarding to BMAD-METHOD without separate training materials.
977
-
978
- ### Story 6.1: Bundle Methodology Presentation with Installation
979
-
980
- As a **team lead**,
981
- I want the BMAD-METHOD presentation included when ma-agents is installed,
982
- So that new team members can learn the methodology without needing separate training materials.
983
-
984
- **Acceptance Criteria:**
985
-
986
- **Given** a methodology presentation file exists in the ma-agents package
987
- **When** `npx ma-agents install` is run with BMAD installation
988
- **Then** the presentation is copied to the project's BMAD output directory (e.g., `_bmad-output/methodology/`)
989
- **And** the user is informed of the presentation location in the install summary
990
-
991
- **Given** the presentation already exists in the target directory
992
- **When** a subsequent install or update is run
993
- **Then** the presentation is updated only if a newer version exists
994
- **And** existing copies are not overwritten without the `--force` flag
995
-
996
- ### Story 6.2: Add Methodology Overview Command
997
-
998
- As an **engineer**,
999
- I want to run `npx ma-agents methodology` to see an overview of the BMAD-METHOD,
1000
- So that I can quickly understand the methodology without opening the full presentation.
1001
-
1002
- **Acceptance Criteria:**
1003
-
1004
- **Given** the user runs `npx ma-agents methodology`
1005
- **When** the command executes
1006
- **Then** a concise CLI summary of BMAD-METHOD is displayed:
1007
- - What it is (one paragraph)
1008
- - The SDLC phases covered
1009
- - The agent personas available
1010
- - Where to find the full presentation
1011
-
1012
- **Given** BMAD is not installed in the current project
1013
- **When** the methodology command is run
1014
- **Then** it still displays the overview (it's part of ma-agents, not dependent on BMAD install)
1015
- **And** suggests running `npx ma-agents install` to get started
1016
-
1017
- **Status: DEFERRED** — Story 6.2 is not in the current sprint plan. Epic 6's MVP is deliverable with Story 6.1 alone (methodology content is deployed to a known location). Story 6.2 (discoverability command) can be added via correct-course if desired after 6.1 ships. No implementation artifact file exists for this story.
1018
-
1019
- ---
1020
-
1021
- ## Epic 7: Test Suite Foundation
1022
-
1023
- Contributors have automated regression tests verifying architectural contracts across the 4 core modules (cli.js, installer.js, agents.js, bmad.js), catching pipeline ordering violations, registry inconsistencies, and template resolution bugs before release.
1024
-
1025
- **FRs covered:** FR73
1026
- **Dependencies:** Testing framework decision (Architecture, Phase 2 Decisions table) must be finalized before Story 7.1 begins. Epic 9 (OpenCode) affects agent count — tests must use dynamic assertions.
1027
- **Test isolation strategy:** All stories use temp directories for file I/O. Module tests use dependency injection or function-level stubs to prevent real BMAD operations, real installs, or real file system writes outside temp. Each story must document its isolation approach in its acceptance criteria.
1028
- **Coverage targets:** All exported/public functions in the 4 modules. Minimum one happy-path and one error-path assertion per function. Template resolution priority chain requires dedicated edge-case coverage (missing agent template, missing generic template, all fallbacks exhausted).
1029
- **Audience:** Contributors and maintainers — not end users. This epic protects internal code quality.
1030
-
1031
- ### Story 7.1: Set Up Test Framework and First Tests for agents.js
1032
-
1033
- As a **contributor**,
1034
- I want a test framework configured with initial tests for the agent registry module,
1035
- So that agent configuration changes are verified automatically.
1036
-
1037
- **Prerequisites:** Testing framework architectural decision finalized (Architecture, Phase 2 Decisions table). The chosen framework is used throughout — do not assume a specific framework in acceptance criteria.
1038
-
1039
- **Acceptance Criteria:**
1040
-
1041
- **Given** the chosen test framework is configured in `package.json`
1042
- **When** `npm test` is executed
1043
- **Then** tests run and report results with pass/fail counts
1044
-
1045
- **Given** tests exist for `agents.js`
1046
- **When** the test suite runs
1047
- **Then** it verifies:
1048
- - All agents returned by the registry are present with required fields (name, category, paths, instruction file) — assert dynamically against the registry, not a hardcoded count
1049
- - Each agent has a valid `injectionStrategy` object with `position` defined
1050
- - Platform path resolution returns valid paths for the current OS
1051
- - Resource maps are defined for agents that need them (e.g., Cline)
1052
- - No duplicate agent names exist in the registry
1053
- - OpenCode agent (if registered) has `position: 'json-merge'` injection strategy
1054
-
1055
- **Test isolation:** `agents.js` is a pure data + path module with no side effects — tests can call its functions directly without mocking. No file system writes occur.
1056
-
1057
- ### Story 7.2: Add Tests for installer.js Core Operations
1058
-
1059
- As a **contributor**,
1060
- I want tests covering the installer engine's core operations,
1061
- So that skill installation, manifest management, and MANIFEST.yaml generation are protected against regressions.
1062
-
1063
- **Acceptance Criteria:**
1064
-
1065
- **Given** tests exist for `installer.js`
1066
- **When** the test suite runs
1067
- **Then** it verifies:
1068
- - Skill discovery scans the `skills/` directory and finds all valid skills (assert count matches actual directory contents, not a hardcoded number)
1069
- - MANIFEST.yaml generation produces valid YAML from installed skills
1070
- - Manifest read/write operations are atomic (simulate write failure mid-operation — manifest remains in last valid state) (NFR7)
1071
-
1072
- **Given** a test skill directory and a test agent config directory are set up in a temp directory
1073
- **When** install operations are tested
1074
- **Then** files are written to the temp directory, not actual agent config directories
1075
-
1076
- **Template resolution priority chain (dedicated coverage):**
1077
-
1078
- **Given** a test skill with all three template levels (agent-specific, generic, SKILL.md)
1079
- **When** resolution runs for an agent with an agent-specific template
1080
- **Then** the agent-specific template is selected
1081
-
1082
- **Given** a test skill with only generic and SKILL.md (no agent-specific template)
1083
- **When** resolution runs
1084
- **Then** the generic template is selected
1085
-
1086
- **Given** a test skill with only SKILL.md (no templates directory)
1087
- **When** resolution runs
1088
- **Then** SKILL.md is used as fallback
1089
-
1090
- **Given** a test skill where SKILL.md is also missing or empty
1091
- **When** resolution runs
1092
- **Then** a clear error is raised (not a silent failure)
1093
-
1094
- **Given** an agent that has no templates directory in the test skill
1095
- **When** resolution runs for that agent
1096
- **Then** the chain falls through correctly to generic → SKILL.md
1097
-
1098
- **Additive-only verification (NFR5):**
1099
-
1100
- **Given** a temp agent config directory with pre-existing files
1101
- **When** a skill install operation completes
1102
- **Then** all pre-existing files remain untouched — only new skill files are added
1103
- **And** no files are deleted or overwritten unless the same skill is being updated
1104
-
1105
- **Test isolation:** All file operations target temp directories. Installer functions that call `agents.js` for path resolution are called with overridden paths pointing to temp. No real agent config directories are read or written.
1106
-
1107
- ### Story 7.3: Add Tests for bmad.js Pipeline Ordering
1108
-
1109
- As a **contributor**,
1110
- I want tests verifying the BMAD pipeline executes stages in strict order,
1111
- So that customization ordering bugs are caught before release.
1112
-
1113
- **Acceptance Criteria:**
1114
-
1115
- **Stage ordering verification:**
1116
-
1117
- **Given** `bmad.js` pipeline functions are instrumented with a call-order recorder (e.g., each stage function is wrapped to push its name onto an array)
1118
- **When** the full pipeline executes against a temp directory
1119
- **Then** the recorded call order is exactly:
1120
- 1. Install BMAD core files
1121
- 2. Apply YAML config customizations
1122
- 3. Trigger recompile
1123
- 4. Apply workflow customizations
1124
- 5. Apply template customizations
1125
- 6. Apply agent customizations
1126
- **And** no stage is skipped or reordered
1127
-
1128
- **Stage failure halts pipeline:**
1129
-
1130
- **Given** stage 2 (Apply YAML configs) is stubbed to throw an error
1131
- **When** the pipeline executes
1132
- **Then** stages 3–6 do not execute
1133
- **And** the error is propagated to the caller
1134
-
1135
- **Given** stage 3 (Trigger recompile) is stubbed to throw an error
1136
- **When** the pipeline executes
1137
- **Then** stages 4–6 do not execute
1138
- **And** the error is propagated to the caller
1139
-
1140
- **Given** stage 5 (Apply template customizations) is stubbed to throw an error
1141
- **When** the pipeline executes
1142
- **Then** stage 6 does not execute
1143
-
1144
- **Note:** Testing failure at stages 2, 3, and 5 covers all three boundary types: pre-recompile failure, recompile failure, and post-recompile failure. If the pipeline uses a sequential executor pattern, these three cases are sufficient to prove halt-on-failure behavior.
1145
-
1146
- **Test isolation:** Pipeline functions that perform file system operations are stubbed or pointed at temp directories. The recompile step must NOT trigger an actual BMAD recompile — stub it to record the call and return success (or throw, for failure tests). No real BMAD installation is required.
1147
-
1148
- ### Story 7.4: Add Tests for cli.js Command Routing
1149
-
1150
- As a **contributor**,
1151
- I want tests covering CLI command parsing and routing,
1152
- So that command-line argument handling is verified automatically.
1153
-
1154
- **Acceptance Criteria:**
1155
-
1156
- **Command routing — dynamic verification:**
1157
-
1158
- **Given** `cli.js` has a set of registered commands
1159
- **When** the test suite runs
1160
- **Then** every registered command routes to its expected handler function — assert against the actual command registry, not a hardcoded list
1161
- **And** unknown commands produce a helpful error message suggesting valid commands
1162
-
1163
- **BMAD-specific commands:**
1164
-
1165
- **Given** BMAD commands exist (e.g., install-bmad, update-bmad, or equivalent routing through `bmad.js`)
1166
- **When** BMAD commands are invoked
1167
- **Then** they route to `bmad.js` handler functions correctly
1168
- **Note:** Inspect `cli.js` to identify all command routes including BMAD-specific ones — do not assume only install/list/status/uninstall exist
1169
-
1170
- **Flag parsing:**
1171
-
1172
- **Given** CLI arguments include flags (`--yes`, `--force`, `--agent <name>`, `--help`, `--version`)
1173
- **When** arguments are parsed
1174
- **Then** boolean flags (`--yes`, `--force`) are extracted as `true`
1175
- **And** value flags (`--agent`) capture their argument
1176
- **And** `--help` triggers help output without executing a command
1177
- **And** `--version` displays the version from `package.json`
1178
-
1179
- **Interactive vs non-interactive boundary:**
1180
-
1181
- **Given** no `--yes` flag is provided and stdin is a TTY
1182
- **When** the CLI starts
1183
- **Then** it enters interactive wizard mode (inquirer-based)
1184
-
1185
- **Given** `--yes` flag is provided
1186
- **When** the CLI starts
1187
- **Then** it skips all interactive prompts and uses defaults (CI/CD mode per FR6)
1188
-
1189
- **Note:** These tests verify the boundary detection logic, not the full wizard flow. Assert that the correct code path is selected, not that inquirer renders correctly.
1190
-
1191
- **Test isolation:** CLI tests stub the handler functions (`installer.js`, `bmad.js`) so that command routing is tested without triggering real installs or BMAD operations. Stdin/TTY detection is stubbed to test both interactive and non-interactive paths.
1192
-
1193
- ---
1194
-
1195
- ## Epic 8: Skill Enforcement Architecture (Phase 2)
1196
-
1197
- **Goal:** Engineers' installed skills are reliably enforced by all agents — zero-reminder workflow.
1198
- **FRs covered:** FR51, FR52, FR53, FR54, FR55
1199
- **NFRs addressed:** NFR16 (extension survives updates), NFR17 (zero core modifications)
1200
-
1201
- ### Story 8.1: Move Instruction Injection to TOP Priority Position
1202
-
1203
- As a **Chief Architect**,
1204
- I want the `<!-- MA-AGENTS-START -->` instruction block injected at the TOP of agent instruction files (after any file headers),
1205
- So that skills have the highest priority during LLM context processing and are not ignored.
1206
-
1207
- **Acceptance Criteria:**
1208
-
1209
- **Given** the installer runs for any markdown-based agent (Claude Code, Cursor, Copilot, etc.)
1210
- **When** the instruction block is injected into the agent's instruction file
1211
- **Then** the block is placed at the TOP of the file, after any file headers (e.g., YAML frontmatter delimited by `---`)
1212
- **And** the `skipPatterns` from the agent's `injectionStrategy` in `agents.js` are respected
1213
-
1214
- **Given** an instruction file already has an `<!-- MA-AGENTS-START -->` block
1215
- **When** the installer runs again
1216
- **Then** the existing block is found and replaced in-place at its current position
1217
- **And** no duplicate blocks are created
1218
-
1219
- **Given** an instruction file has no existing ma-agents block
1220
- **When** the installer injects for the first time
1221
- **Then** the block is inserted after skipped headers but before all other content
1222
-
1223
- ### Story 8.2: Add Agent-Aware Injection Strategy to Registry
1224
-
1225
- As a **Chief Architect**,
1226
- I want each agent in `agents.js` to have an `injectionStrategy` property specifying format, position, and skip patterns,
1227
- So that the installer can inject instructions correctly for each agent's file format without hardcoding per-agent logic in `installer.js`.
1228
-
1229
- **Acceptance Criteria:**
1230
-
1231
- **Given** the `agents.js` registry
1232
- **When** any agent entry is reviewed
1233
- **Then** each agent has an `injectionStrategy` object with `position` and optional `skipPatterns`
1234
- **And** markdown agents have `position: 'top'` with appropriate skip patterns
1235
-
1236
- **Given** `installer.js` performs injection
1237
- **When** it processes any agent
1238
- **Then** it reads `injectionStrategy` from the agent's registry entry
1239
- **And** all format-awareness logic lives in `agents.js`, not in `installer.js`
1240
-
1241
- ### Story 8.3: Create BMAD Extension Module Structure
1242
-
1243
- As a **Chief Architect**,
1244
- I want the installer to deploy a BMAD extension module (`extends-module: bmm`) with `critical_actions` for skill loading,
1245
- So that all BMAD agents automatically load skills on activation before any menu or workflow executes.
1246
-
1247
- **Acceptance Criteria:**
1248
-
1249
- **Given** `npx ma-agents install` is run with BMAD installation
1250
- **When** the BMAD pipeline completes
1251
- **Then** `lib/bmad-extension/module.yaml` exists with `extends-module: bmm`
1252
- **And** `lib/bmad-extension/module-help.csv` exists with registered phases
1253
- **And** `lib/bmad-extension/agents/` contains 11 `.customize.yaml` files
1254
-
1255
- **Given** the 4 custom agents (SRE, DevOps, Cyber, MIL-498)
1256
- **When** their `.customize.yaml` files are deployed
1257
- **Then** each contains full customization: persona, menu, and `critical_actions` steps 1-3 for skill loading
1258
-
1259
- **Given** the 7 built-in BMM agents (PM, Architect, Dev, QA, SM, Tech Writer, UX Designer)
1260
- **When** their `.customize.yaml` files are deployed
1261
- **Then** each contains only `critical_actions` steps 1-3 for skill loading (no persona or menu overrides)
1262
-
1263
- **Given** the extension module is deployed
1264
- **When** `npx bmad-method install --action update` is run
1265
- **Then** the extension module survives the update without losing functionality (NFR16)
1266
-
1267
- ### Story 8.4: Integration Verification
1268
-
1269
- As a **Chief Architect**,
1270
- I want to verify that Stories 8.1, 8.2, and 8.3 work together end-to-end,
1271
- So that the skill enforcement architecture is validated as a complete pipeline before research stories proceed.
1272
-
1273
- **Acceptance Criteria:**
1274
-
1275
- **Given** Stories 8.1, 8.2, and 8.3 are all implemented
1276
- **When** `npx ma-agents install` runs for Claude Code
1277
- **Then** the MA-AGENTS block is injected at TOP of `.claude/CLAUDE.md` (after frontmatter)
1278
- **And** `injectionStrategy` from agents.js was read and used
1279
-
1280
- **Given** install runs with BMAD
1281
- **When** BMAD pipeline completes
1282
- **Then** extension module is deployed with correct per-agent MANIFEST paths
1283
- **And** MA-AGENTS block is injected at TOP of BMAD agent .md files
1284
-
1285
- **Given** a second install runs (update scenario)
1286
- **When** injection runs on files that already have MA-AGENTS blocks
1287
- **Then** blocks are replaced in-place (no duplicates)
1288
-
1289
- ### Story 8.5: Research and Implement Per-Agent Enforcement Hooks
1290
-
1291
- As a **Chief Architect**,
1292
- I want per-agent enforcement mechanisms researched and implemented where agents support them,
1293
- So that skill compliance is enforced at multiple layers beyond instruction placement.
1294
-
1295
- **Acceptance Criteria:**
1296
-
1297
- **Given** Claude Code supports hooks (pre-tool-use, post-tool-use)
1298
- **When** enforcement hooks are researched
1299
- **Then** a technical note documents: hook types available, how they can verify manifest was read, implementation approach
1300
- **And** if feasible, a Claude Code hook is implemented that checks skill loading
1301
-
1302
- **Given** other agents may have enforcement mechanisms
1303
- **When** the research is conducted
1304
- **Then** findings document which agents support hooks/verification and which don't
1305
- **And** recommendations for future implementation are provided
1306
-
1307
- ### Story 8.6: Research Context Persistence Strategies
1308
-
1309
- As a **Chief Architect**,
1310
- I want context persistence strategies researched to ensure skills survive LLM context compression,
1311
- So that long sessions don't lose skill directives.
1312
-
1313
- **Acceptance Criteria:**
1314
-
1315
- **Given** BMAD supports sidecar memory (`hasSidecar`/`sidecar-folder`)
1316
- **When** context persistence is researched
1317
- **Then** a technical note documents: how sidecar memory works, whether it can store skill state, restoration patterns
1318
- **And** recommendations for implementation are provided
1319
-
1320
- **Given** the research is complete
1321
- **When** findings are documented
1322
- **Then** a clear recommendation exists for whether to implement persistence now or defer to a future phase
1323
-
1324
- ---
1325
-
1326
- ## Epic 9: OpenCode Agent Support (Phase 2)
1327
-
1328
- **Goal:** Engineers can target OpenCode as the 12th supported agent for skill installation with JSON-based instruction injection.
1329
- **FRs covered:** FR56, FR57
1330
- **NFRs addressed:** NFR18 (additive-only JSON merge), NFR13 (config-driven registry)
1331
-
1332
- ### Story 9.1: Register OpenCode Agent in Registry
1333
-
1334
- As a **Chief Architect**,
1335
- I want OpenCode added to `agents.js` as the 12th agent with its configuration, skill directory, and JSON injection strategy,
1336
- So that the installer can target OpenCode using the same config-driven pattern as all other agents.
1337
-
1338
- **Acceptance Criteria:**
1339
-
1340
- **Given** the `agents.js` registry
1341
- **When** the OpenCode agent entry is added
1342
- **Then** it includes: `name: 'opencode'`, `category: 'ide'`, `configDir: '.opencode'`, `skillsDir: '.opencode/skills'`, `instructionFile: 'opencode.json'`
1343
- **And** `injectionStrategy` is `{ position: 'json-merge', targetKey: 'instructions' }`
1344
-
1345
- **Given** the installer runs with `--agent opencode`
1346
- **When** agent resolution occurs
1347
- **Then** OpenCode is found in the registry and processed like any other agent
1348
- **And** no code changes to `installer.js` were needed (NFR13)
1349
-
1350
- ### Story 9.2: Implement JSON Merge Injection for OpenCode
1351
-
1352
- As a **Chief Architect**,
1353
- I want the installer to support JSON-merge injection that creates or additively merges `opencode.json`,
1354
- So that skill instructions reach OpenCode without corrupting existing user configuration (NFR18).
1355
-
1356
- **Acceptance Criteria:**
1357
-
1358
- **Given** no `opencode.json` exists in the project
1359
- **When** the installer runs for OpenCode
1360
- **Then** a new `opencode.json` is created with the ma-agents `instructions` array entries tagged with `[ma-agents]`
1361
-
1362
- **Given** an existing `opencode.json` with user-defined instructions and other configuration keys
1363
- **When** the installer runs for OpenCode
1364
- **Then** existing non-ma-agents instructions are preserved
1365
- **And** existing ma-agents entries (identified by `[ma-agents]` tag) are replaced with fresh entries
1366
- **And** all other JSON keys (not `instructions`) are preserved exactly as-is
1367
-
1368
- **Given** an existing `opencode.json` with invalid JSON
1369
- **When** the installer attempts injection
1370
- **Then** a clear error message is displayed and the file is NOT modified
1371
- **And** the installer continues with other agents (non-fatal)
1372
-
1373
- ---
1374
-
1375
- ## Epic 10: Project Knowledge Preservation (Phase 2)
1376
-
1377
- **Goal:** `_bmad-output` is version-controlled project knowledge, never gitignored.
1378
- **FRs covered:** FR58, FR59
1379
-
1380
- ### Story 10.1: Ensure _bmad-output Is Not Gitignored
1381
-
1382
- As a **Chief Architect**,
1383
- I want the installer to remove `_bmad-output` from `.gitignore` if present and never add it,
1384
- So that planning artifacts are tracked as version-controlled project knowledge.
1385
-
1386
- **Acceptance Criteria:**
1387
-
1388
- **Given** a project with `_bmad-output` listed in `.gitignore`
1389
- **When** the installer runs (install or update)
1390
- **Then** the `_bmad-output` line is removed from `.gitignore`
1391
- **And** a message is displayed: `"_bmad-output is now tracked as project knowledge (not gitignored)"`
1392
-
1393
- **Given** a project with no `_bmad-output` in `.gitignore`
1394
- **When** the installer runs
1395
- **Then** `.gitignore` is not modified for this concern
1396
-
1397
- **Given** no `.gitignore` file exists
1398
- **When** the installer runs
1399
- **Then** no `.gitignore` is created for this purpose
1400
-
1401
- **Given** the installer creates or updates `.gitignore` for other entries (e.g., `node_modules`, `_bmad/`)
1402
- **When** it writes the file
1403
- **Then** `_bmad-output` is never included in any gitignore entries
1404
-
1405
- ### Story 10.2: Document _bmad-output Policy in README and Installation Guidance
1406
-
1407
- As a **Chief Architect**,
1408
- I want the `_bmad-output` folder policy documented in the README and installation guidance,
1409
- So that developers understand why `_bmad-output` is version-controlled and do not add it back to `.gitignore`.
1410
-
1411
- **Acceptance Criteria:**
1412
-
1413
- **Given** the project README
1414
- **When** a developer reads it
1415
- **Then** it contains a section explaining that `_bmad-output/` is intentionally tracked in version control as project knowledge
1416
- **And** the section explains what the folder contains (planning artifacts: PRDs, architecture, epics, stories, sprint plans)
1417
- **And** the section explains why it is tracked (team alignment, AI context continuity, project history)
1418
-
1419
- **Given** the installation or getting-started documentation
1420
- **When** a developer sets up the tool
1421
- **Then** the guidance explicitly states that `_bmad-output/` must not be added to `.gitignore` and explains that the installer will remove it if found
1422
-
1423
- **Dependency:** Story 10.1 (documents the installer behavior introduced there)
1424
-
1425
- ---
1426
-
1427
- ## Epic 11: Bug Management System (Phase 2)
1428
-
1429
- **Goal:** Agents detect defects in already-delivered code and generate structured bug reports that enter the backlog for sprint prioritization.
1430
- **FRs covered:** FR60, FR61, FR62, FR63, FR64
1431
- **NFRs addressed:** NFR19 (menu + slash command invocation)
1432
- **Dependency:** Uses extension module from Epic 8 for workflow deployment
1433
-
1434
- ### Story 11.1: Create auto-bug-detection Skill
1435
-
1436
- As a **Chief Architect**,
1437
- I want an `auto-bug-detection` skill that instructs agents to identify and report defects in already-delivered code,
1438
- So that bugs are caught proactively during all agent sessions.
1439
-
1440
- **Acceptance Criteria:**
1441
-
1442
- **Given** the `auto-bug-detection` skill is authored
1443
- **When** it is installed via ma-agents
1444
- **Then** `skills/auto-bug-detection/skill.json` exists with `always_load: true`
1445
- **And** `skills/auto-bug-detection/SKILL.md` contains detection criteria and reporting instructions
1446
-
1447
- **Given** the skill is loaded by an agent via `critical_actions`
1448
- **When** the agent encounters a defect in already-delivered code during any session
1449
- **Then** the skill directives instruct the agent to report the defect using a structured format
1450
- **And** the skill distinguishes between bugs in delivered code vs. work-in-progress
1451
-
1452
- **Given** the skill follows standard skill schema
1453
- **When** validated against skill.json contract
1454
- **Then** it passes all existing skill validation rules
1455
-
1456
- ### Story 11.2: Create Bug Story Extension Workflow
1457
-
1458
- As a **Scrum Master**,
1459
- I want a BMAD extension workflow that creates structured bug stories from detected defects,
1460
- So that bugs enter the backlog with consistent format and are actionable for sprint planning.
1461
-
1462
- **Acceptance Criteria:**
1463
-
1464
- **Given** the `create-bug-story` workflow exists in `lib/bmad-extension/workflows/create-bug-story/workflow.md`
1465
- **When** invoked via BMAD agent menu or slash command (NFR19)
1466
- **Then** it guides the agent through creating a bug story with: title, reproduction steps, expected vs actual behavior, severity, affected component
1467
-
1468
- **Given** a bug story is created
1469
- **When** it is saved
1470
- **Then** it exists as a standalone backlog item alongside user stories (FR64)
1471
- **And** it follows a consistent template format
1472
-
1473
- **Given** the workflow is registered in `module-help.csv`
1474
- **When** a BMAD agent loads the extension module
1475
- **Then** the workflow appears in the agent's available workflows
1476
-
1477
- ### Story 11.3: Integrate Bug Detection into Code Review
1478
-
1479
- As a **Developer**,
1480
- I want the code review workflow to include explicit bug detection checks,
1481
- So that defects in delivered code are caught during review and routed to the bug management system.
1482
-
1483
- **Acceptance Criteria:**
1484
-
1485
- **Given** a code review is in progress
1486
- **When** the `auto-bug-detection` skill is loaded (via `critical_actions`)
1487
- **Then** the reviewing agent evaluates delivered code for defects as part of the review
1488
- **And** detected bugs are flagged separately from code review feedback
1489
-
1490
- **Given** a bug is detected during code review
1491
- **When** the reviewer documents it
1492
- **Then** the reviewer recommends creating a bug story via the `create-bug-story` workflow
1493
- **And** the bug is tracked independently from the story being reviewed
1494
-
1495
- ---
1496
-
1497
- ## Epic 12: Realistic Sprint Management (Phase 2) **[SUPERSEDED by Epic 17]**
1498
-
1499
- > **DEPRECATION NOTICE:** Epic 12 delivered workflow shell files but NOT the underlying sprint data model. Epic 17 (Sprint Management Model Rework) builds the unified `sprint-status.yaml` model and rewires all workflows. All FR65-FR71 functionality is now delivered through Epic 17's reworked stories. Epic 12 stories below are retained for historical context only — do not implement them.
1500
-
1501
- **Goal:** Project managers work with flat backlogs containing stories and bugs, capacity-based sprints, and multi-criteria prioritization.
1502
- **FRs covered:** FR65, FR66, FR67, FR68, FR69, FR70, FR71
1503
- **NFRs addressed:** NFR19 (menu + slash command invocation)
1504
- **Dependency:** Uses extension module from Epic 8 for workflow deployment
1505
-
1506
- ### Story 12.1: Create Add Sprint Extension Workflow
1507
-
1508
- As a **Scrum Master**,
1509
- I want an extension workflow to create new sprints with capacity limits,
1510
- So that sprint planning uses realistic capacity-based constraints rather than unbounded scope.
1511
-
1512
- **Acceptance Criteria:**
1513
-
1514
- **Given** the `add-sprint` workflow exists in `lib/bmad-extension/workflows/add-sprint/workflow.md`
1515
- **When** invoked via BMAD agent menu or slash command (NFR19)
1516
- **Then** it guides creation of a sprint with: sprint name/number, capacity (item count), start/end context
1517
- **And** the sprint is created as a trackable artifact
1518
-
1519
- **Given** sprint capacity is defined by item count (FR66)
1520
- **When** a sprint is created
1521
- **Then** capacity is expressed as maximum number of items (stories + bugs)
1522
- **And** the workflow validates capacity is a positive integer
1523
-
1524
- ### Story 12.2: Create Add-to-Sprint Extension Workflow
1525
-
1526
- As a **Scrum Master**,
1527
- I want an extension workflow to assign backlog items to a sprint using multi-criteria prioritization,
1528
- So that the highest-value items are selected within sprint capacity.
1529
-
1530
- **Acceptance Criteria:**
1531
-
1532
- **Given** the `add-to-sprint` workflow exists in `lib/bmad-extension/workflows/add-to-sprint/workflow.md`
1533
- **When** invoked via BMAD agent menu or slash command (NFR19)
1534
- **Then** it presents the flat backlog (stories + bugs) for selection (FR65)
1535
- **And** items can be assigned to a sprint
1536
-
1537
- **Given** items are being prioritized for sprint assignment (FR67)
1538
- **When** the workflow guides prioritization
1539
- **Then** multiple criteria are considered (business value, technical dependencies, severity for bugs)
1540
- **And** the agent assists in ranking items within the sprint capacity
1541
-
1542
- **Given** a sprint is at capacity
1543
- **When** an attempt is made to add another item
1544
- **Then** the workflow warns that capacity would be exceeded
1545
- **And** suggests removing an item or increasing capacity
1546
-
1547
- ### Story 12.3: Create Modify Sprint Extension Workflow
1548
-
1549
- As a **Scrum Master**,
1550
- I want an extension workflow to modify existing sprints,
1551
- So that sprint scope can be adjusted when priorities change mid-sprint.
1552
-
1553
- **Acceptance Criteria:**
1554
-
1555
- **Given** the `modify-sprint` workflow exists in `lib/bmad-extension/workflows/modify-sprint/workflow.md`
1556
- **When** invoked via BMAD agent menu or slash command (NFR19)
1557
- **Then** it allows: adding items, removing items, changing capacity, updating sprint metadata
1558
-
1559
- **Given** a sprint modification is requested
1560
- **When** items are added or removed
1561
- **Then** the sprint status reflects the updated item list and remaining capacity (FR71)
1562
-
1563
- ### Story 12.4: Update Sprint Status with Assigned Items
1564
-
1565
- As a **Scrum Master**,
1566
- I want the sprint status workflow to show assigned items per sprint,
1567
- So that sprint progress is visible with all stories and bugs listed.
1568
-
1569
- **Acceptance Criteria:**
1570
-
1571
- **Given** the existing sprint status workflow
1572
- **When** it displays sprint information
1573
- **Then** it shows all assigned items (stories + bugs) with their current status (FR71)
1574
- **And** remaining capacity is visible
1575
- **And** bugs and stories are distinguishable in the listing
1576
-
1577
- ---
1578
-
1579
- ## Epic 13: Project Context Auto-Generation (Phase 2)
1580
-
1581
- **Goal:** Every ma-agents project-level installation produces a platform-agnostic `_bmad-output/project-context.md` that acts as a constitutional document — mandating skill loading, fresh-worktree git workflow, and full mission lifecycle for all agents and BMAD workflows.
1582
- **FRs covered:** FR79, FR80, FR81, FR82, FR83, FR84, FR85, FR86
1583
- **NFRs addressed:** NFR22 (template has no hardcoded paths), NFR23 (additive-only), NFR24 (template as separate file), NFR25 (version comment for upgrade detection)
1584
- **Dependency:** Epic 8 (BMAD extension module with critical_actions infrastructure), Epic 10 (`_bmad-output/` version-controlled policy)
1585
-
1586
- **Execution order:** 13.1 → 13.2 → 13.3 → 13.4 (prerequisite investigation required first) → 13.5
1587
-
1588
- ### Story 13.1: Create Project-Context Template and Generator Function
1589
-
1590
- As a **Chief Architect**,
1591
- I want a standalone project-context template and a `generateProjectContext()` function in the installer,
1592
- So that a constitutional document can be generated with correct platform-specific content at install time.
1593
-
1594
- **Acceptance Criteria:**
1595
-
1596
- **Given** `lib/templates/project-context.template.md` is created (NFR24)
1597
- **When** a developer reads it
1598
- **Then** it contains all mandatory rule sections: pre-task MANIFEST loading, git worktree workflow, and full 8-step mission lifecycle (FR80, FR83)
1599
- **And** it contains a `{{MANIFEST_PATHS_LIST}}` placeholder — no hardcoded platform paths in the template source (NFR22)
1600
- **And** it contains a machine-readable template version comment `<!-- ma-agents-template-version: 1.0 -->` (NFR25)
1601
- **And** it contains inline expansion comments for `bmad-generate-project-context`, `bmad-retrospective`, and manual updates (FR85)
1602
- **And** it contains empty `## Technology Stack` and `## Project-Specific Rules` placeholder sections
1603
-
1604
- **Given** `generateProjectContext(projectRoot, installedAgents)` is implemented in `installer.js`
1605
- **When** called with a project root and ALL agents from the project manifest (not just current-run agents)
1606
- **Then** it reads the template from `lib/templates/project-context.template.md`
1607
- **And** it resolves relative MANIFEST.yaml paths for each agent's `skillsDir` (relative to project root — no absolute paths)
1608
- **And** it replaces `{{MANIFEST_PATHS_LIST}}` with a formatted markdown bullet list of all resolved paths (FR81, FR82)
1609
- **And** it returns the stamped content string — it does NOT write any file (writing is Story 13.2's responsibility)
1610
- **And** when the template file is missing or unreadable it throws a descriptive Error with the cause
1611
-
1612
- **Given** only one platform is installed
1613
- **When** paths are stamped
1614
- **Then** one MANIFEST path appears in the list (FR81)
1615
-
1616
- **Given** multiple platforms are installed
1617
- **When** paths are stamped
1618
- **Then** all platform MANIFEST paths from the manifest appear in the list (FR82)
1619
-
1620
- ### Story 13.2: Integrate Generation into Install Pipeline
1621
-
1622
- As a **DevOps Engineer**,
1623
- I want project-context.md generated automatically at the end of every project-level skill installation,
1624
- So that every ma-agents project has the constitutional document without any manual step.
1625
-
1626
- **Acceptance Criteria:**
1627
-
1628
- **Given** `npx ma-agents install` completes a project-level installation
1629
- **When** skills and/or BMAD have been installed
1630
- **Then** `generateProjectContext()` is called at the end of the install pipeline
1631
- **And** `_bmad-output/project-context.md` exists after installation
1632
-
1633
- **Given** `_bmad-output/project-context.md` does not exist before installation
1634
- **When** the installer runs
1635
- **Then** the file is created with correct platform-stamped content (FR77, FR79)
1636
- **And** a success message is logged: `✓ project-context.md generated at _bmad-output/project-context.md`
1637
-
1638
- **Given** `_bmad-output/project-context.md` already exists before installation (FR82, NFR23)
1639
- **When** the installer runs
1640
- **Then** the existing file is NOT modified or overwritten
1641
- **And** an info message is logged: `ℹ project-context.md already exists — skipping generation`
1642
-
1643
- **Given** the install is a global install (targeting `~/.config/<agent>/`)
1644
- **When** the pipeline runs
1645
- **Then** project-context generation is skipped — no file is created (generation is project-level only)
1646
-
1647
- **Given** the install is non-interactive CI/CD mode (`--yes` flag)
1648
- **When** the pipeline runs
1649
- **Then** project-context generation behaves identically to interactive mode — no interactive prompts required
1650
-
1651
- ### Story 13.3: Update BMAD Extension Critical_Actions to Load Project-Context
1652
-
1653
- As a **Chief Architect**,
1654
- I want all BMAD agent `critical_actions` to load `_bmad-output/project-context.md` at activation,
1655
- So that BMAD workflow agents follow project-context rules in every session, not just IDE agents reading CLAUDE.md.
1656
-
1657
- **Acceptance Criteria:**
1658
-
1659
- **Given** all 11 agent `.customize.yaml` files in `lib/bmad-extension/agents/`
1660
- **When** updated for this story
1661
- **Then** each file's `critical_actions` includes a new step: `"If _bmad-output/project-context.md exists, read it completely"` — placed after the MANIFEST read step and before the skill-loading step (FR84)
1662
-
1663
- **Given** a BMAD agent activates with the updated `critical_actions`
1664
- **When** `_bmad-output/project-context.md` exists in the project
1665
- **Then** the agent reads it as part of initialization and follows all rules therein
1666
- **And** the agent applies the git worktree mandate, mission lifecycle, and skill-loading rules from the file
1667
-
1668
- **Given** a BMAD agent activates with the updated `critical_actions`
1669
- **When** `_bmad-output/project-context.md` does NOT exist (e.g., first install before generation, or global install)
1670
- **Then** the agent skips that step gracefully — the `if exists` phrasing ensures no error
1671
-
1672
- **Given** `bmad.js` deploys the updated extension module
1673
- **When** `npx bmad-method install --action update` is run after deployment
1674
- **Then** the updated `critical_actions` survive the BMAD update (NFR16 — extension module independence)
1675
-
1676
- **Dev Note:** The 4 custom agent customize files (SRE, DevOps, Cyber, MIL-498) have full persona + menu + critical_actions. The 7 built-in agent files (PM, Architect, Dev, QA, SM, Tech Writer, UX Designer, BMad Master) have critical_actions only. All 11 must be updated.
1677
-
1678
- ### Story 13.4: Add Project-Context Expansion Trigger to Retrospective Workflow
1679
-
1680
- As a **Scrum Master**,
1681
- I want the BMAD retrospective workflow to include a project-context update step,
1682
- So that conventions and patterns discovered during a sprint are captured in the living document automatically.
1683
-
1684
- **Acceptance Criteria:**
1685
-
1686
- **Given** the retrospective workflow at `_bmad/bmm/workflows/bmad-retrospective/` (or equivalent extension path)
1687
- **When** a retrospective completes
1688
- **Then** the workflow includes a final step: *"Review `_bmad-output/project-context.md` — identify any new conventions, patterns, or agent failures from this sprint that should be captured. Propose specific additions to the `## Project-Specific Rules` section."*
1689
-
1690
- **Given** the Scrum Master runs `/bmad-retrospective` after a sprint
1691
- **When** the retrospective reaches the expansion step
1692
- **Then** the agent presents the current `## Project-Specific Rules` section of project-context.md
1693
- **And** proposes additions based on patterns observed during the sprint
1694
- **And** waits for human confirmation before writing any changes to the file
1695
-
1696
- **Given** `_bmad-output/project-context.md` does not exist when retrospective runs
1697
- **When** the expansion step executes
1698
- **Then** the step is skipped gracefully with a note: *"No project-context.md found — consider running the install or bmad-generate-project-context first."*
1699
-
1700
- **Dev Note:** This story modifies a BMAD extension workflow. The retrospective workflow may live in `lib/bmad-extension/workflows/` (if it is a custom extension workflow) or in the installed `_bmad/bmm/workflows/` (if it is a built-in BMAD workflow). Investigate the actual location before implementation — if it is a built-in BMAD workflow, create an override or companion extension workflow rather than modifying the core. Never modify bmad-method core files (NFR17). **This story requires prerequisite investigation and should not be started until the workflow location is confirmed.**
1701
-
1702
- ### Story 13.5: Document Project-Context Generation in README and Installation Guidance
1703
-
1704
- As a **DevOps Engineer**,
1705
- I want project-context generation documented in the README and QUICK_START guide,
1706
- So that users understand what the generated file is, why it appeared, and how to expand it over time.
1707
-
1708
- **Acceptance Criteria:**
1709
-
1710
- **Given** the README.md at project root
1711
- **When** updated for this story
1712
- **Then** it includes a "Project Context" section explaining: what `_bmad-output/project-context.md` is, when it is generated (project-level install only), that it is intentionally not overwritten on reinstall, and how to expand it (via `/bmad-generate-project-context` and retrospectives)
1713
-
1714
- **Given** a user runs `npx ma-agents install` and sees `_bmad-output/project-context.md` appear
1715
- **When** they check the README
1716
- **Then** they find an explanation of the file without needing to search elsewhere
1717
-
1718
- **Given** the QUICK_START.md guide
1719
- **When** updated
1720
- **Then** it mentions project-context.md as a post-install artifact with a pointer to the README for details
1721
-
1722
- **Given** the generated project-context.md template (Story 13.1)
1723
- **When** reviewed alongside the README section
1724
- **Then** the expansion instructions in the README match the inline comments in the file — no contradictions between the two
1725
-
1726
- ---
1727
-
1728
- ## Epic 14: External Tooling Integration (Phase 3)
1729
-
1730
- **Goal:** ma-agents can connect to external project management and knowledge management platforms (Jira, Confluence) as alternatives to the default file-system backends. The backend is configured at installation time via `project-context.md` or the root directives file (`CLAUDE.md` / equivalent), so agents and skills resolve data against the configured system without code changes.
1731
- **FRs covered:** Proposed — to be formally added to PRD after Story 14.3 architecture is approved
1732
- **Dependency:** Epic 12 (Sprint Management workflows), Epic 10 (Project Knowledge Preservation), Epic 13 (Project Context Auto-Generation — provides the config schema and installation pipeline)
1733
- **Phase:** 3 — analyst research and architecture design must complete before any implementation story is detailed
1734
- **Analyst + Architect required:** Yes — Stories 14.1, 14.2, and 14.3 are prerequisites for all implementation work
1735
-
1736
- ---
1737
-
1738
- ### Story 14.1: Analyst Research — Jira Sprint Management Integration
1739
-
1740
- As a **Product Manager / Analyst**,
1741
- I want a research report on integrating Jira as a sprint management backend for ma-agents,
1742
- So that the architect has clear requirements before designing the abstraction layer.
1743
-
1744
- **Acceptance Criteria:**
1745
-
1746
- **Given** the current file-system sprint management model (`sprint-status.yaml`, story files)
1747
- **When** the analyst completes the research report
1748
- **Then** it documents: Jira REST API capabilities, authentication models (API token, OAuth, service account), field mapping (Jira status → ma-agents story status), rate limits, and offline/air-gapped scenarios
1749
- **And** it defines the proposed configuration schema to be set in `project-context.md` at installation time
1750
- **And** it identifies the minimum viable Jira integration scope (read story status) vs full bidirectional sync (write back story state)
1751
- **And** it covers both Jira Cloud and Jira Server/Data Center
1752
-
1753
- **Given** the `story-status-lookup` skill (implemented in Epic 11 review cycle) has a reserved Jira extension point
1754
- **When** the report addresses credential handling
1755
- **Then** it proposes how credentials are stored (env vars vs `project-context.md` vs OS keychain)
1756
- **And** it clarifies what must be configured at install time vs at runtime
1757
-
1758
- **Technical notes:**
1759
- - Output artifact: `_bmad-output/planning-artifacts/research-external-tooling-sprint-management.md`
1760
- - This report is the primary input for Story 14.3 (architecture design)
1761
- - Consider: what happens if Jira is unavailable mid-session (network failure, rate limit)?
1762
-
1763
- ---
1764
-
1765
- ### Story 14.2: Analyst Research — Knowledge Management Integration (Confluence)
1766
-
1767
- As a **Product Manager / Analyst**,
1768
- I want a research report on integrating Confluence (and similar tools) as a knowledge management backend for ma-agents,
1769
- So that the architect can design a unified external tooling abstraction that covers both sprint and knowledge management.
1770
-
1771
- **Acceptance Criteria:**
1772
-
1773
- **Given** the current file-system knowledge model (markdown files in `_bmad-output/`)
1774
- **When** the analyst completes the research report
1775
- **Then** it documents: Confluence REST API capabilities, space/page model mapping to ma-agents artifact types (PRD, architecture, epics, retrospectives), read vs write requirements, and versioning model
1776
- **And** it identifies which ma-agents artifacts benefit most from Confluence sync and which should remain file-system-only
1777
- **And** it flags risks: bidirectional sync conflicts, Confluence markup vs markdown conversion, large attachment handling
1778
-
1779
- **Given** agents read from knowledge artifacts during sessions
1780
- **When** the report covers the user experience
1781
- **Then** it proposes how agents know to read from Confluence vs the local file system
1782
- **And** it clarifies whether the integration is read-only, write-only, or bidirectional
1783
-
1784
- **Technical notes:**
1785
- - Output artifact: `_bmad-output/planning-artifacts/research-external-tooling-knowledge-management.md`
1786
- - Input for Story 14.3 (architecture design)
1787
- - Consider other platforms (Notion, Obsidian vaults, SharePoint) — flag capability gaps vs Confluence
1788
-
1789
- ---
1790
-
1791
- ### Story 14.3: Architecture Design — External Tooling Abstraction Layer
1792
-
1793
- As an **Architect**,
1794
- I want to design the abstraction layer that decouples ma-agents sprint and knowledge operations from their backend implementation,
1795
- So that future backends (Jira, Confluence, Linear, Notion) can be added without changing core workflows or skills.
1796
-
1797
- **Acceptance Criteria:**
1798
-
1799
- **Given** the research reports from Stories 14.1 and 14.2
1800
- **When** the architecture design is complete
1801
- **Then** it defines: backend interface contracts, the configuration schema in `project-context.md`, credential handling pattern, and how skills resolve their configured backend at runtime
1802
- **And** it specifies exactly how the `story-status-lookup` skill's Jira extension point (reserved during implementation) is fulfilled — including the configuration key names that `project-context.md` / root directives must contain
1803
- **And** it addresses: offline/air-gapped scenarios, partial configuration (only sprint management configured, or only knowledge management), and graceful degradation to file-system defaults
1804
-
1805
- **Given** the installation pipeline (Epic 13)
1806
- **When** the architecture covers installation-time configuration
1807
- **Then** it defines which configuration questions are asked at install time vs deferred to first use
1808
- **And** it specifies how the installer writes the backend configuration into `project-context.md`
1809
-
1810
- **Technical notes:**
1811
- - Output artifact: ADR in `_bmad-output/planning-artifacts/adr-external-tooling-abstraction.md`
1812
- - Stories 14.4 and 14.5 are fully blocked on this story
1813
- - After this story is approved, add formal FRs to the PRD and create detailed implementation stories for 14.4 and 14.5
1814
-
1815
- ---
1816
-
1817
- ### Story 14.4: Implement Jira Sprint Management Backend
1818
-
1819
- *(Blocked on Stories 14.1 + 14.3 — full story spec to be written after architecture ADR is approved and FRs are added to PRD)*
1820
-
1821
- ---
1822
-
1823
- ### Story 14.5: Implement Confluence Knowledge Management Backend
1824
-
1825
- *(Blocked on Stories 14.2 + 14.3 — full story spec to be written after architecture ADR is approved and FRs are added to PRD)*
1826
-
1827
- ---
1828
-
1829
- ## Epic 15: BMAD 6.2.1 Agent Architecture Migration (Phase 2)
1830
-
1831
- ma-agents upgrades from bmad-method 6.0.4 to 6.2.1, restructures the extension module to follow BMAD 6.2.0 module conventions (agents as skill folders, workflows as skill folders, module.yaml with code field), converts all 34 operational workflows to SKILL.md packages, and provides an installer-driven migration path for existing installations.
1832
-
1833
- ### Story 15.1: Bump bmad-method to 6.2.1 and Update Cache
1834
-
1835
- As a **Chief Architect**,
1836
- I want bmad-method updated from 6.0.4 to 6.2.1 and the cache build script updated to include wds,
1837
- So that the bundled BMAD installation uses the current stable version with all official modules.
1838
-
1839
- **Acceptance Criteria:**
1840
-
1841
- **Given** `package.json` currently pins `"bmad-method": "6.0.4"`
1842
- **When** the version is updated to `"6.2.1"`
1843
- **Then** `npm install` fetches bmad-method v6.2.1 into `node_modules/`
1844
- **And** `require.resolve('bmad-method/tools/bmad-npx-wrapper.js')` resolves correctly
1845
-
1846
- **Given** the cache build script (`npm run build:bmad-cache`) currently clones 4 modules (bmb, cis, tea, gds)
1847
- **When** the script is updated
1848
- **Then** it clones 5 modules: bmb, cis, tea, gds, **wds** (bmad-whiteport-design-studio)
1849
- **And** `lib/bmad-cache/wds/` is populated with the cloned module and pre-installed dependencies
1850
-
1851
- **Given** the bundled installation runs with bmad-method 6.2.1
1852
- **When** `npx ma-agents install` completes
1853
- **Then** the resulting `_bmad/` directory structure is valid for 6.2.1
1854
- **And** all BMAD workflows execute correctly against the 6.2.1 core
1855
-
1856
- **Given** a project previously installed with bmad-method 6.0.4
1857
- **When** the new version runs `npx ma-agents install`
1858
- **Then** `buildBmadArgs()` passes `--action update` (detected from existing `_bmad/`)
1859
- **And** bmad-method 6.2.1 handles the upgrade from 6.0.4
1860
-
1861
- **Technical notes:**
1862
- - Update `package.json`: `"bmad-method": "6.2.1"`
1863
- - Update `build:bmad-cache` script to read the updated `external-official-modules.yaml` from bmad-method 6.2.1 (which includes wds)
1864
- - Verify that bmad-method 6.2.1's CLI accepts the same flags used in `buildBmadArgs()` (Story 5.5)
1865
- - Test that `--custom-content` validation still works with our module.yaml
1866
-
1867
- ### Story 15.2: Restructure Extension Module for 6.2.0 Conventions
1868
-
1869
- As a **Chief Architect**,
1870
- I want the extension module restructured to follow the BMAD 6.2.0 module pattern (verified from CIS module source),
1871
- So that `--custom-content` deployment works correctly and the module integrates natively with BMAD's module system.
1872
-
1873
- **Acceptance Criteria:**
1874
-
1875
- **Given** the current `lib/bmad-extension/module.yaml` contains `extends-module: bmm` but no `code` field
1876
- **When** the module.yaml is updated
1877
- **Then** it contains: `code: ma-skills`, `name`, `description`, and optionally `extends-module: bmm`
1878
- **And** `--custom-content lib/bmad-extension/` passes bmad-method's validation (requires `module.yaml` with `code` field)
1879
-
1880
- **Given** the current module has `agents/*.customize.yaml` and `workflows/*/workflow.md`
1881
- **When** the module is restructured
1882
- **Then** all content moves under a `skills/` directory following the CIS pattern
1883
- **And** the old `agents/` and `workflows/` directories are removed from the module
1884
-
1885
- **Given** the restructured module contains `module-help.csv`
1886
- **When** bmad-method processes the module
1887
- **Then** all 42 skills (4 agents + 38 workflows) are registered in the capability system
1888
-
1889
- **Technical notes:**
1890
- - Create `lib/bmad-extension/skills/` directory
1891
- - Move and convert content in subsequent stories (15.3-15.5)
1892
- - The `module-help.csv` must list all skills with their type and trigger information
1893
- - Verify `--custom-content` deployment with the new structure by running a test installation
1894
-
1895
- ### Story 15.3: Convert 4 Custom Agents to Skill Folders
1896
-
1897
- As a **Chief Architect**,
1898
- I want the 4 custom agents (SRE, DevOps, Cyber, MIL-498) converted from `.customize.yaml` files to BMAD 6.2.0 agent skill folders,
1899
- So that they are delivered as native module agents following the verified CIS pattern.
1900
-
1901
- **Acceptance Criteria:**
1902
-
1903
- **Given** each agent currently exists as a `.customize.yaml` file with persona, menu, and critical_actions
1904
- **When** the agent is converted
1905
- **Then** a skill folder is created at `lib/bmad-extension/skills/bmad-ma-agent-{role}/`
1906
- **And** it contains `SKILL.md` with the full agent definition (persona, menu, activation, critical_actions)
1907
- **And** it contains `bmad-skill-manifest.yaml` with `type: agent`, `name`, `displayName`, `role`, `identity`, `communicationStyle`, `principles`, `module: ma-skills`
1908
-
1909
- **Given** the SRE agent (Alex) has persona fields, 9 menu items referencing SRE playbooks, and skill-loading critical_actions
1910
- **When** converted to `bmad-ma-agent-sre/SKILL.md`
1911
- **Then** the SKILL.md contains the complete persona, all menu items with trigger phrases, activation sequence, and critical_actions
1912
- **And** menu items reference the SRE workflow skills by their new skill names (e.g., `sre-health-check`)
1913
-
1914
- **Given** the same conversion for DevOps (Amit), Cyber (Yael), and MIL-498 (Joseph)
1915
- **When** all 4 agents are converted
1916
- **Then** each has a valid skill folder under `lib/bmad-extension/skills/`
1917
- **And** the `bmad-skill-manifest.yaml` fields match the agent's established persona
1918
-
1919
- **Given** the converted agents are deployed via `--custom-content`
1920
- **When** a user activates any of the 4 agents
1921
- **Then** the agent behaves identically to its pre-conversion behavior — same persona, same menu, same workflows (NFR30)
1922
-
1923
- **Technical notes:**
1924
- - Source material: `lib/bmad-customizations/bmm-{agent}.customize.yaml` (base) + `lib/bmad-extension/agents/bmm-{agent}.customize.yaml` (extended) + `_bmad/custom/agents/{agent}.md` (XML definition)
1925
- - Consolidate all three sources into a single SKILL.md per agent
1926
- - Critical_actions in SKILL.md should use the BMAD 6.2.0 format observed in the customize docs
1927
- - After conversion, the old `.customize.yaml` files for custom agents are no longer needed (removed in Story 15.6)
1928
-
1929
- ### Story 15.4: Convert 11 MIL-498 Workflows to SKILL.md Packages
1930
-
1931
- As a **MIL-STD-498 expert**,
1932
- I want all 11 DID workflows converted from legacy YAML format to BMAD 6.2.0 SKILL.md packages,
1933
- So that they function without the removed legacy workflow engine.
1934
-
1935
- **Acceptance Criteria:**
1936
-
1937
- **Given** each MIL-498 workflow currently exists as `workflow.yaml` + `instructions.md` in `lib/bmad-workflows/mil498/`
1938
- **When** converted to a SKILL.md package
1939
- **Then** a skill folder is created at `lib/bmad-extension/skills/mil498-{did}/` (e.g., `mil498-srs/`)
1940
- **And** it contains `SKILL.md` (workflow entrypoint with routing logic), `bmad-skill-manifest.yaml` (type: skill), `template.md` (DID output template), and `prompts/` (step files for progressive disclosure)
1941
-
1942
- **Given** a MIL-498 workflow has sequential steps that must execute in strict order (compliance-critical)
1943
- **When** the workflow is converted
1944
- **Then** each step becomes a separate file in `prompts/` (Layer 4 progressive disclosure)
1945
- **And** the step files preserve the exact same sequence and content as the original instructions.md
1946
- **And** template output checkpoints (previously `<template-output>` XML tags) become explicit user confirmation gates in step files
1947
-
1948
- **Given** all 11 DID workflows (SSS, SSDD, OCD, SDP, SRS, SDD, STD, STR, IDD, IRS, HRS) are converted
1949
- **When** a user invokes any DID workflow
1950
- **Then** it produces the same document output as before conversion (NFR32)
1951
- **And** the same pause-and-confirm behavior for document section approval is preserved
1952
-
1953
- **Technical notes:**
1954
- - 11 workflows: mil498-sss, mil498-ssdd, mil498-ocd, mil498-sdp, mil498-srs, mil498-sdd, mil498-std, mil498-str, mil498-idd, mil498-irs, mil498-hrs
1955
- - These are Complex Workflow skill type — the most structured form in BMAD 6.2.0
1956
- - The step file naming should follow a consistent pattern: `01-discovery.md`, `02-requirements.md`, etc.
1957
- - Templates must be carried over verbatim — no content changes during conversion
1958
-
1959
- ### Story 15.5: Convert 23 SRE/DevOps/Cyber Workflows to SKILL.md Packages
1960
-
1961
- As a **Chief Architect**,
1962
- I want all SRE, DevOps, and Cyber operational playbooks converted to SKILL.md skill packages,
1963
- So that they integrate with the BMAD 6.2.0 skill system consistently.
1964
-
1965
- **Acceptance Criteria:**
1966
-
1967
- **Given** SRE playbooks currently exist as standalone `.md` files in `lib/bmad-workflows/sre/` (9 workflows)
1968
- **When** each is converted to a SKILL.md package
1969
- **Then** a skill folder is created at `lib/bmad-extension/skills/sre-{workflow}/`
1970
- **And** it contains `SKILL.md` (wrapping the existing workflow content with proper frontmatter) and `bmad-skill-manifest.yaml` (type: skill)
1971
-
1972
- **Given** DevOps playbooks in `lib/bmad-workflows/devops/` (6 workflows) and Cyber playbooks in `lib/bmad-workflows/cyber/` (8 workflows)
1973
- **When** converted following the same pattern
1974
- **Then** each gets its own skill folder under `lib/bmad-extension/skills/`
1975
-
1976
- **Given** a multi-step workflow (e.g., `sre-health-check` with discovery → diagnosis → remediation)
1977
- **When** it is complex enough to benefit from progressive disclosure
1978
- **Then** it uses `prompts/` for step files (Complex Workflow type)
1979
- **Otherwise** single-pass playbooks remain as simple `SKILL.md` files (Simple Workflow type)
1980
-
1981
- **Given** all 23 workflows are converted
1982
- **When** the agent menu references them
1983
- **Then** agents can invoke them by the new skill name
1984
- **And** the workflow behavior is identical to pre-conversion (NFR32)
1985
-
1986
- **Technical notes:**
1987
- - 9 SRE: health-check, fix-deployments, performance-opt, check-deployment-status, check-secrets, day-2-ops, deployment-strategies, gitops-status, + 1 more
1988
- - 6 DevOps: configure-infrastructure, optimize-pipelines, manage-helm, disconnected-deployment, docker-compose-setup, sign-docker-image
1989
- - 8 Cyber: vulnerability-scan, security-audit, threat-modeling, generate-certs, immunity-estimation, vault-secrets, verify-docker-users, verify-image-signature
1990
- - Conversion is lighter than MIL-498 — existing .md content wraps into SKILL.md with frontmatter
1991
- - Also convert the 4 extension workflows (create-bug-story, add-sprint, modify-sprint, add-to-sprint) to skill format
1992
-
1993
- ### Story 15.6: Separate Built-in Agent Customizations
1994
-
1995
- As a **Chief Architect**,
1996
- I want the `.customize.yaml` files for 8 built-in BMM agents moved from `lib/bmad-extension/agents/` to `lib/bmad-customize/`,
1997
- So that module-owned agents (in skill folders) are cleanly separated from customizations of other modules' agents.
1998
-
1999
- **Acceptance Criteria:**
2000
-
2001
- **Given** the 8 built-in agent `.customize.yaml` files (bmm-pm, bmm-architect, bmm-dev, bmm-qa, bmm-sm, bmm-tech-writer, bmm-ux-designer, core-bmad-master)
2002
- **When** moved to `lib/bmad-customize/`
2003
- **Then** each file contains only `critical_actions` (skill loading + project-context loading)
2004
- **And** no persona, menu, or other overrides are present
2005
-
2006
- **Given** the `.customize.yaml` files use BMAD 6.2.0 syntax
2007
- **When** the critical_actions are written
2008
- **Then** they use array syntax (list of strings) per current BMAD documentation:
2009
- ```yaml
2010
- critical_actions:
2011
- - "Read the skills MANIFEST at {project-root}/skills/MANIFEST.yaml"
2012
- - "For each skill marked always_load: true, read the skill file completely"
2013
- - "If _bmad-output/project-context.md exists, read it completely"
2014
- - "Follow all skill directives and project-context rules during this session"
2015
- ```
2016
-
2017
- **Given** `bmad.js` deploys these files
2018
- **When** installation runs
2019
- **Then** files are copied from `lib/bmad-customize/` to `_bmad/_config/agents/` AFTER `--custom-content` deploys the extension module
2020
-
2021
- **Given** the old `lib/bmad-extension/agents/` directory contained both custom and built-in agent files
2022
- **When** the separation is complete
2023
- **Then** `lib/bmad-extension/agents/` no longer exists (custom agents are now in `skills/`, built-ins are in `lib/bmad-customize/`)
2024
-
2025
- **Technical notes:**
2026
- - `bmad.js` needs two deployment steps: (1) `--custom-content lib/bmad-extension/` for the module, (2) file copy from `lib/bmad-customize/*.customize.yaml` to `_bmad/_config/agents/`
2027
- - The old `lib/bmad-customizations/` directory (base configs) is also eliminated — its content was merged into agent skill folders in Story 15.3
2028
-
2029
- ### Story 15.7: Migration Detection and Upgrade Path
2030
-
2031
- As a **DevOps engineer**,
2032
- I want the installer to automatically detect and upgrade from 6.0.4 to 6.2.1 during normal installation,
2033
- So that I don't need a separate upgrade command and my existing customizations are preserved.
2034
-
2035
- **Acceptance Criteria:**
2036
-
2037
- **Given** an existing project with bmad-method 6.0.4 installed (detected from `_bmad/core/config.yaml` version field)
2038
- **When** `npx ma-agents install` runs with the new version
2039
- **Then** the installer detects the old version and logs: `"Upgrading BMAD from 6.0.4 to 6.2.1..."`
2040
- **And** passes `--action update` to bmad-method
2041
-
2042
- **Given** the user had customized agent personas (e.g., changed SRE agent's name from Alex to Sasha)
2043
- **When** the migration runs
2044
- **Then** the installer backs up existing `_bmad/_config/agents/*.customize.yaml` before updating
2045
- **And** after the module deploys, it checks backed-up files for user-added `memories`, extra `critical_actions`, or persona overrides
2046
- **And** carries forward user customizations that don't conflict with the new structure
2047
-
2048
- **Given** legacy artifacts exist (old `.customize.yaml` for custom agents in `_bmad/_config/agents/`, XML agent definitions in `_bmad/custom/agents/`, YAML workflow files)
2049
- **When** migration completes successfully
2050
- **Then** legacy artifacts are removed
2051
- **And** a migration log is printed listing what was cleaned up
2052
-
2053
- **Given** the bmad-method update fails (e.g., file permission error, corrupted state)
2054
- **When** the error is caught
2055
- **Then** the installer restores backed-up `.customize.yaml` files
2056
- **And** logs the error with a recovery suggestion
2057
- **And** the project remains functional on the old version (NFR29)
2058
-
2059
- **Given** a fresh project with no existing BMAD installation
2060
- **When** `npx ma-agents install` runs
2061
- **Then** it deploys directly in 6.2.1 format with skill-based agents and workflows
2062
- **And** no migration logic executes (FR110)
2063
-
2064
- **Technical notes:**
2065
- - `detectMigrationNeed()` function reads `_bmad/core/config.yaml` for version
2066
- - Backup directory: `_bmad/_config/agents/.backup-pre-migration/`
2067
- - Customization merge is best-effort — if a user customized something that no longer exists in the new format, log a warning
2068
- - The migration sequence: back up → invoke bmad-method update → deploy new extension module → deploy built-in customizes → merge user customizations → clean up legacy
2069
-
2070
- ### Story 15.8: Validate Migrated Agents and Workflows
2071
-
2072
- As a **Chief Architect**,
2073
- I want to verify that all migrated agents and workflows function identically to their pre-migration behavior,
2074
- So that functional equivalence (NFR30) and output equivalence (NFR32) are confirmed.
2075
-
2076
- **Acceptance Criteria:**
2077
-
2078
- **Given** all 4 custom agents have been converted to skill folders
2079
- **When** each agent is activated
2080
- **Then** the agent displays the same persona, same greeting, and same menu items as before
2081
- **And** every menu item routes to the correct workflow
2082
-
2083
- **Given** all 11 MIL-498 workflows have been converted
2084
- **When** each DID workflow is invoked
2085
- **Then** it produces the same document structure with the same template sections
2086
- **And** the progressive disclosure step files execute in the same order
2087
-
2088
- **Given** all 23 SRE/DevOps/Cyber workflows have been converted
2089
- **When** each playbook is invoked
2090
- **Then** it produces the same output as the pre-conversion `.md` version
2091
-
2092
- **Given** the migrated extension module is deployed
2093
- **When** BMAD Builder lint gate scripts are run against the skill folders
2094
- **Then** `scan-path-standards.py` passes without critical violations
2095
- **And** `scan-scripts.py` passes without critical violations (NFR31)
2096
-
2097
- **Technical notes:**
2098
- - This is a validation/testing story
2099
- - Create a checklist document: each agent menu item → expected behavior → actual behavior
2100
- - Compare MIL-498 DID output before/after conversion using diff
2101
- - Run BMAD Builder QO (Quality Optimize) if available against the module
2102
-
2103
- ---
2104
-
2105
- ## Epic 16: Multi-Repository Project Layout (Phase 2)
2106
-
2107
- Enterprise projects that separate planning knowledge, sprint management, and code across repositories are fully supported. The installer discovers repo locations, stores paths in config, and stamps them into project-context.md so agents resolve artifacts to the correct repository.
2108
-
2109
- ### Story 16.1: Repository Layout Wizard
2110
-
2111
- As a **Chief Architect**,
2112
- I want the installer to ask where the knowledgebase and sprint management are managed during installation,
2113
- So that the project layout is configured correctly for multi-repo environments.
2114
-
2115
- **Acceptance Criteria:**
2116
-
2117
- **Given** the user runs `npx ma-agents install`
2118
- **When** the wizard reaches the repository layout section
2119
- **Then** it asks: "Where is your knowledgebase managed?" with options: Current repository (default), Local path, Remote git repository
2120
- **And** it asks: "Where is your sprint management managed?" with the same options
2121
-
2122
- **Given** the user selects "Remote git repository" for knowledgebase
2123
- **When** prompted for details
2124
- **Then** the wizard asks for the git URL
2125
- **And** asks for the local destination path for cloning
2126
- **And** if the destination already exists, displays its contents summary and asks the user to confirm (FR113)
2127
- **And** if the destination does not exist, clones the repository to that path (FR114)
2128
-
2129
- **Given** the user selects "Local path" for sprint management
2130
- **When** prompted for the path
2131
- **Then** the wizard validates the path exists
2132
- **And** if it does not exist, alerts the user and asks to confirm or correct (FR115)
2133
-
2134
- **Given** the user selects "Current repository" for both concerns
2135
- **When** the wizard completes
2136
- **Then** no additional configuration is needed — single-repo mode preserved (FR116)
2137
-
2138
- **Given** the user runs with `--yes` flag (CI/CD mode)
2139
- **When** the wizard reaches the repository layout section
2140
- **Then** both concerns default to "Current repository" without prompting
2141
-
2142
- **Technical notes:**
2143
- - New section in `cli.js` wizard, after agent selection
2144
- - Use existing inquirer prompts pattern
2145
- - `git clone` command must quote the URL and destination path for space-safety
2146
-
2147
- ### Story 16.2: Config Storage and Cross-Reference File
2148
-
2149
- As a **DevOps engineer**,
2150
- I want the configured repo paths stored persistently and a cross-reference file created in the code repo,
2151
- So that agents and BMAD workflows can discover the correct paths without re-running installation.
2152
-
2153
- **Acceptance Criteria:**
2154
-
2155
- **Given** the user configured knowledgebase at `d:/Code/kb-repo` and sprint management at `d:/Code/sprint-repo`
2156
- **When** the installation completes
2157
- **Then** `_bmad/core/config.yaml` contains:
2158
- ```yaml
2159
- knowledgebase_path: "d:/Code/kb-repo"
2160
- sprint_management_path: "d:/Code/sprint-repo"
2161
- ```
2162
-
2163
- **Given** multi-repo mode is configured
2164
- **When** the installation completes
2165
- **Then** `_bmad-output/project-layout.yaml` is created in the CODE repository containing:
2166
- ```yaml
2167
- generated: '2026-03-26'
2168
- knowledgebase:
2169
- mode: remote
2170
- path: "d:/Code/kb-repo"
2171
- gitUrl: "https://..."
2172
- sprint_management:
2173
- mode: local
2174
- path: "d:/Code/sprint-repo"
2175
- ```
2176
-
2177
- **Given** single-repo mode is configured (both set to "current repository")
2178
- **When** the installation completes
2179
- **Then** config.yaml contains `knowledgebase_path: "."` and `sprint_management_path: "."`
2180
- **And** no `project-layout.yaml` is created (NFR34)
2181
-
2182
- **Given** the installation runs multiple times with the same multi-repo configuration
2183
- **When** `project-layout.yaml` is regenerated
2184
- **Then** the output is identical except for the `generated` date field (NFR36)
2185
-
2186
- **Technical notes:**
2187
- - Write config values after bmad-method installation completes
2188
- - `project-layout.yaml` is generated by ma-agents installer, not by bmad-method
2189
- - The file is created in `_bmad-output/` which is version-controlled (per F3)
2190
-
2191
- ### Story 16.3: Project-Context Multi-Repo Section
2192
-
2193
- As an **AI agent**,
2194
- I want project-context.md to include the configured repository paths,
2195
- So that I know where to read and write planning and sprint artifacts.
2196
-
2197
- **Acceptance Criteria:**
2198
-
2199
- **Given** multi-repo is configured with knowledgebase at `/path/to/kb` and sprint at `/path/to/sprint`
2200
- **When** project-context.md is generated (or regenerated)
2201
- **Then** it includes a "Repository Layout" section:
2202
- ```markdown
2203
- ### Repository Layout
2204
- - **Knowledgebase:** /path/to/kb
2205
- - **Sprint Management:** /path/to/sprint
2206
- - When creating or reading planning artifacts, use the knowledgebase path
2207
- - When creating or reading sprint/story artifacts, use the sprint management path
2208
- ```
2209
-
2210
- **Given** single-repo mode is configured
2211
- **When** project-context.md is generated
2212
- **Then** the "Repository Layout" section is omitted entirely (NFR34 backward compatibility)
2213
-
2214
- **Given** project-context.md already exists when the installer runs
2215
- **When** multi-repo is configured for the first time
2216
- **Then** project-context.md is NOT modified (idempotency per FR84)
2217
- **And** the installer logs: "project-context.md exists — add Repository Layout section manually or run /bmad-generate-project-context"
2218
-
2219
- **Technical notes:**
2220
- - Update `lib/templates/project-context.template.md` to include conditional multi-repo section
2221
- - Add `{{REPO_LAYOUT_SECTION}}` placeholder that resolves to the section or empty string
2222
- - The generator function needs the repo layout config as input alongside installedAgents
2223
-
2224
- ### Story 16.4: Validate Cross-Repo Path Resolution
2225
-
2226
- As a **Chief Architect**,
2227
- I want to verify that BMAD workflows correctly resolve artifact paths from the configured repo layout,
2228
- So that planning and sprint artifacts are read from and written to the correct repositories.
2229
-
2230
- **Acceptance Criteria:**
2231
-
2232
- **Given** a multi-repo configuration where knowledgebase is at a different path than the code repo
2233
- **When** a BMAD planning workflow (e.g., `/bmad-bmm-create-prd`) runs
2234
- **Then** it reads existing planning artifacts from `{knowledgebase_path}/_bmad-output/planning-artifacts/`
2235
- **And** writes output to the same path
2236
-
2237
- **Given** a multi-repo configuration where sprint management is at a different path
2238
- **When** a BMAD sprint workflow (e.g., `/bmad-bmm-sprint-planning`) runs
2239
- **Then** it reads/writes sprint artifacts from `{sprint_management_path}/_bmad-output/sprints/`
2240
-
2241
- **Given** single-repo configuration
2242
- **When** any BMAD workflow runs
2243
- **Then** artifacts are read from and written to the current project's `_bmad-output/` as before (NFR34)
2244
-
2245
- **Given** an agent is working in the code repository with multi-repo configured
2246
- **When** the agent needs planning context (e.g., reading the PRD during story implementation)
2247
- **Then** it discovers the knowledgebase path from `_bmad-output/project-layout.yaml` or `_bmad/core/config.yaml`
2248
- **And** reads the PRD from the knowledgebase repository
2249
-
2250
- **Technical notes:**
2251
- - This is a validation/testing story
2252
- - Verify that BMAD workflows use config values for path resolution, not hardcoded `_bmad-output/`
2253
- - If BMAD workflows don't natively support configurable output paths, this story identifies the gap and documents what workflow changes are needed
2254
- - Test both directions: writing artifacts to external repo AND reading artifacts from external repo
2255
-
2256
- ### Story 16.5: Fix Config Lost on Update (Bug)
2257
-
2258
- As a **user with a multi-repo layout configured**,
2259
- I want my repo layout configuration to be preserved when I update ma-agents,
2260
- So that I don't silently lose my multi-repo paths every time I add a skill or update agents.
2261
-
2262
- **Acceptance Criteria:**
2263
-
2264
- **Given** an existing installation with multi-repo layout configured in `project-layout.yaml`
2265
- **When** the user runs `ma-agents` again and selects "Update"
2266
- **Then** the repo layout prompts are pre-populated with the existing configuration
2267
-
2268
- **Given** an update with `--yes` flag and no env vars
2269
- **When** `project-layout.yaml` exists with multi-repo paths
2270
- **Then** the existing layout is preserved instead of defaulting to single-repo
2271
-
2272
- **Given** an update with `--yes` flag and env vars set
2273
- **When** `project-layout.yaml` also exists
2274
- **Then** the env vars take precedence over the file (explicit override wins)
2275
-
2276
- **Technical notes:**
2277
- - BUG: `collectRepoLayout()` runs unconditionally on every install/update — no `isUpdate` guard
2278
- - Implement `readExistingLayout()` to parse `project-layout.yaml` and pre-populate prompts
2279
- - In `--yes` mode without env vars, preserve existing config from file
2280
- - Origin: Adversarial Review Finding #1
2281
-
2282
- ### Story 16.6: Repository Sync Check Skill
2283
-
2284
- As a **developer using multi-repo layout**,
2285
- I want a skill that checks whether external repos are in sync and properly scaffolded,
2286
- So that I catch stale clones and missing directory structures before agents fail at runtime.
2287
-
2288
- **Acceptance Criteria:**
2289
-
2290
- **Given** a multi-repo layout is configured
2291
- **When** the user or agent runs the repo-sync-check skill
2292
- **Then** it reads config.yaml, checks each external path exists, verifies expected directory structure, and checks git sync status
2293
-
2294
- **Given** an external path missing `_bmad-output/planning-artifacts/`
2295
- **When** the skill runs
2296
- **Then** it reports the missing structure and offers to scaffold it
2297
-
2298
- **Given** an external git repo where local is behind remote
2299
- **When** the skill runs
2300
- **Then** it reports how many commits behind and advises `git pull`
2301
-
2302
- **Given** a single-repo layout
2303
- **When** the skill runs
2304
- **Then** it reports "no external repos to check" and exits cleanly
2305
-
2306
- **Technical notes:**
2307
- - Covers both scaffolding gap (external repo never initialized) and sync gap (no pull after clone)
2308
- - Read-only git operations: `git fetch`, `git rev-list --count`, `git status --porcelain`
2309
- - Implemented as a skill (not workflow) — short, self-contained check
2310
- - Origin: Adversarial Review Findings #3 and #4
2311
-
2312
- ### Story 16.7: Portable Path Storage
2313
-
2314
- As a **team member cloning a project with multi-repo layout**,
2315
- I want stored paths to be relative rather than absolute,
2316
- So that `project-layout.yaml` and `config.yaml` work across different machines.
2317
-
2318
- **Acceptance Criteria:**
2319
-
2320
- **Given** a local multi-repo path that is relative to the project root
2321
- **When** the config is written
2322
- **Then** the path is stored as relative (e.g., `../kb-repo` instead of `d:/Code/kb-repo`)
2323
-
2324
- **Given** a path that cannot be expressed as a relative path (cross-drive on Windows)
2325
- **When** the config is written
2326
- **Then** the absolute path is stored with a portability warning comment
2327
-
2328
- **Given** stored relative paths
2329
- **When** `readExistingLayout()` reads them back
2330
- **Then** it resolves to absolute paths using `path.resolve(projectRoot, storedPath)`
2331
-
2332
- **Technical notes:**
2333
- - Add `toPortablePath(absolutePath, projectRoot)` utility using `path.relative()`
2334
- - Update `writeProjectLayoutYaml()` and `writeRepoLayoutConfig()` to use portable paths
2335
- - Backward compatible: existing absolute paths still work when read back
2336
- - Origin: Adversarial Review Finding #7
2337
-
2338
- ### Story 16.8: CI/CD Remote Repository Mode
2339
-
2340
- As a **CI/CD pipeline operator**,
2341
- I want to configure remote git repositories headlessly via env vars,
2342
- So that automated pipelines can set up multi-repo remote layouts without prompts.
2343
-
2344
- **Acceptance Criteria:**
2345
-
2346
- **Given** `--yes` flag and `MA_KNOWLEDGEBASE_GIT_URL` env var set
2347
- **When** `collectRepoLayout()` runs
2348
- **Then** it clones the repo to `MA_KNOWLEDGEBASE_PATH` and returns `mode: 'remote'`
2349
-
2350
- **Given** git URL env var set but corresponding path env var missing
2351
- **When** `collectRepoLayout()` runs
2352
- **Then** it exits with error: "MA_KNOWLEDGEBASE_GIT_URL requires MA_KNOWLEDGEBASE_PATH"
2353
-
2354
- **Given** clone destination already exists with `.git` directory
2355
- **When** clone is attempted
2356
- **Then** it skips cloning (idempotent for CI re-runs)
2357
-
2358
- **Given** clone failure in CI mode
2359
- **When** the error occurs
2360
- **Then** it exits non-zero with clear error (no silent fallback to same mode)
2361
-
2362
- **Technical notes:**
2363
- - New env vars: `MA_KNOWLEDGEBASE_GIT_URL`, `MA_SPRINT_GIT_URL`
2364
- - CI mode must fail loudly — no fallback to `same` on error
2365
- - Idempotent: existing valid clone at destination is reused
2366
- - Origin: Adversarial Review Finding #8
2367
-
2368
- ### Story 16.9: Reconfigure Layout Workflow
2369
-
2370
- As a **user who needs to change repo layout after installation**,
2371
- I want a dedicated command and workflow to reconfigure repo layout,
2372
- So that I can change paths without re-running the full installer.
2373
-
2374
- **Acceptance Criteria:**
2375
-
2376
- **Given** the user runs `ma-agents config layout`
2377
- **When** the command starts
2378
- **Then** it displays current layout and presents the layout wizard pre-populated with current values
2379
-
2380
- **Given** the user runs `ma-agents config layout --show`
2381
- **Then** it displays current configuration in read-only mode (no prompts)
2382
-
2383
- **Given** reconfiguration completes
2384
- **When** new paths are confirmed
2385
- **Then** `config.yaml`, `project-layout.yaml`, and `project-context.md` are all updated
2386
-
2387
- **Given** reconfiguration from multi-repo to single-repo
2388
- **When** update completes
2389
- **Then** `project-layout.yaml` is deleted and config reverts to single-repo defaults
2390
-
2391
- **Technical notes:**
2392
- - Reuses all existing functions: `readExistingLayout()`, `collectRepoLayout()`, `writeRepoLayoutConfig()`, `writeProjectLayoutYaml()`, `updateProjectContextRepoLayout()`
2393
- - Also create a BMAD skill so agents can guide users to the command
2394
- - Depends on Stories 16.5, 16.7, 16.8
2395
- - Origin: Adversarial Review Finding #10
2396
-
2397
- ---
2398
-
2399
- ## Epic 17: Sprint Management Model Rework (Phase 2)
2400
-
2401
- Sprint management is redesigned around a **single unified `sprint-status.yaml`** file that replaces the previous three-file model (`backlog.yaml`, `sprints/sprint-N.yaml`, `sprint-status.yaml`). The unified file has three sections: `epics` (reference data from epics.md), `backlog` (unassigned items in priority order), and `sprints` (sprint definitions with their assigned items inline). Stories and bugs MOVE between the `backlog` and `sprints` sections — an item exists in exactly one location at any time. Each item carries its own `status` field, updated in-place. Done items are removed from the file and archived to `done/`. A new close-sprint skill handles sprint lifecycle closure. When `tracking_system` is `jira`, the same data model reads/writes from Jira API via an adapter pattern. All 12 sprint-related skills are reworked to operate against this single file. Epic 12 delivered workflow shells — this epic rebuilds the underlying model and rewires everything.
2402
-
2403
- **Execution order:** 17.9 (schema) → 17.15 (bootstrap) → 17.10 (generate-backlog) → 17.16 (add-sprint) → 17.11 (add-to-sprint) → 17.12 (remove-from-sprint) → 17.13 (sprint-status-view) → 17.14 (cleanup-done) → 17.17 (modify-sprint) → 17.18 (bmad-dev-story) → 17.19 (story-status-lookup) → 17.20 (bmad-sprint-status) → 17.24 (prioritize-backlog rework) → 17.21 (close-sprint) → 17.22 (Jira adapter) → 17.23 (migration)
2404
-
2405
- ### Story 17.9: Unified sprint-status.yaml Schema
2406
-
2407
- As a **Scrum Master**,
2408
- I want all sprint management data consolidated into a single `sprint-status.yaml` file with three structured sections,
2409
- So that there is one source of truth for epics, backlog, and sprints — eliminating data duplication across multiple files.
2410
-
2411
- **Acceptance Criteria:**
2412
-
2413
- **Given** the unified schema is defined
2414
- **When** `sprint-status.yaml` is created or updated
2415
- **Then** it contains exactly three top-level sections:
2416
- ```yaml
2417
- epics:
2418
- epic-5:
2419
- status: in-progress
2420
- retrospective: null
2421
- epic-17:
2422
- status: planning
2423
- retrospective: null
2424
-
2425
- backlog:
2426
- - id: "15-2-restructure-extension-module"
2427
- type: story
2428
- epic: 15
2429
- title: "Restructure Extension Module"
2430
- priority: 1
2431
- status: ready-for-dev
2432
- - id: "BUG-path-spaces"
2433
- type: bug
2434
- epic: null
2435
- title: "Fix space-in-path bug"
2436
- priority: 2
2437
- status: backlog
2438
- severity: high
2439
-
2440
- sprints:
2441
- - id: sprint-3
2442
- name: "Sprint 3"
2443
- status: active # planning | active | closed
2444
- capacity: 6 # max items (stories + bugs)
2445
- start: "2026-04-01"
2446
- end: "2026-04-14"
2447
- items:
2448
- - id: "5-5-explicit-parameter-passing"
2449
- type: story
2450
- epic: 5
2451
- title: "Explicit Parameter Passing"
2452
- status: in-progress
2453
- - id: "5-6-fix-space-in-path-bug"
2454
- type: story
2455
- epic: 5
2456
- title: "Fix Space-in-Path Bug"
2457
- status: review
2458
- ```
2459
-
2460
- **Given** an item is in the `backlog` section
2461
- **When** it is assigned to a sprint
2462
- **Then** it is REMOVED from `backlog` and ADDED to the target sprint's `items` array (FR134 — movement semantics)
2463
- **And** the item exists in exactly one location at any time
2464
-
2465
- **Given** an item's status changes (e.g., `ready-for-dev` to `in-progress`)
2466
- **When** the status is updated
2467
- **Then** the `status` field is updated in-place on the item, wherever it currently resides (FR135)
2468
-
2469
- **Given** an item reaches `done` status
2470
- **When** cleanup runs
2471
- **Then** the item is REMOVED from `sprint-status.yaml` entirely (FR136)
2472
- **And** archived to the `done/` folder
2473
-
2474
- **Given** a sprint transitions from `planning` to `active`
2475
- **When** the sprint is activated
2476
- **Then** only one sprint can have `status: active` at a time
2477
- **And** the previous active sprint must be closed first
2478
-
2479
- **Technical notes:**
2480
- - File location: `{sprint_management_path}/sprint-status.yaml` (resolves via config, defaults to `_bmad-output/implementation-artifacts/sprint-status.yaml`)
2481
- - The `epics` section is a MAP keyed by epic ID (e.g., `epic-5:`), with `status` and optional `retrospective` — derived data like title, story_count, done_count are computed from `backlog`/`sprints` sections at display time
2482
- - The `epics` section is reference data — regenerated from `epics.md` by the sprint-planning skill
2483
- - The `backlog` section contains ONLY items not assigned to any sprint
2484
- - The `sprints` section contains sprint definitions with their assigned items inline (no separate sprint files)
2485
- - Item schema: `id`, `type` (story|bug), `epic` (number|null), `title`, `status`, `priority` (in backlog only), plus optional `severity` for bugs
2486
- - Sprint schema: `id`, `name`, `status`, `capacity`, `start`, `end`, `items` array
2487
- - This replaces the old 3-file model: `backlog.yaml` (removed), `sprints/sprint-N.yaml` (removed), `sprint-status.yaml` (repurposed with new schema)
2488
-
2489
- ### Story 17.10: Rework generate-backlog Skill (Heavy Rework)
2490
-
2491
- As a **Scrum Master**,
2492
- I want the `generate-backlog` skill to populate the `backlog` section of the unified `sprint-status.yaml`,
2493
- So that all unassigned stories and bugs are maintained in a single file rather than a separate `backlog.yaml`.
2494
-
2495
- **Acceptance Criteria:**
2496
-
2497
- **Given** the `generate-backlog` skill is invoked
2498
- **When** it parses the epics document
2499
- **Then** it writes all unassigned stories and bugs to the `backlog` section of `sprint-status.yaml` in priority order
2500
- **And** it updates the `epics` section with current epic metadata (title, status, story counts)
2501
- **And** it does NOT touch the `sprints` section — sprint-assigned items are preserved
2502
-
2503
- **Given** items already exist in the `sprints` section of `sprint-status.yaml`
2504
- **When** the backlog is regenerated
2505
- **Then** items currently assigned to sprints are NOT duplicated in the `backlog` section
2506
- **And** new stories from `epics.md` that don't exist anywhere in `sprint-status.yaml` are added to `backlog`
2507
-
2508
- **Given** a story exists in `backlog` but has been removed from `epics.md`
2509
- **When** the backlog is regenerated
2510
- **Then** the orphaned item is flagged with a warning but NOT automatically removed (human review required)
2511
-
2512
- **Given** bugs exist as standalone story files (FR64)
2513
- **When** the backlog is regenerated
2514
- **Then** bugs are included in the `backlog` section with `type: bug` and `epic: null`
2515
- **And** bug-specific fields (`severity`, `version_found`, `bug_type`) are preserved
2516
-
2517
- **Technical notes:**
2518
- - Reworks the existing `generate-backlog` skill to write to `sprint-status.yaml` `backlog` section instead of standalone `backlog.yaml`
2519
- - Must merge with existing `sprint-status.yaml` content (preserve `sprints` section)
2520
- - Priority ordering: bugs with `severity: critical` float to top, then by explicit `priority` field, then by epic order
2521
- - Items with status `done` are excluded (they live in `done/` archive)
2522
- - The old `backlog.yaml` file is no longer written (see Story 17.23 for migration)
2523
-
2524
- ### Story 17.11: Rework add-to-sprint Skill (Heavy Rework — Movement Semantics)
2525
-
2526
- As a **Scrum Master**,
2527
- I want the `add-to-sprint` skill to MOVE items from the `backlog` section to a sprint's `items` array within the same file,
2528
- So that sprint assignment is a single-file atomic operation with movement semantics.
2529
-
2530
- **Acceptance Criteria:**
2531
-
2532
- **Given** the `backlog` section contains unassigned items
2533
- **When** the Scrum Master invokes `add-to-sprint`
2534
- **Then** it displays the target sprint (active or planning) and its current capacity usage (items.length / capacity)
2535
- **And** shows the top N unassigned items from the `backlog` section in priority order
2536
- **And** the Scrum Master selects which items to add
2537
-
2538
- **Given** the Scrum Master selects items for the sprint
2539
- **When** the items are assigned
2540
- **Then** each selected item is REMOVED from the `backlog` array (FR134)
2541
- **And** ADDED to the target sprint's `items` array in the `sprints` section
2542
- **And** the item's `priority` field is dropped (priority only applies in backlog)
2543
- **And** the item's other fields (`id`, `type`, `epic`, `title`, `status`) are preserved
2544
-
2545
- **Given** assigning items would exceed sprint capacity
2546
- **When** the assignment is attempted
2547
- **Then** the skill warns that capacity would be exceeded
2548
- **And** suggests removing items or increasing capacity before proceeding
2549
-
2550
- **Given** the skill is invoked via menu or slash command
2551
- **When** it executes
2552
- **Then** it works identically in both invocation modes (NFR19)
2553
-
2554
- **Technical notes:**
2555
- - Reworks the existing `add-to-sprint` skill (Story 12.2)
2556
- - Single file read-modify-write on `sprint-status.yaml`
2557
- - Must validate the target sprint exists and is in `planning` or `active` status
2558
- - Atomic operation: both the removal from backlog and addition to sprint happen in one file write
2559
-
2560
- ### Story 17.12: Rework remove-from-sprint Skill (Heavy Rework — Movement Semantics)
2561
-
2562
- As a **Scrum Master**,
2563
- I want the `remove-from-sprint` skill to MOVE items from a sprint's `items` array back to the `backlog` section,
2564
- So that sprint scope adjustments are clean, reversible, single-file operations.
2565
-
2566
- **Acceptance Criteria:**
2567
-
2568
- **Given** a sprint has assigned items
2569
- **When** the Scrum Master invokes `remove-from-sprint`
2570
- **Then** it displays the sprint's currently assigned items with their statuses
2571
- **And** the Scrum Master selects which items to remove
2572
-
2573
- **Given** items are removed from the sprint
2574
- **When** the removal completes
2575
- **Then** each selected item is REMOVED from the sprint's `items` array (FR134)
2576
- **And** ADDED back to the `backlog` array with a `priority` field set to position 1 (top of backlog — Scrum Master can reprioritize later)
2577
- **And** the item's `status` is NOT changed — it retains its current status (e.g., stays `ready-for-dev`)
2578
-
2579
- **Given** a sprint's capacity was full (e.g., 6/6 items)
2580
- **When** an item is removed
2581
- **Then** the sprint's effective capacity usage decreases (e.g., 5/6)
2582
-
2583
- **Technical notes:**
2584
- - Reworks the existing `remove-from-sprint` skill
2585
- - Single file read-modify-write on `sprint-status.yaml`
2586
- - This is the inverse of Story 17.11
2587
- - Removed items re-enter backlog at priority 1 by default; the Scrum Master should reprioritize after bulk removals
2588
-
2589
- ### Story 17.13: Rework sprint-status-view Skill (Heavy Rework — Single Source Read)
2590
-
2591
- As a **Project Manager**,
2592
- I want the `sprint-status-view` skill to read all sprint data from the single `sprint-status.yaml` file,
2593
- So that sprint status display is fast and consistent with no cross-file reconciliation needed.
2594
-
2595
- **Acceptance Criteria:**
2596
-
2597
- **Given** the `sprint-status-view` skill is invoked
2598
- **When** it reads `sprint-status.yaml`
2599
- **Then** it displays a formatted view from the three sections:
2600
- ```
2601
- === Epics ===
2602
- Epic 5: Bundled BMAD Installation [in-progress] (2/6 done)
2603
- Epic 17: Sprint Management Model Rework [planning] (0/15 done)
2604
-
2605
- === Sprint 3 (active) — 4/6 items ===
2606
- * 5-5-explicit-parameter-passing [story] — in-progress
2607
- * 5-6-fix-space-in-path-bug [story] — review
2608
- * BUG-path-spaces [bug, high] — ready-for-dev
2609
- * 15-1-bump-bmad-method [story] — backlog
2610
-
2611
- === Backlog — 12 items ===
2612
- 1. 15-2-restructure-extension-module [story] — ready-for-dev
2613
- 2. 15-3-convert-custom-agents [story] — backlog
2614
- ...
2615
- ```
2616
-
2617
- **Given** no `sprint-status.yaml` file exists
2618
- **When** the skill is invoked
2619
- **Then** it reports: "No sprint-status.yaml found. Run sprint planning to initialize."
2620
-
2621
- **Given** the file contains multiple sprints (one active, others closed or planning)
2622
- **When** the status is displayed
2623
- **Then** the active sprint is shown first, followed by planning sprints, then a summary of closed sprints
2624
-
2625
- **Technical notes:**
2626
- - Reworks the existing `sprint-status-view` skill
2627
- - Single file read — no cross-file reconciliation needed (previously had to merge backlog.yaml + sprint files + sprint-status.yaml)
2628
- - The display format should work well for both human reading and LLM parsing
2629
- - Does NOT write to the file — read-only operation
2630
-
2631
- ### Story 17.14: Rework cleanup-done Skill (Heavy Rework — Single Source)
2632
-
2633
- As a **Scrum Master**,
2634
- I want the `cleanup-done` skill to scan the unified `sprint-status.yaml` for done items, remove them from the file, and archive their story files,
2635
- So that the active sprint view stays clean and done work is preserved in the archive.
2636
-
2637
- **Acceptance Criteria:**
2638
-
2639
- **Given** items with `status: done` exist in the `sprints` section of `sprint-status.yaml`
2640
- **When** the `cleanup-done` skill is invoked
2641
- **Then** each done item is REMOVED from its sprint's `items` array (FR136)
2642
- **And** the corresponding story/bug file is moved to `{implementation_artifacts}/done/` (FR131)
2643
- **And** if the `done/` subfolder doesn't exist, it is created
2644
-
2645
- **Given** items with `status: done` exist in the `backlog` section (edge case — done but never sprint-assigned)
2646
- **When** the `cleanup-done` skill is invoked
2647
- **Then** those items are also REMOVED from the `backlog` array and their files archived
2648
-
2649
- **Given** a story file exists at `{implementation_artifacts}/{story-id}.md`
2650
- **When** the story reaches `done` status and cleanup runs
2651
- **Then** the file is moved to `{implementation_artifacts}/done/{story-id}.md`
2652
-
2653
- **Given** a bug file exists at `{implementation_artifacts}/BUG-{title}.md`
2654
- **When** the bug reaches `done` status and cleanup runs
2655
- **Then** the file is moved to `{implementation_artifacts}/done/BUG-{title}.md`
2656
-
2657
- **Given** all items in a sprint reach `done` status and are cleaned up
2658
- **When** the sprint has zero remaining items
2659
- **Then** the sprint's `items` array is empty but the sprint definition is preserved (historical record)
2660
- **And** the skill suggests closing the sprint (see Story 17.21)
2661
-
2662
- **Technical notes:**
2663
- - Reworks the existing `cleanup-done` skill
2664
- - Single file read-modify-write on `sprint-status.yaml`
2665
- - File move uses `fs.rename()` — not copy+delete
2666
- - The `done/` subfolder already exists at `_bmad-output/implementation-artifacts/done/` — this story formalizes its use
2667
- - Cleanup can be triggered explicitly or as part of sprint-status-view and sprint-planning workflows
2668
-
2669
- ### Story 17.15: Rework bmad-sprint-planning Skill (Heavy Rework — Bootstrap Unified File)
2670
-
2671
- As a **Scrum Master**,
2672
- I want the `bmad-sprint-planning` skill to bootstrap or update the unified `sprint-status.yaml` from the epics document,
2673
- So that sprint planning always starts from a complete, consistent single file.
2674
-
2675
- **Acceptance Criteria:**
2676
-
2677
- **Given** no `sprint-status.yaml` exists (first-time setup)
2678
- **When** the Scrum Master invokes `bmad-sprint-planning`
2679
- **Then** it creates `sprint-status.yaml` with:
2680
- - `epics` section populated from `epics.md` (all epics with title, status, story counts)
2681
- - `backlog` section populated with all non-done stories and bugs in priority order
2682
- - `sprints` section initialized as an empty array `[]`
2683
-
2684
- **Given** `sprint-status.yaml` already exists
2685
- **When** the Scrum Master invokes `bmad-sprint-planning`
2686
- **Then** the `epics` section is refreshed from `epics.md` (new epics added, counts updated)
2687
- **And** new stories from `epics.md` that don't exist in `backlog` or any `sprints` section are added to `backlog`
2688
- **And** existing items in `backlog` and `sprints` sections are NOT modified (preserves status, priority, sprint assignments)
2689
- **And** done items are NOT reintroduced (they stay in the `done/` archive)
2690
-
2691
- **Given** the sprint-planning workflow includes cleanup
2692
- **When** it detects items with `status: done` still in the file
2693
- **Then** it runs the cleanup-done logic (Story 17.14) as part of the planning workflow
2694
-
2695
- **Technical notes:**
2696
- - Reworks the existing `bmad-sprint-planning` skill
2697
- - This is the primary bootstrap entry point for the unified file
2698
- - Must handle the merge carefully: new items go to backlog, existing items stay where they are
2699
- - The `epics` section is always fully regenerated (it's reference data, not user-managed)
2700
- - Should be run at the start of each sprint planning session
2701
-
2702
- ### Story 17.16: Rework add-sprint Skill (Moderate Rework — Section-Based)
2703
-
2704
- As a **Scrum Master**,
2705
- I want the `add-sprint` skill to create a new sprint entry in the `sprints` section of `sprint-status.yaml`,
2706
- So that new sprints are defined within the unified file rather than as separate files.
2707
-
2708
- **Acceptance Criteria:**
2709
-
2710
- **Given** the Scrum Master invokes `add-sprint`
2711
- **When** the sprint details are provided (name, capacity, optional ISO start/end dates)
2712
- **Then** a new sprint entry is appended to the `sprints` array in `sprint-status.yaml`:
2713
- ```yaml
2714
- sprints:
2715
- - id: sprint-4
2716
- name: "Sprint 4"
2717
- status: planning
2718
- capacity: 6
2719
- start: "2026-04-15"
2720
- end: "2026-04-28"
2721
- items: []
2722
- ```
2723
- **And** the sprint ID is auto-incremented from the highest existing sprint ID
2724
-
2725
- **Given** a sprint with `status: planning` already exists
2726
- **When** a new sprint is created
2727
- **Then** the new sprint is also created with `status: planning` (multiple planning sprints are allowed)
2728
- **And** only one sprint can be `active` at a time
2729
-
2730
- **Given** `sprint-status.yaml` does not exist
2731
- **When** `add-sprint` is invoked
2732
- **Then** the skill reports: "No sprint-status.yaml found. Run sprint planning first to initialize the file."
2733
-
2734
- **Technical notes:**
2735
- - Reworks the existing `add-sprint` skill (Story 12.1)
2736
- - Writes to the `sprints` section of `sprint-status.yaml` instead of creating a separate `sprints/sprint-N.yaml` file
2737
- - Sprint ID format: `sprint-{number}` (kebab-case, auto-incremented)
2738
- - Capacity is defined by number of items (stories + bugs) per FR66
2739
-
2740
- ### Story 17.17: Rework modify-sprint Skill (Moderate Rework — Section-Based)
2741
-
2742
- As a **Scrum Master**,
2743
- I want the `modify-sprint` skill to update sprint metadata within the `sprints` section of `sprint-status.yaml`,
2744
- So that sprint adjustments (capacity, dates, name, status) are made in the unified file.
2745
-
2746
- **Acceptance Criteria:**
2747
-
2748
- **Given** the Scrum Master invokes `modify-sprint` with a target sprint ID
2749
- **When** the sprint exists in the `sprints` section
2750
- **Then** the skill allows modification of: `name`, `capacity`, `start`, `end`, `status`
2751
- **And** the updated sprint is written back to `sprint-status.yaml`
2752
-
2753
- **Given** the Scrum Master changes a sprint's `status` to `active`
2754
- **When** another sprint is already `active`
2755
- **Then** the skill warns that only one sprint can be active
2756
- **And** requires the existing active sprint to be closed first (or offers to close it)
2757
-
2758
- **Given** the Scrum Master reduces capacity below the current item count
2759
- **When** the modification is attempted
2760
- **Then** the skill warns: "Sprint has N items but new capacity is M (M < N). Remove items first."
2761
- **And** does NOT apply the capacity change until items are removed
2762
-
2763
- **Technical notes:**
2764
- - Reworks the existing `modify-sprint` skill (Story 12.3)
2765
- - Modifies the sprint entry in-place within the `sprints` array of `sprint-status.yaml`
2766
- - Status transitions: `planning` -> `active` -> `closed`. No backward transitions except via the Scrum Master explicitly overriding.
2767
-
2768
- ### Story 17.18: Rework bmad-dev-story Skill (Moderate Rework — Cross-Section Status Update)
2769
-
2770
- As a **Developer**,
2771
- I want the `bmad-dev-story` skill to update story status in-place within `sprint-status.yaml` regardless of which section the story resides in,
2772
- So that development progress is reflected in the unified file without manual status updates.
2773
-
2774
- **Acceptance Criteria:**
2775
-
2776
- **Given** a developer starts working on a story via `bmad-dev-story`
2777
- **When** the story transitions from `ready-for-dev` to `in-progress`
2778
- **Then** the skill finds the item in `sprint-status.yaml` (searching both `backlog` and all `sprints[].items`)
2779
- **And** updates the item's `status` field in-place (FR135)
2780
-
2781
- **Given** a developer completes a story
2782
- **When** the story transitions to `review` or `done`
2783
- **Then** the status is updated in-place in whichever section the item currently resides
2784
- **And** if the status becomes `done`, the cleanup-done logic can be triggered (or deferred to explicit cleanup)
2785
-
2786
- **Given** the story ID is not found in `sprint-status.yaml`
2787
- **When** the skill attempts to update status
2788
- **Then** it reports: "Story {id} not found in sprint-status.yaml. It may have been archived to done/ or not yet added to the backlog."
2789
-
2790
- **Technical notes:**
2791
- - Reworks the existing `bmad-dev-story` skill
2792
- - Must search across both `backlog` and all `sprints[].items` sections to find the item by `id`
2793
- - Write is a targeted update — only the `status` field changes, all other fields preserved
2794
- - Cross-section search is needed because a developer may work on a story whether or not it's sprint-assigned
2795
-
2796
- ### Story 17.19: Rework story-status-lookup Skill (Light Rework — Cross-Section Search)
2797
-
2798
- As a **Developer**,
2799
- I want the `story-status-lookup` skill to search the unified `sprint-status.yaml` for any story's current status,
2800
- So that code can be classified as delivered or work-in-progress from a single data source.
2801
-
2802
- **Acceptance Criteria:**
2803
-
2804
- **Given** the `story-status-lookup` skill is invoked with a story ID
2805
- **When** the story exists in the `backlog` section of `sprint-status.yaml`
2806
- **Then** it returns the item's status and notes it is "in backlog (unassigned)"
2807
-
2808
- **Given** the story exists in a sprint's `items` array
2809
- **When** the lookup completes
2810
- **Then** it returns the item's status and notes which sprint it is assigned to (e.g., "in sprint-3")
2811
-
2812
- **Given** the story is not found in `sprint-status.yaml`
2813
- **When** the lookup checks the `done/` archive folder
2814
- **Then** it reports: "Story {id} is archived (done)" if the file exists in `done/`
2815
- **Or** reports: "Story {id} not found in sprint-status.yaml or done/ archive"
2816
-
2817
- **Technical notes:**
2818
- - Reworks the existing `story-status-lookup` skill
2819
- - Single file search across `backlog` + all `sprints[].items` sections
2820
- - Fallback: check `done/` folder for archived stories
2821
- - The `always_load: true` flag in MANIFEST.yaml remains — this skill is loaded every session
2822
- - The Jira extension point reserved in this skill is activated by Story 17.22
2823
-
2824
- ### Story 17.20: Rework bmad-sprint-status Skill (Light Rework — Structured Sections)
2825
-
2826
- As a **Project Manager**,
2827
- I want the `bmad-sprint-status` skill to produce a concise risk-focused summary from the structured sections of `sprint-status.yaml`,
2828
- So that sprint health and risks are surfaced quickly from the single source of truth.
2829
-
2830
- **Acceptance Criteria:**
2831
-
2832
- **Given** the `bmad-sprint-status` skill is invoked
2833
- **When** it reads the `sprints` section of `sprint-status.yaml`
2834
- **Then** it identifies the active sprint and calculates:
2835
- - Items by status: how many `in-progress`, `review`, `ready-for-dev`, `backlog`
2836
- - Capacity usage: items.length / capacity
2837
- - Blocked items: items with `status: blocked` (if any)
2838
-
2839
- **Given** the active sprint has items with concerning statuses
2840
- **When** the summary is generated
2841
- **Then** it flags risks:
2842
- - "3 of 6 items still in `backlog` status — not yet started"
2843
- - "Sprint at 100% capacity with 2 items in `ready-for-dev`"
2844
- - "No items in `review` or `done` — sprint may be at risk"
2845
-
2846
- **Given** the `epics` section contains epic-level data
2847
- **When** the summary is generated
2848
- **Then** it includes epic progress: "Epic 5: 2/6 done, Epic 17: 0/15 done"
2849
-
2850
- **Technical notes:**
2851
- - Reworks the existing `bmad-sprint-status` skill
2852
- - Reads from the structured sections of `sprint-status.yaml` — no cross-file joins needed
2853
- - Output is optimized for LLM context (concise, structured) and human readability
2854
- - This is the quick-summary variant; `sprint-status-view` (Story 17.13) is the detailed view
2855
-
2856
- ### Story 17.21: New close-sprint Skill
2857
-
2858
- As a **Scrum Master**,
2859
- I want a `close-sprint` skill that transitions a sprint from `active` to `closed`, archives all done items, and returns incomplete items to the backlog,
2860
- So that sprint closure is a clean, well-defined workflow.
2861
-
2862
- **Acceptance Criteria:**
2863
-
2864
- **Given** the Scrum Master invokes `close-sprint`
2865
- **When** an active sprint exists
2866
- **Then** the skill displays the sprint summary: total items, done count, incomplete count
2867
-
2868
- **Given** the sprint has items with `status: done`
2869
- **When** the sprint is closed
2870
- **Then** all done items are REMOVED from the sprint's `items` array
2871
- **And** their story/bug files are moved to `{implementation_artifacts}/done/` (same as cleanup-done)
2872
-
2873
- **Given** the sprint has incomplete items (status != `done`)
2874
- **When** the sprint is closed
2875
- **Then** the skill presents three options for handling incomplete items (FR137):
2876
- (a) **Move all to the next sprint** — all incomplete items are MOVED from the current sprint's `items` array to the next sprint's `items` array (the next sprint must exist in `planning` status; if no next sprint exists, the skill prompts to create one or falls back to option b)
2877
- (b) **Return all to backlog** — all incomplete items are MOVED from the sprint's `items` array back to the `backlog` section (FR134 — movement semantics), each receiving a `priority` value placing it at the top of the backlog (to be reprioritized)
2878
- (c) **Decide per item** — the skill iterates through each incomplete item and asks whether to move it to the next sprint or return it to the backlog
2879
- **And** regardless of option chosen, each item's status is preserved (e.g., `in-progress` items stay `in-progress`)
2880
-
2881
- **Given** all items have been archived or returned to backlog
2882
- **When** the sprint is fully processed
2883
- **Then** the sprint's `status` is set to `closed`
2884
- **And** the sprint's `items` array is empty `[]`
2885
- **And** the sprint definition is preserved in the `sprints` section (historical record)
2886
- **And** a summary is displayed: "Sprint N closed. X items archived, Y items returned to backlog."
2887
-
2888
- **Given** no active sprint exists
2889
- **When** `close-sprint` is invoked
2890
- **Then** it reports: "No active sprint found. Nothing to close."
2891
-
2892
- **Technical notes:**
2893
- - NEW skill: `lib/bmad-extension/skills/close-sprint/`
2894
- - Combines done-item archival (Story 17.14 logic) with incomplete-item return to backlog (Story 17.12 inverse)
2895
- - Single file read-modify-write on `sprint-status.yaml` plus file moves for archived stories
2896
- - After close-sprint, the Scrum Master typically runs `add-sprint` to create the next sprint
2897
-
2898
- ### Story 17.22: Jira Adapter Pattern (tracking_system Switch)
2899
-
2900
- As a **Project Manager**,
2901
- I want sprint management skills to read/write from Jira when `tracking_system` is configured as `jira`,
2902
- So that teams using Jira for project tracking can use the same BMAD sprint skills with their Jira instance.
2903
-
2904
- **Acceptance Criteria:**
2905
-
2906
- **Given** `project-context.md` (or root directives) contains `tracking_system: file-system` (default)
2907
- **When** any sprint management skill is invoked
2908
- **Then** it reads/writes `sprint-status.yaml` on the local file system (current behavior)
2909
-
2910
- **Given** `project-context.md` contains `tracking_system: jira` with Jira connection config
2911
- **When** any sprint management skill is invoked
2912
- **Then** it reads/writes from the Jira API using the same data model (epics, backlog items, sprint items)
2913
- **And** the Jira adapter maps: Jira Sprint -> `sprints[]` entries, Jira Backlog -> `backlog[]` entries, Jira Epic -> `epics[]` entries
2914
- **And** Jira status fields are mapped to the same status vocabulary: `backlog`, `ready-for-dev`, `in-progress`, `review`, `done`
2915
-
2916
- **Given** the Jira adapter is active
2917
- **When** an item is moved from backlog to sprint (Story 17.11 logic)
2918
- **Then** the adapter calls the Jira REST API to move the issue to the target sprint
2919
- **And** the local `sprint-status.yaml` is NOT written (Jira is the source of truth)
2920
-
2921
- **Given** the Jira connection fails (network error, auth failure, rate limit)
2922
- **When** the skill detects the failure
2923
- **Then** it reports the error clearly and suggests checking credentials/connectivity
2924
- **And** does NOT fall back to file-system silently (explicit fail, no silent data divergence)
2925
-
2926
- **Given** the adapter pattern is implemented
2927
- **When** a new backend is added in the future (e.g., Linear, Azure DevOps)
2928
- **Then** only a new adapter module is needed — no changes to skill logic
2929
-
2930
- **Technical notes:**
2931
- - Blocked on Epic 14 Story 14.3 (External Tooling Abstraction Layer architecture) — the adapter interface contract must be designed first
2932
- - The adapter pattern uses a `resolveBackend(config)` function that returns either a `FilesystemBackend` or `JiraBackend` object implementing the same interface
2933
- - Interface methods: `readSprintStatus()`, `writeSprintStatus(data)`, `moveItem(itemId, fromSection, toSection)`, `updateItemStatus(itemId, newStatus)`, `archiveItem(itemId)`
2934
- - Credentials: environment variables (`JIRA_BASE_URL`, `JIRA_API_TOKEN`, `JIRA_USER_EMAIL`) as proposed by Epic 14 research
2935
- - All 12 sprint skills call through the backend interface — they never read/write files directly
2936
- - FR138 scope: same data model, different storage backend. Skills do NOT expose Jira-specific UI or fields.
2937
-
2938
- ### Story 17.23: Migration and Deprecation of Old Files
2939
-
2940
- As a **DevOps Engineer**,
2941
- I want the old three-file sprint model (`backlog.yaml`, `sprints/sprint-N.yaml`, `sprint-status.yaml` with old schema) automatically migrated to the unified `sprint-status.yaml`,
2942
- So that existing projects transition cleanly without data loss.
2943
-
2944
- **Acceptance Criteria:**
2945
-
2946
- **Given** a project has the old `backlog.yaml` file
2947
- **When** `bmad-sprint-planning` is run (Story 17.15) and `sprint-status.yaml` does not yet exist (or has the old schema)
2948
- **Then** the migration reads `backlog.yaml` and imports all items into the `backlog` section of the new unified `sprint-status.yaml`
2949
- **And** priority ordering from the old file is preserved
2950
-
2951
- **Given** a project has old `sprints/sprint-N.yaml` files
2952
- **When** the migration runs
2953
- **Then** each sprint file is imported as an entry in the `sprints` section of `sprint-status.yaml`
2954
- **And** items referenced in old sprint files are matched to backlog items and moved to the sprint's `items` array
2955
-
2956
- **Given** the old `sprint-status.yaml` exists with the old schema (flat `development_status` list)
2957
- **When** the migration detects the old format
2958
- **Then** it extracts item statuses from the old file and applies them to the corresponding items in the new schema
2959
- **And** the old file is backed up to `sprint-status.yaml.bak` before overwriting with the new schema
2960
-
2961
- **Given** the migration completes successfully
2962
- **When** the new `sprint-status.yaml` is verified
2963
- **Then** the old files are removed:
2964
- - `backlog.yaml` is deleted
2965
- - `sprints/` directory is deleted (if empty after migration)
2966
- - `sprint-status.yaml.bak` is preserved for 1 sprint cycle (manual deletion)
2967
-
2968
- **Given** the migration encounters conflicts (e.g., item in old backlog with different status than old sprint-status)
2969
- **When** the conflict is detected
2970
- **Then** the migration logs the conflict and uses the most recent status (from sprint-status.yaml or sprint file, whichever was modified last)
2971
- **And** a migration report is generated listing all conflicts and resolutions
2972
-
2973
- **Technical notes:**
2974
- - Migration runs as part of `bmad-sprint-planning` (Story 17.15) — not a separate skill
2975
- - Old schema detection: if `sprint-status.yaml` has a `development_status` top-level key (old) vs `epics`/`backlog`/`sprints` keys (new)
2976
- - The migration is idempotent — running it twice produces the same result
2977
- - After one successful migration, subsequent `bmad-sprint-planning` runs skip migration logic (new schema detected)
2978
-
2979
- ### Story 17.24: Rework `prioritize-backlog` Skill for Unified File
2980
-
2981
- As a **Scrum Master**,
2982
- I want the `prioritize-backlog` skill to read and write the `backlog` section of the unified `sprint-status.yaml`,
2983
- So that backlog reprioritization works against the single source of truth instead of the deprecated standalone `backlog.yaml` file.
2984
-
2985
- **Acceptance Criteria:**
2986
-
2987
- **Given** the `prioritize-backlog` skill is invoked
2988
- **When** the unified `sprint-status.yaml` exists
2989
- **Then** it reads items from the `backlog` section only (items already assigned to a sprint keep their priority and are NOT reprioritized)
2990
-
2991
- **Given** the Scrum Master reorders or adjusts priority values
2992
- **When** the reprioritization is applied
2993
- **Then** the skill writes updated `priority` values back to the `backlog` section of `sprint-status.yaml`
2994
- **And** all other sections (`epics`, `sprints`) are preserved unchanged
2995
-
2996
- **Given** items exist in both `backlog` and `sprints` sections
2997
- **When** the skill displays items for prioritization
2998
- **Then** only `backlog` items are shown — sprint-assigned items are excluded from the prioritization view
2999
-
3000
- **Given** the old `backlog.yaml` file exists but `sprint-status.yaml` also exists
3001
- **When** the skill is invoked
3002
- **Then** it operates on `sprint-status.yaml` only (the old file is ignored; see Story 17.23 for migration)
3003
-
3004
- **Technical notes:**
3005
- - Reworks the existing `prioritize-backlog` skill to read/write `sprint-status.yaml` `backlog` section instead of standalone `backlog.yaml`
3006
- - Rework level: Light — the core prioritization logic (multi-criteria sorting, severity, business value, dependencies, type, age) remains unchanged; only the file I/O layer changes
3007
- - Single file read-modify-write on `sprint-status.yaml`
3008
- - Depends on Story 17.9 (unified schema definition)
3009
- - FRs: FR133 (unified file), FR134 (movement semantics — prioritization respects section boundaries)
3010
-
3011
- ---
3012
-
3013
- ## Epic 18: Roo Code IDE Support (Phase 2)
3014
-
3015
- **Goal:** Full Roo Code integration — ma-agents skill installation, BMAD agent personas as custom modes, planning instructions as rules, and BMAD workflows as slash commands.
3016
- **FRs covered:** FR34 (extended to include Roo Code), FR36, FR38
3017
- **Proposed FRs:** FR158 (Roo Code custom modes from BMAD agents), FR159 (Roo Code rules from BMAD instructions), FR160 (Roo Code slash commands from BMAD workflows), FR161 (Cline-to-Roo migration) — renumbered from FR142-145; FR141-FR157 are now reserved for Epic 19 (Knowledge Graph)
3018
- **Research:** `_bmad-output/planning-artifacts/domain-research-roocode-2026-03-31.md`
3019
- **Dependency:** None (can proceed independently; upstream `bmad-method` already has `roo` in `platform-codes.yaml`)
3020
-
3021
- ### Story 18.1: Add Roo Code Agent Entry to ma-agents
3022
-
3023
- As a **Chief Architect**,
3024
- I want Roo Code registered as a supported IDE in `lib/agents.js`,
3025
- So that ma-agents CLI can install skills into Roo Code's `.roo/skills/` directory.
3026
-
3027
- **Acceptance Criteria:**
3028
-
3029
- **Given** the `lib/agents.js` file
3030
- **When** a developer adds Roo Code support
3031
- **Then** a new entry is added with:
3032
- ```javascript
3033
- {
3034
- id: 'roo-code',
3035
- name: 'Roo Code',
3036
- version: '1.0.0',
3037
- category: 'ide',
3038
- description: 'Roo Code AI Assistant (Enhanced Cline fork)',
3039
- skillsDir: '.roo/skills',
3040
- getProjectPath: () => path.join(process.cwd(), '.roo', 'skills'),
3041
- getGlobalPath: () => { /* VS Code globalStorage: Code/User/globalStorage/rooveterinaryinc.roo-cline/skills */ },
3042
- fileExtension: '.md',
3043
- template: 'generic',
3044
- instructionFiles: ['.roo/rules/00-ma-agents.md'],
3045
- injectionStrategy: { position: 'top', skipPatterns: ['---'] }
3046
- }
3047
- ```
3048
-
3049
- **Given** `ma-agents install --agent roo-code` is run
3050
- **When** a skill is selected
3051
- **Then** the skill is installed to `.roo/skills/{skill-id}/SKILL.md`
3052
- **And** a `MANIFEST.yaml` is generated in `.roo/skills/`
3053
-
3054
- **Given** `ma-agents list --agent roo-code` is run
3055
- **When** the agent is targeted
3056
- **Then** skills and their status are displayed correctly
3057
-
3058
- **Technical notes:**
3059
- - The `instructionFiles` points to `.roo/rules/00-ma-agents.md` (not a top-level instruction file) because Roo Code loads rules from the `.roo/rules/` directory, not a single instruction file
3060
- - The `00-` prefix ensures the ma-agents planning instruction loads first (alphabetical order)
3061
- - Unlike Cline, Roo Code does NOT use `.clinerules` as primary — it uses `.roo/rules/`
3062
- - Global path should use `RooCode` (matching VS Code extension storage conventions)
3063
-
3064
- ### Story 18.2: Create BMAD IDE Config and Manifest Entry
3065
-
3066
- As a **Chief Architect**,
3067
- I want Roo Code recognized in the BMAD configuration system,
3068
- So that the BMAD installer includes Roo Code in IDE setup and customization flows.
3069
-
3070
- **Acceptance Criteria:**
3071
-
3072
- **Given** the BMAD configuration directory `_bmad/_config/ides/`
3073
- **When** Roo Code is added
3074
- **Then** a file `roo-code.yaml` is created:
3075
- ```yaml
3076
- ide: roo-code
3077
- configured_date: 2026-03-31
3078
- last_updated: 2026-03-31
3079
- configuration:
3080
- _noConfigNeeded: true
3081
- ```
3082
-
3083
- **Given** the BMAD manifest at `_bmad/_config/manifest.yaml`
3084
- **When** Roo Code is added
3085
- **Then** `roo-code` appears in the `ides` list:
3086
- ```yaml
3087
- ides:
3088
- - claude-code
3089
- - gemini
3090
- - cline
3091
- - cursor
3092
- - antigravity
3093
- - roo-code
3094
- ```
3095
-
3096
- **Given** the agent customization directory `_bmad/_config/agents/`
3097
- **When** Roo Code is added
3098
- **Then** a file `roo-code.customize.yaml` is created with the standard customization template (persona, principles, menu overrides)
3099
-
3100
- **Technical notes:**
3101
- - Follow the exact same pattern as existing IDE configs
3102
- - The customize.yaml should have the same structure as `cline.customize.yaml`
3103
-
3104
- ### Story 18.3: Update Installer to Handle Roo Code Rules Injection
3105
-
3106
- As a **Chief Architect**,
3107
- I want the ma-agents installer to inject planning instructions into Roo Code's `.roo/rules/` directory,
3108
- So that the MANIFEST-based skill loading instruction is automatically applied when Roo Code starts.
3109
-
3110
- **Acceptance Criteria:**
3111
-
3112
- **Given** `ma-agents install --agent roo-code` runs
3113
- **When** skills are installed
3114
- **Then** a file `.roo/rules/00-ma-agents.md` is created with:
3115
- ```markdown
3116
- <!-- MA-AGENTS-START -->
3117
- # AI Agent Skills - Planning Instruction
3118
-
3119
- You have access to a library of skills in your skills directory. Before starting any task:
3120
-
3121
- 1. Read the skill manifest at .roo/skills/MANIFEST.yaml
3122
- 2. Based on the task description, select which skills are relevant
3123
- 3. Read only the selected skill files
3124
- 4. Then proceed with the task
3125
-
3126
- Always load skills marked with always_load: true.
3127
- Do not load skills that are not relevant to the current task.
3128
- <!-- MA-AGENTS-END -->
3129
- ```
3130
-
3131
- **Given** the file `.roo/rules/00-ma-agents.md` already exists with MA-AGENTS markers
3132
- **When** the installer runs again
3133
- **Then** the content between markers is updated in place (idempotent)
3134
-
3135
- **Given** `ma-agents uninstall --agent roo-code` runs
3136
- **When** skills are removed
3137
- **Then** the `00-ma-agents.md` file is removed from `.roo/rules/`
3138
-
3139
- **Technical notes:**
3140
- - The `updateAgentInstructions()` function in `installer.js` already handles marker-based injection — this story extends it to support directory-based instruction files (Roo Code puts rules in a directory, not a single file)
3141
- - The `00-` prefix ensures this loads before any user rules (alphabetical order)
3142
- - Must handle the case where `.roo/rules/` directory doesn't exist yet (create it)
3143
-
3144
- ### Story 18.4: Generate .roomodes with BMAD Agent Personas
3145
-
3146
- As a **Chief Architect**,
3147
- I want the BMAD installer to generate a `.roomodes` file with BMAD agent personas as Roo Code custom modes,
3148
- So that users can switch between BMAD roles (PM, Analyst, Architect, Dev, QA, SM) directly from the Roo Code mode selector.
3149
-
3150
- **Acceptance Criteria:**
3151
-
3152
- **Given** the BMAD installer runs `bmad install --ide roo`
3153
- **When** agent artifacts are processed
3154
- **Then** a `.roomodes` file is generated in YAML format with BMAD agents as custom modes:
3155
- ```yaml
3156
- customModes:
3157
- - slug: bmad-analyst
3158
- name: "Analyst (Mary)"
3159
- description: "Strategic business analysis, market research, requirements elicitation"
3160
- roleDefinition: |
3161
- You are Mary, a Senior Business Analyst with deep expertise in market research,
3162
- competitive analysis, and requirements elicitation...
3163
- whenToUse: |
3164
- Use this mode when conducting market research, creating product briefs,
3165
- competitive analysis, or domain research.
3166
- customInstructions: |
3167
- Load and follow the BMAD agent activation protocol from
3168
- {project-root}/_bmad/bmm/agents/analyst.md
3169
- groups:
3170
- - read
3171
- - mcp
3172
- - slug: bmad-pm
3173
- name: "PM (Patricia)"
3174
- ...
3175
- ```
3176
-
3177
- **Given** BMAD agent personas include tool restrictions
3178
- **When** the mode is generated
3179
- **Then** each mode's `groups` field reflects appropriate tool permissions:
3180
- - Analyst/PM/SM: `[read, mcp]` (no edit, no command)
3181
- - Architect: `[read, edit, mcp]` (can edit architecture docs)
3182
- - Dev: `[read, edit, command, mcp]` (full access)
3183
- - QA: `[read, edit, command, mcp]` (full access for test writing)
3184
-
3185
- **Given** a `.roomodes` file already exists with user-defined modes
3186
- **When** the installer runs
3187
- **Then** BMAD modes (slug starting with `bmad-`) are replaced/updated
3188
- **And** user-defined modes are preserved untouched
3189
-
3190
- **Technical notes:**
3191
- - This requires a new function in the Roo Code IDE handler (or config-driven installer extension)
3192
- - BMAD agent slugs use `bmad-` prefix for safe identification and cleanup
3193
- - The `roleDefinition` should be extracted from the agent's `<persona>` section
3194
- - The `customInstructions` should reference the full agent file path for runtime loading
3195
- - Read agent data from `_bmad/bmm/agents/*.md` at install time
3196
- - `.roomodes` supports both YAML and JSON — prefer YAML for readability
3197
-
3198
- ### Story 18.5: Deploy BMAD Workflows as Roo Code Slash Commands
3199
-
3200
- As a **Chief Architect**,
3201
- I want BMAD workflows deployed as Roo Code slash commands in `.roo/commands/`,
3202
- So that users can trigger BMAD workflows (create-prd, sprint-planning, code-review, etc.) directly from the chat input.
3203
-
3204
- **Acceptance Criteria:**
3205
-
3206
- **Given** the BMAD installer runs for Roo Code
3207
- **When** workflow artifacts are processed
3208
- **Then** markdown files are created in `.roo/commands/` for each BMAD workflow:
3209
- ```markdown
3210
- ---
3211
- description: Create a PRD from scratch through guided collaborative workflow
3212
- mode: bmad-pm
3213
- ---
3214
- You must fully embody the PM agent persona and follow all activation instructions.
3215
-
3216
- <agent-activation CRITICAL="TRUE">
3217
- 1. LOAD the FULL agent file from {project-root}/_bmad/bmm/agents/pm.md
3218
- 2. READ its entire contents
3219
- 3. FOLLOW every step in the <activation> section precisely
3220
- 4. Execute the Create PRD menu item
3221
- </agent-activation>
3222
- ```
3223
-
3224
- **Given** a workflow has a natural target mode (e.g., create-prd → PM, create-architecture → Architect)
3225
- **When** the slash command is generated
3226
- **Then** the frontmatter `mode` field maps to the corresponding `bmad-*` custom mode (from Story 18.4)
3227
-
3228
- **Given** slash commands are generated
3229
- **When** they are listed
3230
- **Then** all BMAD workflows appear as `/bmad-*` commands in Roo Code's command palette:
3231
- - `/bmad-create-prd`
3232
- - `/bmad-create-architecture`
3233
- - `/bmad-sprint-planning`
3234
- - `/bmad-code-review`
3235
- - `/bmad-create-story`
3236
- - `/bmad-dev-story`
3237
- - etc.
3238
-
3239
- **Given** BMAD agent launchers exist
3240
- **When** slash commands are generated
3241
- **Then** each BMAD agent also gets a launcher slash command:
3242
- - `/bmad-analyst` → activates Analyst agent
3243
- - `/bmad-pm` → activates PM agent
3244
- - etc.
3245
-
3246
- **Technical notes:**
3247
- - Slash command filenames become the command name (auto-slugified)
3248
- - Use `bmad-` prefix for all commands for clean namespacing
3249
- - The `mode` field triggers automatic mode switching when the command is run
3250
- - This leverages the same agent artifact data used by other IDEs (`.claude/commands/`, `.cursor/commands/`, etc.)
3251
- - The config-driven installer's `cleanup()` already handles `legacy_targets: [.roo/commands]` for removing old artifacts
3252
-
3253
- ### Story 18.6: Mode-Specific Rules for BMAD Agents
3254
-
3255
- As a **Chief Architect**,
3256
- I want mode-specific BMAD rules deployed to `.roo/rules-{bmad-modeSlug}/` directories,
3257
- So that each BMAD agent mode receives its specific planning instructions and behavioral guidelines.
3258
-
3259
- **Acceptance Criteria:**
3260
-
3261
- **Given** the BMAD installer generates custom modes (Story 18.4)
3262
- **When** mode-specific rules are deployed
3263
- **Then** directories are created for each BMAD mode:
3264
- ```
3265
- .roo/
3266
- ├── rules/
3267
- │ └── 00-ma-agents.md (from Story 18.3)
3268
- ├── rules-bmad-analyst/
3269
- │ └── 01-analyst-instructions.md
3270
- ├── rules-bmad-pm/
3271
- │ └── 01-pm-instructions.md
3272
- ├── rules-bmad-architect/
3273
- │ └── 01-architect-instructions.md
3274
- ├── rules-bmad-dev/
3275
- │ └── 01-dev-instructions.md
3276
- ├── rules-bmad-qa/
3277
- │ └── 01-qa-instructions.md
3278
- └── rules-bmad-sm/
3279
- └── 01-sm-instructions.md
3280
- ```
3281
-
3282
- **Given** a BMAD mode is activated in Roo Code
3283
- **When** the mode loads
3284
- **Then** both the general rules (`.roo/rules/`) AND the mode-specific rules (`.roo/rules-bmad-{slug}/`) are loaded into the system prompt
3285
-
3286
- **Given** mode-specific rules already exist
3287
- **When** the installer re-runs
3288
- **Then** BMAD-generated rule files are updated in place
3289
- **And** user-added rule files in the same directory are preserved
3290
-
3291
- **Technical notes:**
3292
- - Mode-specific rules complement the `customInstructions` in `.roomodes` — they provide additional context without bloating the mode definition
3293
- - Each rule file should contain the BMAD planning instruction specific to that agent's role
3294
- - Use `01-` prefix for BMAD rules to allow users to add `00-` or `02-` for their own rules
3295
- - Files should be prefixed with BMAD markers for clean identification and update
3296
-
3297
- ### Story 18.7: Cline-to-Roo Code Migration Path
3298
-
3299
- As a **Developer**,
3300
- I want an automated migration from Cline to Roo Code configuration,
3301
- So that my existing BMAD/Cline setup transfers seamlessly when I switch to Roo Code.
3302
-
3303
- **Acceptance Criteria:**
3304
-
3305
- **Given** a project has Cline configuration (`.cline/skills/`, `.clinerules/`)
3306
- **When** the user runs `ma-agents migrate cline-to-roo`
3307
- **Then** skills from `.cline/skills/` are copied to `.roo/skills/`
3308
- **And** `.clinerules` content is converted to `.roo/rules/` files
3309
- **And** MANIFEST.yaml is regenerated for `.roo/skills/`
3310
- **And** a summary of migrated items is displayed
3311
-
3312
- **Given** a project has both Cline and Roo Code configurations
3313
- **When** migration is attempted
3314
- **Then** the CLI warns about existing Roo Code config
3315
- **And** prompts the user to confirm overwrite or skip
3316
-
3317
- **Given** the migration completes
3318
- **When** the user opens Roo Code
3319
- **Then** all previously-installed BMAD skills are available
3320
- **And** planning instructions are loaded from `.roo/rules/`
3321
-
3322
- **Technical notes:**
3323
- - Roo Code natively supports `.clinerules` fallback, but migrating explicitly to `.roo/` is cleaner
3324
- - Migration should update the ma-agents manifest (`.ma-agents.json`) to replace `cline` with `roo-code` in the agents list
3325
- - The `bmad-method` installer's cleanup for Cline already removes `.clinerules/workflows` — migration should run before cleanup
3326
-
3327
- ### Story 18.8: End-to-End Validation and Test Coverage
3328
-
3329
- As a **QA Engineer**,
3330
- I want comprehensive test coverage for the Roo Code integration,
3331
- So that all Roo Code integration points are validated and regression-protected.
3332
-
3333
- **Acceptance Criteria:**
3334
-
3335
- **Given** the Roo Code agent is registered in `agents.js`
3336
- **When** unit tests run
3337
- **Then** tests verify:
3338
- - `getAgent('roo-code')` returns the correct agent object
3339
- - `getProjectPath()` returns `.roo/skills` path
3340
- - `getGlobalPath()` returns OS-specific paths
3341
- - `fileExtension` is `.md`
3342
- - `template` is `generic`
3343
- - `instructionFiles` contains `.roo/rules/00-ma-agents.md`
3344
-
3345
- **Given** the installer targets Roo Code
3346
- **When** integration tests run
3347
- **Then** tests verify:
3348
- - Skills are installed to `.roo/skills/{id}/SKILL.md`
3349
- - `MANIFEST.yaml` is generated in `.roo/skills/`
3350
- - Planning instructions are written to `.roo/rules/00-ma-agents.md`
3351
- - Idempotent re-runs update markers without duplicating content
3352
- - Uninstall removes skill directories and the ma-agents rule file
3353
-
3354
- **Given** the `.roomodes` generation runs
3355
- **When** integration tests execute
3356
- **Then** tests verify:
3357
- - `.roomodes` is valid YAML
3358
- - Each BMAD mode has required fields: `slug`, `name`, `roleDefinition`
3359
- - BMAD mode slugs start with `bmad-`
3360
- - User modes are preserved during regeneration
3361
- - Tool group permissions match agent role expectations
3362
-
3363
- **Given** slash commands are generated
3364
- **When** integration tests execute
3365
- **Then** tests verify:
3366
- - Files exist in `.roo/commands/` with correct naming
3367
- - Each file has valid YAML frontmatter
3368
- - The `mode` field references a valid BMAD mode slug
3369
- - Agent activation instructions reference valid agent file paths
3370
-
3371
- **Technical notes:**
3372
- - Follow the existing test patterns in the project
3373
- - Tests should cover both install and uninstall flows
3374
- - Mock the file system for unit tests, use temp directories for integration tests
3375
-
3376
- ---
3377
-
3378
- ### Epic 18 — Cross-Epic Notes
3379
-
3380
- **Relationship to Cline (Epic N/A):**
3381
- Roo Code is a fork of Cline. The existing Cline support (`id: 'cline'` in agents.js) should be preserved — they are separate IDEs. Story 18.7 provides an explicit migration path.
3382
-
3383
- **Relationship to bmad-method upstream:**
3384
- The `bmad-method` npm package already has `roo` in `platform-codes.yaml` and can generate skills to `.roo/skills/`. Stories 18.4-18.6 extend this with Roo-specific features (modes, rules, commands) that go beyond the standard skill format.
3385
-
3386
- **Development Execution Order:**
3387
- 1. Story 18.1 (agents.js) — no dependencies
3388
- 2. Story 18.2 (BMAD config) — no dependencies
3389
- 3. Story 18.3 (installer rules injection) — depends on 18.1
3390
- 4. Story 18.4 (.roomodes generation) — depends on 18.2
3391
- 5. Story 18.5 (slash commands) — depends on 18.4
3392
- 6. Story 18.6 (mode-specific rules) — depends on 18.4
3393
- 7. Story 18.7 (Cline migration) — depends on 18.1, 18.3
3394
- 8. Story 18.8 (validation/tests) — depends on all above
3395
-
3396
- ---
3397
-
3398
- ## Epic 19: BMAD Knowledge Graph (Phase 3)
3399
-
3400
- Every planning and implementation artifact generated by BMAD skills is automatically woven into a non-hierarchical knowledge graph stored as `_bmad-output/knowledge-graph.json`. Any-to-any directed relationships (not just parent-child traceability) are captured with full provenance. Engineers can open an interactive visualization of the entire project knowledge graph — navigating to any document at the specific heading where a concept is defined — via the `open-graph` skill.
3401
-
3402
- ### Story 19.1: Knowledge Graph Core Library (`emitToGraph`)
3403
-
3404
- As a **Chief Architect**,
3405
- I want a shared `emitToGraph()` utility function in the BMAD extension module,
3406
- So that all BMAD skills can emit nodes and edges to the knowledge graph using a single consistent API without duplicating file I/O logic.
3407
-
3408
- **Acceptance Criteria:**
3409
-
3410
- **Given** the function `emitToGraph(projectRoot, emission)` is called with a valid emission payload
3411
- **When** `_bmad-output/knowledge-graph.json` does not yet exist
3412
- **Then** the function creates the file with a valid four-section structure: `meta`, `files`, `nodes`, `edges`
3413
- **And** `meta` contains `schema_version: "1.0"`, `generated_at` (ISO timestamp), `project` (derived from package.json name or directory name), `file_count: 0`, `node_count: 0`, `edge_count: 0`
3414
- **And** `files`, `nodes`, `edges` are initialized as empty object, empty array, empty array respectively
3415
-
3416
- **Given** `knowledge-graph.json` already exists with prior content
3417
- **When** `emitToGraph()` is called
3418
- **Then** it reads the existing file, appends new files/nodes/edges, updates counts in `meta`, and writes the result back atomically
3419
- **And** no existing nodes, edges, or file registrations are deleted or overwritten
3420
-
3421
- **Given** an emission payload includes a `files` entry with `pointer_type: "relative_path"`
3422
- **When** that file-id does not yet exist in the `files` table
3423
- **Then** the file is registered: `files[file-id] = { pointer, title, pointer_type }`
3424
- **And** if the file-id already exists, registration is skipped (first-write-wins)
3425
-
3426
- **Given** an emission payload includes a node with id `file-id#heading-anchor`
3427
- **When** a node with that id already exists in `nodes`
3428
- **Then** the node is not duplicated
3429
-
3430
- **Given** an emission payload includes an edge with `(from, to, type)` triple
3431
- **When** an edge with the same `(from, to, type)` already exists in `edges`
3432
- **Then** the edge is not duplicated (provenance of the first edge is preserved)
3433
-
3434
- **Given** the function writes the updated graph
3435
- **When** the write operation completes
3436
- **Then** `meta.file_count`, `meta.node_count`, `meta.edge_count` reflect the total counts in the file
3437
-
3438
- **Technical notes:**
3439
- - Implement in `lib/bmad-extension/skills/` as a shared utility module (e.g., `lib/knowledge-graph/emit.js`)
3440
- - Heading anchor derivation: `heading.toLowerCase().replace(/[^\w\s-]/g, '').replace(/\s+/g, '-')` (GitHub slug algorithm)
3441
- - File path for graph: always `path.join(projectRoot, '_bmad-output', 'knowledge-graph.json')`
3442
- - Use synchronous file I/O (`fs.readFileSync` / `fs.writeFileSync`) — graph updates happen after artifact generation, not in hot paths
3443
- - JSON serialization: `JSON.stringify(graph, null, 2)` for human-readable output
3444
- - FRs: FR141, FR142, FR143, FR144, FR145, FR146, FR147, FR148
3445
- - NFRs: NFR39 (LLM-writability — flat structure, copy-pattern extension), NFR40 (additive-only)
3446
-
3447
- ### Story 19.2: Graph Emission — `create-prd` (Graph Seed)
3448
-
3449
- As a **Product Manager**,
3450
- I want the `create-prd` skill to automatically seed the knowledge graph when a PRD is generated,
3451
- So that the PRD becomes the root of the project knowledge graph without any user action.
3452
-
3453
- **Acceptance Criteria:**
3454
-
3455
- **Given** the `create-prd` skill completes generation of `_bmad-output/planning-artifacts/prd.md`
3456
- **When** the artifact write step finishes
3457
- **Then** `emitToGraph()` is called silently as the final step — no user prompt, no output message
3458
- **And** the PRD file is registered in the `files` table as `{ pointer: "_bmad-output/planning-artifacts/prd.md", title: "Product Requirements Document", pointer_type: "relative_path" }` with file-id `prd`
3459
-
3460
- **Given** the PRD contains top-level `##` headings (e.g., `## Executive Summary`, `## Functional Requirements`)
3461
- **When** emission runs
3462
- **Then** one node is emitted per heading: `{ id: "prd#executive-summary", file: "prd", anchor: "executive-summary", title: "Executive Summary", type: "prd" }`
3463
-
3464
- **Given** the graph is seeded from a new PRD
3465
- **When** the `knowledge-graph.json` file is inspected
3466
- **Then** it contains no edges (PRD is the root — it does not reference other documents yet)
3467
- **And** `meta.node_count` equals the number of `##` headings in the PRD
3468
-
3469
- **Given** `create-prd` runs on a project where `knowledge-graph.json` already exists
3470
- **When** emission runs
3471
- **Then** only new headings (not yet present as nodes) are added — re-runs are idempotent
3472
-
3473
- **Technical notes:**
3474
- - Extract headings by scanning the generated markdown for `^## ` lines
3475
- - Emit only level-2 (`##`) headings as nodes — level-3+ create noise without adding navigation value
3476
- - The PRD seeding call is the only emission that produces zero edges — all other skills emit edges pointing back to PRD nodes
3477
- - FRs: FR149, FR150, FR151, FR152
3478
-
3479
- ### Story 19.3: Graph Emission — `create-architecture` and `create-epics-and-stories`
3480
-
3481
- As a **Chief Architect** and **Product Manager**,
3482
- I want the `create-architecture` and `create-epics-and-stories` skills to emit traceability edges to the knowledge graph automatically,
3483
- So that every architectural decision and every epic traces back to the PRD sections that motivated it.
3484
-
3485
- **Acceptance Criteria:**
3486
-
3487
- **Given** the `create-architecture` skill completes generation of `_bmad-output/planning-artifacts/architecture.md`
3488
- **When** emission runs
3489
- **Then** the architecture file is registered as file-id `arch` with `pointer_type: "relative_path"`
3490
- **And** one node is emitted per `##` heading in architecture.md (type: `architecture`)
3491
- **And** for each architecture decision section (headings matching `## Decision` or similar), an `implements` edge is emitted: `{ from: "arch#decision-slug", to: "prd#relevant-fr-section", type: "implements", label: "implements PRD requirement", created_by: <user>, agent: <agent-id>, created_at: <timestamp> }`
3492
-
3493
- **Given** the `create-architecture` skill is run when PRD nodes do not yet exist in the graph
3494
- **When** an edge references a PRD node that is not yet in `nodes`
3495
- **Then** a stub node is emitted for the referenced PRD heading so the edge is not orphaned
3496
- **And** the stub node carries `type: "prd"` and the correct `file` and `anchor` fields
3497
-
3498
- **Given** the `create-epics-and-stories` skill completes updating `_bmad-output/planning-artifacts/epics.md`
3499
- **When** emission runs
3500
- **Then** the epics file is registered as file-id `epics` with `pointer_type: "relative_path"`
3501
- **And** one node is emitted per epic heading (type: `epic`)
3502
- **And** for each epic, a `derives-from` edge is emitted to the PRD Functional Requirements node: `{ from: "epics#epic-N-name", to: "prd#functional-requirements", type: "derives-from", ... }`
3503
- **And** where an epic was informed by an architecture decision, an `informed-by` edge is also emitted: `{ from: "epics#epic-N-name", to: "arch#decision-slug", type: "informed-by", ... }`
3504
-
3505
- **Technical notes:**
3506
- - The `informed-by` edge is the non-hierarchical edge type — it captures cross-domain influence (an epic shaped by an architectural decision, not just a PRD section)
3507
- - Architecture decision headings can be detected by scanning for `## Decision` or `## P[0-9]-[0-9]` patterns (architecture doc convention)
3508
- - Epic headings can be detected by scanning for `## Epic [0-9]+:` pattern
3509
- - Emit after the file write step completes; `created_by` is read from BMAD config (user name); `agent` is the BMAD agent identity string from the skill context
3510
- - FRs: FR149, FR150, FR151, FR152
3511
-
3512
- ### Story 19.4: Graph Emission — `create-story`, `validate-prd`, `dev-story`, `bmad-sprint-planning`
3513
-
3514
- As a **Developer** and **QA Engineer**,
3515
- I want individual story files and validation artifacts to emit traceability edges automatically,
3516
- So that the knowledge graph captures the full SDLC chain from PRD through architecture through epics through stories through implementation.
3517
-
3518
- **Acceptance Criteria:**
3519
-
3520
- **Given** the `create-story` skill generates a story file (e.g., `_bmad-output/implementation-artifacts/17-9-unified-sprint-status-schema.md`)
3521
- **When** emission runs
3522
- **Then** the story file is registered in the `files` table with `pointer_type: "relative_path"` and a file-id derived from the story number (e.g., `story-17-9`)
3523
- **And** a node is emitted for the story root heading (type: `story`)
3524
- **And** a `traces-to` edge is emitted from the story node to its parent epic node: `{ from: "story-17-9#story-title", to: "epics#epic-17-sprint-management", type: "traces-to", ... }`
3525
- **And** if the story's technical notes reference architecture decisions, `informed-by` edges are emitted from the story node to the relevant architecture nodes
3526
-
3527
- **Given** the `validate-prd` skill completes a validation report
3528
- **When** emission runs
3529
- **Then** the validation report file is registered with file-id `validation-<date>`
3530
- **And** a `validates` edge is emitted from the validation report node to `prd#functional-requirements`: `{ type: "validates", label: "PRD validation report <date>", ... }`
3531
-
3532
- **Given** `dev-story` completes implementation guidance for a story
3533
- **When** emission runs
3534
- **Then** an `informed-by` edge is emitted from the story node to `arch#implementation-notes` (or the most relevant architecture section)
3535
-
3536
- **Given** `bmad-sprint-planning` completes sprint plan generation
3537
- **When** emission runs
3538
- **Then** sprint plan nodes are emitted and `derives-from` edges connect them to the relevant epic nodes
3539
-
3540
- **Technical notes:**
3541
- - Story file-ids use the format `story-<epic-number>-<story-number>` (derived from the file path)
3542
- - The 7 skills emitting to the graph: `create-prd`, `create-architecture`, `create-epics-and-stories`, `create-story`, `validate-prd`, `dev-story`, `bmad-sprint-planning`
3543
- - All emission calls are identical in structure: call `emitToGraph(projectRoot, emission)` at the end of the artifact write step
3544
- - FRs: FR149, FR150, FR151, FR152
3545
-
3546
- ### Story 19.5: `open-graph` Skill
3547
-
3548
- As an **Engineer**,
3549
- I want to run `/open-graph` in any BMAD agent,
3550
- So that the knowledge graph visualization opens in VSCode (as a webview) or in my default browser when outside VSCode — without any additional configuration.
3551
-
3552
- **Acceptance Criteria:**
3553
-
3554
- **Given** `open-graph` is invoked inside VSCode (detected via `process.env.TERM_PROGRAM === 'vscode'` or `process.env.VSCODE_PID !== undefined`)
3555
- **When** the skill runs
3556
- **Then** it generates `_bmad-output/knowledge-graph.html` (if not already current) from the JSON data
3557
- **And** opens the HTML file via VSCode's `vscode.env.openExternal(Uri.file(...))` API or equivalent open command
3558
-
3559
- **Given** `open-graph` is invoked outside VSCode (standard terminal)
3560
- **When** the skill runs
3561
- **Then** it generates `knowledge-graph.html` from the current JSON data
3562
- **And** opens it using the platform-appropriate command: `start` (Windows), `open` (macOS), `xdg-open` (Linux)
3563
-
3564
- **Given** `_bmad-output/knowledge-graph.json` does not exist
3565
- **When** `open-graph` is invoked
3566
- **Then** the skill informs the user that no knowledge graph data has been generated yet
3567
- **And** suggests running a BMAD planning skill to seed the graph
3568
-
3569
- **Given** `knowledge-graph.html` already exists and is newer than `knowledge-graph.json`
3570
- **When** `open-graph` is invoked
3571
- **Then** the skill skips regeneration and opens the existing HTML directly
3572
-
3573
- **Technical notes:**
3574
- - Skill location: `lib/bmad-extension/skills/open-graph/`
3575
- - Skill files: `SKILL.md` (agent instruction), `skill.json` (metadata), `generate-html.js` (HTML renderer generator)
3576
- - The `generate-html.js` script reads the JSON, inlines the data as a JavaScript literal, and writes the self-contained HTML file
3577
- - `always_load: false` — this is an on-demand skill, not a mandatory load
3578
- - Add `open-graph` to the BMAD extension module's MANIFEST.yaml
3579
- - FR: FR153
3580
-
3581
- ### Story 19.6: Interactive Visualization Renderer
3582
-
3583
- As an **Engineer**,
3584
- I want the knowledge graph HTML file to render an interactive, navigable visualization of all project artifacts and their relationships,
3585
- So that I can explore cross-document traceability visually and jump directly to any document section from the graph.
3586
-
3587
- **Acceptance Criteria:**
3588
-
3589
- **Given** `knowledge-graph.html` is opened in a browser or VSCode webview
3590
- **When** the graph renders
3591
- **Then** each node appears as a circle color-coded by document type:
3592
- - `prd` → blue
3593
- - `architecture` → orange
3594
- - `epic` → green
3595
- - `story` → teal
3596
- - `decision` → purple
3597
- - `validation` → red
3598
- **And** directed edges are rendered as arrows with the edge type as a label
3599
- **And** the initial render completes within 3 seconds for graphs up to 500 nodes and 1000 edges (NFR38)
3600
-
3601
- **Given** the user clicks a node
3602
- **When** the click handler fires
3603
- **Then** the node's source document opens at the specific heading anchor via the IDE's file protocol or a browser file URL
3604
-
3605
- **Given** the user hovers over an edge
3606
- **When** the tooltip renders
3607
- **Then** it displays: edge type, label, created_by, agent, created_at (FR155)
3608
-
3609
- **Given** the user selects a node
3610
- **When** the selection occurs
3611
- **Then** the immediate neighbors (one hop in either direction) are highlighted
3612
- **And** non-neighbor nodes and edges are dimmed (FR156)
3613
-
3614
- **Given** the user uses the filter controls
3615
- **When** a node type or edge type is deselected
3616
- **Then** nodes and edges of that type are hidden from the visualization
3617
- **And** re-selecting them restores visibility (FR156)
3618
-
3619
- **Given** the HTML file is opened in an air-gapped environment with no network access
3620
- **When** the page loads
3621
- **Then** the graph renders identically to a connected environment — no CDN requests, no external fonts, no script fetches (FR157, NFR41)
3622
-
3623
- **Technical notes:**
3624
- - All JavaScript and CSS are inlined in the HTML file — no external dependencies
3625
- - Graph data is embedded as a `const GRAPH_DATA = {...}` literal at generation time (not fetched at runtime)
3626
- - Use SVG for node and edge rendering — no canvas required, simpler interaction model
3627
- - Pre-compute the first 100 physics ticks at generation time to arrive at a stable initial layout (avoids animation jitter on open)
3628
- - The renderer is approximately 300-500 lines of vanilla JS — no framework, no bundler
3629
- - Node positioning: simple force-directed simulation using Coulomb repulsion + spring attraction
3630
- - FRs: FR154, FR155, FR156, FR157
3631
- - NFRs: NFR38, NFR41
3632
-
3633
- ### Story 19.7: LLM-Writability Contract Validation and Integration Tests
3634
-
3635
- As a **Chief Architect**,
3636
- I want the knowledge graph JSON format validated against the LLM-writability contract and covered by integration tests,
3637
- So that we can verify that any LLM can extend the graph by copying existing patterns, and that the additive-only semantics are enforced.
3638
-
3639
- **Acceptance Criteria:**
3640
-
3641
- **Given** a `knowledge-graph.json` file with one existing node and one existing edge
3642
- **When** an LLM is instructed to add a new node and a new edge by copying the existing patterns (no external schema provided)
3643
- **Then** the resulting JSON is valid and passes `emitToGraph()` ingestion without errors
3644
- **And** the existing node and edge are preserved unchanged (NFR40)
3645
-
3646
- **Given** `emitToGraph()` is called with a node id that already exists in `nodes`
3647
- **When** the function completes
3648
- **Then** `nodes` contains exactly one entry with that id (no duplicate)
3649
- **And** the original node's fields are unchanged
3650
-
3651
- **Given** `emitToGraph()` is called with an edge `(from, to, type)` triple that already exists
3652
- **When** the function completes
3653
- **Then** `edges` contains exactly one entry with that triple (no duplicate)
3654
- **And** the original edge's provenance (created_by, agent, created_at) is unchanged
3655
-
3656
- **Given** a graph with 500 nodes and 1000 edges
3657
- **When** `emitToGraph()` adds one new node and one new edge
3658
- **Then** the operation completes in under 1 second
3659
-
3660
- **Given** the full emission sequence is run (all 7 skills emit in order)
3661
- **When** the resulting `knowledge-graph.json` is inspected
3662
- **Then** all emitted nodes are present
3663
- **And** all emitted edges are present with correct provenance
3664
- **And** `meta.file_count`, `meta.node_count`, `meta.edge_count` are accurate
3665
-
3666
- **Technical notes:**
3667
- - Tests live in `tests/knowledge-graph/` following the existing test structure
3668
- - Use temp directories for all file I/O in tests
3669
- - The LLM-writability test can use a fixture JSON and verify that extending it by hand-editing produces valid output
3670
- - Test the VSCode detection logic with environment variable mocks
3671
- - NFRs: NFR39 (LLM-writability), NFR40 (additive-only)
3672
-
3673
- ---
3674
-
3675
- ### Epic 19 — Cross-Epic Notes
3676
-
3677
- **Relationship to Epic 15 (BMAD 6.2.1 Migration):**
3678
- The `open-graph` skill deploys as a BMAD extension skill following the 6.2.1 module structure established by Epic 15. Epic 15 must be complete before Story 19.5.
3679
-
3680
- **Relationship to Epic 17 (Sprint Management):**
3681
- `bmad-sprint-planning` is one of the 7 skills that emit to the knowledge graph. Epic 17 must be complete (skill structure settled) before Story 19.4 wires in sprint planning emission.
3682
-
3683
- **Relationship to Epic 7 (Test Suite):**
3684
- Story 19.7 integration tests follow the test infrastructure from Epic 7. Epic 7 is on hold, so Story 19.7 uses the existing Node.js test runner pattern directly.
3685
-
3686
- **File outputs produced by this epic:**
3687
- ```
3688
- _bmad-output/
3689
- ├── knowledge-graph.json ← graph data (generated by Stories 19.2-19.4)
3690
- └── knowledge-graph.html ← self-contained renderer (generated by Story 19.5/19.6)
3691
-
3692
- lib/
3693
- ├── knowledge-graph/
3694
- │ └── emit.js ← shared emitToGraph() utility (Story 19.1)
3695
- └── bmad-extension/
3696
- └── skills/
3697
- └── open-graph/ ← new BMAD extension skill (Story 19.5)
3698
- ├── SKILL.md
3699
- ├── skill.json
3700
- └── generate-html.js
3701
- ```
3702
-
3703
- **Development Execution Order:**
3704
- 1. Story 19.1 (core library) — no dependencies; establish before any emission story
3705
- 2. Story 19.2 (create-prd emission) — depends on 19.1
3706
- 3. Story 19.3 (create-architecture + create-epics-and-stories emission) — depends on 19.1; can run in parallel with 19.2
3707
- 4. Story 19.4 (create-story + remaining emission) — depends on 19.1; can run in parallel with 19.2 and 19.3
3708
- 5. Story 19.5 (open-graph skill) — depends on 19.1 (needs the generate-html logic)
3709
- 6. Story 19.6 (visualization renderer) — depends on 19.5 (renderer is invoked by open-graph skill)
3710
- 7. Story 19.7 (LLM contract validation + tests) — depends on all above
3711
-
3712
- ---
3713
-
3714
- ## Epic 20: Software Quality Assurance (SQA) Agent — Gad (Phase 3)
3715
-
3716
- **Goal:** Deliver a dedicated Software Quality Assurance agent (Gad) that provides structured quality workflows for projects managed with the ma-agents/BMAD stack. The agent presents a menu of quality-focused workflows; the initial release includes a multi-dimensional Project Audit and an IEEE/ISO/IEC 12207 lifecycle process compliance assessment.
3717
-
3718
- **Value:** Closes the quality verification gap in the BMAD lifecycle. Today there is no agent that looks across planning artifacts, sprint state, and process compliance together. Gad gives quality engineers and project managers a single entry point to answer "how healthy is this project, really?" and "does this project meet recognized lifecycle standards?"
3719
-
3720
- **PRD Coverage:** FR158–FR171, NFR42–NFR43 (Architecture Decision P3-2)
3721
-
3722
- **Status:** Planned
3723
-
3724
- **Dependencies:**
3725
- - Epic 15 (BMAD 6.2.0 Agent Architecture Migration) must be complete — Gad's skills use the P2-9 BMAD 6.2.0 skill folder pattern
3726
- - Epic 11 (Bug Management System) must be complete — Story 20.3 invokes `create-bug-story` for gap remediation (FR171)
3727
-
3728
- ---
3729
-
3730
- ### Story 20.1 — SQA Agent Skill: Gad Persona and Menu
3731
-
3732
- **As a** quality engineer,
3733
- **I want** to activate the Gad SQA agent from within a BMAD session,
3734
- **so that** I have a dedicated quality assurance persona with a structured menu of QA workflows available.
3735
-
3736
- **Acceptance Criteria:**
3737
-
3738
- 1. `lib/bmad-extension/skills/bmad-ma-agent-sqa/SKILL.md` exists and fully defines the Gad agent persona: role, identity, communication style, and principles
3739
- 2. `lib/bmad-extension/skills/bmad-ma-agent-sqa/bmad-skill-manifest.yaml` exists with `type: agent`, `name: bmad-ma-agent-sqa`, `displayName: Gad`, `title: Software Quality Assurance Expert`, and `module: ma-skills`
3740
- 3. The SKILL.md activation sequence follows the standard BMAD 6.2.0 agent pattern: load config.yaml → greet user → display menu → wait for input → dispatch to skill
3741
- 4. The menu includes at minimum: Redisplay Menu Help (MH), Chat (CH), Project Audit (AU → `sqa-audit`), IEEE 12207 Compliance (IC → `sqa-ieee12207`), Dismiss Agent (DA)
3742
- 5. `lib/bmad-extension/module-help.csv` contains an entry for `bmad-ma-agent-sqa` in the `anytime` phase under module `ma-skills`
3743
- 6. `lib/bmad-extension/skills/bmad-ma-agent-sqa/.gitkeep` exists
3744
- 7. `test/extension-module-restructure.test.js` includes `bmad-ma-agent-sqa` in the expected agent skills array and passes
3745
-
3746
- **Technical Notes:**
3747
- - Gad binds to the `bmm-qa` BMAD built-in agent persona — no new BMAD agent slot is created
3748
- - Communication style: clear, precise, structured; findings always include severity levels; observations distinguished from blocking issues
3749
- - No new BMAD agent host customization files needed — the `lib/bmad-customize/bmm-qa.customize.yaml` existing skill-enforcement hooks are sufficient
3750
-
3751
- ---
3752
-
3753
- ### Story 20.2 — Project Audit Workflow Skill
3754
-
3755
- **As a** quality engineer,
3756
- **I want** Gad to run a structured project audit across multiple quality dimensions,
3757
- **so that** I can identify gaps in traceability, process compliance, sprint health, and release readiness in a single structured session.
3758
-
3759
- **Acceptance Criteria:**
3760
-
3761
- 1. `lib/bmad-extension/skills/sqa-audit/SKILL.md` exists and implements the full five-step audit workflow:
3762
- - Step 1: Scope selection — asks full vs. partial, lists all five dimensions by number, waits for user input
3763
- - Step 2: Data collection — reads all required artifacts, reports which were found vs. missing before proceeding
3764
- - Step 3: Executes only the selected dimensions (1–5 as described below)
3765
- - Step 4: Compiles a full audit report in the specified format
3766
- - Step 5: Saves the report to `{output_folder}/sqa-audit-report-{YYYY-MM-DD}.md` and confirms the path to the user
3767
- 2. Dimension 1 (Code ↔ Stories): reads done/in-progress items from sprint-status.yaml, lists each story with traceability status, flags stories with no code evidence and code with no story
3768
- 3. Dimension 2 (Stories ↔ Architecture/PRD): produces a PRD coverage table (COVERED / MISSING / PARTIAL per requirement) and an architecture compliance issue list
3769
- 4. Dimension 3 (Process Compliance): evaluates commit convention adherence, branch discipline, test file presence, and code review evidence; produces a checklist with PASS / FAIL / UNKNOWN per item
3770
- 5. Dimension 4 (Sprint Health): produces a per-sprint summary table (total, done, in-progress, not started, completion %) and flags stalled items, blockers, and backlog grooming issues
3771
- 6. Dimension 5 (Release State): produces a READY / AT RISK / NOT READY release readiness summary, lists blocking items, and records deployment status per environment as provided by the user
3772
- 7. Report format: executive summary → per-dimension findings with severity (FAIL / WARNING / PASS) → prioritized action items table → skipped dimensions with required artifacts
3773
- 8. Severity aggregation: any FAIL → overall FAIL; no FAIL but any WARNING → WARNING; all PASS or SKIPPED → PASS
3774
- 9. After saving the report, Gad asks the user if they want to drill into any finding or take action on issues (FR171 gap remediation offered for FAIL items)
3775
- 10. `lib/bmad-extension/skills/sqa-audit/bmad-skill-manifest.yaml` exists with `type: skill`, `name: sqa-audit`, `module: ma-skills`
3776
- 11. `lib/bmad-extension/module-help.csv` contains an entry for `sqa-audit` in the `4-implementation` phase under module `ma-skills`
3777
- 12. `test/extension-module-restructure.test.js` includes `sqa-audit` in `expectedSqaSkills` and passes
3778
-
3779
- **Technical Notes:**
3780
- - Required artifact reads: `_bmad/bmm/config.yaml` (resolve output_folder), `prd.md`, `architecture.md`, `epics.md`, `sprint-status.yaml`; optional: `project-context.md`
3781
- - Dimension skips gracefully when an artifact is missing — produces a SKIPPED entry in the report with the artifact path that was not found
3782
- - Report is saved as markdown; no HTML or external rendering required
3783
-
3784
- ---
3785
-
3786
- ### Story 20.3 — IEEE/ISO/IEC 12207 Compliance Workflow Skill
3787
-
3788
- **As a** quality engineer or project manager,
3789
- **I want** Gad to evaluate the project's compliance with IEEE/ISO/IEC 12207:2017,
3790
- **so that** I have a structured compliance posture report with gap analysis and recommended corrective actions.
3791
-
3792
- **Acceptance Criteria:**
3793
-
3794
- 1. `lib/bmad-extension/skills/sqa-ieee12207/SKILL.md` exists and implements the full five-step compliance workflow:
3795
- - Step 1: Scope selection — presents the four process groups, asks full vs. selected, waits for user input
3796
- - Step 2: Data collection — reads all required artifacts, reports found vs. missing
3797
- - Step 3: Evaluates all 23 process areas in selected groups with per-area ratings
3798
- - Step 4: Compiles the compliance matrix report in the specified format
3799
- - Step 5: Saves the report to `{output_folder}/sqa-ieee12207-report-{YYYY-MM-DD}.md`, confirms path, and offers to create backlog stories for P1 gaps (FR171)
3800
- 2. The four process groups and their process areas are correctly modeled in the SKILL.md:
3801
- - Technical Processes (11 areas: 6.4.1–6.4.11)
3802
- - Technical Management Processes (8 areas: 6.3.1–6.3.8)
3803
- - Agreement Processes (2 areas: 6.1.1–6.1.2)
3804
- - Organizational Enabling Processes (2 areas: 6.2.1, 6.2.7)
3805
- 3. Each evaluated process area maps to specific project artifacts as evidence sources (e.g., 6.4.2 Stakeholder Requirements → prd.md; 6.3.5 Configuration Management → git history, CHANGELOG, version files)
3806
- 4. Each area receives one of five ratings: COMPLIANT, PARTIAL, NON-COMPLIANT, NOT APPLICABLE, ORGANIZATION-SCOPE — with the rating justified by evidence found or absent
3807
- 5. Report includes: executive summary, per-group compliance matrix (clause | process area | rating | key evidence | gaps), gap analysis (critical gaps vs. partial compliance), prioritized recommended-action table (priority, action, clause, effort), compliance summary table (counts per group + overall compliance percentage)
3808
- 6. When the user confirms gap-to-story creation, Gad iterates over P1 (NON-COMPLIANT) gaps and offers to invoke `create-bug-story` for each — one story per gap
3809
- 7. All evaluation logic and process area definitions are embedded in SKILL.md — no network access required (NFR43)
3810
- 8. `lib/bmad-extension/skills/sqa-ieee12207/bmad-skill-manifest.yaml` exists with `type: skill`, `name: sqa-ieee12207`, `module: ma-skills`
3811
- 9. `lib/bmad-extension/module-help.csv` contains an entry for `sqa-ieee12207` in the `4-implementation` phase under module `ma-skills`
3812
- 10. `test/extension-module-restructure.test.js` includes `sqa-ieee12207` in `expectedSqaSkills` and passes
3813
-
3814
- **Technical Notes:**
3815
- - The workflow is a compliance *posture* assessment, not a formal certification — it produces a structured report based on available project artifacts; it makes no claim of organizational-level ISO certification
3816
- - Organizational Enabling Processes (Group 4) are assessed from project artifacts only where possible; remaining items are automatically rated ORGANIZATION-SCOPE with a note explaining what organizational evidence would be needed
3817
- - Gap-to-story creation is optional and per-item — the user can accept or skip each P1 gap individually
3818
-
3819
- ---
3820
-
3821
- ### Story 20.4 — Test Suite Update for SQA Skills
3822
-
3823
- **As a** developer,
3824
- **I want** the extension module restructure test to verify the SQA skills exist and are registered,
3825
- **so that** future changes that accidentally remove or misconfigure SQA skills are caught by the automated test suite.
3826
-
3827
- **Acceptance Criteria:**
3828
-
3829
- 1. `test/extension-module-restructure.test.js` includes `expectedSqaSkills = ['sqa-audit', 'sqa-ieee12207']`
3830
- 2. `bmad-ma-agent-sqa` is included in `expectedAgentSkills`
3831
- 3. All skill directory count tests are updated to reflect the 3 new directories (agent + 2 workflow skills): total skill count is previous count + 3
3832
- 4. All CSV row count tests are updated to reflect the 3 new `module-help.csv` entries: total CSV row count is previous count + 3
3833
- 5. New test `'all 2 SQA skill directories exist'` verifies both `sqa-audit` and `sqa-ieee12207` directories exist in `lib/bmad-extension/skills/`
3834
- 6. New test `'CSV has entries for all 2 SQA skills'` verifies both workflow skills are in `module-help.csv`
3835
- 7. All tests in `test/extension-module-restructure.test.js` pass with 0 failures after these changes
3836
-
3837
- **Technical Notes:**
3838
- - This story has no runtime behavior — it is test-only
3839
- - The `.gitkeep` files required in each new skill directory must be present for the existing `.gitkeep` coverage test to pass
3840
-
3841
- ---
3842
-
3843
- ### Epic 20 — Cross-Epic Notes
3844
-
3845
- **Relationship to Epic 15 (BMAD 6.2.0 Agent Architecture Migration):**
3846
- Gad follows the SKILL.md-based agent pattern established by Epic 15. Epic 15 must be complete before Story 20.1 to ensure the agent folder structure and BMAD agent dispatch mechanism are stable.
3847
-
3848
- **Relationship to Epic 11 (Bug Management System):**
3849
- Story 20.3 invokes `create-bug-story` for IEEE 12207 P1 gaps (FR171). Epic 11 must be complete — specifically Story 11.2 (BMAD extension workflow for bug story creation) — before this feature of Story 20.3 is active.
3850
-
3851
- **Relationship to Epic 17 (Sprint Management Model Rework):**
3852
- Story 20.2 reads `sprint-status.yaml` for Sprint Health analysis. The unified schema established by Epic 17 (FR133–FR135) defines the file structure that the audit workflow depends on.
3853
-
3854
- **File outputs produced by this epic:**
3855
- ```
3856
- lib/
3857
- └── bmad-extension/
3858
- └── skills/
3859
- ├── bmad-ma-agent-sqa/
3860
- │ ├── .gitkeep
3861
- │ ├── SKILL.md
3862
- │ └── bmad-skill-manifest.yaml
3863
- ├── sqa-audit/
3864
- │ ├── .gitkeep
3865
- │ ├── SKILL.md
3866
- │ └── bmad-skill-manifest.yaml
3867
- └── sqa-ieee12207/
3868
- ├── .gitkeep
3869
- ├── SKILL.md
3870
- └── bmad-skill-manifest.yaml
3871
-
3872
- _bmad-output/ (generated at runtime, not committed)
3873
- ├── sqa-audit-report-{date}.md
3874
- └── sqa-ieee12207-report-{date}.md
3875
- ```
3876
-
3877
- **Development Execution Order:**
3878
- 1. Story 20.4 (test suite update) — can be written first as a failing test to drive implementation
3879
- 2. Story 20.1 (Gad agent skill) — no dependency on other Epic 20 stories; establishes the agent entry point
3880
- 3. Story 20.2 (Project Audit workflow) — no dependency on 20.1 at the code level; can develop in parallel with 20.1
3881
- 4. Story 20.3 (IEEE 12207 workflow) — no dependency on other Epic 20 stories; can develop in parallel with 20.1 and 20.2
3882
-
3883
-
3884
- ---
3885
-
3886
- ## Epic 21: On-Prem / Local-LLM Tuning (Phase 3)
3887
-
3888
- The primary deployment scenario for ma-agents is an air-gapped enterprise network running a local non-Claude LLM (e.g., Nemotron Super 49B) behind one of the supported coding agents (Claude Code, Cline, Roo Code, OpenCode). Field experience documented in `optimizing-local-llm-coding-agents-bmad.md` shows local LLMs misinterpret Claude-tuned system prompts: they create files when asked questions, dump output into `~/.claude/`, hallucinate Claude Code's `str_replace_editor` tool, skip BMAD planning to start coding, and overthink simple prompts because reasoning mode is on by default. This epic adapts the installer-generated configuration so on-prem installs activate the application-layer guardrails the host tools already provide (Roo Code `fileRegex` restrictions, OpenCode permission gating, Cline Architect mode discipline) and inject local-LLM-aware system prompts.
3889
-
3890
- Two layers are introduced via a single install-time **profile** prompt persisted in `.ma-agents.json`:
3891
-
3892
- - **Universal** (all profiles): expanded per-tool instruction injection enforcing text-vs-file discipline and BMAD phase boundaries; new `.roomodes` template defining 4 BMAD modes with `fileRegex` restrictions; expanded `AGENTS.md` for OpenCode; expanded `.clinerules`.
3893
- - **On-prem** (profile=on-prem only): `/no_think` planning prefix, no-home-dir-writes rule, no-`str_replace_editor` rule, BMAD persona phase-aware system-prompt prefixes.
3894
-
3895
- Inference-server tuning (vLLM flags, quantization) ships as documentation only at `docs/deployment/vllm-nemotron.md` — the installer does not manage the serving stack.
3896
-
3897
- ### Story 21.1: Install-Time Profile Prompt and Persistence
3898
-
3899
- As an **engineer running `npx ma-agents install`**,
3900
- I want the installer to ask whether this is an on-prem / air-gapped install once and remember my answer,
3901
- So that on-prem-specific guardrails activate without me having to remember a CLI flag, and I am not re-prompted on subsequent installs.
3902
-
3903
- **Acceptance Criteria:**
3904
-
3905
- **Given** `npx ma-agents install` runs interactively in a project with no existing `.ma-agents.json` profile entry
3906
- **When** the install wizard reaches the profile step
3907
- **Then** the user is shown the prompt:
3908
- ```
3909
- ? Is this an on-prem / air-gapped install using a local LLM (e.g. Nemotron)?
3910
- > Yes — apply local-LLM guardrails (recommended for non-Claude models)
3911
- No — standard install (Claude on web, Anthropic API, etc.)
3912
- ```
3913
- **And** the chosen value is persisted as `"profile": "on-prem"` or `"profile": "standard"` in `.ma-agents.json`
3914
-
3915
- **Given** `.ma-agents.json` already contains a `"profile"` value from a previous install
3916
- **When** `npx ma-agents install` runs again
3917
- **Then** the prompt is NOT shown
3918
- **And** the persisted profile is used to drive instruction generation
3919
- **And** the resolved profile is logged once at the start of the install (e.g., `Using profile: on-prem (from .ma-agents.json)`)
3920
-
3921
- **Given** `--yes` is passed and there is no persisted profile
3922
- **When** the installer runs
3923
- **Then** the profile defaults to `standard`
3924
- **And** no prompt is shown
3925
- **And** `standard` is persisted to `.ma-agents.json`
3926
-
3927
- **Technical notes:**
3928
- - Implement a new module `lib/profile.js` exposing `getProfile(projectRoot)`, `setProfile(projectRoot, value)`, and `resolveProfile({ persisted, yesMode })`. All call sites (installer, customize-loader) go through this module — no direct reads/writes from elsewhere
3929
- - Wizard prompt uses the same prompt library already used by other install questions (consistent UX)
3930
- - `.ma-agents.json` schema gains an optional top-level `"profile"` field; absence is treated as unset, not as `standard` (forces explicit choice on first install)
3931
-
3932
- ---
3933
-
3934
- ### Story 21.2: Universal Per-Tool Instruction Block Expansion
3935
-
3936
- As a **chief architect**,
3937
- I want the existing `<!-- MA-AGENTS-START -->` injection block to enforce text-vs-file discipline and BMAD phase boundaries for every install (regardless of profile),
3938
- So that all coding agents — even Claude on the web — stop dumping random files as responses and stop skipping BMAD planning to start coding.
3939
-
3940
- **Acceptance Criteria:**
3941
-
3942
- **Given** the universal instruction-block template `lib/templates/instruction-block-universal.template.md`
3943
- **When** the file is created
3944
- **Then** it includes (in addition to the current MANIFEST loading instruction):
3945
- - A "respond in TEXT vs. create FILES" rules section listing concrete keyword triggers (`create`, `write`, `generate`, `build`, `implement` → file action; `what do you think`, `how should we`, `discuss`, `opinion` → text response)
3946
- - An "if unsure, respond in text" default
3947
- - A "never create response.md or output.md as a reply" rule
3948
- - A BMAD phase discipline rule: respect the current phase declared in the conversation; do not skip ahead to implementation during planning
3949
- - A "confirm file paths before writing" rule
3950
-
3951
- **Given** any agent with markdown instruction injection (Claude Code, Cline, Roo Code rules, Cursor, Kilocode, Copilot, Gemini)
3952
- **When** the installer runs (any profile)
3953
- **Then** the universal block content is rendered between `<!-- MA-AGENTS-START -->` / `<!-- MA-AGENTS-END -->` markers in that agent's instruction file
3954
- **And** content outside the markers is preserved byte-for-byte
3955
-
3956
- **Given** the same profile and project state
3957
- **When** the installer runs twice in a row
3958
- **Then** the content within the marker block is byte-identical between runs (NFR46)
3959
-
3960
- **Technical notes:**
3961
- - The injection function in `lib/installer.js` composes: `[universal block]` + `(profile === 'on-prem' ? [on-prem block] : '')`. Story 21.6 wires the on-prem layer; this story only requires the universal block render correctly with an empty on-prem layer
3962
- - The block must NOT mention `/no_think`, `str_replace_editor`, `~/.claude/`, or any local-LLM-specific concept — those belong in the on-prem template (Story 21.6)
3963
-
3964
- ---
3965
-
3966
- ### Story 21.3: `.roomodes` Template with BMAD Mode File-Regex Restrictions
3967
-
3968
- As a **chief architect**,
3969
- I want a `.roomodes` file generated for Roo Code installs defining 4 BMAD modes with `fileRegex` restrictions per phase,
3970
- So that Roo Code's application-layer enforcement (`FileRestrictionError`) prevents agents from editing code files during planning phases — independent of whether the LLM follows the prompt.
3971
-
3972
- **Acceptance Criteria:**
3973
-
3974
- **Given** the template `lib/templates/roomodes.template.yaml`
3975
- **When** the file is created
3976
- **Then** it defines four `customModes`:
3977
- - `bmad-pm` — read + edit restricted to `\.md$`
3978
- - `bmad-architect` — read + edit restricted to `\.(md|xml|drawio)$`
3979
- - `bmad-techlead` — read + edit restricted to `\.(md|json|yaml|yml)$`
3980
- - `bmad-dev` — read + edit + command (full access)
3981
- **And** each mode has a `roleDefinition`, `whenToUse`, and `customInstructions` block matching the BMAD phase descriptions in the source playbook
3982
-
3983
- **Given** the Roo Code agent is included in a `npx ma-agents install`
3984
- **When** the installer runs
3985
- **Then** `.roomodes` is written at the project root with the 4 BMAD modes
3986
- **And** if `.roomodes` already exists with user-defined `customModes`, those entries are preserved as long as their slugs do not collide with the 4 ma-agents BMAD slugs (FR176)
3987
- **And** colliding slugs are overwritten with the ma-agents version (with a console warning naming the slug)
3988
-
3989
- **Given** the user is in `bmad-architect` mode in Roo Code after install
3990
- **When** the agent attempts to edit a `.ts` or `.py` file
3991
- **Then** Roo Code rejects the edit with `FileRestrictionError` (NFR47 — verified via integration test)
3992
-
3993
- **Technical notes:**
3994
- - `lib/agents.js` for the Roo Code entry gains a new optional field `extraInstructionTemplates: [{ template: 'roomodes.template.yaml', target: '.roomodes', merger: 'yaml-customModes' }]`
3995
- - New YAML merger function `mergeRoomodes(existingYaml, templateYaml)` lives in `lib/installer.js` (or a new `lib/merge/roomodes.js` if size warrants)
3996
- - Slug collision handling: only the 4 ma-agents-owned slugs (`bmad-pm`, `bmad-architect`, `bmad-techlead`, `bmad-dev`) are managed by ma-agents; all other entries are preserved untouched
3997
-
3998
- ---
3999
-
4000
- ### Story 21.4: Expanded `AGENTS.md` Template for OpenCode
4001
-
4002
- As an **OpenCode user installing ma-agents**,
4003
- I want a comprehensive `AGENTS.md` generated at my project root covering text-vs-file rules, BMAD phase discipline, and the project's BMAD output structure,
4004
- So that OpenCode's auto-loading of AGENTS.md gives the agent the same guardrails Roo Code gets via `.roomodes`.
4005
-
4006
- **Acceptance Criteria:**
4007
-
4008
- **Given** the template `lib/templates/agents-md.template.md`
4009
- **When** the file is created
4010
- **Then** it includes:
4011
- - The same text-vs-file rules from the universal block
4012
- - A "never create files in `~/.claude/` or any user home directory" rule (this is universal for AGENTS.md regardless of profile, because OpenCode + any model should respect it)
4013
- - A BMAD phase declaration section (Discovery/PM, Architecture, Tech Lead/Stories, Implementation) with phase-specific behavior rules
4014
- - The project BMAD output structure (`/docs/bmad/planning/`, `/docs/bmad/architecture/`, etc., adjusted to the project's actual `_bmad-output/` paths via stamping)
4015
-
4016
- **Given** the OpenCode agent is included in `npx ma-agents install`
4017
- **When** the installer runs
4018
- **Then** `AGENTS.md` is written at the project root using the existing additive injection pattern (markers preserved if file exists)
4019
- **And** the `opencode.json::instructions[]` array gets `AGENTS.md` appended via the existing JSON-merge from Epic 9 if not already present (NFR18 still satisfied — additive only)
4020
-
4021
- **Technical notes:**
4022
- - The phase declaration content is the same in both standard and on-prem profiles (universal layer); on-prem-specific bits (reasoning mode, `/no_think`) come via Story 21.6
4023
- - Reuses Epic 9's JSON-merge function unchanged
4024
-
4025
- ---
4026
-
4027
- ### Story 21.5: Expanded `.clinerules` Template
4028
-
4029
- As a **Cline user**,
4030
- I want `.clinerules` to include BMAD phase discipline and text-vs-file rules,
4031
- So that Cline (which already supports `.clinerules` natively) gets the same universal guardrails.
4032
-
4033
- **Acceptance Criteria:**
4034
-
4035
- **Given** the template `lib/templates/clinerules.template.md`
4036
- **When** the file is created
4037
- **Then** it includes the universal text-vs-file rules and BMAD phase rules, formatted for the Cline `.clinerules` convention
4038
-
4039
- **Given** Cline is included in `npx ma-agents install`
4040
- **When** the installer runs
4041
- **Then** `.clinerules` is written/updated at the project root using the marker-based additive injection
4042
- **And** existing user content outside markers is preserved
4043
-
4044
- **Technical notes:**
4045
- - Cline currently writes to `.cline/clinerules.md` AND `.clinerules` (per `lib/agents.js`). This story keeps both in sync; both files contain the same expanded content
4046
-
4047
- ---
4048
-
4049
- ### Story 21.6: On-Prem Layered Guardrails
4050
-
4051
- As an **engineer running an on-prem install**,
4052
- I want the installer to layer local-LLM-specific guardrails on top of the universal block when profile=on-prem,
4053
- So that Nemotron and other local LLMs stop hallucinating `str_replace_editor`, dumping files into `~/.claude/`, and overthinking planning prompts.
4054
-
4055
- **Acceptance Criteria:**
4056
-
4057
- **Given** the template `lib/templates/instruction-block-onprem.template.md`
4058
- **When** the file is created
4059
- **Then** it contains:
4060
- - A `/no_think` reasoning-OFF directive applied as a system-prompt prefix for planning-phase use
4061
- - A "NEVER create files in `~/.claude/` or any user home directory; all files go under the project directory" rule
4062
- - A "do NOT reference or use `str_replace_editor` or any Claude Code-specific tool that may not exist in this agent" rule
4063
- - Reasoning-mode and sampling guidance per BMAD phase (planning: reasoning OFF, low temperature; implementation: reasoning ON, moderate temperature)
4064
-
4065
- **Given** profile=on-prem
4066
- **When** any agent's instruction-block injection runs
4067
- **Then** the universal block content is followed by the on-prem block content within the same `<!-- MA-AGENTS-START -->` markers
4068
-
4069
- **Given** profile=standard
4070
- **When** any agent's instruction-block injection runs
4071
- **Then** the on-prem block is NOT present in the rendered output (NFR44 — verified by absence of the strings `/no_think`, `str_replace_editor`, `~/.claude/` in standard-profile output)
4072
-
4073
- **Technical notes:**
4074
- - The `.roomodes`, `AGENTS.md`, and `.clinerules` files from Stories 21.3–21.5 also gain on-prem-specific sections gated by profile — concretely, the `customInstructions` block per Roo Code mode and the AGENTS.md "Critical Behavior Rules" section get the on-prem rules appended when profile=on-prem
4075
- - All on-prem additions are appended within ma-agents marker blocks or ma-agents-owned slugs only
4076
-
4077
- ---
4078
-
4079
- ### Story 21.7: BMAD Persona Phase-Aware Prompt Prefix (On-Prem Only)
4080
-
4081
- As an **engineer running an on-prem install with the BMAD module**,
4082
- I want each BMAD agent persona to receive a phase-aware system-prompt prefix steering its reasoning mode appropriately,
4083
- So that planning agents (PM, Architect, SM) stop overthinking and producing files for discussion prompts, and implementation agents (Dev) keep their reasoning mode for careful coding.
4084
-
4085
- **Acceptance Criteria:**
4086
-
4087
- **Given** profile=on-prem
4088
- **When** the BMAD customize-loader composes a persona's system prompt from `lib/bmad-customize/{agent}.customize.yaml`
4089
- **Then** a phase-aware prefix is prepended:
4090
- - Planning personas (`bmm-pm` John, `bmm-architect` Winston, `bmm-sm` Bob, `bmm-analyst` Mary, `bmm-tech-writer` Paige, `bmm-ux-designer` Sally, `bmm-qa` Gad) — receive a `/no_think` + "respond in text for questions; create files only when explicitly asked" prefix
4091
- - Implementation personas (`bmm-dev` Amelia, `bmm-quick-flow-solo-dev` Barry) — receive a "think carefully before writing code; reference the story you are implementing" prefix
4092
-
4093
- **Given** profile=standard
4094
- **When** the customize-loader composes a persona's system prompt
4095
- **Then** NO phase prefix is prepended (NFR44 — standard profile is byte-identical to pre-Epic-21 baseline for customize output)
4096
-
4097
- **Given** the `lib/bmad-customize/*.customize.yaml` files are committed
4098
- **When** Story 21.7 is implemented
4099
- **Then** the YAML files themselves contain a new optional `on_prem_phase_prefix:` field (per agent) with the prefix text — the customize-loader reads this field only when profile=on-prem, so the YAML files remain valid for both profiles
4100
-
4101
- **Technical notes:**
4102
- - Phase classification (planning vs. implementation) is encoded in the `.customize.yaml` via a simple `phase: planning|implementation` field, not derived from agent slug — keeps the loader stateless
4103
- - The phase prefix block is prepended to the persona's existing `critical_actions` / system-prompt content; all prior content is preserved
4104
-
4105
- ---
4106
-
4107
- ### Story 21.8: vLLM Reference Deployment Doc and README On-Prem Section
4108
-
4109
- As a **DevOps engineer setting up the on-prem inference server**,
4110
- I want a single reference doc covering vLLM flags, tool-call-parser, context length, quantization, and per-phase sampling guidance,
4111
- So that I can configure Nemotron Super 49B (or similar) to behave correctly with the coding agents ma-agents installs.
4112
-
4113
- **Acceptance Criteria:**
4114
-
4115
- **Given** the file `docs/deployment/vllm-nemotron.md`
4116
- **When** the file is created
4117
- **Then** it covers:
4118
- - Recommended vLLM flags (`--enable-auto-tool-choice`, `--tool-call-parser qwen3_coder`, `--max-model-len 32768`, `--enforce-eager`, `--trust-remote-code`)
4119
- - Quantization tradeoffs (BF16 vs FP8 vs NVFP4) including VRAM and instruction-following quality impact
4120
- - Reasoning-mode behavior (`/no_think` system-prompt directive, default reasoning ON)
4121
- - Per-phase sampling parameters table (planning: temp 0.0, top_p 1.0; implementation: temp 0.6, top_p 0.95)
4122
- - The `str_replace_editor` hallucination warning and mitigation
4123
- - A complete sample launch command
4124
-
4125
- **Given** the README is updated
4126
- **When** Story 21.8 completes
4127
- **Then** README has a new "On-Prem / Air-Gapped Deployment" section linking to the deployment doc and explaining the install-time profile prompt
4128
- **And** the deployment doc is NOT stamped into target projects by the installer (it is repo documentation only — FR179)
4129
-
4130
- ---
4131
-
4132
- ### Story 21.9: Tests and Validation
4133
-
4134
- As a **chief architect**,
4135
- I want automated regression tests for the profile system and the universal/on-prem instruction-block injection,
4136
- So that future changes to installer or templates do not silently regress on-prem support or break standard installs.
4137
-
4138
- **Acceptance Criteria:**
4139
-
4140
- **Given** the test suite in `test/`
4141
- **When** Story 21.9 completes
4142
- **Then** the suite includes:
4143
- - `test/profile.test.js` — covers `getProfile`, `setProfile`, `resolveProfile` precedence (CLI flag > persisted > yes-default), persistence round-trip, missing-file handling
4144
- - `test/onprem-injection.test.js` — covers (a) standard profile produces no on-prem-specific strings; (b) on-prem profile produces both universal + on-prem content; (c) idempotency — two consecutive installs produce byte-identical marker-block content; (d) `.roomodes` slug-collision: ma-agents BMAD slugs overwrite, non-colliding user slugs preserved; (e) NFR47 enforcement contract — `bmad-architect` `fileRegex` rejects `.ts`/`.py` paths
4145
-
4146
- **Given** all Epic 21 stories are merged
4147
- **When** the full test suite runs
4148
- **Then** all new tests pass
4149
- **And** existing tests in `test/` still pass (no regression)
4150
-
4151
- **Technical notes:**
4152
- - NFR47 enforcement test does not require running Roo Code itself — verifies that the generated `.roomodes` `fileRegex` patterns match the expected restrictions (the actual `FileRestrictionError` is enforced by Roo Code at runtime; the contract under test is that we generate the correct restriction)
4153
-
4154
- ### Story 21.10: Profile Reconfigure
4155
-
4156
- As an **engineer who needs to change a previously-persisted profile**,
4157
- I want a `ma-agents reconfigure` subcommand that re-runs the profile prompt and re-stamps all profile-dependent artifacts,
4158
- So that a CI-default `standard` profile or a mistaken interactive answer can be corrected without hand-editing `.ma-agents.json`.
4159
-
4160
- **Acceptance Criteria:**
4161
-
4162
- **Given** a project with `.ma-agents.json` containing `"profile": "standard"` (perhaps auto-persisted by a CI `--yes` run)
4163
- **When** the engineer runs `npx ma-agents reconfigure` interactively
4164
- **Then** the profile-selection prompt appears with the currently-persisted value as the default highlighted option
4165
- **And** the user can switch to `on-prem` and confirm
4166
-
4167
- **Given** the user changes the profile from `standard` to `on-prem` (or vice versa)
4168
- **When** `reconfigure` proceeds after the confirmation prompt
4169
- **Then** all profile-dependent artifacts are re-stamped (instruction-block injection files, `.roomodes`, BMAD persona customize output)
4170
- **And** each to-be-overwritten marker-block region is backed up to `<target>.backup-<ISO-timestamp>`
4171
- **And** a history entry `{ date, from, to, source: "reconfigure" }` is appended to `.ma-agents.json::profileHistory` (new field, capped at 20 entries)
4172
-
4173
- **Given** `--yes` is passed to `reconfigure`
4174
- **When** the command runs
4175
- **Then** it exits nonzero with the message `--yes is not valid for reconfigure — this command is interactive by design to prevent accidental CI-triggered profile changes.`
4176
- **And** no files are modified
4177
-
4178
- **Given** the user-edited `.roomodes` ma-agents-owned slugs have diverged from the template
4179
- **When** `reconfigure` runs without `--force-roomodes-overwrite`
4180
- **Then** it aborts with `RoomodesSlugDivergenceError` per Story 21.3 AC #9
4181
-
4182
- **Technical notes:**
4183
- - New CLI subcommand `reconfigure` in `bin/cli.js`
4184
- - New orchestrator module `lib/reconfigure.js` — composes prompt, injection re-stamp, backup, history append
4185
- - Reuses `lib/profile.js` (unchanged public contract); reuses injection helpers from `lib/installer.js`
4186
- - `.ma-agents.json` gains optional top-level `"profileHistory"` field (append-only, capped at 20)
4187
- - Detailed spec: `_bmad-output/implementation-artifacts/21-10-profile-reconfigure.md`
4188
-
4189
- ---
4190
-
4191
- ### Story 21.11: Profile Uninstall
4192
-
4193
- As an **engineer migrating a project away from ma-agents or switching from on-prem to a different deployment model**,
4194
- I want a `ma-agents uninstall --profile-artifacts` subcommand that removes all ma-agents-owned profile-dependent content while preserving user content,
4195
- So that I can cleanly reverse the install without hand-editing every generated file or leaving dead guardrails that no longer reflect the project's actual deployment.
4196
-
4197
- **Acceptance Criteria:**
4198
-
4199
- **Given** a project with ma-agents-stamped content (marker blocks in CLAUDE.md/.clinerules/etc., ma-agents-owned slugs in `.roomodes`, `profile` set in `.ma-agents.json`)
4200
- **When** the engineer runs `npx ma-agents uninstall --profile-artifacts` interactively
4201
- **Then** the command lists every file and region it will modify and asks for confirmation
4202
- **And** after confirmation, all marker-block content (including the markers) is removed, `.roomodes` ma-agents-owned slugs are removed (user slugs preserved), and the `profile` field is cleared from `.ma-agents.json`
4203
-
4204
- **Given** each to-be-removed file or region
4205
- **When** `uninstall --profile-artifacts` proceeds
4206
- **Then** a backup is written to `<target>.backup-<ISO-timestamp>` before removal
4207
-
4208
- **Given** the `profileHistory` field from Story 21.10 or the `roomodesOverwriteLog` field from Story 21.3
4209
- **When** `uninstall --profile-artifacts` runs
4210
- **Then** both fields are PRESERVED (audit trails survive uninstall)
4211
- **And** a new entry `{ date, from: <previous>, to: null, source: "uninstall" }` is appended to `profileHistory`
4212
-
4213
- **Given** `--yes` is passed to `uninstall --profile-artifacts`
4214
- **When** the command runs in CI
4215
- **Then** the confirmation prompt is skipped and the operation proceeds (unlike `reconfigure` where `--yes` is rejected — uninstall has legitimate CI use cases such as decommissioning scripts)
4216
-
4217
- **Technical notes:**
4218
- - New CLI flag `--profile-artifacts` on the `uninstall` subcommand (creates the subcommand if not already present)
4219
- - New orchestrator module `lib/uninstall.js` exporting `uninstallProfileArtifacts(projectRoot, opts)`
4220
- - Expands `lib/profile.js` with a 4th export `clearProfile(projectRoot)` — see Dev Notes in the story spec for the Story 21.1 AC #1 contract-update decision
4221
- - Idempotent: second run is a no-op with friendly message
4222
- - Detailed spec: `_bmad-output/implementation-artifacts/21-11-profile-uninstall.md`
4223
-
4224
- ---
4225
-
4226
- ### Epic 21 — Cross-Epic Notes
4227
-
4228
- - **bmad.js coordination:** Epic 21 does not modify `bmad.js`. The cross-epic `bmad.js` ordering note (Epics 5/15/6/8) is unaffected.
4229
- - **OpenCode JSON-merge (Epic 9) reuse:** Story 21.4 reuses Epic 9's `mergeOpencodeJson()` unchanged — additive append to `instructions[]`. NFR18 remains satisfied.
4230
- - **Roo Code agent registration (Epic 18) prerequisite — STATUS: satisfied.** Story 21.3 depends on Roo Code being registered in `lib/agents.js`. As of 2026-04-14, `lib/agents.js` already has the Roo Code entry (Story 18.1 was completed at the code level ahead of Epic 18's formal tracking). Story 21.3 is NOT blocked by Epic 18. The remaining Epic 18 stories (18.2-18.8) do not interact with Epic 21 and can proceed independently.
4231
- - **Customize-loader (Epic 15) prerequisite — STATUS: clarified.** Story 21.7 was originally scoped as if ma-agents owned a customize-loader. On audit (2026-04-14), `lib/bmad-customize/` contains only `*.customize.yaml` artifacts — the loader itself lives upstream in BMAD. Per the project's durable policy of overriding BMAD built-ins via extension rather than upstream PRs, Story 21.7's `phase: mixed` enum extension (added in corrective-plan step 3) will be implemented via the extension pattern: the `*.customize.yaml` files gain the `phase` field and, if BMAD's upstream loader rejects unknown values, the ma-agents extension intercepts the YAML at install time and produces two variants (`*.customize.yaml` and `*.customize.on-prem.yaml`) with the installer choosing based on the persisted profile. See Story 21.7 Dev Notes "Notes on Customize-Loader Discovery" for the decision branches the implementing dev will resolve during Task 1.
4232
- - **Knowledge graph (Epic 19) interaction:** None. Epic 21 does not emit graph nodes/edges.