ma-agents 2.22.2 → 3.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (476) hide show
  1. package/.opencode/skills/.ma-agents.json +99 -99
  2. package/lib/bmad-cache/bmb/.claude-plugin/marketplace.json +22 -0
  3. package/lib/bmad-cache/bmb/.markdownlint-cli2.yaml +1 -0
  4. package/lib/bmad-cache/bmb/_git_preserved/index +0 -0
  5. package/lib/bmad-cache/bmb/_git_preserved/logs/HEAD +1 -1
  6. package/lib/bmad-cache/bmb/_git_preserved/logs/refs/heads/main +1 -1
  7. package/lib/bmad-cache/bmb/_git_preserved/logs/refs/remotes/origin/HEAD +1 -1
  8. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-0de89e0854d5b2b3b3b0c1ee56eee73a739f15e7.idx +0 -0
  9. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-0de89e0854d5b2b3b3b0c1ee56eee73a739f15e7.pack +0 -0
  10. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-0de89e0854d5b2b3b3b0c1ee56eee73a739f15e7.rev +0 -0
  11. package/lib/bmad-cache/bmb/_git_preserved/packed-refs +1 -1
  12. package/lib/bmad-cache/bmb/_git_preserved/refs/heads/main +1 -1
  13. package/lib/bmad-cache/bmb/_git_preserved/shallow +1 -1
  14. package/lib/bmad-cache/bmb/package-lock.json +2 -2
  15. package/lib/bmad-cache/bmb/package.json +7 -4
  16. package/lib/bmad-cache/bmb/skills/bmad-agent-builder/scripts/generate-html-report.py +534 -0
  17. package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-agent-builder/scripts/prepass-execution-deps.py +4 -35
  18. package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-agent-builder/scripts/prepass-prompt-metrics.py +2 -75
  19. package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-agent-builder/scripts/prepass-structure-capabilities.py +3 -194
  20. package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-agent-builder/scripts/scan-path-standards.py +104 -18
  21. package/lib/bmad-cache/bmb/skills/bmad-builder-setup/assets/module-help.csv +6 -0
  22. package/lib/bmad-cache/bmb/skills/bmad-builder-setup/assets/module.yaml +20 -0
  23. package/lib/bmad-cache/bmb/skills/bmad-builder-setup/scripts/cleanup-legacy.py +259 -0
  24. package/lib/bmad-cache/bmb/skills/bmad-builder-setup/scripts/merge-config.py +408 -0
  25. package/lib/bmad-cache/bmb/skills/bmad-builder-setup/scripts/merge-help-csv.py +220 -0
  26. package/lib/bmad-cache/bmb/skills/bmad-builder-setup/scripts/tests/test-cleanup-legacy.py +429 -0
  27. package/lib/bmad-cache/bmb/skills/bmad-builder-setup/scripts/tests/test-merge-config.py +644 -0
  28. package/lib/bmad-cache/bmb/skills/bmad-builder-setup/scripts/tests/test-merge-help-csv.py +237 -0
  29. package/lib/bmad-cache/bmb/skills/bmad-workflow-builder/scripts/generate-html-report.py +539 -0
  30. package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-workflow-builder/scripts/prepass-execution-deps.py +5 -30
  31. package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-workflow-builder/scripts/prepass-workflow-integrity.py +0 -5
  32. package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-workflow-builder/scripts/scan-path-standards.py +103 -16
  33. package/lib/bmad-cache/bmb/skills/module-help.csv +6 -0
  34. package/lib/bmad-cache/bmb/skills/module.yaml +20 -0
  35. package/lib/bmad-cache/bmb/tools/validate-doc-links.cjs +407 -0
  36. package/lib/bmad-cache/bmb/tools/validate-file-refs.mjs +1 -1
  37. package/lib/bmad-cache/cache-manifest.json +16 -10
  38. package/lib/bmad-cache/cis/.claude-plugin/marketplace.json +33 -0
  39. package/lib/bmad-cache/cis/_git_preserved/index +0 -0
  40. package/lib/bmad-cache/cis/_git_preserved/logs/HEAD +1 -1
  41. package/lib/bmad-cache/cis/_git_preserved/logs/refs/heads/main +1 -1
  42. package/lib/bmad-cache/cis/_git_preserved/logs/refs/remotes/origin/HEAD +1 -1
  43. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-9d60aae6b09bbea0d0c5e79fdbe96e8f66de84e6.idx +0 -0
  44. package/lib/bmad-cache/cis/_git_preserved/objects/pack/{pack-157d7eb8d527233a8607d926fc74ebf87f2ae0d3.pack → pack-9d60aae6b09bbea0d0c5e79fdbe96e8f66de84e6.pack} +0 -0
  45. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-9d60aae6b09bbea0d0c5e79fdbe96e8f66de84e6.rev +0 -0
  46. package/lib/bmad-cache/cis/_git_preserved/packed-refs +1 -1
  47. package/lib/bmad-cache/cis/_git_preserved/refs/heads/main +1 -1
  48. package/lib/bmad-cache/cis/_git_preserved/shallow +1 -1
  49. package/lib/bmad-cache/cis/package-lock.json +17015 -0
  50. package/lib/bmad-cache/cis/package.json +3 -4
  51. package/lib/bmad-cache/cis/src/module-help.csv +6 -6
  52. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-brainstorming-coach/bmad-skill-manifest.yaml +11 -0
  53. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-creative-problem-solver/bmad-skill-manifest.yaml +11 -0
  54. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-design-thinking-coach/bmad-skill-manifest.yaml +11 -0
  55. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-innovation-strategist/bmad-skill-manifest.yaml +11 -0
  56. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-presentation-master/bmad-skill-manifest.yaml +11 -0
  57. package/lib/bmad-cache/cis/src/skills/bmad-cis-agent-storyteller/bmad-skill-manifest.yaml +11 -0
  58. package/lib/bmad-cache/gds/.claude-plugin/marketplace.json +58 -0
  59. package/lib/bmad-cache/gds/_git_preserved/index +0 -0
  60. package/lib/bmad-cache/gds/_git_preserved/logs/HEAD +1 -1
  61. package/lib/bmad-cache/gds/_git_preserved/logs/refs/heads/main +1 -1
  62. package/lib/bmad-cache/gds/_git_preserved/logs/refs/remotes/origin/HEAD +1 -1
  63. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-8099a88fca0ad946a573316a00887a2921ca1712.idx +0 -0
  64. package/lib/bmad-cache/gds/_git_preserved/objects/pack/{pack-44faafb9245b4ca17ad81bd6c9e6fc52fb5915a1.pack → pack-8099a88fca0ad946a573316a00887a2921ca1712.pack} +0 -0
  65. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-8099a88fca0ad946a573316a00887a2921ca1712.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 -0
  70. package/lib/bmad-cache/gds/src/module-help.csv +35 -35
  71. package/lib/bmad-cache/tea/.claude-plugin/marketplace.json +33 -0
  72. package/lib/bmad-cache/tea/CHANGELOG.md +2 -14
  73. package/lib/bmad-cache/tea/README.md +31 -18
  74. package/lib/bmad-cache/tea/_git_preserved/index +0 -0
  75. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-d243f64f83b36190434d68872a69a40870c53030.idx +0 -0
  76. package/lib/bmad-cache/tea/_git_preserved/objects/pack/{pack-96ec1ce3a9ef4c891e00e060795b4434ba8f7163.pack → pack-d243f64f83b36190434d68872a69a40870c53030.pack} +0 -0
  77. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-d243f64f83b36190434d68872a69a40870c53030.rev +0 -0
  78. package/lib/bmad-cache/tea/_git_preserved/packed-refs +1 -1
  79. package/lib/bmad-cache/tea/_git_preserved/refs/heads/main +1 -1
  80. package/lib/bmad-cache/tea/_git_preserved/refs/tags/v1.7.3 +1 -0
  81. package/lib/bmad-cache/tea/_git_preserved/shallow +1 -1
  82. package/lib/bmad-cache/tea/docs/explanation/knowledge-base-system.md +5 -5
  83. package/lib/bmad-cache/tea/docs/explanation/step-file-architecture.md +2 -2
  84. package/lib/bmad-cache/tea/docs/explanation/tea-overview.md +3 -3
  85. package/lib/bmad-cache/tea/docs/glossary/index.md +1 -1
  86. package/lib/bmad-cache/tea/docs/how-to/customization/extend-tea-with-custom-workflows.md +73 -0
  87. package/lib/bmad-cache/tea/docs/how-to/workflows/teach-me-testing.md +7 -7
  88. package/lib/bmad-cache/tea/docs/index.md +2 -1
  89. package/lib/bmad-cache/tea/docs/reference/commands.md +4 -1
  90. package/lib/bmad-cache/tea/docs/reference/configuration.md +37 -15
  91. package/lib/bmad-cache/tea/docs/reference/knowledge-base.md +75 -73
  92. package/lib/bmad-cache/tea/docs/reference/troubleshooting.md +32 -19
  93. package/lib/bmad-cache/tea/docs/tutorials/learn-testing-tea-academy.md +3 -3
  94. package/lib/bmad-cache/tea/package-lock.json +2 -2
  95. package/lib/bmad-cache/tea/package.json +2 -1
  96. package/lib/bmad-cache/tea/src/agents/bmad-tea/SKILL.md +70 -0
  97. package/lib/bmad-cache/tea/src/agents/bmad-tea/bmad-skill-manifest.yaml +14 -0
  98. package/lib/bmad-cache/tea/src/module-help.csv +10 -10
  99. package/lib/bmad-cache/tea/src/module.yaml +8 -8
  100. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/checklist.md +1 -1
  101. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/data/curriculum.yaml +1 -1
  102. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/data/session-content-map.yaml +26 -14
  103. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/data/tea-resources-index.yaml +108 -73
  104. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/instructions.md +2 -2
  105. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-03-session-menu.md +1 -1
  106. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-01.md +3 -3
  107. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-04-session-07.md +14 -6
  108. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/steps-c/step-05-completion.md +3 -3
  109. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/templates/certificate-template.md +1 -1
  110. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-teach-me-testing/workflow-plan-teach-me-testing.md +8 -8
  111. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/atdd-checklist-template.md +1 -1
  112. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-01-preflight-and-context.md +3 -3
  113. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-atdd/steps-c/step-04a-subagent-api-failing.md +9 -1
  114. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-c/step-01-preflight-and-context.md +1 -1
  115. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-automate/steps-c/step-03b-subagent-e2e.md +2 -2
  116. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-c/step-02-generate-pipeline.md +6 -0
  117. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-ci/steps-c/step-03-configure-quality-gates.md +6 -1
  118. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-framework/steps-c/step-03-scaffold-framework.md +3 -2
  119. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-nfr/steps-c/step-01-load-context.md +1 -1
  120. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-design/steps-c/step-02-load-context.md +1 -1
  121. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/steps-c/step-01-load-context.md +1 -1
  122. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-test-review/test-review-template.md +11 -11
  123. package/lib/bmad-cache/tea/src/workflows/testarch/bmad-testarch-trace/steps-c/step-01-load-context.md +1 -1
  124. package/lib/bmad-cache/tea/test/test-installation-components.js +85 -21
  125. package/lib/bmad-cache/tea/test/test-knowledge-base.js +1 -1
  126. package/lib/bmad-cache/tea/tools/validate-agent-schema.js +105 -5
  127. package/lib/bmad-cache/wds/.claude-plugin/marketplace.json +35 -0
  128. package/lib/bmad-cache/wds/.markdownlint-cli2.yaml +38 -0
  129. package/lib/bmad-cache/wds/.nvmrc +1 -0
  130. package/lib/bmad-cache/wds/.prettierignore +9 -0
  131. package/lib/bmad-cache/wds/LICENSE +27 -0
  132. package/lib/bmad-cache/wds/README.md +126 -0
  133. package/lib/bmad-cache/wds/_git_preserved/HEAD +1 -0
  134. package/lib/bmad-cache/wds/_git_preserved/config +13 -0
  135. package/lib/bmad-cache/wds/_git_preserved/description +1 -0
  136. package/lib/bmad-cache/wds/_git_preserved/hooks/applypatch-msg.sample +15 -0
  137. package/lib/bmad-cache/wds/_git_preserved/hooks/commit-msg.sample +24 -0
  138. package/lib/bmad-cache/wds/_git_preserved/hooks/fsmonitor-watchman.sample +174 -0
  139. package/lib/bmad-cache/wds/_git_preserved/hooks/post-update.sample +8 -0
  140. package/lib/bmad-cache/wds/_git_preserved/hooks/pre-applypatch.sample +14 -0
  141. package/lib/bmad-cache/wds/_git_preserved/hooks/pre-commit.sample +49 -0
  142. package/lib/bmad-cache/wds/_git_preserved/hooks/pre-merge-commit.sample +13 -0
  143. package/lib/bmad-cache/wds/_git_preserved/hooks/pre-push.sample +53 -0
  144. package/lib/bmad-cache/wds/_git_preserved/hooks/pre-rebase.sample +169 -0
  145. package/lib/bmad-cache/wds/_git_preserved/hooks/pre-receive.sample +24 -0
  146. package/lib/bmad-cache/wds/_git_preserved/hooks/prepare-commit-msg.sample +42 -0
  147. package/lib/bmad-cache/wds/_git_preserved/hooks/push-to-checkout.sample +78 -0
  148. package/lib/bmad-cache/wds/_git_preserved/hooks/sendemail-validate.sample +77 -0
  149. package/lib/bmad-cache/wds/_git_preserved/hooks/update.sample +128 -0
  150. package/lib/bmad-cache/wds/_git_preserved/index +0 -0
  151. package/lib/bmad-cache/wds/_git_preserved/info/exclude +6 -0
  152. package/lib/bmad-cache/wds/_git_preserved/logs/HEAD +1 -0
  153. package/lib/bmad-cache/wds/_git_preserved/logs/refs/heads/main +1 -0
  154. package/lib/bmad-cache/wds/_git_preserved/logs/refs/remotes/origin/HEAD +1 -0
  155. package/lib/bmad-cache/wds/_git_preserved/objects/pack/pack-92d32f26e3a97a0786dcea5cb2c24bf90384521c.idx +0 -0
  156. package/lib/bmad-cache/wds/_git_preserved/objects/pack/pack-92d32f26e3a97a0786dcea5cb2c24bf90384521c.pack +0 -0
  157. package/lib/bmad-cache/wds/_git_preserved/objects/pack/pack-92d32f26e3a97a0786dcea5cb2c24bf90384521c.rev +0 -0
  158. package/lib/bmad-cache/wds/_git_preserved/packed-refs +2 -0
  159. package/lib/bmad-cache/wds/_git_preserved/refs/heads/main +1 -0
  160. package/lib/bmad-cache/wds/_git_preserved/refs/remotes/origin/HEAD +1 -0
  161. package/lib/bmad-cache/wds/_git_preserved/shallow +1 -0
  162. package/lib/bmad-cache/wds/eslint.config.mjs +152 -0
  163. package/lib/bmad-cache/wds/package.json +82 -0
  164. package/lib/bmad-cache/wds/prettier.config.mjs +32 -0
  165. package/lib/bmad-cache/wds/src/agents/wds-agent-freya-ux/bmad-skill-manifest.yaml +12 -0
  166. package/lib/bmad-cache/wds/src/agents/wds-agent-saga-analyst/bmad-skill-manifest.yaml +12 -0
  167. package/lib/bmad-cache/wds/src/module-help.csv +18 -0
  168. package/lib/bmad-cache/wds/src/module.yaml +148 -0
  169. package/lib/bmad-cache/wds/src/workflows/wds-1-project-brief/bmad-skill-manifest.yaml +1 -0
  170. package/lib/bmad-cache/wds/src/workflows/wds-1-project-brief/templates/platform-requirements.template.yaml +69 -0
  171. package/lib/bmad-cache/wds/src/workflows/wds-2-trigger-mapping/bmad-skill-manifest.yaml +1 -0
  172. package/lib/bmad-cache/wds/src/workflows/wds-3-scenarios/bmad-skill-manifest.yaml +1 -0
  173. package/lib/bmad-cache/wds/src/workflows/wds-4-ux-design/bmad-skill-manifest.yaml +1 -0
  174. package/lib/bmad-cache/wds/src/workflows/wds-4-ux-design/templates/design-delivery.template.yaml +104 -0
  175. package/lib/bmad-cache/wds/src/workflows/wds-4-ux-design/templates/test-scenario.template.yaml +192 -0
  176. package/lib/bmad-cache/wds/src/workflows/wds-5-agentic-development/bmad-skill-manifest.yaml +1 -0
  177. package/lib/bmad-cache/wds/src/workflows/wds-5-agentic-development/templates/components/dev-mode.css +164 -0
  178. package/lib/bmad-cache/wds/src/workflows/wds-5-agentic-development/templates/components/dev-mode.html +18 -0
  179. package/lib/bmad-cache/wds/src/workflows/wds-5-agentic-development/templates/components/dev-mode.js +430 -0
  180. package/lib/bmad-cache/wds/src/workflows/wds-5-agentic-development/templates/demo-data-template.json +63 -0
  181. package/lib/bmad-cache/wds/src/workflows/wds-5-agentic-development/templates/page-template.html +465 -0
  182. package/lib/bmad-cache/wds/src/workflows/wds-5-agentic-development/templates/work-file-template.yaml +264 -0
  183. package/lib/bmad-cache/wds/src/workflows/wds-6-asset-generation/bmad-skill-manifest.yaml +1 -0
  184. package/lib/bmad-cache/wds/src/workflows/wds-7-design-system/bmad-skill-manifest.yaml +1 -0
  185. package/lib/bmad-cache/wds/src/workflows/wds-7-design-system/templates/catalog.template.html +363 -0
  186. package/lib/bmad-cache/wds/src/workflows/wds-8-product-evolution/bmad-skill-manifest.yaml +1 -0
  187. package/lib/bmad-customize/bmm-architect.customize.yaml +6 -0
  188. package/lib/bmad-customize/bmm-bmad-master.customize.yaml +6 -0
  189. package/lib/bmad-customize/bmm-dev.customize.yaml +6 -0
  190. package/lib/bmad-customize/bmm-pm.customize.yaml +6 -0
  191. package/lib/bmad-customize/bmm-qa.customize.yaml +6 -0
  192. package/lib/bmad-customize/bmm-sm.customize.yaml +6 -0
  193. package/lib/bmad-customize/bmm-tech-writer.customize.yaml +6 -0
  194. package/lib/bmad-customize/bmm-ux-designer.customize.yaml +6 -0
  195. package/lib/bmad-extension/module-help.csv +37 -7
  196. package/lib/bmad-extension/module.yaml +4 -2
  197. package/lib/bmad-extension/skills/add-sprint/.gitkeep +0 -0
  198. package/lib/bmad-extension/skills/add-sprint/SKILL.md +121 -0
  199. package/lib/bmad-extension/skills/add-sprint/bmad-skill-manifest.yaml +3 -0
  200. package/lib/bmad-extension/skills/add-to-sprint/.gitkeep +0 -0
  201. package/lib/bmad-extension/skills/add-to-sprint/SKILL.md +215 -0
  202. package/lib/bmad-extension/skills/add-to-sprint/bmad-skill-manifest.yaml +3 -0
  203. package/lib/bmad-extension/skills/bmad-ma-agent-cyber/.gitkeep +0 -0
  204. package/lib/bmad-extension/skills/bmad-ma-agent-cyber/SKILL.md +49 -0
  205. package/lib/bmad-extension/skills/bmad-ma-agent-cyber/bmad-skill-manifest.yaml +11 -0
  206. package/lib/bmad-extension/skills/bmad-ma-agent-devops/.gitkeep +0 -0
  207. package/lib/bmad-extension/skills/bmad-ma-agent-devops/SKILL.md +49 -0
  208. package/lib/bmad-extension/skills/bmad-ma-agent-devops/bmad-skill-manifest.yaml +11 -0
  209. package/lib/bmad-extension/skills/bmad-ma-agent-mil498/.gitkeep +0 -0
  210. package/lib/bmad-extension/skills/bmad-ma-agent-mil498/SKILL.md +53 -0
  211. package/lib/bmad-extension/skills/bmad-ma-agent-mil498/bmad-skill-manifest.yaml +11 -0
  212. package/lib/bmad-extension/skills/bmad-ma-agent-sre/.gitkeep +0 -0
  213. package/lib/bmad-extension/skills/bmad-ma-agent-sre/SKILL.md +49 -0
  214. package/lib/bmad-extension/skills/bmad-ma-agent-sre/bmad-skill-manifest.yaml +11 -0
  215. package/lib/bmad-extension/skills/create-bug-story/.gitkeep +0 -0
  216. package/lib/bmad-extension/skills/create-bug-story/SKILL.md +195 -0
  217. package/lib/bmad-extension/skills/create-bug-story/bmad-skill-manifest.yaml +3 -0
  218. package/lib/bmad-extension/skills/cyber-generate-certs/.gitkeep +0 -0
  219. package/lib/bmad-extension/skills/cyber-generate-certs/SKILL.md +27 -0
  220. package/lib/bmad-extension/skills/cyber-generate-certs/bmad-skill-manifest.yaml +3 -0
  221. package/lib/bmad-extension/skills/cyber-immunity-estimation/.gitkeep +0 -0
  222. package/lib/bmad-extension/skills/cyber-immunity-estimation/SKILL.md +29 -0
  223. package/lib/bmad-extension/skills/cyber-immunity-estimation/bmad-skill-manifest.yaml +3 -0
  224. package/lib/bmad-extension/skills/cyber-security-audit/.gitkeep +0 -0
  225. package/lib/bmad-extension/skills/cyber-security-audit/SKILL.md +27 -0
  226. package/lib/bmad-extension/skills/cyber-security-audit/bmad-skill-manifest.yaml +3 -0
  227. package/lib/bmad-extension/skills/cyber-vault-secrets/.gitkeep +0 -0
  228. package/lib/bmad-extension/skills/cyber-vault-secrets/SKILL.md +28 -0
  229. package/lib/bmad-extension/skills/cyber-vault-secrets/bmad-skill-manifest.yaml +3 -0
  230. package/lib/bmad-extension/skills/cyber-verify-docker-users/.gitkeep +0 -0
  231. package/lib/bmad-extension/skills/cyber-verify-docker-users/SKILL.md +23 -0
  232. package/lib/bmad-extension/skills/cyber-verify-docker-users/bmad-skill-manifest.yaml +3 -0
  233. package/lib/bmad-extension/skills/cyber-verify-image-signature/.gitkeep +0 -0
  234. package/lib/bmad-extension/skills/cyber-verify-image-signature/SKILL.md +22 -0
  235. package/lib/bmad-extension/skills/cyber-verify-image-signature/bmad-skill-manifest.yaml +3 -0
  236. package/lib/bmad-extension/skills/cyber-vulnerability-scan/.gitkeep +0 -0
  237. package/lib/bmad-extension/skills/cyber-vulnerability-scan/SKILL.md +28 -0
  238. package/lib/bmad-extension/skills/cyber-vulnerability-scan/bmad-skill-manifest.yaml +3 -0
  239. package/lib/bmad-extension/skills/devops-configure-infrastructure/.gitkeep +0 -0
  240. package/lib/bmad-extension/skills/devops-configure-infrastructure/SKILL.md +27 -0
  241. package/lib/bmad-extension/skills/devops-configure-infrastructure/bmad-skill-manifest.yaml +3 -0
  242. package/lib/bmad-extension/skills/devops-disconnected-deployment/.gitkeep +0 -0
  243. package/lib/bmad-extension/skills/devops-disconnected-deployment/SKILL.md +27 -0
  244. package/lib/bmad-extension/skills/devops-disconnected-deployment/bmad-skill-manifest.yaml +3 -0
  245. package/lib/bmad-extension/skills/devops-docker-compose-setup/.gitkeep +0 -0
  246. package/lib/bmad-extension/skills/devops-docker-compose-setup/SKILL.md +26 -0
  247. package/lib/bmad-extension/skills/devops-docker-compose-setup/bmad-skill-manifest.yaml +3 -0
  248. package/lib/bmad-extension/skills/devops-manage-helm/.gitkeep +0 -0
  249. package/lib/bmad-extension/skills/devops-manage-helm/SKILL.md +28 -0
  250. package/lib/bmad-extension/skills/devops-manage-helm/bmad-skill-manifest.yaml +3 -0
  251. package/lib/bmad-extension/skills/devops-sign-docker-image/.gitkeep +0 -0
  252. package/lib/bmad-extension/skills/devops-sign-docker-image/SKILL.md +24 -0
  253. package/lib/bmad-extension/skills/devops-sign-docker-image/bmad-skill-manifest.yaml +3 -0
  254. package/lib/bmad-extension/skills/mil498-ocd/.gitkeep +0 -0
  255. package/lib/bmad-extension/skills/mil498-ocd/SKILL.md +30 -0
  256. package/lib/bmad-extension/skills/mil498-ocd/bmad-skill-manifest.yaml +5 -0
  257. package/lib/bmad-extension/skills/mil498-ocd/prompts/01-discover-project-artifacts.md +26 -0
  258. package/lib/bmad-extension/skills/mil498-ocd/prompts/02-load-template.md +10 -0
  259. package/lib/bmad-extension/skills/mil498-ocd/prompts/03-generate-document.md +90 -0
  260. package/lib/bmad-extension/skills/mil498-ocd/prompts/04-validate.md +14 -0
  261. package/lib/bmad-extension/skills/mil498-ocd/prompts/05-review.md +15 -0
  262. package/lib/bmad-extension/skills/mil498-ocd/prompts/06-save.md +15 -0
  263. package/lib/bmad-extension/skills/mil498-ocd/template.md +169 -0
  264. package/lib/bmad-extension/skills/mil498-sdd/.gitkeep +0 -0
  265. package/lib/bmad-extension/skills/mil498-sdd/SKILL.md +30 -0
  266. package/lib/bmad-extension/skills/mil498-sdd/bmad-skill-manifest.yaml +5 -0
  267. package/lib/bmad-extension/skills/mil498-sdd/prompts/01-discover-project-artifacts.md +50 -0
  268. package/lib/bmad-extension/skills/mil498-sdd/prompts/02-load-template.md +10 -0
  269. package/lib/bmad-extension/skills/mil498-sdd/prompts/03-generate-document.md +98 -0
  270. package/lib/bmad-extension/skills/mil498-sdd/prompts/04-validate.md +16 -0
  271. package/lib/bmad-extension/skills/mil498-sdd/prompts/05-review.md +15 -0
  272. package/lib/bmad-extension/skills/mil498-sdd/prompts/06-save.md +19 -0
  273. package/lib/bmad-extension/skills/mil498-sdd/template.md +163 -0
  274. package/lib/bmad-extension/skills/mil498-sdp/.gitkeep +0 -0
  275. package/lib/bmad-extension/skills/mil498-sdp/SKILL.md +30 -0
  276. package/lib/bmad-extension/skills/mil498-sdp/bmad-skill-manifest.yaml +5 -0
  277. package/lib/bmad-extension/skills/mil498-sdp/prompts/01-discover-project-artifacts.md +32 -0
  278. package/lib/bmad-extension/skills/mil498-sdp/prompts/02-load-template.md +10 -0
  279. package/lib/bmad-extension/skills/mil498-sdp/prompts/03-generate-document.md +187 -0
  280. package/lib/bmad-extension/skills/mil498-sdp/prompts/04-validate.md +13 -0
  281. package/lib/bmad-extension/skills/mil498-sdp/prompts/05-review.md +15 -0
  282. package/lib/bmad-extension/skills/mil498-sdp/prompts/06-save.md +14 -0
  283. package/lib/bmad-extension/skills/mil498-sdp/template.md +307 -0
  284. package/lib/bmad-extension/skills/mil498-srs/.gitkeep +0 -0
  285. package/lib/bmad-extension/skills/mil498-srs/SKILL.md +30 -0
  286. package/lib/bmad-extension/skills/mil498-srs/bmad-skill-manifest.yaml +5 -0
  287. package/lib/bmad-extension/skills/mil498-srs/prompts/01-discover-project-artifacts.md +42 -0
  288. package/lib/bmad-extension/skills/mil498-srs/prompts/02-load-template.md +10 -0
  289. package/lib/bmad-extension/skills/mil498-srs/prompts/03-generate-document.md +100 -0
  290. package/lib/bmad-extension/skills/mil498-srs/prompts/04-validate.md +16 -0
  291. package/lib/bmad-extension/skills/mil498-srs/prompts/05-review.md +15 -0
  292. package/lib/bmad-extension/skills/mil498-srs/prompts/06-save.md +18 -0
  293. package/lib/bmad-extension/skills/mil498-srs/template.md +219 -0
  294. package/lib/bmad-extension/skills/mil498-ssdd/.gitkeep +0 -0
  295. package/lib/bmad-extension/skills/mil498-ssdd/SKILL.md +32 -0
  296. package/lib/bmad-extension/skills/mil498-ssdd/bmad-skill-manifest.yaml +5 -0
  297. package/lib/bmad-extension/skills/mil498-ssdd/prompts/01-discover-project-artifacts.md +32 -0
  298. package/lib/bmad-extension/skills/mil498-ssdd/prompts/02-load-template.md +10 -0
  299. package/lib/bmad-extension/skills/mil498-ssdd/prompts/03-csci-discovery-interview.md +43 -0
  300. package/lib/bmad-extension/skills/mil498-ssdd/prompts/04-generate-document.md +96 -0
  301. package/lib/bmad-extension/skills/mil498-ssdd/prompts/05-validate.md +14 -0
  302. package/lib/bmad-extension/skills/mil498-ssdd/prompts/06-review.md +16 -0
  303. package/lib/bmad-extension/skills/mil498-ssdd/prompts/07-save.md +16 -0
  304. package/lib/bmad-extension/skills/mil498-ssdd/template.md +154 -0
  305. package/lib/bmad-extension/skills/mil498-sss/.gitkeep +0 -0
  306. package/lib/bmad-extension/skills/mil498-sss/SKILL.md +31 -0
  307. package/lib/bmad-extension/skills/mil498-sss/bmad-skill-manifest.yaml +5 -0
  308. package/lib/bmad-extension/skills/mil498-sss/prompts/01-discover-project-artifacts.md +31 -0
  309. package/lib/bmad-extension/skills/mil498-sss/prompts/02-load-template.md +10 -0
  310. package/lib/bmad-extension/skills/mil498-sss/prompts/03-generate-document.md +108 -0
  311. package/lib/bmad-extension/skills/mil498-sss/prompts/04-validate.md +16 -0
  312. package/lib/bmad-extension/skills/mil498-sss/prompts/05-review.md +15 -0
  313. package/lib/bmad-extension/skills/mil498-sss/prompts/06-save.md +15 -0
  314. package/lib/bmad-extension/skills/mil498-sss/template.md +225 -0
  315. package/lib/bmad-extension/skills/mil498-std/.gitkeep +0 -0
  316. package/lib/bmad-extension/skills/mil498-std/SKILL.md +30 -0
  317. package/lib/bmad-extension/skills/mil498-std/bmad-skill-manifest.yaml +5 -0
  318. package/lib/bmad-extension/skills/mil498-std/prompts/01-discover-project-artifacts.md +42 -0
  319. package/lib/bmad-extension/skills/mil498-std/prompts/02-load-template.md +10 -0
  320. package/lib/bmad-extension/skills/mil498-std/prompts/03-generate-document.md +117 -0
  321. package/lib/bmad-extension/skills/mil498-std/prompts/04-validate.md +15 -0
  322. package/lib/bmad-extension/skills/mil498-std/prompts/05-review.md +15 -0
  323. package/lib/bmad-extension/skills/mil498-std/prompts/06-save.md +15 -0
  324. package/lib/bmad-extension/skills/mil498-std/template.md +188 -0
  325. package/lib/bmad-extension/skills/modify-sprint/.gitkeep +0 -0
  326. package/lib/bmad-extension/skills/modify-sprint/SKILL.md +259 -0
  327. package/lib/bmad-extension/skills/modify-sprint/bmad-skill-manifest.yaml +3 -0
  328. package/lib/bmad-extension/skills/project-context-expansion/.gitkeep +0 -0
  329. package/lib/bmad-extension/skills/project-context-expansion/SKILL.md +238 -0
  330. package/lib/bmad-extension/skills/project-context-expansion/bmad-skill-manifest.yaml +3 -0
  331. package/lib/bmad-extension/skills/sprint-status-view/.gitkeep +0 -0
  332. package/lib/bmad-extension/skills/sprint-status-view/SKILL.md +202 -0
  333. package/lib/bmad-extension/skills/sprint-status-view/bmad-skill-manifest.yaml +3 -0
  334. package/lib/bmad-extension/skills/sre-check-deployment-status/.gitkeep +0 -0
  335. package/lib/bmad-extension/skills/sre-check-deployment-status/SKILL.md +32 -0
  336. package/lib/bmad-extension/skills/sre-check-deployment-status/bmad-skill-manifest.yaml +3 -0
  337. package/lib/bmad-extension/skills/sre-check-secrets/.gitkeep +0 -0
  338. package/lib/bmad-extension/skills/sre-check-secrets/SKILL.md +23 -0
  339. package/lib/bmad-extension/skills/sre-check-secrets/bmad-skill-manifest.yaml +3 -0
  340. package/lib/bmad-extension/skills/sre-check-system-status/.gitkeep +0 -0
  341. package/lib/bmad-extension/skills/sre-check-system-status/SKILL.md +27 -0
  342. package/lib/bmad-extension/skills/sre-check-system-status/bmad-skill-manifest.yaml +3 -0
  343. package/lib/bmad-extension/skills/sre-day-2-ops/.gitkeep +0 -0
  344. package/lib/bmad-extension/skills/sre-day-2-ops/SKILL.md +26 -0
  345. package/lib/bmad-extension/skills/sre-day-2-ops/bmad-skill-manifest.yaml +3 -0
  346. package/lib/bmad-extension/skills/sre-deployment-strategies/.gitkeep +0 -0
  347. package/lib/bmad-extension/skills/sre-deployment-strategies/SKILL.md +28 -0
  348. package/lib/bmad-extension/skills/sre-deployment-strategies/bmad-skill-manifest.yaml +3 -0
  349. package/lib/bmad-extension/skills/sre-fix-deployments/.gitkeep +0 -0
  350. package/lib/bmad-extension/skills/sre-fix-deployments/SKILL.md +25 -0
  351. package/lib/bmad-extension/skills/sre-fix-deployments/bmad-skill-manifest.yaml +3 -0
  352. package/lib/bmad-extension/skills/sre-gitops-status/.gitkeep +0 -0
  353. package/lib/bmad-extension/skills/sre-gitops-status/SKILL.md +25 -0
  354. package/lib/bmad-extension/skills/sre-gitops-status/bmad-skill-manifest.yaml +3 -0
  355. package/lib/bmad.js +541 -1
  356. package/package.json +3 -3
  357. package/test/bmad-extension.test.js +115 -69
  358. package/test/bmad-version-bump.test.js +313 -0
  359. package/test/convert-agents-to-skills.test.js +245 -0
  360. package/test/extension-module-restructure.test.js +359 -0
  361. package/test/integration-verification.test.js +71 -40
  362. package/test/migration-validation.test.js +499 -0
  363. package/test/migration.test.js +832 -0
  364. package/test/story-15-5-workflow-skills.test.js +311 -0
  365. package/test/yes-flag.test.js +8 -1
  366. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-c6e539e2308f8ed764c5b54b6ab68a67f8a3796b.idx +0 -0
  367. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-c6e539e2308f8ed764c5b54b6ab68a67f8a3796b.pack +0 -0
  368. package/lib/bmad-cache/bmb/_git_preserved/objects/pack/pack-c6e539e2308f8ed764c5b54b6ab68a67f8a3796b.rev +0 -0
  369. package/lib/bmad-cache/bmb/samples/bmad-agent-dream-weaver/bmad-manifest.json +0 -62
  370. package/lib/bmad-cache/bmb/samples/bmad-excalidraw/bmad-manifest.json +0 -18
  371. package/lib/bmad-cache/bmb/src/module-help.csv +0 -7
  372. package/lib/bmad-cache/bmb/src/module.yaml +0 -20
  373. package/lib/bmad-cache/bmb/src/skills/bmad-agent-builder/bmad-manifest.json +0 -24
  374. package/lib/bmad-cache/bmb/src/skills/bmad-agent-builder/scripts/bmad-manifest-schema.json +0 -103
  375. package/lib/bmad-cache/bmb/src/skills/bmad-agent-builder/scripts/generate-html-report.py +0 -1002
  376. package/lib/bmad-cache/bmb/src/skills/bmad-agent-builder/scripts/manifest.py +0 -420
  377. package/lib/bmad-cache/bmb/src/skills/bmad-workflow-builder/bmad-manifest.json +0 -23
  378. package/lib/bmad-cache/bmb/src/skills/bmad-workflow-builder/scripts/bmad-manifest-schema.json +0 -103
  379. package/lib/bmad-cache/bmb/src/skills/bmad-workflow-builder/scripts/generate-html-report.py +0 -1002
  380. package/lib/bmad-cache/bmb/src/skills/bmad-workflow-builder/scripts/manifest.py +0 -420
  381. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-157d7eb8d527233a8607d926fc74ebf87f2ae0d3.idx +0 -0
  382. package/lib/bmad-cache/cis/_git_preserved/objects/pack/pack-157d7eb8d527233a8607d926fc74ebf87f2ae0d3.rev +0 -0
  383. package/lib/bmad-cache/cis/src/agents/brainstorming-coach.agent.yaml +0 -21
  384. package/lib/bmad-cache/cis/src/agents/creative-problem-solver.agent.yaml +0 -21
  385. package/lib/bmad-cache/cis/src/agents/design-thinking-coach.agent.yaml +0 -21
  386. package/lib/bmad-cache/cis/src/agents/innovation-strategist.agent.yaml +0 -21
  387. package/lib/bmad-cache/cis/src/agents/presentation-master.agent.yaml +0 -53
  388. package/lib/bmad-cache/cis/src/agents/storyteller/storyteller.agent.yaml +0 -25
  389. package/lib/bmad-cache/cis/src/teams/creative-squad.yaml +0 -7
  390. package/lib/bmad-cache/cis/src/teams/default-party.csv +0 -12
  391. package/lib/bmad-cache/cis/src/workflows/README.md +0 -175
  392. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-44faafb9245b4ca17ad81bd6c9e6fc52fb5915a1.idx +0 -0
  393. package/lib/bmad-cache/gds/_git_preserved/objects/pack/pack-44faafb9245b4ca17ad81bd6c9e6fc52fb5915a1.rev +0 -0
  394. package/lib/bmad-cache/gds/_git_preserved/refs/tags/v0.2.2 +0 -1
  395. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-96ec1ce3a9ef4c891e00e060795b4434ba8f7163.idx +0 -0
  396. package/lib/bmad-cache/tea/_git_preserved/objects/pack/pack-96ec1ce3a9ef4c891e00e060795b4434ba8f7163.rev +0 -0
  397. package/lib/bmad-cache/tea/_git_preserved/refs/tags/v1.7.0 +0 -1
  398. package/lib/bmad-cache/tea/docs/MIGRATION.md +0 -488
  399. package/lib/bmad-cache/tea/src/agents/tea.agent.yaml +0 -67
  400. package/lib/bmad-cache/tea/src/teams/default-party.csv +0 -2
  401. package/lib/bmad-customizations/bmm-cyber.customize.yaml +0 -24
  402. package/lib/bmad-customizations/bmm-devops.customize.yaml +0 -24
  403. package/lib/bmad-customizations/bmm-mil498.customize.yaml +0 -36
  404. package/lib/bmad-customizations/bmm-sre.customize.yaml +0 -24
  405. package/lib/bmad-customizations/cyber.md +0 -71
  406. package/lib/bmad-customizations/devops.md +0 -71
  407. package/lib/bmad-customizations/mil498.md +0 -75
  408. package/lib/bmad-customizations/sre.md +0 -71
  409. package/lib/bmad-extension/agents/bmm-architect.customize.yaml +0 -5
  410. package/lib/bmad-extension/agents/bmm-bmad-master.customize.yaml +0 -5
  411. package/lib/bmad-extension/agents/bmm-cyber.customize.yaml +0 -30
  412. package/lib/bmad-extension/agents/bmm-dev.customize.yaml +0 -5
  413. package/lib/bmad-extension/agents/bmm-devops.customize.yaml +0 -30
  414. package/lib/bmad-extension/agents/bmm-mil498.customize.yaml +0 -42
  415. package/lib/bmad-extension/agents/bmm-pm.customize.yaml +0 -5
  416. package/lib/bmad-extension/agents/bmm-qa.customize.yaml +0 -5
  417. package/lib/bmad-extension/agents/bmm-sm.customize.yaml +0 -5
  418. package/lib/bmad-extension/agents/bmm-sre.customize.yaml +0 -30
  419. package/lib/bmad-extension/agents/bmm-tech-writer.customize.yaml +0 -5
  420. package/lib/bmad-extension/agents/bmm-ux-designer.customize.yaml +0 -5
  421. /package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-agent-builder/scripts/scan-scripts.py +0 -0
  422. /package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-workflow-builder/scripts/prepass-prompt-metrics.py +0 -0
  423. /package/lib/bmad-cache/bmb/{src/skills → skills}/bmad-workflow-builder/scripts/scan-scripts.py +0 -0
  424. /package/lib/bmad-cache/{bmb/src/skills/bmad-agent-builder → cis/src/skills/bmad-cis-design-thinking}/bmad-skill-manifest.yaml +0 -0
  425. /package/lib/bmad-cache/cis/src/{workflows → skills}/bmad-cis-design-thinking/design-methods.csv +0 -0
  426. /package/lib/bmad-cache/{bmb/src/skills/bmad-workflow-builder → cis/src/skills/bmad-cis-innovation-strategy}/bmad-skill-manifest.yaml +0 -0
  427. /package/lib/bmad-cache/cis/src/{workflows → skills}/bmad-cis-innovation-strategy/innovation-frameworks.csv +0 -0
  428. /package/lib/bmad-cache/cis/src/{workflows/bmad-cis-design-thinking → skills/bmad-cis-problem-solving}/bmad-skill-manifest.yaml +0 -0
  429. /package/lib/bmad-cache/cis/src/{workflows → skills}/bmad-cis-problem-solving/solving-methods.csv +0 -0
  430. /package/lib/bmad-cache/cis/src/{workflows/bmad-cis-innovation-strategy → skills/bmad-cis-storytelling}/bmad-skill-manifest.yaml +0 -0
  431. /package/lib/bmad-cache/cis/src/{workflows → skills}/bmad-cis-storytelling/story-types.csv +0 -0
  432. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/adr-quality-readiness-checklist.md +0 -0
  433. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/api-request.md +0 -0
  434. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/api-testing-patterns.md +0 -0
  435. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/auth-session.md +0 -0
  436. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/burn-in.md +0 -0
  437. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/ci-burn-in.md +0 -0
  438. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/component-tdd.md +0 -0
  439. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/contract-testing.md +0 -0
  440. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/data-factories.md +0 -0
  441. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/email-auth.md +0 -0
  442. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/error-handling.md +0 -0
  443. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/feature-flags.md +0 -0
  444. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/file-utils.md +0 -0
  445. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/fixture-architecture.md +0 -0
  446. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/fixtures-composition.md +0 -0
  447. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/intercept-network-call.md +0 -0
  448. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/log.md +0 -0
  449. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/network-error-monitor.md +0 -0
  450. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/network-first.md +0 -0
  451. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/network-recorder.md +0 -0
  452. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/nfr-criteria.md +0 -0
  453. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/overview.md +0 -0
  454. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/pact-consumer-di.md +0 -0
  455. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/pact-consumer-framework-setup.md +0 -0
  456. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/pact-mcp.md +0 -0
  457. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/pactjs-utils-consumer-helpers.md +0 -0
  458. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/pactjs-utils-overview.md +0 -0
  459. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/pactjs-utils-provider-verifier.md +0 -0
  460. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/pactjs-utils-request-filter.md +0 -0
  461. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/playwright-cli.md +0 -0
  462. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/playwright-config.md +0 -0
  463. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/probability-impact.md +0 -0
  464. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/recurse.md +0 -0
  465. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/risk-governance.md +0 -0
  466. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/selective-testing.md +0 -0
  467. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/selector-resilience.md +0 -0
  468. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/test-healing-patterns.md +0 -0
  469. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/test-levels-framework.md +0 -0
  470. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/test-priorities-matrix.md +0 -0
  471. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/test-quality.md +0 -0
  472. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/timing-debugging.md +0 -0
  473. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/knowledge/visual-debugging.md +0 -0
  474. /package/lib/bmad-cache/tea/src/{testarch → agents/bmad-tea/resources}/tea-index.csv +0 -0
  475. /package/lib/bmad-cache/{cis/src/workflows/bmad-cis-problem-solving → wds/src/workflows/wds-0-alignment-signoff}/bmad-skill-manifest.yaml +0 -0
  476. /package/lib/bmad-cache/{cis/src/workflows/bmad-cis-storytelling → wds/src/workflows/wds-0-project-setup}/bmad-skill-manifest.yaml +0 -0
