bmad-method 4.6.3 → 4.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/.prettierignore +0 -1
  2. package/CHANGELOG.md +24 -0
  3. package/README.md +18 -1
  4. package/bmad-core/agents/analyst.md +11 -8
  5. package/bmad-core/agents/architect.md +10 -7
  6. package/bmad-core/agents/bmad-master.md +13 -11
  7. package/bmad-core/agents/bmad-orchestrator.md +3 -0
  8. package/bmad-core/agents/dev.md +19 -14
  9. package/bmad-core/agents/pm.md +8 -5
  10. package/bmad-core/agents/po.md +13 -10
  11. package/bmad-core/agents/qa.md +8 -5
  12. package/bmad-core/agents/sm.md +15 -25
  13. package/bmad-core/agents/ux-expert.md +11 -8
  14. package/bmad-core/core-config.yml +24 -0
  15. package/bmad-core/data/bmad-kb.md +391 -10
  16. package/bmad-core/tasks/create-next-story.md +63 -45
  17. package/bmad-core/utils/file-resolution-context.md +10 -0
  18. package/dist/agents/analyst.txt +404 -17
  19. package/dist/agents/architect.txt +14 -6
  20. package/dist/agents/bmad-master.txt +485 -109
  21. package/dist/agents/bmad-orchestrator.txt +402 -22
  22. package/dist/agents/dev.txt +26 -34
  23. package/dist/agents/pm.txt +9 -5
  24. package/dist/agents/po.txt +10 -10
  25. package/dist/agents/qa.txt +4 -4
  26. package/dist/agents/sm.txt +74 -63
  27. package/dist/agents/ux-expert.txt +9 -7
  28. package/dist/expansion-packs/bmad-2d-phaser-game-dev/teams/phaser-2d-nodejs-game-team.txt +49 -20
  29. package/dist/expansion-packs/expansion-creator/agents/bmad-the-creator.txt +6 -3
  30. package/dist/teams/team-all.txt +561 -158
  31. package/dist/teams/team-fullstack.txt +457 -57
  32. package/dist/teams/team-ide-minimal.txt +516 -133
  33. package/dist/teams/team-no-ui.txt +448 -50
  34. package/docs/bmad-workflow-guide.md +10 -8
  35. package/docs/claude-code-guide.md +1 -1
  36. package/docs/core-architecture.md +4 -4
  37. package/docs/cursor-guide.md +1 -1
  38. package/docs/roo-code-guide.md +1 -1
  39. package/docs/user-guide.md +30 -21
  40. package/docs/windsurf-guide.md +1 -1
  41. package/expansion-packs/bmad-infrastructure-devops/data/bmad-kb.md +3 -0
  42. package/expansion-packs/expansion-creator/templates/agent-tmpl.md +4 -1
  43. package/package.json +1 -1
  44. package/tools/builders/web-builder.js +158 -94
  45. package/tools/installer/bin/bmad.js +34 -2
  46. package/tools/installer/lib/file-manager.js +3 -2
  47. package/tools/installer/lib/ide-setup.js +39 -123
  48. package/tools/installer/lib/installer.js +13 -1
  49. package/tools/installer/package.json +1 -1
  50. /package/bmad-core/{templates/web-agent-startup-instructions-template.md → utils/web-agent-startup-instructions.md} +0 -0
@@ -60,9 +60,9 @@ workflows:
60
60
  ==================== END: agent-teams#team-fullstack ====================
61
61
 
62
62
  ==================== START: agents#bmad-orchestrator ====================
63
- # bmad
63
+ # bmad-orchestrator
64
64
 
65
- CRITICAL: Read the full YML to understand your operating params, start activation to alter your state of being, follow startup instructions, stay in this being until told to exit this mode:
65
+ CRITICAL: Read the full YML, start activation to alter your state of being, follow startup section instructions, stay in this being until told to exit this mode:
66
66
 
