@zeyue0329/xiaoma-cli 1.0.8 → 1.0.10

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 (326) hide show
  1. package/.github/FORK_GUIDE.md +106 -0
  2. package/.github/FUNDING.yaml +15 -0
  3. package/.github/ISSUE_TEMPLATE/bug_report.md +32 -0
  4. package/.github/ISSUE_TEMPLATE/feature_request.md +22 -0
  5. package/.github/workflows/discord.yaml +26 -0
  6. package/.github/workflows/format-check.yaml +44 -0
  7. package/.github/workflows/manual-release.yaml +174 -0
  8. package/.github/workflows/pr-validation.yaml +55 -0
  9. package/.husky/pre-commit +3 -0
  10. package/.vscode/settings.json +26 -1
  11. package/CHANGELOG.md +686 -0
  12. package/CONTRIBUTING.md +250 -0
  13. package/LICENSE +6 -1
  14. package/common/tasks/create-doc.md +2 -0
  15. package/common/tasks/execute-checklist.md +2 -7
  16. package/common/utils/bmad-doc-template.md +7 -5
  17. package/common/utils/workflow-management.md +2 -0
  18. package/dist/expansion-packs/bmad-2d-phaser-game-dev/agents/game-designer.txt +2103 -0
  19. package/dist/expansion-packs/bmad-2d-phaser-game-dev/agents/game-developer.txt +1627 -0
  20. package/dist/expansion-packs/bmad-2d-phaser-game-dev/agents/game-sm.txt +822 -0
  21. package/dist/expansion-packs/bmad-2d-phaser-game-dev/teams/phaser-2d-nodejs-game-team.txt +8486 -0
  22. package/dist/expansion-packs/bmad-2d-unity-game-dev/agents/game-architect.txt +3210 -0
  23. package/dist/expansion-packs/bmad-2d-unity-game-dev/agents/game-designer.txt +3244 -0
  24. package/dist/expansion-packs/bmad-2d-unity-game-dev/agents/game-developer.txt +317 -0
  25. package/dist/expansion-packs/bmad-2d-unity-game-dev/agents/game-sm.txt +982 -0
  26. package/dist/expansion-packs/bmad-2d-unity-game-dev/teams/unity-2d-game-team.txt +12854 -0
  27. package/dist/expansion-packs/bmad-creative-writing/agents/beta-reader.txt +921 -0
  28. package/dist/expansion-packs/bmad-creative-writing/agents/book-critic.txt +81 -0
  29. package/dist/expansion-packs/bmad-creative-writing/agents/character-psychologist.txt +886 -0
  30. package/dist/expansion-packs/bmad-creative-writing/agents/cover-designer.txt +85 -0
  31. package/dist/expansion-packs/bmad-creative-writing/agents/dialog-specialist.txt +903 -0
  32. package/dist/expansion-packs/bmad-creative-writing/agents/editor.txt +837 -0
  33. package/dist/expansion-packs/bmad-creative-writing/agents/genre-specialist.txt +989 -0
  34. package/dist/expansion-packs/bmad-creative-writing/agents/narrative-designer.txt +888 -0
  35. package/dist/expansion-packs/bmad-creative-writing/agents/plot-architect.txt +1173 -0
  36. package/dist/expansion-packs/bmad-creative-writing/agents/world-builder.txt +914 -0
  37. package/dist/expansion-packs/bmad-creative-writing/teams/agent-team.txt +6071 -0
  38. package/dist/expansion-packs/bmad-infrastructure-devops/agents/infra-devops-platform.txt +2079 -0
  39. package/docs/GUIDING-PRINCIPLES.md +91 -0
  40. package/docs/core-architecture.md +219 -0
  41. package/docs/enhanced-ide-development-workflow.md +248 -0
  42. package/docs/expansion-packs.md +200 -0
  43. package/docs/how-to-contribute-with-pull-requests.md +158 -0
  44. package/docs/user-guide.md +530 -0
  45. package/docs/versioning-and-releases.md +155 -0
  46. package/docs/versions.md +48 -0
  47. package/docs/working-in-the-brownfield.md +597 -0
  48. package/eslint.config.mjs +119 -0
  49. package/expansion-packs/bmad-2d-phaser-game-dev/agent-teams/phaser-2d-nodejs-game-team.yaml +14 -0
  50. package/expansion-packs/bmad-2d-phaser-game-dev/agents/game-designer.md +73 -0
  51. package/expansion-packs/bmad-2d-phaser-game-dev/agents/game-developer.md +80 -0
  52. package/expansion-packs/bmad-2d-phaser-game-dev/agents/game-sm.md +66 -0
  53. package/expansion-packs/bmad-2d-phaser-game-dev/checklists/game-design-checklist.md +203 -0
  54. package/expansion-packs/bmad-2d-phaser-game-dev/checklists/game-story-dod-checklist.md +162 -0
  55. package/expansion-packs/bmad-2d-phaser-game-dev/config.yaml +9 -0
  56. package/expansion-packs/bmad-2d-phaser-game-dev/data/bmad-kb.md +252 -0
  57. package/expansion-packs/bmad-2d-phaser-game-dev/data/development-guidelines.md +649 -0
  58. package/expansion-packs/bmad-2d-phaser-game-dev/tasks/advanced-elicitation.md +112 -0
  59. package/expansion-packs/bmad-2d-phaser-game-dev/tasks/create-game-story.md +218 -0
  60. package/expansion-packs/bmad-2d-phaser-game-dev/tasks/game-design-brainstorming.md +292 -0
  61. package/expansion-packs/bmad-2d-phaser-game-dev/templates/game-architecture-tmpl.yaml +614 -0
  62. package/expansion-packs/bmad-2d-phaser-game-dev/templates/game-brief-tmpl.yaml +357 -0
  63. package/expansion-packs/bmad-2d-phaser-game-dev/templates/game-design-doc-tmpl.yaml +344 -0
  64. package/expansion-packs/bmad-2d-phaser-game-dev/templates/game-story-tmpl.yaml +254 -0
  65. package/expansion-packs/bmad-2d-phaser-game-dev/templates/level-design-doc-tmpl.yaml +485 -0
  66. package/expansion-packs/bmad-2d-phaser-game-dev/workflows/game-dev-greenfield.yaml +184 -0
  67. package/expansion-packs/bmad-2d-phaser-game-dev/workflows/game-prototype.yaml +176 -0
  68. package/expansion-packs/bmad-2d-unity-game-dev/agent-teams/unity-2d-game-team.yaml +15 -0
  69. package/expansion-packs/bmad-2d-unity-game-dev/agents/game-architect.md +82 -0
  70. package/expansion-packs/bmad-2d-unity-game-dev/agents/game-designer.md +79 -0
  71. package/expansion-packs/bmad-2d-unity-game-dev/agents/game-developer.md +80 -0
  72. package/expansion-packs/bmad-2d-unity-game-dev/agents/game-sm.md +67 -0
  73. package/expansion-packs/bmad-2d-unity-game-dev/checklists/game-architect-checklist.md +393 -0
  74. package/expansion-packs/bmad-2d-unity-game-dev/checklists/game-change-checklist.md +205 -0
  75. package/expansion-packs/bmad-2d-unity-game-dev/checklists/game-design-checklist.md +203 -0
  76. package/expansion-packs/bmad-2d-unity-game-dev/checklists/game-story-dod-checklist.md +126 -0
  77. package/expansion-packs/bmad-2d-unity-game-dev/config.yaml +7 -0
  78. package/expansion-packs/bmad-2d-unity-game-dev/data/bmad-kb.md +771 -0
  79. package/expansion-packs/bmad-2d-unity-game-dev/data/development-guidelines.md +588 -0
  80. package/expansion-packs/bmad-2d-unity-game-dev/tasks/advanced-elicitation.md +112 -0
  81. package/expansion-packs/bmad-2d-unity-game-dev/tasks/correct-course-game.md +143 -0
  82. package/expansion-packs/bmad-2d-unity-game-dev/tasks/create-game-story.md +186 -0
  83. package/expansion-packs/bmad-2d-unity-game-dev/tasks/game-design-brainstorming.md +292 -0
  84. package/expansion-packs/bmad-2d-unity-game-dev/tasks/validate-game-story.md +202 -0
  85. package/expansion-packs/bmad-2d-unity-game-dev/templates/game-architecture-tmpl.yaml +1031 -0
  86. package/expansion-packs/bmad-2d-unity-game-dev/templates/game-brief-tmpl.yaml +357 -0
  87. package/expansion-packs/bmad-2d-unity-game-dev/templates/game-design-doc-tmpl.yaml +706 -0
  88. package/expansion-packs/bmad-2d-unity-game-dev/templates/game-story-tmpl.yaml +257 -0
  89. package/expansion-packs/bmad-2d-unity-game-dev/templates/level-design-doc-tmpl.yaml +485 -0
  90. package/expansion-packs/bmad-2d-unity-game-dev/workflows/game-dev-greenfield.yaml +184 -0
  91. package/expansion-packs/bmad-2d-unity-game-dev/workflows/game-prototype.yaml +176 -0
  92. package/expansion-packs/bmad-creative-writing/README.md +146 -0
  93. package/expansion-packs/bmad-creative-writing/agent-teams/agent-team.yaml +20 -0
  94. package/expansion-packs/bmad-creative-writing/agents/beta-reader.md +94 -0
  95. package/expansion-packs/bmad-creative-writing/agents/book-critic.md +40 -0
  96. package/expansion-packs/bmad-creative-writing/agents/character-psychologist.md +93 -0
  97. package/expansion-packs/bmad-creative-writing/agents/cover-designer.md +46 -0
  98. package/expansion-packs/bmad-creative-writing/agents/dialog-specialist.md +92 -0
  99. package/expansion-packs/bmad-creative-writing/agents/editor.md +93 -0
  100. package/expansion-packs/bmad-creative-writing/agents/genre-specialist.md +95 -0
  101. package/expansion-packs/bmad-creative-writing/agents/narrative-designer.md +93 -0
  102. package/expansion-packs/bmad-creative-writing/agents/plot-architect.md +95 -0
  103. package/expansion-packs/bmad-creative-writing/agents/world-builder.md +94 -0
  104. package/expansion-packs/bmad-creative-writing/checklists/beta-feedback-closure-checklist.md +23 -0
  105. package/expansion-packs/bmad-creative-writing/checklists/character-consistency-checklist.md +23 -0
  106. package/expansion-packs/bmad-creative-writing/checklists/comedic-timing-checklist.md +23 -0
  107. package/expansion-packs/bmad-creative-writing/checklists/cyberpunk-aesthetic-checklist.md +23 -0
  108. package/expansion-packs/bmad-creative-writing/checklists/ebook-formatting-checklist.md +21 -0
  109. package/expansion-packs/bmad-creative-writing/checklists/epic-poetry-meter-checklist.md +23 -0
  110. package/expansion-packs/bmad-creative-writing/checklists/fantasy-magic-system-checklist.md +23 -0
  111. package/expansion-packs/bmad-creative-writing/checklists/foreshadowing-payoff-checklist.md +22 -0
  112. package/expansion-packs/bmad-creative-writing/checklists/genre-tropes-checklist.md +22 -0
  113. package/expansion-packs/bmad-creative-writing/checklists/historical-accuracy-checklist.md +23 -0
  114. package/expansion-packs/bmad-creative-writing/checklists/horror-suspense-checklist.md +23 -0
  115. package/expansion-packs/bmad-creative-writing/checklists/kdp-cover-ready-checklist.md +25 -0
  116. package/expansion-packs/bmad-creative-writing/checklists/line-edit-quality-checklist.md +23 -0
  117. package/expansion-packs/bmad-creative-writing/checklists/marketing-copy-checklist.md +23 -0
  118. package/expansion-packs/bmad-creative-writing/checklists/mystery-clue-trail-checklist.md +23 -0
  119. package/expansion-packs/bmad-creative-writing/checklists/orbital-mechanics-checklist.md +23 -0
  120. package/expansion-packs/bmad-creative-writing/checklists/plot-structure-checklist.md +59 -0
  121. package/expansion-packs/bmad-creative-writing/checklists/publication-readiness-checklist.md +23 -0
  122. package/expansion-packs/bmad-creative-writing/checklists/romance-emotional-beats-checklist.md +23 -0
  123. package/expansion-packs/bmad-creative-writing/checklists/scene-quality-checklist.md +23 -0
  124. package/expansion-packs/bmad-creative-writing/checklists/scifi-technology-plausibility-checklist.md +22 -0
  125. package/expansion-packs/bmad-creative-writing/checklists/sensitivity-representation-checklist.md +23 -0
  126. package/expansion-packs/bmad-creative-writing/checklists/steampunk-gadget-checklist.md +23 -0
  127. package/expansion-packs/bmad-creative-writing/checklists/thriller-pacing-stakes-checklist.md +23 -0
  128. package/expansion-packs/bmad-creative-writing/checklists/timeline-continuity-checklist.md +23 -0
  129. package/expansion-packs/bmad-creative-writing/checklists/world-building-continuity-checklist.md +23 -0
  130. package/expansion-packs/bmad-creative-writing/checklists/ya-appropriateness-checklist.md +23 -0
  131. package/expansion-packs/bmad-creative-writing/config.yaml +12 -0
  132. package/expansion-packs/bmad-creative-writing/data/bmad-kb.md +209 -0
  133. package/expansion-packs/bmad-creative-writing/data/story-structures.md +67 -0
  134. package/expansion-packs/bmad-creative-writing/docs/brief.md +212 -0
  135. package/expansion-packs/bmad-creative-writing/tasks/advanced-elicitation.md +119 -0
  136. package/expansion-packs/bmad-creative-writing/tasks/analyze-reader-feedback.md +23 -0
  137. package/expansion-packs/bmad-creative-writing/tasks/analyze-story-structure.md +67 -0
  138. package/expansion-packs/bmad-creative-writing/tasks/assemble-kdp-package.md +29 -0
  139. package/expansion-packs/bmad-creative-writing/tasks/brainstorm-premise.md +23 -0
  140. package/expansion-packs/bmad-creative-writing/tasks/build-world.md +24 -0
  141. package/expansion-packs/bmad-creative-writing/tasks/character-depth-pass.md +22 -0
  142. package/expansion-packs/bmad-creative-writing/tasks/create-doc.md +103 -0
  143. package/expansion-packs/bmad-creative-writing/tasks/create-draft-section.md +26 -0
  144. package/expansion-packs/bmad-creative-writing/tasks/critical-review.md +26 -0
  145. package/expansion-packs/bmad-creative-writing/tasks/develop-character.md +24 -0
  146. package/expansion-packs/bmad-creative-writing/tasks/execute-checklist.md +88 -0
  147. package/expansion-packs/bmad-creative-writing/tasks/expand-premise.md +23 -0
  148. package/expansion-packs/bmad-creative-writing/tasks/expand-synopsis.md +23 -0
  149. package/expansion-packs/bmad-creative-writing/tasks/final-polish.md +23 -0
  150. package/expansion-packs/bmad-creative-writing/tasks/generate-cover-brief.md +25 -0
  151. package/expansion-packs/bmad-creative-writing/tasks/generate-cover-prompts.md +26 -0
  152. package/expansion-packs/bmad-creative-writing/tasks/generate-scene-list.md +23 -0
  153. package/expansion-packs/bmad-creative-writing/tasks/incorporate-feedback.md +25 -0
  154. package/expansion-packs/bmad-creative-writing/tasks/outline-scenes.md +23 -0
  155. package/expansion-packs/bmad-creative-writing/tasks/provide-feedback.md +24 -0
  156. package/expansion-packs/bmad-creative-writing/tasks/publish-chapter.md +23 -0
  157. package/expansion-packs/bmad-creative-writing/tasks/quick-feedback.md +22 -0
  158. package/expansion-packs/bmad-creative-writing/tasks/select-next-arc.md +23 -0
  159. package/expansion-packs/bmad-creative-writing/tasks/workshop-dialog.md +64 -0
  160. package/expansion-packs/bmad-creative-writing/templates/beta-feedback-form.yaml +97 -0
  161. package/expansion-packs/bmad-creative-writing/templates/chapter-draft-tmpl.yaml +82 -0
  162. package/expansion-packs/bmad-creative-writing/templates/character-profile-tmpl.yaml +92 -0
  163. package/expansion-packs/bmad-creative-writing/templates/cover-design-brief-tmpl.yaml +98 -0
  164. package/expansion-packs/bmad-creative-writing/templates/premise-brief-tmpl.yaml +78 -0
  165. package/expansion-packs/bmad-creative-writing/templates/scene-list-tmpl.yaml +55 -0
  166. package/expansion-packs/bmad-creative-writing/templates/story-outline-tmpl.yaml +96 -0
  167. package/expansion-packs/bmad-creative-writing/templates/world-guide-tmpl.yaml +89 -0
  168. package/expansion-packs/bmad-creative-writing/workflows/book-cover-design-workflow.md +218 -0
  169. package/expansion-packs/bmad-creative-writing/workflows/novel-greenfield-workflow.yaml +56 -0
  170. package/expansion-packs/bmad-creative-writing/workflows/novel-serial-workflow.yaml +50 -0
  171. package/expansion-packs/bmad-creative-writing/workflows/novel-snowflake-workflow.yaml +69 -0
  172. package/expansion-packs/bmad-creative-writing/workflows/novel-writing.yaml +91 -0
  173. package/expansion-packs/bmad-creative-writing/workflows/screenplay-development.yaml +85 -0
  174. package/expansion-packs/bmad-creative-writing/workflows/series-planning.yaml +78 -0
  175. package/expansion-packs/bmad-creative-writing/workflows/short-story-creation.yaml +64 -0
  176. package/expansion-packs/bmad-infrastructure-devops/README.md +147 -0
  177. package/expansion-packs/bmad-infrastructure-devops/agents/infra-devops-platform.md +73 -0
  178. package/expansion-packs/bmad-infrastructure-devops/checklists/infrastructure-checklist.md +486 -0
  179. package/expansion-packs/bmad-infrastructure-devops/config.yaml +10 -0
  180. package/expansion-packs/bmad-infrastructure-devops/data/bmad-kb.md +307 -0
  181. package/expansion-packs/bmad-infrastructure-devops/tasks/review-infrastructure.md +161 -0
  182. package/expansion-packs/bmad-infrastructure-devops/tasks/validate-infrastructure.md +155 -0
  183. package/expansion-packs/bmad-infrastructure-devops/templates/infrastructure-architecture-tmpl.yaml +425 -0
  184. package/expansion-packs/bmad-infrastructure-devops/templates/infrastructure-platform-from-arch-tmpl.yaml +630 -0
  185. package/implement-fork-friendly-ci.sh +229 -0
  186. package/package.json +75 -45
  187. package/prettier.config.mjs +32 -0
  188. package/test.md +1 -0
  189. package/tools/builders/web-builder.js +143 -149
  190. package/tools/bump-all-versions.js +42 -33
  191. package/tools/bump-expansion-version.js +23 -16
  192. package/tools/cli.js +15 -15
  193. package/tools/flattener/aggregate.js +76 -0
  194. package/tools/flattener/binary.js +80 -0
  195. package/tools/flattener/discovery.js +71 -0
  196. package/tools/flattener/files.js +35 -0
  197. package/tools/flattener/ignoreRules.js +176 -0
  198. package/tools/flattener/main.js +458 -460
  199. package/tools/flattener/projectRoot.js +206 -0
  200. package/tools/flattener/prompts.js +44 -0
  201. package/tools/flattener/stats.helpers.js +395 -0
  202. package/tools/flattener/stats.js +80 -0
  203. package/tools/flattener/test-matrix.js +413 -0
  204. package/tools/flattener/xml.js +88 -0
  205. package/tools/installer/README.md +1 -1
  206. package/tools/installer/bin/xiaoma.js +390 -150
  207. package/tools/installer/config/ide-agent-config.yaml +1 -1
  208. package/tools/installer/config/install.config.yaml +60 -9
  209. package/tools/installer/lib/config-loader.js +55 -51
  210. package/tools/installer/lib/file-manager.js +92 -117
  211. package/tools/installer/lib/ide-base-setup.js +57 -56
  212. package/tools/installer/lib/ide-setup.js +821 -414
  213. package/tools/installer/lib/installer.js +924 -699
  214. package/tools/installer/lib/memory-profiler.js +54 -53
  215. package/tools/installer/lib/module-manager.js +19 -15
  216. package/tools/installer/lib/resource-locator.js +31 -33
  217. package/tools/installer/package.json +24 -23
  218. package/tools/lib/dependency-resolver.js +39 -43
  219. package/tools/lib/yaml-utils.js +7 -7
  220. package/tools/md-assets/web-agent-startup-instructions.md +6 -6
  221. package/tools/preview-release-notes.js +66 -0
  222. package/tools/setup-hooks.sh +37 -0
  223. package/tools/shared/bannerArt.js +105 -0
  224. package/tools/sync-installer-version.js +7 -9
  225. package/tools/sync-version.sh +23 -0
  226. package/tools/update-expansion-version.js +14 -15
  227. package/tools/upgraders/v3-to-v4-upgrader.js +203 -294
  228. package/tools/version-bump.js +41 -26
  229. package/tools/xiaoma-npx-wrapper.js +14 -14
  230. package/tools/yaml-format.js +56 -43
  231. package/xiaoma-core/agent-teams/team-all.yaml +3 -2
  232. package/xiaoma-core/agent-teams/team-fullstack.yaml +2 -1
  233. package/xiaoma-core/agent-teams/team-ide-minimal.yaml +1 -0
  234. package/xiaoma-core/agent-teams/team-no-ui.yaml +2 -1
  235. package/xiaoma-core/agents/analyst.md +20 -17
  236. package/xiaoma-core/agents/architect.md +15 -14
  237. package/xiaoma-core/agents/{xiaoma-master.md → bmad-master.md} +29 -27
  238. package/xiaoma-core/agents/{xiaoma-orchestrator.md → bmad-orchestrator.md} +36 -39
  239. package/xiaoma-core/agents/dev.md +23 -18
  240. package/xiaoma-core/agents/pm.md +18 -15
  241. package/xiaoma-core/agents/po.md +13 -10
  242. package/xiaoma-core/agents/qa.md +46 -24
  243. package/xiaoma-core/agents/sm.md +11 -8
  244. package/xiaoma-core/agents/ux-expert.md +10 -7
  245. package/xiaoma-core/checklists/architect-checklist.md +2 -5
  246. package/xiaoma-core/checklists/change-checklist.md +4 -2
  247. package/xiaoma-core/checklists/pm-checklist.md +2 -5
  248. package/xiaoma-core/checklists/po-master-checklist.md +2 -9
  249. package/xiaoma-core/checklists/story-dod-checklist.md +2 -7
  250. package/xiaoma-core/checklists/story-draft-checklist.md +2 -3
  251. package/xiaoma-core/core-config.yaml +4 -1
  252. package/xiaoma-core/data/{xiaoma-kb.md → bmad-kb.md} +48 -42
  253. package/xiaoma-core/data/brainstorming-techniques.md +2 -0
  254. package/xiaoma-core/data/elicitation-methods.md +22 -0
  255. package/xiaoma-core/data/technical-preferences.md +2 -0
  256. package/xiaoma-core/data/test-levels-framework.md +148 -0
  257. package/xiaoma-core/data/test-priorities-matrix.md +174 -0
  258. package/xiaoma-core/tasks/advanced-elicitation.md +2 -0
  259. package/xiaoma-core/tasks/apply-qa-fixes.md +150 -0
  260. package/xiaoma-core/tasks/brownfield-create-epic.md +2 -0
  261. package/xiaoma-core/tasks/brownfield-create-story.md +2 -0
  262. package/xiaoma-core/tasks/correct-course.md +2 -0
  263. package/xiaoma-core/tasks/create-brownfield-story.md +14 -4
  264. package/xiaoma-core/tasks/create-deep-research-prompt.md +2 -11
  265. package/xiaoma-core/tasks/create-next-story.md +3 -1
  266. package/xiaoma-core/tasks/document-project.md +17 -13
  267. package/xiaoma-core/tasks/facilitate-brainstorming-session.md +5 -3
  268. package/xiaoma-core/tasks/generate-ai-frontend-prompt.md +2 -0
  269. package/xiaoma-core/tasks/index-docs.md +2 -6
  270. package/xiaoma-core/tasks/kb-mode-interaction.md +17 -15
  271. package/xiaoma-core/tasks/nfr-assess.md +345 -0
  272. package/xiaoma-core/tasks/qa-gate.md +163 -0
  273. package/xiaoma-core/tasks/review-story.md +245 -74
  274. package/xiaoma-core/tasks/risk-profile.md +355 -0
  275. package/xiaoma-core/tasks/shard-doc.md +2 -2
  276. package/xiaoma-core/tasks/test-design.md +176 -0
  277. package/xiaoma-core/tasks/trace-requirements.md +266 -0
  278. package/xiaoma-core/tasks/validate-next-story.md +5 -3
  279. package/xiaoma-core/templates/architecture-tmpl.yaml +50 -49
  280. package/xiaoma-core/templates/brainstorming-output-tmpl.yaml +5 -5
  281. package/xiaoma-core/templates/brownfield-architecture-tmpl.yaml +32 -31
  282. package/xiaoma-core/templates/brownfield-prd-tmpl.yaml +14 -13
  283. package/xiaoma-core/templates/competitor-analysis-tmpl.yaml +20 -6
  284. package/xiaoma-core/templates/front-end-architecture-tmpl.yaml +22 -9
  285. package/xiaoma-core/templates/front-end-spec-tmpl.yaml +25 -24
  286. package/xiaoma-core/templates/fullstack-architecture-tmpl.yaml +123 -104
  287. package/xiaoma-core/templates/market-research-tmpl.yaml +3 -2
  288. package/xiaoma-core/templates/prd-tmpl.yaml +10 -9
  289. package/xiaoma-core/templates/project-brief-tmpl.yaml +5 -4
  290. package/xiaoma-core/templates/qa-gate-tmpl.yaml +103 -0
  291. package/xiaoma-core/templates/story-tmpl.yaml +13 -12
  292. package/xiaoma-core/workflows/brownfield-fullstack.yaml +13 -12
  293. package/xiaoma-core/workflows/brownfield-service.yaml +5 -4
  294. package/xiaoma-core/workflows/brownfield-ui.yaml +5 -4
  295. package/xiaoma-core/workflows/greenfield-fullstack.yaml +7 -6
  296. package/xiaoma-core/workflows/greenfield-service.yaml +5 -4
  297. package/xiaoma-core/workflows/greenfield-ui.yaml +6 -5
  298. package/.releaserc.json +0 -18
  299. package/README.md +0 -532
  300. package/XiaoMa-Web/345/244/232/346/231/272/350/203/275/344/275/2230-1/351/241/271/347/233/256/345/274/200/345/217/221/345/256/214/346/225/264/346/214/207/345/215/227.md +0 -977
  301. package/XiaoMa-Web/347/216/260/346/234/211/351/241/271/347/233/256/351/234/200/346/261/202/345/274/200/345/217/221/345/256/214/346/225/264/346/214/207/345/215/227.md +0 -873
  302. package/XiaoMa-Web/347/272/257/345/211/215/347/253/257/351/241/271/347/233/256Claude-Code/345/274/200/345/217/221/345/256/214/346/225/264/346/214/207/345/215/227.md +0 -372
  303. package/XiaoMa-Web/351/241/271/347/233/256/346/200/273/347/273/223/346/212/245/345/221/212.md +0 -310
  304. package/dist/agents/analyst.txt +0 -2882
  305. package/dist/agents/architect.txt +0 -3543
  306. package/dist/agents/dev-cn.txt +0 -428
  307. package/dist/agents/dev.txt +0 -428
  308. package/dist/agents/pm.txt +0 -2229
  309. package/dist/agents/po.txt +0 -1364
  310. package/dist/agents/qa.txt +0 -386
  311. package/dist/agents/sm.txt +0 -668
  312. package/dist/agents/ux-expert.txt +0 -701
  313. package/dist/agents/xiaoma-master.txt +0 -8756
  314. package/dist/agents/xiaoma-orchestrator.txt +0 -1490
  315. package/dist/teams/team-all.txt +0 -11062
  316. package/dist/teams/team-fullstack.txt +0 -10392
  317. package/dist/teams/team-ide-minimal.txt +0 -3507
  318. package/dist/teams/team-no-ui.txt +0 -8951
  319. package/docs/quick-start.md +0 -179
  320. package/tools/bmad-npx-wrapper.js +0 -39
  321. package/tools/installer/package-lock.json +0 -704
  322. package/tools/semantic-release-sync-installer.js +0 -30
  323. package/xiaoma-core/bmad-core/user-guide.md +0 -0
  324. package/xiaoma-core/enhanced-ide-development-workflow.md +0 -43
  325. package/xiaoma-core/user-guide.md +0 -251
  326. package/xiaoma-core/working-in-the-brownfield.md +0 -364