@@ -1,1002 +0,0 @@
1
- # /// script
2
- # requires-python = ">=3.9"
3
- # ///
4
-
5
- #!/usr/bin/env python3
6
- """
7
- Generate an interactive HTML quality report from scanner temp JSON files.
8
-
9
- Reads all *-temp.json and *-prepass.json files from a quality scan output
10
- directory, normalizes findings into a unified data model, and produces a
11
- self-contained HTML report with:
12
- - Collapsible sections with severity filter badges
13
- - Per-item copy-prompt buttons
14
- - Multi-select batch prompt generator
15
- - Executive summary with severity counts
16
-
17
- Usage:
18
- python3 generate-html-report.py {quality-report-dir} [--open] [--skill-path /path/to/skill]
19
-
20
- The --skill-path is embedded in the prompt context so generated prompts
21
- reference the correct location. If omitted, it is read from the first
22
- temp JSON that contains a skill_path field.
23
- """
24
-
25
- from __future__ import annotations
26
-
27
- import argparse
28
- import json
29
- import platform
30
- import subprocess
31
- import sys
32
- from datetime import datetime, timezone
33
- from pathlib import Path
34
-
35
-
36
- # =============================================================================
37
- # Normalization — diverse scanner JSONs → unified item model
38
- # =============================================================================
39
-
40
- SEVERITY_RANK = {
41
- 'critical': 0, 'high': 1, 'medium': 2, 'low': 3,
42
- 'high-opportunity': 1, 'medium-opportunity': 2, 'low-opportunity': 3,
43
- 'note': 4, 'strength': 5, 'suggestion': 4, 'info': 5,
44
- }
45
-
46
- # Map scanner names to report sections
47
- SCANNER_SECTIONS = {
48
- 'workflow-integrity': 'structural',
49
- 'structure': 'structure-capabilities',
50
- 'prompt-craft': 'prompt-craft',
51
- 'execution-efficiency': 'efficiency',
52
- 'skill-cohesion': 'cohesion',
53
- 'agent-cohesion': 'cohesion',
54
- 'path-standards': 'quality',
55
- 'scripts': 'scripts',
56
- 'script-opportunities': 'script-opportunities',
57
- 'enhancement-opportunities': 'creative',
58
- }
59
-
60
- SECTION_LABELS = {
61
- 'structural': 'Structural',
62
- 'structure-capabilities': 'Structure & Capabilities',
63
- 'prompt-craft': 'Prompt Craft',
64
- 'efficiency': 'Efficiency',
65
- 'cohesion': 'Cohesion',
66
- 'quality': 'Path & Script Standards',
67
- 'scripts': 'Scripts',
68
- 'script-opportunities': 'Script Opportunities',
69
- 'creative': 'Creative & Enhancements',
70
- }
71
-
72
-
73
- def _coalesce(*values) -> str:
74
- """Return the first truthy string value, or empty string."""
75
- for v in values:
76
- if v and isinstance(v, str) and v.strip() and v.strip() not in ('N/A', 'n/a', 'None'):
77
- return v.strip()
78
- return ''
79
-
80
-
81
- def _norm_severity(sev: str) -> str:
82
- """Normalize severity to lowercase, handle variants."""
83
- if not sev:
84
- return 'low'
85
- s = sev.strip().lower()
86
- # Map common variants
87
- return {
88
- 'high-opportunity': 'high-opportunity',
89
- 'medium-opportunity': 'medium-opportunity',
90
- 'low-opportunity': 'low-opportunity',
91
- }.get(s, s)
92
-
93
-
94
- def normalize_finding(f: dict, scanner: str, idx: int) -> dict:
95
- """
96
- Normalize a single finding/issue dict into the unified item model.
97
-
98
- Handles all known field name variants across scanners:
99
- Title: issue | title | description (fallback)
100
- Desc: description | rationale | observation | insight | scenario |
101
- current_behavior | current_pattern | context | nuance
102
- Action: fix | recommendation | suggestion | suggested_approach |
103
- efficient_alternative | script_alternative
104
- File: file | location | current_location
105
- Line: line | lines
106
- Cat: category | dimension
107
- Impact: user_impact | impact | estimated_savings | estimated_token_savings
108
- """
109
- sev = _norm_severity(f.get('severity', 'low'))
110
- section = SCANNER_SECTIONS.get(scanner, 'other')
111
-
112
- # Determine item type from severity
113
- if sev in ('strength', 'note') or f.get('category') == 'strength':
114
- item_type = 'strength'
115
- action_type = 'none'
116
- selectable = False
117
- elif sev.endswith('-opportunity'):
118
- item_type = 'enhancement'
119
- action_type = 'enhance'
120
- selectable = True
121
- elif f.get('category') == 'suggestion' or sev == 'suggestion':
122
- item_type = 'suggestion'
123
- action_type = 'refactor'
124
- selectable = True
125
- else:
126
- item_type = 'issue'
127
- action_type = 'fix'
128
- selectable = True
129
-
130
- # --- Title: prefer 'title', fall back to old field names ---
131
- title = _coalesce(
132
- f.get('title'),
133
- f.get('issue'),
134
- _truncate(f.get('scenario', ''), 150),
135
- _truncate(f.get('current_behavior', ''), 150),
136
- _truncate(f.get('description', ''), 150),
137
- f.get('observation', ''),
138
- )
139
- if not title:
140
- title = f.get('id', 'Finding')
141
-
142
- # --- Detail/description: prefer 'detail', fall back to old field names ---
143
- description = _coalesce(f.get('detail'))
144
- if not description:
145
- # Backward compat: coalesce old field names
146
- desc_candidates = []
147
- for key in ('description', 'rationale', 'observation', 'insight', 'scenario',
148
- 'current_behavior', 'current_pattern', 'context', 'nuance',
149
- 'assessment'):
150
- v = f.get(key)
151
- if v and isinstance(v, str) and v.strip() and v != title:
152
- desc_candidates.append(v.strip())
153
- description = ' '.join(desc_candidates) if desc_candidates else ''
154
-
155
- # --- Action: prefer 'action', fall back to old field names ---
156
- action = _coalesce(
157
- f.get('action'),
158
- f.get('fix'),
159
- f.get('recommendation'),
160
- f.get('suggestion'),
161
- f.get('suggested_approach'),
162
- f.get('efficient_alternative'),
163
- f.get('script_alternative'),
164
- )
165
-
166
- # --- File reference ---
167
- file_ref = _coalesce(
168
- f.get('file'),
169
- f.get('location'),
170
- f.get('current_location'),
171
- )
172
-
173
- # --- Line reference ---
174
- line = f.get('line')
175
- if line is None:
176
- lines_str = f.get('lines')
177
- if lines_str:
178
- line = str(lines_str)
179
-
180
- # --- Category ---
181
- category = _coalesce(
182
- f.get('category'),
183
- f.get('dimension'),
184
- )
185
-
186
- # --- Impact (backward compat only - new schema folds into detail) ---
187
- impact = _coalesce(
188
- f.get('user_impact'),
189
- f.get('impact'),
190
- f.get('estimated_savings'),
191
- str(f.get('estimated_token_savings', '')) if f.get('estimated_token_savings') else '',
192
- )
193
-
194
- # --- Extra fields for specific scanners ---
195
- extra = {}
196
- if scanner == 'script-opportunities':
197
- action_type = 'create-script'
198
- for k in ('determinism_confidence', 'implementation_complexity',
199
- 'language', 'could_be_prepass', 'reusable_across_skills'):
200
- if k in f:
201
- extra[k] = f[k]
202
-
203
- # Use scanner-provided id if available
204
- item_id = f.get('id', f'{scanner}-{idx:03d}')
205
-
206
- return {
207
- 'id': item_id,
208
- 'scanner': scanner,
209
- 'section': section,
210
- 'type': item_type,
211
- 'severity': sev,
212
- 'rank': SEVERITY_RANK.get(sev, 3),
213
- 'category': category,
214
- 'file': file_ref,
215
- 'line': line,
216
- 'title': title,
217
- 'description': description,
218
- 'action': action,
219
- 'impact': impact,
220
- 'extra': extra,
221
- 'selectable': selectable,
222
- 'action_type': action_type,
223
- }
224
-
225
-
226
- def _truncate(text: str, max_len: int) -> str:
227
- """Truncate text to max_len, breaking at sentence boundary if possible."""
228
- if not text:
229
- return ''
230
- text = text.strip()
231
- if len(text) <= max_len:
232
- return text
233
- # Try to break at sentence boundary
234
- for end in ('. ', '.\n', ' — ', '; '):
235
- pos = text.find(end)
236
- if 0 < pos < max_len:
237
- return text[:pos + 1].strip()
238
- return text[:max_len].strip() + '...'
239
-
240
-
241
- def normalize_scanner(data: dict) -> tuple[list[dict], dict]:
242
- """
243
- Normalize a full scanner JSON into (items, meta).
244
- Returns list of normalized items + dict of meta/assessment data.
245
- Handles all known scanner output variants.
246
- """
247
- scanner = data.get('scanner', 'unknown')
248
- items = []
249
- meta = {}
250
-
251
- # New schema: findings[]. Backward compat: issues[] or findings[]
252
- findings = data.get('findings') or data.get('issues') or []
253
- for idx, f in enumerate(findings):
254
- items.append(normalize_finding(f, scanner, idx))
255
-
256
- # Backward compat: opportunities[] (execution-efficiency had separate array)
257
- for idx, opp in enumerate(data.get('opportunities', []), start=len(findings)):
258
- opp_item = normalize_finding(opp, scanner, idx)
259
- opp_item['type'] = 'enhancement'
260
- opp_item['action_type'] = 'enhance'
261
- opp_item['selectable'] = True
262
- items.append(opp_item)
263
-
264
- # Backward compat: strengths[] (old cohesion scanners — plain strings)
265
- for idx, s in enumerate(data.get('strengths', [])):
266
- text = s if isinstance(s, str) else (s.get('title', '') if isinstance(s, dict) else str(s))
267
- desc = '' if isinstance(s, str) else (s.get('description', s.get('detail', '')) if isinstance(s, dict) else '')
268
- items.append({
269
- 'id': f'{scanner}-str-{idx:03d}',
270
- 'scanner': scanner,
271
- 'section': SCANNER_SECTIONS.get(scanner, 'cohesion'),
272
- 'type': 'strength',
273
- 'severity': 'strength',
274
- 'rank': 5,
275
- 'category': 'strength',
276
- 'file': '',
277
- 'line': None,
278
- 'title': text,
279
- 'description': desc,
280
- 'action': '',
281
- 'impact': '',
282
- 'extra': {},
283
- 'selectable': False,
284
- 'action_type': 'none',
285
- })
286
-
287
- # Backward compat: creative_suggestions[] (old cohesion scanners)
288
- for idx, cs in enumerate(data.get('creative_suggestions', [])):
289
- if isinstance(cs, str):
290
- cs_title, cs_desc = cs, ''
291
- else:
292
- cs_title = _coalesce(cs.get('title'), cs.get('idea'), '')
293
- cs_desc = _coalesce(cs.get('description'), cs.get('detail'), cs.get('rationale'), '')
294
- items.append({
295
- 'id': cs.get('id', f'{scanner}-cs-{idx:03d}') if isinstance(cs, dict) else f'{scanner}-cs-{idx:03d}',
296
- 'scanner': scanner,
297
- 'section': SCANNER_SECTIONS.get(scanner, 'cohesion'),
298
- 'type': 'suggestion',
299
- 'severity': 'suggestion',
300
- 'rank': 4,
301
- 'category': cs.get('type', 'suggestion') if isinstance(cs, dict) else 'suggestion',
302
- 'file': '',
303
- 'line': None,
304
- 'title': cs_title,
305
- 'description': cs_desc,
306
- 'action': cs_title,
307
- 'impact': cs.get('estimated_impact', '') if isinstance(cs, dict) else '',
308
- 'extra': {},
309
- 'selectable': True,
310
- 'action_type': 'refactor',
311
- })
312
-
313
- # New schema: assessments{} contains all structured analysis
314
- # Backward compat: also collect from top-level keys
315
- if 'assessments' in data:
316
- meta.update(data['assessments'])
317
-
318
- # Backward compat: collect meta from top-level keys
319
- skip_keys = {'scanner', 'script', 'version', 'skill_path', 'agent_path',
320
- 'timestamp', 'scan_date', 'status', 'issues', 'findings',
321
- 'strengths', 'creative_suggestions', 'opportunities', 'assessments'}
322
- for key, val in data.items():
323
- if key not in skip_keys and key not in meta:
324
- meta[key] = val
325
-
326
- return items, meta
327
-
328
-
329
- def build_journeys(data: dict) -> list[dict]:
330
- """
331
- Extract user journey data from enhancement-opportunities scanner.
332
- Handles two formats:
333
- - Array of objects: [{archetype, journey_summary, friction_points, bright_spots}]
334
- - Object keyed by persona: {first_timer: {entry_friction, mid_flow_resilience, exit_satisfaction}}
335
- """
336
- journeys_raw = data.get('user_journeys')
337
- if not journeys_raw:
338
- return []
339
-
340
- # Format 1: already a list — normalize field names
341
- if isinstance(journeys_raw, list):
342
- normalized = []
343
- for j in journeys_raw:
344
- if isinstance(j, dict):
345
- normalized.append({
346
- 'archetype': j.get('archetype', 'unknown'),
347
- 'journey_summary': j.get('summary', j.get('journey_summary', '')),
348
- 'friction_points': j.get('friction_points', []),
349
- 'bright_spots': j.get('bright_spots', []),
350
- })
351
- else:
352
- normalized.append(j)
353
- return normalized
354
-
355
- # Format 2: object keyed by persona name
356
- if isinstance(journeys_raw, dict):
357
- result = []
358
- for persona, details in journeys_raw.items():
359
- if isinstance(details, dict):
360
- # Convert the dict-based format to the expected format
361
- journey = {
362
- 'archetype': persona.replace('_', ' ').title(),
363
- 'journey_summary': '',
364
- 'friction_points': [],
365
- 'bright_spots': [],
366
- }
367
- # Map known sub-keys to friction/bright spots
368
- for key, val in details.items():
369
- if isinstance(val, str):
370
- # Heuristic: negative-sounding keys → friction, positive → bright
371
- if any(neg in key.lower() for neg in ('friction', 'issue', 'problem', 'gap', 'pain')):
372
- journey['friction_points'].append(val)
373
- elif any(pos in key.lower() for pos in ('bright', 'strength', 'satisfaction', 'delight')):
374
- journey['bright_spots'].append(val)
375
- else:
376
- # Neutral keys — include as summary parts
377
- if journey['journey_summary']:
378
- journey['journey_summary'] += f' | {key}: {val}'
379
- else:
380
- journey['journey_summary'] = f'{key}: {val}'
381
- elif isinstance(val, list):
382
- for item in val:
383
- if isinstance(item, str):
384
- journey['friction_points'].append(item)
385
- # Build summary from all fields if not yet set
386
- if not journey['journey_summary']:
387
- parts = []
388
- for k, v in details.items():
389
- if isinstance(v, str):
390
- parts.append(f'**{k.replace("_", " ").title()}:** {v}')
391
- journey['journey_summary'] = ' | '.join(parts) if parts else str(details)
392
- result.append(journey)
393
- elif isinstance(details, str):
394
- result.append({
395
- 'archetype': persona.replace('_', ' ').title(),
396
- 'journey_summary': details,
397
- 'friction_points': [],
398
- 'bright_spots': [],
399
- })
400
- return result
401
-
402
- return []
403
-
404
-
405
- # =============================================================================
406
- # Report Data Assembly
407
- # =============================================================================
408
-
409
- def load_report_data(report_dir: Path, skill_path: str | None) -> dict:
410
- """Load all temp/prepass JSONs and assemble normalized report data."""
411
- all_items = []
412
- all_meta = {}
413
- journeys = []
414
- detected_skill_path = skill_path
415
-
416
- # Read all JSON files
417
- json_files = sorted(report_dir.glob('*.json'))
418
- for jf in json_files:
419
- try:
420
- data = json.loads(jf.read_text(encoding='utf-8'))
421
- except (json.JSONDecodeError, OSError):
422
- continue
423
-
424
- if not isinstance(data, dict):
425
- continue
426
-
427
- scanner = data.get('scanner', jf.stem.replace('-temp', '').replace('-prepass', ''))
428
-
429
- # Detect skill path from scanner data
430
- if not detected_skill_path:
431
- detected_skill_path = data.get('skill_path') or data.get('agent_path')
432
-
433
- # Only normalize temp files (not prepass)
434
- if '-temp' in jf.name or jf.name in ('path-standards-temp.json', 'scripts-temp.json'):
435
- items, meta = normalize_scanner(data)
436
- all_items.extend(items)
437
- all_meta[scanner] = meta
438
-
439
- if scanner == 'enhancement-opportunities':
440
- journeys = build_journeys(data)
441
- elif '-prepass' in jf.name:
442
- all_meta[f'prepass-{scanner}'] = data
443
-
444
- # Sort items: severity rank first, then section
445
- all_items.sort(key=lambda x: (x['rank'], x['section']))
446
-
447
- # Build severity counts
448
- counts = {'critical': 0, 'high': 0, 'medium': 0, 'low': 0}
449
- for item in all_items:
450
- if item['type'] == 'issue' and item['severity'] in counts:
451
- counts[item['severity']] += 1
452
-
453
- enhancement_count = sum(1 for i in all_items if i['type'] == 'enhancement')
454
- strength_count = sum(1 for i in all_items if i['type'] == 'strength')
455
- total_issues = sum(counts.values())
456
-
457
- # Quality grade
458
- if counts['critical'] > 0:
459
- grade = 'Poor'
460
- elif counts['high'] > 2:
461
- grade = 'Fair'
462
- elif counts['high'] > 0 or counts['medium'] > 5:
463
- grade = 'Good'
464
- else:
465
- grade = 'Excellent'
466
-
467
- # Extract assessments for display
468
- assessments = {}
469
- for scanner_key, meta in all_meta.items():
470
- for akey in ('cohesion_analysis', 'autonomous_assessment', 'skill_understanding',
471
- 'agent_identity', 'skill_identity', 'prompt_health',
472
- 'skillmd_assessment', 'top_insights'):
473
- if akey in meta:
474
- assessments[akey] = meta[akey]
475
- if 'summary' in meta:
476
- s = meta['summary']
477
- if 'craft_assessment' in s:
478
- assessments['craft_assessment'] = s['craft_assessment']
479
- if 'overall_cohesion' in s:
480
- assessments['overall_cohesion'] = s['overall_cohesion']
481
-
482
- # Skill name from path
483
- sp = detected_skill_path or str(report_dir)
484
- skill_name = Path(sp).name
485
-
486
- return {
487
- 'meta': {
488
- 'skill_name': skill_name,
489
- 'skill_path': detected_skill_path or '',
490
- 'timestamp': datetime.now(timezone.utc).isoformat(),
491
- 'scanner_count': len([f for f in json_files if '-temp' in f.name]),
492
- 'report_dir': str(report_dir),
493
- },
494
- 'executive_summary': {
495
- 'total_issues': total_issues,
496
- 'counts': counts,
497
- 'enhancement_count': enhancement_count,
498
- 'strength_count': strength_count,
499
- 'grade': grade,
500
- 'craft_assessment': assessments.get('craft_assessment', ''),
501
- 'overall_cohesion': assessments.get('overall_cohesion', ''),
502
- },
503
- 'items': all_items,
504
- 'journeys': journeys,
505
- 'assessments': assessments,
506
- 'section_labels': SECTION_LABELS,
507
- }
508
-
509
-
510
- # =============================================================================
511
- # HTML Generation
512
- # =============================================================================
513
-
514
- HTML_TEMPLATE = r"""<!DOCTYPE html>
515
- <html lang="en">
516
- <head>
517
- <meta charset="utf-8">
518
- <meta name="viewport" content="width=device-width, initial-scale=1">
519
- <title>Quality Report: SKILL_NAME_PLACEHOLDER</title>
520
- <style>
521
- :root {
522
- --bg: #0d1117; --surface: #161b22; --surface2: #21262d; --border: #30363d;
523
- --text: #e6edf3; --text-muted: #8b949e; --text-dim: #6e7681;
524
- --critical: #f85149; --high: #f0883e; --medium: #d29922; --low: #58a6ff;
525
- --strength: #3fb950; --suggestion: #a371f7; --info: #8b949e;
526
- --accent: #58a6ff; --accent-hover: #79c0ff;
527
- --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
528
- --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
529
- }
530
- @media (prefers-color-scheme: light) {
531
- :root {
532
- --bg: #ffffff; --surface: #f6f8fa; --surface2: #eaeef2; --border: #d0d7de;
533
- --text: #1f2328; --text-muted: #656d76; --text-dim: #8c959f;
534
- --critical: #cf222e; --high: #bc4c00; --medium: #9a6700; --low: #0969da;
535
- --strength: #1a7f37; --suggestion: #8250df; --info: #656d76;
536
- --accent: #0969da; --accent-hover: #0550ae;
537
- }
538
- }
539
- * { margin: 0; padding: 0; box-sizing: border-box; }
540
- body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.5; padding: 2rem; max-width: 960px; margin: 0 auto; padding-bottom: 6rem; }
541
- h1 { font-size: 1.5rem; margin-bottom: 0.25rem; }
542
- .subtitle { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 1.5rem; }
543
- .badge { display: inline-flex; align-items: center; padding: 0.15rem 0.5rem; border-radius: 2rem; font-size: 0.75rem; font-weight: 600; cursor: pointer; border: 2px solid transparent; transition: all 0.15s; user-select: none; }
544
- .badge:hover { filter: brightness(1.2); }
545
- .badge.active { border-color: currentColor; }
546
- .badge-critical { background: color-mix(in srgb, var(--critical) 20%, transparent); color: var(--critical); }
547
- .badge-high { background: color-mix(in srgb, var(--high) 20%, transparent); color: var(--high); }
548
- .badge-medium { background: color-mix(in srgb, var(--medium) 20%, transparent); color: var(--medium); }
549
- .badge-low { background: color-mix(in srgb, var(--low) 20%, transparent); color: var(--low); }
550
- .badge-strength { background: color-mix(in srgb, var(--strength) 20%, transparent); color: var(--strength); }
551
- .badge-suggestion, .badge-note { background: color-mix(in srgb, var(--suggestion) 20%, transparent); color: var(--suggestion); }
552
- .badge-high-opportunity { background: color-mix(in srgb, var(--high) 20%, transparent); color: var(--high); }
553
- .badge-medium-opportunity { background: color-mix(in srgb, var(--medium) 20%, transparent); color: var(--medium); }
554
- .badge-low-opportunity { background: color-mix(in srgb, var(--low) 20%, transparent); color: var(--low); }
555
- .badge-info { background: color-mix(in srgb, var(--info) 20%, transparent); color: var(--info); }
556
- .grade { font-size: 2rem; font-weight: 700; }
557
- .grade-Excellent { color: var(--strength); }
558
- .grade-Good { color: var(--low); }
559
- .grade-Fair { color: var(--medium); }
560
- .grade-Poor { color: var(--critical); }
561
- .summary-grid { display: grid; grid-template-columns: auto 1fr; gap: 0.75rem 2rem; margin: 1rem 0; align-items: baseline; }
562
- .summary-grid dt { color: var(--text-muted); font-size: 0.85rem; }
563
- .summary-grid dd { font-size: 0.95rem; }
564
- .filters { display: flex; gap: 0.5rem; flex-wrap: wrap; margin: 1rem 0; }
565
- .section { border: 1px solid var(--border); border-radius: 0.5rem; margin: 0.75rem 0; overflow: hidden; }
566
- .section-header { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem 1rem; background: var(--surface); cursor: pointer; user-select: none; }
567
- .section-header:hover { background: var(--surface2); }
568
- .section-header .arrow { font-size: 0.7rem; transition: transform 0.15s; color: var(--text-muted); width: 1rem; }
569
- .section-header.open .arrow { transform: rotate(90deg); }
570
- .section-header .label { font-weight: 600; flex: 1; }
571
- .section-header .count { font-size: 0.8rem; color: var(--text-muted); }
572
- .section-body { display: none; }
573
- .section-body.open { display: block; }
574
- .item { display: flex; gap: 0.75rem; padding: 0.75rem 1rem; border-top: 1px solid var(--border); align-items: flex-start; }
575
- .item:hover { background: var(--surface); }
576
- .item-check { margin-top: 0.2rem; accent-color: var(--accent); flex-shrink: 0; }
577
- .item-body { flex: 1; min-width: 0; }
578
- .item-title { font-weight: 600; font-size: 0.9rem; }
579
- .item-file { font-family: var(--mono); font-size: 0.75rem; color: var(--text-muted); }
580
- .item-desc { font-size: 0.85rem; color: var(--text-muted); margin-top: 0.25rem; }
581
- .item-action { font-size: 0.85rem; margin-top: 0.25rem; }
582
- .item-action strong { color: var(--strength); }
583
- .item-impact { font-size: 0.8rem; color: var(--text-dim); margin-top: 0.2rem; font-style: italic; }
584
- .item-actions { flex-shrink: 0; display: flex; gap: 0.25rem; }
585
- .copy-btn { background: none; border: 1px solid var(--border); border-radius: 0.25rem; padding: 0.2rem 0.4rem; cursor: pointer; color: var(--text-muted); font-size: 0.75rem; transition: all 0.15s; }
586
- .copy-btn:hover { border-color: var(--accent); color: var(--accent); }
587
- .copy-btn.copied { border-color: var(--strength); color: var(--strength); }
588
- .journey { padding: 0.75rem 1rem; border-top: 1px solid var(--border); }
589
- .journey h4 { font-size: 0.9rem; text-transform: capitalize; }
590
- .journey p { font-size: 0.85rem; color: var(--text-muted); margin: 0.25rem 0; }
591
- .journey ul { font-size: 0.85rem; padding-left: 1.25rem; margin: 0.25rem 0; }
592
- .journey .friction { color: var(--high); }
593
- .journey .bright { color: var(--strength); }
594
- .assessment { padding: 0.75rem 1rem; border-top: 1px solid var(--border); }
595
- .assessment table { width: 100%; border-collapse: collapse; font-size: 0.85rem; margin-top: 0.5rem; }
596
- .assessment th, .assessment td { text-align: left; padding: 0.3rem 0.5rem; border-bottom: 1px solid var(--border); }
597
- .assessment th { color: var(--text-muted); font-weight: 600; }
598
- .sticky-footer { position: fixed; bottom: 0; left: 0; right: 0; background: var(--surface); border-top: 1px solid var(--border); padding: 0.75rem 2rem; display: flex; align-items: center; justify-content: center; gap: 1rem; z-index: 100; transition: transform 0.2s; }
599
- .sticky-footer.hidden { transform: translateY(100%); }
600
- .gen-btn { background: var(--accent); color: #fff; border: none; padding: 0.5rem 1.25rem; border-radius: 0.375rem; cursor: pointer; font-weight: 600; font-size: 0.9rem; }
601
- .gen-btn:hover { background: var(--accent-hover); }
602
- .sel-count { font-size: 0.9rem; color: var(--text-muted); }
603
- .modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.6); z-index: 200; align-items: center; justify-content: center; }
604
- .modal-overlay.visible { display: flex; }
605
- .modal { background: var(--surface); border: 1px solid var(--border); border-radius: 0.5rem; padding: 1.5rem; width: 90%; max-width: 700px; max-height: 80vh; overflow-y: auto; }
606
- .modal h3 { margin-bottom: 0.75rem; }
607
- .modal pre { background: var(--bg); border: 1px solid var(--border); border-radius: 0.375rem; padding: 1rem; font-family: var(--mono); font-size: 0.8rem; white-space: pre-wrap; word-wrap: break-word; max-height: 50vh; overflow-y: auto; }
608
- .modal-actions { display: flex; gap: 0.75rem; margin-top: 1rem; justify-content: flex-end; }
609
- .modal-actions button { padding: 0.4rem 1rem; border-radius: 0.375rem; cursor: pointer; font-size: 0.85rem; }
610
- .modal-close { background: var(--surface2); border: 1px solid var(--border); color: var(--text); }
611
- .modal-copy { background: var(--accent); border: none; color: #fff; font-weight: 600; }
612
- .empty-msg { color: var(--text-dim); font-size: 0.85rem; padding: 1rem; font-style: italic; }
613
- </style>
614
- </head>
615
- <body>
616
-
617
- <h1>Quality Report: <span id="skill-name"></span></h1>
618
- <div class="subtitle" id="subtitle"></div>
619
-
620
- <div id="exec-summary"></div>
621
-
622
- <div class="filters" id="filters"></div>
623
-
624
- <div id="sections"></div>
625
-
626
- <div class="sticky-footer hidden" id="footer">
627
- <span class="sel-count"><span id="sel-count">0</span> selected</span>
628
- <button class="gen-btn" onclick="showBatchPrompt()">Generate Prompt</button>
629
- </div>
630
-
631
- <div class="modal-overlay" id="modal" onclick="if(event.target===this)closeModal()">
632
- <div class="modal">
633
- <h3 id="modal-title">Generated Prompt</h3>
634
- <pre id="modal-content"></pre>
635
- <div class="modal-actions">
636
- <button class="modal-close" onclick="closeModal()">Close</button>
637
- <button class="modal-copy" onclick="copyModal()">Copy to Clipboard</button>
638
- </div>
639
- </div>
640
- </div>
641
-
642
- <script>
643
- const DATA = JSON.parse(document.getElementById('report-data').textContent);
644
- const selected = new Set();
645
-
646
- function init() {
647
- const m = DATA.meta;
648
- const es = DATA.executive_summary;
649
- document.getElementById('skill-name').textContent = m.skill_name;
650
- document.getElementById('subtitle').textContent = `${m.skill_path} \u2022 ${m.timestamp.split('T')[0]} \u2022 ${m.scanner_count} scanners`;
651
-
652
- // Executive summary
653
- let html = `<div class="grade grade-${es.grade}">${es.grade}</div>`;
654
- html += `<dl class="summary-grid">`;
655
- html += `<dt>Issues</dt><dd>${es.total_issues} total \u2014 ${es.counts.critical} critical, ${es.counts.high} high, ${es.counts.medium} medium, ${es.counts.low} low</dd>`;
656
- if (es.enhancement_count) html += `<dt>Enhancements</dt><dd>${es.enhancement_count} opportunities identified</dd>`;
657
- if (es.strength_count) html += `<dt>Strengths</dt><dd>${es.strength_count} noted</dd>`;
658
- if (es.craft_assessment) html += `<dt>Craft</dt><dd>${esc(es.craft_assessment)}</dd>`;
659
- if (es.overall_cohesion) html += `<dt>Cohesion</dt><dd>${esc(es.overall_cohesion)}</dd>`;
660
- html += `</dl>`;
661
- document.getElementById('exec-summary').innerHTML = html;
662
-
663
- // Severity filters
664
- renderFilters();
665
-
666
- // Sections
667
- renderSections();
668
- }
669
-
670
- // --- Severity filters ---
671
- const activeFilters = new Set(['critical','high','medium','low','high-opportunity','medium-opportunity','low-opportunity','strength','suggestion','note','info']);
672
-
673
- function renderFilters() {
674
- const counts = {};
675
- DATA.items.forEach(i => { counts[i.severity] = (counts[i.severity]||0) + 1; });
676
- const order = ['critical','high','medium','low','high-opportunity','medium-opportunity','low-opportunity','strength','suggestion','note'];
677
- let html = '';
678
- order.forEach(s => {
679
- if (!counts[s]) return;
680
- const active = activeFilters.has(s) ? 'active' : '';
681
- html += `<span class="badge badge-${s} ${active}" data-sev="${s}" onclick="toggleFilter('${s}')">${s.replace('-',' ')} ${counts[s]}</span>`;
682
- });
683
- document.getElementById('filters').innerHTML = html;
684
- }
685
-
686
- function toggleFilter(sev) {
687
- if (activeFilters.has(sev)) activeFilters.delete(sev); else activeFilters.add(sev);
688
- renderFilters();
689
- renderSections();
690
- }
691
-
692
- // --- Sections ---
693
- function renderSections() {
694
- const groups = {};
695
- const sectionOrder = ['structural','structure-capabilities','prompt-craft','cohesion','efficiency','quality','scripts','script-opportunities','creative'];
696
-
697
- DATA.items.forEach(i => {
698
- if (!activeFilters.has(i.severity)) return;
699
- const s = i.section;
700
- if (!groups[s]) groups[s] = [];
701
- groups[s].push(i);
702
- });
703
-
704
- // Truly broken (always first, always open)
705
- const broken = DATA.items.filter(i => i.type === 'issue' && (i.severity === 'critical' || i.severity === 'high'));
706
- const brokenIds = new Set(broken.map(i => i.id));
707
- // Strengths
708
- const strengths = DATA.items.filter(i => i.type === 'strength' && activeFilters.has(i.severity));
709
-
710
- let html = '';
711
-
712
- if (broken.length) {
713
- html += renderSection('truly-broken', `Truly Broken / Missing (${broken.length})`, broken, true);
714
- }
715
- if (strengths.length) {
716
- html += renderSection('strengths', `Strengths (${strengths.length})`, strengths, false);
717
- }
718
-
719
- sectionOrder.forEach(sec => {
720
- // Exclude strengths (shown above) and items already in Truly Broken
721
- const items = (groups[sec] || []).filter(i => i.type !== 'strength' && !brokenIds.has(i.id));
722
- if (!items.length) return;
723
- const label = DATA.section_labels[sec] || sec;
724
- html += renderSection(sec, `${label} (${items.length})`, items, false);
725
- });
726
-
727
- // User journeys
728
- if (DATA.journeys.length) {
729
- html += renderJourneysSection();
730
- }
731
-
732
- // Assessments
733
- if (Object.keys(DATA.assessments).length) {
734
- html += renderAssessmentsSection();
735
- }
736
-
737
- document.getElementById('sections').innerHTML = html;
738
- }
739
-
740
- function renderSection(id, label, items, startOpen) {
741
- const openCls = startOpen ? 'open' : '';
742
- let html = `<div class="section"><div class="section-header ${openCls}" onclick="toggleSection(this)">`;
743
- html += `<span class="arrow">\u25B6</span><span class="label">${label}</span>`;
744
- html += `</div><div class="section-body ${openCls}">`;
745
- items.forEach(i => { html += renderItem(i); });
746
- html += `</div></div>`;
747
- return html;
748
- }
749
-
750
- function renderItem(item) {
751
- const isStrength = item.type === 'strength';
752
- const chk = item.selectable ? `<input type="checkbox" class="item-check" data-id="${item.id}" ${selected.has(item.id)?'checked':''} onchange="toggleSelect('${item.id}', this.checked)">` : '';
753
- const sev = `<span class="badge badge-${item.severity}">${item.severity.replace('-',' ')}</span>`;
754
- const file = item.file ? `<span class="item-file">${esc(item.file)}${item.line ? ':'+item.line : ''}</span>` : '';
755
- const desc = item.description && item.description !== item.title ? `<div class="item-desc">${esc(item.description)}</div>` : '';
756
- // Suppress action/impact for strengths — "N/A" is noise
757
- const actionText = item.action && !isStrength && item.action !== 'N/A' ? item.action : '';
758
- const action = actionText ? `<div class="item-action"><strong>${item.action_type === 'fix' ? 'Fix' : item.action_type === 'create-script' ? 'Script' : 'Suggestion'}:</strong> ${esc(actionText)}</div>` : '';
759
- const impactText = item.impact && !isStrength && item.impact !== 'N/A' ? item.impact : '';
760
- const impact = impactText ? `<div class="item-impact">Impact: ${esc(impactText)}</div>` : '';
761
- const copyBtn = item.selectable ? `<button class="copy-btn" onclick="copySinglePrompt('${item.id}')" title="Copy prompt for this item">\u2398</button>` : '';
762
-
763
- return `<div class="item">${chk}<div class="item-body">${sev} ${file}<div class="item-title">${esc(item.title)}</div>${desc}${action}${impact}</div><div class="item-actions">${copyBtn}</div></div>`;
764
- }
765
-
766
- function renderJourneysSection() {
767
- let html = `<div class="section"><div class="section-header" onclick="toggleSection(this)">`;
768
- html += `<span class="arrow">\u25B6</span><span class="label">User Journeys (${DATA.journeys.length})</span>`;
769
- html += `</div><div class="section-body">`;
770
- DATA.journeys.forEach(j => {
771
- html += `<div class="journey"><h4>${esc(j.archetype)}</h4>`;
772
- html += `<p>${esc(j.journey_summary)}</p>`;
773
- if (j.friction_points && j.friction_points.length) {
774
- html += `<ul class="friction">`;
775
- j.friction_points.forEach(fp => { html += `<li>${esc(fp)}</li>`; });
776
- html += `</ul>`;
777
- }
778
- if (j.bright_spots && j.bright_spots.length) {
779
- html += `<ul class="bright">`;
780
- j.bright_spots.forEach(bs => { html += `<li>${esc(bs)}</li>`; });
781
- html += `</ul>`;
782
- }
783
- html += `</div>`;
784
- });
785
- html += `</div></div>`;
786
- return html;
787
- }
788
-
789
- function renderAssessmentsSection() {
790
- let html = `<div class="section"><div class="section-header" onclick="toggleSection(this)">`;
791
- html += `<span class="arrow">\u25B6</span><span class="label">Assessments & Analysis</span>`;
792
- html += `</div><div class="section-body">`;
793
-
794
- const ca = DATA.assessments.cohesion_analysis;
795
- if (ca) {
796
- html += `<div class="assessment"><h4>Cohesion Analysis</h4><table><tr><th>Dimension</th><th>Score</th><th>Notes</th></tr>`;
797
- Object.entries(ca).forEach(([dim, val]) => {
798
- if (typeof val === 'object' && val.score) {
799
- html += `<tr><td>${esc(dim.replace(/_/g, ' '))}</td><td>${esc(val.score)}</td><td>${esc(val.notes || '')}</td></tr>`;
800
- }
801
- });
802
- html += `</table></div>`;
803
- }
804
-
805
- const aa = DATA.assessments.autonomous_assessment;
806
- if (aa) {
807
- html += `<div class="assessment"><h4>Autonomous Readiness</h4><table>`;
808
- html += `<tr><td>Overall Potential</td><td>${esc(aa.potential||aa.overall_potential||'')}</td></tr>`;
809
- html += `<tr><td>HITL Points</td><td>${aa.hitl_points||aa.hitl_interaction_points||0}</td></tr>`;
810
- html += `<tr><td>Auto-Resolvable</td><td>${aa.auto_resolvable||0}</td></tr>`;
811
- html += `<tr><td>Needs Input</td><td>${aa.needs_input||0}</td></tr>`;
812
- if (aa.notes) html += `<tr><td>Notes</td><td>${esc(aa.notes)}</td></tr>`;
813
- html += `</table></div>`;
814
- }
815
-
816
- const ti = DATA.assessments.top_insights;
817
- if (ti && ti.length) {
818
- html += `<div class="assessment"><h4>Top Insights</h4>`;
819
- ti.forEach(t => {
820
- const tiTitle = t.title || t.insight || '';
821
- const tiDetail = t.detail || t.why_it_matters || '';
822
- const tiAction = t.action || t.suggestion || '';
823
- html += `<div style="margin:0.5rem 0"><strong>${esc(tiTitle)}</strong>`;
824
- if (tiDetail) html += `<br><em>Context:</em> ${esc(tiDetail)}`;
825
- if (tiAction) html += `<br><em>Suggestion:</em> ${esc(tiAction)}`;
826
- html += `</div>`;
827
- });
828
- html += `</div>`;
829
- }
830
-
831
- html += `</div></div>`;
832
- return html;
833
- }
834
-
835
- // --- Interactions ---
836
- function toggleSection(el) {
837
- el.classList.toggle('open');
838
- el.nextElementSibling.classList.toggle('open');
839
- }
840
-
841
- function toggleSelect(id, checked) {
842
- if (checked) selected.add(id); else selected.delete(id);
843
- document.getElementById('sel-count').textContent = selected.size;
844
- document.getElementById('footer').classList.toggle('hidden', selected.size === 0);
845
- }
846
-
847
- // --- Prompt Generation ---
848
- function itemById(id) { return DATA.items.find(i => i.id === id); }
849
-
850
- function buildPromptForItem(item) {
851
- let p = '';
852
- const sev = item.severity.replace('-', ' ').toUpperCase();
853
- const loc = item.file ? `${item.file}${item.line ? ':'+item.line : ''}` : '';
854
- p += `**[${sev}] ${item.title}**\n`;
855
- if (loc) p += `- File: ${loc}\n`;
856
- if (item.description && item.description !== item.title) p += `- Context: ${item.description}\n`;
857
- if (item.action) {
858
- const label = item.action_type === 'fix' ? 'Fix' : item.action_type === 'create-script' ? 'Create script' : 'Suggestion';
859
- p += `- ${label}: ${item.action}\n`;
860
- }
861
- if (item.impact) p += `- Impact: ${item.impact}\n`;
862
- return p;
863
- }
864
-
865
- function buildPrompt(ids) {
866
- const items = ids.map(itemById).filter(Boolean);
867
- const fixes = items.filter(i => i.action_type === 'fix');
868
- const scripts = items.filter(i => i.action_type === 'create-script');
869
- const enhancements = items.filter(i => i.action_type === 'enhance' || i.action_type === 'refactor');
870
-
871
- let prompt = `## Task: Quality Improvements for ${DATA.meta.skill_name}\nSkill path: ${DATA.meta.skill_path}\n\n`;
872
-
873
- if (fixes.length) {
874
- prompt += `### Fix These Issues (${fixes.length})\n\n`;
875
- fixes.forEach((item, i) => { prompt += `${i+1}. ${buildPromptForItem(item)}\n`; });
876
- }
877
- if (scripts.length) {
878
- prompt += `### Create These Scripts (${scripts.length})\n\n`;
879
- scripts.forEach((item, i) => { prompt += `${i+1}. ${buildPromptForItem(item)}\n`; });
880
- }
881
- if (enhancements.length) {
882
- prompt += `### Implement These Enhancements (${enhancements.length})\n\n`;
883
- enhancements.forEach((item, i) => { prompt += `${i+1}. ${buildPromptForItem(item)}\n`; });
884
- }
885
- return prompt.trim();
886
- }
887
-
888
- function copySinglePrompt(id) {
889
- const item = itemById(id);
890
- if (!item) return;
891
- let prompt = `## Task: Quality Fix for ${DATA.meta.skill_name}\nSkill path: ${DATA.meta.skill_path}\n\n`;
892
- prompt += buildPromptForItem(item);
893
- navigator.clipboard.writeText(prompt).then(() => {
894
- const btn = document.querySelector(`[onclick="copySinglePrompt('${id}')"]`);
895
- if (btn) { btn.classList.add('copied'); btn.textContent = '\u2713'; setTimeout(() => { btn.classList.remove('copied'); btn.textContent = '\u2398'; }, 1500); }
896
- });
897
- }
898
-
899
- function showBatchPrompt() {
900
- const prompt = buildPrompt([...selected]);
901
- document.getElementById('modal-content').textContent = prompt;
902
- document.getElementById('modal').classList.add('visible');
903
- }
904
-
905
- function closeModal() { document.getElementById('modal').classList.remove('visible'); }
906
-
907
- function copyModal() {
908
- const text = document.getElementById('modal-content').textContent;
909
- navigator.clipboard.writeText(text).then(() => {
910
- const btn = document.querySelector('.modal-copy');
911
- btn.textContent = 'Copied!';
912
- setTimeout(() => { btn.textContent = 'Copy to Clipboard'; }, 1500);
913
- });
914
- }
915
-
916
- function esc(s) {
917
- if (!s) return '';
918
- const d = document.createElement('div');
919
- d.textContent = String(s);
920
- return d.innerHTML;
921
- }
922
-
923
- init();
924
- </script>
925
- </body>
926
- </html>"""
927
-
928
-
929
- def generate_html(report_data: dict) -> str:
930
- """Inject report data into the HTML template."""
931
- data_json = json.dumps(report_data, indent=None, ensure_ascii=False)
932
- # Embed the JSON as a script tag before the main script
933
- data_tag = f'<script id="report-data" type="application/json">{data_json}</script>'
934
- # Insert before the main <script> tag
935
- html = HTML_TEMPLATE.replace('<script>\nconst DATA', f'{data_tag}\n<script>\nconst DATA')
936
- html = html.replace('SKILL_NAME_PLACEHOLDER', report_data['meta']['skill_name'])
937
- return html
938
-
939
-
940
- # =============================================================================
941
- # CLI
942
- # =============================================================================
943
-
944
- def main() -> int:
945
- parser = argparse.ArgumentParser(
946
- description='Generate interactive HTML quality report from scanner JSON files',
947
- )
948
- parser.add_argument(
949
- 'report_dir',
950
- type=Path,
951
- help='Directory containing *-temp.json and *-prepass.json files',
952
- )
953
- parser.add_argument(
954
- '--skill-path',
955
- help='Path to the skill being scanned (auto-detected from JSON if omitted)',
956
- )
957
- parser.add_argument(
958
- '--open',
959
- action='store_true',
960
- help='Open the HTML report in the default browser',
961
- )
962
- parser.add_argument(
963
- '--output', '-o',
964
- type=Path,
965
- help='Output HTML file path (default: {report_dir}/quality-report.html)',
966
- )
967
- args = parser.parse_args()
968
-
969
- if not args.report_dir.is_dir():
970
- print(f'Error: {args.report_dir} is not a directory', file=sys.stderr)
971
- return 2
972
-
973
- report_data = load_report_data(args.report_dir, args.skill_path)
974
-
975
- if not report_data['items']:
976
- print('Warning: No scanner data found in directory', file=sys.stderr)
977
-
978
- html = generate_html(report_data)
979
-
980
- output_path = args.output or (args.report_dir / 'quality-report.html')
981
- output_path.write_text(html, encoding='utf-8')
982
- print(json.dumps({
983
- 'html_report': str(output_path),
984
- 'items': len(report_data['items']),
985
- 'issues': report_data['executive_summary']['total_issues'],
986
- 'grade': report_data['executive_summary']['grade'],
987
- }))
988
-
989
- if args.open:
990
- system = platform.system()
991
- if system == 'Darwin':
992
- subprocess.run(['open', str(output_path)])
993
- elif system == 'Linux':
994
- subprocess.run(['xdg-open', str(output_path)])
995
- elif system == 'Windows':
996
- subprocess.run(['start', str(output_path)], shell=True)
997
-
998
- return 0
999
-
1000
-
1001
- if __name__ == '__main__':
1002
- sys.exit(main())