$npx -y skills add aj-geddes/claude-code-bmad-skills --skill bmad-parallel-planTurns a sequential, ready-for-dev story backlog into conflict-free CONCURRENT WAVES. Builds a dependency DAG from epic order, per-story dependency maps, and Owned File/Module Scope overlaps, then topologically sorts it into parallel waves of mutually disjoint, dependency-satisfie
| 1 | # BMAD Parallel Plan |
| 2 | |
| 3 | Convert a linear backlog into **waves** of stories that can be developed at the same |
| 4 | time without colliding — then describe exactly how to merge them back together. This |
| 5 | skill produces a *plan*. Your external dev tools execute it. |
| 6 | |
| 7 | **Persona flavor:** Winston (Architect) reasons about isolation; the workflow does the math. |
| 8 | |
| 9 | ## Scope (read first) |
| 10 | |
| 11 | - This skill **plans** concurrency. It NEVER spawns worktrees, runs dev agents, writes |
| 12 | application code, runs tests, lints, or runs `git`. |
| 13 | - Inputs are planning artifacts. The only output is `parallelization-plan.md` (plus an |
| 14 | optional `dependency-graph.json` / `waves.json` for traceability). |
| 15 | - Branch names and merge order are *recommendations* the dev tool/human carries out. |
| 16 | |
| 17 | ## Inputs |
| 18 | |
| 19 | | Artifact | Path (under output folder) | Used for | |
| 20 | |----------|---------------------------|----------| |
| 21 | | Sprint status | `sprint-status.yaml` | story ids, epic, status, dependency lists | |
| 22 | | Ready stories | `stories/{epic}.{story}.{slug}.story.md` | **Owned File/Module Scope** + **Dependency Maps** | |
| 23 | | Architecture | `architecture.md` | semantic-conflict prevention (boundaries, shared modules) | |
| 24 | | Config | `userConfig.maxParallel` (default `3`) | wave width cap | |
| 25 | |
| 26 | Only stories at status `ready-for-dev` (or later) are eligible for a wave. |
| 27 | |
| 28 | ## The four steps |
| 29 | |
| 30 | 1. **Lean on architecture for semantic safety.** Read `architecture.md`. Architecture is |
| 31 | what makes parallelism *safe* — clean module boundaries mean two stories touching |
| 32 | different components won't create a hidden semantic conflict even if the files differ. |
| 33 | Note any shared/cross-cutting modules (auth, config, DB schema, shared types); stories |
| 34 | that touch them are high-conflict and rarely parallelizable. |
| 35 | |
| 36 | 2. **Read each story's Owned File/Module Scope.** Every ready story declares the explicit |
| 37 | list of paths it may touch. Collect `{story_id -> [paths]}`. A missing or empty scope |
| 38 | is a **planning blocker** — flag it; do not guess. |
| 39 | |
| 40 | 3. **Build the dependency DAG, then topologically sort into waves.** Edges come from three |
| 41 | conflict classes (see REFERENCE.md): |
| 42 | - **Ordering edges** — epic order (stories within an epic are usually sequential) and |
| 43 | each story's explicit Dependency Maps (`depends_on`). |
| 44 | - **File-scope edges** — any two stories whose Owned File/Module Scopes intersect must |
| 45 | not share a wave (an undirected conflict, resolved by lower story id first). |
| 46 | - **Semantic edges** — both touch a shared/cross-cutting module from step 1. |
| 47 | |
| 48 | Topologically sort: wave *N* = all stories whose dependencies are already satisfied by |
| 49 | waves `< N` AND that are pairwise file-disjoint AND pairwise semantically safe. Cap each |
| 50 | wave at `maxParallel`; overflow rolls to the next wave (lowest id first). |
| 51 | |
| 52 | 4. **Emit `parallelization-plan.md`.** For each wave, list the ready-for-dev stories; give |
| 53 | each an isolated `git-worktree` branch name and its disjoint file scope. Then give the |
| 54 | **ordered merge sequence**: lowest story id first into an `integration` branch, an |
| 55 | integration review checkpoint, then a single PR `integration -> main`. |
| 56 | |
| 57 | ## Three intents |
| 58 | |
| 59 | - **Create** — first wave plan from the current backlog. |
| 60 | - **Update** — re-plan after stories were added/finished/re-scoped (recompute the DAG; |
| 61 | exclude `done`, re-sort remaining). |
| 62 | - **Validate** — re-check an existing plan: confirm every wave is still file-disjoint, |
| 63 | dependency-satisfied, and within `maxParallel`; report drift. |
| 64 | |
| 65 | State the intent, then proceed. |
| 66 | |
| 67 | ## Run the helper scripts |
| 68 | |
| 69 | Both scripts are deterministic and read-only. Resolve paths via `${CLAUDE_PLUGIN_ROOT}`. |
| 70 | |
| 71 | ```bash |
| 72 | # 1) Build the dependency DAG (edges + conflict class) from status + story scopes |
| 73 | python3 "${CLAUDE_PLUGIN_ROOT}/skills/bmad-parallel-plan/scripts/build-dependency-graph.py" \ |
| 74 | --status "<output>/sprint-status.yaml" \ |
| 75 | --stories "<output>/stories" \ |
| 76 | - |