appiq-solution 1.3.3 → 1.4.2

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 (295) hide show
  1. package/#Tools/APPIQ-METHOD/.bmad-config.json +13 -0
  2. package/#Tools/APPIQ-METHOD/.cursor/commands/analyze.md +27 -0
  3. package/#Tools/APPIQ-METHOD/.cursor/commands/appiq.md +27 -0
  4. package/#Tools/APPIQ-METHOD/.cursor/commands/help.md +27 -0
  5. package/#Tools/APPIQ-METHOD/.cursor/commands/story.md +27 -0
  6. package/#Tools/APPIQ-METHOD/CHANGELOG.md +119 -173
  7. package/#Tools/APPIQ-METHOD/DEVELOPMENT_GUIDE.md +855 -0
  8. package/#Tools/APPIQ-METHOD/NPM-README.md +138 -0
  9. package/#Tools/APPIQ-METHOD/SMART_WORKFLOW_GUIDE.md +401 -0
  10. package/#Tools/APPIQ-METHOD/activate-appiq.js +81 -0
  11. package/#Tools/APPIQ-METHOD/appiq-solution/README.md +226 -0
  12. package/#Tools/APPIQ-METHOD/bmad-core/agent-teams/team-flutter-mobile.yaml +114 -0
  13. package/#Tools/APPIQ-METHOD/bmad-core/agent-teams/team-fullstack.yaml +11 -1
  14. package/#Tools/APPIQ-METHOD/bmad-core/agents/analyst.md +7 -3
  15. package/#Tools/APPIQ-METHOD/bmad-core/agents/architect.md +6 -0
  16. package/#Tools/APPIQ-METHOD/bmad-core/agents/bmad-orchestrator.md +0 -84
  17. package/#Tools/APPIQ-METHOD/bmad-core/agents/bmad-smart-launcher.md +170 -0
  18. package/#Tools/APPIQ-METHOD/bmad-core/agents/dev.md +31 -12
  19. package/#Tools/APPIQ-METHOD/bmad-core/agents/pm.md +10 -4
  20. package/#Tools/APPIQ-METHOD/bmad-core/agents/qa.md +17 -0
  21. package/#Tools/APPIQ-METHOD/bmad-core/agents/sm.md +8 -3
  22. package/#Tools/APPIQ-METHOD/bmad-core/agents/ux-expert.md +8 -3
  23. package/#Tools/APPIQ-METHOD/bmad-core/bmad-core/user-guide.md +0 -0
  24. package/#Tools/APPIQ-METHOD/bmad-core/checklists/security-validation-checklist.md +332 -0
  25. package/#Tools/APPIQ-METHOD/bmad-core/data/backend-services-integration.md +686 -0
  26. package/#Tools/APPIQ-METHOD/bmad-core/data/shadcn-ui-integration.md +388 -0
  27. package/#Tools/APPIQ-METHOD/bmad-core/data/technical-preferences.md +147 -1
  28. package/#Tools/APPIQ-METHOD/bmad-core/enhanced-ide-development-workflow.md +43 -0
  29. package/#Tools/APPIQ-METHOD/bmad-core/tasks/create-flutter-story.md +197 -0
  30. package/#Tools/APPIQ-METHOD/bmad-core/tasks/intelligent-epic-creation.md +234 -0
  31. package/#Tools/APPIQ-METHOD/bmad-core/tasks/smart-project-analysis.md +289 -0
  32. package/#Tools/APPIQ-METHOD/bmad-core/templates/flutter-mobile-prd-tmpl.yaml +330 -0
  33. package/#Tools/APPIQ-METHOD/bmad-core/templates/flutter-story-tmpl.yaml +376 -0
  34. package/#Tools/APPIQ-METHOD/bmad-core/templates/flutter-ui-spec-tmpl.yaml +415 -0
  35. package/#Tools/APPIQ-METHOD/bmad-core/templates/fullstack-architecture-tmpl.yaml +12 -5
  36. package/#Tools/APPIQ-METHOD/bmad-core/user-guide.md +10 -9
  37. package/#Tools/APPIQ-METHOD/bmad-core/workflows/brownfield-fullstack.yaml +15 -1
  38. package/#Tools/APPIQ-METHOD/bmad-core/workflows/greenfield-fullstack.yaml +49 -5
  39. package/#Tools/APPIQ-METHOD/bmad-core/working-in-the-brownfield.md +56 -44
  40. package/#Tools/APPIQ-METHOD/commands/README.md +28 -0
  41. package/#Tools/APPIQ-METHOD/commands/analyze.md +27 -0
  42. package/#Tools/APPIQ-METHOD/commands/appiq.md +27 -0
  43. package/#Tools/APPIQ-METHOD/commands/help.md +27 -0
  44. package/#Tools/APPIQ-METHOD/commands/story.md +27 -0
  45. package/#Tools/APPIQ-METHOD/dist/agents/bmad-orchestrator.txt +0 -111
  46. package/#Tools/APPIQ-METHOD/dist/agents/pm.txt +2 -0
  47. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-2d-phaser-game-dev/teams/phaser-2d-nodejs-game-team.txt +0 -111
  48. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-2d-unity-game-dev/teams/unity-2d-game-team.txt +0 -111
  49. package/#Tools/APPIQ-METHOD/dist/teams/team-all.txt +2 -111
  50. package/#Tools/APPIQ-METHOD/dist/teams/team-fullstack.txt +2 -111
  51. package/#Tools/APPIQ-METHOD/dist/teams/team-ide-minimal.txt +0 -111
  52. package/#Tools/APPIQ-METHOD/dist/teams/team-no-ui.txt +2 -111
  53. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-2d-phaser-game-dev/config.yaml +1 -1
  54. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-2d-unity-game-dev/config.yaml +1 -1
  55. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/agent-teams/flutter-mobile-team.yaml +23 -0
  56. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/agents/flutter-cubit-agent.md +133 -0
  57. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/agents/flutter-data-agent.md +160 -0
  58. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/agents/flutter-domain-agent.md +153 -0
  59. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/agents/flutter-ui-agent.md +122 -0
  60. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/agents/shared-components-agent.md +161 -0
  61. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/checklists/flutter-story-dod-checklist.md +194 -0
  62. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/config.yaml +41 -0
  63. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/data/flutter-development-guidelines.md +551 -0
  64. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/templates/flutter-mobile-architecture-tmpl.yaml +530 -0
  65. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-flutter-mobile-dev/workflows/flutter-ui-first-development.yaml +220 -0
  66. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-infrastructure-devops/config.yaml +1 -1
  67. package/#Tools/APPIQ-METHOD/install-appiq.sh +41 -0
  68. package/#Tools/APPIQ-METHOD/package-lock.json +631 -0
  69. package/#Tools/APPIQ-METHOD/package.json +20 -69
  70. package/#Tools/APPIQ-METHOD/tasks/todo.md +275 -0
  71. package/#Tools/APPIQ-METHOD/tools/appiq-installer.js +2622 -0
  72. package/#Tools/APPIQ-METHOD/tools/bmad-npx-wrapper.js +5 -7
  73. package/#Tools/APPIQ-METHOD/tools/cli.js +3 -3
  74. package/#Tools/APPIQ-METHOD/tools/epic-solution-installer.js +538 -0
  75. package/#Tools/APPIQ-METHOD/tools/flattener/main.js +570 -0
  76. package/#Tools/APPIQ-METHOD/tools/installer/bin/bmad.js +15 -14
  77. package/#Tools/APPIQ-METHOD/tools/installer/lib/installer.js +28 -2
  78. package/#Tools/APPIQ-METHOD/tools/installer/package-lock.json +906 -0
  79. package/#Tools/APPIQ-METHOD/tools/installer/package.json +1 -1
  80. package/#Tools/APPIQ-METHOD/tools/setup-ide-commands.js +345 -0
  81. package/#Tools/APPIQ-METHOD/tools/smart-installer.js +589 -0
  82. package/package.json +20 -69
  83. package/tools/appiq-installer.js +2622 -0
  84. package/tools/bmad-npx-wrapper.js +5 -7
  85. package/tools/cli.js +3 -3
  86. package/tools/epic-solution-installer.js +538 -0
  87. package/tools/flattener/main.js +570 -0
  88. package/tools/installer/bin/bmad.js +15 -14
  89. package/tools/installer/lib/installer.js +28 -2
  90. package/tools/installer/package-lock.json +89 -89
  91. package/tools/installer/package.json +1 -1
  92. package/tools/setup-ide-commands.js +345 -0
  93. package/tools/smart-installer.js +589 -0
  94. package/#Tools/APPIQ-METHOD/appiq_start.md +0 -232
  95. package/#Tools/APPIQ-METHOD/deployment/DEPLOYMENT_GUIDE.md +0 -426
  96. package/#Tools/APPIQ-METHOD/deployment/GITHUB_RELEASE_GUIDE.md +0 -326
  97. package/#Tools/APPIQ-METHOD/deployment/README.md +0 -331
  98. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agent-teams/team-all.yaml +0 -14
  99. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agent-teams/team-fullstack.yaml +0 -18
  100. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agent-teams/team-ide-minimal.yaml +0 -10
  101. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agent-teams/team-no-ui.yaml +0 -13
  102. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/analyst.md +0 -81
  103. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/architect.md +0 -84
  104. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/bmad-master.md +0 -108
  105. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/bmad-orchestrator.md +0 -234
  106. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/dev.md +0 -76
  107. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/pm.md +0 -79
  108. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/po.md +0 -76
  109. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/qa.md +0 -69
  110. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/sm.md +0 -62
  111. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/agents/ux-expert.md +0 -66
  112. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/checklists/architect-checklist.md +0 -443
  113. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/checklists/change-checklist.md +0 -182
  114. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/checklists/pm-checklist.md +0 -375
  115. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/checklists/po-master-checklist.md +0 -441
  116. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/checklists/story-dod-checklist.md +0 -101
  117. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/checklists/story-draft-checklist.md +0 -156
  118. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/data/bmad-kb.md +0 -803
  119. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/data/brainstorming-techniques.md +0 -36
  120. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/data/elicitation-methods.md +0 -134
  121. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/data/technical-preferences.md +0 -3
  122. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/advanced-elicitation.md +0 -117
  123. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/brownfield-create-epic.md +0 -160
  124. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/brownfield-create-story.md +0 -147
  125. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/correct-course.md +0 -70
  126. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/create-brownfield-story.md +0 -304
  127. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/create-deep-research-prompt.md +0 -289
  128. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/create-next-story.md +0 -112
  129. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/document-project.md +0 -341
  130. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/facilitate-brainstorming-session.md +0 -136
  131. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/generate-ai-frontend-prompt.md +0 -51
  132. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/index-docs.md +0 -179
  133. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/kb-mode-interaction.md +0 -75
  134. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/review-story.md +0 -145
  135. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/shard-doc.md +0 -187
  136. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/tasks/validate-next-story.md +0 -134
  137. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/architecture-tmpl.yaml +0 -650
  138. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/brainstorming-output-tmpl.yaml +0 -156
  139. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/brownfield-architecture-tmpl.yaml +0 -476
  140. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/brownfield-prd-tmpl.yaml +0 -280
  141. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/competitor-analysis-tmpl.yaml +0 -293
  142. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/front-end-architecture-tmpl.yaml +0 -206
  143. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/front-end-spec-tmpl.yaml +0 -349
  144. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/fullstack-architecture-tmpl.yaml +0 -805
  145. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/market-research-tmpl.yaml +0 -252
  146. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/prd-tmpl.yaml +0 -202
  147. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/project-brief-tmpl.yaml +0 -221
  148. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/templates/story-tmpl.yaml +0 -137
  149. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/user-guide.md +0 -250
  150. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/workflows/brownfield-fullstack.yaml +0 -297
  151. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/workflows/brownfield-service.yaml +0 -187
  152. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/workflows/brownfield-ui.yaml +0 -197
  153. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/workflows/greenfield-fullstack.yaml +0 -240
  154. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/workflows/greenfield-service.yaml +0 -206
  155. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/workflows/greenfield-ui.yaml +0 -235
  156. package/#Tools/APPIQ-METHOD/deployment/build/bmad-core/working-in-the-brownfield.md +0 -361
  157. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/README.md +0 -3
  158. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/agent-teams/phaser-2d-nodejs-game-team.yaml +0 -13
  159. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/agents/game-designer.md +0 -71
  160. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/agents/game-developer.md +0 -78
  161. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/agents/game-sm.md +0 -64
  162. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/checklists/game-design-checklist.md +0 -201
  163. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/checklists/game-story-dod-checklist.md +0 -160
  164. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/config.yaml +0 -8
  165. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/data/bmad-kb.md +0 -254
  166. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/data/development-guidelines.md +0 -651
  167. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/tasks/advanced-elicitation.md +0 -111
  168. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/tasks/create-game-story.md +0 -216
  169. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/tasks/game-design-brainstorming.md +0 -308
  170. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/templates/game-architecture-tmpl.yaml +0 -613
  171. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/templates/game-brief-tmpl.yaml +0 -356
  172. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/templates/game-design-doc-tmpl.yaml +0 -343
  173. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/templates/game-story-tmpl.yaml +0 -253
  174. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/templates/level-design-doc-tmpl.yaml +0 -484
  175. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/workflows/game-dev-greenfield.yaml +0 -183
  176. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-phaser-game-dev/workflows/game-prototype.yaml +0 -175
  177. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/agent-teams/unity-2d-game-team.yaml +0 -14
  178. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/agents/game-architect.md +0 -80
  179. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/agents/game-designer.md +0 -77
  180. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/agents/game-developer.md +0 -78
  181. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/agents/game-sm.md +0 -65
  182. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/checklists/game-architect-checklist.md +0 -396
  183. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/checklists/game-change-checklist.md +0 -203
  184. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/checklists/game-design-checklist.md +0 -201
  185. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/checklists/game-story-dod-checklist.md +0 -132
  186. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/config.yaml +0 -6
  187. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/data/bmad-kb.md +0 -776
  188. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/data/development-guidelines.md +0 -590
  189. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/tasks/advanced-elicitation.md +0 -111
  190. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/tasks/correct-course-game.md +0 -151
  191. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/tasks/create-game-story.md +0 -184
  192. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/tasks/game-design-brainstorming.md +0 -308
  193. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/tasks/validate-game-story.md +0 -200
  194. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/templates/game-architecture-tmpl.yaml +0 -1030
  195. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/templates/game-brief-tmpl.yaml +0 -356
  196. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/templates/game-design-doc-tmpl.yaml +0 -705
  197. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/templates/game-story-tmpl.yaml +0 -256
  198. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/templates/level-design-doc-tmpl.yaml +0 -484
  199. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/workflows/game-dev-greenfield.yaml +0 -183
  200. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-2d-unity-game-dev/workflows/game-prototype.yaml +0 -175
  201. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/README.md +0 -147
  202. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/agents/infra-devops-platform.md +0 -71
  203. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/checklists/infrastructure-checklist.md +0 -484
  204. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/config.yaml +0 -9
  205. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/data/bmad-kb.md +0 -308
  206. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/tasks/review-infrastructure.md +0 -160
  207. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/tasks/validate-infrastructure.md +0 -154
  208. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/templates/infrastructure-architecture-tmpl.yaml +0 -424
  209. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-infrastructure-devops/templates/infrastructure-platform-from-arch-tmpl.yaml +0 -629
  210. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agent-teams/mobile-team-cross-platform.yaml +0 -22
  211. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agent-teams/mobile-team-flutter.yaml +0 -20
  212. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agent-teams/mobile-team-minimal.yaml +0 -13
  213. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agent-teams/mobile-team-react-native.yaml +0 -20
  214. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agents/mobile-analytics.md +0 -1487
  215. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agents/mobile-architect.md +0 -279
  216. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agents/mobile-developer.md +0 -649
  217. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agents/mobile-pm.md +0 -339
  218. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agents/mobile-qa.md +0 -622
  219. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agents/mobile-security.md +0 -1027
  220. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/agents/mobile-ux-expert.md +0 -1451
  221. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/checklists/mobile-development-checklist.md +0 -490
  222. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/config.yaml +0 -54
  223. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/data/bmad-kb.md +0 -292
  224. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/data/flutter-development-guidelines.md +0 -483
  225. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/tasks/existing-app-analysis.md +0 -645
  226. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/tasks/platform-selection.md +0 -489
  227. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/templates/mobile-architecture-tmpl.yaml +0 -437
  228. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/templates/mobile-prd-tmpl.yaml +0 -408
  229. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/workflows/mobile-app-development-init.yaml +0 -555
  230. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/workflows/mobile-brownfield-flutter.yaml +0 -336
  231. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/workflows/mobile-brownfield-react-native.yaml +0 -345
  232. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/workflows/mobile-greenfield-flutter.yaml +0 -281
  233. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/workflows/mobile-greenfield-react-native.yaml +0 -283
  234. package/#Tools/APPIQ-METHOD/deployment/build/expansion-packs/bmad-mobile-app-dev/workflows/mobile-platform-selection.yaml +0 -404
  235. package/#Tools/APPIQ-METHOD/deployment/build/slash-commands/appiq.md +0 -273
  236. package/#Tools/APPIQ-METHOD/deployment/build/slash-commands/ide-integrations/claude-appiq.md +0 -294
  237. package/#Tools/APPIQ-METHOD/deployment/build/slash-commands/ide-integrations/cursor-appiq.md +0 -516
  238. package/#Tools/APPIQ-METHOD/deployment/build/slash-commands/ide-integrations/universal-appiq.md +0 -448
  239. package/#Tools/APPIQ-METHOD/deployment/build/slash-commands/ide-integrations/windsurf-appiq.md +0 -698
  240. package/#Tools/APPIQ-METHOD/deployment/build/slash-commands/start.md +0 -211
  241. package/#Tools/APPIQ-METHOD/deployment/build-release.sh +0 -449
  242. package/#Tools/APPIQ-METHOD/deployment/create-release.sh +0 -196
  243. package/#Tools/APPIQ-METHOD/deployment/dist/appiq_installer.sh +0 -678
  244. package/#Tools/APPIQ-METHOD/deployment/docs/main_prd.md +0 -36
  245. package/#Tools/APPIQ-METHOD/deployment/init_appiq.sh +0 -805
  246. package/#Tools/APPIQ-METHOD/deployment/init_appiq_v2.sh +0 -678
  247. package/#Tools/APPIQ-METHOD/deployment/installers/appiq-global.sh +0 -91
  248. package/#Tools/APPIQ-METHOD/deployment/installers/claude-integration.sh +0 -281
  249. package/#Tools/APPIQ-METHOD/deployment/installers/cursor-integration.sh +0 -257
  250. package/#Tools/APPIQ-METHOD/deployment/installers/terminal-integration.sh +0 -645
  251. package/#Tools/APPIQ-METHOD/deployment/installers/windsurf-integration.sh +0 -350
  252. package/#Tools/APPIQ-METHOD/deployment/package-v2.sh +0 -97
  253. package/#Tools/APPIQ-METHOD/deployment/package.sh +0 -363
  254. package/#Tools/APPIQ-METHOD/deployment/quick-install.sh +0 -57
  255. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-mobile-app-dev/agents/mobile-analytics.txt +0 -1530
  256. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-mobile-app-dev/agents/mobile-architect.txt +0 -322
  257. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-mobile-app-dev/agents/mobile-developer.txt +0 -692
  258. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-mobile-app-dev/agents/mobile-pm.txt +0 -382
  259. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-mobile-app-dev/agents/mobile-qa.txt +0 -665
  260. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-mobile-app-dev/agents/mobile-security.txt +0 -1070
  261. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-mobile-app-dev/agents/mobile-ux-expert.txt +0 -1494
  262. package/#Tools/APPIQ-METHOD/dist/expansion-packs/bmad-mobile-app-dev/teams/mobile-team-cross-platform.txt +0 -15613
  263. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agent-teams/mobile-team-cross-platform.yaml +0 -22
  264. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agent-teams/mobile-team-flutter.yaml +0 -20
  265. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agent-teams/mobile-team-minimal.yaml +0 -13
  266. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agent-teams/mobile-team-react-native.yaml +0 -20
  267. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agents/mobile-analytics.md +0 -1487
  268. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agents/mobile-architect.md +0 -279
  269. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agents/mobile-developer.md +0 -649
  270. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agents/mobile-pm.md +0 -339
  271. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agents/mobile-qa.md +0 -622
  272. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agents/mobile-security.md +0 -1027
  273. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/agents/mobile-ux-expert.md +0 -1451
  274. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/checklists/mobile-development-checklist.md +0 -490
  275. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/config.yaml +0 -54
  276. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/data/bmad-kb.md +0 -292
  277. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/data/flutter-development-guidelines.md +0 -483
  278. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/tasks/existing-app-analysis.md +0 -645
  279. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/tasks/platform-selection.md +0 -489
  280. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/templates/mobile-architecture-tmpl.yaml +0 -437
  281. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/templates/mobile-prd-tmpl.yaml +0 -408
  282. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/workflows/mobile-app-development-init.yaml +0 -555
  283. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/workflows/mobile-brownfield-flutter.yaml +0 -336
  284. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/workflows/mobile-brownfield-react-native.yaml +0 -345
  285. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/workflows/mobile-greenfield-flutter.yaml +0 -281
  286. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/workflows/mobile-greenfield-react-native.yaml +0 -283
  287. package/#Tools/APPIQ-METHOD/expansion-packs/bmad-mobile-app-dev/workflows/mobile-platform-selection.yaml +0 -404
  288. package/#Tools/APPIQ-METHOD/package-bmad-backup.json +0 -78
  289. package/#Tools/APPIQ-METHOD/slash-commands/appiq.md +0 -273
  290. package/#Tools/APPIQ-METHOD/slash-commands/ide-integrations/claude-appiq.md +0 -294
  291. package/#Tools/APPIQ-METHOD/slash-commands/ide-integrations/cursor-appiq.md +0 -516
  292. package/#Tools/APPIQ-METHOD/slash-commands/ide-integrations/universal-appiq.md +0 -448
  293. package/#Tools/APPIQ-METHOD/slash-commands/ide-integrations/windsurf-appiq.md +0 -698
  294. package/#Tools/APPIQ-METHOD/slash-commands/start.md +0 -211
  295. /package/#Tools/APPIQ-METHOD/{deployment/build/bmad-core/core-config.yaml → bmad-core/core-config.yaml.bak} +0 -0
@@ -0,0 +1,2622 @@
1
+ #!/usr/bin/env node
2
+
3
+ /**
4
+ * Appiq Solution Smart Installer
5
+ *
6
+ * Super einfache Installation mit One-Click Workflows
7
+ * Usage: npx appiq-solution install
8
+ *
9
+ * Built with ❤️ based on the amazing Bmad-Method
10
+ * Credits: https://github.com/Viktor-Hermann/APPIQ-METHOD
11
+ */
12
+
13
+ const fs = require('fs');
14
+ const path = require('path');
15
+ const inquirer = require('inquirer');
16
+ const chalk = require('chalk');
17
+
18
+ const MCP_SERVERS = {
19
+ // 🌍 GLOBAL SERVERS
20
+ "sequential-thinking": {
21
+ name: "Sequential Thinking",
22
+ description: "Structured thinking for complex problem solving",
23
+ command: "npx",
24
+ args: ["-y", "@modelcontextprotocol/server-sequential-thinking"],
25
+ tags: ['all', 'planning', 'architect', 'pm']
26
+ },
27
+ "puppeteer": {
28
+ name: "Puppeteer MCP Server",
29
+ description: "Browser automation and web scraping",
30
+ command: "npx",
31
+ args: ["-y", "puppeteer-mcp-server"],
32
+ tags: ['web', 'qa', 'automation']
33
+ },
34
+ "claude-continuity": {
35
+ name: "Claude Thread Continuity",
36
+ description: "Enhanced thread continuity for Claude",
37
+ command: "python3",
38
+ args: ["~/.mcp-servers/claude-continuity/server.py"],
39
+ tags: ['all', 'ide-enhancement']
40
+ },
41
+
42
+ // 📁 LOCAL SERVERS
43
+ "extended-memory": {
44
+ name: "Extended Memory MCP",
45
+ description: "Enhanced memory capabilities for AI assistants",
46
+ command: "python3",
47
+ args: ["-m", "extended_memory_mcp.server"],
48
+ env: { "LOG_LEVEL": "INFO" },
49
+ tags: ['all', 'ide-enhancement']
50
+ },
51
+ "@21st-dev/magic": {
52
+ name: "21st.dev Magic MCP",
53
+ description: "UI builder for MCP - like v0 but in your IDE",
54
+ command: "npx",
55
+ args: ["-y", "@21st-dev/magic@latest"],
56
+ tags: ['web', 'flutter', 'ui', 'ux-expert', 'flutter-ui-agent']
57
+ },
58
+ "dart": {
59
+ name: "Dart MCP Server",
60
+ description: "Dart SDK integration for Flutter/Dart projects",
61
+ command: "dart",
62
+ args: ["mcp-server", "--force-roots-fallback"],
63
+ tags: ['flutter', 'flutter-ui-agent', 'flutter-cubit-agent', 'flutter-data-agent']
64
+ },
65
+ "firebase": {
66
+ name: "Firebase MCP Server",
67
+ description: "Firebase services - Auth, Firestore, Functions",
68
+ command: "npx",
69
+ args: ["-y", "firebase-tools@latest", "experimental:mcp"],
70
+ tags: ['backend', 'fullstack', 'flutter', 'web', 'dev']
71
+ },
72
+ "supabase": {
73
+ name: "Supabase MCP Server",
74
+ description: "Supabase integration - database, auth, storage",
75
+ command: "npx",
76
+ args: ["-y", "@supabase/mcp-server-supabase@latest", "--read-only"],
77
+ tags: ['backend', 'fullstack', 'flutter', 'web', 'dev']
78
+ },
79
+ "context7": {
80
+ name: "Context7 MCP (Upstash)",
81
+ description: "Up-to-date code documentation for any library",
82
+ command: "npx",
83
+ args: ["-y", "@upstash/context7-mcp"],
84
+ tags: ['all', 'research', 'dev', 'architect']
85
+ },
86
+ "stripe": {
87
+ name: "Stripe MCP Server",
88
+ description: "Stripe payment integration",
89
+ command: "npx",
90
+ args: ["-y", "@stripe/mcp", "--tools=all"],
91
+ tags: ['backend', 'fullstack', 'web', 'payment', 'dev']
92
+ }
93
+ };
94
+
95
+ class AppiqSolutionInstaller {
96
+ constructor() {
97
+ this.projectRoot = process.cwd();
98
+ this.appiqPath = path.join(this.projectRoot, "appiq-solution");
99
+ this.config = {
100
+ version: "1.0.0",
101
+ projectType: null, // 'greenfield' or 'brownfield'
102
+ techStack: {
103
+ platform: null, // 'flutter', 'web', 'fullstack', 'api'
104
+ isFlutter: false,
105
+ hasUI: false,
106
+ database: null,
107
+ libraries: [],
108
+ },
109
+ selectedIDEs: [],
110
+ projectName: null,
111
+ projectIdea: null,
112
+ targetUsers: null,
113
+ projectPlan: null,
114
+ planApproved: false,
115
+
116
+ };
117
+ }
118
+
119
+ async install() {
120
+ console.log(chalk.bold.cyan("🚀 Appiq Solution Smart Installer v1.0.0"));
121
+ console.log(chalk.cyan("============================================"));
122
+ console.log(chalk.dim("Built with ❤️ based on Bmad-Method"));
123
+ console.log(chalk.dim("https://github.com/Viktor-Hermann/APPIQ-METHOD\n"));
124
+
125
+ try {
126
+ // Phase 1: Projekt-Typ Detection
127
+ await this.detectProjectType();
128
+
129
+ // Phase 1.5: Tech Stack Detection (Flutter, Web, etc.)
130
+ await this.detectTechStack();
131
+
132
+ // Phase 2: Projektidee erfassen
133
+ await this.collectProjectIdea();
134
+
135
+ // Phase 3: IDE Selection (MULTISELECT)
136
+ await this.selectIDE();
137
+
138
+
139
+
140
+ // Phase 5: Projektplan erstellen
141
+ await this.createProjectPlan();
142
+
143
+ // Phase 6: Plan-Freigabe
144
+ await this.approvePlan();
145
+
146
+ // Phase 7: Installation
147
+ await this.performInstallation();
148
+
149
+
150
+
151
+ // Phase 9: BMAD Core Configuration Setup
152
+ await this.setupBMADCoreConfig();
153
+
154
+ // Phase 10: Document Templates & Dependencies
155
+ await this.setupDocumentTemplates();
156
+
157
+ // Phase 11: Agent Dependencies System (+ Flutter Agents & MCPs)
158
+ await this.setupAgentDependencies();
159
+
160
+ // Phase 12: BMAD Orchestration (Full Flow)
161
+ await this.setupBMADOrchestration();
162
+
163
+ // Phase 13: One-Click Setup
164
+ await this.setupOneClickWorkflows();
165
+
166
+ // Phase 14: Simple Instructions
167
+ await this.showSimpleInstructions();
168
+ } catch (error) {
169
+ console.error(chalk.red("❌ Installation failed:"), error.message);
170
+ process.exit(1);
171
+ }
172
+ }
173
+
174
+ async detectProjectType() {
175
+ console.log(chalk.yellow("🔍 Projekt-Analyse..."));
176
+
177
+ // Auto-Detection
178
+ const hasPackageJson = fs.existsSync(
179
+ path.join(this.projectRoot, "package.json")
180
+ );
181
+ const hasPubspec = fs.existsSync(
182
+ path.join(this.projectRoot, "pubspec.yaml")
183
+ );
184
+ const hasExistingCode = this.hasExistingSourceCode();
185
+ const hasDocumentation = this.hasExistingDocumentation();
186
+
187
+ let suggestedType = "greenfield";
188
+ let reason = "Neues Projekt erkannt";
189
+
190
+ if (hasExistingCode || hasDocumentation) {
191
+ suggestedType = "brownfield";
192
+ reason = "Existierenden Code/Dokumentation gefunden";
193
+ }
194
+
195
+ console.log(chalk.gray(`💡 Analyse: ${reason}`));
196
+ console.log(
197
+ chalk.gray(
198
+ `📊 Empfehlung: ${
199
+ suggestedType === "greenfield"
200
+ ? "Greenfield (Neues Projekt)"
201
+ : "Brownfield (Bestehendes Projekt)"
202
+ }`
203
+ )
204
+ );
205
+
206
+ // User Confirmation
207
+ const { projectType } = await inquirer.prompt([
208
+ {
209
+ type: "list",
210
+ name: "projectType",
211
+ message: "🎯 Welcher Projekt-Typ ist das?",
212
+ choices: [
213
+ {
214
+ name: `✨ Greenfield - Neues Projekt (Empfohlen: ${
215
+ suggestedType === "greenfield" ? "✅" : "❌"
216
+ })`,
217
+ value: "greenfield",
218
+ short: "Greenfield",
219
+ },
220
+ {
221
+ name: `🔧 Brownfield - Bestehendes Projekt (Empfohlen: ${
222
+ suggestedType === "brownfield" ? "✅" : "❌"
223
+ })`,
224
+ value: "brownfield",
225
+ short: "Brownfield",
226
+ },
227
+ ],
228
+ default: suggestedType,
229
+ },
230
+ ]);
231
+
232
+ this.config.projectType = projectType;
233
+ console.log(
234
+ chalk.green(
235
+ `✅ Projekt-Typ: ${
236
+ projectType === "greenfield"
237
+ ? "Greenfield (Neu)"
238
+ : "Brownfield (Bestehend)"
239
+ }\n`
240
+ )
241
+ );
242
+ }
243
+
244
+ async selectIDE() {
245
+ console.log(chalk.yellow("🛠️ IDE Auswahl"));
246
+ console.log(
247
+ chalk.bold.yellow.bgRed(
248
+ " ⚠️ MULTISELECT: Verwenden Sie SPACEBAR zum Auswählen mehrerer IDEs! "
249
+ )
250
+ );
251
+ console.log(chalk.gray("Wählen Sie ALLE IDEs aus, die Sie nutzen:\n"));
252
+
253
+ const { ides } = await inquirer.prompt([
254
+ {
255
+ type: "checkbox",
256
+ name: "ides",
257
+ message:
258
+ "🎯 Welche IDEs nutzen Sie? (SPACEBAR = auswählen, ENTER = bestätigen)",
259
+ choices: [
260
+ { name: "🔵 Cursor", value: "cursor" },
261
+ { name: "🟣 Claude Code CLI", value: "claude-code" },
262
+ { name: "🟢 Windsurf", value: "windsurf" },
263
+ { name: "🔶 VS Code + Cline", value: "cline" },
264
+ { name: "🟠 Trae", value: "trae" },
265
+ { name: "🔴 Roo Code", value: "roo" },
266
+ { name: "🟪 Gemini CLI", value: "gemini" },
267
+ { name: "⚫ GitHub Copilot", value: "github-copilot" },
268
+ ],
269
+ validate: (input) => {
270
+ if (input.length === 0) {
271
+ return "Bitte wählen Sie mindestens eine IDE aus!";
272
+ }
273
+ return true;
274
+ },
275
+ },
276
+ ]);
277
+
278
+ this.config.selectedIDEs = ides;
279
+ const ideNames = ides.map((ide) => this.getIDEName(ide)).join(", ");
280
+ console.log(chalk.green(`✅ IDEs: ${ideNames}\n`));
281
+ }
282
+
283
+
284
+
285
+ async detectTechStack() {
286
+ console.log(chalk.yellow("🔍 Tech Stack Detection"));
287
+ console.log(chalk.gray("Analysiere Projekt-Umgebung und Tech Stack...\n"));
288
+
289
+ // Check for Flutter
290
+ const isFlutter = fs.existsSync(
291
+ path.join(this.projectRoot, "pubspec.yaml")
292
+ );
293
+
294
+ // Check for existing web frameworks
295
+ const hasPackageJson = fs.existsSync(
296
+ path.join(this.projectRoot, "package.json")
297
+ );
298
+ let webFramework = null;
299
+
300
+ if (hasPackageJson) {
301
+ try {
302
+ const packageJson = JSON.parse(
303
+ fs.readFileSync(path.join(this.projectRoot, "package.json"), "utf8")
304
+ );
305
+ if (packageJson.dependencies) {
306
+ const deps = Object.keys(packageJson.dependencies);
307
+ if (deps.includes("next")) webFramework = "next.js";
308
+ else if (deps.includes("react")) webFramework = "react";
309
+ else if (deps.includes("vue")) webFramework = "vue";
310
+ else if (deps.includes("@nuxt/core")) webFramework = "nuxt.js";
311
+ else if (deps.includes("@angular/core")) webFramework = "angular";
312
+ }
313
+ } catch (e) {
314
+ // ignore package.json parsing errors
315
+ }
316
+ }
317
+
318
+ // Auto-detect or ask user
319
+ if (isFlutter) {
320
+ console.log(chalk.green("✅ Flutter Projekt erkannt!"));
321
+ this.config.techStack.platform = "flutter";
322
+ this.config.techStack.isFlutter = true;
323
+ this.config.techStack.hasUI = true;
324
+ console.log(chalk.cyan(" → Dart MCP Server wird konfiguriert"));
325
+ console.log(
326
+ chalk.cyan(" → Flutter Clean Architecture Agents werden geladen\n")
327
+ );
328
+ } else if (webFramework) {
329
+ console.log(chalk.green(`✅ ${webFramework} Projekt erkannt!`));
330
+ this.config.techStack.platform = "web";
331
+ this.config.techStack.hasUI = true;
332
+ console.log(
333
+ chalk.cyan(" → shadcn/ui + v0.dev Integration wird konfiguriert\n")
334
+ );
335
+ } else {
336
+ // Ask user for platform
337
+ const { platform } = await inquirer.prompt([
338
+ {
339
+ type: "list",
340
+ name: "platform",
341
+ message: "🎯 Welchen Tech Stack verwenden Sie?",
342
+ choices: [
343
+ { name: "📱 Flutter Mobile App", value: "flutter" },
344
+ { name: "🌐 Web App (React/Next.js/Vue)", value: "web" },
345
+ { name: "🚀 Fullstack (Frontend + Backend)", value: "fullstack" },
346
+ { name: "⚡ API/Backend Only", value: "api" },
347
+ { name: "🤷 Noch nicht sicher", value: "unknown" },
348
+ ],
349
+ },
350
+ ]);
351
+
352
+ this.config.techStack.platform = platform;
353
+ this.config.techStack.isFlutter = platform === "flutter";
354
+ this.config.techStack.hasUI = ["flutter", "web", "fullstack"].includes(
355
+ platform
356
+ );
357
+
358
+ if (platform === "flutter") {
359
+ console.log(chalk.cyan(" → Dart MCP Server wird konfiguriert"));
360
+ console.log(
361
+ chalk.cyan(" → Flutter Clean Architecture Agents werden geladen")
362
+ );
363
+ } else if (platform === "web" || platform === "fullstack") {
364
+ console.log(
365
+ chalk.cyan(" → shadcn/ui + v0.dev Integration wird konfiguriert")
366
+ );
367
+ }
368
+ console.log("");
369
+ }
370
+ }
371
+
372
+ async collectProjectIdea() {
373
+ console.log(chalk.yellow("💡 Projektidee erfassen"));
374
+ console.log(chalk.gray("Beschreiben Sie Ihr Projekt-Vorhaben:\n"));
375
+
376
+ const { projectIdea, projectName, targetUsers } = await inquirer.prompt([
377
+ {
378
+ type: "input",
379
+ name: "projectName",
380
+ message: "🏷️ Wie soll Ihr Projekt heißen?",
381
+ validate: (input) =>
382
+ input.length > 0 ? true : "Bitte geben Sie einen Projektnamen ein!",
383
+ },
384
+ {
385
+ type: "editor",
386
+ name: "projectIdea",
387
+ message: "💡 Beschreiben Sie Ihre Projektidee (detailliert):",
388
+ validate: (input) =>
389
+ input.length > 10
390
+ ? true
391
+ : "Bitte beschreiben Sie Ihr Projekt ausführlicher!",
392
+ },
393
+ {
394
+ type: "input",
395
+ name: "targetUsers",
396
+ message: "👥 Wer sind Ihre Zielgruppen/User?",
397
+ validate: (input) =>
398
+ input.length > 0 ? true : "Bitte beschreiben Sie Ihre Zielgruppe!",
399
+ },
400
+ ]);
401
+
402
+ this.config.projectName = projectName;
403
+ this.config.projectIdea = projectIdea;
404
+ this.config.targetUsers = targetUsers;
405
+
406
+ console.log(chalk.green(`✅ Projektidee erfasst: "${projectName}"\n`));
407
+ }
408
+
409
+ async createProjectPlan() {
410
+ console.log(chalk.yellow("📋 Projektplan wird erstellt..."));
411
+ console.log(chalk.gray("Basierend auf Ihrer Idee und dem Projekt-Typ\n"));
412
+
413
+ // Hier würde normalerweise die team-fullstack.yaml verwendet
414
+ const plan = this.generateProjectPlan();
415
+ this.config.projectPlan = plan;
416
+
417
+ console.log(chalk.cyan("📋 Ihr Projektplan:"));
418
+ console.log(chalk.white("─".repeat(50)));
419
+ console.log(plan);
420
+ console.log(chalk.white("─".repeat(50) + "\n"));
421
+ }
422
+
423
+ async approvePlan() {
424
+ const { approved, changes } = await inquirer.prompt([
425
+ {
426
+ type: "confirm",
427
+ name: "approved",
428
+ message: "✅ Sind Sie mit diesem Plan zufrieden?",
429
+ default: true,
430
+ },
431
+ {
432
+ type: "input",
433
+ name: "changes",
434
+ message:
435
+ "📝 Welche Änderungen möchten Sie? (oder ENTER für keine Änderungen)",
436
+ when: (answers) => !answers.approved,
437
+ },
438
+ ]);
439
+
440
+ if (!approved && changes) {
441
+ console.log(chalk.yellow("📝 Plan wird angepasst..."));
442
+ this.config.planChanges = changes;
443
+ // Hier würde Plan angepasst werden
444
+ console.log(chalk.green("✅ Plan wurde angepasst!\n"));
445
+ } else {
446
+ console.log(
447
+ chalk.green("✅ Plan freigegeben - Entwicklung kann starten!\n")
448
+ );
449
+ }
450
+
451
+ this.config.planApproved = true;
452
+ }
453
+
454
+ generateProjectPlan() {
455
+ const { projectType, projectName, projectIdea, targetUsers } = this.config;
456
+
457
+ return `🎯 PROJEKTPLAN: ${projectName}
458
+
459
+ 📊 PROJEKT-TYP: ${
460
+ projectType === "greenfield"
461
+ ? "Greenfield (Neues Projekt)"
462
+ : "Brownfield (Bestehendes Projekt)"
463
+ }
464
+ 👥 ZIELGRUPPE: ${targetUsers}
465
+
466
+ 💡 PROJEKTIDEE:
467
+ ${projectIdea}
468
+
469
+ 🚀 ENTWICKLUNGS-PIPELINE:
470
+ ${
471
+ projectType === "greenfield"
472
+ ? `
473
+ 1. 📋 PO (Product Owner) → PRD erstellen
474
+ 2. 🏗️ Architect → System-Architektur designen
475
+ 3. 🎨 UX Expert → UI/UX Design
476
+ 4. 📝 Story Master → User Stories aufbrechen
477
+ 5. 💻 Developer → Features implementieren
478
+ 6. ✅ QA Expert → Testing & Validierung
479
+ 7. 📊 SM (Scrum Master) → Sprint-Koordination
480
+ `
481
+ : `
482
+ 1. 📋 PO → Bestehende Dokumentation analysieren
483
+ 2. 🏗️ Architect → Architektur-Review
484
+ 3. 📝 Story Master → Neue Features planen
485
+ 4. 💻 Developer → Features in bestehende Basis integrieren
486
+ 5. ✅ QA Expert → Regression Testing
487
+ 6. 📊 SM → Change Management
488
+ `
489
+ }
490
+
491
+ 🎮 ONE-CLICK BEFEHLE:
492
+ - /start → Gesamten Workflow starten
493
+ - /plan → Detailplanung
494
+ - /develop → Entwicklung beginnen
495
+ - /review → Code Review
496
+ - /deploy → Deployment vorbereiten`;
497
+ }
498
+
499
+ async setupBMADCoreConfig() {
500
+ console.log(chalk.yellow("⚙️ BMAD Core Configuration einrichten..."));
501
+
502
+ // Create .bmad-core directory
503
+ const bmadCoreDir = path.join(this.appiqPath, ".bmad-core");
504
+ if (!fs.existsSync(bmadCoreDir)) {
505
+ fs.mkdirSync(bmadCoreDir, { recursive: true });
506
+ }
507
+
508
+ // Create core-config.yaml
509
+ const coreConfigPath = path.join(bmadCoreDir, "core-config.yaml");
510
+ fs.writeFileSync(coreConfigPath, this.generateCoreConfig());
511
+
512
+ // Create technical-preferences.md
513
+ const techPrefsPath = path.join(bmadCoreDir, "data");
514
+ if (!fs.existsSync(techPrefsPath)) {
515
+ fs.mkdirSync(techPrefsPath, { recursive: true });
516
+ }
517
+ fs.writeFileSync(
518
+ path.join(techPrefsPath, "technical-preferences.md"),
519
+ this.generateTechnicalPreferences()
520
+ );
521
+
522
+ console.log(chalk.green("✅ BMAD Core Configuration bereit!\n"));
523
+ }
524
+
525
+ async setupDocumentTemplates() {
526
+ console.log(chalk.yellow("📄 Document Templates & Struktur einrichten..."));
527
+
528
+ // Create docs directory structure
529
+ const docsDir = path.join(this.projectRoot, "docs");
530
+ const archDir = path.join(docsDir, "architecture");
531
+ const storiesDir = path.join(docsDir, "stories");
532
+
533
+ [docsDir, archDir, storiesDir].forEach((dir) => {
534
+ if (!fs.existsSync(dir)) {
535
+ fs.mkdirSync(dir, { recursive: true });
536
+ }
537
+ });
538
+
539
+ // Create templates
540
+ const templatesDir = path.join(this.appiqPath, "templates");
541
+ if (!fs.existsSync(templatesDir)) {
542
+ fs.mkdirSync(templatesDir, { recursive: true });
543
+ }
544
+
545
+ // PRD Template
546
+ fs.writeFileSync(
547
+ path.join(templatesDir, "prd-template.md"),
548
+ this.generatePRDTemplate()
549
+ );
550
+
551
+ // Architecture Template
552
+ fs.writeFileSync(
553
+ path.join(templatesDir, "architecture-template.md"),
554
+ this.generateArchitectureTemplate()
555
+ );
556
+
557
+ // Story Template
558
+ fs.writeFileSync(
559
+ path.join(templatesDir, "story-template.md"),
560
+ this.generateStoryTemplate()
561
+ );
562
+
563
+ // Create initial PRD if planning is complete
564
+ if (this.config.planApproved) {
565
+ fs.writeFileSync(path.join(docsDir, "prd.md"), this.generateInitialPRD());
566
+ }
567
+
568
+ console.log(chalk.green("✅ Document Templates erstellt!\n"));
569
+ }
570
+
571
+ async setupAgentDependencies() {
572
+ console.log(chalk.yellow("🔗 Agent Dependencies System einrichten..."));
573
+
574
+ const agentsDir = path.join(this.appiqPath, "agents");
575
+ const tasksDir = path.join(this.appiqPath, "tasks");
576
+ const dataDir = path.join(this.appiqPath, "data");
577
+
578
+ // Create directories
579
+ [tasksDir, dataDir].forEach((dir) => {
580
+ if (!fs.existsSync(dir)) {
581
+ fs.mkdirSync(dir, { recursive: true });
582
+ }
583
+ });
584
+
585
+ // Create BMAD Knowledge Base
586
+ fs.writeFileSync(
587
+ path.join(dataDir, "bmad-kb.md"),
588
+ this.generateBMADKnowledgeBase()
589
+ );
590
+
591
+ // Create essential tasks
592
+ fs.writeFileSync(
593
+ path.join(tasksDir, "create-doc.md"),
594
+ this.generateCreateDocTask()
595
+ );
596
+ fs.writeFileSync(
597
+ path.join(tasksDir, "shard-doc.md"),
598
+ this.generateShardDocTask()
599
+ );
600
+ fs.writeFileSync(
601
+ path.join(tasksDir, "validate-story.md"),
602
+ this.generateValidateStoryTask()
603
+ );
604
+
605
+ // Add Flutter-specific agents if Flutter project
606
+ if (this.config.techStack.isFlutter) {
607
+ await this.addFlutterAgents();
608
+ }
609
+
610
+ // Update agents with proper dependencies
611
+ await this.updateAgentsWithDependencies();
612
+
613
+ console.log(chalk.green("✅ Agent Dependencies System bereit!\n"));
614
+ }
615
+
616
+ async setupBMADOrchestration() {
617
+ console.log(chalk.yellow("🎭 BMAD Full Orchestration einrichten..."));
618
+
619
+ // Create orchestration config based on BMAD Flow
620
+ const orchestrationConfig = {
621
+ planningPhase: {
622
+ agents: ["analyst", "pm", "ux-expert", "architect", "po"],
623
+ workflow:
624
+ this.config.projectType === "greenfield"
625
+ ? "greenfield-planning"
626
+ : "brownfield-planning",
627
+ },
628
+ developmentPhase: {
629
+ agents: ["sm", "po", "dev", "qa"],
630
+ workflow: "core-development-cycle",
631
+ },
632
+ transitions: {
633
+ planningToIDE: "document-sharding",
634
+ criticalCommitPoints: ["before-next-story", "after-qa-approval"],
635
+ },
636
+ };
637
+
638
+ // Generate BMAD Orchestration
639
+ const orchestrationPath = path.join(
640
+ this.appiqPath,
641
+ "bmad-orchestration.yaml"
642
+ );
643
+ fs.writeFileSync(
644
+ orchestrationPath,
645
+ this.generateBMADOrchestration(orchestrationConfig)
646
+ );
647
+
648
+ // Create workflow guides
649
+ const workflowsDir = path.join(this.appiqPath, "workflows");
650
+ if (!fs.existsSync(workflowsDir)) {
651
+ fs.mkdirSync(workflowsDir, { recursive: true });
652
+ }
653
+
654
+ fs.writeFileSync(
655
+ path.join(workflowsDir, "planning-workflow.md"),
656
+ this.generatePlanningWorkflow()
657
+ );
658
+ fs.writeFileSync(
659
+ path.join(workflowsDir, "development-cycle.md"),
660
+ this.generateDevelopmentCycle()
661
+ );
662
+ fs.writeFileSync(
663
+ path.join(workflowsDir, "document-sharding.md"),
664
+ this.generateDocumentSharding()
665
+ );
666
+
667
+ console.log(chalk.green("✅ BMAD Full Orchestration bereit!\n"));
668
+ }
669
+
670
+ generateCoreConfig() {
671
+ return `# BMAD Core Configuration
672
+ # Built with ❤️ based on Bmad-Method
673
+
674
+ project:
675
+ name: ${this.config.projectName || "Unbenanntes Projekt"}
676
+ type: ${this.config.projectType}
677
+ created: ${new Date().toISOString()}
678
+
679
+ # Files that dev agent should ALWAYS load into context
680
+ devLoadAlwaysFiles:
681
+ - docs/architecture/coding-standards.md
682
+ - docs/architecture/tech-stack.md
683
+ - docs/architecture/project-structure.md
684
+
685
+ # Document paths configuration
686
+ documentPaths:
687
+ prd: "docs/prd.md"
688
+ architecture: "docs/architecture.md"
689
+ stories: "docs/stories/"
690
+ templates: "appiq-solution/templates/"
691
+
692
+ # Agent dependencies configuration
693
+ dependencies:
694
+ templates:
695
+ - prd-template.md
696
+ - architecture-template.md
697
+ - story-template.md
698
+ tasks:
699
+ - create-doc.md
700
+ - shard-doc.md
701
+ - validate-story.md
702
+ data:
703
+ - bmad-kb.md
704
+ - technical-preferences.md
705
+ `;
706
+ }
707
+
708
+ generateTechnicalPreferences() {
709
+ return `# Technical Preferences
710
+
711
+ *Diese Datei hilft PM und Architect dabei, Ihre bevorzugten Design-Patterns und Technologien zu berücksichtigen.*
712
+
713
+ ## Projekt: ${this.config.projectName || "Unbenanntes Projekt"}
714
+ **Platform:** ${this.config.techStack.platform || "nicht definiert"}
715
+
716
+ ### Bevorzugte Technologien
717
+
718
+ ${
719
+ this.config.techStack.isFlutter
720
+ ? `
721
+ **📱 Flutter Mobile Development:**
722
+ - **Framework:** Flutter 3.35+ (beta), Dart 3.9+
723
+ - **Architecture:** Clean Architecture with Feature-based structure
724
+ - **State Management:** Cubit/BLoC pattern (preferred), Riverpod (alternative)
725
+ - **Dependency Injection:** GetIt + Injectable
726
+ - **Code Generation:** Freezed, Build Runner
727
+ - **Backend Integration:** Firebase, Supabase, REST APIs, GraphQL
728
+ - **Testing:** Unit Testing, Widget Testing, Integration Testing, Golden Tests
729
+
730
+ **🔌 Flutter MCP Integration:**
731
+ - **Dart MCP Server:** Automatisch konfiguriert für AI-Assistenten
732
+ - **Hot Reload:** Via MCP für Live-Development
733
+ - **Package Management:** pub.dev Integration via MCP
734
+ - **Error Analysis:** Automatische Fehlererkennung via MCP
735
+
736
+ **📦 Recommended Packages:**
737
+ - **UI:** Material 3, Cupertino (iOS-style)
738
+ - **Navigation:** go_router
739
+ - **HTTP:** dio
740
+ - **Local Storage:** shared_preferences, hive
741
+ - **Image:** cached_network_image
742
+ `
743
+ : ""
744
+ }
745
+
746
+ ${
747
+ this.config.techStack.platform === "web" ||
748
+ this.config.techStack.platform === "fullstack"
749
+ ? `
750
+ **🌐 Web Development:**
751
+ - **Framework:** React/Next.js, Vue/Nuxt, Angular
752
+ - **UI Library:** shadcn/ui (preferred), v0.dev components, Material-UI, Chakra UI
753
+ - **Styling:** Tailwind CSS, CSS-in-JS, SCSS
754
+ - **AI Design:** v0.dev für Rapid Prototyping
755
+
756
+ **🎨 shadcn/ui + v0.dev Integration:**
757
+ - **Design System:** shadcn/ui als Basis-Komponenten
758
+ - **AI-Generated Components:** v0.dev für schnelle UI-Erstellung
759
+ - **Customization:** Tailwind CSS für individuelle Anpassungen
760
+ - **Accessibility:** Radix-UI Primitives als Basis
761
+ `
762
+ : ""
763
+ }
764
+
765
+ ${
766
+ this.config.projectType === "greenfield" && !this.config.techStack.isFlutter
767
+ ? `
768
+ **Backend:**
769
+ - Runtime: Node.js, Python, Go
770
+ - Framework: Express, FastAPI, Gin
771
+ - Database: PostgreSQL, MongoDB, Redis
772
+
773
+ **DevOps:**
774
+ - Deployment: Vercel, Railway, AWS
775
+ - CI/CD: GitHub Actions, GitLab CI
776
+ - Monitoring: Sentry, LogRocket
777
+ `
778
+ : ""
779
+ }
780
+
781
+ ${
782
+ this.config.projectType === "brownfield"
783
+ ? `
784
+ **Bestehende Technologien erweitern:**
785
+ - Kompatibilität mit bestehender Code-Basis beachten
786
+ - Minimale neue Dependencies
787
+ - Schrittweise Migration wenn nötig
788
+ `
789
+ : ""
790
+ }
791
+
792
+ ### Design Patterns
793
+ ${
794
+ this.config.techStack.isFlutter
795
+ ? `
796
+ - **Clean Architecture** (Presentation → Domain → Data)
797
+ - **Feature-based Structure** (/features/auth, /features/dashboard)
798
+ - **Repository Pattern** für Datenaccess
799
+ - **Cubit Pattern** für State Management
800
+ - **SOLID Principles** anwenden
801
+ `
802
+ : `
803
+ - **Architektur:** Clean Architecture, Hexagonal, MVC
804
+ - **Code Style:** DRY, SOLID Principles, KISS
805
+ ${
806
+ this.config.techStack.hasUI
807
+ ? "- **Design System:** shadcn/ui für konsistente UI"
808
+ : ""
809
+ }
810
+ `
811
+ }
812
+
813
+ ### Testing & Quality
814
+ ${
815
+ this.config.techStack.isFlutter
816
+ ? `
817
+ - **Dart Analysis:** Very strict linting rules
818
+ - **Flutter Lints:** Official Flutter linting package
819
+ - **Testing:** Minimum 80% code coverage
820
+ - **Golden Tests:** UI consistency tests
821
+ - **Integration Tests:** End-to-end testing
822
+ `
823
+ : `
824
+ - **Testing:** TDD/BDD, Unit + Integration Tests
825
+ - **Documentation:** README-driven, Inline Comments
826
+ - **Code Quality:** ESLint + Prettier (wenn applicable)
827
+ ${
828
+ this.config.techStack.hasUI
829
+ ? "- **Component Testing:** Storybook für Component Documentation"
830
+ : ""
831
+ }
832
+ `
833
+ }
834
+
835
+ ### AI-Integration & MCP
836
+ ${
837
+ this.config.techStack.isFlutter
838
+ ? `
839
+ - **Dart MCP Server:** Für direkten AI-Zugriff auf Flutter Tools
840
+ - **Flutter DevTools:** MCP-basierte AI-Assistenz
841
+ - **Package Discovery:** AI-gestützte pub.dev Suche
842
+ - **Code Analysis:** Automatische Fehlererkennung und -behebung
843
+ `
844
+ : ""
845
+ }
846
+ ${
847
+ this.config.techStack.hasUI && !this.config.techStack.isFlutter
848
+ ? `
849
+ - **v0.dev Integration:** AI-generierte UI-Komponenten
850
+ - **shadcn/ui Library:** KI-optimierte Component Library
851
+ - **Design Tokens:** Konsistente AI-generierte Designs
852
+ `
853
+ : ""
854
+ }
855
+
856
+ ### Coding Standards
857
+ - **Naming:** ${
858
+ this.config.techStack.isFlutter
859
+ ? "lowerCamelCase für Variablen, PascalCase für Classes"
860
+ : "camelCase für Variablen, PascalCase für Components"
861
+ }
862
+ - **Files:** ${
863
+ this.config.techStack.isFlutter
864
+ ? "snake_case für Dart Dateien"
865
+ : "kebab-case für Dateien, PascalCase für Components"
866
+ }
867
+ - **Functions:** Kleine, fokussierte Funktionen (<50 Zeilen)
868
+ - **Comments:** Erkläre WARUM, nicht WAS
869
+
870
+ ### Präferenzen
871
+ - **Performance:** Optimierung vor Abstraktion
872
+ - **Security:** Security-by-Design
873
+ - **Accessibility:** ${
874
+ this.config.techStack.isFlutter
875
+ ? "Flutter Accessibility Widget support"
876
+ : "WCAG 2.1 AA Standard"
877
+ }
878
+ - **Mobile:** Mobile-First Approach
879
+
880
+ ---
881
+ *Platform: ${this.config.techStack.platform}*
882
+ *MCP Configured: ${
883
+ this.config.techStack.isFlutter ? "Dart MCP ✅" : "Standard"
884
+ }*
885
+ *Aktualisiert: ${new Date().toLocaleDateString("de-DE")}*
886
+ `;
887
+ }
888
+
889
+ generatePRDTemplate() {
890
+ return `# Product Requirements Document (PRD)
891
+
892
+ ## Projekt: [PROJECT_NAME]
893
+
894
+ ### 1. Problem Statement
895
+ *Welches Problem lösen wir?*
896
+
897
+ ### 2. Solution Overview
898
+ *Wie lösen wir das Problem?*
899
+
900
+ ### 3. Target Users
901
+ *Wer sind unsere Zielgruppen?*
902
+
903
+ ### 4. Functional Requirements (FRs)
904
+ *Was muss das System können?*
905
+
906
+ #### 4.1 Core Features
907
+ - [ ] Feature 1
908
+ - [ ] Feature 2
909
+
910
+ #### 4.2 Advanced Features
911
+ - [ ] Advanced Feature 1
912
+ - [ ] Advanced Feature 2
913
+
914
+ ### 5. Non-Functional Requirements (NFRs)
915
+ *Wie gut muss das System funktionieren?*
916
+
917
+ #### 5.1 Performance
918
+ - Response Time: < 200ms
919
+ - Throughput: [SPECIFY]
920
+
921
+ #### 5.2 Security
922
+ - Authentication: [METHOD]
923
+ - Authorization: [RBAC/ABAC]
924
+
925
+ #### 5.3 Scalability
926
+ - Users: [NUMBER]
927
+ - Data: [VOLUME]
928
+
929
+ ### 6. User Stories & Epics
930
+
931
+ #### Epic 1: [EPIC_NAME]
932
+ - **Story 1.1:** Als [USER] möchte ich [ACTION] um [BENEFIT]
933
+ - **Story 1.2:** Als [USER] möchte ich [ACTION] um [BENEFIT]
934
+
935
+ #### Epic 2: [EPIC_NAME]
936
+ - **Story 2.1:** Als [USER] möchte ich [ACTION] um [BENEFIT]
937
+ - **Story 2.2:** Als [USER] möchte ich [ACTION] um [BENEFIT]
938
+
939
+ ### 7. Success Metrics
940
+ *Wie messen wir Erfolg?*
941
+
942
+ - Metric 1: [DEFINITION]
943
+ - Metric 2: [DEFINITION]
944
+
945
+ ---
946
+ *Erstellt mit Appiq Solution - Built with ❤️ based on Bmad-Method*
947
+ `;
948
+ }
949
+
950
+ generateArchitectureTemplate() {
951
+ return `# System Architecture
952
+
953
+ ## Projekt: [PROJECT_NAME]
954
+
955
+ ### 1. Architecture Overview
956
+ *High-level Systemübersicht*
957
+
958
+ ### 2. Technology Stack
959
+
960
+ #### Frontend
961
+ - Framework: [FRAMEWORK]
962
+ - State Management: [STATE_MANAGEMENT]
963
+ - Styling: [STYLING_SOLUTION]
964
+
965
+ #### Backend
966
+ - Runtime: [RUNTIME]
967
+ - Framework: [FRAMEWORK]
968
+ - Database: [DATABASE]
969
+
970
+ #### Infrastructure
971
+ - Hosting: [HOSTING_PLATFORM]
972
+ - CI/CD: [CI_CD_SOLUTION]
973
+
974
+ ### 3. System Components
975
+
976
+ #### 3.1 Frontend Components
977
+ - Component Library
978
+ - State Management
979
+ - Routing
980
+ - API Layer
981
+
982
+ #### 3.2 Backend Services
983
+ - API Layer
984
+ - Business Logic
985
+ - Data Access Layer
986
+ - External Integrations
987
+
988
+ ### 4. Data Models
989
+
990
+ #### User Model
991
+ \`\`\`
992
+ {
993
+ id: string
994
+ email: string
995
+ name: string
996
+ createdAt: Date
997
+ }
998
+ \`\`\`
999
+
1000
+ ### 5. API Design
1001
+
1002
+ #### Authentication
1003
+ - POST /api/auth/login
1004
+ - POST /api/auth/register
1005
+ - POST /api/auth/logout
1006
+
1007
+ #### Core Resources
1008
+ - GET /api/[resource]
1009
+ - POST /api/[resource]
1010
+ - PUT /api/[resource]/:id
1011
+ - DELETE /api/[resource]/:id
1012
+
1013
+ ### 6. Security Considerations
1014
+ - Authentication Strategy
1015
+ - Authorization Model
1016
+ - Data Validation
1017
+ - Rate Limiting
1018
+
1019
+ ### 7. Performance Considerations
1020
+ - Caching Strategy
1021
+ - Database Optimization
1022
+ - CDN Usage
1023
+ - Lazy Loading
1024
+
1025
+ ### 8. Deployment Architecture
1026
+ - Development Environment
1027
+ - Staging Environment
1028
+ - Production Environment
1029
+
1030
+ ---
1031
+ *Erstellt mit Appiq Solution - Built with ❤️ based on Bmad-Method*
1032
+ `;
1033
+ }
1034
+
1035
+ generateStoryTemplate() {
1036
+ return `# User Story: [STORY_TITLE]
1037
+
1038
+ ## Story Details
1039
+ **Als** [USER_TYPE]
1040
+ **möchte ich** [ACTION]
1041
+ **um** [BENEFIT]
1042
+
1043
+ ## Acceptance Criteria
1044
+ - [ ] Criterion 1
1045
+ - [ ] Criterion 2
1046
+ - [ ] Criterion 3
1047
+
1048
+ ## Technical Tasks
1049
+ - [ ] Task 1: [DESCRIPTION]
1050
+ - [ ] Task 2: [DESCRIPTION]
1051
+ - [ ] Task 3: [DESCRIPTION]
1052
+
1053
+ ## Definition of Done
1054
+ - [ ] Code implemented and tested
1055
+ - [ ] Unit tests written and passing
1056
+ - [ ] Integration tests passing
1057
+ - [ ] Code reviewed and approved
1058
+ - [ ] Documentation updated
1059
+ - [ ] Deployed to staging
1060
+ - [ ] User acceptance testing completed
1061
+
1062
+ ## Dependencies
1063
+ - [ ] Dependency 1
1064
+ - [ ] Dependency 2
1065
+
1066
+ ## Estimation
1067
+ **Story Points:** [POINTS]
1068
+ **Estimated Hours:** [HOURS]
1069
+
1070
+ ## Notes
1071
+ *Zusätzliche Notizen und Überlegungen*
1072
+
1073
+ ---
1074
+ **Sprint:** [SPRINT_NUMBER]
1075
+ **Assigned to:** [DEVELOPER]
1076
+ **Status:** [TODO/IN_PROGRESS/REVIEW/DONE]
1077
+
1078
+ ---
1079
+ *Erstellt mit Appiq Solution - Built with ❤️ based on Bmad-Method*
1080
+ `;
1081
+ }
1082
+
1083
+ generateInitialPRD() {
1084
+ const { projectName, projectIdea, targetUsers, projectType } = this.config;
1085
+
1086
+ return `# Product Requirements Document (PRD)
1087
+
1088
+ ## Projekt: ${projectName}
1089
+
1090
+ ### 1. Problem Statement
1091
+ ${projectIdea}
1092
+
1093
+ ### 2. Target Users
1094
+ ${targetUsers}
1095
+
1096
+ ### 3. Project Type
1097
+ ${
1098
+ projectType === "greenfield"
1099
+ ? "✨ Greenfield (Neues Projekt)"
1100
+ : "🔧 Brownfield (Bestehendes Projekt)"
1101
+ }
1102
+
1103
+ ### 4. Functional Requirements (FRs)
1104
+ *Diese Sektion wird durch den PM Agent vervollständigt*
1105
+
1106
+ #### 4.1 Core Features
1107
+ - [ ] Feature wird durch PM definiert
1108
+
1109
+ ### 5. Non-Functional Requirements (NFRs)
1110
+ *Diese Sektion wird durch den Architect Agent vervollständigt*
1111
+
1112
+ ### 6. User Stories & Epics
1113
+ *Diese Sektion wird durch den Story Master Agent vervollständigt*
1114
+
1115
+ ---
1116
+ **Status:** 📋 Planning Phase Complete - Ready for PM Agent
1117
+ **Nächster Schritt:** PM Agent für detaillierte Requirements
1118
+ **Created:** ${new Date().toLocaleDateString("de-DE")}
1119
+
1120
+ ---
1121
+ *Erstellt mit Appiq Solution - Built with ❤️ based on Bmad-Method*
1122
+ `;
1123
+ }
1124
+
1125
+ generateBMADKnowledgeBase() {
1126
+ return `# BMAD Knowledge Base
1127
+
1128
+ ## The BMad Planning + Execution Workflow
1129
+
1130
+ ### Planning Workflow (Web UI or Powerful IDE Agents)
1131
+ 1. **Analyst** (Optional): Market Research, Competitor Analysis, Project Brief
1132
+ 2. **PM**: Create PRD from Brief with FRs, NFRs, Epics & Stories
1133
+ 3. **UX Expert** (Optional): Create Front End Spec, Generate UI Prompts
1134
+ 4. **Architect**: Create Architecture from PRD + UX Spec
1135
+ 5. **PO**: Run Master Checklist, validate document alignment
1136
+
1137
+ ### Critical Transition: Web UI → IDE
1138
+ - Copy documents to project (docs/prd.md, docs/architecture.md)
1139
+ - Switch to IDE
1140
+ - **PO**: Shard Documents (CRITICAL STEP)
1141
+ - Begin Development Cycle
1142
+
1143
+ ### Core Development Cycle (IDE)
1144
+ 1. **SM**: Review previous story dev/QA notes
1145
+ 2. **SM**: Draft next story from sharded epic + architecture
1146
+ 3. **PO**: Validate story draft (optional)
1147
+ 4. **User Approval** of story
1148
+ 5. **Dev**: Sequential task execution, implement tasks + tests
1149
+ 6. **Dev**: Run all validations, mark ready for review
1150
+ 7. **User Verification**: Request QA or approve
1151
+ 8. **QA**: Senior dev review + active refactoring (if requested)
1152
+ 9. **IMPORTANT**: Verify all regression tests and linting pass
1153
+ 10. **IMPORTANT**: COMMIT CHANGES BEFORE PROCEEDING
1154
+ 11. Mark story as done, loop back to SM
1155
+
1156
+ ### Key Principles
1157
+ - **Document Sharding**: Critical step after planning phase
1158
+ - **Context Management**: Keep files lean and focused
1159
+ - **Commit Regularly**: Save work frequently, especially after QA
1160
+ - **Agent Selection**: Use appropriate agent for each task
1161
+ - **Dependencies**: Each agent loads only what it needs
1162
+
1163
+ ### Special Agents
1164
+ - **BMad-Master**: Can do any task except story implementation
1165
+ - **BMad-Orchestrator**: Heavy-weight agent for web bundles only
1166
+
1167
+ ### Technical Configuration
1168
+ - **core-config.yaml**: devLoadAlwaysFiles configuration
1169
+ - **technical-preferences.md**: Bias PM/Architect recommendations
1170
+ - **Dependencies**: templates, tasks, data for each agent
1171
+
1172
+ ---
1173
+ *Built with ❤️ based on Bmad-Method*
1174
+ `;
1175
+ }
1176
+
1177
+ generateCreateDocTask() {
1178
+ return `# Create Document Task
1179
+
1180
+ ## Purpose
1181
+ Create structured documents following BMAD templates and standards.
1182
+
1183
+ ## Usage
1184
+ This task helps agents create consistent, well-structured documents.
1185
+
1186
+ ## Process
1187
+ 1. **Identify Document Type**: PRD, Architecture, Story, etc.
1188
+ 2. **Load Template**: Use appropriate template from templates/
1189
+ 3. **Gather Requirements**: Collect all necessary information
1190
+ 4. **Fill Template**: Replace placeholders with actual content
1191
+ 5. **Validate Structure**: Ensure all sections are complete
1192
+ 6. **Save Document**: Store in correct location (docs/)
1193
+
1194
+ ## Templates Available
1195
+ - prd-template.md
1196
+ - architecture-template.md
1197
+ - story-template.md
1198
+
1199
+ ## Best Practices
1200
+ - Follow template structure exactly
1201
+ - Replace ALL placeholders
1202
+ - Include creation date and status
1203
+ - Link to related documents
1204
+ - Use consistent formatting
1205
+
1206
+ ## Output Location
1207
+ - PRD: docs/prd.md
1208
+ - Architecture: docs/architecture.md
1209
+ - Stories: docs/stories/[story-name].md
1210
+
1211
+ ---
1212
+ *Built with ❤️ based on Bmad-Method*
1213
+ `;
1214
+ }
1215
+
1216
+ generateShardDocTask() {
1217
+ return `# Document Sharding Task
1218
+
1219
+ ## Purpose
1220
+ **CRITICAL STEP**: Break down large documents into focused, manageable pieces for agents.
1221
+
1222
+ ## When to Use
1223
+ - After planning phase completion
1224
+ - Before beginning development cycle
1225
+ - When switching from Web UI to IDE
1226
+
1227
+ ## Process
1228
+ 1. **Identify Source Document**: Usually PRD or Architecture
1229
+ 2. **Analyze Structure**: Find natural breaking points
1230
+ 3. **Create Focused Files**: Each file serves one purpose
1231
+ 4. **Maintain References**: Link shards together
1232
+ 5. **Update devLoadAlwaysFiles**: Configure core-config.yaml
1233
+
1234
+ ## Sharding Strategy
1235
+
1236
+ ### PRD Sharding
1237
+ - **Core Requirements**: docs/requirements/core.md
1238
+ - **User Stories**: docs/stories/ (individual files)
1239
+ - **Success Metrics**: docs/metrics.md
1240
+
1241
+ ### Architecture Sharding
1242
+ - **Tech Stack**: docs/architecture/tech-stack.md
1243
+ - **Coding Standards**: docs/architecture/coding-standards.md
1244
+ - **Project Structure**: docs/architecture/project-structure.md
1245
+ - **API Design**: docs/architecture/api-design.md
1246
+ - **Data Models**: docs/architecture/data-models.md
1247
+
1248
+ ## Critical Points
1249
+ - **Lean Files**: Each shard should be focused and minimal
1250
+ - **Dev Context**: Sharded files go into devLoadAlwaysFiles
1251
+ - **Agent Performance**: Smaller context = better performance
1252
+ - **Maintainability**: Easier to update specific aspects
1253
+
1254
+ ## Post-Sharding
1255
+ 1. Update core-config.yaml devLoadAlwaysFiles
1256
+ 2. Verify all shards are accessible
1257
+ 3. Test agent context loading
1258
+ 4. Begin development cycle
1259
+
1260
+ ---
1261
+ *Built with ❤️ based on Bmad-Method*
1262
+ `;
1263
+ }
1264
+
1265
+ generateValidateStoryTask() {
1266
+ return `# Validate Story Task
1267
+
1268
+ ## Purpose
1269
+ Ensure user stories align with PRD, architecture, and project goals.
1270
+
1271
+ ## When to Use
1272
+ - Before story implementation begins
1273
+ - When SM drafts new stories
1274
+ - When stories are modified
1275
+
1276
+ ## Validation Checklist
1277
+
1278
+ ### Story Structure
1279
+ - [ ] Clear user role defined
1280
+ - [ ] Specific action described
1281
+ - [ ] Business value stated
1282
+ - [ ] Acceptance criteria present
1283
+
1284
+ ### Technical Alignment
1285
+ - [ ] Aligns with architecture decisions
1286
+ - [ ] Fits within tech stack constraints
1287
+ - [ ] Dependencies identified
1288
+ - [ ] Implementation feasible
1289
+
1290
+ ### Business Alignment
1291
+ - [ ] Supports PRD objectives
1292
+ - [ ] Addresses user needs
1293
+ - [ ] Measurable outcomes
1294
+ - [ ] Priority justified
1295
+
1296
+ ### Quality Gates
1297
+ - [ ] Testable acceptance criteria
1298
+ - [ ] Definition of done complete
1299
+ - [ ] Effort estimation reasonable
1300
+ - [ ] Risk assessment done
1301
+
1302
+ ## Process
1303
+ 1. **Load References**: PRD, Architecture, related stories
1304
+ 2. **Check Structure**: Verify story template compliance
1305
+ 3. **Validate Alignment**: Against PRD and architecture
1306
+ 4. **Assess Dependencies**: Identify blockers or prerequisites
1307
+ 5. **Review Quality**: Ensure story is ready for development
1308
+ 6. **Provide Feedback**: Clear recommendations for improvements
1309
+
1310
+ ## Common Issues
1311
+ - Vague acceptance criteria
1312
+ - Missing technical dependencies
1313
+ - Misalignment with architecture
1314
+ - Unrealistic scope or effort
1315
+
1316
+ ## Output
1317
+ - **Validation Status**: Pass/Fail with reasons
1318
+ - **Recommendations**: Specific improvements needed
1319
+ - **Dependencies**: List of prerequisites
1320
+ - **Risk Assessment**: Potential implementation challenges
1321
+
1322
+ ---
1323
+ *Built with ❤️ based on Bmad-Method*
1324
+ `;
1325
+ }
1326
+
1327
+ async addFlutterAgents() {
1328
+ console.log(chalk.cyan(" 📱 Adding Flutter-specific agents..."));
1329
+
1330
+ const agentsDir = path.join(this.appiqPath, "agents");
1331
+ const flutterExpansionPath = path.join(
1332
+ __dirname,
1333
+ "..",
1334
+ "expansion-packs",
1335
+ "bmad-flutter-mobile-dev",
1336
+ "agents"
1337
+ );
1338
+
1339
+ // Check if Flutter expansion pack exists
1340
+ if (!fs.existsSync(flutterExpansionPath)) {
1341
+ console.log(
1342
+ chalk.yellow(
1343
+ " ⚠️ Flutter expansion pack not found - creating basic Flutter agents"
1344
+ )
1345
+ );
1346
+ await this.createBasicFlutterAgents();
1347
+ return;
1348
+ }
1349
+
1350
+ // Copy Flutter agents from expansion pack
1351
+ const flutterAgents = [
1352
+ "flutter-ui-agent.md",
1353
+ "flutter-cubit-agent.md",
1354
+ "flutter-data-agent.md",
1355
+ "flutter-domain-agent.md",
1356
+ "shared-components-agent.md",
1357
+ ];
1358
+
1359
+ for (const agentFile of flutterAgents) {
1360
+ const sourcePath = path.join(flutterExpansionPath, agentFile);
1361
+ const targetPath = path.join(agentsDir, agentFile);
1362
+
1363
+ if (fs.existsSync(sourcePath)) {
1364
+ fs.copyFileSync(sourcePath, targetPath);
1365
+ console.log(chalk.green(` ✅ ${agentFile} hinzugefügt`));
1366
+ }
1367
+ }
1368
+
1369
+ // Create Flutter-specific data files
1370
+ const dataDir = path.join(this.appiqPath, "data");
1371
+ const flutterDataPath = path.join(
1372
+ __dirname,
1373
+ "..",
1374
+ "expansion-packs",
1375
+ "bmad-flutter-mobile-dev",
1376
+ "data"
1377
+ );
1378
+
1379
+ if (
1380
+ fs.existsSync(
1381
+ path.join(flutterDataPath, "flutter-development-guidelines.md")
1382
+ )
1383
+ ) {
1384
+ fs.copyFileSync(
1385
+ path.join(flutterDataPath, "flutter-development-guidelines.md"),
1386
+ path.join(dataDir, "flutter-development-guidelines.md")
1387
+ );
1388
+ console.log(
1389
+ chalk.green(" ✅ Flutter development guidelines hinzugefügt")
1390
+ );
1391
+ }
1392
+ }
1393
+
1394
+ async createBasicFlutterAgents() {
1395
+ console.log(chalk.gray(" 🔨 Creating basic Flutter agents..."));
1396
+
1397
+ const agentsDir = path.join(this.appiqPath, "agents");
1398
+
1399
+ // Basic Flutter UI Agent
1400
+ const flutterUIAgent = this.generateBasicFlutterUIAgent();
1401
+ fs.writeFileSync(
1402
+ path.join(agentsDir, "flutter-ui-agent.md"),
1403
+ flutterUIAgent
1404
+ );
1405
+
1406
+ // Basic Flutter State Management Agent
1407
+ const flutterStateAgent = this.generateBasicFlutterStateAgent();
1408
+ fs.writeFileSync(
1409
+ path.join(agentsDir, "flutter-cubit-agent.md"),
1410
+ flutterStateAgent
1411
+ );
1412
+
1413
+ console.log(chalk.green(" ✅ Basic Flutter agents created"));
1414
+ }
1415
+
1416
+ generateBasicFlutterUIAgent() {
1417
+ return `# Flutter UI Agent
1418
+
1419
+ Du bist ein spezialisierter Flutter UI Agent, der sich auf die Erstellung von benutzerfreundlichen und responsive Mobile UI-Komponenten fokussiert.
1420
+
1421
+ ## Rolle & Verantwortung
1422
+
1423
+ - **UI Design & Implementation:** Erstelle schöne, Material 3 konforme Flutter UIs
1424
+ - **Widget Composition:** Verwende effiziente Widget-Hierarchien
1425
+ - **Responsive Design:** Sichere Kompatibilität für verschiedene Bildschirmgrößen
1426
+ - **Accessibility:** Implementiere barrierefreie UI-Komponenten
1427
+
1428
+ ## Expertise
1429
+
1430
+ ### Flutter UI Frameworks
1431
+ - **Material 3:** Modernes Material Design
1432
+ - **Cupertino:** iOS-native Looks
1433
+ - **Custom Widgets:** Individuelle UI-Komponenten
1434
+
1435
+ ### Best Practices
1436
+ - **Widget Keys:** Für Testability und Performance
1437
+ - **Const Constructors:** Memory-Optimierung
1438
+ - **Build Method Optimization:** Verhindere unnecessary rebuilds
1439
+ - **Theme Integration:** Konsistente Design Systems
1440
+
1441
+ ## Tech Stack Integration
1442
+
1443
+ **Platform:** ${this.config.techStack.platform}
1444
+ **MCP:** ${this.config.techStack.isFlutter ? "Dart MCP Server ✅" : "Standard"}
1445
+
1446
+ ### Dart MCP Tools
1447
+ - Hot Reload via MCP
1448
+ - Widget Inspection via AI
1449
+ - pub.dev Package Discovery
1450
+ - Runtime Error Analysis
1451
+
1452
+ ## Workflow Integration
1453
+
1454
+ **Planning Phase:** Arbeite mit UX Expert an UI Specs
1455
+ **Development Phase:** Implementiere UI basierend auf Cubit State
1456
+ **Testing Phase:** Golden Tests für UI Consistency
1457
+
1458
+ ---
1459
+ *Built with ❤️ based on Bmad-Method*
1460
+ *Flutter Clean Architecture + Dart MCP Integration*
1461
+ `;
1462
+ }
1463
+
1464
+ generateBasicFlutterStateAgent() {
1465
+ return `# Flutter Cubit State Management Agent
1466
+
1467
+ Du bist ein spezialisierter Flutter State Management Agent mit Fokus auf Cubit/BLoC Pattern und Clean Architecture.
1468
+
1469
+ ## Rolle & Verantwortung
1470
+
1471
+ - **State Management:** Implementiere Cubit/BLoC Pattern
1472
+ - **Clean Architecture:** Separation of Concerns (Presentation → Domain → Data)
1473
+ - **Dependency Injection:** GetIt + Injectable Setup
1474
+ - **Event Handling:** User Interactions und API Calls
1475
+
1476
+ ## Expertise
1477
+
1478
+ ### State Management
1479
+ - **Cubit:** Simple State Management für UI
1480
+ - **BLoC:** Complex Business Logic mit Events
1481
+ - **Riverpod:** Alternative State Management (if needed)
1482
+
1483
+ ### Architecture Patterns
1484
+ - **Clean Architecture:** Feature-based Structure
1485
+ - **Repository Pattern:** Data Access Layer
1486
+ - **Use Cases:** Business Logic Layer
1487
+ - **Dependency Injection:** Loose Coupling
1488
+
1489
+ ## Tech Stack Integration
1490
+
1491
+ **Platform:** ${this.config.techStack.platform}
1492
+ **MCP:** ${this.config.techStack.isFlutter ? "Dart MCP Server ✅" : "Standard"}
1493
+
1494
+ ### Code Generation
1495
+ - **Freezed:** Immutable Data Classes
1496
+ - **Injectable:** Dependency Injection Setup
1497
+ - **Build Runner:** Code Generation Pipeline
1498
+
1499
+ ## Workflow Integration
1500
+
1501
+ **Planning Phase:** Definiere State Structure mit Domain Agent
1502
+ **Development Phase:** Implementiere Business Logic
1503
+ **Testing Phase:** Unit Tests für Cubits und Use Cases
1504
+
1505
+ ---
1506
+ *Built with ❤️ based on Bmad-Method*
1507
+ *Flutter Clean Architecture + Dart MCP Integration*
1508
+ `;
1509
+ }
1510
+
1511
+ async updateAgentsWithDependencies() {
1512
+ console.log(chalk.gray(" 🔗 Updating agents with BMAD dependencies..."));
1513
+
1514
+ const agentsDir = path.join(this.appiqPath, "agents");
1515
+ const agents = fs.readdirSync(agentsDir);
1516
+
1517
+ for (const agentFile of agents) {
1518
+ const agentPath = path.join(agentsDir, agentFile);
1519
+ let content = fs.readFileSync(agentPath, "utf8");
1520
+
1521
+ // Add BMAD dependencies section to each agent
1522
+ const dependenciesSection = `
1523
+
1524
+ ## 🔗 BMAD Dependencies
1525
+
1526
+ ### Templates
1527
+ - prd-template.md
1528
+ - architecture-template.md
1529
+ - story-template.md
1530
+
1531
+ ### Tasks
1532
+ - create-doc.md
1533
+ - shard-doc.md
1534
+ - validate-story.md
1535
+
1536
+ ### Data
1537
+ - bmad-kb.md
1538
+ - technical-preferences.md
1539
+
1540
+ ### Configuration
1541
+ - core-config.yaml (devLoadAlwaysFiles)
1542
+
1543
+ ## 🎯 BMAD Workflow Integration
1544
+
1545
+ **Planning Phase:** Web UI → IDE Transition → Document Sharding
1546
+ **Development Phase:** SM → PO → Dev → QA → Loop
1547
+ **Critical Points:** Commit before proceeding, verify tests passing
1548
+
1549
+ `;
1550
+
1551
+ // Add MCP integration section
1552
+ const mcpSection = this.generateMCPAgentSection(agentFile);
1553
+
1554
+ // Add dependencies and MCP section before the final line
1555
+ const lines = content.split("\n");
1556
+ const lastLine = lines.pop(); // Remove last line
1557
+ lines.push(dependenciesSection);
1558
+ lines.push(mcpSection);
1559
+ lines.push(lastLine); // Add last line back
1560
+
1561
+ fs.writeFileSync(agentPath, lines.join("\n"));
1562
+ }
1563
+ }
1564
+
1565
+ generateMCPAgentSection(agentFile) {
1566
+ // Bestimme Agent-Typ basierend auf Dateiname
1567
+ const agentName = agentFile.replace('.md', '').toLowerCase();
1568
+
1569
+ // Bestimme welche MCPs für diesen Agent relevant sind
1570
+ const relevantMCPs = Object.keys(MCP_SERVERS).filter(mcpKey => {
1571
+ const server = MCP_SERVERS[mcpKey];
1572
+ return server.tags.includes('all') ||
1573
+ server.tags.some(tag => agentName.includes(tag)) ||
1574
+ (agentName.includes('architect') && server.tags.includes('architect')) ||
1575
+ (agentName.includes('pm') && server.tags.includes('pm')) ||
1576
+ (agentName.includes('qa') && server.tags.includes('qa')) ||
1577
+ (agentName.includes('dev') && server.tags.includes('dev')) ||
1578
+ (agentName.includes('ux') && server.tags.includes('ux-expert')) ||
1579
+ (agentName.includes('flutter') && server.tags.includes('flutter')) ||
1580
+ ((agentName.includes('web') || agentName.includes('ui')) && server.tags.includes('ui'));
1581
+ });
1582
+
1583
+ if (relevantMCPs.length === 0) {
1584
+ return '';
1585
+ }
1586
+
1587
+ let section = `\n## 🔌 MCP Server Integration\n\nDu hast Zugriff auf folgende MCP Server, um deine Fähigkeiten zu erweitern:\n\n`;
1588
+
1589
+ relevantMCPs.forEach(mcpKey => {
1590
+ const server = MCP_SERVERS[mcpKey];
1591
+ section += `- **${server.name}:** ${server.description}\n`;
1592
+ });
1593
+
1594
+ section += `\n**Beispiel-Anwendung:**\n`;
1595
+
1596
+ // Spezifische Beispiele basierend auf Agent-Typ
1597
+ if (agentName.includes('flutter')) {
1598
+ section += `- "Nutze den Dart MCP, um mein Flutter Widget zu analysieren."\n`;
1599
+ section += `- "Verwende den 21st.dev Magic MCP, um eine neue UI-Komponente zu erstellen."\n`;
1600
+ } else if (agentName.includes('architect')) {
1601
+ section += `- "Nutze den Context7 MCP, um die neueste Dokumentation für React Hooks zu finden."\n`;
1602
+ section += `- "Verwende Sequential Thinking MCP für die komplexe Architektur-Planung."\n`;
1603
+ } else if (agentName.includes('qa')) {
1604
+ section += `- "Nutze den Puppeteer MCP, um automatisierte Browser-Tests zu erstellen."\n`;
1605
+ } else if (agentName.includes('dev')) {
1606
+ section += `- "Verwende den Firebase MCP, um Firestore-Daten abzurufen."\n`;
1607
+ section += `- "Nutze den Supabase MCP für Datenbankoperationen."\n`;
1608
+ } else {
1609
+ section += `- "Nutze den Context7 MCP für aktuelle Dokumentation."\n`;
1610
+ section += `- "Verwende Sequential Thinking MCP für komplexe Problemlösungen."\n`;
1611
+ }
1612
+
1613
+ section += `\n**Wichtig:** Die MCPs müssen in deiner IDE konfiguriert sein. Siehe mcp-setup-instructions.md für Details.\n`;
1614
+
1615
+ return section;
1616
+ }
1617
+
1618
+ generateBMADOrchestration(config) {
1619
+ return `# BMAD Full Orchestration
1620
+ # Built with ❤️ based on Bmad-Method
1621
+
1622
+ project:
1623
+ name: ${this.config.projectName}
1624
+ type: ${this.config.projectType}
1625
+ plan_approved: ${this.config.planApproved}
1626
+ created: ${new Date().toISOString()}
1627
+
1628
+ # BMAD Planning Phase (Web UI/Powerful IDE)
1629
+ planning_phase:
1630
+ workflow: ${config.planningPhase.workflow}
1631
+ agents:
1632
+ ${config.planningPhase.agents.map((agent) => ` - ${agent}`).join("\n")}
1633
+
1634
+ flow:
1635
+ 1: "analyst → research & project brief (optional)"
1636
+ 2: "pm → create PRD from brief"
1637
+ 3: "ux-expert → create frontend spec (optional)"
1638
+ 4: "architect → create architecture from PRD + UX"
1639
+ 5: "po → run master checklist & validate alignment"
1640
+
1641
+ # Critical Transition: Web UI → IDE
1642
+ transition:
1643
+ type: ${config.transitions.planningToIDE}
1644
+ requirements:
1645
+ - "Copy docs/prd.md and docs/architecture.md to project"
1646
+ - "Switch to IDE"
1647
+ - "PO: Shard documents (CRITICAL)"
1648
+ - "Update core-config.yaml devLoadAlwaysFiles"
1649
+
1650
+ # BMAD Development Phase (IDE Only)
1651
+ development_phase:
1652
+ workflow: ${config.developmentPhase.workflow}
1653
+ agents:
1654
+ ${config.developmentPhase.agents.map((agent) => ` - ${agent}`).join("\n")}
1655
+
1656
+ cycle:
1657
+ 1: "sm → review previous story dev/QA notes"
1658
+ 2: "sm → draft next story from sharded epic + architecture"
1659
+ 3: "po → validate story draft (optional)"
1660
+ 4: "user → approve story"
1661
+ 5: "dev → sequential task execution + implementation"
1662
+ 6: "dev → run all validations, mark ready for review"
1663
+ 7: "user → verify (request QA or approve)"
1664
+ 8: "qa → senior dev review + active refactoring (if requested)"
1665
+ 9: "CRITICAL → verify regression tests + linting pass"
1666
+ 10: "CRITICAL → COMMIT CHANGES BEFORE PROCEEDING"
1667
+ 11: "mark story done → loop back to sm"
1668
+
1669
+ # Critical Commit Points
1670
+ commit_points:
1671
+ ${config.transitions.criticalCommitPoints
1672
+ .map((point) => ` - ${point}`)
1673
+ .join("\n")}
1674
+
1675
+ # IDE Integration
1676
+ ides:
1677
+ ${this.config.selectedIDEs
1678
+ .map(
1679
+ (ide) => ` - name: ${this.getIDEName(ide)}
1680
+ config_path: ${this.getIDEConfig(ide).dir}
1681
+ file_format: ${this.getIDEConfig(ide).suffix}`
1682
+ )
1683
+ .join("\n")}
1684
+
1685
+ # Context Management
1686
+ context:
1687
+ dev_always_files:
1688
+ - docs/architecture/coding-standards.md
1689
+ - docs/architecture/tech-stack.md
1690
+ - docs/architecture/project-structure.md
1691
+
1692
+ agent_dependencies:
1693
+ templates: ["prd-template.md", "architecture-template.md", "story-template.md"]
1694
+ tasks: ["create-doc.md", "shard-doc.md", "validate-story.md"]
1695
+ data: ["bmad-kb.md", "technical-preferences.md"]
1696
+
1697
+ ---
1698
+ *Powered by Appiq Solution - Built with ❤️ based on Bmad-Method*
1699
+ `;
1700
+ }
1701
+
1702
+ generatePlanningWorkflow() {
1703
+ return `# BMAD Planning Workflow
1704
+
1705
+ ## Übersicht
1706
+ Die Planungsphase folgt einem strukturierten Workflow, idealerweise in Web UI für Kosteneffizienz.
1707
+
1708
+ ## Planning Flow
1709
+
1710
+ ### 1. Start: Projektidee
1711
+ - Grundlegendes Konzept definiert
1712
+ - Problem identifiziert
1713
+
1714
+ ### 2. Analyst (Optional)
1715
+ **Brainstorming:**
1716
+ - Marktforschung
1717
+ - Konkurrenzanalyse
1718
+ - Projekt Brief erstellen
1719
+
1720
+ ### 3. Project Manager (PM)
1721
+ **PRD Erstellung:**
1722
+ - PRD aus Brief erstellen (Fast Track)
1723
+ - ODER interaktive PRD Erstellung (mehr Fragen)
1724
+ - Functional Requirements (FRs)
1725
+ - Non-Functional Requirements (NFRs)
1726
+ - Epics & Stories definieren
1727
+
1728
+ ### 4. UX Expert (Optional)
1729
+ **Frontend Specification:**
1730
+ - Frontend Spec erstellen
1731
+ - UI Prompts für Lovable/V0 generieren (optional)
1732
+
1733
+ ### 5. System Architect
1734
+ **Architektur Design:**
1735
+ - Architektur aus PRD erstellen
1736
+ - ODER aus PRD + UX Spec erstellen
1737
+ - Tech Stack definieren
1738
+ - System Components planen
1739
+
1740
+ ### 6. Product Owner (PO)
1741
+ **Master Checklist:**
1742
+ - Dokumenten-Alignment prüfen
1743
+ - Epics & Stories aktualisieren (falls nötig)
1744
+ - PRD/Architektur anpassen (falls nötig)
1745
+
1746
+ ## Kritischer Übergang: Web UI → IDE
1747
+
1748
+ ### ⚠️ WICHTIG: Transition Point
1749
+ Sobald PO Dokumenten-Alignment bestätigt:
1750
+
1751
+ 1. **Dokumente kopieren**: docs/prd.md und docs/architecture.md
1752
+ 2. **IDE wechseln**: Projekt in bevorzugter Agentic IDE öffnen
1753
+ 3. **Document Sharding**: PO Agent zum Shard der Dokumente verwenden
1754
+ 4. **Development beginnen**: Core Development Cycle starten
1755
+
1756
+ ## Qualitäts-Gates
1757
+
1758
+ ### Planning Complete Criteria
1759
+ - [ ] PRD vollständig und genehmigt
1760
+ - [ ] Architektur vollständig und genehmigt
1761
+ - [ ] UX Spec (falls erforderlich) genehmigt
1762
+ - [ ] Alle Dokumente sind aligned
1763
+ - [ ] Epics und Stories definiert
1764
+ - [ ] Übergang zu IDE vorbereitet
1765
+
1766
+ ## Nächste Schritte
1767
+ Nach Planning Complete → **Document Sharding** → **Development Cycle**
1768
+
1769
+ ---
1770
+ *Built with ❤️ based on Bmad-Method*
1771
+ `;
1772
+ }
1773
+
1774
+ generateDevelopmentCycle() {
1775
+ return `# BMAD Core Development Cycle
1776
+
1777
+ ## Übersicht
1778
+ Strukturierter Entwicklungsworkflow in der IDE nach abgeschlossener Planungsphase.
1779
+
1780
+ ## Voraussetzungen
1781
+ - ✅ Planning Phase abgeschlossen
1782
+ - ✅ Dokumente in Projekt kopiert (docs/prd.md, docs/architecture.md)
1783
+ - ✅ **Document Sharding** durch PO Agent durchgeführt
1784
+ - ✅ IDE-Setup komplett
1785
+
1786
+ ## Development Cycle Flow
1787
+
1788
+ ### 1. Scrum Master (SM)
1789
+ **Story Vorbereitung:**
1790
+ - Review previous story dev/QA notes
1791
+ - Draft next story from sharded epic + architecture
1792
+ - Berücksichtigt technical dependencies
1793
+ - Erstellt realistische task breakdown
1794
+
1795
+ ### 2. Product Owner (PO) - Optional
1796
+ **Story Validation:**
1797
+ - Validate story draft against artifacts
1798
+ - Überprüft alignment mit PRD
1799
+ - Bestätigt business value
1800
+ - Kann übersprungen werden bei erfahrenen Teams
1801
+
1802
+ ### 3. User Approval
1803
+ **Story Freigabe:**
1804
+ - ✅ **Approved**: Weiter zu Development
1805
+ - ❌ **Needs Changes**: Zurück zu SM für Anpassungen
1806
+
1807
+ ### 4. Developer (Dev)
1808
+ **Implementation:**
1809
+ - Sequential task execution
1810
+ - Implement tasks + tests
1811
+ - Run all validations
1812
+ - Mark ready for review + add notes
1813
+ - Dokumentiert implementation decisions
1814
+
1815
+ ### 5. User Verification
1816
+ **Review Decision:**
1817
+ - 🔍 **Request QA Review**: Weiter zu QA Agent
1818
+ - ✅ **Approve Without QA**: Direkt zu Final Checks
1819
+ - ❌ **Needs Fixes**: Zurück zu Dev
1820
+
1821
+ ### 6. QA Agent (Optional)
1822
+ **Quality Assurance:**
1823
+ - Senior dev review + active refactoring
1824
+ - Review code, refactor, add tests
1825
+ - Document notes and improvements
1826
+ - **Decision**: Needs Dev Work OR Approved
1827
+
1828
+ ### 7. Final Checks - ⚠️ CRITICAL
1829
+ **Vor dem Abschluss:**
1830
+ - ✅ Verify ALL regression tests passing
1831
+ - ✅ Verify ALL linting passing
1832
+ - ✅ Code review completed (if QA was used)
1833
+ - ✅ Documentation updated
1834
+
1835
+ ### 8. Commit - ⚠️ SUPER CRITICAL
1836
+ **WICHTIG: COMMIT YOUR CHANGES BEFORE PROCEEDING!**
1837
+ - Git add & commit all changes
1838
+ - Include meaningful commit message
1839
+ - Push to repository
1840
+
1841
+ ### 9. Story Complete
1842
+ **Mark als Done:**
1843
+ - Story status → DONE
1844
+ - Loop back to SM for next story
1845
+
1846
+ ## Critical Points
1847
+
1848
+ ### ⚠️ Commit Points
1849
+ - **After QA Approval**: Always commit before marking done
1850
+ - **Before Next Story**: Clean state for next iteration
1851
+
1852
+ ### 🎯 Quality Gates
1853
+ - All tests passing
1854
+ - Linting clean
1855
+ - Code reviewed (if QA used)
1856
+ - Documentation current
1857
+
1858
+ ### 📊 Context Management
1859
+ - Keep relevant files only in context
1860
+ - Use sharded documents
1861
+ - Maintain lean, focused files
1862
+
1863
+ ## Best Practices
1864
+ - **Small Stories**: Keep stories manageable (< 1 week)
1865
+ - **Regular Commits**: Commit frequently during development
1866
+ - **Test First**: Write tests before or with implementation
1867
+ - **Document Decisions**: Record architectural decisions
1868
+
1869
+ ---
1870
+ *Built with ❤️ based on Bmad-Method*
1871
+ `;
1872
+ }
1873
+
1874
+ generateDocumentSharding() {
1875
+ return `# Document Sharding Guide
1876
+
1877
+ ## ⚠️ CRITICAL STEP
1878
+ Document Sharding ist ein **essentieller Schritt** im BMAD Flow nach der Planungsphase.
1879
+
1880
+ ## Wann Document Sharding durchführen?
1881
+ - ✅ Nach Planning Phase Completion
1882
+ - ✅ Beim Übergang von Web UI zu IDE
1883
+ - ✅ Vor Beginn des Development Cycles
1884
+ - ✅ Wenn Dokumente zu groß für Agent-Context werden
1885
+
1886
+ ## Warum Document Sharding?
1887
+ - **Performance**: Kleinere Context = bessere Agent-Performance
1888
+ - **Focus**: Jede Datei dient einem spezifischen Zweck
1889
+ - **Maintainability**: Einfacher zu aktualisieren und zu verwalten
1890
+ - **Agent Efficiency**: Agents laden nur was sie brauchen
1891
+
1892
+ ## Sharding Process
1893
+
1894
+ ### 1. PRD Sharding
1895
+ **Source**: docs/prd.md
1896
+ **Target Structure**:
1897
+ \`\`\`
1898
+ docs/
1899
+ ├── requirements/
1900
+ │ ├── core.md # Core functional requirements
1901
+ │ ├── non-functional.md # NFRs (performance, security)
1902
+ │ └── success-metrics.md # KPIs and success criteria
1903
+ ├── stories/
1904
+ │ ├── epic-1-auth/
1905
+ │ │ ├── story-1-1-login.md
1906
+ │ │ └── story-1-2-register.md
1907
+ │ └── epic-2-dashboard/
1908
+ │ └── story-2-1-overview.md
1909
+ \`\`\`
1910
+
1911
+ ### 2. Architecture Sharding
1912
+ **Source**: docs/architecture.md
1913
+ **Target Structure**:
1914
+ \`\`\`
1915
+ docs/architecture/
1916
+ ├── tech-stack.md # Technology decisions
1917
+ ├── coding-standards.md # Code style and patterns
1918
+ ├── project-structure.md # File/folder organization
1919
+ ├── api-design.md # REST/GraphQL API specs
1920
+ ├── data-models.md # Database schema
1921
+ ├── security.md # Security considerations
1922
+ └── deployment.md # Deployment architecture
1923
+ \`\`\`
1924
+
1925
+ ## Sharding Guidelines
1926
+
1927
+ ### File Size
1928
+ - **Target**: < 50 lines per sharded file
1929
+ - **Maximum**: < 100 lines per sharded file
1930
+ - **Focus**: One concern per file
1931
+
1932
+ ### Naming Convention
1933
+ - **kebab-case**: tech-stack.md, coding-standards.md
1934
+ - **Descriptive**: Clear purpose from filename
1935
+ - **Consistent**: Follow project conventions
1936
+
1937
+ ### Content Rules
1938
+ - **Atomic**: Each file covers one topic completely
1939
+ - **Self-contained**: Can be understood independently
1940
+ - **Linked**: Reference related files when needed
1941
+ - **Lean**: Remove fluff, keep essentials
1942
+
1943
+ ## Post-Sharding Configuration
1944
+
1945
+ ### 1. Update core-config.yaml
1946
+ \`\`\`yaml
1947
+ devLoadAlwaysFiles:
1948
+ - docs/architecture/coding-standards.md
1949
+ - docs/architecture/tech-stack.md
1950
+ - docs/architecture/project-structure.md
1951
+ \`\`\`
1952
+
1953
+ ### 2. Verify Agent Access
1954
+ - Test that agents can load sharded files
1955
+ - Ensure all references are correct
1956
+ - Validate file paths in configuration
1957
+
1958
+ ### 3. Update Templates
1959
+ - Modify templates to reference sharded structure
1960
+ - Update agent prompts to use sharded files
1961
+ - Test template generation
1962
+
1963
+ ## Quality Checks
1964
+
1965
+ ### ✅ Sharding Complete Criteria
1966
+ - [ ] All large documents sharded
1967
+ - [ ] Each shard < 100 lines
1968
+ - [ ] devLoadAlwaysFiles updated
1969
+ - [ ] Agent dependencies resolved
1970
+ - [ ] File references working
1971
+ - [ ] Templates updated
1972
+
1973
+ ### 🚨 Common Mistakes
1974
+ - **Too Large**: Shards still too big (>100 lines)
1975
+ - **Too Small**: Over-sharding (many 5-line files)
1976
+ - **Broken Links**: References to old unified files
1977
+ - **Missing Config**: devLoadAlwaysFiles not updated
1978
+
1979
+ ## After Sharding
1980
+ 1. **Test Agent Loading**: Verify agents can access all needed files
1981
+ 2. **Begin Development**: Start Core Development Cycle
1982
+ 3. **Monitor Performance**: Watch for context issues
1983
+ 4. **Refine as Needed**: Adjust sharding based on usage
1984
+
1985
+ ---
1986
+ *Built with ❤️ based on Bmad-Method*
1987
+ `;
1988
+ }
1989
+
1990
+
1991
+
1992
+
1993
+
1994
+ async performInstallation() {
1995
+ console.log(chalk.yellow("📦 Installation läuft..."));
1996
+
1997
+ // Create appiq-solution directory
1998
+ if (!fs.existsSync(this.appiqPath)) {
1999
+ fs.mkdirSync(this.appiqPath, { recursive: true });
2000
+ }
2001
+
2002
+ // Install optimized agents
2003
+ await this.installOptimizedAgents();
2004
+
2005
+ // Install project-specific configs
2006
+ await this.installProjectConfig();
2007
+
2008
+ // Setup IDE integration
2009
+ await this.setupIDEIntegration();
2010
+
2011
+ console.log(chalk.green("✅ Installation abgeschlossen!\n"));
2012
+ }
2013
+
2014
+ async installOptimizedAgents() {
2015
+ console.log(chalk.gray(" 📄 Optimierte Agents installieren..."));
2016
+
2017
+ const agentsDir = path.join(this.appiqPath, "agents");
2018
+ if (!fs.existsSync(agentsDir)) {
2019
+ fs.mkdirSync(agentsDir, { recursive: true });
2020
+ }
2021
+
2022
+ // Core optimized agents
2023
+ const agents = [
2024
+ "smart-launcher",
2025
+ "project-manager",
2026
+ "architect",
2027
+ "story-master",
2028
+ "developer",
2029
+ "qa-expert",
2030
+ ];
2031
+
2032
+ for (const agent of agents) {
2033
+ await this.createOptimizedAgent(agent);
2034
+ }
2035
+ }
2036
+
2037
+ async createOptimizedAgent(agentName) {
2038
+ const agentContent = this.generateOptimizedAgentContent(agentName);
2039
+ const filePath = path.join(this.appiqPath, "agents", `${agentName}.md`);
2040
+ fs.writeFileSync(filePath, agentContent);
2041
+ }
2042
+
2043
+ generateOptimizedAgentContent(agentName) {
2044
+ const agentConfigs = {
2045
+ "smart-launcher": {
2046
+ name: "Appiq Launcher",
2047
+ role: "Intelligenter Projekt-Starter",
2048
+ commands: ["/start", "/quick-setup", "/help"],
2049
+ description:
2050
+ "Startet automatisch den optimalen Workflow basierend auf Ihrem Projekt-Typ",
2051
+ },
2052
+ "project-manager": {
2053
+ name: "Project Manager",
2054
+ role: "PRD & Projekt-Planung",
2055
+ commands: ["/prd", "/plan", "/epic"],
2056
+ description: "Erstellt PRD und Projekt-Dokumentation",
2057
+ },
2058
+ architect: {
2059
+ name: "System Architect",
2060
+ role: "Technische Architektur",
2061
+ commands: ["/architecture", "/tech-stack", "/design"],
2062
+ description: "Entwickelt System-Architektur und Tech-Stack",
2063
+ },
2064
+ "story-master": {
2065
+ name: "Story Master",
2066
+ role: "User Stories & Sprint Planning",
2067
+ commands: ["/story", "/sprint", "/tasks"],
2068
+ description: "Erstellt User Stories und Sprint-Planung",
2069
+ },
2070
+ developer: {
2071
+ name: "Senior Developer",
2072
+ role: "Code Implementation",
2073
+ commands: ["/code", "/implement", "/fix"],
2074
+ description: "Implementiert Features und behebt Bugs",
2075
+ },
2076
+ "qa-expert": {
2077
+ name: "QA Expert",
2078
+ role: "Testing & Qualität",
2079
+ commands: ["/test", "/review", "/validate"],
2080
+ description: "Führt Tests durch und validiert Code-Qualität",
2081
+ },
2082
+ };
2083
+
2084
+ const config = agentConfigs[agentName];
2085
+
2086
+ return `# ${config.name}
2087
+
2088
+ ## 🎯 Rolle
2089
+ ${config.role}
2090
+
2091
+ ## 📋 Verfügbare Kommandos
2092
+ ${config.commands
2093
+ .map((cmd) => `- **${cmd}** - ${config.description}`)
2094
+ .join("\n")}
2095
+
2096
+ ## 🚀 One-Click Workflows
2097
+
2098
+ ### Für ${
2099
+ this.config.projectType === "greenfield" ? "NEUE" : "BESTEHENDE"
2100
+ } Projekte:
2101
+
2102
+ ${
2103
+ this.config.projectType === "greenfield"
2104
+ ? this.generateGreenfieldWorkflow(config)
2105
+ : this.generateBrownfieldWorkflow(config)
2106
+ }
2107
+
2108
+ ## 🎮 Einfache Nutzung
2109
+
2110
+ 1. **Laden Sie diesen Agent in Ihre IDE**
2111
+ 2. **Sagen Sie:** "Agiere als ${config.name}"
2112
+ 3. **Verwenden Sie:** ${config.commands[0]} für Quick-Start
2113
+
2114
+ ---
2115
+ *Automatisch optimiert für ${this.config.selectedIDEs
2116
+ .map((ide) => this.getIDEName(ide))
2117
+ .join(", ")}*
2118
+ *Powered by Appiq - Based on Bmad-Method*
2119
+ `;
2120
+ }
2121
+
2122
+ generateGreenfieldWorkflow(config) {
2123
+ const workflows = {
2124
+ "Appiq Launcher": `
2125
+ **🚀 Schnell-Start für neues Projekt:**
2126
+ 1. \`/start\` - Automatische Projekt-Analyse
2127
+ 2. Erstellt automatisch: PRD-Vorlage, Architektur-Basis, erste Stories
2128
+ 3. **Wo alles hingehört:** Alle Dateien werden automatisch in \`docs/\` erstellt`,
2129
+
2130
+ "Project Manager": `
2131
+ **📋 PRD Erstellung:**
2132
+ 1. \`/prd\` - Startet PRD-Assistent
2133
+ 2. **Datei wird erstellt:** \`docs/prd.md\`
2134
+ 3. **Nächster Schritt:** Architect für Architektur`,
2135
+
2136
+ "System Architect": `
2137
+ **🏗️ Architektur erstellen:**
2138
+ 1. \`/architecture\` - Basierend auf PRD
2139
+ 2. **Datei wird erstellt:** \`docs/architecture.md\`
2140
+ 3. **Nächster Schritt:** Story Master für erste Stories`,
2141
+
2142
+ "Story Master": `
2143
+ **📝 Erste Stories:**
2144
+ 1. \`/story\` - Erstellt erste User Story
2145
+ 2. **Datei wird erstellt:** \`docs/stories/story-001.md\`
2146
+ 3. **Nächster Schritt:** Developer für Implementation`,
2147
+
2148
+ "Senior Developer": `
2149
+ **💻 Implementation:**
2150
+ 1. \`/implement\` - Implementiert aktuelle Story
2151
+ 2. **Erstellt/bearbeitet:** Entsprechende Code-Dateien
2152
+ 3. **Nächster Schritt:** QA Expert für Review`,
2153
+
2154
+ "QA Expert": `
2155
+ **✅ Testing & Review:**
2156
+ 1. \`/review\` - Reviewed aktuellen Code
2157
+ 2. **Erstellt:** Test-Dateien und Reports
2158
+ 3. **Nächster Schritt:** Zurück zu Story Master für nächste Story`,
2159
+ };
2160
+
2161
+ return workflows[config.name] || "Standard Greenfield Workflow";
2162
+ }
2163
+
2164
+ generateBrownfieldWorkflow(config) {
2165
+ const workflows = {
2166
+ "Appiq Launcher": `
2167
+ **🔧 Schnell-Start für bestehendes Projekt:**
2168
+ 1. \`/analyze\` - Analysiert bestehendes Projekt
2169
+ 2. **Findet:** Existierende Docs, Code-Struktur, Tech-Stack
2170
+ 3. **Erstellt:** Angepasste Workflows für Ihr Projekt`,
2171
+
2172
+ "Project Manager": `
2173
+ **📋 Automatische PRD Erstellung:**
2174
+ 1. **Erstellt automatisch:** \`docs/prd.md\` (falls nicht vorhanden)
2175
+ 2. **Für Flutter Projekte:** Verwendet flutter-mobile-prd-tmpl.yaml
2176
+ 3. **Keine Projektname-Abfrage** - Verwendet Verzeichnisname
2177
+ 4. **Nächster Schritt:** Architect für Architektur-Review`,
2178
+
2179
+ "System Architect": `
2180
+ **🏗️ Architektur-Review:**
2181
+ 1. \`/review-architecture\` - Analysiert bestehende Struktur
2182
+ 2. **Erstellt/updated:** \`docs/architecture.md\`
2183
+ 3. **Nächster Schritt:** Story Master für neue Features`,
2184
+
2185
+ "Story Master": `
2186
+ **📝 Feature Stories:**
2187
+ 1. \`/new-feature\` - Neue Story für bestehendes Projekt
2188
+ 2. **Datei wird erstellt:** \`docs/stories/feature-XXX.md\`
2189
+ 3. **Berücksichtigt:** Bestehende Code-Basis`,
2190
+
2191
+ "Senior Developer": `
2192
+ **💻 Feature Implementation:**
2193
+ 1. \`/add-feature\` - Implementiert in bestehendem Code
2194
+ 2. **Bearbeitet:** Bestehende Dateien sicher
2195
+ 3. **Erstellt:** Neue Dateien wo nötig`,
2196
+
2197
+ "QA Expert": `
2198
+ **✅ Regression Testing:**
2199
+ 1. \`/regression-test\` - Testet neue Features
2200
+ 2. **Validiert:** Keine Breaking Changes
2201
+ 3. **Erstellt:** Test-Reports für bestehende + neue Features`,
2202
+ };
2203
+
2204
+ return workflows[config.name] || "Standard Brownfield Workflow";
2205
+ }
2206
+
2207
+ async setupOneClickWorkflows() {
2208
+ console.log(chalk.yellow("⚡ One-Click Workflows einrichten..."));
2209
+
2210
+ // Create quick commands
2211
+ const commandsDir = path.join(this.appiqPath, "commands");
2212
+ if (!fs.existsSync(commandsDir)) {
2213
+ fs.mkdirSync(commandsDir, { recursive: true });
2214
+ }
2215
+
2216
+ // Project-type specific quick starts
2217
+ const quickStartContent = this.generateQuickStartScript();
2218
+ fs.writeFileSync(
2219
+ path.join(commandsDir, "quick-start.md"),
2220
+ quickStartContent
2221
+ );
2222
+
2223
+ console.log(chalk.green("✅ One-Click Workflows bereit!\n"));
2224
+ }
2225
+
2226
+ generateQuickStartScript() {
2227
+ return `# 🚀 Appiq Solution - BMAD Workflow Guide
2228
+
2229
+ ## Projekt: ${this.config.projectName || "Unbenanntes Projekt"}
2230
+ **Typ:** ${
2231
+ this.config.projectType === "greenfield"
2232
+ ? "✨ Greenfield (Neues Projekt)"
2233
+ : "🔧 Brownfield (Bestehendes Projekt)"
2234
+ }
2235
+
2236
+ ## 📋 BMAD Planning Workflow (Phase 1)
2237
+
2238
+ ### Option A: Web UI Planning (Kosteneffizient)
2239
+ 1. Claude/Gemini/GPT mit team-fullstack Bundle verwenden
2240
+ 2. **Flow:** Analyst → PM → UX Expert → Architect → PO
2241
+ 3. **Output:** docs/prd.md, docs/architecture.md
2242
+
2243
+ ### Option B: IDE Planning (Leistungsstark)
2244
+ \`\`\`
2245
+ @analyst → Market Research & Project Brief
2246
+ @pm → PRD mit FRs, NFRs, Epics & Stories erstellen
2247
+ @ux-expert → Frontend Spec (optional)
2248
+ @architect → System Architecture design
2249
+ @po → Master Checklist & Document Alignment
2250
+ \`\`\`
2251
+
2252
+ ## ⚠️ KRITISCHER ÜBERGANG: Document Sharding
2253
+
2254
+ **ESSENTIAL STEP:**
2255
+ \`\`\`
2256
+ @po bitte shard die PRD und Architecture Dokumente in fokussierte Dateien
2257
+ \`\`\`
2258
+
2259
+ **Das erstellt:**
2260
+ - docs/architecture/tech-stack.md ← Dev lädt immer
2261
+ - docs/architecture/coding-standards.md ← Dev lädt immer
2262
+ - docs/architecture/project-structure.md ← Dev lädt immer
2263
+ - docs/requirements/core.md
2264
+ - docs/stories/ (individual story files)
2265
+
2266
+ ## 🚀 BMAD Development Cycle (Phase 2)
2267
+
2268
+ ### Core Development Loop:
2269
+ \`\`\`
2270
+ 1. @sm → Review previous notes, draft next story from sharded epic
2271
+ 2. @po → Validate story draft (optional)
2272
+ 3. User → Approve story
2273
+ 4. @dev → Sequential tasks, implement + tests, mark ready
2274
+ 5. User → Verify (request QA or approve)
2275
+ 6. @qa → Senior dev review + refactoring (optional)
2276
+ 7. ⚠️ CRITICAL: Verify tests + linting pass
2277
+ 8. ⚠️ SUPER CRITICAL: COMMIT CHANGES BEFORE PROCEEDING!
2278
+ 9. Mark story done → Loop back to @sm
2279
+ \`\`\`
2280
+
2281
+ ## 🎯 One-Click Commands
2282
+
2283
+ ### Planning:
2284
+ - \`/plan\` → Start planning workflow
2285
+ - \`/prd\` → Generate PRD
2286
+ - \`/arch\` → Design architecture
2287
+
2288
+ ### Critical Transition:
2289
+ - \`/shard\` → Document sharding (ESSENTIAL!)
2290
+
2291
+ ### Development:
2292
+ - \`/story\` → Draft next story
2293
+ - \`/dev\` → Start development
2294
+ - \`/test\` → Run tests
2295
+ - \`/qa\` → Request review
2296
+ - \`/commit\` → Commit changes
2297
+
2298
+ ### ${
2299
+ this.config.projectType === "greenfield" ? "Greenfield" : "Brownfield"
2300
+ } Specific:
2301
+ ${
2302
+ this.config.projectType === "greenfield"
2303
+ ? `
2304
+ - \`/start\` → Fresh project setup
2305
+ - \`/design\` → Create from scratch
2306
+ - \`/build\` → Build step by step
2307
+ `
2308
+ : `
2309
+ - \`/analyze\` → Analyze existing code
2310
+ - \`/document\` → Document current state
2311
+ - \`/improve\` → Plan improvements
2312
+ `
2313
+ }
2314
+
2315
+ ## 📊 File Structure
2316
+
2317
+ \`\`\`
2318
+ your-project/
2319
+ ├── docs/
2320
+ │ ├── prd.md ← Initial PRD
2321
+ │ ├── architecture.md ← Initial Architecture
2322
+ │ ├── architecture/ ← Sharded files
2323
+ │ │ ├── tech-stack.md
2324
+ │ │ ├── coding-standards.md
2325
+ │ │ └── project-structure.md
2326
+ │ ├── requirements/
2327
+ │ │ └── core.md
2328
+ │ └── stories/
2329
+ │ ├── epic-1-auth/
2330
+ │ └── epic-2-features/
2331
+ ├── appiq-solution/
2332
+ │ ├── agents/ ← AI-Agents
2333
+ │ ├── templates/ ← Document templates
2334
+ │ ├── workflows/ ← Workflow guides
2335
+ │ └── .bmad-core/ ← BMAD configuration
2336
+ └── .cursor/rules/ ← IDE integration
2337
+ \`\`\`
2338
+
2339
+ ## ⚠️ Critical Success Factors
2340
+
2341
+ ### Document Sharding (ESSENTIAL):
2342
+ - **MUST DO** after planning phase
2343
+ - Creates focused, lean files for agents
2344
+ - Improves agent performance dramatically
2345
+
2346
+ ### Commit Points:
2347
+ - After QA approval (always!)
2348
+ - Before next story (clean state)
2349
+ - Regular commits during development
2350
+
2351
+ ### Quality Gates:
2352
+ - All tests passing ✅
2353
+ - Linting clean ✅
2354
+ - Code reviewed (if QA used) ✅
2355
+ - Documentation updated ✅
2356
+
2357
+ ## 🆘 Help & Support
2358
+
2359
+ - \`/help\` → Show all commands
2360
+ - \`/workflow\` → Current workflow step
2361
+ - \`/agents\` → Available agents
2362
+ - \`/docs\` → Documentation
2363
+
2364
+ ### Workflow Files:
2365
+ - appiq-solution/workflows/planning-workflow.md
2366
+ - appiq-solution/workflows/development-cycle.md
2367
+ - appiq-solution/workflows/document-sharding.md
2368
+
2369
+ ---
2370
+ **IDEs:** ${this.config.selectedIDEs
2371
+ .map((ide) => this.getIDEName(ide))
2372
+ .join(", ")}
2373
+ **Created:** ${new Date().toLocaleDateString("de-DE")}
2374
+ **Powered by Appiq Solution - Built with ❤️ based on Bmad-Method**
2375
+ `;
2376
+ }
2377
+
2378
+ async setupIDEIntegration() {
2379
+ if (
2380
+ this.config.selectedIDEs.includes("manual") &&
2381
+ this.config.selectedIDEs.length === 1
2382
+ )
2383
+ return;
2384
+
2385
+ console.log(chalk.gray(" 🔧 Mehrere IDE-Integrationen..."));
2386
+
2387
+ for (const ide of this.config.selectedIDEs) {
2388
+ if (ide === "manual") continue;
2389
+
2390
+ console.log(
2391
+ chalk.gray(` 📝 ${this.getIDEName(ide)} wird konfiguriert...`)
2392
+ );
2393
+
2394
+ const ideConfig = this.getIDEConfig(ide);
2395
+ const ideDir = path.join(this.projectRoot, ideConfig.dir);
2396
+
2397
+ if (!fs.existsSync(ideDir)) {
2398
+ fs.mkdirSync(ideDir, { recursive: true });
2399
+ }
2400
+
2401
+ // Copy agents to IDE-specific format
2402
+ const agentsPath = path.join(this.appiqPath, "agents");
2403
+ const agents = fs.readdirSync(agentsPath);
2404
+
2405
+ for (const agent of agents) {
2406
+ const sourcePath = path.join(agentsPath, agent);
2407
+ const targetPath = path.join(
2408
+ ideDir,
2409
+ agent.replace(".md", ideConfig.suffix)
2410
+ );
2411
+ fs.copyFileSync(sourcePath, targetPath);
2412
+ }
2413
+
2414
+ console.log(chalk.green(` ✅ ${this.getIDEName(ide)} konfiguriert`));
2415
+ }
2416
+
2417
+ console.log(chalk.green(" ✅ Alle IDE-Integrationen abgeschlossen!"));
2418
+ }
2419
+
2420
+ getIDEConfig(ide) {
2421
+ const configs = {
2422
+ cursor: { dir: ".cursor/rules", suffix: ".mdc" },
2423
+ "claude-code": { dir: ".claude/commands/Appiq", suffix: ".md" },
2424
+ windsurf: { dir: ".windsurf/rules", suffix: ".md" },
2425
+ cline: { dir: ".clinerules", suffix: ".md" },
2426
+ trae: { dir: ".trae/rules", suffix: ".md" },
2427
+ roo: { dir: ".roo/agents", suffix: ".md" },
2428
+ gemini: { dir: ".gemini/commands", suffix: ".md" },
2429
+ "github-copilot": { dir: ".github/copilot", suffix: ".md" },
2430
+ };
2431
+ return configs[ide] || { dir: ".appiq-solution", suffix: ".md" };
2432
+ }
2433
+
2434
+ getIDEName(ide) {
2435
+ const names = {
2436
+ cursor: "Cursor",
2437
+ "claude-code": "Claude Code CLI",
2438
+ windsurf: "Windsurf",
2439
+ cline: "VS Code + Cline",
2440
+ trae: "Trae",
2441
+ roo: "Roo Code",
2442
+ gemini: "Gemini CLI",
2443
+ "github-copilot": "GitHub Copilot",
2444
+ manual: "Manuell",
2445
+ };
2446
+ return names[ide] || ide;
2447
+ }
2448
+
2449
+ async showSimpleInstructions() {
2450
+ console.log(chalk.bold.green("🎉 Appiq Installation Erfolgreich!\n"));
2451
+ console.log(chalk.dim("Built with ❤️ based on the amazing Bmad-Method"));
2452
+ console.log(chalk.dim("https://github.com/Viktor-Hermann/APPIQ-METHOD\n"));
2453
+
2454
+ console.log(chalk.cyan("📋 Nächste Schritte (Super einfach):"));
2455
+ console.log(chalk.white("════════════════════════════════════\n"));
2456
+
2457
+ if (
2458
+ this.config.selectedIDEs.length > 0 &&
2459
+ !this.config.selectedIDEs.includes("manual")
2460
+ ) {
2461
+ console.log(
2462
+ chalk.yellow(
2463
+ `1. Ihre IDEs öffnen: ${this.config.selectedIDEs
2464
+ .map((ide) => this.getIDEName(ide))
2465
+ .join(", ")}`
2466
+ )
2467
+ );
2468
+ console.log(
2469
+ chalk.gray(` → Agents sind bereits in allen IDEs installiert!\n`)
2470
+ );
2471
+ }
2472
+
2473
+ console.log(chalk.yellow("2. 📋 BMAD Planning Workflow:"));
2474
+ if (this.config.planApproved) {
2475
+ console.log(
2476
+ chalk.green(` ✅ Planning Complete - Ready for Development!`)
2477
+ );
2478
+ console.log(chalk.cyan(` → Ihre initial PRD: docs/prd.md`));
2479
+ } else {
2480
+ console.log(chalk.cyan(` Option A: Web UI (kosteneffizient)`));
2481
+ console.log(chalk.gray(` → Claude/Gemini/GPT mit Agents verwenden`));
2482
+ console.log(chalk.cyan(` Option B: Direkt in IDE`));
2483
+ console.log(chalk.gray(` → @pm für PRD, @architect für Architecture`));
2484
+ }
2485
+ console.log("");
2486
+
2487
+ console.log(chalk.yellow("3. ⚠️ KRITISCHER ÜBERGANG: Document Sharding"));
2488
+ console.log(
2489
+ chalk.red(
2490
+ ` → Sagen Sie Ihrer IDE: ${chalk.bold(
2491
+ '"@po bitte shard die PRD und Architecture Dokumente"'
2492
+ )}`
2493
+ )
2494
+ );
2495
+ console.log(
2496
+ chalk.gray(` → Dokumente werden in fokussierte Teile aufgeteilt\n`)
2497
+ );
2498
+
2499
+ console.log(chalk.yellow("4. 🚀 BMAD Development Cycle:"));
2500
+ console.log(chalk.cyan(` 1. @sm → Story Draft von Sharded Epic`));
2501
+ console.log(chalk.cyan(` 2. @po → Story Validation (optional)`));
2502
+ console.log(chalk.cyan(` 3. User → Story Approval`));
2503
+ console.log(chalk.cyan(` 4. @dev → Implementation + Tests`));
2504
+ console.log(chalk.cyan(` 5. @qa → Code Review (optional)`));
2505
+ console.log(chalk.red(` 6. ⚠️ COMMIT CHANGES BEFORE PROCEEDING!`));
2506
+ console.log(chalk.gray(` → Loop zurück zu @sm für nächste Story\n`));
2507
+
2508
+ console.log(chalk.yellow("5. 🎯 Quick Commands (in quick-start.md):"));
2509
+ console.log(chalk.cyan(` /plan → Planning starten`));
2510
+ console.log(chalk.cyan(` /shard → Document Sharding`));
2511
+ console.log(chalk.cyan(` /story → Nächste Story`));
2512
+ console.log(chalk.cyan(` /dev → Development`));
2513
+ console.log(chalk.cyan(` /qa → Quality Review`));
2514
+ console.log(chalk.gray(` → Alle Details in appiq-solution/workflows/\n`));
2515
+
2516
+ console.log(chalk.cyan("🎯 Das war's! Kein komplizierter Setup mehr."));
2517
+ console.log(chalk.green("🚀 Viel Erfolg mit Appiq!\n"));
2518
+
2519
+ // Quick reference
2520
+ console.log(chalk.dim("━".repeat(50)));
2521
+ console.log(chalk.dim("📁 Quick Reference:"));
2522
+ console.log(chalk.dim(` • Agents: appiq-solution/agents/`));
2523
+ console.log(
2524
+ chalk.dim(` • Quick Start: appiq-solution/commands/quick-start.md`)
2525
+ );
2526
+ console.log(chalk.dim(` • Projekt-Typ: ${this.config.projectType}`));
2527
+ console.log(
2528
+ chalk.dim(
2529
+ ` • IDEs: ${this.config.selectedIDEs
2530
+ .map((ide) => this.getIDEName(ide))
2531
+ .join(", ")}`
2532
+ )
2533
+ );
2534
+ }
2535
+
2536
+ // Helper methods
2537
+ hasExistingSourceCode() {
2538
+ const sourceDirs = ["src", "lib", "app", "components", "pages"];
2539
+ return sourceDirs.some(
2540
+ (dir) =>
2541
+ fs.existsSync(path.join(this.projectRoot, dir)) &&
2542
+ fs.readdirSync(path.join(this.projectRoot, dir)).length > 0
2543
+ );
2544
+ }
2545
+
2546
+ hasExistingDocumentation() {
2547
+ const docFiles = ["README.md", "docs", "documentation"];
2548
+ return docFiles.some((file) =>
2549
+ fs.existsSync(path.join(this.projectRoot, file))
2550
+ );
2551
+ }
2552
+
2553
+ async installProjectConfig() {
2554
+ const configContent = this.generateProjectConfig();
2555
+ fs.writeFileSync(
2556
+ path.join(this.appiqPath, "project-config.yaml"),
2557
+ configContent
2558
+ );
2559
+ }
2560
+
2561
+ generateProjectConfig() {
2562
+ return `# Appiq Solution Project Configuration
2563
+ # Built with ❤️ based on Bmad-Method
2564
+ version: "1.0.0"
2565
+ project:
2566
+ type: ${this.config.projectType}
2567
+ created: ${new Date().toISOString()}
2568
+ name: ${this.config.projectName || path.basename(this.projectRoot)}
2569
+ plan_approved: ${this.config.planApproved}
2570
+
2571
+ # Wo die wichtigen Dateien liegen
2572
+ paths:
2573
+ prd: "docs/prd.md"
2574
+ architecture: "docs/architecture.md"
2575
+ stories: "docs/stories/"
2576
+ agents: "appiq-solution/agents/"
2577
+ orchestration: "appiq-solution/orchestration.yaml"
2578
+
2579
+ # One-Click Workflows
2580
+ workflows:
2581
+ ${this.config.projectType === "greenfield" ? "greenfield" : "brownfield"}:
2582
+ start_command: "${
2583
+ this.config.projectType === "greenfield" ? "/start" : "/analyze"
2584
+ }"
2585
+ agents_sequence:
2586
+ - smart-launcher
2587
+ - project-manager
2588
+ - architect
2589
+ - story-master
2590
+ - developer
2591
+ - qa-expert
2592
+
2593
+ # IDE Integration (Mehrere IDEs)
2594
+ ides:
2595
+ ${this.config.selectedIDEs
2596
+ .map(
2597
+ (ide) => ` - name: ${this.getIDEName(ide)}
2598
+ config_path: ${this.getIDEConfig(ide).dir}
2599
+ file_format: ${this.getIDEConfig(ide).suffix}`
2600
+ )
2601
+ .join("\n")}
2602
+ `;
2603
+ }
2604
+ }
2605
+
2606
+ // Run installer if called directly
2607
+ if (require.main === module) {
2608
+ // Check if 'install' command is provided
2609
+ const args = process.argv.slice(2);
2610
+
2611
+ if (args.length === 0 || args[0] === "install") {
2612
+ const installer = new AppiqSolutionInstaller();
2613
+ installer.install().catch(console.error);
2614
+ } else {
2615
+ console.log(
2616
+ chalk.red("❌ Unknown command. Use: npx appiq-solution install")
2617
+ );
2618
+ process.exit(1);
2619
+ }
2620
+ }
2621
+
2622
+ module.exports = AppiqSolutionInstaller;