workflow references to moved workflow status workflow

This commit is contained in:
Brian Madison
2025-10-17 22:34:21 -05:00
parent af8e296e6f
commit b54bb9e47d
82 changed files with 55487 additions and 624 deletions

View File

@@ -0,0 +1,177 @@
# Workflow Status Service - Integration Examples
## How Other Workflows Can Use the Enhanced workflow-status Service
### Example 1: Simple Validation (product-brief workflow)
Replace the old Step 0:
```xml
<!-- OLD WAY - 35+ lines of duplicate code -->
<step n="0" goal="Check and load workflow status file">
<action>Search {output_folder}/ for files matching pattern: bmm-workflow-status.md</action>
<action>Find the most recent file...</action>
<!-- ... 30+ more lines of checking logic ... -->
</step>
```
With the new service call:
```xml
<!-- NEW WAY - Clean and simple -->
<step n="0" goal="Validate workflow readiness">
<invoke-workflow path="{project-root}/bmad/bmm/workflows/workflow-status">
<param>mode: validate</param>
<param>calling_workflow: product-brief</param>
</invoke-workflow>
<check if="status_exists == false">
<output>{{suggestion}}</output>
<output>Note: Status tracking is optional. You can continue without it.</output>
</check>
<check if="warning != ''">
<output>{{warning}}</output>
<ask>Continue anyway? (y/n)</ask>
<check if="n">
<action>Exit workflow</action>
</check>
</check>
<action>Store {{status_file_path}} for later updates if needed</action>
</step>
```
### Example 2: Getting Story Data (create-story workflow)
Replace the complex Step 2.5:
```xml
<!-- OLD WAY - Complex parsing logic -->
<step n="2.5" goal="Check status file TODO section for story to draft">
<action>Read {output_folder}/bmm-workflow-status.md (if exists)</action>
<action>Navigate to "### Implementation Progress (Phase 4 Only)" section</action>
<action>Find "#### TODO (Needs Drafting)" section</action>
<!-- ... 40+ lines of parsing and extraction ... -->
</step>
```
With the new service call:
```xml
<!-- NEW WAY - Let workflow-status handle the complexity -->
<step n="2.5" goal="Get next story to draft">
<invoke-workflow path="{project-root}/bmad/bmm/workflows/workflow-status">
<param>mode: data</param>
<param>data_request: next_story</param>
</invoke-workflow>
<check if="status_exists == false">
<action>Fall back to legacy story discovery</action>
</check>
<check if="todo_story_id exists">
<action>Use {{todo_story_id}} as story to draft</action>
<action>Use {{todo_story_title}} for validation</action>
<action>Create file: {{todo_story_file}}</action>
<output>Drafting story {{todo_story_id}}: {{todo_story_title}}</output>
</check>
</step>
```
### Example 3: Getting Project Configuration (solution-architecture workflow)
```xml
<step n="0" goal="Load project configuration">
<invoke-workflow path="{project-root}/bmad/bmm/workflows/workflow-status">
<param>mode: data</param>
<param>data_request: project_config</param>
</invoke-workflow>
<check if="status_exists == false">
<ask>No status file. Run standalone or create status first?</ask>
</check>
<check if="status_exists == true">
<action>Use {{project_level}} to determine architecture complexity</action>
<action>Use {{project_type}} to select appropriate templates</action>
<action>Use {{field_type}} to know if brownfield constraints apply</action>
</check>
</step>
```
### Example 4: Quick Init Check (any workflow)
```xml
<step n="0" goal="Check if status exists">
<invoke-workflow path="{project-root}/bmad/bmm/workflows/workflow-status">
<param>mode: init-check</param>
</invoke-workflow>
<check if="status_exists == false">
<output>{{suggestion}}</output>
<output>Proceeding without status tracking...</output>
</check>
</step>
```
## Benefits of This Approach
1. **DRY Principle**: No more duplicating status check logic across 50+ workflows
2. **Centralized Logic**: Bug fixes and improvements happen in one place
3. **Backward Compatible**: Old workflows continue to work, can migrate gradually
4. **Advisory Not Blocking**: Workflows can proceed even without status file
5. **Flexible Data Access**: Get just what you need (next_story, project_config, etc.)
6. **Cleaner Workflows**: Focus on core logic, not status management
## Available Modes
### `validate` Mode
- **Purpose**: Check if this workflow should run
- **Returns**:
- `status_exists`: true/false
- `should_proceed`: true (always - advisory only)
- `warning`: Any sequence warnings
- `suggestion`: What to do
- `project_level`, `project_type`, `field_type`: For workflow decisions
- `status_file_path`: For later updates
### `data` Mode
- **Purpose**: Extract specific information
- **Parameters**: `data_request` = one of:
- `next_story`: Get TODO story details
- `project_config`: Get project configuration
- `phase_status`: Get phase completion status
- `all`: Get everything
- **Returns**: Requested fields as template outputs
### `init-check` Mode
- **Purpose**: Simple existence check
- **Returns**:
- `status_exists`: true/false
- `suggestion`: Brief message
### `interactive` Mode (default)
- **Purpose**: User-facing status check
- **Shows**: Current status, options menu
- **Returns**: User proceeds with selected action
## Migration Strategy
1. Start with high-value workflows that have complex Step 0s
2. Test with a few workflows first
3. Gradually migrate others as they're updated
4. Old workflows continue to work unchanged
## Next Steps
To integrate into your workflow:
1. Replace your Step 0 with appropriate service call
2. Remove duplicate status checking logic
3. Use returned values for workflow decisions
4. Update status file at completion (if status_exists == true)

View File