@@ -0,0 +1,1031 @@
1
+ # <!-- Powered by BMAD™ Core -->
2
+ template:
3
+ id: game-architecture-template-v3
4
+ name: Game Architecture Document
5
+ version: 3.0
6
+ output:
7
+ format: markdown
8
+ filename: docs/game-architecture.md
9
+ title: "{{project_name}} Game Architecture Document"
10
+
11
+ workflow:
12
+ mode: interactive
13
+ elicitation: advanced-elicitation
14
+
15
+ sections:
16
+ - id: introduction
17
+ title: Introduction
18
+ instruction: |
19
+ If available, review any provided relevant documents to gather all relevant context before beginning. At a minimum you should locate and review: Game Design Document (GDD), Technical Preferences. If these are not available, ask the user what docs will provide the basis for the game architecture.
20
+ sections:
21
+ - id: intro-content
22
+ content: |
23
+ This document outlines the complete technical architecture for {{project_name}}, a 2D game built with Unity and C#. It serves as the technical foundation for AI-driven game development, ensuring consistency and scalability across all game systems.
24
+
25
+ This architecture is designed to support the gameplay mechanics defined in the Game Design Document while maintaining stable performance and cross-platform compatibility.
26
+ - id: starter-template
27
+ title: Starter Template or Existing Project
28
+ instruction: |
29
+ Before proceeding further with game architecture design, check if the project is based on a Unity template or existing codebase:
30
+
31
+ 1. Review the GDD and brainstorming brief for any mentions of:
32
+ - Unity templates (2D Core, 2D Mobile, 2D URP, etc.)
33
+ - Existing Unity projects being used as a foundation
34
+ - Asset Store packages or game development frameworks
35
+ - Previous game projects to be cloned or adapted
36
+
37
+ 2. If a starter template or existing project is mentioned:
38
+ - Ask the user to provide access via one of these methods:
39
+ - Link to the Unity template documentation
40
+ - Upload/attach the project files (for small projects)
41
+ - Share a link to the project repository (GitHub, GitLab, etc.)
42
+ - Analyze the starter/existing project to understand:
43
+ - Pre-configured Unity version and render pipeline
44
+ - Project structure and organization patterns
45
+ - Built-in packages and dependencies
46
+ - Existing architectural patterns and conventions
47
+ - Any limitations or constraints imposed by the starter
48
+ - Use this analysis to inform and align your architecture decisions
49
+
50
+ 3. If no starter template is mentioned but this is a greenfield project:
51
+ - Suggest appropriate Unity templates based on the target platform
52
+ - Explain the benefits (faster setup, best practices, package integration)
53
+ - Let the user decide whether to use one
54
+
55
+ 4. If the user confirms no starter template will be used:
56
+ - Proceed with architecture design from scratch
57
+ - Note that manual setup will be required for all Unity configuration
58
+
59
+ Document the decision here before proceeding with the architecture design. If none, just say N/A
60
+ elicit: true
61
+ - id: changelog
62
+ title: Change Log
63
+ type: table
64
+ columns: [Date, Version, Description, Author]
65
+ instruction: Track document versions and changes
66
+
67
+ - id: high-level-architecture
68
+ title: High Level Architecture
69
+ instruction: |
70
+ This section contains multiple subsections that establish the foundation of the game architecture. Present all subsections together at once.
71
+ elicit: true
72
+ sections:
73
+ - id: technical-summary
74
+ title: Technical Summary
75
+ instruction: |
76
+ Provide a brief paragraph (3-5 sentences) overview of:
77
+ - The game's overall architecture style (component-based Unity architecture)
78
+ - Key game systems and their relationships
79
+ - Primary technology choices (Unity, C#, target platforms)
80
+ - Core architectural patterns being used (MonoBehaviour components, ScriptableObjects, Unity Events)
81
+ - Reference back to the GDD goals and how this architecture supports them
82
+ - id: high-level-overview
83
+ title: High Level Overview
84
+ instruction: |
85
+ Based on the GDD's Technical Assumptions section, describe:
86
+
87
+ 1. The main architectural style (component-based Unity architecture with MonoBehaviours)
88
+ 2. Repository structure decision from GDD (single Unity project vs multiple projects)
89
+ 3. Game system architecture (modular systems, manager singletons, data-driven design)
90
+ 4. Primary player interaction flow and core game loop
91
+ 5. Key architectural decisions and their rationale (render pipeline, input system, physics)
92
+ - id: project-diagram
93
+ title: High Level Project Diagram
94
+ type: mermaid
95
+ mermaid_type: graph
96
+ instruction: |
97
+ Create a Mermaid diagram that visualizes the high-level game architecture. Consider:
98
+ - Core game systems (Input, Physics, Rendering, Audio, UI)
99
+ - Game managers and their responsibilities
100
+ - Data flow between systems
101
+ - External integrations (platform services, analytics)
102
+ - Player interaction points
103
+
104
+ - id: architectural-patterns
105
+ title: Architectural and Design Patterns
106
+ instruction: |
107
+ List the key high-level patterns that will guide the game architecture. For each pattern:
108
+
109
+ 1. Present 2-3 viable options if multiple exist
110
+ 2. Provide your recommendation with clear rationale
111
+ 3. Get user confirmation before finalizing
112
+ 4. These patterns should align with the GDD's technical assumptions and project goals
113
+
114
+ Common Unity patterns to consider:
115
+ - Component patterns (MonoBehaviour composition, ScriptableObject data)
116
+ - Game management patterns (Singleton managers, Event systems, State machines)
117
+ - Data patterns (ScriptableObject configuration, Save/Load systems)
118
+ - Unity-specific patterns (Object pooling, Coroutines, Unity Events)
119
+ template: "- **{{pattern_name}}:** {{pattern_description}} - _Rationale:_ {{rationale}}"
120
+ examples:
121
+ - "**Component-Based Architecture:** Using MonoBehaviour components for game logic - _Rationale:_ Aligns with Unity's design philosophy and enables reusable, testable game systems"
122
+ - "**ScriptableObject Data:** Using ScriptableObjects for game configuration - _Rationale:_ Enables data-driven design and easy balancing without code changes"
123
+ - "**Event-Driven Communication:** Using Unity Events and C# events for system decoupling - _Rationale:_ Supports modular architecture and easier testing"
124
+
125
+ - id: tech-stack
126
+ title: Tech Stack
127
+ instruction: |
128
+ This is the DEFINITIVE technology selection section for the Unity game. Work with the user to make specific choices:
129
+
130
+ 1. Review GDD technical assumptions and any preferences from {root}/data/technical-preferences.yaml or an attached technical-preferences
131
+ 2. For each category, present 2-3 viable options with pros/cons
132
+ 3. Make a clear recommendation based on project needs
133
+ 4. Get explicit user approval for each selection
134
+ 5. Document exact versions (avoid "latest" - pin specific versions)
135
+ 6. This table is the single source of truth - all other docs must reference these choices
136
+
137
+ Key decisions to finalize - before displaying the table, ensure you are aware of or ask the user about:
138
+
139
+ - Unity version and render pipeline
140
+ - Target platforms and their specific requirements
141
+ - Unity Package Manager packages and versions
142
+ - Third-party assets or frameworks
143
+ - Platform SDKs and services
144
+ - Build and deployment tools
145
+
146
+ Upon render of the table, ensure the user is aware of the importance of this sections choices, should also look for gaps or disagreements with anything, ask for any clarifications if something is unclear why its in the list, and also right away elicit feedback.
147
+ elicit: true
148
+ sections:
149
+ - id: platform-infrastructure
150
+ title: Platform Infrastructure
151
+ template: |
152
+ - **Target Platforms:** {{target_platforms}}
153
+ - **Primary Platform:** {{primary_platform}}
154
+ - **Platform Services:** {{platform_services_list}}
155
+ - **Distribution:** {{distribution_channels}}
156
+ - id: technology-stack-table
157
+ title: Technology Stack Table
158
+ type: table
159
+ columns: [Category, Technology, Version, Purpose, Rationale]
160
+ instruction: Populate the technology stack table with all relevant Unity technologies
161
+ examples:
162
+ - "| **Game Engine** | Unity | 2022.3.21f1 | Core game development platform | Latest LTS version, stable 2D tooling, comprehensive package ecosystem |"
163
+ - "| **Language** | C# | 10.0 | Primary scripting language | Unity's native language, strong typing, excellent tooling |"
164
+ - "| **Render Pipeline** | Universal Render Pipeline (URP) | 14.0.10 | 2D/3D rendering | Optimized for mobile, excellent 2D features, future-proof |"
165
+ - "| **Input System** | Unity Input System | 1.7.0 | Cross-platform input handling | Modern input system, supports multiple devices, rebindable controls |"
166
+ - "| **Physics** | Unity 2D Physics | Built-in | 2D collision and physics | Integrated Box2D, optimized for 2D games |"
167
+ - "| **Audio** | Unity Audio | Built-in | Audio playback and mixing | Built-in audio system with mixer support |"
168
+ - "| **Testing** | Unity Test Framework | 1.1.33 | Unit and integration testing | Built-in testing framework based on NUnit |"
169
+
170
+ - id: data-models
171
+ title: Game Data Models
172
+ instruction: |
173
+ Define the core game data models/entities using Unity's ScriptableObject system:
174
+
175
+ 1. Review GDD requirements and identify key game entities
176
+ 2. For each model, explain its purpose and relationships
177
+ 3. Include key attributes and data types appropriate for Unity/C#
178
+ 4. Show relationships between models using ScriptableObject references
179
+ 5. Discuss design decisions with user
180
+
181
+ Create a clear conceptual model before moving to specific implementations.
182
+ elicit: true
183
+ repeatable: true
184
+ sections:
185
+ - id: model
186
+ title: "{{model_name}}"
187
+ template: |
188
+ **Purpose:** {{model_purpose}}
189
+
190
+ **Key Attributes:**
191
+ - {{attribute_1}}: {{type_1}} - {{description_1}}
192
+ - {{attribute_2}}: {{type_2}} - {{description_2}}
193
+
194
+ **Relationships:**
195
+ - {{relationship_1}}
196
+ - {{relationship_2}}
197
+
198
+ **ScriptableObject Implementation:**
199
+ - Create as `[CreateAssetMenu]` ScriptableObject
200
+ - Store in `Assets/_Project/Data/{{ModelName}}/`
201
+
202
+ - id: components
203
+ title: Game Systems & Components
204
+ instruction: |
205
+ Based on the architectural patterns, tech stack, and data models from above:
206
+
207
+ 1. Identify major game systems and their responsibilities
208
+ 2. Consider Unity's component-based architecture with MonoBehaviours
209
+ 3. Define clear interfaces between systems using Unity Events or C# events
210
+ 4. For each system, specify:
211
+ - Primary responsibility and core functionality
212
+ - Key MonoBehaviour components and ScriptableObjects
213
+ - Dependencies on other systems
214
+ - Unity-specific implementation details (lifecycle methods, coroutines, etc.)
215
+
216
+ 5. Create system diagrams where helpful using Unity terminology
217
+ elicit: true
218
+ sections:
219
+ - id: system-list
220
+ repeatable: true
221
+ title: "{{system_name}} System"
222
+ template: |
223
+ **Responsibility:** {{system_description}}
224
+
225
+ **Key Components:**
226
+ - {{component_1}} (MonoBehaviour)
227
+ - {{component_2}} (ScriptableObject)
228
+ - {{component_3}} (Manager/Controller)
229
+
230
+ **Unity Implementation Details:**
231
+ - Lifecycle: {{lifecycle_methods}}
232
+ - Events: {{unity_events_used}}
233
+ - Dependencies: {{system_dependencies}}
234
+
235
+ **Files to Create:**
236
+ - `Assets/_Project/Scripts/{{SystemName}}/{{MainScript}}.cs`
237
+ - `Assets/_Project/Prefabs/{{SystemName}}/{{MainPrefab}}.prefab`
238
+ - id: component-diagrams
239
+ title: System Interaction Diagrams
240
+ type: mermaid
241
+ instruction: |
242
+ Create Mermaid diagrams to visualize game system relationships. Options:
243
+ - System architecture diagram for high-level view
244
+ - Component interaction diagram for detailed relationships
245
+ - Sequence diagrams for complex game loops (Update, FixedUpdate flows)
246
+ Choose the most appropriate for clarity and Unity-specific understanding
247
+
248
+ - id: gameplay-systems
249
+ title: Gameplay Systems Architecture
250
+ instruction: |
251
+ Define the core gameplay systems that drive the player experience. Focus on game-specific logic and mechanics.
252
+ elicit: true
253
+ sections:
254
+ - id: gameplay-overview
255
+ title: Gameplay Systems Overview
256
+ template: |
257
+ **Core Game Loop:** {{core_game_loop_description}}
258
+
259
+ **Player Actions:** {{primary_player_actions}}
260
+
261
+ **Game State Flow:** {{game_state_transitions}}
262
+ - id: gameplay-components
263
+ title: Gameplay Component Architecture
264
+ template: |
265
+ **Player Controller Components:**
266
+ - {{player_controller_components}}
267
+
268
+ **Game Logic Components:**
269
+ - {{game_logic_components}}
270
+
271
+ **Interaction Systems:**
272
+ - {{interaction_system_components}}
273
+
274
+ - id: component-architecture
275
+ title: Component Architecture Details
276
+ instruction: |
277
+ Define detailed Unity component architecture patterns and conventions for the game.
278
+ elicit: true
279
+ sections:
280
+ - id: monobehaviour-patterns
281
+ title: MonoBehaviour Patterns
282
+ template: |
283
+ **Component Composition:** {{component_composition_approach}}
284
+
285
+ **Lifecycle Management:** {{lifecycle_management_patterns}}
286
+
287
+ **Component Communication:** {{component_communication_methods}}
288
+ - id: scriptableobject-usage
289
+ title: ScriptableObject Architecture
290
+ template: |
291
+ **Data Architecture:** {{scriptableobject_data_patterns}}
292
+
293
+ **Configuration Management:** {{config_scriptableobject_usage}}
294
+
295
+ **Runtime Data:** {{runtime_scriptableobject_patterns}}
296
+
297
+ - id: physics-config
298
+ title: Physics Configuration
299
+ instruction: |
300
+ Define Unity 2D physics setup and configuration for the game.
301
+ elicit: true
302
+ sections:
303
+ - id: physics-settings
304
+ title: Physics Settings
305
+ template: |
306
+ **Physics 2D Settings:** {{physics_2d_configuration}}
307
+
308
+ **Collision Layers:** {{collision_layer_matrix}}
309
+
310
+ **Physics Materials:** {{physics_materials_setup}}
311
+ - id: rigidbody-patterns
312
+ title: Rigidbody Patterns
313
+ template: |
314
+ **Player Physics:** {{player_rigidbody_setup}}
315
+
316
+ **Object Physics:** {{object_physics_patterns}}
317
+
318
+ **Performance Optimization:** {{physics_optimization_strategies}}
319
+
320
+ - id: input-system
321
+ title: Input System Architecture
322
+ instruction: |
323
+ Define input handling using Unity's Input System package.
324
+ elicit: true
325
+ sections:
326
+ - id: input-actions
327
+ title: Input Actions Configuration
328
+ template: |
329
+ **Input Action Assets:** {{input_action_asset_structure}}
330
+
331
+ **Action Maps:** {{input_action_maps}}
332
+
333
+ **Control Schemes:** {{control_schemes_definition}}
334
+ - id: input-handling
335
+ title: Input Handling Patterns
336
+ template: |
337
+ **Player Input:** {{player_input_component_usage}}
338
+
339
+ **UI Input:** {{ui_input_handling_patterns}}
340
+
341
+ **Input Validation:** {{input_validation_strategies}}
342
+
343
+ - id: state-machines
344
+ title: State Machine Architecture
345
+ instruction: |
346
+ Define state machine patterns for game states, player states, and AI behavior.
347
+ elicit: true
348
+ sections:
349
+ - id: game-state-machine
350
+ title: Game State Machine
351
+ template: |
352
+ **Game States:** {{game_state_definitions}}
353
+
354
+ **State Transitions:** {{game_state_transition_rules}}
355
+
356
+ **State Management:** {{game_state_manager_implementation}}
357
+ - id: entity-state-machines
358
+ title: Entity State Machines
359
+ template: |
360
+ **Player States:** {{player_state_machine_design}}
361
+
362
+ **AI Behavior States:** {{ai_state_machine_patterns}}
363
+
364
+ **Object States:** {{object_state_management}}
365
+
366
+ - id: ui-architecture
367
+ title: UI Architecture
368
+ instruction: |
369
+ Define Unity UI system architecture using UGUI or UI Toolkit.
370
+ elicit: true
371
+ sections:
372
+ - id: ui-system-choice
373
+ title: UI System Selection
374
+ template: |
375
+ **UI Framework:** {{ui_framework_choice}} (UGUI/UI Toolkit)
376
+
377
+ **UI Scaling:** {{ui_scaling_strategy}}
378
+
379
+ **Canvas Setup:** {{canvas_configuration}}
380
+ - id: ui-navigation
381
+ title: UI Navigation System
382
+ template: |
383
+ **Screen Management:** {{screen_management_system}}
384
+
385
+ **Navigation Flow:** {{ui_navigation_patterns}}
386
+
387
+ **Back Button Handling:** {{back_button_implementation}}
388
+
389
+ - id: ui-components
390
+ title: UI Component System
391
+ instruction: |
392
+ Define reusable UI components and their implementation patterns.
393
+ elicit: true
394
+ sections:
395
+ - id: ui-component-library
396
+ title: UI Component Library
397
+ template: |
398
+ **Base Components:** {{base_ui_components}}
399
+
400
+ **Custom Components:** {{custom_ui_components}}
401
+
402
+ **Component Prefabs:** {{ui_prefab_organization}}
403
+ - id: ui-data-binding
404
+ title: UI Data Binding
405
+ template: |
406
+ **Data Binding Patterns:** {{ui_data_binding_approach}}
407
+
408
+ **UI Events:** {{ui_event_system}}
409
+
410
+ **View Model Patterns:** {{ui_viewmodel_implementation}}
411
+
412
+ - id: ui-state-management
413
+ title: UI State Management
414
+ instruction: |
415
+ Define how UI state is managed across the game.
416
+ elicit: true
417
+ sections:
418
+ - id: ui-state-patterns
419
+ title: UI State Patterns
420
+ template: |
421
+ **State Persistence:** {{ui_state_persistence}}
422
+
423
+ **Screen State:** {{screen_state_management}}
424
+
425
+ **UI Configuration:** {{ui_configuration_management}}
426
+
427
+ - id: scene-management
428
+ title: Scene Management Architecture
429
+ instruction: |
430
+ Define scene loading, unloading, and transition strategies.
431
+ elicit: true
432
+ sections:
433
+ - id: scene-structure
434
+ title: Scene Structure
435
+ template: |
436
+ **Scene Organization:** {{scene_organization_strategy}}
437
+
438
+ **Scene Hierarchy:** {{scene_hierarchy_patterns}}
439
+
440
+ **Persistent Scenes:** {{persistent_scene_usage}}
441
+ - id: scene-loading
442
+ title: Scene Loading System
443
+ template: |
444
+ **Loading Strategies:** {{scene_loading_patterns}}
445
+
446
+ **Async Loading:** {{async_scene_loading_implementation}}
447
+
448
+ **Loading Screens:** {{loading_screen_management}}
449
+
450
+ - id: data-persistence
451
+ title: Data Persistence Architecture
452
+ instruction: |
453
+ Define save system and data persistence strategies.
454
+ elicit: true
455
+ sections:
456
+ - id: save-data-structure
457
+ title: Save Data Structure
458
+ template: |
459
+ **Save Data Models:** {{save_data_model_design}}
460
+
461
+ **Serialization Format:** {{serialization_format_choice}}
462
+
463
+ **Data Validation:** {{save_data_validation}}
464
+ - id: persistence-strategy
465
+ title: Persistence Strategy
466
+ template: |
467
+ **Save Triggers:** {{save_trigger_events}}
468
+
469
+ **Auto-Save:** {{auto_save_implementation}}
470
+
471
+ **Cloud Save:** {{cloud_save_integration}}
472
+
473
+ - id: save-system
474
+ title: Save System Implementation
475
+ instruction: |
476
+ Define detailed save system implementation patterns.
477
+ elicit: true
478
+ sections:
479
+ - id: save-load-api
480
+ title: Save/Load API
481
+ template: |
482
+ **Save Interface:** {{save_interface_design}}
483
+
484
+ **Load Interface:** {{load_interface_design}}
485
+
486
+ **Error Handling:** {{save_load_error_handling}}
487
+ - id: save-file-management
488
+ title: Save File Management
489
+ template: |
490
+ **File Structure:** {{save_file_structure}}
491
+
492
+ **Backup Strategy:** {{save_backup_strategy}}
493
+
494
+ **Migration:** {{save_data_migration_strategy}}
495
+
496
+ - id: analytics-integration
497
+ title: Analytics Integration
498
+ instruction: |
499
+ Define analytics tracking and integration patterns.
500
+ condition: Game requires analytics tracking
501
+ elicit: true
502
+ sections:
503
+ - id: analytics-events
504
+ title: Analytics Event Design
505
+ template: |
506
+ **Event Categories:** {{analytics_event_categories}}
507
+
508
+ **Custom Events:** {{custom_analytics_events}}
509
+
510
+ **Player Progression:** {{progression_analytics}}
511
+ - id: analytics-implementation
512
+ title: Analytics Implementation
513
+ template: |
514
+ **Analytics SDK:** {{analytics_sdk_choice}}
515
+
516
+ **Event Tracking:** {{event_tracking_patterns}}
517
+
518
+ **Privacy Compliance:** {{analytics_privacy_considerations}}
519
+
520
+ - id: multiplayer-architecture
521
+ title: Multiplayer Architecture
522
+ instruction: |
523
+ Define multiplayer system architecture if applicable.
524
+ condition: Game includes multiplayer features
525
+ elicit: true
526
+ sections:
527
+ - id: networking-approach
528
+ title: Networking Approach
529
+ template: |
530
+ **Networking Solution:** {{networking_solution_choice}}
531
+
532
+ **Architecture Pattern:** {{multiplayer_architecture_pattern}}
533
+
534
+ **Synchronization:** {{state_synchronization_strategy}}
535
+ - id: multiplayer-systems
536
+ title: Multiplayer System Components
537
+ template: |
538
+ **Client Components:** {{multiplayer_client_components}}
539
+
540
+ **Server Components:** {{multiplayer_server_components}}
541
+
542
+ **Network Messages:** {{network_message_design}}
543
+
544
+ - id: rendering-pipeline
545
+ title: Rendering Pipeline Configuration
546
+ instruction: |
547
+ Define Unity rendering pipeline setup and optimization.
548
+ elicit: true
549
+ sections:
550
+ - id: render-pipeline-setup
551
+ title: Render Pipeline Setup
552
+ template: |
553
+ **Pipeline Choice:** {{render_pipeline_choice}} (URP/Built-in)
554
+
555
+ **Pipeline Asset:** {{render_pipeline_asset_config}}
556
+
557
+ **Quality Settings:** {{quality_settings_configuration}}
558
+ - id: rendering-optimization
559
+ title: Rendering Optimization
560
+ template: |
561
+ **Batching Strategies:** {{sprite_batching_optimization}}
562
+
563
+ **Draw Call Optimization:** {{draw_call_reduction_strategies}}
564
+
565
+ **Texture Optimization:** {{texture_optimization_settings}}
566
+
567
+ - id: shader-guidelines
568
+ title: Shader Guidelines
569
+ instruction: |
570
+ Define shader usage and custom shader guidelines.
571
+ elicit: true
572
+ sections:
573
+ - id: shader-usage
574
+ title: Shader Usage Patterns
575
+ template: |
576
+ **Built-in Shaders:** {{builtin_shader_usage}}
577
+
578
+ **Custom Shaders:** {{custom_shader_requirements}}
579
+
580
+ **Shader Variants:** {{shader_variant_management}}
581
+ - id: shader-performance
582
+ title: Shader Performance Guidelines
583
+ template: |
584
+ **Mobile Optimization:** {{mobile_shader_optimization}}
585
+
586
+ **Performance Budgets:** {{shader_performance_budgets}}
587
+
588
+ **Profiling Guidelines:** {{shader_profiling_approach}}
589
+
590
+ - id: sprite-management
591
+ title: Sprite Management
592
+ instruction: |
593
+ Define sprite asset management and optimization strategies.
594
+ elicit: true
595
+ sections:
596
+ - id: sprite-organization
597
+ title: Sprite Organization
598
+ template: |
599
+ **Atlas Strategy:** {{sprite_atlas_organization}}
600
+
601
+ **Sprite Naming:** {{sprite_naming_conventions}}
602
+
603
+ **Import Settings:** {{sprite_import_settings}}
604
+ - id: sprite-optimization
605
+ title: Sprite Optimization
606
+ template: |
607
+ **Compression Settings:** {{sprite_compression_settings}}
608
+
609
+ **Resolution Strategy:** {{sprite_resolution_strategy}}
610
+
611
+ **Memory Optimization:** {{sprite_memory_optimization}}
612
+
613
+ - id: particle-systems
614
+ title: Particle System Architecture
615
+ instruction: |
616
+ Define particle system usage and optimization.
617
+ elicit: true
618
+ sections:
619
+ - id: particle-design
620
+ title: Particle System Design
621
+ template: |
622
+ **Effect Categories:** {{particle_effect_categories}}
623
+
624
+ **Prefab Organization:** {{particle_prefab_organization}}
625
+
626
+ **Pooling Strategy:** {{particle_pooling_implementation}}
627
+ - id: particle-performance
628
+ title: Particle Performance
629
+ template: |
630
+ **Performance Budgets:** {{particle_performance_budgets}}
631
+
632
+ **Mobile Optimization:** {{particle_mobile_optimization}}
633
+
634
+ **LOD Strategy:** {{particle_lod_implementation}}
635
+
636
+ - id: audio-architecture
637
+ title: Audio Architecture
638
+ instruction: |
639
+ Define audio system architecture and implementation.
640
+ elicit: true
641
+ sections:
642
+ - id: audio-system-design
643
+ title: Audio System Design
644
+ template: |
645
+ **Audio Manager:** {{audio_manager_implementation}}
646
+
647
+ **Audio Sources:** {{audio_source_management}}
648
+
649
+ **3D Audio:** {{spatial_audio_implementation}}
650
+ - id: audio-categories
651
+ title: Audio Categories
652
+ template: |
653
+ **Music System:** {{music_system_architecture}}
654
+
655
+ **Sound Effects:** {{sfx_system_design}}
656
+
657
+ **Voice/Dialog:** {{dialog_system_implementation}}
658
+
659
+ - id: audio-mixing
660
+ title: Audio Mixing Configuration
661
+ instruction: |
662
+ Define Unity Audio Mixer setup and configuration.
663
+ elicit: true
664
+ sections:
665
+ - id: mixer-setup
666
+ title: Audio Mixer Setup
667
+ template: |
668
+ **Mixer Groups:** {{audio_mixer_group_structure}}
669
+
670
+ **Effects Chain:** {{audio_effects_configuration}}
671
+
672
+ **Snapshot System:** {{audio_snapshot_usage}}
673
+ - id: dynamic-mixing
674
+ title: Dynamic Audio Mixing
675
+ template: |
676
+ **Volume Control:** {{volume_control_implementation}}
677
+
678
+ **Dynamic Range:** {{dynamic_range_management}}
679
+
680
+ **Platform Optimization:** {{platform_audio_optimization}}
681
+
682
+ - id: sound-banks
683
+ title: Sound Bank Management
684
+ instruction: |
685
+ Define sound asset organization and loading strategies.
686
+ elicit: true
687
+ sections:
688
+ - id: sound-organization
689
+ title: Sound Asset Organization
690
+ template: |
691
+ **Bank Structure:** {{sound_bank_organization}}
692
+
693
+ **Loading Strategy:** {{audio_loading_patterns}}
694
+
695
+ **Memory Management:** {{audio_memory_management}}
696
+ - id: sound-streaming
697
+ title: Audio Streaming
698
+ template: |
699
+ **Streaming Strategy:** {{audio_streaming_implementation}}
700
+
701
+ **Compression Settings:** {{audio_compression_settings}}
702
+
703
+ **Platform Considerations:** {{platform_audio_considerations}}
704
+
705
+ - id: unity-conventions
706
+ title: Unity Development Conventions
707
+ instruction: |
708
+ Define Unity-specific development conventions and best practices.
709
+ elicit: true
710
+ sections:
711
+ - id: unity-best-practices
712
+ title: Unity Best Practices
713
+ template: |
714
+ **Component Design:** {{unity_component_best_practices}}
715
+
716
+ **Performance Guidelines:** {{unity_performance_guidelines}}
717
+
718
+ **Memory Management:** {{unity_memory_best_practices}}
719
+ - id: unity-workflow
720
+ title: Unity Workflow Conventions
721
+ template: |
722
+ **Scene Workflow:** {{scene_workflow_conventions}}
723
+
724
+ **Prefab Workflow:** {{prefab_workflow_conventions}}
725
+
726
+ **Asset Workflow:** {{asset_workflow_conventions}}
727
+
728
+ - id: external-integrations
729
+ title: External Integrations
730
+ condition: Game requires external service integrations
731
+ instruction: |
732
+ For each external service integration required by the game:
733
+
734
+ 1. Identify services needed based on GDD requirements and platform needs
735
+ 2. If documentation URLs are unknown, ask user for specifics
736
+ 3. Document authentication methods and Unity-specific integration approaches
737
+ 4. List specific APIs that will be used
738
+ 5. Note any platform-specific SDKs or Unity packages required
739
+
740
+ If no external integrations are needed, state this explicitly and skip to next section.
741
+ elicit: true
742
+ repeatable: true
743
+ sections:
744
+ - id: integration
745
+ title: "{{service_name}} Integration"
746
+ template: |
747
+ - **Purpose:** {{service_purpose}}
748
+ - **Documentation:** {{service_docs_url}}
749
+ - **Unity Package:** {{unity_package_name}} {{version}}
750
+ - **Platform SDK:** {{platform_sdk_requirements}}
751
+ - **Authentication:** {{auth_method}}
752
+
753
+ **Key Features Used:**
754
+ - {{feature_1}} - {{feature_purpose}}
755
+ - {{feature_2}} - {{feature_purpose}}
756
+
757
+ **Unity Implementation Notes:** {{unity_integration_details}}
758
+
759
+ - id: core-workflows
760
+ title: Core Game Workflows
761
+ type: mermaid
762
+ mermaid_type: sequence
763
+ instruction: |
764
+ Illustrate key game workflows using sequence diagrams:
765
+
766
+ 1. Identify critical player journeys from GDD (game loop, level progression, etc.)
767
+ 2. Show system interactions including Unity lifecycle methods
768
+ 3. Include error handling paths and state transitions
769
+ 4. Document async operations (scene loading, asset loading)
770
+ 5. Create both high-level game flow and detailed system interaction diagrams
771
+
772
+ Focus on workflows that clarify Unity-specific architecture decisions or complex system interactions.
773
+ elicit: true
774
+
775
+ - id: unity-project-structure
776
+ title: Unity Project Structure
777
+ type: code
778
+ language: plaintext
779
+ instruction: |
780
+ Create a Unity project folder structure that reflects:
781
+
782
+ 1. Unity best practices for 2D game organization
783
+ 2. The selected render pipeline and packages
784
+ 3. Component organization from above systems
785
+ 4. Clear separation of concerns for game assets
786
+ 5. Testing structure for Unity Test Framework
787
+ 6. Platform-specific asset organization
788
+
789
+ Follow Unity naming conventions and folder organization standards.
790
+ elicit: true
791
+ examples:
792
+ - |
793
+ ProjectName/
794
+ ├── Assets/
795
+ │ └── _Project/ # Main project folder
796
+ │ ├── Scenes/ # Game scenes
797
+ │ │ ├── Gameplay/ # Level scenes
798
+ │ │ ├── UI/ # UI-only scenes
799
+ │ │ └── Loading/ # Loading scenes
800
+ │ ├── Scripts/ # C# scripts
801
+ │ │ ├── Core/ # Core systems
802
+ │ │ ├── Gameplay/ # Gameplay mechanics
803
+ │ │ ├── UI/ # UI controllers
804
+ │ │ └── Data/ # ScriptableObjects
805
+ │ ├── Prefabs/ # Reusable game objects
806
+ │ │ ├── Characters/ # Player, enemies
807
+ │ │ ├── Environment/ # Level elements
808
+ │ │ └── UI/ # UI prefabs
809
+ │ ├── Art/ # Visual assets
810
+ │ │ ├── Sprites/ # 2D sprites
811
+ │ │ ├── Materials/ # Unity materials
812
+ │ │ └── Shaders/ # Custom shaders
813
+ │ ├── Audio/ # Audio assets
814
+ │ │ ├── Music/ # Background music
815
+ │ │ ├── SFX/ # Sound effects
816
+ │ │ └── Mixers/ # Audio mixers
817
+ │ ├── Data/ # Game data
818
+ │ │ ├── Settings/ # Game settings
819
+ │ │ └── Balance/ # Balance data
820
+ │ └── Tests/ # Unity tests
821
+ │ ├── EditMode/ # Edit mode tests
822
+ │ └── PlayMode/ # Play mode tests
823
+ ├── Packages/ # Package Manager
824
+ │ └── manifest.json # Package dependencies
825
+ └── ProjectSettings/ # Unity project settings
826
+
827
+ - id: infrastructure-deployment
828
+ title: Infrastructure and Deployment
829
+ instruction: |
830
+ Define the Unity build and deployment architecture:
831
+
832
+ 1. Use Unity's build system and any additional tools
833
+ 2. Choose deployment strategy appropriate for target platforms
834
+ 3. Define environments (development, staging, production builds)
835
+ 4. Establish version control and build pipeline practices
836
+ 5. Consider platform-specific requirements and store submissions
837
+
838
+ Get user input on build preferences and CI/CD tool choices for Unity projects.
839
+ elicit: true
840
+ sections:
841
+ - id: unity-build-configuration
842
+ title: Unity Build Configuration
843
+ template: |
844
+ - **Unity Version:** {{unity_version}} LTS
845
+ - **Build Pipeline:** {{build_pipeline_type}}
846
+ - **Addressables:** {{addressables_usage}}
847
+ - **Asset Bundles:** {{asset_bundle_strategy}}
848
+ - id: deployment-strategy
849
+ title: Deployment Strategy
850
+ template: |
851
+ - **Build Automation:** {{build_automation_tool}}
852
+ - **Version Control:** {{version_control_integration}}
853
+ - **Distribution:** {{distribution_platforms}}
854
+ - id: environments
855
+ title: Build Environments
856
+ repeatable: true
857
+ template: "- **{{env_name}}:** {{env_purpose}} - {{platform_settings}}"
858
+ - id: platform-specific-builds
859
+ title: Platform-Specific Build Settings
860
+ type: code
861
+ language: text
862
+ template: "{{platform_build_configurations}}"
863
+
864
+ - id: coding-standards
865
+ title: Coding Standards
866
+ instruction: |
867
+ These standards are MANDATORY for AI agents working on Unity game development. Work with user to define ONLY the critical rules needed to prevent bad Unity code. Explain that:
868
+
869
+ 1. This section directly controls AI developer behavior
870
+ 2. Keep it minimal - assume AI knows general C# and Unity best practices
871
+ 3. Focus on project-specific Unity conventions and gotchas
872
+ 4. Overly detailed standards bloat context and slow development
873
+ 5. Standards will be extracted to separate file for dev agent use
874
+
875
+ For each standard, get explicit user confirmation it's necessary.
876
+ elicit: true
877
+ sections:
878
+ - id: core-standards
879
+ title: Core Standards
880
+ template: |
881
+ - **Unity Version:** {{unity_version}} LTS
882
+ - **C# Language Version:** {{csharp_version}}
883
+ - **Code Style:** Microsoft C# conventions + Unity naming
884
+ - **Testing Framework:** Unity Test Framework (NUnit-based)
885
+ - id: unity-naming-conventions
886
+ title: Unity Naming Conventions
887
+ type: table
888
+ columns: [Element, Convention, Example]
889
+ instruction: Only include if deviating from Unity defaults
890
+ examples:
891
+ - "| MonoBehaviour | PascalCase + Component suffix | PlayerController, HealthSystem |"
892
+ - "| ScriptableObject | PascalCase + Data/Config suffix | PlayerData, GameConfig |"
893
+ - "| Prefab | PascalCase descriptive | PlayerCharacter, EnvironmentTile |"
894
+ - id: critical-rules
895
+ title: Critical Unity Rules
896
+ instruction: |
897
+ List ONLY rules that AI might violate or Unity-specific requirements. Examples:
898
+ - "Always cache GetComponent calls in Awake() or Start()"
899
+ - "Use [SerializeField] for private fields that need Inspector access"
900
+ - "Prefer UnityEvents over C# events for Inspector-assignable callbacks"
901
+ - "Never call GameObject.Find() in Update, FixedUpdate, or LateUpdate"
902
+
903
+ Avoid obvious rules like "follow SOLID principles" or "optimize performance"
904
+ repeatable: true
905
+ template: "- **{{rule_name}}:** {{rule_description}}"
906
+ - id: unity-specifics
907
+ title: Unity-Specific Guidelines
908
+ condition: Critical Unity-specific rules needed
909
+ instruction: Add ONLY if critical for preventing AI mistakes with Unity APIs
910
+ sections:
911
+ - id: unity-lifecycle
912
+ title: Unity Lifecycle Rules
913
+ repeatable: true
914
+ template: "- **{{lifecycle_method}}:** {{usage_rule}}"
915
+
916
+ - id: test-strategy
917
+ title: Test Strategy and Standards
918
+ instruction: |
919
+ Work with user to define comprehensive Unity test strategy:
920
+
921
+ 1. Use Unity Test Framework for both Edit Mode and Play Mode tests
922
+ 2. Decide on test-driven development vs test-after approach
923
+ 3. Define test organization and naming for Unity projects
924
+ 4. Establish coverage goals for game logic
925
+ 5. Determine integration test infrastructure (scene-based testing)
926
+ 6. Plan for test data and mock external dependencies
927
+
928
+ Note: Basic info goes in Coding Standards for dev agent. This detailed section is for comprehensive testing strategy.
929
+ elicit: true
930
+ sections:
931
+ - id: testing-philosophy
932
+ title: Testing Philosophy
933
+ template: |
934
+ - **Approach:** {{test_approach}}
935
+ - **Coverage Goals:** {{coverage_targets}}
936
+ - **Test Distribution:** {{edit_mode_vs_play_mode_split}}
937
+ - id: unity-test-types
938
+ title: Unity Test Types and Organization
939
+ sections:
940
+ - id: edit-mode-tests
941
+ title: Edit Mode Tests
942
+ template: |
943
+ - **Framework:** Unity Test Framework (Edit Mode)
944
+ - **File Convention:** {{edit_mode_test_naming}}
945
+ - **Location:** `Assets/_Project/Tests/EditMode/`
946
+ - **Purpose:** C# logic testing without Unity runtime
947
+ - **Coverage Requirement:** {{edit_mode_coverage}}
948
+
949
+ **AI Agent Requirements:**
950
+ - Test ScriptableObject data validation
951
+ - Test utility classes and static methods
952
+ - Test serialization/deserialization logic
953
+ - Mock Unity APIs where necessary
954
+ - id: play-mode-tests
955
+ title: Play Mode Tests
956
+ template: |
957
+ - **Framework:** Unity Test Framework (Play Mode)
958
+ - **Location:** `Assets/_Project/Tests/PlayMode/`
959
+ - **Purpose:** Integration testing with Unity runtime
960
+ - **Test Scenes:** {{test_scene_requirements}}
961
+ - **Coverage Requirement:** {{play_mode_coverage}}
962
+
963
+ **AI Agent Requirements:**
964
+ - Test MonoBehaviour component interactions
965
+ - Test scene loading and GameObject lifecycle
966
+ - Test physics interactions and collision systems
967
+ - Test UI interactions and event systems
968
+ - id: test-data-management
969
+ title: Test Data Management
970
+ template: |
971
+ - **Strategy:** {{test_data_approach}}
972
+ - **ScriptableObject Fixtures:** {{test_scriptableobject_location}}
973
+ - **Test Scene Templates:** {{test_scene_templates}}
974
+ - **Cleanup Strategy:** {{cleanup_approach}}
975
+
976
+ - id: security
977
+ title: Security Considerations
978
+ instruction: |
979
+ Define security requirements specific to Unity game development:
980
+
981
+ 1. Focus on Unity-specific security concerns
982
+ 2. Consider platform store requirements
983
+ 3. Address save data protection and anti-cheat measures
984
+ 4. Define secure communication patterns for multiplayer
985
+ 5. These rules directly impact Unity code generation
986
+ elicit: true
987
+ sections:
988
+ - id: save-data-security
989
+ title: Save Data Security
990
+ template: |
991
+ - **Encryption:** {{save_data_encryption_method}}
992
+ - **Validation:** {{save_data_validation_approach}}
993
+ - **Anti-Tampering:** {{anti_tampering_measures}}
994
+ - id: platform-security
995
+ title: Platform Security Requirements
996
+ template: |
997
+ - **Mobile Permissions:** {{mobile_permission_requirements}}
998
+ - **Store Compliance:** {{platform_store_requirements}}
999
+ - **Privacy Policy:** {{privacy_policy_requirements}}
1000
+ - id: multiplayer-security
1001
+ title: Multiplayer Security (if applicable)
1002
+ condition: Game includes multiplayer features
1003
+ template: |
1004
+ - **Client Validation:** {{client_validation_rules}}
1005
+ - **Server Authority:** {{server_authority_approach}}
1006
+ - **Anti-Cheat:** {{anti_cheat_measures}}
1007
+
1008
+ - id: checklist-results
1009
+ title: Checklist Results Report
1010
+ instruction: Before running the checklist, offer to output the full game architecture document. Once user confirms, execute the architect-checklist and populate results here.
1011
+
1012
+ - id: next-steps
1013
+ title: Next Steps
1014
+ instruction: |
1015
+ After completing the game architecture:
1016
+
1017
+ 1. Review with Game Designer and technical stakeholders
1018
+ 2. Begin story implementation with Game Developer agent
1019
+ 3. Set up Unity project structure and initial configuration
1020
+ 4. Configure version control and build pipeline
1021
+
1022
+ Include specific prompts for next agents if needed.
1023
+ sections:
1024
+ - id: developer-prompt
1025
+ title: Game Developer Prompt
1026
+ instruction: |
1027
+ Create a brief prompt to hand off to Game Developer for story implementation. Include:
1028
+ - Reference to this game architecture document
1029
+ - Key Unity-specific requirements from this architecture
1030
+ - Any Unity package or configuration decisions made here
1031
+ - Request for adherence to established coding standards and patterns