ma-agents 3.14.0 → 3.14.1
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.
- package/README.md +3 -3
- package/lib/agents.js +2 -2
- package/lib/bmad-customize/bmm-qa.customize.yaml +3 -3
- package/lib/bmad-extension/.claude-plugin/marketplace.json.template +2 -1
- package/lib/bmad-extension/skills/bmad-dev-epic/SKILL.md +101 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/bmad-skill-manifest.yaml +3 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/checklist.md +44 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/customize.toml +54 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/references/story-pipeline.md +112 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/steps/step-01-intake.md +59 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/steps/step-02-plan-waves.md +56 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/steps/step-03-epic-branch.md +35 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/steps/step-04-run-waves.md +49 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/steps/step-05-epic-adversarial.md +31 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/steps/step-06-release.md +57 -0
- package/lib/bmad-extension/skills/bmad-dev-epic/steps/step-07-report.md +40 -0
- package/lib/bmad-extension/skills/ma-agent-sqa/SKILL.md +3 -3
- package/lib/bmad-extension/skills/ma-agent-sqa/bmad-skill-manifest.yaml +1 -1
- package/lib/bmad-extension/skills/module-help.csv +2 -1
- package/lib/bmad-extension/skills/module.yaml +1 -1
- package/lib/bmad-extension/skills/sqa-audit/SKILL.md +2 -2
- package/lib/bmad-extension/skills/sqa-ieee12207/SKILL.md +3 -3
- package/lib/bmad-extension/skills/sqa-requirements-quality/SKILL.md +2 -2
- package/lib/bmad-extension-plugin/.claude-plugin/marketplace.json +3 -2
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/SKILL.md +101 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/bmad-skill-manifest.yaml +3 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/checklist.md +44 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/customize.toml +54 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/references/story-pipeline.md +112 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/steps/step-01-intake.md +59 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/steps/step-02-plan-waves.md +56 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/steps/step-03-epic-branch.md +35 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/steps/step-04-run-waves.md +49 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/steps/step-05-epic-adversarial.md +31 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/steps/step-06-release.md +57 -0
- package/lib/bmad-extension-plugin/skills/bmad-dev-epic/steps/step-07-report.md +40 -0
- package/lib/bmad-extension-plugin/skills/ma-agent-sqa/SKILL.md +3 -3
- package/lib/bmad-extension-plugin/skills/ma-agent-sqa/bmad-skill-manifest.yaml +1 -1
- package/lib/bmad-extension-plugin/skills/module-help.csv +2 -1
- package/lib/bmad-extension-plugin/skills/module.yaml +1 -1
- package/lib/bmad-extension-plugin/skills/sqa-audit/SKILL.md +2 -2
- package/lib/bmad-extension-plugin/skills/sqa-ieee12207/SKILL.md +3 -3
- package/lib/bmad-extension-plugin/skills/sqa-requirements-quality/SKILL.md +2 -2
- package/lib/templates/instruction-block-git.template.md +25 -25
- package/lib/templates/instruction-block-onprem.template.md +86 -86
- package/lib/templates/instruction-block-universal.template.md +29 -29
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -184,7 +184,7 @@ These domain-expert agents are installed alongside BMAD-METHOD and provide guide
|
|
|
184
184
|
| DevOps Agent | Amit | `_bmad/skills/devops/` | `_bmad/bmm/agents/devops.md` |
|
|
185
185
|
| Cyber Analyst | Yael | `_bmad/skills/cyber/` | `_bmad/bmm/agents/cyber.md` |
|
|
186
186
|
| ML Scientist | Demerzel | `_bmad/skills/demerzel/` | `_bmad/bmm/agents/demerzel.md` |
|
|
187
|
-
| SQA & Standards Expert |
|
|
187
|
+
| SQA & Standards Expert | Gadi | `_bmad/skills/sqa/` | `_bmad/bmm/agents/qa.md` |
|
|
188
188
|
|
|
189
189
|
## Available Skills
|
|
190
190
|
|
|
@@ -247,7 +247,7 @@ These workflows are installed as part of the BMAD agent system and are invoked t
|
|
|
247
247
|
| `ml-revision` | ML Scientist | Amend hypothesis and requirements based on experiment findings |
|
|
248
248
|
| `ml-advise` | ML Scientist | Search past experiments, surface findings and failure warnings |
|
|
249
249
|
| `ml-retrospective` | ML Scientist | Capture session learnings and update project context |
|
|
250
|
-
| **SQA & MIL-STD-498 (
|
|
250
|
+
| **SQA & MIL-STD-498 (Gadi)** | | |
|
|
251
251
|
| `sqa-audit` | SQA & Standards Expert | Multi-dimensional project quality audit: code↔story traceability, stories↔architecture/PRD alignment, process compliance, sprint health, release state — saves audit report and optional remediation plan |
|
|
252
252
|
| `sqa-ieee12207` | SQA & Standards Expert | IEEE/ISO/IEC 12207:2017 compliance assessment across 23 process areas in 4 groups — produces compliance matrix, gap analysis, and optional remediation plan |
|
|
253
253
|
| `sqa-requirements-quality` | SQA & Standards Expert | Requirements quality audit against 14 criteria with scope selection (PRD FRs, NFRs, epics, stories) — per-requirement audit table, critical-fail detection, Overall Quality Score, and optional remediation plan |
|
|
@@ -357,7 +357,7 @@ npx ma-agents install --yes # fully offline BMAD install — no network neede
|
|
|
357
357
|
- **Focus**: Hypothesis-driven machine learning lifecycle with scientific rigor.
|
|
358
358
|
- **Capabilities**: EDA, architecture design, locked TechSpec contracts, experiment execution, failure-cost analysis.
|
|
359
359
|
- **Workflows**: 12-stage ML lifecycle from ideation through retrospective, with mandatory review gates.
|
|
360
|
-
5. **
|
|
360
|
+
5. **Gadi (SQA & Standards Expert)**:
|
|
361
361
|
- **Focus**: Software quality assurance and defense documentation standards — a unified persona covering SQA auditing and MIL-STD-498 document generation.
|
|
362
362
|
- **SQA Capabilities**: Multi-dimensional project quality audits, IEEE/ISO/IEC 12207:2017 compliance assessments (23 process areas, 4 groups), requirements evaluation against 14 established quality criteria (scope-selectable: PRD FRs, NFRs, epics, stories).
|
|
363
363
|
- **MIL-STD-498 Capabilities**: Full Data Item Description (DID) generation for SRS, SDD, SDP, OCD, SSS, STD, and SSDD. Requirements quality review tailored to MIL-STD-498 structure and military-standard terminology (CSCI, HWCI, IRS).
|
package/lib/agents.js
CHANGED
|
@@ -314,10 +314,10 @@ const agents = [
|
|
|
314
314
|
},
|
|
315
315
|
{
|
|
316
316
|
id: 'bmm-qa',
|
|
317
|
-
name: 'SQA & Standards Expert (
|
|
317
|
+
name: 'SQA & Standards Expert (Gadi)',
|
|
318
318
|
version: '1.0.0',
|
|
319
319
|
category: 'bmad',
|
|
320
|
-
description: 'Software Quality Assurance and MIL-STD-498 Standards Expert (
|
|
320
|
+
description: 'Software Quality Assurance and MIL-STD-498 Standards Expert (Gadi)',
|
|
321
321
|
skillsDir: '_bmad/skills/sqa',
|
|
322
322
|
getProjectPath: () => path.join(process.cwd(), '_bmad', 'skills', 'sqa'),
|
|
323
323
|
getGlobalPath: () => null,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
# MA-AGENTS:
|
|
1
|
+
# MA-AGENTS: Gadi — Software Quality Assurance Expert
|
|
2
2
|
phase: planning
|
|
3
3
|
on_prem_phase_prefix: "/no_think You are in a planning phase — respond in text for questions; create files only when explicitly asked."
|
|
4
4
|
agent:
|
|
5
5
|
metadata:
|
|
6
|
-
name: "
|
|
6
|
+
name: "Gadi"
|
|
7
7
|
|
|
8
8
|
persona:
|
|
9
9
|
role: "Software Quality Assurance Engineer responsible for verifying project quality across all dimensions — code, process, documentation, and delivery."
|
|
@@ -17,7 +17,7 @@ persona:
|
|
|
17
17
|
|
|
18
18
|
menu:
|
|
19
19
|
- trigger: skill:ma-agent-sqa
|
|
20
|
-
description: "Activate
|
|
20
|
+
description: "Activate Gadi — Software Quality Assurance Expert"
|
|
21
21
|
|
|
22
22
|
critical_actions:
|
|
23
23
|
- "Read the skills MANIFEST at {project-root}/skills/MANIFEST.yaml"
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"owner": {
|
|
12
12
|
"name": "Alon Mayaffit"
|
|
13
13
|
},
|
|
14
|
-
"description": "ma-agents BMAD extension — enterprise SDLC personas (Yael, Amit, Alex, Demerzel,
|
|
14
|
+
"description": "ma-agents BMAD extension — enterprise SDLC personas (Yael, Amit, Alex, Demerzel, Gadi) plus MIL-STD-498, SRE, DevOps, Cyber, ML, and SQA workflow skills.",
|
|
15
15
|
"license": "MIT",
|
|
16
16
|
"homepage": "https://github.com/mayafit/AI_Agents",
|
|
17
17
|
"repository": "https://github.com/mayafit/AI_Agents",
|
|
@@ -99,6 +99,7 @@
|
|
|
99
99
|
"./skills/ml-techspec",
|
|
100
100
|
"./skills/add-sprint",
|
|
101
101
|
"./skills/add-to-sprint",
|
|
102
|
+
"./skills/bmad-dev-epic",
|
|
102
103
|
"./skills/bmad-dev-story",
|
|
103
104
|
"./skills/bmad-sprint-planning",
|
|
104
105
|
"./skills/bmad-sprint-status",
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: bmad-dev-epic
|
|
3
|
+
description: 'Orchestrate a full epic end-to-end with parallel subagents — per-story create/dev/review/edge-case/fix/e2e pipeline, dependency-aware waves, configurable model tiers, an epic-level adversarial + package-integrity gate, and gated beta publish + PR. Use when the user says "run the epic", "dev epic [id]", or "orchestrate epic development".'
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Epic Orchestrator Workflow
|
|
7
|
+
|
|
8
|
+
**Goal:** Drive an already-planned epic from stories to a review-ready epic PR, autonomously, by orchestrating BMAD skills across parallel subagents under a strict, repeatable process.
|
|
9
|
+
|
|
10
|
+
**Your Role:** You are the Epic Orchestrator. You do not write story code yourself — you decompose the epic into dependency-ordered waves, spawn subagents that each run a disciplined per-story pipeline, enforce a Definition of Done before any merge, run an epic-level adversarial + package-integrity gate, and stop at the two human gates (publish, PR). You are precise about git isolation, model tiers, and failure handling. No noise, no filler.
|
|
11
|
+
|
|
12
|
+
## Conventions
|
|
13
|
+
|
|
14
|
+
- Bare paths (e.g. `checklist.md`) resolve from the skill root.
|
|
15
|
+
- `{skill-root}` resolves to this skill's installed directory (where `customize.toml` lives).
|
|
16
|
+
- `{project-root}`-prefixed paths resolve from the project working directory.
|
|
17
|
+
- `{skill-name}` resolves to the skill directory's basename (`bmad-dev-epic`).
|
|
18
|
+
|
|
19
|
+
## On Activation
|
|
20
|
+
|
|
21
|
+
### Step 1: Resolve the Workflow Block
|
|
22
|
+
|
|
23
|
+
Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`
|
|
24
|
+
|
|
25
|
+
**If the script fails**, resolve the `workflow` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver:
|
|
26
|
+
|
|
27
|
+
1. `{skill-root}/customize.toml` — defaults
|
|
28
|
+
2. `{project-root}/_bmad/custom/{skill-name}.toml` — team overrides
|
|
29
|
+
3. `{project-root}/_bmad/custom/{skill-name}.user.toml` — personal overrides
|
|
30
|
+
|
|
31
|
+
Any missing file is skipped. Scalars override, tables deep-merge, arrays of tables keyed by `code` or `id` replace matching entries and append new entries, and all other arrays append.
|
|
32
|
+
|
|
33
|
+
### Step 2: Execute Prepend Steps
|
|
34
|
+
|
|
35
|
+
Execute each entry in `{workflow.activation_steps_prepend}` in order before proceeding.
|
|
36
|
+
|
|
37
|
+
### Step 3: Load Persistent Facts
|
|
38
|
+
|
|
39
|
+
Treat every entry in `{workflow.persistent_facts}` as foundational context you carry for the rest of the run. Entries prefixed `file:` are paths or globs under `{project-root}` — load the referenced contents as facts. All other entries are facts verbatim.
|
|
40
|
+
|
|
41
|
+
### Step 4: Load Config
|
|
42
|
+
|
|
43
|
+
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
|
44
|
+
|
|
45
|
+
- `project_name`, `planning_artifacts`, `implementation_artifacts`, `user_name`
|
|
46
|
+
- `communication_language`, `document_output_language`, `user_skill_level`
|
|
47
|
+
- `date` as system-generated current datetime
|
|
48
|
+
- `sprint_status` = `{implementation_artifacts}/sprint-status.yaml`
|
|
49
|
+
- `project_context` = `**/project-context.md` (load if exists)
|
|
50
|
+
- CLAUDE.md / memory files (load if exist)
|
|
51
|
+
- ALWAYS speak in the config `{communication_language}`.
|
|
52
|
+
|
|
53
|
+
### Step 5: Greet the User
|
|
54
|
+
|
|
55
|
+
Greet `{user_name}`, speaking in `{communication_language}`. State plainly what this skill will do (run an entire epic through parallel subagents) and that it runs unattended through dev + review, requiring your **approval at only two release gates** — before publishing the beta package and before opening the epic PR. (It will still HALT for genuine blockers, e.g. a missing/unready epic or a dependency cycle.)
|
|
56
|
+
|
|
57
|
+
### Step 6: Execute Append Steps
|
|
58
|
+
|
|
59
|
+
Execute each entry in `{workflow.activation_steps_append}` in order.
|
|
60
|
+
|
|
61
|
+
Activation is complete. If `activation_steps_prepend` or `activation_steps_append` were non-empty, confirm every entry was executed in order before proceeding. Do not begin the main workflow until all activation steps have completed.
|
|
62
|
+
|
|
63
|
+
## WORKFLOW ARCHITECTURE
|
|
64
|
+
|
|
65
|
+
This uses **step-file architecture** for disciplined execution:
|
|
66
|
+
|
|
67
|
+
- **Micro-file Design**: Each step is self-contained and followed exactly.
|
|
68
|
+
- **Just-In-Time Loading**: Only load the current step file.
|
|
69
|
+
- **Sequential Enforcement**: Complete steps in order, no skipping.
|
|
70
|
+
- **State Tracking**: Persist progress in an in-memory **Run Ledger** (see below) and mirror it to `{implementation_artifacts}/epic-runs/<epic-id>/run-ledger.md` so a resumed run can recover.
|
|
71
|
+
|
|
72
|
+
### The Run Ledger
|
|
73
|
+
|
|
74
|
+
Maintain a single source of truth for the run with, per story: `id`, `wave`, `status` (`pending` → `in-progress` → `review` → `fixing` → `e2e` → `merged` → `blocked`), `worktree`, `branch`, `fix_rounds_used`, and a short note. Update it at every state transition and after every subagent returns.
|
|
75
|
+
|
|
76
|
+
### Step Processing Rules
|
|
77
|
+
|
|
78
|
+
1. **READ COMPLETELY**: Read the entire step file before acting.
|
|
79
|
+
2. **FOLLOW SEQUENCE**: Execute sections in order.
|
|
80
|
+
3. **HONOR GATES**: Halt only at the two declared human gates (publish, PR) and wherever a step says HALT.
|
|
81
|
+
4. **LOAD NEXT**: When directed, read fully and follow the next step file.
|
|
82
|
+
|
|
83
|
+
### Git discipline (defer to `git-workflow-skill`)
|
|
84
|
+
|
|
85
|
+
**`git-workflow-skill` is the single authority for every git operation in this run** — worktree creation, branch naming, conventional commits, hooks, rebasing, PR creation, and cleanup. Do not hand-roll git flows that contradict it. Load and follow it.
|
|
86
|
+
|
|
87
|
+
This epic uses a **nested-branch topology** (epic branch off the trunk; story branches off the epic branch; stories merge back to the epic branch; one PR to the trunk). Where that diverges from the skill's script defaults — chiefly the scripts' `dev` base assumption and their auto-PR-to-`dev` — use the skill's documented **manual equivalents** with the base overridden as the step specifies (trunk for the epic branch, the epic branch for stories). Everything else (worktree-per-unit-of-work, conventional commits, hook compliance, worktree cleanup) is used exactly as the skill defines it.
|
|
88
|
+
|
|
89
|
+
### Critical Rules (NO EXCEPTIONS)
|
|
90
|
+
|
|
91
|
+
- **NEVER** load multiple step files simultaneously.
|
|
92
|
+
- **NEVER** perform any git action outside the `git-workflow-skill` conventions. The trunk (`main`) is never committed to or modified directly; all file-writing happens inside a worktree on a feature branch.
|
|
93
|
+
- **NEVER** publish to npm or open the epic PR without explicit user confirmation at the gate.
|
|
94
|
+
- **NEVER** treat the known pre-existing `npm test` CRLF failure as a regression — use the real package-integrity gate defined in step-05.
|
|
95
|
+
- **ALWAYS** validate each story against INVEST and split oversized / multi-goal stories before implementing them (see step-02 and `references/story-pipeline.md`).
|
|
96
|
+
- **ALWAYS** enforce the per-story Definition of Done before merging a story to the epic branch.
|
|
97
|
+
- **ALWAYS** respect the configured fix-loop cap; escalate a non-converging story rather than looping forever.
|
|
98
|
+
|
|
99
|
+
## FIRST STEP
|
|
100
|
+
|
|
101
|
+
Read fully and follow: `./steps/step-01-intake.md`
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# bmad-dev-epic — Run Checklist
|
|
2
|
+
|
|
3
|
+
A run is correct only if every box can be checked. Use this to self-audit mid-run and before each gate.
|
|
4
|
+
|
|
5
|
+
## Intake (step-01)
|
|
6
|
+
- [ ] Target epic identified and its stories enumerated with dependencies.
|
|
7
|
+
- [ ] Epic is genuinely ready (stories have acceptance criteria); otherwise routed to planning.
|
|
8
|
+
- [ ] Model tiers mapped to actually-available models (collapsed to one if single-model/air-gapped).
|
|
9
|
+
- [ ] Parallelism strategy, max-parallel, and fix-loop cap confirmed.
|
|
10
|
+
- [ ] Both release gates confirmed ON (or explicitly changed by the user).
|
|
11
|
+
- [ ] Real test/build gate command confirmed.
|
|
12
|
+
- [ ] Single go/no-go confirmation received.
|
|
13
|
+
|
|
14
|
+
## Planning (step-02 / step-03)
|
|
15
|
+
- [ ] Every story checked against INVEST; oversized / multi-goal stories split into focused sub-stories (user-confirmed) before graphing.
|
|
16
|
+
- [ ] Dependency DAG built; no cycles (or cycle resolved with the user).
|
|
17
|
+
- [ ] Waves computed per the chosen strategy.
|
|
18
|
+
- [ ] Epic branch `feature/epic-<id>` created off the trunk via `git-workflow-skill` (base overridden to trunk), in its own worktree.
|
|
19
|
+
|
|
20
|
+
## Per story (step-04 / story-pipeline)
|
|
21
|
+
- [ ] Story branch cut from the epic branch in its own worktree, per `git-workflow-skill`.
|
|
22
|
+
- [ ] Spec re-checked against INVEST/size after create-story; if too large/multi-goal, returned `needs-split` (not implemented) and the orchestrator split it.
|
|
23
|
+
- [ ] create-story → dev-story → parallel code-review + edge-case-hunter executed.
|
|
24
|
+
- [ ] Blocking findings fixed within the fix-loop cap (or story marked blocked, not papered over).
|
|
25
|
+
- [ ] E2E tests generated and passing; test gate green on the story branch.
|
|
26
|
+
- [ ] Definition of Done met before the story is integrated.
|
|
27
|
+
- [ ] Story merged into the epic branch by the orchestrator (serialized, `--no-ff`).
|
|
28
|
+
- [ ] Cross-story breakage checked after each merge.
|
|
29
|
+
|
|
30
|
+
## Epic gate (step-05)
|
|
31
|
+
- [ ] Adversarial whole-epic review run; blocking findings cleared or HALTED.
|
|
32
|
+
- [ ] `npm run build:plugin` passes; bundle drift clean/committed.
|
|
33
|
+
- [ ] New test failures distinguished from the known pre-existing CRLF baseline.
|
|
34
|
+
|
|
35
|
+
## Release (step-06)
|
|
36
|
+
- [ ] `code-review` self-review on the full epic diff completed.
|
|
37
|
+
- [ ] GATE A confirmed by user before publish; version bumped; packed `--ignore-scripts`; tarball inspected; published `--tag beta`.
|
|
38
|
+
- [ ] GATE B confirmed by user before PR; single epic PR opened to the trunk; body includes blocked/follow-up section.
|
|
39
|
+
- [ ] PR NOT merged (left for human approval).
|
|
40
|
+
|
|
41
|
+
## Report (step-07)
|
|
42
|
+
- [ ] Honest summary presented, including every blocked story.
|
|
43
|
+
- [ ] Story worktrees cleaned up; epic worktree retained until merge.
|
|
44
|
+
- [ ] Run Ledger persisted.
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# DO NOT EDIT -- overwritten on every update.
|
|
2
|
+
#
|
|
3
|
+
# Workflow customization surface for bmad-dev-epic. Mirrors the workflow
|
|
4
|
+
# customization shape under the [workflow] namespace. Override in
|
|
5
|
+
# {project-root}/_bmad/custom/bmad-dev-epic.toml (team) or
|
|
6
|
+
# {project-root}/_bmad/custom/bmad-dev-epic.user.toml (personal).
|
|
7
|
+
|
|
8
|
+
[workflow]
|
|
9
|
+
|
|
10
|
+
activation_steps_prepend = []
|
|
11
|
+
activation_steps_append = []
|
|
12
|
+
|
|
13
|
+
persistent_facts = [
|
|
14
|
+
"file:{project-root}/**/project-context.md",
|
|
15
|
+
]
|
|
16
|
+
|
|
17
|
+
on_complete = ""
|
|
18
|
+
|
|
19
|
+
# ── Orchestration defaults ──────────────────────────────────────────────────
|
|
20
|
+
# These are PROPOSED defaults the intake step shows the user; the user can
|
|
21
|
+
# override every one of them at runtime. They are tier-abstract on purpose so
|
|
22
|
+
# the skill works on disconnected networks and with non-Claude runtimes.
|
|
23
|
+
#
|
|
24
|
+
# All keys below are scalars, so a team/user override TOML replaces them by the
|
|
25
|
+
# normal scalar-override merge rule (override wins over base).
|
|
26
|
+
|
|
27
|
+
[workflow.defaults]
|
|
28
|
+
|
|
29
|
+
# Model tiers are ABSTRACT. The intake step maps each tier to a concrete model
|
|
30
|
+
# that the runtime actually exposes (Claude Opus/Sonnet, Gemini, a local model,
|
|
31
|
+
# etc.). If only one model is available, both tiers collapse to it.
|
|
32
|
+
# review_tier → deep reasoning: create-story, code-review, edge-case-hunter,
|
|
33
|
+
# epic adversarial review.
|
|
34
|
+
# exec_tier → implementation: dev-story, fix loops, e2e generation.
|
|
35
|
+
review_tier_model = "claude-opus" # proposed; ask at runtime
|
|
36
|
+
exec_tier_model = "claude-sonnet" # proposed; ask at runtime
|
|
37
|
+
|
|
38
|
+
# Max story pipelines running concurrently within a single wave.
|
|
39
|
+
max_parallel_stories = 3
|
|
40
|
+
|
|
41
|
+
# Max review→fix→re-review rounds before a story is escalated as blocked.
|
|
42
|
+
fix_loop_cap = 2
|
|
43
|
+
|
|
44
|
+
# Parallelization strategy: "waves" (dependency-aware) | "sequential" | "full".
|
|
45
|
+
parallelism_strategy = "waves"
|
|
46
|
+
|
|
47
|
+
# Human gates. Dev + review run unattended; these two are always confirmed.
|
|
48
|
+
gate_before_publish = true
|
|
49
|
+
gate_before_pr = true
|
|
50
|
+
|
|
51
|
+
# Release behavior at the publish gate.
|
|
52
|
+
npm_dist_tag = "beta"
|
|
53
|
+
version_bump = "prerelease" # npm version <bump> --preid=beta
|
|
54
|
+
pack_ignore_scripts = true # avoid Windows prepare tarball leak
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
# Per-Story Pipeline Contract
|
|
2
|
+
|
|
3
|
+
This is the self-contained instruction set handed to each story subagent. The
|
|
4
|
+
orchestrator fills the `<…>` placeholders before spawning. The subagent owns
|
|
5
|
+
exactly one story, in exactly one worktree, and never touches the epic branch.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Inputs (filled by the orchestrator)
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
STORY_ID = <id>
|
|
13
|
+
STORY_TITLE = <title>
|
|
14
|
+
EPIC_ID = <epic-id>
|
|
15
|
+
EPIC_BRANCH = feature/epic-<epic-id>
|
|
16
|
+
STORY_BRANCH = feature/epic-<epic-id>-story-<id>
|
|
17
|
+
WORKTREE = .worktrees/epic-<epic-id>-story-<id>
|
|
18
|
+
SPRINT_STATUS = <path to sprint-status.yaml>
|
|
19
|
+
EXEC_MODEL = <execution-tier model | "host-default">
|
|
20
|
+
REVIEW_MODEL = <review-tier model | "host-default">
|
|
21
|
+
FIX_LOOP_CAP = <n>
|
|
22
|
+
TEST_CMD = <project test/build gate>
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
## Setup
|
|
26
|
+
|
|
27
|
+
All git follows `git-workflow-skill`; the only override is the base branch
|
|
28
|
+
(the story branch is cut from `<EPIC_BRANCH>`, not `dev`).
|
|
29
|
+
|
|
30
|
+
1. Create the worktree off the epic branch, per `git-workflow-skill` (manual
|
|
31
|
+
form shown, base overridden to the epic branch):
|
|
32
|
+
```bash
|
|
33
|
+
git worktree add <WORKTREE> -b <STORY_BRANCH> <EPIC_BRANCH>
|
|
34
|
+
```
|
|
35
|
+
2. Work **only** inside `<WORKTREE>`. Use the Conventional Commit format the
|
|
36
|
+
skill enforces (`feat`, `fix`, `test`, `docs`, `refactor`, `chore`, `ci`),
|
|
37
|
+
scoped to the story. Honor the skill's git hooks.
|
|
38
|
+
|
|
39
|
+
## Pipeline
|
|
40
|
+
|
|
41
|
+
### 1. Create story spec — `bmad-create-story` [REVIEW_MODEL]
|
|
42
|
+
Produce the context-filled spec for `<STORY_ID>`. If the spec already exists and
|
|
43
|
+
is complete, validate it instead of regenerating. The spec's acceptance criteria
|
|
44
|
+
(ACs) are the contract for the Definition of Done.
|
|
45
|
+
|
|
46
|
+
**INVEST & size gate (before implementing).** Once the spec is fleshed out,
|
|
47
|
+
re-check it against INVEST and the sizing/focus heuristics (same criteria as
|
|
48
|
+
step-02): one focused goal, small enough to reach Definition of Done in this
|
|
49
|
+
single pass, testable ACs. A spec often only reveals its true size here. **If
|
|
50
|
+
the story is too large or pursues more than one goal, do NOT implement it** —
|
|
51
|
+
return immediately with `status: needs-split` and a `split_proposal` (the
|
|
52
|
+
smallest set of INVEST-compliant sub-stories, each with a focused goal, derived
|
|
53
|
+
ids, and refined dependencies). The orchestrator owns the split because it
|
|
54
|
+
affects the epic-wide wave plan (see step-04). Only proceed to step 2 when the
|
|
55
|
+
story passes the gate.
|
|
56
|
+
|
|
57
|
+
### 2. Implement — `bmad-dev-story` [EXEC_MODEL]
|
|
58
|
+
Implement strictly against the spec. Follow the repo's always-load skills
|
|
59
|
+
(language best-practices, logging, test-accompanied-development, etc.). Commit.
|
|
60
|
+
|
|
61
|
+
### 3. Adversarial + edge-case review (PARALLEL) [REVIEW_MODEL]
|
|
62
|
+
Run both, ideally as parallel sub-subagents, each seeing the story diff:
|
|
63
|
+
- `bmad-code-review` — full adversarial review against spec + context.
|
|
64
|
+
- `bmad-review-edge-case-hunter` — exhaustive boundary/branch analysis.
|
|
65
|
+
Collect both findings sets.
|
|
66
|
+
|
|
67
|
+
### 4. Triage & fix loop [EXEC_MODEL]
|
|
68
|
+
Classify findings as **blocking** (correctness, security, AC miss, broken build)
|
|
69
|
+
vs **non-blocking** (style, nits). For blocking findings:
|
|
70
|
+
- Run `bmad-dev-story` to fix them. Commit.
|
|
71
|
+
- Re-review **only the changed surface**.
|
|
72
|
+
- Repeat until no blocking findings remain OR `FIX_LOOP_CAP` rounds are used.
|
|
73
|
+
- If the cap is hit with blocking findings remaining → return `status: blocked`
|
|
74
|
+
with the unresolved findings. Do not merge, do not paper over.
|
|
75
|
+
Record non-blocking findings in the return notes (not fixed, by design).
|
|
76
|
+
|
|
77
|
+
### 5. E2E tests — `bmad-qa-generate-e2e-tests` [EXEC_MODEL]
|
|
78
|
+
Generate e2e/automated tests for the story's behavior and **run them**. Also run
|
|
79
|
+
`<TEST_CMD>` to confirm the story didn't break the package build. If e2e cannot
|
|
80
|
+
be made green within the fix budget, return `status: blocked` with details.
|
|
81
|
+
|
|
82
|
+
### 6. Definition of Done (gate before returning ready)
|
|
83
|
+
ALL must hold, or the story is `blocked`:
|
|
84
|
+
- [ ] All spec acceptance criteria implemented.
|
|
85
|
+
- [ ] No blocking findings remain from either reviewer.
|
|
86
|
+
- [ ] E2E tests written and passing.
|
|
87
|
+
- [ ] `<TEST_CMD>` passes on the story branch (modulo known pre-existing failures).
|
|
88
|
+
- [ ] All work committed with Conventional Commit messages.
|
|
89
|
+
|
|
90
|
+
## Return value (structured)
|
|
91
|
+
|
|
92
|
+
```
|
|
93
|
+
{
|
|
94
|
+
"story_id": "<STORY_ID>",
|
|
95
|
+
"status": "merged-ready" | "blocked" | "needs-split",
|
|
96
|
+
"branch": "<STORY_BRANCH>",
|
|
97
|
+
"worktree": "<WORKTREE>",
|
|
98
|
+
"commits": [ "<sha> <subject>", … ],
|
|
99
|
+
"e2e_status": "passing" | "failing" | "not-created",
|
|
100
|
+
"unresolved_findings": [ "<blocking finding>", … ],
|
|
101
|
+
"split_proposal": [ { "id": "<S3a>", "goal": "<focused goal>", "acs": [ … ], "depends_on": [ … ] }, … ],
|
|
102
|
+
"fix_rounds_used": <n>,
|
|
103
|
+
"notes": "<non-blocking findings, decisions, caveats>"
|
|
104
|
+
}
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
`split_proposal` is populated only when `status: needs-split` (empty/omitted
|
|
108
|
+
otherwise). On `needs-split` the subagent has done **no** implementation — it
|
|
109
|
+
returns the proposal and stops.
|
|
110
|
+
|
|
111
|
+
**Do NOT** merge into `<EPIC_BRANCH>`. The orchestrator serializes all
|
|
112
|
+
integration into the epic branch (step-04) to avoid parallel-merge races.
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
# Step 01 — Intake & Guided Configuration
|
|
2
|
+
|
|
3
|
+
**Goal:** Confirm the epic exists and is ready, then collect the run configuration through guided questions. Nothing is spawned and no branch is created until this step completes.
|
|
4
|
+
|
|
5
|
+
## 1. Locate and validate the epic (PRECONDITION)
|
|
6
|
+
|
|
7
|
+
This skill *runs* an epic; it does not invent one. Find the target epic:
|
|
8
|
+
|
|
9
|
+
1. Read `{sprint_status}` (`{implementation_artifacts}/sprint-status.yaml`) and the epics/stories planning artifacts under `{planning_artifacts}`.
|
|
10
|
+
2. If the user named an epic (id or title), select it. Otherwise list candidate epics and **HALT** for the user to choose.
|
|
11
|
+
3. Enumerate the epic's stories. For each story capture: id, title, status, and declared dependencies / "depends on" / prerequisite references.
|
|
12
|
+
|
|
13
|
+
**If the epic has no stories**, or stories are placeholders without acceptance criteria: STOP and tell the user to run `bmad-create-epics-and-stories` (and `bmad-sprint-planning`) first. Do not fabricate stories.
|
|
14
|
+
|
|
15
|
+
**If some stories are already `done`/`merged`**: by default skip them (treat as satisfied dependencies). Confirm this with the user.
|
|
16
|
+
|
|
17
|
+
## 2. Ask the guided questions
|
|
18
|
+
|
|
19
|
+
Ask these as a single grouped set (use the host's structured-question UI if available; otherwise a numbered list). Show the proposed default from `{workflow.defaults}` for each and accept "use defaults".
|
|
20
|
+
|
|
21
|
+
1. **Model tiers (tier-abstract — critical for disconnected/non-Claude runtimes).**
|
|
22
|
+
First ask: *what models does this runtime actually expose?* Then map:
|
|
23
|
+
- `{review_model}` — deep reasoning tier (create-story, code-review, edge-case-hunter, epic adversarial review). Default: `{workflow.defaults.review_tier_model}`.
|
|
24
|
+
- `{exec_model}` — execution tier (dev-story, fix loops, e2e). Default: `{workflow.defaults.exec_tier_model}`.
|
|
25
|
+
- If only ONE model is available (air-gapped local model, or a single-provider CLI), **collapse both tiers to it** and note that tier separation is disabled.
|
|
26
|
+
- If the runtime is not Claude (e.g. Gemini, Codex, a local model) or does not support per-subagent model selection, record the mapping anyway but note it is **best-effort**: subagents will use whatever model the host assigns. Never block on this.
|
|
27
|
+
|
|
28
|
+
2. **Parallelism strategy** — default `{workflow.defaults.parallelism_strategy}`:
|
|
29
|
+
- `waves` (recommended): dependency-aware; independent stories run in parallel, dependents wait for their predecessors to merge.
|
|
30
|
+
- `sequential`: one story fully done before the next.
|
|
31
|
+
- `full`: all stories at once (warn: ignores dependencies; high merge-conflict / broken-build risk).
|
|
32
|
+
|
|
33
|
+
3. **Max parallel stories per wave** — default `{workflow.defaults.max_parallel_stories}`. Cap to what the host can sanely run concurrently.
|
|
34
|
+
|
|
35
|
+
4. **Fix-loop cap** — default `{workflow.defaults.fix_loop_cap}`. Max review→fix→re-review rounds before a story is escalated as `blocked`.
|
|
36
|
+
|
|
37
|
+
5. **Release gates** — confirm both default to ON: pause before npm publish (`{workflow.defaults.gate_before_publish}`) and before the epic PR (`{workflow.defaults.gate_before_pr}`). Confirm `{workflow.defaults.npm_dist_tag}` (default `beta`) and the version bump (default `{workflow.defaults.version_bump}`).
|
|
38
|
+
|
|
39
|
+
6. **Test command** — the project's real test/build gate for the package-integrity check (step-05). Propose `npm run build:plugin` plus the targeted test subset; confirm. (Note: bare `npm test` has a known pre-existing CRLF failure on Windows — see step-05; do not rely on its exit code alone.)
|
|
40
|
+
|
|
41
|
+
## 3. Record the resolved configuration
|
|
42
|
+
|
|
43
|
+
Write the resolved config into the Run Ledger header and mirror it to
|
|
44
|
+
`{implementation_artifacts}/epic-runs/<epic-id>/run-ledger.md`:
|
|
45
|
+
|
|
46
|
+
```
|
|
47
|
+
Epic: <id> — <title>
|
|
48
|
+
Stories: <n> ( <ids…> ) skipped(done): <ids…>
|
|
49
|
+
review_model: <model> exec_model: <model> (tiers collapsed: yes/no)
|
|
50
|
+
strategy: <waves|sequential|full> max_parallel: <n> fix_cap: <n>
|
|
51
|
+
gates: publish=<on/off> pr=<on/off> dist-tag=<tag> bump=<bump>
|
|
52
|
+
test_gate: <command(s)>
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## 4. Confirm and proceed
|
|
56
|
+
|
|
57
|
+
Present the resolved config in one compact block and **HALT for a single go/no-go confirmation**. This is the last broad confirmation — after "go", stories run unattended through to the two release gates.
|
|
58
|
+
|
|
59
|
+
On "go": read fully and follow `./steps/step-02-plan-waves.md`.
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# Step 02 — Right-Size Stories, Build the Dependency DAG, Compute Waves
|
|
2
|
+
|
|
3
|
+
**Goal:** Make the story set sound (INVEST-compliant, focused, appropriately small) and then turn it into an ordered set of execution waves so independent stories parallelize and dependents only start once their prerequisites are merged.
|
|
4
|
+
|
|
5
|
+
## 1. INVEST & story-sizing pre-pass
|
|
6
|
+
|
|
7
|
+
Before graphing dependencies, assess **every** non-skipped story against **INVEST**:
|
|
8
|
+
|
|
9
|
+
- **I**ndependent — minimal coupling to other stories (soft-couples become dependency edges in §2, not blockers).
|
|
10
|
+
- **N**egotiable — describes intent, not a frozen implementation.
|
|
11
|
+
- **V**aluable — delivers a discrete, demonstrable slice of user/system value.
|
|
12
|
+
- **E**stimable — small and clear enough to estimate with confidence.
|
|
13
|
+
- **S**mall — completable within a single focused pipeline run; **one** focused goal.
|
|
14
|
+
- **T**estable — has acceptance criteria that can be verified (and later turned into e2e tests).
|
|
15
|
+
|
|
16
|
+
**Sizing / focus heuristics — a story is "too long" and should be split if any hold:**
|
|
17
|
+
- it pursues more than one distinct goal, or its title contains "and" joining separable outcomes;
|
|
18
|
+
- it spans multiple unrelated modules/layers that could ship and be tested independently;
|
|
19
|
+
- its acceptance criteria are so numerous that they read like several stories stapled together;
|
|
20
|
+
- it cannot plausibly reach Definition of Done (implement + review + e2e) in one focused pass.
|
|
21
|
+
|
|
22
|
+
**When a story is too large or multi-goal:** split it into the smallest set of INVEST-compliant sub-stories, each with one focused goal and its own acceptance criteria. Preserve the original as a parent/epic-let reference, give sub-stories derived ids (e.g. `S3` → `S3a`, `S3b`), and carry over / refine dependencies. **Present the proposed split to the user and HALT for confirmation** before committing it to `sprint-status.yaml` (splitting changes the planned scope). Record the final, right-sized story set — it is the input to §2.
|
|
23
|
+
|
|
24
|
+
> This is the planning-time pass. The per-story pipeline (`references/story-pipeline.md`) re-checks INVEST after `bmad-create-story` and can still return `needs-split` if a story only reveals its true size once its spec is fleshed out — see step-04's handling.
|
|
25
|
+
|
|
26
|
+
## 2. Build the dependency graph
|
|
27
|
+
|
|
28
|
+
For every non-skipped story, resolve its dependencies into a directed graph (edge `A → B` means "A depends on B; B must merge first"). Sources of dependencies, in priority order:
|
|
29
|
+
|
|
30
|
+
1. Explicit `depends_on` / prerequisite fields in `sprint-status.yaml` or the story spec.
|
|
31
|
+
2. Stated dependencies in the epic / story prose ("requires the API from story X").
|
|
32
|
+
3. Shared-file heuristics: if two stories are known to edit the same module, treat them as a soft conflict (same-wave concurrency risk) and prefer to sequence them.
|
|
33
|
+
|
|
34
|
+
## 3. Detect cycles
|
|
35
|
+
|
|
36
|
+
Run a topological sort. **If a cycle exists**, STOP and report the cycle to the user — a circular dependency cannot be waved automatically. Offer to (a) break the cycle by merging the stories, or (b) force a user-specified order.
|
|
37
|
+
|
|
38
|
+
## 4. Compute waves by strategy
|
|
39
|
+
|
|
40
|
+
- **`waves`** (default): Wave *k* = all stories whose dependencies are all satisfied by waves `< k`. Within a wave, cap concurrent pipelines at `max_parallel_stories`; if a wave is larger, run it in batches.
|
|
41
|
+
- **`sequential`**: one story per wave, in topological order.
|
|
42
|
+
- **`full`**: a single wave of all stories (only if the user explicitly chose this; re-warn about conflict risk).
|
|
43
|
+
|
|
44
|
+
## 5. Present the plan
|
|
45
|
+
|
|
46
|
+
Show the wave plan compactly and record it in the Run Ledger:
|
|
47
|
+
|
|
48
|
+
```
|
|
49
|
+
Wave 1: S1, S2, S3 (independent)
|
|
50
|
+
Wave 2: S4 (needs S1), S5 (needs S2)
|
|
51
|
+
Wave 3: S6 (needs S4,S5)
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Do **not** HALT here (the user already gave go in step-01) — but if the computed plan reveals a problem the user could not have anticipated (e.g. every story is sequential and the user expected parallelism, or a story has unresolved/dangling dependencies), surface it in one line and HALT for a decision.
|
|
55
|
+
|
|
56
|
+
Then read fully and follow `./steps/step-03-epic-branch.md`.
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Step 03 — Create the Epic Feature Branch
|
|
2
|
+
|
|
3
|
+
**Goal:** Establish the integration branch for the whole epic, off the trunk, before any story work begins. This is the branch the final PR targets `main` from, and the branch every story branch merges back into.
|
|
4
|
+
|
|
5
|
+
## Branch topology (the contract)
|
|
6
|
+
|
|
7
|
+
```
|
|
8
|
+
main
|
|
9
|
+
└── feature/epic-<epic-id> ← epic integration branch (this step)
|
|
10
|
+
├── feature/epic-<epic-id>-story-<s1> ← per-story branch (step-04, own worktree)
|
|
11
|
+
├── feature/epic-<epic-id>-story-<s2>
|
|
12
|
+
└── … each merges back into feature/epic-<epic-id>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
- The **epic branch** is cut from `main` (this repo's trunk; confirm the trunk name — `main` here).
|
|
16
|
+
- Each **story branch** is cut from the **epic branch**, developed in its own worktree, and merged back into the epic branch when it passes its Definition of Done (step-04). Stories integrate with `--no-ff` so each story is one reviewable merge commit. No PR per story (the user approves only the epic PR).
|
|
17
|
+
- The single **epic PR** (step-06) is `feature/epic-<epic-id>` → `main`.
|
|
18
|
+
|
|
19
|
+
## Procedure
|
|
20
|
+
|
|
21
|
+
All git here follows `git-workflow-skill`. The only epic-specific override is the **base branch**: the epic branch is cut from the **trunk** (`main`), not from `dev`.
|
|
22
|
+
|
|
23
|
+
1. Follow `git-workflow-skill` to create the epic worktree + feature branch, with the base overridden to the trunk. Use its `start-feature.sh` if it accepts a base argument; otherwise use the skill's documented **manual** equivalent:
|
|
24
|
+
```bash
|
|
25
|
+
git fetch origin
|
|
26
|
+
# git-workflow-skill manual form, base overridden to the trunk:
|
|
27
|
+
git worktree add .worktrees/epic-<epic-id> -b feature/epic-<epic-id> main
|
|
28
|
+
```
|
|
29
|
+
(`.worktrees/` is gitignored in this repo. Confirm the trunk name first — `main` here. Ensure the skill's git hooks are installed so commit-message/branch protections apply.)
|
|
30
|
+
2. Record the epic worktree path and branch in the Run Ledger.
|
|
31
|
+
3. Story worktrees are created later, one per story, branched from `feature/epic-<epic-id>` — see step-04.
|
|
32
|
+
|
|
33
|
+
**Do not** write any non-git file outside a worktree from here on. All story output lands in story worktrees; all integration lands on the epic branch.
|
|
34
|
+
|
|
35
|
+
Then read fully and follow `./steps/step-04-run-waves.md`.
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Step 04 — Run the Waves (Parallel Per-Story Pipelines)
|
|
2
|
+
|
|
3
|
+
**Goal:** Execute each wave by spawning one subagent per story, each running the full per-story pipeline in its own worktree, then integrating passing stories back into the epic branch. This is the core of the orchestration.
|
|
4
|
+
|
|
5
|
+
## How subagents are used
|
|
6
|
+
|
|
7
|
+
- Spawn **one subagent per story** using the host's Agent/Task tool. Put all spawns for a wave (up to `max_parallel_stories`) in a **single response** so they run concurrently.
|
|
8
|
+
- Each subagent is **stateless w.r.t. this conversation** — it receives a self-contained prompt (the story-pipeline contract below) plus the paths it needs. It must not assume access to the orchestrator's context.
|
|
9
|
+
- Assign each subagent the model implied by the step it is running (`{review_model}` vs `{exec_model}`). Because a single subagent runs multiple BMAD skills across both tiers, prefer this split:
|
|
10
|
+
- If the host supports per-skill model switching inside one subagent, instruct it to use `{review_model}` for create-story/code-review/edge-case-hunter and `{exec_model}` for dev-story/fixes/e2e.
|
|
11
|
+
- If not, run the story as **two chained subagents**: an `{exec_model}` "builder" and a `{review_model}` "reviewer", handing the worktree between them.
|
|
12
|
+
- If model selection is unavailable (non-Claude / single-model runtime), run one subagent and note tiers are collapsed.
|
|
13
|
+
|
|
14
|
+
## Per-story pipeline (the contract every story subagent runs)
|
|
15
|
+
|
|
16
|
+
Give each story subagent the full contract in `references/story-pipeline.md` (skill-root–relative). The inline summary below is **illustrative only** — `references/story-pipeline.md` is the authoritative contract; if they diverge, the reference file wins. In summary, in the story's own worktree branched from the epic branch:
|
|
17
|
+
|
|
18
|
+
1. `bmad-create-story` → produce the context-filled story spec. [review tier]
|
|
19
|
+
2. `bmad-dev-story` → implement against the spec. [exec tier]
|
|
20
|
+
3. Parallel review: `bmad-code-review` **and** `bmad-review-edge-case-hunter`. [review tier]
|
|
21
|
+
4. Triage findings → if any are blocking, `bmad-dev-story` fix loop (cap `fix_loop_cap`), then re-review only the changed surface. [exec tier]
|
|
22
|
+
5. `bmad-qa-generate-e2e-tests` → generate e2e tests and run them. [exec tier]
|
|
23
|
+
6. Enforce the **Definition of Done** (review clean + e2e green + spec ACs met). Commit with Conventional Commits.
|
|
24
|
+
|
|
25
|
+
The subagent returns a structured result: `{story_id, status: merged-ready|blocked|needs-split, branch, worktree, commits, unresolved_findings[], split_proposal[], e2e_status, notes}`. It must **not** merge to the epic branch itself — the orchestrator integrates (step below) to keep merges serialized. A `needs-split` result means the story was found too large/multi-goal at spec time and was **not** implemented — the orchestrator handles the split (see below).
|
|
26
|
+
|
|
27
|
+
## Wave loop
|
|
28
|
+
|
|
29
|
+
For each wave in order:
|
|
30
|
+
|
|
31
|
+
1. **Spawn** the wave's story subagents in parallel (respect `max_parallel_stories`; batch if larger). Mark each story `in-progress` in the Run Ledger.
|
|
32
|
+
2. **Collect** results as subagents return. Update the Ledger per story.
|
|
33
|
+
3. **Handle `needs-split` results**: the story was found too large/multi-goal and was not implemented. Apply its `split_proposal`: present the proposed sub-stories to the user and **HALT for confirmation** (splitting changes planned scope), then add the confirmed sub-stories to `sprint-status.yaml`, replace the parent in the Ledger, recompute affected dependencies/waves (re-enter step-02's §2–§4 for just the new stories), and schedule the sub-stories into the current wave (if independent) or a later wave. Discard the parent's unused story worktree/branch via `git-workflow-skill` cleanup.
|
|
34
|
+
4. **Integrate** each `merged-ready` story into the epic branch, **one at a time** (serialized), from the epic worktree (use the epic worktree path recorded in the Run Ledger, not a re-derived guess). Use `git-workflow-skill` conventions; the merge into the epic branch is the epic-specific manual step:
|
|
35
|
+
```bash
|
|
36
|
+
git -C <epic-worktree> merge --no-ff feature/epic-<epic-id>-story-<sid>
|
|
37
|
+
```
|
|
38
|
+
- On a **merge conflict**: do not guess. Spawn an `{exec_model}` subagent scoped to resolve only that conflict against both stories' intent, or HALT and report if it cannot. Re-run that story's e2e after resolution.
|
|
39
|
+
- After a successful merge, run the project build/test gate (the step-01 `test_gate`) on the epic branch to catch cross-story breakage early. If it breaks, treat as a blocking finding against the just-merged story.
|
|
40
|
+
5. **Blocked stories**: a story that exhausts `fix_loop_cap` without converging, or whose e2e cannot pass, is marked `blocked` with its `unresolved_findings`. Do **not** silently drop it. Continue the epic with the rest, but record it for the step-05 report and the PR description. If a *downstream* story depends on a blocked story, mark the dependents `blocked (upstream)` and skip their wave entry.
|
|
41
|
+
6. Clean up each story worktree after its merge, per `git-workflow-skill` (manual form: `git worktree remove .worktrees/epic-<epic-id>-story-<sid>`).
|
|
42
|
+
|
|
43
|
+
**Persist the Run Ledger to disk** (`{implementation_artifacts}/epic-runs/<epic-id>/run-ledger.md`) after integrating each story and again at the end of each wave, so a crashed run can be resumed without redoing merged stories.
|
|
44
|
+
|
|
45
|
+
Proceed to the next wave only when the current wave's stories are all `merged` or `blocked`.
|
|
46
|
+
|
|
47
|
+
## After all waves
|
|
48
|
+
|
|
49
|
+
Record the final tally in the Run Ledger (merged / blocked / skipped) and persist it to disk. Then read fully and follow `./steps/step-05-epic-adversarial.md`.
|