@@ -0,0 +1,238 @@
# Workflow Status System
The universal entry point for BMM workflows - answers "what should I do now?" for any agent.
## Overview
The workflow status system provides:
- **Smart project initialization** - Detects existing work and infers project details
- **Simple status tracking** - Key-value pairs for instant parsing
- **Intelligent routing** - Suggests next actions based on current state
- **Modular workflow paths** - Each project type/level has its own clean definition
## Architecture
### Core Components
```
workflow-status/
├── workflow.yaml # Main configuration
├── instructions.md # Status checker (99 lines)
├── workflow-status-template.md # Clean key-value template
├── project-levels.yaml # Source of truth for scale definitions
└── paths/ # Modular workflow definitions
├── greenfield-level-0.yaml through level-4.yaml
├── brownfield-level-0.yaml through level-4.yaml
└── game-design.yaml
```
### Related Workflow
```
workflow-init/
├── workflow.yaml # Initialization configuration
└── instructions.md # Smart setup (182 lines)
```
## How It Works
### For New Projects
1. User runs `workflow-status`
2. System finds no status file
3. Directs to `workflow-init`
4. Init workflow:
- Scans for existing work (PRDs, code, etc.)
- Infers project details from what it finds
- Asks minimal questions (name + description)
- Confirms understanding in one step
- Creates status file with workflow path
### For Existing Projects
1. User runs `workflow-status`
2. System reads status file
3. Shows current state and options:
- Continue in-progress work
- Next required step
- Available optional workflows
4. User picks action
## Status File Format
Simple key-value pairs for instant parsing:
```markdown
PROJECT_NAME: MyProject
PROJECT_TYPE: software
PROJECT_LEVEL: 2
FIELD_TYPE: greenfield
CURRENT_PHASE: 2-Planning
CURRENT_WORKFLOW: prd
TODO_STORY: story-1.2.md
IN_PROGRESS_STORY: story-1.1.md
NEXT_ACTION: Continue PRD
NEXT_COMMAND: prd
NEXT_AGENT: pm
```
Any agent can instantly grep what they need:
- SM: `grep 'TODO_STORY:' status.md`
- DEV: `grep 'IN_PROGRESS_STORY:' status.md`
- Any: `grep 'NEXT_ACTION:' status.md`
## Project Levels
Source of truth: `/src/modules/bmm/README.md` lines 77-85
- **Level 0**: Single atomic change (1 story)
- **Level 1**: Small feature (1-10 stories)
- **Level 2**: Medium project (5-15 stories)
- **Level 3**: Complex system (12-40 stories)
- **Level 4**: Enterprise scale (40+ stories)
## Workflow Paths
Each combination has its own file:
- `greenfield-level-X.yaml` - New projects at each level
- `brownfield-level-X.yaml` - Existing codebases at each level
- `game-design.yaml` - Game projects (all levels)
Benefits:
- Load only what's needed (60 lines vs 750+)
- Easy to maintain individual paths
- Clear separation of concerns
## Smart Detection
The init workflow intelligently detects:
**Project Type:**
- Finds GDD → game
- Otherwise → software
**Project Level:**
- Reads PRD epic/story counts
- Analyzes scope descriptions
- Makes educated guess
**Field Type:**
- Finds source code → brownfield
- Only planning docs → greenfield
- Checks git history age
**Documentation Status:**
- Finds index.md → was undocumented
- Good README → documented
- Missing docs → needs documentation
## Usage Examples
### Any Agent Checking Status
```
Agent: workflow-status
Result: "TODO: story-1.2.md, Next: create-story"
```
### New Project Setup
```
Agent: workflow-status
System: "No status found. Run workflow-init"
Agent: workflow-init
System: "Tell me about your project"
User: "Building a dashboard with user management"
System: "Level 2 greenfield software project. Correct?"
User: "Yes"
System: "Status created! Next: pm agent, run prd"
```
### Smart Inference
```
System finds: prd-dashboard.md with 3 epics
System finds: package.json, src/ directory
System infers: Level 2 brownfield software
User confirms or corrects
```
## Philosophy
**Less Structure, More Intelligence**
Instead of complex if/else logic:
- Trust the LLM to analyze and infer
- Use natural language for corrections
- Keep menus simple and contextual
- Let intelligence emerge from the model
**Result:** A workflow system that feels like talking to a smart assistant, not filling out a form.
## Implementation Details
### workflow-init (6 Steps)
1. **Scan for existing work** - Check for docs, code, git history
2. **Confirm findings** - Show what was detected (if anything)
3. **Gather info** - Name, description, confirm type/level/field
4. **Load path file** - Select appropriate workflow definition
5. **Generate workflow** - Build from path file
6. **Create status file** - Save and show next step
### workflow-status (4 Steps)
1. **Check for status file** - Direct to init if missing
2. **Parse status** - Extract key-value pairs
3. **Display options** - Show current, required, optional
4. **Handle selection** - Execute user's choice
## Best Practices
1. **Let the AI guess** - It's usually right, user corrects if needed
2. **One conversation** - Get all info in Step 3 of init
3. **Simple parsing** - Key-value pairs, not complex structures
4. **Modular paths** - Each scenario in its own file
5. **Trust intelligence** - LLM understands context better than rules
## Integration
Other workflows read the status to coordinate:
- `create-story` reads TODO_STORY
- `dev-story` reads IN_PROGRESS_STORY
- Any workflow can check CURRENT_PHASE
- All agents can ask "what should I do?"
The status file is the single source of truth for project state and the hub that keeps all agents synchronized.
## Benefits
**Smart Detection** - Infers from existing work instead of asking everything
**Minimal Questions** - Just name and description in most cases
**Clean Status** - Simple key-value pairs for instant parsing
**Modular Paths** - 60-line files instead of 750+ line monolith
**Natural Language** - "Tell me about your project" not "Pick 1-12"
**Intelligent Menus** - Shows only relevant options
**Fast Parsing** - Grep instead of complex logic
**Easy Maintenance** - Change one level without affecting others
## Future Enhancements
- Visual progress indicators
- Time tracking and estimates
- Multi-project support
- Team synchronization
---
**This workflow is the front door to BMad Method. Start here to know what to do next.**

View File

@@ -0,0 +1,175 @@
# Workflow Init - Project Setup Instructions
<critical>The workflow execution engine is governed by: {project-root}/bmad/core/tasks/workflow.xml</critical>
<critical>You MUST have already loaded and processed: workflow-init/workflow.yaml</critical>
<critical>Communicate in {communication_language} with {user_name}</critical>
<workflow>
<step n="1" goal="Scan for existing work">
<action>Search {output_folder}/ for existing BMM artifacts:</action>
- PRD files (*prd*.md)
- Architecture docs (architecture*.md, solution-architecture*.md, architecture/*)
- Briefs (*brief*.md)
- Brainstorming docs (brainstorm*.md)
- Research docs (*research*.md)
- Tech specs (tech-spec*.md)
- GDD files (gdd*.md)
- Story files (story-*.md)
- Epic files (epic*.md)
- Documentation files (index.md (and referenced files within), other files in docs or provided)
Check for existing codebase indicators:
- src/ or lib/ directories
- package.json, requirements.txt, go.mod, Cargo.toml, etc.
- .git directory (check git log for commit history age)
- README.md (check if it describes existing functionality)
- Test directories (tests/, **tests**/, spec/)
- Existing source files (_.js, _.py, _.go, _.rs, etc.)
<action>Also check config for existing {project_name} variable</action>
<check if="found existing artifacts">
<action>Analyze documents to infer project details</action>
<action>Guess project type (game vs software) from content</action>
<action>Estimate level based on scope:
- Level 0: Single atomic change (1 story)
- Level 1: Small feature (1-10 stories)
- Level 2: Medium project (5-15 stories)
- Level 3: Complex system (12-40 stories)
- Level 4: Enterprise scale (40+ stories)
</action>
<action>Detect if greenfield (only planning) or brownfield (has code)</action>
<action>Go to Step 2 (Confirm inferred settings)</action>
</check>
<check if="no artifacts found">
<action>Set fresh_start = true</action>
<action>Go to Step 3 (Gather project info)</action>
</check>
</step>
<step n="2" goal="Confirm inferred settings" if="found artifacts">
<output>📊 I found existing work! Here's what I detected:
**Project Name:** {{inferred_project_name}}
**Type:** {{inferred_type}}
**Complexity:** {{inferred_level_description}}
**Codebase:** {{inferred_field_type}}
**Current Phase:** {{current_phase}}
</output>
<ask>Is this correct?
1. **Yes** - Use these settings
2. **Start Fresh** - Ignore existing work
Or tell me what's different:</ask>
<check if="choice == 1">
<action>Use inferred settings</action>
<action>Go to Step 5 (Generate workflow)</action>
</check>
<check if="choice == 2">
<action>Set fresh_start = true</action>
<action>Go to Step 3 (Gather project info)</action>
</check>
<check if="user provides corrections">
<action>Update inferred values based on user input</action>
<action>Go to Step 5 (Generate workflow)</action>
</check>
<template-output>project_name</template-output>
<template-output>project_type</template-output>
<template-output>project_level</template-output>
<template-output>field_type</template-output>
</step>
<step n="3" goal="Gather project info">
<output>Welcome to BMad Method, {user_name}!</output>
<ask>What's your project called? {{#if project_name}}(Config shows: {{project_name}}){{/if}}</ask>
<action>Set project_name</action>
<template-output>project_name</template-output>
<ask>Tell me about what you're building. What's the goal? are we adding on to something or starting fresh.</ask>
<action>Analyze description to determine project type, level, and field type</action>
<action>Set project_type (game or software)</action>
<action>Set project_level (0-4 based on complexity)</action>
<action>Set field_type (greenfield or brownfield based on description)</action>
<ask>Based on your description: Level {{project_level}} {{field_type}} {{project_type}} project.
Is that correct? (y/n or tell me what's different)</ask>
<check if="user corrects">
<action>Update values based on corrections</action>
</check>
<template-output>project_type</template-output>
<template-output>project_level</template-output>
<template-output>field_type</template-output>
</step>
<step n="4" goal="Load appropriate workflow path">
<action>Determine path file based on selections:</action>
<check if="project_type == game">
<action>Load {path_files}/game-design.yaml</action>
<action>Set workflow_path_file = "game-design.yaml"</action>
</check>
<check if="project_type == software">
<!-- field_type will be "greenfield" or "brownfield", project_level will be 0-4 -->
<action>Build filename: {field_type}-level-{project_level}.yaml</action>
<action>Load {path_files}/{field_type}-level-{project_level}.yaml</action>
<action>Set workflow_path_file = constructed filename</action>
</check>
<action>Parse workflow path file to extract phases and workflows</action>
<template-output>workflow_path_file</template-output>
</step>
<step n="5" goal="Generate workflow summary">
<action>Build workflow from loaded path file</action>
<action>Display phases and workflows</action>
<action>Set initial values for status file</action>
<template-output>current_phase</template-output>
<template-output>current_workflow</template-output>
<template-output>current_agent</template-output>
<template-output>next_action</template-output>
<template-output>next_command</template-output>
<template-output>next_agent</template-output>
</step>
<step n="6" goal="Create status file">
<action>Initialize all status values</action>
<template-output>start_date</template-output>
<template-output>last_updated</template-output>
<template-output>phase_1_complete</template-output>
<template-output>phase_2_complete</template-output>
<template-output>phase_3_complete</template-output>
<template-output>phase_4_complete</template-output>
<template-output>ordered_story_list = "[]"</template-output>
<template-output>todo_story</template-output>
<template-output>todo_title</template-output>
<template-output>in_progress_story</template-output>
<template-output>in_progress_title</template-output>
<template-output>completed_story_list = "[]"</template-output>
<template-output>backlog_count</template-output>
<template-output>done_count</template-output>
<template-output>total_stories</template-output>
<ask>Ready to create your workflow status file? (y/n)</ask>
<check if="answer == y">
<action>Save status file to {output_folder}/bmm-workflow-status.md</action>
<output>✅ Status file created! Next up: {{next_agent}} agent, run `{{next_command}}`</output>
</check>
</step>
</workflow>

View File

@@ -0,0 +1,25 @@
# Workflow Init - Initial Project Setup
name: workflow-init
description: "Initialize a new BMM project by determining level, type, and creating workflow path"
author: "BMad"
# Critical variables from config
config_source: "{project-root}/bmad/bmm/config.yaml"
output_folder: "{config_source}:output_folder"
user_name: "{config_source}:user_name"
project_name: "{config_source}:project_name"
communication_language: "{config_source}:communication_language"
document_output_language: "{config_source}:document_output_language"
user_skill_level: "{config_source}:user_skill_level"
date: system-generated
# Workflow components
installed_path: "{project-root}/bmad/bmm/workflows/workflow-status/init"
instructions: "{installed_path}/instructions.md"
template: "{project-root}/bmad/bmm/workflows/workflow-status/workflow-status-template.md"
# Path data files
path_files: "{project-root}/src/modules/bmm/workflows/workflow-status/paths/"
# Output configuration
default_output_file: "{output_folder}/bmm-workflow-status.md"

View File

@@ -0,0 +1,266 @@
# Workflow Status Check - Multi-Mode Service
<critical>The workflow execution engine is governed by: {project-root}/bmad/core/tasks/workflow.xml</critical>
<critical>You MUST have already loaded and processed: {project-root}/bmad/bmm/workflows/workflow-status/workflow.yaml</critical>
<critical>This workflow operates in multiple modes: interactive (default), validate, data, init-check</critical>
<critical>Other workflows can call this as a service to avoid duplicating status logic</critical>
<workflow>
<step n="0" goal="Determine execution mode">
<action>Check for {{mode}} parameter passed by calling workflow</action>
<action>Default mode = "interactive" if not specified</action>
<check if="mode == interactive">
<action>Continue to Step 1 for normal status check flow</action>
</check>
<check if="mode == validate">
<action>Jump to Step 10 for workflow validation service</action>
</check>
<check if="mode == data">
<action>Jump to Step 20 for data extraction service</action>
</check>
<check if="mode == init-check">
<action>Jump to Step 30 for simple init check</action>
</check>
</step>
<step n="1" goal="Check for status file">
<action>Search {output_folder}/ for file: bmm-workflow-status.md</action>
<check if="no status file found">
<output>No workflow status found. To get started:
Load analyst agent and run: `workflow-init`
This will guide you through project setup and create your workflow path.</output>
<action>Exit workflow</action>
</check>
<check if="status file found">
<action>Continue to step 2</action>
</check>
</step>
<step n="2" goal="Read and parse status">
<action>Read bmm-workflow-status.md</action>
<action>Extract key-value pairs from status file:</action>
Parse these fields:
- PROJECT_NAME
- PROJECT_TYPE
- PROJECT_LEVEL
- FIELD_TYPE
- CURRENT_PHASE
- CURRENT_WORKFLOW
- TODO_STORY
- IN_PROGRESS_STORY
- NEXT_ACTION
- NEXT_COMMAND
- NEXT_AGENT
</step>
<step n="3" goal="Display current status and options">
<action>Load workflow path file to check for optional steps</action>
<action>Check if current workflow is in progress or complete</action>
<output>
## 📊 Current Status
**Project:** {{PROJECT_NAME}} (Level {{PROJECT_LEVEL}} {{PROJECT_TYPE}})
**Phase:** {{CURRENT_PHASE}}
**Current Workflow:** {{CURRENT_WORKFLOW}}
{{#if CURRENT_PHASE == "4-Implementation"}}
**Development Queue:**
- TODO: {{TODO_STORY}} - {{TODO_TITLE}}
- IN PROGRESS: {{IN_PROGRESS_STORY}} - {{IN_PROGRESS_TITLE}}
{{/if}}
## 🎯 Your Options
{{#if CURRENT_WORKFLOW != "complete"}}
**Continue in progress:**
- {{CURRENT_WORKFLOW}} ({{CURRENT_AGENT}} agent)
{{/if}}
**Next required step:**
- Command: `{{NEXT_COMMAND}}`
- Agent: {{NEXT_AGENT}}
{{#if optional_workflows_available}}
**Optional workflows available:**
{{#each optional_workflows}}
- {{workflow_name}} ({{agent}})
{{/each}}
{{/if}}
</output>
</step>
<step n="4" goal="Offer actions">
<ask>What would you like to do?
{{#if CURRENT_WORKFLOW != "complete"}}
1. **Continue current** - Resume {{CURRENT_WORKFLOW}}
{{/if}}
2. **Next required** - {{NEXT_COMMAND}}
{{#if optional_workflows_available}}
3. **Optional workflow** - Choose from available options
{{/if}}
4. **View full status** - See complete status file
5. **Exit** - Return to agent
Your choice:</ask>
<action>Handle user selection based on available options</action>
</step>
<!-- ============================================= -->
<!-- SERVICE MODES - Called by other workflows -->
<!-- ============================================= -->
<step n="10" goal="Validate mode - Check if calling workflow should proceed">
<action>Read {output_folder}/bmm-workflow-status.md if exists</action>
<check if="status file not found">
<template-output>status_exists = false</template-output>
<template-output>should_proceed = true</template-output>
<template-output>warning = "No status file found. Running without progress tracking."</template-output>
<template-output>suggestion = "Consider running workflow-init first for progress tracking"</template-output>
<action>Return to calling workflow</action>
</check>
<check if="status file found">
<action>Parse status file fields</action>
<action>Load workflow path file from WORKFLOW_PATH field</action>
<action>Check if {{calling_workflow}} matches CURRENT_WORKFLOW or NEXT_COMMAND</action>
<template-output>status_exists = true</template-output>
<template-output>current_phase = {{CURRENT_PHASE}}</template-output>
<template-output>current_workflow = {{CURRENT_WORKFLOW}}</template-output>
<template-output>next_workflow = {{NEXT_COMMAND}}</template-output>
<template-output>project_level = {{PROJECT_LEVEL}}</template-output>
<template-output>project_type = {{PROJECT_TYPE}}</template-output>
<template-output>field_type = {{FIELD_TYPE}}</template-output>
<check if="calling_workflow == current_workflow">
<template-output>should_proceed = true</template-output>
<template-output>warning = ""</template-output>
<template-output>suggestion = "Resuming {{current_workflow}}"</template-output>
</check>
<check if="calling_workflow == next_workflow">
<template-output>should_proceed = true</template-output>
<template-output>warning = ""</template-output>
<template-output>suggestion = "Proceeding with planned next step"</template-output>
</check>
<check if="calling_workflow != current_workflow AND calling_workflow != next_workflow">
<action>Check if calling_workflow is in optional workflows list</action>
<check if="is optional">
<template-output>should_proceed = true</template-output>
<template-output>warning = "Running optional workflow {{calling_workflow}}"</template-output>
<template-output>suggestion = "This is optional. Expected next: {{next_workflow}}"</template-output>
</check>
<check if="not optional">
<template-output>should_proceed = true</template-output>
<template-output>warning = "⚠️ Out of sequence: Expected {{next_workflow}}, running {{calling_workflow}}"</template-output>
<template-output>suggestion = "Consider running {{next_workflow}} instead, or continue if intentional"</template-output>
</check>
</check>
<template-output>status_file_path = {{path to bmm-workflow-status.md}}</template-output>
</check>
<action>Return control to calling workflow with all template outputs</action>
</step>
<step n="20" goal="Data mode - Extract specific information">
<action>Read {output_folder}/bmm-workflow-status.md if exists</action>
<check if="status file not found">
<template-output>status_exists = false</template-output>
<template-output>error = "No status file to extract data from"</template-output>
<action>Return to calling workflow</action>
</check>
<check if="status file found">
<action>Parse status file completely</action>
<template-output>status_exists = true</template-output>
<check if="data_request == next_story">
<action>Extract from Development Queue section</action>
<template-output>todo_story_id = {{TODO_STORY}}</template-output>
<template-output>todo_story_title = {{TODO_TITLE}}</template-output>
<template-output>in_progress_story = {{IN_PROGRESS_STORY}}</template-output>
<template-output>stories_sequence = {{STORIES_SEQUENCE}}</template-output>
<template-output>stories_done = {{STORIES_DONE}}</template-output>
<action>Determine story file path based on ID format</action>
<check if='todo_story_id matches "N.M" format'>
<template-output>todo_story_file = "story-{{N}}.{{M}}.md"</template-output>
</check>
<check if='todo_story_id matches "slug-N" format'>
<template-output>todo_story_file = "story-{{slug}}-{{N}}.md"</template-output>
</check>
<check if='todo_story_id matches "slug" format'>
<template-output>todo_story_file = "story-{{slug}}.md"</template-output>
</check>
</check>
<check if="data_request == project_config">
<template-output>project_name = {{PROJECT_NAME}}</template-output>
<template-output>project_type = {{PROJECT_TYPE}}</template-output>
<template-output>project_level = {{PROJECT_LEVEL}}</template-output>
<template-output>field_type = {{FIELD_TYPE}}</template-output>
<template-output>workflow_path = {{WORKFLOW_PATH}}</template-output>
</check>
<check if="data_request == phase_status">
<template-output>current_phase = {{CURRENT_PHASE}}</template-output>
<template-output>phase_1_complete = {{PHASE_1_COMPLETE}}</template-output>
<template-output>phase_2_complete = {{PHASE_2_COMPLETE}}</template-output>
<template-output>phase_3_complete = {{PHASE_3_COMPLETE}}</template-output>
<template-output>phase_4_complete = {{PHASE_4_COMPLETE}}</template-output>
</check>
<check if="data_request == all">
<action>Return all parsed fields as template outputs</action>
</check>
<template-output>status_file_path = {{path to bmm-workflow-status.md}}</template-output>
</check>
<action>Return control to calling workflow with requested data</action>
</step>
<step n="30" goal="Init-check mode - Simple existence check">
<action>Check if {output_folder}/bmm-workflow-status.md exists</action>
<check if="exists">
<template-output>status_exists = true</template-output>
<template-output>suggestion = "Status file found. Ready to proceed."</template-output>
</check>
<check if="not exists">
<template-output>status_exists = false</template-output>
<template-output>suggestion = "No status file. Run workflow-init to create one (optional for progress tracking)"</template-output>
</check>
<action>Return immediately to calling workflow</action>
</step>
</workflow>

View File

@@ -0,0 +1,69 @@
# Brownfield Level 0 - Single Atomic Change in Existing Codebase
# One change to existing system
project_type: "software"
level: 0
field_type: "brownfield"
description: "Single atomic change to existing codebase"
phases:
- phase: 0
name: "Documentation"
conditional: "if_undocumented"
workflows:
- id: "document-project"
required: true
agent: "analyst"
command: "document-project"
output: "Codebase documentation"
- phase: 1
name: "Analysis"
optional: true
workflows:
- id: "brainstorm-project"
optional: true
agent: "analyst"
command: "brainstorm-project"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
output: "Creates single story file"
note: "Must understand existing patterns"
- phase: 3
name: "Solutioning"
skip: true
- phase: 4
name: "Implementation"
required: true
workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
note: "Include existing code context"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
story_naming: "story-<short-title>.md"
story_example: "story-fix-auth-bug.md"
max_stories: 1
brownfield_note: "Ensure changes align with existing patterns"

View File

@@ -0,0 +1,77 @@
# Brownfield Level 1 - Small Feature in Existing Codebase
# 1-10 stories adding to existing system
project_type: "software"
level: 1
field_type: "brownfield"
description: "Small feature addition to existing codebase"
phases:
- phase: 0
name: "Documentation"
conditional: "if_undocumented"
workflows:
- id: "document-project"
required: true
agent: "analyst"
command: "document-project"
output: "Codebase documentation"
- phase: 1
name: "Analysis"
optional: true
workflows:
- id: "brainstorm-project"
optional: true
agent: "analyst"
command: "brainstorm-project"
- id: "research"
optional: true
agent: "analyst"
command: "research"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
output: "Creates story files for feature"
note: "Must integrate with existing architecture"
- phase: 3
name: "Solutioning"
skip: true
- phase: 4
name: "Implementation"
required: true
workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
note: "Include existing code context"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "review-story"
optional: true
agent: "dev"
command: "review-story"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
story_naming: "story-<short-title>.md"
story_example: "story-add-auth.md, story-update-dashboard.md"
max_stories: 10
brownfield_note: "Ensure changes align with existing patterns and architecture"

View File

@@ -0,0 +1,95 @@
# Brownfield Level 2 - Medium Project in Existing Codebase
# 5-15 stories, multiple features added to existing system
project_type: "software"
level: 2
field_type: "brownfield"
description: "Medium project adding multiple features to existing codebase"
phases:
- phase: 0
name: "Documentation"
conditional: "if_undocumented"
workflows:
- id: "document-project"
required: true
agent: "analyst"
command: "document-project"
output: "Codebase documentation"
- phase: 1
name: "Analysis"
optional: true
workflows:
- id: "brainstorm-project"
optional: true
agent: "analyst"
command: "brainstorm-project"
- id: "research"
optional: true
agent: "analyst"
command: "research"
- id: "product-brief"
optional: true
agent: "analyst"
command: "product-brief"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "prd"
recommended: true
agent: "pm"
command: "prd"
output: "Focused PRD for new features"
note: "Must consider existing system constraints"
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
output: "Creates multiple story files"
note: "Integrate with existing patterns"
- id: "ux-spec"
conditional: "if_has_ui"
agent: "pm"
command: "ux-spec"
- phase: 3
name: "Solutioning"
skip: true
- phase: 4
name: "Implementation"
required: true
workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
note: "Include existing code context"
- id: "validate-story-context"
optional: true
agent: "sm"
command: "validate-story-context"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "review-story"
recommended: true
agent: "dev"
command: "review-story"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
story_naming: "story-<short-title>.md"
story_example: "story-user-dashboard.md, story-api-integration.md"
max_stories: 15
brownfield_note: "Balance new features with existing system stability"

View File

@@ -0,0 +1,135 @@
# Brownfield Level 3 - Complex Integration with Existing System
# Major feature addition requiring architectural integration
project_type: "software"
level: 3
field_type: "brownfield"
description: "Complex integration with existing system architecture"
phases:
- phase: 0
name: "Documentation"
conditional: "if_undocumented"
workflows:
- id: "document-project"
required: true
agent: "analyst"
command: "document-project"
output: "Comprehensive codebase documentation"
- phase: 1
name: "Analysis"
recommended: true
workflows:
- id: "brainstorm-project"
optional: true
agent: "analyst"
command: "brainstorm-project"
- id: "research"
recommended: true
agent: "analyst"
command: "research"
note: "Research existing architecture patterns"
- id: "product-brief"
recommended: true
agent: "analyst"
command: "product-brief"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "prd"
required: true
agent: "pm"
command: "prd"
output: "Requirements with integration points"
- id: "ux-spec"
conditional: "if_has_ui"
agent: "pm"
command: "ux-spec"
note: "Must align with existing UI patterns"
- phase: 3
name: "Solutioning"
required: true
workflows:
- id: "architecture-review"
required: true
agent: "architect"
command: "architecture-review"
note: "Review existing architecture first"
- id: "integration-planning"
required: true
agent: "architect"
command: "integration-planning"
output: "Integration strategy document"
- id: "solution-architecture"
required: true
agent: "architect"
command: "solution-architecture"
note: "Extension of existing architecture"
- id: "assess-project-ready"
required: true
agent: "sm"
command: "assess-project-ready"
- phase: 4
name: "Implementation"
required: true
epic_loop: "for_each_epic"
epic_workflows:
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
note: "Must respect existing patterns"
story_loop: "for_each_story_in_epic"
story_workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
note: "Heavy emphasis on existing code context"
- id: "validate-story-context"
required: true
agent: "sm"
command: "validate-story-context"
note: "Ensure no breaking changes"
- id: "story-ready"
recommended: true
agent: "sm"
command: "story-ready"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "review-story"
required: true
agent: "dev"
command: "review-story"
note: "Check integration points"
- id: "correct-course"
conditional: "if_review_fails"
agent: "dev"
command: "correct-course"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
epic_completion:
- id: "integration-test"
required: true
agent: "dev"
command: "integration-test"
- id: "retrospective"
required: true
agent: "pm"
command: "retrospective"
story_naming: "story-<epic>.<story>.md"
brownfield_note: "All changes must integrate seamlessly with existing system"

View File

@@ -0,0 +1,147 @@
# Brownfield Level 4 - Enterprise Scale Changes to Existing System
# 40+ stories, major expansion of existing enterprise system
project_type: "software"
level: 4
field_type: "brownfield"
description: "Enterprise scale expansion of existing system"
phases:
- phase: 0
name: "Documentation"
conditional: "if_undocumented"
workflows:
- id: "document-project"
required: true
agent: "analyst"
command: "document-project"
output: "Comprehensive codebase documentation"
note: "Critical for enterprise-scale changes"
- phase: 1
name: "Analysis"
required: true
workflows:
- id: "brainstorm-project"
recommended: true
agent: "analyst"
command: "brainstorm-project"
- id: "research"
required: true
agent: "analyst"
command: "research"
note: "Research existing system architecture deeply"
- id: "product-brief"
required: true
agent: "analyst"
command: "product-brief"
note: "Strategic brief for major expansion"
- id: "impact-assessment"
recommended: true
agent: "analyst"
command: "impact-assessment"
note: "Assess impact on existing systems"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "prd"
required: true
agent: "pm"
command: "prd"
output: "Comprehensive PRD considering existing system"
- id: "ux-spec"
required: true
agent: "pm"
command: "ux-spec"
note: "Multiple UI/UX specifications"
- id: "product-spec"
recommended: true
agent: "pm"
command: "product-spec"
note: "Detailed specifications for expansion"
- id: "migration-plan"
conditional: "if_breaking_changes"
agent: "architect"
command: "migration-plan"
- phase: 3
name: "Solutioning"
required: true
workflows:
- id: "solution-architecture"
required: true
agent: "architect"
command: "solution-architecture"
output: "Architecture for system expansion"
note: "Must maintain backward compatibility"
- id: "assess-project-ready"
required: true
agent: "sm"
command: "assess-project-ready"
note: "Critical validation before major changes"
- phase: 4
name: "Implementation"
required: true
epic_loop: "for_each_epic"
epic_workflows:
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
note: "JIT per epic - creates stories considering existing code"
story_loop: "for_each_story_in_epic"
story_workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
note: "Extensive existing code context required"
- id: "validate-story-context"
required: true
agent: "sm"
command: "validate-story-context"
- id: "story-ready"
required: true
agent: "sm"
command: "story-ready"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "review-story"
required: true
agent: "dev"
command: "review-story"
note: "Rigorous review for enterprise changes"
- id: "correct-course"
conditional: "if_review_fails"
agent: "dev"
command: "correct-course"
- id: "integration-test"
required: true
agent: "dev"
command: "integration-test"
note: "Test integration with existing systems"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
epic_completion:
- id: "retrospective"
required: true
agent: "pm"
command: "retrospective"
note: "Critical for enterprise-scale learning"
story_naming: "story-<epic>.<story>.md"
story_example: "story-1.1.md, story-2.3.md"
epic_structure: "JIT tech-specs per epic create stories"
enterprise_note: "Maintain system stability while implementing major changes"
brownfield_note: "Extensive regression testing and backward compatibility required"

View File

@@ -0,0 +1,125 @@
# Game Design - All Levels
# Game development follows a different path than software
project_type: "game"
level: "all"
field_type: "any"
description: "Game development workflow - applies to all complexity levels"
phases:
- phase: 1
name: "Analysis"
optional: true
workflows:
- id: "brainstorm-game"
optional: true
agent: "game-designer"
command: "brainstorm-game"
- id: "research"
optional: true
agent: "analyst"
command: "research"
note: "Market research, competitive analysis"
- id: "game-brief"
recommended: true
agent: "game-designer"
command: "game-brief"
output: "Game concept and vision document"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "gdd"
required: true
agent: "pm"
command: "gdd"
output: "Game Design Document with features and mechanics"
- id: "tech-spec"
conditional: "if_level_0_1"
agent: "architect"
command: "tech-spec"
note: "For simpler games, jump to implementation"
- phase: 3
name: "Solutioning"
conditional: "if_level_3_4"
workflows:
- id: "solution-architecture"
required: true
agent: "architect"
command: "solution-architecture"
note: "Engine architecture, networking, systems"
- id: "assess-project-ready"
required: true
agent: "sm"
command: "assess-project-ready"
- phase: 4
name: "Implementation"
required: true
note: "Implementation varies by game complexity"
level_based_implementation:
level_0_1:
story_loop: "for_each_story"
workflows:
- id: "create-story"
required: true
agent: "sm"
- id: "story-context"
required: true
agent: "sm"
- id: "dev-story"
required: true
agent: "dev"
- id: "story-approved"
required: true
agent: "dev"
level_2_4:
feature_loop: "for_each_feature"
feature_workflows:
- id: "tech-spec"
optional: true
agent: "architect"
note: "Per major feature"
story_loop: "for_each_story_in_feature"
story_workflows:
- id: "create-story"
required: true
agent: "sm"
- id: "story-context"
required: true
agent: "sm"
- id: "validate-story-context"
optional: true
agent: "sm"
- id: "dev-story"
required: true
agent: "dev"
- id: "review-story"
recommended: true
agent: "dev"
- id: "story-approved"
required: true
agent: "dev"
feature_completion:
- id: "playtest"
required: true
agent: "game-designer"
command: "playtest"
- id: "retrospective"
optional: true
agent: "pm"
story_naming:
level_0_1: "story-<feature>.md"
level_2_4: "story-<feature>.<n>.md"
story_examples:
- "story-player-movement.md"
- "story-inventory-1.md"
- "story-combat-system-3.md"
special_considerations:
- "Iterative playtesting throughout development"
- "Art and audio pipelines run parallel to code"
- "Balance and tuning as ongoing process"

View File

@@ -0,0 +1,60 @@
# Greenfield Level 0 - Single Atomic Change
# The simplest possible workflow - one change, one story
project_type: "software"
level: 0
field_type: "greenfield"
description: "Single atomic change - bug fix, tiny feature, one story"
phases:
- phase: 1
name: "Analysis"
optional: true
workflows:
- id: "brainstorm-project"
optional: true
agent: "analyst"
command: "brainstorm-project"
- id: "product-brief"
optional: true
agent: "analyst"
command: "product-brief"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
output: "Creates single story file"
- phase: 3
name: "Solutioning"
skip: true
- phase: 4
name: "Implementation"
required: true
workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
story_naming: "story-<short-title>.md"
story_example: "story-fix-login.md"
max_stories: 1

View File

@@ -0,0 +1,73 @@
# Greenfield Level 1 - Small Feature
# Coherent feature with 2-3 stories in a single epic
project_type: "software"
level: 1
field_type: "greenfield"
description: "Small coherent feature - 2-3 stories, single epic"
phases:
- phase: 1
name: "Analysis"
optional: true
workflows:
- id: "brainstorm-project"
optional: true
agent: "analyst"
command: "brainstorm-project"
- id: "research"
optional: true
agent: "analyst"
command: "research"
- id: "product-brief"
optional: true
agent: "analyst"
command: "product-brief"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
output: "Creates 2-3 story files"
- phase: 3
name: "Solutioning"
skip: true
- phase: 4
name: "Implementation"
required: true
loop_type: "for_each_story"
workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
- id: "story-ready"
optional: true
agent: "sm"
command: "story-ready"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "review-story"
optional: true
agent: "dev"
command: "review-story"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
story_naming: "story-<title>-<n>.md"
story_example: "story-oauth-integration-1.md"
max_stories: 3

View File

@@ -0,0 +1,93 @@
# Greenfield Level 2 - Medium Project
# Multiple epics with 10+ stories total
project_type: "software"
level: 2
field_type: "greenfield"
description: "Medium project - multiple epics, 10+ stories"
phases:
- phase: 1
name: "Analysis"
optional: true
workflows:
- id: "brainstorm-project"
optional: true
agent: "analyst"
command: "brainstorm-project"
- id: "research"
optional: true
agent: "analyst"
command: "research"
note: "Can have multiple research docs"
- id: "product-brief"
recommended: true
agent: "analyst"
command: "product-brief"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "prd"
required: true
agent: "pm"
command: "prd"
output: "Creates epics.md and story list"
- id: "ux-spec"
conditional: "if_has_ui"
agent: "pm"
command: "ux-spec"
- id: "tech-spec"
optional: true
agent: "architect"
command: "tech-spec"
note: "Lightweight technical planning"
- phase: 3
name: "Solutioning"
skip: true
- phase: 4
name: "Implementation"
required: true
loop_type: "for_each_story"
workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
- id: "validate-story-context"
optional: true
agent: "sm"
command: "validate-story-context"
- id: "story-ready"
optional: true
agent: "sm"
command: "story-ready"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "review-story"
optional: true
agent: "dev"
command: "review-story"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
epic_completion:
- id: "retrospective"
optional: true
agent: "pm"
command: "retrospective"
note: "After each epic completes"
story_naming: "story-<epic>.<story>.md"
story_example: "story-1.1.md, story-2.3.md"
epic_structure: "Numbered epics with numbered stories"

View File

@@ -0,0 +1,109 @@
# Greenfield Level 3 - Complex System
# Subsystems, integrations, architectural decisions required
project_type: "software"
level: 3
field_type: "greenfield"
description: "Complex system - subsystems, integrations, architectural decisions"
phases:
- phase: 1
name: "Analysis"
optional: true
workflows:
- id: "brainstorm-project"
optional: true
agent: "analyst"
command: "brainstorm-project"
- id: "research"
optional: true
agent: "analyst"
command: "research"
note: "Multiple research areas likely"
- id: "product-brief"
recommended: true
agent: "analyst"
command: "product-brief"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "prd"
required: true
agent: "pm"
command: "prd"
output: "High-level requirements and epic definitions"
- id: "ux-spec"
conditional: "if_has_ui"
agent: "pm"
command: "ux-spec"
- phase: 3
name: "Solutioning"
required: true
workflows:
- id: "solution-architecture"
required: true
agent: "architect"
command: "solution-architecture"
output: "System-wide architecture document"
- id: "assess-project-ready"
required: true
agent: "sm"
command: "assess-project-ready"
note: "Validate architecture before implementation"
- phase: 4
name: "Implementation"
required: true
epic_loop: "for_each_epic"
epic_workflows:
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
note: "JIT per epic - creates stories for that epic"
story_loop: "for_each_story_in_epic"
story_workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
- id: "validate-story-context"
recommended: true
agent: "sm"
command: "validate-story-context"
- id: "story-ready"
optional: true
agent: "sm"
command: "story-ready"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "review-story"
recommended: true
agent: "dev"
command: "review-story"
- id: "correct-course"
conditional: "if_review_fails"
agent: "dev"
command: "correct-course"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
epic_completion:
- id: "retrospective"
recommended: true
agent: "pm"
command: "retrospective"
story_naming: "story-<epic>.<story>.md"
story_example: "story-1.1.md, story-2.3.md"
epic_structure: "JIT tech-specs per epic create stories"

View File

@@ -0,0 +1,118 @@
# Greenfield Level 4 - Enterprise Scale
# Multiple products, enterprise architecture, 40+ stories
project_type: "software"
level: 4
field_type: "greenfield"
description: "Enterprise scale - multiple products, enterprise architecture"
phases:
- phase: 1
name: "Analysis"
required: true
workflows:
- id: "brainstorm-project"
recommended: true
agent: "analyst"
command: "brainstorm-project"
- id: "research"
required: true
agent: "analyst"
command: "research"
note: "Extensive research across multiple domains"
- id: "product-brief"
required: true
agent: "analyst"
command: "product-brief"
note: "Strategic brief for enterprise scope"
- phase: 2
name: "Planning"
required: true
workflows:
- id: "prd"
required: true
agent: "pm"
command: "prd"
output: "Comprehensive product requirements document"
- id: "ux-spec"
required: true
agent: "pm"
command: "ux-spec"
note: "Multiple UI/UX specifications needed"
- id: "product-spec"
recommended: true
agent: "pm"
command: "product-spec"
note: "Detailed product specifications"
- phase: 3
name: "Solutioning"
required: true
workflows:
- id: "solution-architecture"
required: true
agent: "architect"
command: "solution-architecture"
output: "Enterprise architecture documentation"
- id: "assess-project-ready"
required: true
agent: "sm"
command: "assess-project-ready"
note: "Critical validation before enterprise implementation"
- phase: 4
name: "Implementation"
required: true
epic_loop: "for_each_epic"
epic_workflows:
- id: "tech-spec"
required: true
agent: "architect"
command: "tech-spec"
note: "JIT per epic - creates stories for that epic"
story_loop: "for_each_story_in_epic"
story_workflows:
- id: "create-story"
required: true
agent: "sm"
command: "create-story"
- id: "story-context"
required: true
agent: "sm"
command: "story-context"
- id: "validate-story-context"
required: true
agent: "sm"
command: "validate-story-context"
- id: "story-ready"
recommended: true
agent: "sm"
command: "story-ready"
- id: "dev-story"
required: true
agent: "dev"
command: "dev-story"
- id: "review-story"
required: true
agent: "dev"
command: "review-story"
- id: "correct-course"
conditional: "if_review_fails"
agent: "dev"
command: "correct-course"
- id: "story-approved"
required: true
agent: "dev"
command: "story-approved"
epic_completion:
- id: "retrospective"
required: true
agent: "pm"
command: "retrospective"
note: "Critical for enterprise-scale learning"
story_naming: "story-<epic>.<story>.md"
story_example: "story-1.1.md, story-2.3.md"
epic_structure: "JIT tech-specs per epic create stories"
enterprise_note: "Rigorous validation and reviews required at scale"

View File

@@ -0,0 +1,59 @@
# BMM Project Scale Levels - Source of Truth
# Reference: /src/modules/bmm/README.md lines 77-85
levels:
0:
name: "Level 0"
title: "Single Atomic Change"
stories: "1 story"
description: "Bug fix, tiny feature, one small change"
documentation: "Minimal - tech spec only"
architecture: false
1:
name: "Level 1"
title: "Small Feature"
stories: "1-10 stories"
description: "Small coherent feature, minimal documentation"
documentation: "Tech spec"
architecture: false
2:
name: "Level 2"
title: "Medium Project"
stories: "5-15 stories"
description: "Multiple features, focused PRD"
documentation: "PRD + optional tech spec"
architecture: false
3:
name: "Level 3"
title: "Complex System"
stories: "12-40 stories"
description: "Subsystems, integrations, full architecture"
documentation: "PRD + solution architecture + JIT tech specs"
architecture: true
4:
name: "Level 4"
title: "Enterprise Scale"
stories: "40+ stories"
description: "Multiple products, enterprise architecture"
documentation: "Full suite - PRD, architecture, product specs"
architecture: true
# Quick detection hints for workflow-init
detection_hints:
keywords:
level_0: ["fix", "bug", "typo", "small change", "quick update", "patch"]
level_1: ["simple", "basic", "small feature", "add", "minor"]
level_2: ["dashboard", "several features", "admin panel", "medium"]
level_3: ["platform", "integration", "complex", "system", "architecture"]
level_4: ["enterprise", "multi-tenant", "multiple products", "ecosystem", "scale"]
story_counts:
level_0: [1, 1]
level_1: [1, 10]
level_2: [5, 15]
level_3: [12, 40]
level_4: [40, 999]

View File

@@ -0,0 +1,54 @@
# BMM Workflow Status
## Project Configuration
PROJECT_NAME: {{project_name}}
PROJECT_TYPE: {{project_type}}
PROJECT_LEVEL: {{project_level}}
FIELD_TYPE: {{field_type}}
START_DATE: {{start_date}}
WORKFLOW_PATH: {{workflow_path_file}}
## Current State
CURRENT_PHASE: {{current_phase}}
CURRENT_WORKFLOW: {{current_workflow}}
CURRENT_AGENT: {{current_agent}}
PHASE_1_COMPLETE: {{phase_1_complete}}
PHASE_2_COMPLETE: {{phase_2_complete}}
PHASE_3_COMPLETE: {{phase_3_complete}}
PHASE_4_COMPLETE: {{phase_4_complete}}
## Development Queue
STORIES_SEQUENCE: {{ordered_story_list}}
TODO_STORY: {{todo_story}}
TODO_TITLE: {{todo_title}}
IN_PROGRESS_STORY: {{in_progress_story}}
IN_PROGRESS_TITLE: {{in_progress_title}}
STORIES_DONE: {{completed_story_list}}
## Next Action
NEXT_ACTION: {{next_action}}
NEXT_COMMAND: {{next_command}}
NEXT_AGENT: {{next_agent}}
## Story Backlog
{{#backlog_stories}}
- {{story_id}}: {{story_title}}
{{/backlog_stories}}
## Completed Stories
{{#done_stories}}
- {{story_id}}: {{completed_date}}
{{/done_stories}}
---
_Last Updated: {{last_updated}}_
_Status Version: 2.0_

View File

@@ -0,0 +1,29 @@
# Workflow Status - Master Router and Status Tracker
name: workflow-status
description: "Lightweight status checker - answers 'what should I do now?' for any agent. Reads simple key-value status file for instant parsing. Use workflow-init for new projects."
author: "BMad"
# Critical variables from config
config_source: "{project-root}/bmad/bmm/config.yaml"
output_folder: "{config_source}:output_folder"
user_name: "{config_source}:user_name"
communication_language: "{config_source}:communication_language"
document_output_language: "{config_source}:document_output_language"
user_skill_level: "{config_source}:user_skill_level"
date: system-generated
# Workflow components
installed_path: "{project-root}/bmad/bmm/workflows/workflow-status"
instructions: "{installed_path}/instructions.md"
# Template for status file creation (used by workflow-init)
template: "{installed_path}/workflow-status-template.md"
# Path definitions for project types
path_files: "{installed_path}/paths/"
# Output configuration - reads existing status
default_output_file: "{output_folder}/bmm-workflow-status.md"
# This is now a lightweight router workflow
web_bundle: false