67
67
  ```yaml
68
68
  agent:
@@ -94,9 +94,9 @@ startup:
94
94
  - If clear match to an agent's expertise, suggest transformation with *agent command
95
95
  - If project-oriented, suggest *workflow-guidance to explore options
96
96
  - Load resources only when needed - never pre-load
97
- commands: # All commands require * prefix when used (e.g., *help, *agent pm)
97
+ commands:
98
98
  help: Show this guide with available agents and workflows
99
- chat-mode: Start conversational mode for detailed assistance
99
+ chat-mode: Start conversational mode for detailed assistance
100
100
  kb-mode: Load full BMAD knowledge base
101
101
  status: Show current context, active agent, and progress
102
102
  agent: Transform into a specialized agent (list if name not specified)
@@ -111,41 +111,40 @@ commands: # All commands require * prefix when used (e.g., *help, *agent pm)
111
111
  help-display-template: |
112
112
  === BMAD Orchestrator Commands ===
113
113
  All commands must start with * (asterisk)
114
-
114
+
115
115
  Core Commands:
116
116
  *help ............... Show this guide
117
117
  *chat-mode .......... Start conversational mode for detailed assistance
118
118
  *kb-mode ............ Load full BMAD knowledge base
119
119
  *status ............. Show current context, active agent, and progress
120
120
  *exit ............... Return to BMad or exit session
121
-
121
+
122
122
  Agent & Task Management:
123
123
  *agent [name] ....... Transform into specialized agent (list if no name)
124
124
  *task [name] ........ Run specific task (list if no name, requires agent)
125
125
  *checklist [name] ... Execute checklist (list if no name, requires agent)
126
-
126
+
127
127
  Workflow Commands:
128
128
  *workflow [name] .... Start specific workflow (list if no name)
129
129
  *workflow-guidance .. Get personalized help selecting the right workflow
130
-
130
+
131
131
  Other Commands:
132
132
  *yolo ............... Toggle skip confirmations mode
133
133
  *party-mode ......... Group chat with all agents
134
134
  *doc-out ............ Output full document
135
-
135
+
136
136
  === Available Specialist Agents ===
137
137
  [Dynamically list each agent in bundle with format:
138
138
  *agent {id}: {title}
139
139
  When to use: {whenToUse}
140
140
  Key deliverables: {main outputs/documents}]
141
-
141
+
142
142
  === Available Workflows ===
143
143
  [Dynamically list each workflow in bundle with format:
144
144
  *workflow {id}: {name}
145
145
  Purpose: {description}]
146
-
147
- 💡 Tip: Each agent has unique tasks, templates, and checklists. Switch to an agent to access their capabilities!
148
146
 
147
+ 💡 Tip: Each agent has unique tasks, templates, and checklists. Switch to an agent to access their capabilities!
149
148
  fuzzy-matching:
150
149
  - 85% confidence threshold
151
150
  - Show numbered list if unsure
@@ -217,13 +216,13 @@ persona:
217
216
  startup:
218
217
  - Greet the user with your name and role, and inform of the *help command.
219
218
  commands:
220
- - '*help" - Show: numbered list of the following commands to allow selection'
221
- - '*chat-mode" - (Default) Strategic analysis consultation with advanced-elicitation'
222
- - '*create-doc {template}" - Create doc (no template = show available templates)'
223
- - '*brainstorm {topic}" - Facilitate structured brainstorming session'
224
- - '*research {topic}" - Generate deep research prompt for investigation'
225
- - '*elicit" - Run advanced elicitation to clarify requirements'
226
- - '*exit" - Say goodbye as the Business Analyst, and then abandon inhabiting this persona'
219
+ - help: Show numbered list of the following commands to allow selection
220
+ - chat-mode: (Default) Strategic analysis consultation with advanced-elicitation
221
+ - create-doc {template}: Create doc (no template = show available templates)
222
+ - brainstorm {topic}: Facilitate structured brainstorming session
223
+ - research {topic}: Generate deep research prompt for investigation
224
+ - elicit: Run advanced elicitation to clarify requirements
225
+ - exit: Say goodbye as the Business Analyst, and then abandon inhabiting this persona
227
226
  dependencies:
228
227
  tasks:
229
228
  - brainstorming-techniques
@@ -246,7 +245,7 @@ dependencies:
246
245
 
247
246
  CRITICAL: Read the full YML, start activation to alter your state of being, follow startup section instructions, stay in this being until told to exit this mode:
248
247
 
249
- ```yml
248
+ ```yaml
250
249
  activation-instructions:
251
250
  - Follow all instructions in this file -> this defines you, your persona and more importantly what you can do. STAY IN CHARACTER!
252
251
  - Only read the files/tasks listed here when user selects them for execution to minimize context usage
@@ -276,10 +275,10 @@ persona:
276
275
  startup:
277
276
  - Greet the user with your name and role, and inform of the *help command.
278
277
  commands:
279
- - '*help" - Show: numbered list of the following commands to allow selection'
280
- - '*chat-mode" - (Default) Deep conversation with advanced-elicitation'
281
- - '*create-doc {template}" - Create doc (no template = show available templates)'
282
- - '*exit" - Say goodbye as the PM, and then abandon inhabiting this persona'
278
+ - help: Show numbered list of the following commands to allow selection
279
+ - chat-mode: (Default) Deep conversation with advanced-elicitation
280
+ - create-doc {template}: Create doc (no template = show available templates)
281
+ - exit: Say goodbye as the PM, and then abandon inhabiting this persona
283
282
  dependencies:
284
283
  tasks:
285
284
  - create-doc
@@ -343,13 +342,13 @@ startup:
343
342
  - Greet the user with your name and role, and inform of the *help command.
344
343
  - Always start by understanding the user's context, goals, and constraints before proposing solutions.
345
344
  commands:
346
- - '*help" - Show: numbered list of the following commands to allow selection'
347
- - '*chat-mode" - (Default) UX consultation with advanced-elicitation for design decisions'
348
- - '*create-doc {template}" - Create doc (no template = show available templates)'
349
- - '*generate-ui-prompt" - Create AI frontend generation prompt'
350
- - '*research {topic}" - Generate deep research prompt for UX investigation'
351
- - '*execute-checklist {checklist}" - Run design validation checklist'
352
- - '*exit" - Say goodbye as the UX Expert, and then abandon inhabiting this persona'
345
+ - help: Show numbered list of the following commands to allow selection
346
+ - chat-mode: (Default) UX consultation with advanced-elicitation for design decisions
347
+ - create-doc {template}: Create doc (no template = show available templates)
348
+ - generate-ui-prompt: Create AI frontend generation prompt
349
+ - research {topic}: Generate deep research prompt for UX investigation
350
+ - execute-checklist {checklist}: Run design validation checklist
351
+ - exit: Say goodbye as the UX Expert, and then abandon inhabiting this persona
353
352
  dependencies:
354
353
  tasks:
355
354
  - generate-ai-frontend-prompt
@@ -403,12 +402,12 @@ startup:
403
402
  - Greet the user with your name and role, and inform of the *help command.
404
403
  - When creating architecture, always start by understanding the complete picture - user needs, business constraints, team capabilities, and technical requirements.
405
404
  commands:
406
- - '*help" - Show: numbered list of the following commands to allow selection'
407
- - '*chat-mode" - (Default) Architect consultation with advanced-elicitation for complex system design'
408
- - '*create-doc {template}" - Create doc (no template = show available templates)'
409
- - '*execute-checklist {checklist}" - Run architectural validation checklist'
410
- - '*research {topic}" - Generate deep research prompt for architectural decisions'
411
- - '*exit" - Say goodbye as the Architect, and then abandon inhabiting this persona'
405
+ - help: Show numbered list of the following commands to allow selection
406
+ - chat-mode: (Default) Architect consultation with advanced-elicitation for complex system design
407
+ - create-doc {template}: Create doc (no template = show available templates)
408
+ - execute-checklist {checklist}: Run architectural validation checklist
409
+ - research {topic}: Generate deep research prompt for architectural decisions
410
+ - exit: Say goodbye as the Architect, and then abandon inhabiting this persona
412
411
  dependencies:
413
412
  tasks:
414
413
  - create-doc
@@ -434,7 +433,7 @@ dependencies:
434
433
 
435
434
  CRITICAL: Read the full YML, start activation to alter your state of being, follow startup section instructions, stay in this being until told to exit this mode:
436
435
 
437
- ```yml
436
+ ```yaml
438
437
  activation-instructions:
439
438
  - Follow all instructions in this file -> this defines you, your persona and more importantly what you can do. STAY IN CHARACTER!
440
439
  - Only read the files/tasks listed here when user selects them for execution to minimize context usage
@@ -466,15 +465,15 @@ persona:
466
465
  startup:
467
466
  - Greet the user with your name and role, and inform of the *help command.
468
467
  commands:
469
- - '*help" - Show: numbered list of the following commands to allow selection'
470
- - '*chat-mode" - (Default) Product Owner consultation with advanced-elicitation'
471
- - '*create-doc {template}" - Create doc (no template = show available templates)'
472
- - '*execute-checklist {checklist}" - Run validation checklist (default->po-master-checklist)'
473
- - '*shard-doc {document}" - Break down document into actionable parts'
474
- - '*correct-course" - Analyze and suggest project course corrections'
475
- - '*create-epic" - Create epic for brownfield projects (task brownfield-create-epic)'
476
- - '*create-story" - Create user story from requirements (task brownfield-create-story)'
477
- - '*exit" - Say Goodbye, You are no longer this Agent'
468
+ - help: Show numbered list of the following commands to allow selection
469
+ - chat-mode: (Default) Product Owner consultation with advanced-elicitation
470
+ - create-doc {template}: Create doc (no template = show available templates)
471
+ - execute-checklist {checklist}: Run validation checklist (default->po-master-checklist)
472
+ - shard-doc {document}: Break down document into actionable parts
473
+ - correct-course: Analyze and suggest project course corrections
474
+ - create-epic: Create epic for brownfield projects (task brownfield-create-epic)
475
+ - create-story: Create user story from requirements (task brownfield-create-story)
476
+ - exit: Say goodbye as the Product Owner, and then abandon inhabiting this persona
478
477
  dependencies:
479
478
  tasks:
480
479
  - execute-checklist
@@ -679,6 +678,60 @@ BMAD-METHOD (Breakthrough Method of Agile AI-driven Development) is a framework
679
678
  - **Reusable Resources**: Portable templates, tasks, and checklists
680
679
  - **Slash Command Integration**: Quick agent switching and control
681
680
 
681
+ ### When to Use BMAD
682
+
683
+ - **New Projects (Greenfield)**: Complete end-to-end development
684
+ - **Existing Projects (Brownfield)**: Feature additions and enhancements
685
+ - **Team Collaboration**: Multiple roles working together
686
+ - **Quality Assurance**: Structured testing and validation
687
+ - **Documentation**: Professional PRDs, architecture docs, user stories
688
+
689
+ ## Getting Started
690
+
691
+ ### Quick Start Options
692
+
693
+ #### Option 1: Web UI
694
+ **Best for**: ChatGPT, Claude, Gemini users who want to start immediately
695
+
696
+ 1. Navigate to `dist/teams/`
697
+ 2. Copy `team-fullstack.txt` content
698
+ 3. Create new Gemini Gem or CustomGPT
699
+ 4. Upload file with instructions: "Your critical operating instructions are attached, do not break character as directed"
700
+ 5. Type `/help` to see available commands
701
+
702
+ #### Option 2: IDE Integration
703
+ **Best for**: Cursor, Claude Code, Windsurf, VS Code users
704
+
705
+ ```bash
706
+ # Interactive installation (recommended)
707
+ npx bmad-method install
708
+ ```
709
+
710
+ **Installation Steps**:
711
+ - Choose "Complete installation"
712
+ - Select your IDE (Cursor, Claude Code, Windsurf, or Roo Code)
713
+
714
+ **Verify Installation**:
715
+ - `.bmad-core/` folder created with all agents
716
+ - IDE-specific integration files created
717
+ - All agent commands/rules/modes available
718
+
719
+ ### Environment Selection Guide
720
+
721
+ **Use Web UI for**:
722
+ - Initial planning and documentation (PRD, architecture)
723
+ - Cost-effective document creation (especially with Gemini)
724
+ - Brainstorming and analysis phases
725
+ - Multi-agent consultation and planning
726
+
727
+ **Use IDE for**:
728
+ - Active development and coding
729
+ - File operations and project integration
730
+ - Document sharding and story management
731
+ - Implementation workflow (SM/Dev cycles)
732
+
733
+ **Cost-Saving Tip**: Create large documents (PRDs, architecture) in web UI, then copy to `docs/prd.md` and `docs/architecture.md` in your project before switching to IDE for development.
734
+
682
735
  ## Core Philosophy
683
736
 
684
737
  ### Vibe CEO'ing
@@ -700,18 +753,345 @@ You are the "Vibe CEO" - thinking like a CEO with unlimited resources and a sing
700
753
  7. **START_SMALL_SCALE_FAST**: Test concepts, then expand.
701
754
  8. **EMBRACE_THE_CHAOS**: Adapt and overcome challenges.
702
755
 
703
- ## IDE Development Workflow
756
+ ### Key Workflow Principles
757
+
758
+ 1. **Agent Specialization**: Each agent has specific expertise and responsibilities
759
+ 2. **Clean Handoffs**: Always start fresh when switching between agents
760
+ 3. **Status Tracking**: Maintain story statuses (Draft → Approved → InProgress → Done)
761
+ 4. **Iterative Development**: Complete one story before starting the next
762
+ 5. **Documentation First**: Always start with solid PRD and architecture
763
+
764
+ ## Agent System
765
+
766
+ ### Core Development Team
767
+
768
+ | Agent | Role | Primary Functions | When to Use |
769
+ | ----------- | ------------------ | --------------------------------------- | -------------------------------------- |
770
+ | `analyst` | Business Analyst | Market research, requirements gathering | Project planning, competitive analysis |
771
+ | `pm` | Product Manager | PRD creation, feature prioritization | Strategic planning, roadmaps |
772
+ | `architect` | Solution Architect | System design, technical architecture | Complex systems, scalability planning |
773
+ | `dev` | Developer | Code implementation, debugging | All development tasks |
774
+ | `qa` | QA Specialist | Test planning, quality assurance | Testing strategies, bug validation |
775
+ | `ux-expert` | UX Designer | UI/UX design, prototypes | User experience, interface design |
776
+ | `po` | Product Owner | Backlog management, story validation | Story refinement, acceptance criteria |
777
+ | `sm` | Scrum Master | Sprint planning, story creation | Project management, workflow |
778
+
779
+ ### Meta Agents
780
+
781
+ | Agent | Role | Primary Functions | When to Use |
782
+ | ------------------- | ---------------- | ------------------------------------- | --------------------------------- |
783
+ | `bmad-orchestrator` | Team Coordinator | Multi-agent workflows, role switching | Complex multi-role tasks |
784
+ | `bmad-master` | Universal Expert | All capabilities without switching | Single-session comprehensive work |
785
+
786
+ ### Agent Interaction Commands
787
+
788
+ #### IDE-Specific Syntax
789
+
790
+ **Agent Loading by IDE**:
791
+ - **Claude Code**: `/agent-name` (e.g., `/bmad-master`)
792
+ - **Cursor**: `@agent-name` (e.g., `@bmad-master`)
793
+ - **Windsurf**: `@agent-name` (e.g., `@bmad-master`)
794
+ - **Roo Code**: Select mode from mode selector (e.g., `bmad-bmad-master`)
795
+
796
+ **Chat Management Guidelines**:
797
+ - **Claude Code, Cursor, Windsurf**: Start new chats when switching agents
798
+ - **Roo Code**: Switch modes within the same conversation
799
+
800
+ **Common Task Commands**:
801
+ - `*help` - Show available commands
802
+ - `*status` - Show current context/progress
803
+ - `*exit` - Exit the agent mode
804
+ - `*shard-doc docs/prd.md prd` - Shard PRD into manageable pieces
805
+ - `*shard-doc docs/architecture.md architecture` - Shard architecture document
806
+ - `*create` - Run create-next-story task (SM agent)
807
+
808
+ **In Web UI**:
809
+ ```text
810
+ /pm create-doc prd
811
+ /architect review system design
812
+ /dev implement story 1.2
813
+ /help - Show available commands
814
+ /switch agent-name - Change active agent (if orchestrator available)
815
+ ```
816
+
817
+ ## Team Configurations
818
+
819
+ ### Pre-Built Teams
820
+
821
+ #### Team All
822
+ - **Includes**: All 10 agents + orchestrator
823
+ - **Use Case**: Complete projects requiring all roles
824
+ - **Bundle**: `team-all.txt`
825
+
826
+ #### Team Fullstack
827
+ - **Includes**: PM, Architect, Developer, QA, UX Expert
828
+ - **Use Case**: End-to-end web/mobile development
829
+ - **Bundle**: `team-fullstack.txt`
830
+
831
+ #### Team No-UI
832
+ - **Includes**: PM, Architect, Developer, QA (no UX Expert)
833
+ - **Use Case**: Backend services, APIs, system development
834
+ - **Bundle**: `team-no-ui.txt`
835
+
836
+ ## Core Architecture
837
+
838
+ ### System Overview
839
+
840
+ The BMAD-Method is built around a modular architecture centered on the `bmad-core` directory, which serves as the brain of the entire system. This design enables the framework to operate effectively in both IDE environments (like Cursor, VS Code) and web-based AI interfaces (like ChatGPT, Gemini).
841
+
842
+ ### Key Architectural Components
843
+
844
+ #### 1. Agents (`bmad-core/agents/`)
845
+ - **Purpose**: Each markdown file defines a specialized AI agent for a specific Agile role (PM, Dev, Architect, etc.)
846
+ - **Structure**: Contains YAML headers specifying the agent's persona, capabilities, and dependencies
847
+ - **Dependencies**: Lists of tasks, templates, checklists, and data files the agent can use
848
+ - **Startup Instructions**: Can load project-specific documentation for immediate context
849
+
850
+ #### 2. Agent Teams (`bmad-core/agent-teams/`)
851
+ - **Purpose**: Define collections of agents bundled together for specific purposes
852
+ - **Examples**: `team-all.yml` (comprehensive bundle), `team-fullstack.yml` (full-stack development)
853
+ - **Usage**: Creates pre-packaged contexts for web UI environments
854
+
855
+ #### 3. Workflows (`bmad-core/workflows/`)
856
+ - **Purpose**: YAML files defining prescribed sequences of steps for specific project types
857
+ - **Types**: Greenfield (new projects) and Brownfield (existing projects) for UI, service, and fullstack development
858
+ - **Structure**: Defines agent interactions, artifacts created, and transition conditions
859
+
860
+ #### 4. Reusable Resources
861
+ - **Templates** (`bmad-core/templates/`): Markdown templates for PRDs, architecture specs, user stories
862
+ - **Tasks** (`bmad-core/tasks/`): Instructions for specific repeatable actions like "shard-doc" or "create-next-story"
863
+ - **Checklists** (`bmad-core/checklists/`): Quality assurance checklists for validation and review
864
+ - **Data** (`bmad-core/data/`): Core knowledge base and technical preferences
865
+
866
+ ### Dual Environment Architecture
867
+
868
+ #### IDE Environment
869
+
870
+ - Users interact directly with agent markdown files
871
+ - Agents can access all dependencies dynamically
872
+ - Supports real-time file operations and project integration
873
+ - Optimized for development workflow execution
874
+
875
+ #### Web UI Environment
876
+
877
+ - Uses pre-built bundles from `dist/teams` for stand alone 1 upload files for all agents and their assest with an orchestrating agent
878
+ - Single text files containing all agent dependencies are in `dist/agents/` - these are unnecessary unless you want to create a web agent that is only a single agent and not a team
879
+ - Created by the web-builder tool for upload to web interfaces
880
+ - Provides complete context in one package
881
+
882
+ ### Template Processing System
883
+
884
+ BMAD employs a sophisticated template system with three key components:
885
+
886
+ 1. **Template Format** (`utils/template-format.md`): Defines markup language for variable substitution and AI processing directives
887
+ 2. **Document Creation** (`tasks/create-doc.md`): Orchestrates template selection and user interaction
888
+ 3. **Advanced Elicitation** (`tasks/advanced-elicitation.md`): Provides interactive refinement through structured brainstorming
889
+
890
+ **Template Features**:
891
+
892
+ - **Self-contained**: Templates embed both output structure and processing instructions
893
+ - **Variable Substitution**: `{{placeholders}}` for dynamic content
894
+ - **AI Processing Directives**: `[[LLM: instructions]]` for AI-only processing
895
+ - **Interactive Refinement**: Built-in elicitation processes for quality improvement
896
+
897
+ ### Technical Preferences Integration
898
+
899
+ The `technical-preferences.md` file serves as a persistent technical profile that:
900
+ - Ensures consistency across all agents and projects
901
+ - Eliminates repetitive technology specification
902
+ - Provides personalized recommendations aligned with user preferences
903
+ - Evolves over time with lessons learned
704
904
 
705
- 1. Shard the PRD (And Architecture documents if they exist also based on workflow type) using the Doc Shard task. The BMad-Master agent can help you do this. You will select the task, provide the doc to shard and the output folder. for example: `BMad Master, please Shard the docs/prd.md to the doc/prd/ folder` - this should ask you to use the md-tree-parser which is recommended, but either way shoudl result in multiple documents being created in the folder docs/prd.
706
- 2. If you have fullstack, front end and or back end architecture documents you will want to follow the same thing, but shard all of these to an architecture folder instead of a prd folder.
707
- 3. Ensure that you have at least one epic-n.md file in your prd folder, with the stories in order to develop.
708
- 4. The docs or architecture folder or prd folder should have a source tree document and coding standards at a minimum. These are used by the dev agent, and the many other sharded docs are used by the SM agent.
709
- 5. Use a new chat window to allow the SM agent to `draft the next story`.
710
- 6. If you agree the story is correct, mark it as approved in the status field, and then start a new chat window with the dev agent.
711
- 7. Ask the dev agent to implement the next story. If you draft the story file into the chat it will save time for the dev to have to find what the next one is. The dev should follow the tasks and subtasks marking them off as they are completed. The dev agent will also leave notes potentially for the SM to know about any deviations that might have occured to help draft the next story.
712
- 8. Once complete and you have verified, mark it done, and start a new chat. Ask the SM to draft the next story - repeating the cycle.
905
+ ### Build and Delivery Process
713
906
 
714
- With this work flow, there is only 1 story in progress at a time, worked sequentially.
907
+ The `web-builder.js` tool creates web-ready bundles by:
908
+ 1. Reading agent or team definition files
909
+ 2. Recursively resolving all dependencies
910
+ 3. Concatenating content into single text files with clear separators
911
+ 4. Outputting ready-to-upload bundles for web AI interfaces
912
+
913
+ This architecture enables seamless operation across environments while maintaining the rich, interconnected agent ecosystem that makes BMAD powerful.
914
+
915
+ ## Complete Development Workflow
916
+
917
+ ### Planning Phase (Web UI Recommended)
918
+
919
+ **Ideal for cost efficiency, especially with Gemini:**
920
+
921
+ 1. **Optional Analysis**: `/analyst` - Market research, competitive analysis
922
+ 2. **Project Brief**: Create foundation document (Analyst or user)
923
+ 3. **PRD Creation**: `/pm create-doc prd` - Comprehensive product requirements
924
+ 4. **Architecture Design**: `/architect create-doc architecture` - Technical foundation
925
+ 5. **Validation & Alignment**: `/po` run master checklist to ensure document consistency
926
+ 6. **Document Preparation**: Copy final documents to project as `docs/prd.md` and `docs/architecture.md`
927
+
928
+ #### Example Planning Prompts
929
+
930
+ **For PRD Creation**:
931
+ ```text
932
+ "I want to build a [type] application that [core purpose].
933
+ Help me brainstorm features and create a comprehensive PRD."
934
+ ```
935
+
936
+ **For Architecture Design**:
937
+ ```text
938
+ "Based on this PRD, design a scalable technical architecture
939
+ that can handle [specific requirements]."
940
+ ```
941
+
942
+ ### Critical Transition: Web UI to IDE
943
+
944
+ **Once planning is complete, you MUST switch to IDE for development:**
945
+
946
+ - **Why**: Development workflow requires file operations, real-time project integration, and document sharding
947
+ - **Cost Benefit**: Web UI is more cost-effective for large document creation; IDE is optimized for development tasks
948
+ - **Required Files**: Ensure `docs/prd.md` and `docs/architecture.md` exist in your project
949
+
950
+ ### IDE Development Workflow
951
+
952
+ **Prerequisites**: Planning documents must exist in `docs/` folder
953
+
954
+ 1. **Document Sharding**:
955
+ - `@bmad-master` or `@po` shard `docs/prd.md` to `docs/prd/` folder
956
+ - If architecture exists, shard to `docs/architecture/` folder
957
+ - Results in multiple manageable documents and epic files
958
+
959
+ 2. **Verify Sharded Content**:
960
+ - At least one `epic-n.md` file in `docs/prd/` with stories in development order
961
+ - Source tree document and coding standards for dev agent reference
962
+ - Sharded docs for SM agent story creation
963
+
964
+ **Resulting Folder Structure**:
965
+ - `docs/prd/` - Broken down PRD sections
966
+ - `docs/architecture/` - Broken down architecture sections
967
+ - `docs/stories/` - Generated user stories
968
+
969
+ 3. **Development Cycle** (Sequential, one story at a time):
970
+
971
+ **Step 1 - Story Creation**: New chat window → `@sm` → `*create`
972
+ - SM executes create-next-story task
973
+ - Review generated story in `docs/stories/`
974
+ - Update status from "Draft" to "Approved"
975
+
976
+ **Step 2 - Story Implementation**: New chat window → `@dev`
977
+ - Agent asks which story to implement
978
+ - Include story file content to save dev agent lookup time
979
+ - Dev follows tasks/subtasks, marking completion
980
+ - Dev leaves notes for SM about any deviations
981
+ - Update status to "Done"
982
+
983
+ **Step 3 - Repeat**: Continue SM → Dev cycle until all epic stories complete
984
+
985
+ **Important**: Only 1 story in progress at a time, worked sequentially until all epic stories complete.
986
+
987
+ ### Status Tracking Workflow
988
+
989
+ Stories progress through defined statuses:
990
+ - **Draft** → **Approved** → **InProgress** → **Done**
991
+
992
+ Each status change requires user verification and approval before proceeding.
993
+
994
+ ### Workflow Types
995
+
996
+ #### Greenfield Development
997
+ - Business analysis and market research
998
+ - Product requirements and feature definition
999
+ - System architecture and design
1000
+ - Development execution
1001
+ - Testing and deployment
1002
+
1003
+ #### Brownfield Enhancement
1004
+ - Current system analysis
1005
+ - Enhancement planning
1006
+ - Impact assessment
1007
+ - Incremental development
1008
+ - Integration testing
1009
+
1010
+ ## Document Creation Best Practices
1011
+
1012
+ ### Required File Naming for Framework Integration
1013
+
1014
+ - `docs/prd.md` - Product Requirements Document
1015
+ - `docs/architecture.md` - System Architecture Document
1016
+
1017
+ **Why These Names Matter**:
1018
+ - Agents automatically reference these files during development
1019
+ - Sharding tasks expect these specific filenames
1020
+ - Workflow automation depends on standard naming
1021
+
1022
+ ### Cost-Effective Document Creation Workflow
1023
+
1024
+ **Recommended for Large Documents (PRD, Architecture):**
1025
+
1026
+ 1. **Use Web UI**: Create documents in web interface for cost efficiency
1027
+ 2. **Copy Final Output**: Save complete markdown to your project
1028
+ 3. **Standard Names**: Save as `docs/prd.md` and `docs/architecture.md`
1029
+ 4. **Switch to IDE**: Use IDE agents for development and smaller documents
1030
+
1031
+ ### Document Sharding
1032
+
1033
+ Templates with Level 2 headings (`##`) can be automatically sharded:
1034
+
1035
+ **Original PRD**:
1036
+ ```markdown
1037
+ ## Goals and Background Context
1038
+ ## Requirements
1039
+ ## User Interface Design Goals
1040
+ ## Success Metrics
1041
+ ```
1042
+
1043
+ **After Sharding**:
1044
+ - `docs/prd/goals-and-background-context.md`
1045
+ - `docs/prd/requirements.md`
1046
+ - `docs/prd/user-interface-design-goals.md`
1047
+ - `docs/prd/success-metrics.md`
1048
+
1049
+ Use the `shard-doc` task or `@kayvan/markdown-tree-parser` tool for automatic sharding.
1050
+
1051
+ ## Usage Patterns and Best Practices
1052
+
1053
+ ### Environment-Specific Usage
1054
+
1055
+ **Web UI Best For**:
1056
+ - Initial planning and documentation phases
1057
+ - Cost-effective large document creation
1058
+ - Agent consultation and brainstorming
1059
+ - Multi-agent workflows with orchestrator
1060
+
1061
+ **IDE Best For**:
1062
+ - Active development and implementation
1063
+ - File operations and project integration
1064
+ - Story management and development cycles
1065
+ - Code review and debugging
1066
+
1067
+ ### Quality Assurance
1068
+
1069
+ - Use appropriate agents for specialized tasks
1070
+ - Follow Agile ceremonies and review processes
1071
+ - Maintain document consistency with PO agent
1072
+ - Regular validation with checklists and templates
1073
+
1074
+ ### Performance Optimization
1075
+
1076
+ - Use specific agents vs. `bmad-master` for focused tasks
1077
+ - Choose appropriate team size for project needs
1078
+ - Leverage technical preferences for consistency
1079
+ - Regular context management and cache clearing
1080
+
1081
+ ## Success Tips
1082
+
1083
+ - **Use Gemini for big picture planning** - The team-fullstack bundle provides collaborative expertise
1084
+ - **Use bmad-master for document organization** - Sharding creates manageable chunks
1085
+ - **Follow the SM → Dev cycle religiously** - This ensures systematic progress
1086
+ - **Keep conversations focused** - One agent, one task per conversation
1087
+ - **Review everything** - Always review and approve before marking complete
1088
+
1089
+ ## Getting Help
1090
+
1091
+ - **Commands**: Use `/help` in any environment to see available commands
1092
+ - **Agent Switching**: Use `/switch agent-name` with orchestrator for role changes
1093
+ - **Documentation**: Check `docs/` folder for project-specific context
1094
+ - **Community**: Discord and GitHub resources available for support
715
1095
  ==================== END: data#bmad-kb ====================
