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,398 @@
1
+ const fs = require('../fs-native');
2
+ const path = require('node:path');
3
+ const yaml = require('yaml');
4
+ const { MODULE_HELP_CSV_HEADER } = require('./module-help-schema');
5
+
6
+ /**
7
+ * Resolves how to install a plugin from marketplace.json by analyzing
8
+ * where module.yaml and module-help.csv live relative to the listed skills.
9
+ *
10
+ * Five strategies, tried in order:
11
+ * 1. Root module files at the common parent of all skills
12
+ * 2. A -setup skill with assets/module.yaml + assets/module-help.csv
13
+ * 3. Single standalone skill with both files in its assets/
14
+ * 4. Multiple standalone skills, each with both files in assets/
15
+ * 5. Fallback: synthesize from marketplace.json + SKILL.md frontmatter
16
+ */
17
+ class PluginResolver {
18
+ /**
19
+ * Resolve a plugin to one or more installable module definitions.
20
+ * @param {string} repoPath - Absolute path to the cloned repository root
21
+ * @param {Object} plugin - Plugin object from marketplace.json
22
+ * @param {string} plugin.name - Plugin identifier
23
+ * @param {string} [plugin.source] - Relative path from repo root
24
+ * @param {string} [plugin.version] - Semantic version
25
+ * @param {string} [plugin.description] - Plugin description
26
+ * @param {string[]} [plugin.skills] - Relative paths to skill directories
27
+ * @returns {Promise<ResolvedModule[]>} Array of resolved module definitions
28
+ */
29
+ async resolve(repoPath, plugin) {
30
+ const skillRelPaths = plugin.skills || [];
31
+
32
+ // No skills array: legacy behavior - caller should use existing findModuleSource
33
+ if (skillRelPaths.length === 0) {
34
+ return [];
35
+ }
36
+
37
+ // Resolve skill paths to absolute, constrain to repo root, filter non-existent
38
+ const repoRoot = path.resolve(repoPath);
39
+ const skillPaths = [];
40
+ for (const rel of skillRelPaths) {
41
+ const normalized = rel.replace(/^\.\//, '');
42
+ const abs = path.resolve(repoPath, normalized);
43
+ // Guard against path traversal (.. segments, absolute paths in marketplace.json)
44
+ if (!abs.startsWith(repoRoot + path.sep) && abs !== repoRoot) {
45
+ continue;
46
+ }
47
+ if (await fs.pathExists(abs)) {
48
+ skillPaths.push(abs);
49
+ }
50
+ }
51
+
52
+ if (skillPaths.length === 0) {
53
+ return [];
54
+ }
55
+
56
+ // Try each strategy in order
57
+ const result =
58
+ (await this._tryRootModuleFiles(repoPath, plugin, skillPaths)) ||
59
+ (await this._trySetupSkill(repoPath, plugin, skillPaths)) ||
60
+ (await this._trySingleStandalone(repoPath, plugin, skillPaths)) ||
61
+ (await this._tryMultipleStandalone(repoPath, plugin, skillPaths)) ||
62
+ (await this._synthesizeFallback(repoPath, plugin, skillPaths));
63
+
64
+ return result;
65
+ }
66
+
67
+ // ─── Strategy 1: Root Module Files ──────────────────────────────────────────
68
+
69
+ /**
70
+ * Check if module.yaml + module-help.csv exist at the common parent of all skills.
71
+ */
72
+ async _tryRootModuleFiles(repoPath, plugin, skillPaths) {
73
+ const commonParent = this._computeCommonParent(skillPaths);
74
+ const moduleYamlPath = path.join(commonParent, 'module.yaml');
75
+ const moduleHelpPath = path.join(commonParent, 'module-help.csv');
76
+
77
+ if (!(await fs.pathExists(moduleYamlPath)) || !(await fs.pathExists(moduleHelpPath))) {
78
+ return null;
79
+ }
80
+
81
+ const moduleData = await this._readModuleYaml(moduleYamlPath);
82
+ if (!moduleData) return null;
83
+
84
+ return [
85
+ {
86
+ code: moduleData.code || plugin.name,
87
+ name: moduleData.name || plugin.name,
88
+ version: plugin.version || moduleData.module_version || null,
89
+ description: moduleData.description || plugin.description || '',
90
+ strategy: 1,
91
+ pluginName: plugin.name,
92
+ moduleYamlPath,
93
+ moduleHelpCsvPath: moduleHelpPath,
94
+ skillPaths,
95
+ synthesizedModuleYaml: null,
96
+ synthesizedHelpCsv: null,
97
+ },
98
+ ];
99
+ }
100
+
101
+ // ─── Strategy 2: Setup Skill ────────────────────────────────────────────────
102
+
103
+ /**
104
+ * Search for a skill ending in -setup with assets/module.yaml + assets/module-help.csv.
105
+ */
106
+ async _trySetupSkill(repoPath, plugin, skillPaths) {
107
+ for (const skillPath of skillPaths) {
108
+ const dirName = path.basename(skillPath);
109
+ if (!dirName.endsWith('-setup')) continue;
110
+
111
+ const moduleYamlPath = path.join(skillPath, 'assets', 'module.yaml');
112
+ const moduleHelpPath = path.join(skillPath, 'assets', 'module-help.csv');
113
+
114
+ if (!(await fs.pathExists(moduleYamlPath)) || !(await fs.pathExists(moduleHelpPath))) {
115
+ continue;
116
+ }
117
+
118
+ const moduleData = await this._readModuleYaml(moduleYamlPath);
119
+ if (!moduleData) continue;
120
+
121
+ return [
122
+ {
123
+ code: moduleData.code || plugin.name,
124
+ name: moduleData.name || plugin.name,
125
+ version: plugin.version || moduleData.module_version || null,
126
+ description: moduleData.description || plugin.description || '',
127
+ strategy: 2,
128
+ pluginName: plugin.name,
129
+ moduleYamlPath,
130
+ moduleHelpCsvPath: moduleHelpPath,
131
+ skillPaths,
132
+ synthesizedModuleYaml: null,
133
+ synthesizedHelpCsv: null,
134
+ },
135
+ ];
136
+ }
137
+
138
+ return null;
139
+ }
140
+
141
+ // ─── Strategy 3: Single Standalone Skill ────────────────────────────────────
142
+
143
+ /**
144
+ * One skill listed, with assets/module.yaml + assets/module-help.csv.
145
+ */
146
+ async _trySingleStandalone(repoPath, plugin, skillPaths) {
147
+ if (skillPaths.length !== 1) return null;
148
+
149
+ const skillPath = skillPaths[0];
150
+ const moduleYamlPath = path.join(skillPath, 'assets', 'module.yaml');
151
+ const moduleHelpPath = path.join(skillPath, 'assets', 'module-help.csv');
152
+
153
+ if (!(await fs.pathExists(moduleYamlPath)) || !(await fs.pathExists(moduleHelpPath))) {
154
+ return null;
155
+ }
156
+
157
+ const moduleData = await this._readModuleYaml(moduleYamlPath);
158
+ if (!moduleData) return null;
159
+
160
+ return [
161
+ {
162
+ code: moduleData.code || plugin.name,
163
+ name: moduleData.name || plugin.name,
164
+ version: plugin.version || moduleData.module_version || null,
165
+ description: moduleData.description || plugin.description || '',
166
+ strategy: 3,
167
+ pluginName: plugin.name,
168
+ moduleYamlPath,
169
+ moduleHelpCsvPath: moduleHelpPath,
170
+ skillPaths,
171
+ synthesizedModuleYaml: null,
172
+ synthesizedHelpCsv: null,
173
+ },
174
+ ];
175
+ }
176
+
177
+ // ─── Strategy 4: Multiple Standalone Skills ─────────────────────────────────
178
+
179
+ /**
180
+ * Multiple skills, each with assets/module.yaml + assets/module-help.csv.
181
+ * Each becomes its own installable module.
182
+ */
183
+ async _tryMultipleStandalone(repoPath, plugin, skillPaths) {
184
+ if (skillPaths.length < 2) return null;
185
+
186
+ const resolved = [];
187
+
188
+ for (const skillPath of skillPaths) {
189
+ const moduleYamlPath = path.join(skillPath, 'assets', 'module.yaml');
190
+ const moduleHelpPath = path.join(skillPath, 'assets', 'module-help.csv');
191
+
192
+ if (!(await fs.pathExists(moduleYamlPath)) || !(await fs.pathExists(moduleHelpPath))) {
193
+ continue;
194
+ }
195
+
196
+ const moduleData = await this._readModuleYaml(moduleYamlPath);
197
+ if (!moduleData) continue;
198
+
199
+ resolved.push({
200
+ code: moduleData.code || path.basename(skillPath),
201
+ name: moduleData.name || path.basename(skillPath),
202
+ version: plugin.version || moduleData.module_version || null,
203
+ description: moduleData.description || '',
204
+ strategy: 4,
205
+ pluginName: plugin.name,
206
+ moduleYamlPath,
207
+ moduleHelpCsvPath: moduleHelpPath,
208
+ skillPaths: [skillPath],
209
+ synthesizedModuleYaml: null,
210
+ synthesizedHelpCsv: null,
211
+ });
212
+ }
213
+
214
+ // Only use strategy 4 if ALL skills have module files
215
+ if (resolved.length === skillPaths.length) {
216
+ return resolved;
217
+ }
218
+
219
+ // Partial match: fall through to strategy 5
220
+ return null;
221
+ }
222
+
223
+ // ─── Strategy 5: Fallback (Synthesized) ─────────────────────────────────────
224
+
225
+ /**
226
+ * No module files found anywhere. Synthesize from marketplace.json metadata
227
+ * and SKILL.md frontmatter.
228
+ */
229
+ async _synthesizeFallback(repoPath, plugin, skillPaths) {
230
+ const skillInfos = [];
231
+
232
+ for (const skillPath of skillPaths) {
233
+ const frontmatter = await this._parseSkillFrontmatter(skillPath);
234
+ skillInfos.push({
235
+ dirName: path.basename(skillPath),
236
+ name: frontmatter.name || path.basename(skillPath),
237
+ description: frontmatter.description || '',
238
+ });
239
+ }
240
+
241
+ const moduleName = this._formatDisplayName(plugin.name);
242
+ const code = plugin.name;
243
+
244
+ const synthesizedYaml = {
245
+ code,
246
+ name: moduleName,
247
+ description: plugin.description || '',
248
+ module_version: plugin.version || '1.0.0',
249
+ default_selected: false,
250
+ };
251
+
252
+ const synthesizedCsv = this._buildSynthesizedHelpCsv(moduleName, skillInfos);
253
+
254
+ return [
255
+ {
256
+ code,
257
+ name: moduleName,
258
+ version: plugin.version || null,
259
+ description: plugin.description || '',
260
+ strategy: 5,
261
+ pluginName: plugin.name,
262
+ moduleYamlPath: null,
263
+ moduleHelpCsvPath: null,
264
+ skillPaths,
265
+ synthesizedModuleYaml: synthesizedYaml,
266
+ synthesizedHelpCsv: synthesizedCsv,
267
+ },
268
+ ];
269
+ }
270
+
271
+ // ─── Helpers ────────────────────────────────────────────────────────────────
272
+
273
+ /**
274
+ * Compute the deepest common ancestor directory of an array of absolute paths.
275
+ * @param {string[]} absPaths - Absolute directory paths
276
+ * @returns {string} Common parent directory
277
+ */
278
+ _computeCommonParent(absPaths) {
279
+ if (absPaths.length === 0) return '/';
280
+ if (absPaths.length === 1) return path.dirname(absPaths[0]);
281
+
282
+ const segments = absPaths.map((p) => p.split(path.sep));
283
+ const minLen = Math.min(...segments.map((s) => s.length));
284
+ const common = [];
285
+
286
+ for (let i = 0; i < minLen; i++) {
287
+ const segment = segments[0][i];
288
+ if (segments.every((s) => s[i] === segment)) {
289
+ common.push(segment);
290
+ } else {
291
+ break;
292
+ }
293
+ }
294
+
295
+ return common.join(path.sep) || '/';
296
+ }
297
+
298
+ /**
299
+ * Read and parse a module.yaml file.
300
+ * @param {string} yamlPath - Absolute path to module.yaml
301
+ * @returns {Object|null} Parsed content or null on failure
302
+ */
303
+ async _readModuleYaml(yamlPath) {
304
+ try {
305
+ const content = await fs.readFile(yamlPath, 'utf8');
306
+ return yaml.parse(content);
307
+ } catch {
308
+ return null;
309
+ }
310
+ }
311
+
312
+ /**
313
+ * Extract name and description from a SKILL.md YAML frontmatter block.
314
+ * @param {string} skillDirPath - Absolute path to the skill directory
315
+ * @returns {Object} { name, description } or empty strings
316
+ */
317
+ async _parseSkillFrontmatter(skillDirPath) {
318
+ const skillMdPath = path.join(skillDirPath, 'SKILL.md');
319
+ try {
320
+ const content = await fs.readFile(skillMdPath, 'utf8');
321
+ const match = content.match(/^---\s*\n([\s\S]*?)\n---/);
322
+ if (!match) return { name: '', description: '' };
323
+
324
+ const parsed = yaml.parse(match[1]);
325
+ return {
326
+ name: parsed.name || '',
327
+ description: parsed.description || '',
328
+ };
329
+ } catch {
330
+ return { name: '', description: '' };
331
+ }
332
+ }
333
+
334
+ /**
335
+ * Build a synthesized module-help.csv from plugin metadata and skill frontmatter.
336
+ * Uses the standard 13-column format.
337
+ * @param {string} moduleName - Display name for the module column
338
+ * @param {Array<{dirName: string, name: string, description: string}>} skillInfos
339
+ * @returns {string} CSV content
340
+ */
341
+ _buildSynthesizedHelpCsv(moduleName, skillInfos) {
342
+ const rows = [MODULE_HELP_CSV_HEADER];
343
+
344
+ for (const info of skillInfos) {
345
+ const displayName = this._formatDisplayName(info.name || info.dirName);
346
+ const menuCode = this._generateMenuCode(info.name || info.dirName);
347
+ const description = this._escapeCSVField(info.description);
348
+
349
+ rows.push(`${moduleName},${info.dirName},${displayName},${menuCode},${description},activate,,anytime,,,false,,`);
350
+ }
351
+
352
+ return rows.join('\n') + '\n';
353
+ }
354
+
355
+ /**
356
+ * Format a kebab-case or snake_case name into a display name.
357
+ * Strips common prefixes like "drt-" or "drt-agent-".
358
+ * @param {string} name - Raw name
359
+ * @returns {string} Formatted display name
360
+ */
361
+ _formatDisplayName(name) {
362
+ let cleaned = name.replace(/^drt-agent-/, '').replace(/^drt-/, '');
363
+ return cleaned
364
+ .split(/[-_]/)
365
+ .map((word) => word.charAt(0).toUpperCase() + word.slice(1))
366
+ .join(' ');
367
+ }
368
+
369
+ /**
370
+ * Generate a short menu code from a skill name.
371
+ * Takes first letter of each significant word, uppercased, max 3 chars.
372
+ * @param {string} name - Skill name (kebab-case)
373
+ * @returns {string} Menu code (e.g., "CC" for "code-coach")
374
+ */
375
+ _generateMenuCode(name) {
376
+ const cleaned = name.replace(/^drt-agent-/, '').replace(/^drt-/, '');
377
+ const words = cleaned.split(/[-_]/).filter((w) => w.length > 0);
378
+ return words
379
+ .map((w) => w.charAt(0).toUpperCase())
380
+ .join('')
381
+ .slice(0, 3);
382
+ }
383
+
384
+ /**
385
+ * Escape a value for CSV output (wrap in quotes if it contains commas, quotes, or newlines).
386
+ * @param {string} value
387
+ * @returns {string}
388
+ */
389
+ _escapeCSVField(value) {
390
+ if (!value) return '';
391
+ if (value.includes(',') || value.includes('"') || value.includes('\n')) {
392
+ return `"${value.replaceAll('"', '""')}"`;
393
+ }
394
+ return value;
395
+ }
396
+ }
397
+
398
+ module.exports = { PluginResolver };