drt-method 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (299) hide show
  1. package/AGENTS.md +45 -0
  2. package/GETTING-STARTED.md +269 -0
  3. package/README.md +233 -0
  4. package/drt-method-1.0.0.tgz +0 -0
  5. package/drt-modules.yaml +1 -0
  6. package/package.json +51 -0
  7. package/scripts/install-from-github.ps1 +22 -0
  8. package/scripts/install-from-github.sh +17 -0
  9. package/src/core-skills/drt-advanced-elicitation/SKILL.md +142 -0
  10. package/src/core-skills/drt-advanced-elicitation/methods.csv +72 -0
  11. package/src/core-skills/drt-brainstorming/SKILL.md +80 -0
  12. package/src/core-skills/drt-brainstorming/assets/brain-icons.json +166 -0
  13. package/src/core-skills/drt-brainstorming/assets/brain-methods.csv +109 -0
  14. package/src/core-skills/drt-brainstorming/assets/brain-selector.html +326 -0
  15. package/src/core-skills/drt-brainstorming/customize.toml +84 -0
  16. package/src/core-skills/drt-brainstorming/references/converge.md +24 -0
  17. package/src/core-skills/drt-brainstorming/references/finalize.md +26 -0
  18. package/src/core-skills/drt-brainstorming/references/headless.md +54 -0
  19. package/src/core-skills/drt-brainstorming/references/in-chat-techniques.md +18 -0
  20. package/src/core-skills/drt-brainstorming/references/mode-autonomous.md +10 -0
  21. package/src/core-skills/drt-brainstorming/references/mode-facilitator.md +11 -0
  22. package/src/core-skills/drt-brainstorming/references/mode-partner.md +16 -0
  23. package/src/core-skills/drt-brainstorming/references/resume.md +5 -0
  24. package/src/core-skills/drt-brainstorming/scripts/brain.py +740 -0
  25. package/src/core-skills/drt-customize/SKILL.md +111 -0
  26. package/src/core-skills/drt-customize/scripts/list_customizable_skills.py +231 -0
  27. package/src/core-skills/drt-editorial-review-prose/SKILL.md +86 -0
  28. package/src/core-skills/drt-editorial-review-structure/SKILL.md +179 -0
  29. package/src/core-skills/drt-forge-idea/SKILL.md +107 -0
  30. package/src/core-skills/drt-forge-idea/customize.toml +42 -0
  31. package/src/core-skills/drt-forge-idea/scripts/resolve_personas.py +270 -0
  32. package/src/core-skills/drt-help/SKILL.md +75 -0
  33. package/src/core-skills/drt-index-docs/SKILL.md +66 -0
  34. package/src/core-skills/drt-party-mode/SKILL.md +60 -0
  35. package/src/core-skills/drt-party-mode/customize.toml +211 -0
  36. package/src/core-skills/drt-party-mode/references/create-party.md +70 -0
  37. package/src/core-skills/drt-party-mode/references/mode-agent-team.md +13 -0
  38. package/src/core-skills/drt-party-mode/references/mode-auto.md +13 -0
  39. package/src/core-skills/drt-party-mode/references/mode-subagent.md +31 -0
  40. package/src/core-skills/drt-party-mode/references/party-memory.md +51 -0
  41. package/src/core-skills/drt-party-mode/scripts/resolve_party.py +272 -0
  42. package/src/core-skills/drt-review-adversarial-general/SKILL.md +37 -0
  43. package/src/core-skills/drt-review-edge-case-hunter/SKILL.md +73 -0
  44. package/src/core-skills/drt-review-edge-case-hunter/references/deletion-check.md +14 -0
  45. package/src/core-skills/drt-review-verification-gap/SKILL.md +106 -0
  46. package/src/core-skills/drt-shard-doc/SKILL.md +105 -0
  47. package/src/core-skills/drt-spec/SKILL.md +160 -0
  48. package/src/core-skills/drt-spec/assets/headless-schemas.md +33 -0
  49. package/src/core-skills/drt-spec/assets/spec-template.md +49 -0
  50. package/src/core-skills/drt-spec/assets/stories-schema.md +44 -0
  51. package/src/core-skills/drt-spec/customize.toml +53 -0
  52. package/src/core-skills/module-help.csv +14 -0
  53. package/src/core-skills/module.yaml +33 -0
  54. package/src/drt-skills/1-analysis/drt-agent-analyst/SKILL.md +76 -0
  55. package/src/drt-skills/1-analysis/drt-agent-analyst/customize.toml +90 -0
  56. package/src/drt-skills/1-analysis/drt-agent-tech-writer/SKILL.md +76 -0
  57. package/src/drt-skills/1-analysis/drt-agent-tech-writer/customize.toml +81 -0
  58. package/src/drt-skills/1-analysis/drt-agent-tech-writer/explain-concept.md +20 -0
  59. package/src/drt-skills/1-analysis/drt-agent-tech-writer/mermaid-gen.md +20 -0
  60. package/src/drt-skills/1-analysis/drt-agent-tech-writer/validate-doc.md +19 -0
  61. package/src/drt-skills/1-analysis/drt-agent-tech-writer/write-document.md +20 -0
  62. package/src/drt-skills/1-analysis/drt-document-project/SKILL.md +62 -0
  63. package/src/drt-skills/1-analysis/drt-document-project/checklist.md +245 -0
  64. package/src/drt-skills/1-analysis/drt-document-project/customize.toml +41 -0
  65. package/src/drt-skills/1-analysis/drt-document-project/documentation-requirements.csv +12 -0
  66. package/src/drt-skills/1-analysis/drt-document-project/instructions.md +128 -0
  67. package/src/drt-skills/1-analysis/drt-document-project/templates/deep-dive-template.md +345 -0
  68. package/src/drt-skills/1-analysis/drt-document-project/templates/index-template.md +169 -0
  69. package/src/drt-skills/1-analysis/drt-document-project/templates/project-overview-template.md +103 -0
  70. package/src/drt-skills/1-analysis/drt-document-project/templates/project-scan-report-schema.json +160 -0
  71. package/src/drt-skills/1-analysis/drt-document-project/templates/source-tree-template.md +135 -0
  72. package/src/drt-skills/1-analysis/drt-document-project/workflows/deep-dive-instructions.md +300 -0
  73. package/src/drt-skills/1-analysis/drt-document-project/workflows/deep-dive-workflow.md +34 -0
  74. package/src/drt-skills/1-analysis/drt-document-project/workflows/full-scan-instructions.md +1111 -0
  75. package/src/drt-skills/1-analysis/drt-document-project/workflows/full-scan-workflow.md +34 -0
  76. package/src/drt-skills/1-analysis/drt-prfaq/SKILL.md +135 -0
  77. package/src/drt-skills/1-analysis/drt-prfaq/agents/artifact-analyzer.md +60 -0
  78. package/src/drt-skills/1-analysis/drt-prfaq/agents/web-researcher.md +49 -0
  79. package/src/drt-skills/1-analysis/drt-prfaq/assets/prfaq-template.md +62 -0
  80. package/src/drt-skills/1-analysis/drt-prfaq/bmad-manifest.json +16 -0
  81. package/src/drt-skills/1-analysis/drt-prfaq/customize.toml +41 -0
  82. package/src/drt-skills/1-analysis/drt-prfaq/references/customer-faq.md +55 -0
  83. package/src/drt-skills/1-analysis/drt-prfaq/references/internal-faq.md +51 -0
  84. package/src/drt-skills/1-analysis/drt-prfaq/references/press-release.md +60 -0
  85. package/src/drt-skills/1-analysis/drt-prfaq/references/verdict.md +83 -0
  86. package/src/drt-skills/1-analysis/drt-product-brief/SKILL.md +91 -0
  87. package/src/drt-skills/1-analysis/drt-product-brief/assets/brief-template.md +41 -0
  88. package/src/drt-skills/1-analysis/drt-product-brief/customize.toml +99 -0
  89. package/src/drt-skills/1-analysis/research/drt-domain-research/SKILL.md +96 -0
  90. package/src/drt-skills/1-analysis/research/drt-domain-research/customize.toml +41 -0
  91. package/src/drt-skills/1-analysis/research/drt-domain-research/domain-steps/step-01-init.md +137 -0
  92. package/src/drt-skills/1-analysis/research/drt-domain-research/domain-steps/step-02-domain-analysis.md +229 -0
  93. package/src/drt-skills/1-analysis/research/drt-domain-research/domain-steps/step-03-competitive-landscape.md +238 -0
  94. package/src/drt-skills/1-analysis/research/drt-domain-research/domain-steps/step-04-regulatory-focus.md +206 -0
  95. package/src/drt-skills/1-analysis/research/drt-domain-research/domain-steps/step-05-technical-trends.md +234 -0
  96. package/src/drt-skills/1-analysis/research/drt-domain-research/domain-steps/step-06-research-synthesis.md +450 -0
  97. package/src/drt-skills/1-analysis/research/drt-domain-research/research.template.md +29 -0
  98. package/src/drt-skills/1-analysis/research/drt-market-research/SKILL.md +96 -0
  99. package/src/drt-skills/1-analysis/research/drt-market-research/customize.toml +41 -0
  100. package/src/drt-skills/1-analysis/research/drt-market-research/research.template.md +29 -0
  101. package/src/drt-skills/1-analysis/research/drt-market-research/steps/step-01-init.md +184 -0
  102. package/src/drt-skills/1-analysis/research/drt-market-research/steps/step-02-customer-behavior.md +239 -0
  103. package/src/drt-skills/1-analysis/research/drt-market-research/steps/step-03-customer-pain-points.md +251 -0
  104. package/src/drt-skills/1-analysis/research/drt-market-research/steps/step-04-customer-decisions.md +261 -0
  105. package/src/drt-skills/1-analysis/research/drt-market-research/steps/step-05-competitive-analysis.md +173 -0
  106. package/src/drt-skills/1-analysis/research/drt-market-research/steps/step-06-research-completion.md +484 -0
  107. package/src/drt-skills/1-analysis/research/drt-technical-research/SKILL.md +96 -0
  108. package/src/drt-skills/1-analysis/research/drt-technical-research/customize.toml +41 -0
  109. package/src/drt-skills/1-analysis/research/drt-technical-research/research.template.md +29 -0
  110. package/src/drt-skills/1-analysis/research/drt-technical-research/technical-steps/step-01-init.md +137 -0
  111. package/src/drt-skills/1-analysis/research/drt-technical-research/technical-steps/step-02-technical-overview.md +239 -0
  112. package/src/drt-skills/1-analysis/research/drt-technical-research/technical-steps/step-03-integration-patterns.md +248 -0
  113. package/src/drt-skills/1-analysis/research/drt-technical-research/technical-steps/step-04-architectural-patterns.md +202 -0
  114. package/src/drt-skills/1-analysis/research/drt-technical-research/technical-steps/step-05-implementation-research.md +233 -0
  115. package/src/drt-skills/1-analysis/research/drt-technical-research/technical-steps/step-06-research-synthesis.md +493 -0
  116. package/src/drt-skills/2-plan-workflows/drt-agent-pm/SKILL.md +76 -0
  117. package/src/drt-skills/2-plan-workflows/drt-agent-pm/customize.toml +75 -0
  118. package/src/drt-skills/2-plan-workflows/drt-agent-ux-designer/SKILL.md +76 -0
  119. package/src/drt-skills/2-plan-workflows/drt-agent-ux-designer/customize.toml +60 -0
  120. package/src/drt-skills/2-plan-workflows/drt-create-prd/SKILL.md +30 -0
  121. package/src/drt-skills/2-plan-workflows/drt-create-prd/customize.toml +41 -0
  122. package/src/drt-skills/2-plan-workflows/drt-edit-prd/SKILL.md +30 -0
  123. package/src/drt-skills/2-plan-workflows/drt-edit-prd/customize.toml +42 -0
  124. package/src/drt-skills/2-plan-workflows/drt-prd/SKILL.md +92 -0
  125. package/src/drt-skills/2-plan-workflows/drt-prd/assets/headless-schemas.md +76 -0
  126. package/src/drt-skills/2-plan-workflows/drt-prd/assets/prd-template.md +165 -0
  127. package/src/drt-skills/2-plan-workflows/drt-prd/assets/prd-validation-checklist.md +135 -0
  128. package/src/drt-skills/2-plan-workflows/drt-prd/assets/validation-report-template.html +325 -0
  129. package/src/drt-skills/2-plan-workflows/drt-prd/customize.toml +147 -0
  130. package/src/drt-skills/2-plan-workflows/drt-prd/references/headless.md +39 -0
  131. package/src/drt-skills/2-plan-workflows/drt-prd/references/validate.md +97 -0
  132. package/src/drt-skills/2-plan-workflows/drt-ux/SKILL.md +90 -0
  133. package/src/drt-skills/2-plan-workflows/drt-ux/assets/color-themes.md +9 -0
  134. package/src/drt-skills/2-plan-workflows/drt-ux/assets/design-directions.md +9 -0
  135. package/src/drt-skills/2-plan-workflows/drt-ux/assets/design-example-editorial.md +158 -0
  136. package/src/drt-skills/2-plan-workflows/drt-ux/assets/design-example-mobile.md +93 -0
  137. package/src/drt-skills/2-plan-workflows/drt-ux/assets/design-example-shadcn.md +109 -0
  138. package/src/drt-skills/2-plan-workflows/drt-ux/assets/excalidraw-wireframe.md +19 -0
  139. package/src/drt-skills/2-plan-workflows/drt-ux/assets/experience-example-mobile.md +112 -0
  140. package/src/drt-skills/2-plan-workflows/drt-ux/assets/experience-example-shadcn.md +133 -0
  141. package/src/drt-skills/2-plan-workflows/drt-ux/assets/headless-schemas.md +84 -0
  142. package/src/drt-skills/2-plan-workflows/drt-ux/assets/key-screens.md +29 -0
  143. package/src/drt-skills/2-plan-workflows/drt-ux/assets/validation-report-template.html +319 -0
  144. package/src/drt-skills/2-plan-workflows/drt-ux/customize.toml +100 -0
  145. package/src/drt-skills/2-plan-workflows/drt-ux/references/creative-tools.md +19 -0
  146. package/src/drt-skills/2-plan-workflows/drt-ux/references/design-md-spec.md +50 -0
  147. package/src/drt-skills/2-plan-workflows/drt-ux/references/headless.md +37 -0
  148. package/src/drt-skills/2-plan-workflows/drt-ux/references/validate.md +115 -0
  149. package/src/drt-skills/2-plan-workflows/drt-validate-prd/SKILL.md +30 -0
  150. package/src/drt-skills/2-plan-workflows/drt-validate-prd/customize.toml +42 -0
  151. package/src/drt-skills/3-solutioning/drt-agent-architect/SKILL.md +76 -0
  152. package/src/drt-skills/3-solutioning/drt-agent-architect/customize.toml +65 -0
  153. package/src/drt-skills/3-solutioning/drt-architecture/SKILL.md +85 -0
  154. package/src/drt-skills/3-solutioning/drt-architecture/assets/spine-template.md +79 -0
  155. package/src/drt-skills/3-solutioning/drt-architecture/customize.toml +100 -0
  156. package/src/drt-skills/3-solutioning/drt-architecture/references/headless.md +26 -0
  157. package/src/drt-skills/3-solutioning/drt-architecture/references/reviewer-gate.md +13 -0
  158. package/src/drt-skills/3-solutioning/drt-architecture/scripts/lint_spine.py +257 -0
  159. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/SKILL.md +91 -0
  160. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/customize.toml +41 -0
  161. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/steps/step-01-document-discovery.md +179 -0
  162. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/steps/step-02-prd-analysis.md +168 -0
  163. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/steps/step-03-epic-coverage-validation.md +169 -0
  164. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/steps/step-04-ux-alignment.md +129 -0
  165. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/steps/step-05-epic-quality-review.md +241 -0
  166. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/steps/step-06-final-assessment.md +132 -0
  167. package/src/drt-skills/3-solutioning/drt-check-implementation-readiness/templates/readiness-report-template.md +4 -0
  168. package/src/drt-skills/3-solutioning/drt-create-architecture/SKILL.md +30 -0
  169. package/src/drt-skills/3-solutioning/drt-create-architecture/customize.toml +41 -0
  170. package/src/drt-skills/3-solutioning/drt-create-epics-and-stories/SKILL.md +93 -0
  171. package/src/drt-skills/3-solutioning/drt-create-epics-and-stories/customize.toml +41 -0
  172. package/src/drt-skills/3-solutioning/drt-create-epics-and-stories/steps/step-01-validate-prerequisites.md +263 -0
  173. package/src/drt-skills/3-solutioning/drt-create-epics-and-stories/steps/step-02-design-epics.md +242 -0
  174. package/src/drt-skills/3-solutioning/drt-create-epics-and-stories/steps/step-03-create-stories.md +255 -0
  175. package/src/drt-skills/3-solutioning/drt-create-epics-and-stories/steps/step-04-final-validation.md +143 -0
  176. package/src/drt-skills/3-solutioning/drt-create-epics-and-stories/templates/epics-template.md +61 -0
  177. package/src/drt-skills/3-solutioning/drt-generate-project-context/SKILL.md +81 -0
  178. package/src/drt-skills/3-solutioning/drt-generate-project-context/customize.toml +41 -0
  179. package/src/drt-skills/3-solutioning/drt-generate-project-context/project-context-template.md +21 -0
  180. package/src/drt-skills/3-solutioning/drt-generate-project-context/steps/step-01-discover.md +186 -0
  181. package/src/drt-skills/3-solutioning/drt-generate-project-context/steps/step-02-generate.md +321 -0
  182. package/src/drt-skills/3-solutioning/drt-generate-project-context/steps/step-03-complete.md +284 -0
  183. package/src/drt-skills/4-implementation/drt-agent-dev/SKILL.md +76 -0
  184. package/src/drt-skills/4-implementation/drt-agent-dev/customize.toml +95 -0
  185. package/src/drt-skills/4-implementation/drt-checkpoint-preview/SKILL.md +68 -0
  186. package/src/drt-skills/4-implementation/drt-checkpoint-preview/customize.toml +41 -0
  187. package/src/drt-skills/4-implementation/drt-checkpoint-preview/generate-trail.md +38 -0
  188. package/src/drt-skills/4-implementation/drt-checkpoint-preview/step-01-orientation.md +105 -0
  189. package/src/drt-skills/4-implementation/drt-checkpoint-preview/step-02-walkthrough.md +89 -0
  190. package/src/drt-skills/4-implementation/drt-checkpoint-preview/step-03-detail-pass.md +106 -0
  191. package/src/drt-skills/4-implementation/drt-checkpoint-preview/step-04-testing.md +74 -0
  192. package/src/drt-skills/4-implementation/drt-checkpoint-preview/step-05-wrapup.md +30 -0
  193. package/src/drt-skills/4-implementation/drt-code-review/SKILL.md +90 -0
  194. package/src/drt-skills/4-implementation/drt-code-review/customize.toml +93 -0
  195. package/src/drt-skills/4-implementation/drt-code-review/steps/step-01-gather-context.md +84 -0
  196. package/src/drt-skills/4-implementation/drt-code-review/steps/step-02-review.md +32 -0
  197. package/src/drt-skills/4-implementation/drt-code-review/steps/step-03-triage.md +50 -0
  198. package/src/drt-skills/4-implementation/drt-code-review/steps/step-04-present.md +132 -0
  199. package/src/drt-skills/4-implementation/drt-correct-course/SKILL.md +301 -0
  200. package/src/drt-skills/4-implementation/drt-correct-course/checklist.md +288 -0
  201. package/src/drt-skills/4-implementation/drt-correct-course/customize.toml +41 -0
  202. package/src/drt-skills/4-implementation/drt-create-story/SKILL.md +432 -0
  203. package/src/drt-skills/4-implementation/drt-create-story/checklist.md +357 -0
  204. package/src/drt-skills/4-implementation/drt-create-story/customize.toml +41 -0
  205. package/src/drt-skills/4-implementation/drt-create-story/discover-inputs.md +88 -0
  206. package/src/drt-skills/4-implementation/drt-create-story/template.md +49 -0
  207. package/src/drt-skills/4-implementation/drt-dev-auto/SKILL.md +123 -0
  208. package/src/drt-skills/4-implementation/drt-dev-auto/compile-epic-context.md +62 -0
  209. package/src/drt-skills/4-implementation/drt-dev-auto/customize.toml +108 -0
  210. package/src/drt-skills/4-implementation/drt-dev-auto/spec-template.md +98 -0
  211. package/src/drt-skills/4-implementation/drt-dev-auto/step-01-clarify-and-route.md +84 -0
  212. package/src/drt-skills/4-implementation/drt-dev-auto/step-02-plan.md +31 -0
  213. package/src/drt-skills/4-implementation/drt-dev-auto/step-03-implement.md +42 -0
  214. package/src/drt-skills/4-implementation/drt-dev-auto/step-04-review.md +95 -0
  215. package/src/drt-skills/4-implementation/drt-dev-story/SKILL.md +500 -0
  216. package/src/drt-skills/4-implementation/drt-dev-story/checklist.md +80 -0
  217. package/src/drt-skills/4-implementation/drt-dev-story/customize.toml +41 -0
  218. package/src/drt-skills/4-implementation/drt-implement-task/SKILL.md +101 -0
  219. package/src/drt-skills/4-implementation/drt-implement-task/assets/task-spec-template.md +60 -0
  220. package/src/drt-skills/4-implementation/drt-implement-task/customize.toml +17 -0
  221. package/src/drt-skills/4-implementation/drt-implement-task/steps/step-01-gather-intent.md +42 -0
  222. package/src/drt-skills/4-implementation/drt-implement-task/steps/step-02-plan-and-approve.md +43 -0
  223. package/src/drt-skills/4-implementation/drt-implement-task/steps/step-03-confirm-dependencies.md +38 -0
  224. package/src/drt-skills/4-implementation/drt-implement-task/steps/step-04-implement.md +42 -0
  225. package/src/drt-skills/4-implementation/drt-implement-task/steps/step-05-qc-test.md +31 -0
  226. package/src/drt-skills/4-implementation/drt-implement-task/steps/step-06-quality-review.md +30 -0
  227. package/src/drt-skills/4-implementation/drt-implement-task/steps/step-07-fix-findings.md +33 -0
  228. package/src/drt-skills/4-implementation/drt-implement-task/steps/step-08-complete.md +35 -0
  229. package/src/drt-skills/4-implementation/drt-qa-generate-e2e-tests/SKILL.md +176 -0
  230. package/src/drt-skills/4-implementation/drt-qa-generate-e2e-tests/checklist.md +33 -0
  231. package/src/drt-skills/4-implementation/drt-qa-generate-e2e-tests/customize.toml +41 -0
  232. package/src/drt-skills/4-implementation/drt-quick-dev/SKILL.md +13 -0
  233. package/src/drt-skills/4-implementation/drt-quick-dev/compile-epic-context.md +62 -0
  234. package/src/drt-skills/4-implementation/drt-quick-dev/customize.toml +83 -0
  235. package/src/drt-skills/4-implementation/drt-quick-dev/render.js +206 -0
  236. package/src/drt-skills/4-implementation/drt-quick-dev/spec-template.md +89 -0
  237. package/src/drt-skills/4-implementation/drt-quick-dev/step-01-clarify-and-route.md +103 -0
  238. package/src/drt-skills/4-implementation/drt-quick-dev/step-02-plan.md +47 -0
  239. package/src/drt-skills/4-implementation/drt-quick-dev/step-03-implement.md +45 -0
  240. package/src/drt-skills/4-implementation/drt-quick-dev/step-04-review.md +55 -0
  241. package/src/drt-skills/4-implementation/drt-quick-dev/step-05-present.md +78 -0
  242. package/src/drt-skills/4-implementation/drt-quick-dev/step-oneshot.md +78 -0
  243. package/src/drt-skills/4-implementation/drt-quick-dev/sync-sprint-status.md +19 -0
  244. package/src/drt-skills/4-implementation/drt-quick-dev/workflow.md +85 -0
  245. package/src/drt-skills/4-implementation/drt-retrospective/SKILL.md +1527 -0
  246. package/src/drt-skills/4-implementation/drt-retrospective/customize.toml +41 -0
  247. package/src/drt-skills/4-implementation/drt-sprint-planning/SKILL.md +319 -0
  248. package/src/drt-skills/4-implementation/drt-sprint-planning/checklist.md +34 -0
  249. package/src/drt-skills/4-implementation/drt-sprint-planning/customize.toml +41 -0
  250. package/src/drt-skills/4-implementation/drt-sprint-planning/sprint-status-template.yaml +69 -0
  251. package/src/drt-skills/4-implementation/drt-sprint-status/SKILL.md +311 -0
  252. package/src/drt-skills/4-implementation/drt-sprint-status/customize.toml +41 -0
  253. package/src/drt-skills/module-help.csv +32 -0
  254. package/src/drt-skills/module.yaml +95 -0
  255. package/src/scripts/lib/load-toml.js +43 -0
  256. package/src/scripts/lib/merge-utils.js +89 -0
  257. package/src/scripts/memlog.js +184 -0
  258. package/src/scripts/package.json +7 -0
  259. package/src/scripts/resolve-config.js +56 -0
  260. package/src/scripts/resolve-customization.js +77 -0
  261. package/tools/installer/cli-utils.js +53 -0
  262. package/tools/installer/commands/install.js +149 -0
  263. package/tools/installer/commands/status.js +65 -0
  264. package/tools/installer/commands/uninstall.js +167 -0
  265. package/tools/installer/core/config.js +73 -0
  266. package/tools/installer/core/existing-install.js +121 -0
  267. package/tools/installer/core/install-paths.js +132 -0
  268. package/tools/installer/core/installer.js +1762 -0
  269. package/tools/installer/core/legacy-warnings.js +151 -0
  270. package/tools/installer/core/manifest-generator.js +859 -0
  271. package/tools/installer/core/manifest.js +433 -0
  272. package/tools/installer/core/uv-check.js +97 -0
  273. package/tools/installer/core/wsl-node-check.js +109 -0
  274. package/tools/installer/drt-cli.js +104 -0
  275. package/tools/installer/file-ops.js +204 -0
  276. package/tools/installer/fs-native.js +116 -0
  277. package/tools/installer/ide/_config-driven.js +972 -0
  278. package/tools/installer/ide/manager.js +324 -0
  279. package/tools/installer/ide/platform-codes.js +80 -0
  280. package/tools/installer/ide/platform-codes.yaml +343 -0
  281. package/tools/installer/ide/shared/installed-skills.js +50 -0
  282. package/tools/installer/ide/shared/path-utils.js +217 -0
  283. package/tools/installer/ide/shared/skill-manifest.js +57 -0
  284. package/tools/installer/install-messages.yaml +29 -0
  285. package/tools/installer/list-options.js +210 -0
  286. package/tools/installer/message-loader.js +83 -0
  287. package/tools/installer/modules/channel-plan.js +203 -0
  288. package/tools/installer/modules/channel-resolver.js +241 -0
  289. package/tools/installer/modules/custom-module-manager.js +918 -0
  290. package/tools/installer/modules/external-manager.js +667 -0
  291. package/tools/installer/modules/module-help-schema.js +13 -0
  292. package/tools/installer/modules/official-modules.js +2257 -0
  293. package/tools/installer/modules/plugin-resolver.js +398 -0
  294. package/tools/installer/modules/version-resolver.js +336 -0
  295. package/tools/installer/project-root.js +224 -0
  296. package/tools/installer/prompts.js +852 -0
  297. package/tools/installer/set-overrides.js +330 -0
  298. package/tools/installer/ui.js +2090 -0
  299. package/tools/installer/yaml-format.js +245 -0
@@ -0,0 +1,79 @@
1
+ ---
2
+ name: '{name}'
3
+ type: architecture-spine
4
+ purpose: build-substrate # build-substrate (default) Β· discussion Β· report Β· deck
5
+ altitude: feature # initiative (keeps features) Β· feature (keeps epics) Β· epic (keeps stories)
6
+ paradigm: '{named design pattern, e.g. hexagonal, layered, pipes-and-filters, actor}'
7
+ scope: '{what this spine governs}'
8
+ status: draft # draft Β· final
9
+ created: '{date}'
10
+ updated: '{date}'
11
+ binds: [] # capability / unit IDs governed (from the driving spec; at epic altitude, also the inherited parent AD ids)
12
+ sources: []
13
+ companions: []
14
+ ---
15
+
16
+ # Architecture Spine β€” {name}
17
+
18
+ <!-- TEMPLATE GUIDE β€” act on these comments, then delete them; never emit a comment in the finished spine. This is a shape, not a script: keep only the sections this spine needs and cut the rest (no empty headers). A small intent may be just paradigm + a few ADs + conventions; a platform earns more. An inherited epic spine is usually mostly Inherited Invariants + a thin Deferred. Decisions, not rationale (rationale lives in the memlog). Carry shape in diagrams; prose only where it must. -->
19
+
20
+ ## Design Paradigm
21
+
22
+ <!-- Name the pattern (a known one loads a whole model for free) and map its layers to namespaces/directories. The smallest, most durable thing here. -->
23
+
24
+ ## Inherited Invariants
25
+
26
+ <!-- Only when this spine inherits a higher-altitude parent. The parent's ADs/conventions/paradigm that bind here, by their ORIGINAL ids β€” read-only, never renumbered, not re-derived. A local decision that contradicts one is a conflict to surface, not an override. Cut this section otherwise. -->
27
+
28
+ | Inherited | From parent | Binds here |
29
+ | --- | --- | --- |
30
+ | {AD-id / convention} | {parent spine} | {what it constrains in this scope} |
31
+
32
+ ## Invariants & Rules
33
+
34
+ <!-- The durable heart: calls a future builder can't read off compliant code. One block per decision: stable ascending id (never reused/renumbered), Binds, Prevents (the divergence), Rule (enforceable). Tag [ADOPTED] when the user or existing reality settled it. Include a dependency-direction diagram (who may depend on whom) β€” it IS a rule; author it as valid mermaid, never an empty graph. -->
35
+
36
+ ### AD-1 β€” {decision}
37
+
38
+ - **Binds:** {capability / unit ids / fr/nfr's, areas, or `all`}
39
+ - **Prevents:** {the divergence this stops}
40
+ - **Rule:** {the constraint downstream must follow}
41
+
42
+ ## Consistency Conventions
43
+
44
+ <!-- Defaults that bind where independent builders would drift. Cut rows that don't apply; add rows the project needs. -->
45
+
46
+ | Concern | Convention |
47
+ | --- | --- |
48
+ | Naming (entities, files, interfaces, events) | |
49
+ | Data & formats (ids, dates, error shapes, envelopes) | |
50
+ | State & cross-cutting (mutation, errors, logging, config, auth) | |
51
+
52
+ ## Stack
53
+
54
+ <!-- SEED β€” verified current at authoring; the code owns this once it exists. Name + version only; the why lives in the memlog. One row per language, framework, key dependency, platform, or chain that's pinned. -->
55
+
56
+ | Name | Version |
57
+ | --- | --- |
58
+ | {language / framework / key dep / platform / chain} | {pinned version} |
59
+
60
+ ## Structural Seed
61
+
62
+ <!-- The shapes worth fixing at cold-start β€” not a fixed list. Include only what's non-obvious at this altitude, and use as many diagrams as convey it, each as VALID mermaid (never a placeholder or empty graph). Candidates: system/container/context view; DEPLOYMENT & ENVIRONMENTS and external provider/infra topology (cover the operational envelope here when this altitude owns it β€” don't let it fall through); core-entity ERD (names + relationships only; an attribute that's itself an invariant is an AD, not a diagram); a minimal source tree. The code owns the detail β€” this is scaffold, not a mirror to maintain. -->
63
+
64
+ ```text
65
+ {root}/
66
+ {dir}/ # {what lives here}
67
+ ```
68
+
69
+ ## Capability β†’ Architecture Map
70
+
71
+ <!-- Present when a spec drove this run. Bridges the spec's capabilities to where they live + what governs them; the consistency auditor's checklist. Cut otherwise. -->
72
+
73
+ | Capability / Area | Lives in | Governed by |
74
+ | --- | --- | --- |
75
+ | {CAP-id / area} | {component / module} | {AD-id, convention, paradigm} |
76
+
77
+ ## Deferred
78
+
79
+ <!-- Decisions intentionally pushed down, each with the reason it can wait β€” including whole dimensions this altitude doesn't own yet. The half of the contract that keeps the spine lean. -->
@@ -0,0 +1,100 @@
1
+ # DO NOT EDIT -- overwritten on every update.
2
+ #
3
+ # Workflow customization surface for drt-architecture.
4
+ #
5
+ # Override files (not edited here):
6
+ # {project-root}/_drt/custom/drt-architecture.toml (team)
7
+ # {project-root}/_drt/custom/drt-architecture.user.toml (personal)
8
+
9
+ [workflow]
10
+
11
+ # --- Configurable below. Overrides merge per DRT structural rules: ---
12
+ # scalars: override wins β€’ arrays: append
13
+
14
+ # Steps to run before the standard activation (config load, greet).
15
+ # Use for pre-flight loads, approved-stack policy checks, etc.
16
+ activation_steps_prepend = []
17
+
18
+ # Steps to run after greet but before the workflow begins.
19
+ # Use for context-heavy setup that should happen once the user has been acknowledged.
20
+ activation_steps_append = []
21
+
22
+ # Persistent facts the workflow keeps in mind for the whole run
23
+ # (approved stacks, banned dependencies, platform constraints, compliance guardrails).
24
+ # Each entry is either a literal sentence, a skill prefixed with `skill:`, or a `file:`-prefixed
25
+ # path/glob whose contents are loaded as facts.
26
+ #
27
+ # Default loads project-context.md if drt-generate-project-context produced one β€” giving the
28
+ # architect persistent awareness of the project's tech, domain, and conventions (load-bearing
29
+ # for brownfield). Common opt-ins (set in team/user override TOML):
30
+ # "Our org is AWS-only -- do not propose GCP or Azure."
31
+ # "file:{project-root}/docs/engineering-standards.md"
32
+ persistent_facts = [
33
+ "file:{project-root}/**/project-context.md",
34
+ ]
35
+
36
+ # Executed when the workflow completes (after the spine is final and the user has been told).
37
+ # String scalar (single instruction) or array of instructions executed in order. Empty for none.
38
+ on_complete = ""
39
+
40
+ # The architecture spine template. Treated as expert prior knowledge, not a checklist β€” the LLM
41
+ # adapts it to the project, altitude, and domain, and drops sections a project genuinely doesn't
42
+ # need. Override the path in team/user TOML to enforce a different spine shape.
43
+ spine_template = "assets/spine-template.md"
44
+
45
+ # Run folder location. ARCHITECTURE-SPINE.md, its .memlog.md, and any fuller rendering the run
46
+ # produces all land inside `{spine_output_path}/{run_folder_pattern}/`. Resume-check scans
47
+ # `{spine_output_path}` for prior unfinished runs.
48
+ #
49
+ # The default pattern fits the common case (one spine per project, at the altitude above epics).
50
+ # At EPIC altitude, override run_folder_pattern to carry the epic identity so per-epic runs don't
51
+ # collide on the same day β€” e.g. set it (team/user TOML) to "architecture-epic-{epic_id}", binding
52
+ # {epic_id} from the driving spec / the activating payload. Headless callers may instead pass an
53
+ # explicit doc_workspace and bypass the pattern entirely.
54
+ spine_output_path = "{planning_artifacts}/architecture"
55
+ run_folder_pattern = "architecture-{project_name}-{date}"
56
+
57
+ # Prose-editorial standards applied at finalize ONLY to a fuller prose document the run produces
58
+ # (a discussion report, full architecture doc, or design addendum) β€” never to the spine or other
59
+ # short, structured outputs, which are terse and carry decisions in AD-n blocks and diagrams by
60
+ # design. Each entry is a `skill:`, `file:`, or plain-text directive applied before the user sees
61
+ # the polished draft. Suggested order: structural passes first, prose mechanics last. Append-only.
62
+ doc_standards = [
63
+ "skill:drt-editorial-review-structure",
64
+ "skill:drt-editorial-review-prose",
65
+ ]
66
+
67
+ # External-source registry. Natural-language directives describing knowledge bases, MCP tools, or
68
+ # internal systems the LLM may consult ON DEMAND during the run (not preemptively) β€” approved-stack
69
+ # catalogs, internal platform docs, version registries. Each entry names the tool, the trigger
70
+ # condition, and any fields it needs. If a named tool is unavailable at runtime, the LLM falls back
71
+ # to standard behavior (e.g. web research) and notes the gap. Empty by default.
72
+ #
73
+ # Examples (set in team/user override TOML):
74
+ # "When choosing a datastore, consult corp:platform_catalog before recommending one."
75
+ # "For current library versions, query corp:artifact_registry before web search."
76
+ external_sources = []
77
+
78
+ # External-handoff routing applied at Finalize to push outputs beyond local files (Confluence,
79
+ # Notion, ticket systems). Each entry names the MCP tool, the destination, and required fields.
80
+ # Runs after polish; returned URLs/IDs are surfaced. Unavailable tools are skipped and flagged;
81
+ # local files always exist. Empty by default.
82
+ external_handoffs = []
83
+
84
+ # --- Finalize reviewers ---
85
+ # Extra review lenses spawned as parallel subagents at the validation gate (Finalize and the
86
+ # Validate intent), on top of the skill's built-in good-spine checklist and the lint_spine.py
87
+ # mechanical floor. The GATE is stakes-gated β€” a throwaway spine may run it quietly or skip it β€”
88
+ # but whenever the gate runs, every entry here runs with it (the configured floor, never cherry-
89
+ # picked); only ad-hoc lenses are optional, and headless never skips the gate.
90
+ #
91
+ # Entries follow the standard prefix convention:
92
+ # "skill:NAME" invoke the named review skill as a subagent against ARCHITECTURE-SPINE.md
93
+ # "file:PATH" load the file as a review prompt; spawn an adversarial subagent applying it
94
+ # plain text use the text directly as the subagent's review prompt
95
+ #
96
+ # Resolved on-demand (not at activation). Override TOML may append.
97
+ finalize_reviewers = [
98
+ "Verify every committed decision was web-researched or reality-checked rather than asserted from training data: current library/framework versions, that each named technology still exists and fits, and β€” greenfield β€” the live defaults of any starter it leans on. Flag anything that could be out of date and wasn't confirmed against the web, the existing project, or the current starter.",
99
+ "Attack the spine as an adversary: construct two units one level down that each obey every AD to the letter yet still build incompatibly β€” clashing shared-data shapes, two owners of one entity, conflicting state-mutation paths. Every pair you find is a hole to close with a new or tightened AD.",
100
+ ]
@@ -0,0 +1,26 @@
1
+ ο»Ώ# Headless
2
+
3
+ No interactive user: infer everything, ask nothing, but never invent β€” record inferences as `assumptions[]` and gaps that need a human as `open_questions[]`. Detect headless from a `headless: true` flag, a non-interactive / no-TTY invocation, an activation hook that declares it, or a first message that pre-supplies all inputs and asks for an artifact path back; when ambiguous, default to interactive.
4
+
5
+ Drive the run from the payload in the first message β€” `intent`, `altitude`, `purpose`, the driving input (spec package / PRD / raw intent / brownfield path), a parent spine path at lower altitude, and `doc_workspace` if a specific folder is required. Infer anything absent from the inputs or workspace; don't invent stack, constraints, or scope to fill a gap. You still verify named tech on the web (you can't ask, but you can check) and still drive every write through the shared `{project-root}/_drt/scripts/memlog.js`. Run the full Reviewer Gate (`references/reviewer-gate.md`) non-interactively: `scripts/lint_spine.py` plus **every `{workflow.finalize_reviewers}` lens as a parallel subagent** (and any ad-hoc lens the spine's criticality warrants). Headless skips only the human picking from the menu β€” never the reviewers themselves; apply the clear fixes and record anything unresolved in `open_questions[]`. For a true authority collision, list it in `conflicts_with_prior_decisions[]`. For the Validate intent, always write the report to `{doc_workspace}` and add `"offer_to_update": true`. If intent stays ambiguous after inference, halt blocked.
6
+
7
+ End with JSON only, omitting keys for artifacts not produced β€” the shape below is the fully-produced (`complete`) case; a `blocked` run produces no spine, so it omits `spine`, `memlog`, and `companions` entirely (see the note under the block):
8
+
9
+ ```json
10
+ {
11
+ "status": "complete | partial | blocked",
12
+ "intent": "create | update | validate",
13
+ "altitude": "initiative | feature | epic",
14
+ "purpose": "build-substrate | discussion",
15
+ "doc_workspace": "<resolved run folder>",
16
+ "spine": "{doc_workspace}/ARCHITECTURE-SPINE.md",
17
+ "memlog": "{doc_workspace}/.memlog.md",
18
+ "companions": [],
19
+ "assumptions": [],
20
+ "open_questions": [],
21
+ "conflicts_with_prior_decisions": [],
22
+ "reason": "<one line, only when blocked>"
23
+ }
24
+ ```
25
+
26
+ `complete` stands alone Β· `partial` (spine produced, but `open_questions[]` non-empty or critical inputs inferred) means review before downstream use Β· `blocked` means no spine produced β€” return only `status`, `intent`, `reason`, and `doc_workspace` (if bound), omitting `spine`, `memlog`, `companions`, and the artifact arrays that don't exist.
@@ -0,0 +1,13 @@
1
+ # Reviewer Gate
2
+
3
+ The spine's pre-handoff review. Runs at Finalize (after distill + reconcile) and *is* the Validate intent. The difference is the ending: at Finalize you apply the clear fixes yourself; under Validate you report and don't change the spine.
4
+
5
+ Cheap deterministic pass first: `uv run {skill-root}/scripts/lint_spine.py --workspace {doc_workspace}` settles the mechanical misses (placeholders, duplicate `AD` IDs, missing Binds/Prevents/Rule, unpinned Stack versions), so reviewers spend judgment on the semantic half.
6
+
7
+ Assemble the menu: a **rubric walker** that judges the spine against the good-spine checklist below, **+ every entry in `{workflow.finalize_reviewers}`**, + ad-hoc lenses you invent or offer as the spine's rigor, altitude, and criticality warrant β€” a security/compliance lens for regulated stakes, a seam reviewer cross-team, a data-integrity lens for a heavy data model. Scale *whether and how heavily the gate runs* to the stakes: a throwaway prototype may run it quietly or skip the gate entirely; a high-criticality or platform-altitude spine earns more lenses and the explicit all / subset / skip menu. But once the gate runs, the `{workflow.finalize_reviewers}` always run β€” they are the configured floor, never cherry-picked out; only the ad-hoc lenses are optional. (Headless never skips the gate.)
8
+
9
+ Dispatch every entry as a **parallel subagent against `ARCHITECTURE-SPINE.md`** (prefix convention: `skill:` / `file:` / plain text). Each writes its full review to `{doc_workspace}/reviews/review-{slug}.md` β€” a subfolder, so the gate's scratch stays out of the deliverable folder β€” and returns ONLY a compact summary (verdict, top 2–5 findings, file path) β€” the parent never holds full review text. An inline self-check does not count: the independent context is the point, because a fresh reviewer finds the divergences the author talks past. If subagents are unavailable, run sequentially β€” write the file first, then flush it from context.
10
+
11
+ **Good-spine checklist** (what the rubric walker judges): it fixes the real divergence points for the level below and misses none; every `AD`'s Rule is enforceable and actually prevents its stated divergence; nothing under Deferred could let two units diverge; named tech is verified-current; it ratifies rather than contradicts a brownfield codebase; if a spec drove it, it covers that spec's capabilities; if a parent spine is inherited, no new `AD` weakens or contradicts an inherited one; and every dimension the altitude owns is decided, deferred, or an open question β€” a whole dimension left silent is a finding, especially the operational/environmental envelope (deployment & environments, infra/provider strategy, operations) a domain-focused draft skips.
12
+
13
+ Surface findings tiered, never dumped: a one-sentence gate verdict, then critical + high; medium/low roll into a tail ("plus N more in {file}"). Per finding: autofix, discuss, defer to Deferred / open items, or ignore. **At Finalize this is your own gate β€” apply the clear fixes rather than handing over a list; surface only what genuinely needs the user.** Under the **Validate intent**, fold every reviewer's output into one bespoke HTML + markdown report and open the HTML.
@@ -0,0 +1,257 @@
1
+ #!/usr/bin/env python3
2
+ # /// script
3
+ # requires-python = ">=3.10"
4
+ # ///
5
+ """lint-spine β€” the mechanical half of spine decision-integrity, done deterministically.
6
+
7
+ LLMs miscount IDs and miss literal placeholders; a grep does not. This linter owns the
8
+ checks a script does better than a prompt, and leaves the semantic half (is each Rule
9
+ actually enforceable? does the boundary make sense?) to the rubric walker.
10
+
11
+ It reads ARCHITECTURE-SPINE.md from a workspace and reports, as compact JSON on stdout:
12
+
13
+ - placeholder literal TBD / TODO / "similar to AD-n" / unfilled {template-token}
14
+ - ad_id duplicate or non-monotonic AD-n identifiers
15
+ - ad_fields an AD-n block missing Binds / Prevents / Rule
16
+ - version_pin a ## Stack table row with no version
17
+
18
+ Fenced code blocks are blanked (replaced with equal-count blank lines) before scanning, so
19
+ mermaid and source trees don't trip false positives AND reported line numbers still line up
20
+ with the real file. Reported lines are absolute file lines (frontmatter offset added). Exit
21
+ code is always 0 β€” findings travel in the JSON; the caller (Reviewer Gate / rubric walker)
22
+ decides what to do with them.
23
+ """
24
+ from __future__ import annotations
25
+
26
+ import argparse
27
+ import json
28
+ import re
29
+ import sys
30
+ from pathlib import Path
31
+
32
+ SPINE = "ARCHITECTURE-SPINE.md"
33
+
34
+ AD_HEADING = re.compile(r"^#{2,4}\s*AD-(\d+)\b(.*)$", re.MULTILINE)
35
+ HEADING = re.compile(r"^#{1,6}\s", re.MULTILINE)
36
+ FENCE = re.compile(r"```.*?```", re.DOTALL)
37
+ PLACEHOLDER_WORD = re.compile(r"\b(TBD|TODO|FIXME|XXX)\b")
38
+ SIMILAR_TO = re.compile(r"similar to AD-\d+", re.IGNORECASE)
39
+ TEMPLATE_TOKEN = re.compile(r"\{[a-z_][a-z0-9_ /.-]*\}")
40
+
41
+
42
+ def split_frontmatter(text: str) -> tuple[str, str, int]:
43
+ """Return (frontmatter, body, body_line_offset).
44
+
45
+ Frontmatter is the content between the first two lines that are *exactly* `---`
46
+ (line-exact, like memlog.split β€” a `---` inside a value or a body thematic break never
47
+ truncates it). body_line_offset is the number of file lines before the body begins, so a
48
+ body-relative line number plus the offset gives the absolute file line. Absent frontmatter
49
+ β†’ ('', text, 0)."""
50
+ lines = text.split("\n")
51
+ if lines and lines[0] == "---":
52
+ for i in range(1, len(lines)):
53
+ if lines[i] == "---":
54
+ fm = "\n".join(lines[1:i])
55
+ body = "\n".join(lines[i + 1:])
56
+ return fm, body, i + 1
57
+ return "", text, 0
58
+
59
+
60
+ def blank_fences(text: str) -> str:
61
+ """Replace each fenced block with the same number of newlines, so scanning skips fenced
62
+ content while every line number outside the fence stays put."""
63
+ return FENCE.sub(lambda m: "\n" * m.group(0).count("\n"), text)
64
+
65
+
66
+ def line_of(text: str, idx: int) -> int:
67
+ return text.count("\n", 0, idx) + 1
68
+
69
+
70
+ def find_placeholders(body: str, offset: int) -> list[dict]:
71
+ findings: list[dict] = []
72
+ scan = blank_fences(body)
73
+ # (regex, label, severity) β€” TBD/TODO and dangling cross-refs are unambiguous; a bare
74
+ # {template-token} can be legitimate brace prose, so it is flagged low ("possible") to keep
75
+ # the mechanical pass near-zero false-positive rather than train reviewers to ignore it.
76
+ for rx, label, severity in (
77
+ (PLACEHOLDER_WORD, "placeholder marker", "high"),
78
+ (SIMILAR_TO, "unresolved cross-reference", "high"),
79
+ (TEMPLATE_TOKEN, "possible unfilled template token (verify)", "low"),
80
+ ):
81
+ for m in rx.finditer(scan):
82
+ findings.append({
83
+ "category": "placeholder",
84
+ "severity": severity,
85
+ "detail": f"{label}: {m.group(0)!r}",
86
+ "location": f"{SPINE} (line {offset + line_of(scan, m.start())})",
87
+ })
88
+ return findings
89
+
90
+
91
+ def find_frontmatter_placeholders(frontmatter: str) -> list[dict]:
92
+ """Catch unfilled tokens left in frontmatter (e.g. paradigm/scope/date) β€” part of the
93
+ spine contract, but outside the body that find_placeholders scans."""
94
+ findings: list[dict] = []
95
+ for rx, label, severity in (
96
+ (PLACEHOLDER_WORD, "placeholder marker", "high"),
97
+ (TEMPLATE_TOKEN, "possible unfilled template token (verify)", "low"),
98
+ ):
99
+ for m in rx.finditer(frontmatter):
100
+ findings.append({
101
+ "category": "placeholder",
102
+ "severity": severity,
103
+ "detail": f"frontmatter {label}: {m.group(0)!r}",
104
+ "location": f"{SPINE} frontmatter (line {1 + line_of(frontmatter, m.start())})",
105
+ })
106
+ return findings
107
+
108
+
109
+ def find_ad_issues(body: str, offset: int) -> list[dict]:
110
+ findings: list[dict] = []
111
+ scan = blank_fences(body) # AD headings shown inside a code fence are not live ADs
112
+ matches = list(AD_HEADING.finditer(scan))
113
+ seen: dict[int, int] = {}
114
+ prev: int | None = None
115
+ for m in matches:
116
+ num = int(m.group(1))
117
+ file_line = offset + line_of(scan, m.start())
118
+ loc = f"{SPINE} AD-{num} (line {file_line})"
119
+ if num in seen:
120
+ findings.append({
121
+ "category": "ad_id",
122
+ "severity": "high",
123
+ "detail": f"AD-{num} id reused (also at line {seen[num]})",
124
+ "location": loc,
125
+ })
126
+ else:
127
+ seen[num] = file_line
128
+ if prev is not None and num <= prev:
129
+ findings.append({
130
+ "category": "ad_id",
131
+ "severity": "high",
132
+ "detail": f"AD-{num} is non-monotonic (follows AD-{prev}); ids must ascend and never renumber",
133
+ "location": loc,
134
+ })
135
+ prev = num if prev is None else max(prev, num)
136
+
137
+ # block text = from this heading to the next heading of any level
138
+ start = m.end()
139
+ nxt = HEADING.search(scan, start)
140
+ block = scan[start:nxt.start()] if nxt else scan[start:]
141
+ low = block.lower()
142
+ missing = [f for f in ("binds", "prevents", "rule") if f not in low]
143
+ if missing:
144
+ findings.append({
145
+ "category": "ad_fields",
146
+ "severity": "high",
147
+ "detail": f"AD-{num} missing required field(s): {', '.join(missing)}",
148
+ "location": loc,
149
+ })
150
+ return findings
151
+
152
+
153
+ def find_unpinned_stack(body: str, offset: int) -> list[dict]:
154
+ """Flag a `## Stack` table row that names something but leaves its version blank or a
155
+ placeholder. Pinning lives in the body table now, not frontmatter. A row whose name is
156
+ still a `{token}` skeleton is left to the placeholder pass, not double-reported here.
157
+
158
+ Fences are blanked first (like find_placeholders / find_ad_issues), so a pipe-row or
159
+ heading inside a code block is never read as live Stack content. The heading match is
160
+ `## Stack` with a word boundary, so a renamed heading (`## Stack & Versions`) still
161
+ counts. Name and Version columns are located from the header row, so a reordered table
162
+ pairs name to version correctly; both default to the canonical positions (0, 1)."""
163
+ findings: list[dict] = []
164
+ in_stack = False
165
+ header_seen = False
166
+ name_idx, ver_idx = 0, 1
167
+ scan = blank_fences(body)
168
+ for i, raw in enumerate(scan.splitlines()):
169
+ if HEADING.match(raw):
170
+ in_stack = re.match(r"^##\s+Stack\b", raw) is not None
171
+ header_seen = False
172
+ name_idx, ver_idx = 0, 1
173
+ continue
174
+ if not in_stack or not raw.lstrip().startswith("|"):
175
+ continue
176
+ if set(raw.strip()) <= set("|-: "):
177
+ continue # separator row
178
+ cells = _table_cells(raw)
179
+ if not header_seen:
180
+ header_seen = True
181
+ for j, c in enumerate(cells):
182
+ if c.lower() == "name":
183
+ name_idx = j
184
+ elif c.lower() == "version":
185
+ ver_idx = j
186
+ continue
187
+ name = cells[name_idx] if len(cells) > name_idx else ""
188
+ version = cells[ver_idx] if len(cells) > ver_idx else ""
189
+ if not name or TEMPLATE_TOKEN.search(name):
190
+ continue
191
+ if not version or TEMPLATE_TOKEN.search(version):
192
+ findings.append({
193
+ "category": "version_pin",
194
+ "severity": "medium",
195
+ "detail": f"Stack entry {name!r} has no version",
196
+ "location": f"{SPINE} (line {offset + i + 1})",
197
+ })
198
+ return findings
199
+
200
+
201
+ def _table_cells(row: str) -> list[str]:
202
+ """Split a markdown table row into trimmed cells, dropping the leading/trailing pipe."""
203
+ s = row.strip()
204
+ if s.startswith("|"):
205
+ s = s[1:]
206
+ if s.endswith("|"):
207
+ s = s[:-1]
208
+ return [c.strip() for c in s.split("|")]
209
+
210
+
211
+ def lint(text: str) -> dict:
212
+ frontmatter, body, offset = split_frontmatter(text)
213
+ findings: list[dict] = []
214
+ findings += find_frontmatter_placeholders(frontmatter)
215
+ findings += find_placeholders(body, offset)
216
+ findings += find_ad_issues(body, offset)
217
+ findings += find_unpinned_stack(body, offset)
218
+ counts: dict[str, int] = {}
219
+ for f in findings:
220
+ counts[f["severity"]] = counts.get(f["severity"], 0) + 1
221
+ return {
222
+ "ok": len(findings) == 0,
223
+ "spine": SPINE,
224
+ "total_findings": len(findings),
225
+ "by_severity": counts,
226
+ "findings": findings,
227
+ }
228
+
229
+
230
+ def main(argv: list[str] | None = None) -> int:
231
+ ap = argparse.ArgumentParser(description="Lint an architecture spine for mechanical integrity.")
232
+ ap.add_argument("--workspace", required=True, help="run folder containing ARCHITECTURE-SPINE.md")
233
+ ap.add_argument("-o", "--output", help="write JSON here instead of stdout")
234
+ args = ap.parse_args(argv)
235
+
236
+ spine_path = Path(args.workspace) / SPINE
237
+ if not spine_path.exists():
238
+ result = {"ok": False, "error": f"{spine_path} not found", "findings": [], "total_findings": 0}
239
+ else:
240
+ try:
241
+ text = spine_path.read_text(encoding="utf-8")
242
+ except (OSError, UnicodeDecodeError) as e:
243
+ # honor the "exit code is always 0" contract: a read/decode failure travels in JSON
244
+ result = {"ok": False, "error": f"could not read {spine_path}: {e}", "findings": [], "total_findings": 0}
245
+ else:
246
+ result = lint(text)
247
+
248
+ out = json.dumps(result, indent=2)
249
+ if args.output:
250
+ Path(args.output).write_text(out + "\n", encoding="utf-8")
251
+ else:
252
+ print(out)
253
+ return 0
254
+
255
+
256
+ if __name__ == "__main__":
257
+ sys.exit(main())
@@ -0,0 +1,91 @@
1
+ ο»Ώ---
2
+ name: drt-check-implementation-readiness
3
+ description: 'Validate PRD, UX, Architecture and Epics specs are complete. Use when the user says "check implementation readiness".'
4
+ ---
5
+
6
+ # Implementation Readiness
7
+
8
+ **Goal:** Validate that PRD, UX, Architecture, Epics and Stories are complete and aligned before Phase 4 implementation starts, with a focus on ensuring epics and stories are logical and have accounted for all requirements and planning.
9
+
10
+ **Your Role:** You are an expert Product Manager, renowned and respected in the field of requirements traceability and spotting gaps in planning. Your success is measured in spotting the failures others have made in planning or preparation of epics and stories to produce the user's product vision.
11
+
12
+ ## Conventions
13
+
14
+ - Bare paths (e.g. `steps/step-01-document-discovery.md`) resolve from the skill root.
15
+ - `{skill-root}` resolves to this skill's installed directory (where `customize.toml` lives).
16
+ - `{project-root}`-prefixed paths resolve from the project working directory.
17
+ - `{skill-name}` resolves to the skill directory's basename.
18
+
19
+ ## WORKFLOW ARCHITECTURE
20
+
21
+ ### Core Principles
22
+
23
+ - **Micro-file Design**: Each step toward the overall goal is a self-contained instruction file; adhere to one file at a time, as directed
24
+ - **Just-In-Time Loading**: Only 1 current step file will be loaded and followed to completion - never load future step files until told to do so
25
+ - **Sequential Enforcement**: Sequence within the step files must be completed in order, no skipping or optimization allowed
26
+ - **State Tracking**: Document progress in output file frontmatter using `stepsCompleted` array when a workflow produces a document
27
+ - **Append-Only Building**: Build documents by appending content as directed to the output file
28
+
29
+ ### Step Processing Rules
30
+
31
+ 1. **READ COMPLETELY**: Always read the entire step file before taking any action
32
+ 2. **FOLLOW SEQUENCE**: Execute all numbered sections in order, never deviate
33
+ 3. **WAIT FOR INPUT**: If a menu is presented, halt and wait for user selection
34
+ 4. **CHECK CONTINUATION**: If the step has a menu with Continue as an option, only proceed to next step when user selects 'C' (Continue)
35
+ 5. **SAVE STATE**: Update `stepsCompleted` in frontmatter before loading next step
36
+ 6. **LOAD NEXT**: When directed, read fully and follow the next step file
37
+
38
+ ### Critical Rules (NO EXCEPTIONS)
39
+
40
+ - πŸ›‘ **NEVER** load multiple step files simultaneously
41
+ - πŸ“– **ALWAYS** read entire step file before execution
42
+ - 🚫 **NEVER** skip steps or optimize the sequence
43
+ - πŸ’Ύ **ALWAYS** update frontmatter of output files when writing the final output for a specific step
44
+ - 🎯 **ALWAYS** follow the exact instructions in the step file
45
+ - ⏸️ **ALWAYS** halt at menus and wait for user input
46
+ - πŸ“‹ **NEVER** create mental todo lists from future steps
47
+
48
+ ## On Activation
49
+
50
+ ### Step 1: Resolve the Workflow Block
51
+
52
+ Run: `node {project-root}/_drt/scripts/resolve-customization.js --skill {skill-root} --key workflow`
53
+
54
+ **If the script fails**, resolve the `workflow` block yourself by reading these three files in base β†’ team β†’ user order and applying the same structural merge rules as the resolver:
55
+
56
+ 1. `{skill-root}/customize.toml` β€” defaults
57
+ 2. `{project-root}/_drt/custom/{skill-name}.toml` β€” team overrides
58
+ 3. `{project-root}/_drt/custom/{skill-name}.user.toml` β€” personal overrides
59
+
60
+ Any missing file is skipped. Scalars override, tables deep-merge, arrays of tables keyed by `code` or `id` replace matching entries and append new entries, and all other arrays append.
61
+
62
+ ### Step 2: Execute Prepend Steps
63
+
64
+ Execute each entry in `{workflow.activation_steps_prepend}` in order before proceeding.
65
+
66
+ ### Step 3: Load Persistent Facts
67
+
68
+ Treat every entry in `{workflow.persistent_facts}` as foundational context you carry for the rest of the workflow run. Entries prefixed `file:` are paths or globs under `{project-root}` β€” load the referenced contents as facts. All other entries are facts verbatim.
69
+
70
+ ### Step 4: Load Config
71
+
72
+ Load config from `{project-root}/_drt/drt/config.yaml` and resolve:
73
+ - Use `{user_name}` for greeting
74
+ - Use `{communication_language}` for all communications
75
+ - Use `{document_output_language}` for output documents
76
+ - Use `{planning_artifacts}` for output location and artifact scanning
77
+ - Use `{project_knowledge}` for additional context scanning
78
+
79
+ ### Step 5: Greet the User
80
+
81
+ Greet `{user_name}`, speaking in `{communication_language}`.
82
+
83
+ ### Step 6: Execute Append Steps
84
+
85
+ Execute each entry in `{workflow.activation_steps_append}` in order.
86
+
87
+ Activation is complete. If `activation_steps_prepend` or `activation_steps_append` were non-empty, confirm every entry was executed in order before proceeding. Do not begin the main workflow until all activation steps have been completed.
88
+
89
+ ## Execution
90
+
91
+ Read fully and follow: `./steps/step-01-document-discovery.md` to begin the workflow.
@@ -0,0 +1,41 @@
1
+ # DO NOT EDIT -- overwritten on every update.
2
+ #
3
+ # Workflow customization surface for drt-check-implementation-readiness. Mirrors the
4
+ # agent customization shape under the [workflow] namespace.
5
+
6
+ [workflow]
7
+
8
+ # --- Configurable below. Overrides merge per DRT structural rules: ---
9
+ # scalars: override wins β€’ arrays (persistent_facts, activation_steps_*): append
10
+ # arrays-of-tables with `code`/`id`: replace matching items, append new ones.
11
+
12
+ # Steps to run before the standard activation (config load, greet).
13
+ # Overrides append. Use for pre-flight loads, compliance checks, etc.
14
+
15
+ activation_steps_prepend = []
16
+
17
+ # Steps to run after greet but before the workflow begins.
18
+ # Overrides append. Use for context-heavy setup that should happen
19
+ # once the user has been acknowledged.
20
+
21
+ activation_steps_append = []
22
+
23
+ # Persistent facts the workflow keeps in mind for the whole run
24
+ # (standards, compliance constraints, stylistic guardrails).
25
+ # Distinct from the runtime memory sidecar β€” these are static context
26
+ # loaded on activation. Overrides append.
27
+ #
28
+ # Each entry is either:
29
+ # - a literal sentence, e.g. "All artifacts must follow org naming conventions."
30
+ # - a file reference prefixed with `file:`, e.g. "file:{project-root}/docs/standards.md"
31
+ # (glob patterns are supported; the file's contents are loaded and treated as facts).
32
+
33
+ persistent_facts = [
34
+ "file:{project-root}/**/project-context.md",
35
+ ]
36
+
37
+ # Scalar: executed when the workflow reaches Step 6 (Final Assessment),
38
+ # after the readiness report has been saved and presented. Override wins.
39
+ # Leave empty for no custom post-completion behavior.
40
+
41
+ on_complete = ""