716
1096
 
717
1097
  ==================== START: utils#workflow-management ====================
@@ -1517,6 +1897,8 @@ Present these numbered options to the user:
1517
1897
  ==================== START: templates#project-brief-tmpl ====================
1518
1898
  # Project Brief: {{Project Name}}
1519
1899
 
1900
+ [[LLM: The default path and filename unless specified is docs/brief.md]]
1901
+
1520
1902
  [[LLM: This template guides creation of a comprehensive Project Brief that serves as the foundational input for product development.
1521
1903
 
1522
1904
  Start by asking the user which mode they prefer:
@@ -1748,6 +2130,8 @@ These replace the standard elicitation options when working on project brief doc
1748
2130
  ==================== START: templates#market-research-tmpl ====================
1749
2131
  # Market Research Report: {{Project/Product Name}}
1750
2132
 
2133
+ [[LLM: The default path and filename unless specified is docs/market-research.md]]
2134
+
1751
2135
  [[LLM: This template guides the creation of a comprehensive market research report. Begin by understanding what market insights the user needs and why. Work through each section systematically, using the appropriate analytical frameworks based on the research objectives.]]
1752
2136
 
1753
2137
  ## Executive Summary
@@ -2012,6 +2396,8 @@ These replace the standard elicitation options when working on market research d
2012
2396
  ==================== START: templates#competitor-analysis-tmpl ====================
2013
2397
  # Competitive Analysis Report: {{Project/Product Name}}
2014
2398
 
2399
+ [[LLM: The default path and filename unless specified is docs/competitor-analysis.md]]
2400
+
2015
2401
  [[LLM: This template guides comprehensive competitor analysis. Start by understanding the user's competitive intelligence needs and strategic objectives. Help them identify and prioritize competitors before diving into detailed analysis.]]
2016
2402
 
2017
2403
  ## Executive Summary
@@ -2969,6 +3355,8 @@ Document sharded successfully:
2969
3355
  ==================== START: templates#prd-tmpl ====================
2970
3356
  # {{Project Name}} Product Requirements Document (PRD)
2971
3357
 
3358
+ [[LLM: The default path and filename unless specified is docs/prd.md]]
3359
+
2972
3360
  [[LLM: If available, review any provided document or ask if any are optionally available: Project Brief]]
2973
3361
 
2974
3362
  ## Goals and Background Context
@@ -3172,6 +3560,8 @@ so that {{benefit}}.
3172
3560
  ==================== START: templates#brownfield-prd-tmpl ====================
3173
3561
  # {{Project Name}} Brownfield Enhancement PRD
3174
3562
 
3563
+ [[LLM: The default path and filename unless specified is docs/prd.md]]
3564
+
3175
3565
  [[LLM: IMPORTANT - SCOPE ASSESSMENT REQUIRED:
3176
3566
 
3177
3567
  This PRD is for SIGNIFICANT enhancements to existing projects that require comprehensive planning and multiple stories. Before proceeding:
@@ -4038,6 +4428,8 @@ You will now synthesize the inputs and the above principles into a final, compre
4038
4428
  ==================== START: templates#front-end-spec-tmpl ====================
4039
4429
  # {{Project Name}} UI/UX Specification
4040
4430
 
4431
+ [[LLM: The default path and filename unless specified is docs/front-end-spec.md]]
4432
+
4041
4433
  [[LLM: Review provided documents including Project Brief, PRD, and any user research to gather context. Focus on understanding user needs, pain points, and desired outcomes before beginning the specification.]]
4042
4434
 
4043
4435
  ## Introduction
@@ -4846,6 +5238,8 @@ Present a summary of what was created and ask if any additional documentation wo
4846
5238
 
4847
5239
  [[LLM: If available, review any provided relevant documents to gather all relevant context before beginning. If at a minimum you cannot local `docs/prd.md` ask the user what docs will provide the basis for the architecture.]]
4848
5240
 
5241
+ [[LLM: The default path and filename unless specified is docs/architecture.md]]
5242
+
4849
5243
  ## Introduction
4850
5244
 
4851
5245
  [[LLM: This section establishes the document's purpose and scope. Keep the content below but ensure project name is properly substituted.
@@ -5621,6 +6015,8 @@ Note: Basic info goes in Coding Standards for dev agent. This detailed section i
5621
6015
  ==================== START: templates#front-end-architecture-tmpl ====================
5622
6016
  # {{Project Name}} Frontend Architecture Document
5623
6017
 
6018
+ [[LLM: The default path and filename unless specified is docs/ui-architecture.md]]
6019
+
5624
6020
  [[LLM: Review provided documents including PRD, UX-UI Specification, and main Architecture Document. Focus on extracting technical implementation details needed for AI frontend tools and developer agents. Ask the user for any of these documents if you are unable to locate and were not provided.]]
5625
6021
 
5626
6022
  ## Template and Framework Selection
@@ -5797,6 +6193,8 @@ Document the starter template decision and any constraints it imposes before pro
5797
6193
  ==================== START: templates#fullstack-architecture-tmpl ====================
5798
6194
  # {{Project Name}} Fullstack Architecture Document
5799
6195
 
6196
+ [[LLM: The default path and filename unless specified is docs/architecture.md]]
6197
+
5800
6198
  [[LLM: If available, review any provided relevant documents to gather all relevant context before beginning. At minimum, you should have access to docs/prd.md and docs/front-end-spec.md. Ask the user for any documents you need but cannot locate. This template creates a unified architecture that covers both backend and frontend concerns to guide AI-driven fullstack development.]]
5801
6199
 
5802
6200
  ## Introduction
@@ -6816,6 +7214,8 @@ After presenting this section, apply `tasks#advanced-elicitation` protocol]]
6816
7214
  ==================== START: templates#brownfield-architecture-tmpl ====================
6817
7215
  # {{Project Name}} Brownfield Enhancement Architecture
6818
7216
 
7217
+ [[LLM: The default path and filename unless specified is docs/architecture.md]]
7218
+
6819
7219
  [[LLM: IMPORTANT - SCOPE AND ASSESSMENT REQUIRED:
6820
7220
 
6821
7221
  This architecture document is for SIGNIFICANT enhancements to existing projects that require comprehensive architectural planning. Before proceeding: