@mhd-ghaith-abtah/flow 0.7.2-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/CHANGELOG.md +87 -0
  2. package/LICENSE +21 -0
  3. package/README.md +162 -0
  4. package/adapters/e2e/_interface.md +42 -0
  5. package/adapters/e2e/none.md +15 -0
  6. package/adapters/e2e/playwright-mcp.md +86 -0
  7. package/adapters/issue-tracker/_interface.md +46 -0
  8. package/adapters/issue-tracker/github-issues.md +103 -0
  9. package/adapters/issue-tracker/linear.md +65 -0
  10. package/adapters/issue-tracker/none.md +26 -0
  11. package/adapters/pr/_interface.md +29 -0
  12. package/adapters/pr/github.md +61 -0
  13. package/adapters/pr/none.md +32 -0
  14. package/adapters/verify/_interface.md +26 -0
  15. package/adapters/verify/custom.md +27 -0
  16. package/adapters/verify/make.md +30 -0
  17. package/adapters/verify/pnpm.md +27 -0
  18. package/bin/flow.js +129 -0
  19. package/catalog.yaml +364 -0
  20. package/docs/adapters.md +99 -0
  21. package/docs/migrate-from-bmad.md +95 -0
  22. package/docs/profiles.md +81 -0
  23. package/docs/quickstart.md +82 -0
  24. package/lib/catalog.js +164 -0
  25. package/lib/commands/add.js +147 -0
  26. package/lib/commands/doctor.js +392 -0
  27. package/lib/commands/init.js +86 -0
  28. package/lib/commands/install.js +181 -0
  29. package/lib/commands/plan.js +108 -0
  30. package/lib/commands/remove.js +87 -0
  31. package/lib/commands/uninstall.js +157 -0
  32. package/lib/repo-root.js +53 -0
  33. package/package.json +62 -0
  34. package/schemas/catalog.schema.json +155 -0
  35. package/schemas/flow-config.schema.json +85 -0
  36. package/schemas/install-state.schema.json +79 -0
  37. package/skills/flow-doctor/SKILL.md +15 -0
  38. package/skills/flow-doctor/workflow.md +157 -0
  39. package/skills/flow-init/SKILL.md +10 -0
  40. package/skills/flow-init/workflow.md +420 -0
  41. package/skills/flow-sprint/SKILL.md +10 -0
  42. package/skills/flow-sprint/workflow.md +394 -0
  43. package/skills/flow-story/SKILL.md +12 -0
  44. package/skills/flow-story/workflow.md +531 -0
  45. package/templates/claude-md-section.md.tmpl +55 -0
  46. package/templates/flow-readme.md.tmpl +34 -0
  47. package/templates/flow.config.yaml.tmpl +94 -0
  48. package/templates/pr.md.tmpl +40 -0
  49. package/templates/retro.md.tmpl +58 -0
  50. package/templates/sprint.yaml.tmpl +18 -0
  51. package/templates/story.md.tmpl +35 -0
  52. package/tools/fix-caveman-shrink.sh +68 -0
  53. package/tools/lint-changelog.js +98 -0
package/catalog.yaml ADDED
@@ -0,0 +1,364 @@
1
+ # Flow catalog — the single source of truth for what can be installed.
2
+ # Validated against schemas/catalog.schema.json on every install + in CI.
3
+ #
4
+ # Structure:
5
+ # flow_components: Flow's own files (skills, adapters, templates)
6
+ # adapters: Per-category adapter list (issue-tracker, pr, e2e, verify, notification)
7
+ # mcps: MCP server definitions used by adapters
8
+ # upstreams: BMad + ECC delegation config (Flow does not own these — calls upstream installers)
9
+ # profiles: Named bundles users pick from (mini, standard, team, full)
10
+
11
+ version: 1
12
+ flow_version_compat: ">=0.0.1 <0.2.0"
13
+
14
+ # ─────────────────────────────────────────────────────────────────────────────
15
+ # FLOW COMPONENTS — Flow's own files installed via copy-file operations
16
+ # ─────────────────────────────────────────────────────────────────────────────
17
+ flow_components:
18
+
19
+ - id: core:flow-skills
20
+ family: core
21
+ description: "The four Flow skills (flow-init, flow-sprint, flow-story, flow-doctor)"
22
+ required: true
23
+ operations:
24
+ - copy: { from: "skills/flow-init", to: "$HOME/.claude/skills/flow-init" }
25
+ - copy: { from: "skills/flow-sprint", to: "$HOME/.claude/skills/flow-sprint" }
26
+ - copy: { from: "skills/flow-story", to: "$HOME/.claude/skills/flow-story" }
27
+ - copy: { from: "skills/flow-doctor", to: "$HOME/.claude/skills/flow-doctor" }
28
+
29
+ - id: core:flow-templates
30
+ family: core
31
+ description: "Project-level templates: story.md, sprint.yaml, retro.md, flow.config.yaml, pr.md"
32
+ required: true
33
+ operations:
34
+ - copy: { from: "templates", to: "$HOME/.claude/skills/flow-init/templates" }
35
+
36
+ - id: core:flow-state-store
37
+ family: core
38
+ description: "Install-state machinery — initializes $HOME/.claude/flow/install-state.json"
39
+ required: true
40
+ operations:
41
+ - ensure_dir: "$HOME/.claude/flow"
42
+ - touch: "$HOME/.claude/flow/install-state.json"
43
+
44
+ # ─────────────────────────────────────────────────────────────────────────────
45
+ # ADAPTERS — pluggable integrations selected per project in flow.config.yaml
46
+ # ─────────────────────────────────────────────────────────────────────────────
47
+ adapters:
48
+
49
+ # Issue tracker ────────────────────────────────────────────────────────────
50
+ - id: adapter:issue-tracker-linear
51
+ family: issue-tracker
52
+ description: "Linear issues via MCP — create, transition, close"
53
+ needs_mcp: [linear]
54
+ config_keys:
55
+ - { name: integrations.issue_tracker.team_key, example: "PLA", required: true }
56
+ operations:
57
+ - copy: { from: "adapters/issue-tracker/linear.md", to: "$HOME/.claude/skills/flow-story/adapters/issue-tracker/linear.md" }
58
+
59
+ - id: adapter:issue-tracker-github-issues
60
+ family: issue-tracker
61
+ description: "GitHub Issues via gh CLI"
62
+ needs_cli: [gh]
63
+ config_keys:
64
+ - { name: integrations.issue_tracker.repo, example: "ghaith/focal", auto_detect: "gh repo view --json nameWithOwner -q .nameWithOwner" }
65
+ operations:
66
+ - copy: { from: "adapters/issue-tracker/github-issues.md", to: "$HOME/.claude/skills/flow-story/adapters/issue-tracker/github-issues.md" }
67
+
68
+ - id: adapter:issue-tracker-none
69
+ family: issue-tracker
70
+ description: "No external issue tracker — sprint.yaml is the source of truth"
71
+ operations:
72
+ - copy: { from: "adapters/issue-tracker/none.md", to: "$HOME/.claude/skills/flow-story/adapters/issue-tracker/none.md" }
73
+
74
+ # PR platform ──────────────────────────────────────────────────────────────
75
+ - id: adapter:pr-github
76
+ family: pr
77
+ description: "GitHub PRs via gh CLI"
78
+ needs_cli: [gh]
79
+ operations:
80
+ - copy: { from: "adapters/pr/github.md", to: "$HOME/.claude/skills/flow-story/adapters/pr/github.md" }
81
+
82
+ - id: adapter:pr-none
83
+ family: pr
84
+ description: "No PR platform — commits go straight to main"
85
+ operations:
86
+ - copy: { from: "adapters/pr/none.md", to: "$HOME/.claude/skills/flow-story/adapters/pr/none.md" }
87
+
88
+ # E2E ──────────────────────────────────────────────────────────────────────
89
+ - id: adapter:e2e-playwright-mcp
90
+ family: e2e
91
+ description: "Headless browser journey via Playwright MCP"
92
+ needs_mcp: [playwright]
93
+ config_keys:
94
+ - { name: integrations.e2e.base_url, example: "http://localhost:3000" }
95
+ - { name: integrations.e2e.journeys_dir, default: "docs/flow/journeys" }
96
+ runtime_deps:
97
+ - { pkg_manager: "auto", install_cmd: "add -D @playwright/test", post_install: "npx playwright install chromium" }
98
+ operations:
99
+ - copy: { from: "adapters/e2e/playwright-mcp.md", to: "$HOME/.claude/skills/flow-story/adapters/e2e/playwright-mcp.md" }
100
+
101
+ - id: adapter:e2e-none
102
+ family: e2e
103
+ description: "No E2E adapter — Flow skips the E2E phase"
104
+ operations:
105
+ - copy: { from: "adapters/e2e/none.md", to: "$HOME/.claude/skills/flow-story/adapters/e2e/none.md" }
106
+
107
+ # Verify ───────────────────────────────────────────────────────────────────
108
+ - id: adapter:verify-make
109
+ family: verify
110
+ description: "Runs `make verify` as the project verification gate"
111
+ needs_cli: [make]
112
+ detect: "test -f Makefile && grep -q '^verify:' Makefile"
113
+ operations:
114
+ - copy: { from: "adapters/verify/make.md", to: "$HOME/.claude/skills/flow-story/adapters/verify/make.md" }
115
+
116
+ - id: adapter:verify-pnpm
117
+ family: verify
118
+ description: "Runs `pnpm verify` (or another script) as the verification gate"
119
+ needs_cli: [pnpm]
120
+ config_keys:
121
+ - { name: integrations.verify.script, default: "verify" }
122
+ operations:
123
+ - copy: { from: "adapters/verify/pnpm.md", to: "$HOME/.claude/skills/flow-story/adapters/verify/pnpm.md" }
124
+
125
+ - id: adapter:verify-custom
126
+ family: verify
127
+ description: "User-defined shell command as the verification gate"
128
+ config_keys:
129
+ - { name: integrations.verify.command, example: "cargo check && cargo test", required: true }
130
+ operations:
131
+ - copy: { from: "adapters/verify/custom.md", to: "$HOME/.claude/skills/flow-story/adapters/verify/custom.md" }
132
+
133
+ # ─────────────────────────────────────────────────────────────────────────────
134
+ # MCP SERVERS
135
+ # ─────────────────────────────────────────────────────────────────────────────
136
+ mcps:
137
+
138
+ - id: context7
139
+ name: "Context7"
140
+ description: "Up-to-date library/API docs lookup"
141
+ package: "@upstash/context7-mcp"
142
+ install_cmd: "claude mcp add context7 npx @upstash/context7-mcp"
143
+ detect_cmd: "claude mcp list 2>/dev/null | grep -q '^context7'"
144
+ scope_default: home
145
+ auth: none
146
+
147
+ - id: playwright
148
+ name: "Playwright MCP"
149
+ description: "Headless browser for E2E + UI verification"
150
+ package: "@playwright/mcp"
151
+ install_cmd: "claude mcp add playwright npx @playwright/mcp@latest"
152
+ detect_cmd: "claude mcp list 2>/dev/null | grep -q '^playwright'"
153
+ scope_default: project
154
+ auth: none
155
+
156
+ - id: linear
157
+ name: "Linear MCP"
158
+ description: "Linear issues — create, transition, query"
159
+ package: "@tacticlaunch/mcp-linear"
160
+ install_cmd: "claude mcp add linear npx @tacticlaunch/mcp-linear"
161
+ detect_cmd: "claude mcp list 2>/dev/null | grep -q '^linear'"
162
+ scope_default: home
163
+ auth: oauth_browser
164
+ auth_instructions: |
165
+ After install, restart Claude Code, then run /mcp.
166
+ Click "linear" → "Authenticate" → grant access in the browser tab.
167
+
168
+ - id: github-mcp
169
+ name: "GitHub MCP (optional)"
170
+ description: "GitHub repo/PR/issue access via MCP. Optional — gh CLI usually sufficient."
171
+ package: "@modelcontextprotocol/server-github"
172
+ install_cmd: "claude mcp add github npx @modelcontextprotocol/server-github"
173
+ detect_cmd: "claude mcp list 2>/dev/null | grep -q '^github'"
174
+ scope_default: home
175
+ auth: api_token
176
+ env:
177
+ - { name: GITHUB_PERSONAL_ACCESS_TOKEN, secret: true, prompt: "GitHub PAT (scopes: repo, read:org):" }
178
+ optional: true
179
+
180
+ # ─────────────────────────────────────────────────────────────────────────────
181
+ # UPSTREAMS — delegation config for BMad + ECC
182
+ # ─────────────────────────────────────────────────────────────────────────────
183
+ upstreams:
184
+
185
+ bmad:
186
+ name: "BMad Method"
187
+ repo: "https://github.com/bmad-code-org/BMAD-METHOD"
188
+ homepage: "https://bmad-code-org.github.io/BMAD-METHOD/"
189
+ detect:
190
+ check_cmd: "test -d _bmad || test -d ~/.claude/bmad"
191
+ version_path_candidates:
192
+ - "_bmad/_config/manifest.yaml"
193
+ - "_bmad/install-manifest.yaml"
194
+ installer:
195
+ cmd: "npx bmad-method install"
196
+ base_args: "--tools claude-code --yes"
197
+ module_arg: "--modules"
198
+ config_arg: "--set"
199
+ directory_arg: "--directory"
200
+ available_modules: [bmm, cis, bmb, tea, core]
201
+ curated_subsets:
202
+ none:
203
+ description: "Skip BMad entirely"
204
+ modules: []
205
+ planning-only:
206
+ description: "PRD + architecture + epics (no per-story BMad)"
207
+ modules: [bmm]
208
+ config: { bmm.skill_set: "planning" }
209
+ planning-plus-research:
210
+ description: "Planning + market/domain/technical research"
211
+ modules: [bmm]
212
+ config: { bmm.skill_set: "planning-research" }
213
+ creative-thinking:
214
+ description: "CIS module — brainstorming, design thinking, storytelling"
215
+ modules: [cis]
216
+ test-architecture:
217
+ description: "TEA module — test design, ATDD, NFR"
218
+ modules: [tea]
219
+ full:
220
+ description: "All BMad modules"
221
+ modules: [bmm, cis, bmb, tea]
222
+ passthrough:
223
+ description: "Run BMad's own interactive installer — Flow doesn't choose"
224
+ modules: null
225
+
226
+ ecc:
227
+ name: "Everything Claude Code"
228
+ repo: "https://github.com/affaan-m/everything-claude-code"
229
+ detect:
230
+ check_cmd: "test -d ~/.claude/rules/common"
231
+ version_path: "~/.claude/rules/VERSION"
232
+ installer_path_candidates:
233
+ - "~/dev-tools/everything-claude-code/install.sh"
234
+ - "/usr/local/lib/node_modules/@everything-claude-code/ecc/install.sh"
235
+ installer:
236
+ cmd: "{installer_path}"
237
+ cmd_fallback: "npx @everything-claude-code/ecc install"
238
+ base_args: "--target claude"
239
+ profile_arg: "--profile"
240
+ with_arg: "--with"
241
+ without_arg: "--without"
242
+ dry_run_arg: "--dry-run"
243
+ json_arg: "--json"
244
+ available_profiles: [minimal, core, developer, security, research, full]
245
+ curated_subsets:
246
+ none:
247
+ description: "Skip ECC — assume already installed or not needed"
248
+ profile: null
249
+ flow-essentials:
250
+ description: "Just what Flow needs: plan + code-review + prp-*"
251
+ profile: core
252
+ without: [baseline:hooks]
253
+ flow-essentials-plus-tdd:
254
+ description: "Essentials + TDD + test-coverage + E2E"
255
+ profile: developer
256
+ without: [baseline:hooks, capability:research]
257
+ security-heavy:
258
+ description: "Adds security-reviewer agent + security framework guidance"
259
+ profile: security
260
+ without: [baseline:hooks]
261
+ research-heavy:
262
+ description: "Adds research APIs + business/voice skills"
263
+ profile: research
264
+ use-ecc-default:
265
+ description: "ECC's own default developer profile, unmodified"
266
+ profile: developer
267
+ passthrough:
268
+ description: "Run ECC's installer with no overrides — ECC chooses"
269
+ profile: null
270
+
271
+ caveman:
272
+ name: "Caveman"
273
+ repo: "https://github.com/JuliusBrussee/caveman"
274
+ description: "Output-compression layer for Claude Code (~46% input, ~75% output token savings). Flow expects Caveman to be active so its outputs stay tight."
275
+ detect:
276
+ # Current Caveman installer routes via Claude Code's plugin marketplace —
277
+ # files land under ~/.claude/plugins/cache/caveman/, NOT the legacy
278
+ # ~/.claude/skills/caveman/ path. Detection probes both layouts so future
279
+ # installer changes don't break Flow.
280
+ check_cmd: "find $HOME/.claude/plugins -path '*caveman*SKILL.md' -print -quit 2>/dev/null | grep -q . || test -f $HOME/.claude/skills/caveman/SKILL.md || test -f $HOME/.claude/hooks/caveman-config.js"
281
+ hooks_cmd: "ls $HOME/.claude/hooks/caveman-* 2>/dev/null"
282
+ installer:
283
+ cmd: "curl -fsSL https://raw.githubusercontent.com/JuliusBrussee/caveman/main/install.sh | bash"
284
+ # Mirror of detect.check_cmd — succeeds for either the plugin-marketplace
285
+ # layout (current) or the legacy ~/.claude/skills/caveman/ layout (older
286
+ # installer releases). Verifies "the install landed somewhere we can find".
287
+ verify_after_cmd: "find $HOME/.claude/plugins -path '*caveman*SKILL.md' -print -quit 2>/dev/null | grep -q . || test -f $HOME/.claude/skills/caveman/SKILL.md || test -f $HOME/.claude/hooks/caveman-config.js"
288
+ security_note: "Caveman ships only via curl-pipe-bash. Flow will surface this and ask for confirmation unless --yes is passed. To inspect the script before running, set $FLOW_INSPECT_INSTALL_SCRIPTS=1 — Flow will download to /tmp first, pause for review, then execute."
289
+ available_modes: [lite, full, ultra, wenyan]
290
+ curated_subsets:
291
+ none:
292
+ description: "Skip Caveman — only choose this if you have a specific reason (e.g. you already use a different compression layer)"
293
+ mode: null
294
+ lite:
295
+ description: "Light compression. Most readable. Lower savings (~20%)."
296
+ mode: lite
297
+ full:
298
+ description: "Recommended Flow default. ~46% input / ~75% output savings."
299
+ mode: full
300
+ ultra:
301
+ description: "Maximum compression. Some readability loss in long-form responses."
302
+ mode: ultra
303
+ wenyan:
304
+ description: "Classical Chinese-style ultra-compressed mode. Experimental."
305
+ mode: wenyan
306
+
307
+ # ─────────────────────────────────────────────────────────────────────────────
308
+ # PROFILES — named bundles users pick during /flow-init
309
+ # ─────────────────────────────────────────────────────────────────────────────
310
+ profiles:
311
+
312
+ minimal:
313
+ description: "Bare Flow — no upstreams except Caveman compression, no adapters, just sprint.yaml + story files"
314
+ flow_components:
315
+ - core:flow-skills
316
+ - core:flow-templates
317
+ - core:flow-state-store
318
+ adapters:
319
+ - adapter:issue-tracker-none
320
+ - adapter:pr-none
321
+ - adapter:e2e-none
322
+ - adapter:verify-custom
323
+ mcps: []
324
+ bmad_subset: none
325
+ ecc_subset: none
326
+ caveman_subset: full # Flow expects Caveman compression — installed by default in every profile
327
+
328
+ mini:
329
+ description: "Solo dev, single repo, GitHub, light review"
330
+ extends: minimal
331
+ adapters:
332
+ - adapter:issue-tracker-github-issues
333
+ - adapter:pr-github
334
+ - adapter:verify-make
335
+ mcps: [context7]
336
+ bmad_subset: none
337
+ ecc_subset: flow-essentials
338
+ caveman_subset: full
339
+
340
+ standard:
341
+ description: "Solo or small team, formal review + PRs, Playwright"
342
+ extends: mini
343
+ adapters:
344
+ - adapter:e2e-playwright-mcp
345
+ mcps: [context7, playwright]
346
+ bmad_subset: planning-only
347
+ ecc_subset: flow-essentials-plus-tdd
348
+ caveman_subset: full
349
+
350
+ team:
351
+ description: "Small team, Linear-driven sprints, separate-model code review for fresh perspective"
352
+ extends: standard
353
+ adapters:
354
+ - adapter:issue-tracker-linear # overrides github-issues from mini
355
+ mcps: [context7, playwright, linear]
356
+ bmad_subset: full
357
+ ecc_subset: flow-essentials-plus-tdd
358
+ caveman_subset: full
359
+ # Note: review.use_separate_model is set to true in the generated
360
+ # flow.config.yaml for this profile (spawns one reviewer with a different
361
+ # model for fresh perspective). The previous `features` block here
362
+ # advertised multi_repo + audit_log + multi_llm_review — multi_repo and
363
+ # audit_log had zero implementation (E5-007 strip 2026-05-19), and
364
+ # multi_llm_review was a renamed duplicate of use_separate_model.
@@ -0,0 +1,99 @@
1
+ # Adapters
2
+
3
+ Flow's per-category adapter system lets you swap integrations without changing any skill code. There are four adapter families today; more land in v0.2.
4
+
5
+ ## Families + v0.1 options
6
+
7
+ | Family | Picks | What it does |
8
+ |---|---|---|
9
+ | `issue-tracker` | `linear`, `github-issues`, `none` | External issue mirror — create, transition, close issues from `/flow-story` |
10
+ | `pr` | `github`, `none` | Pull-request platform — open + monitor + auto-merge PRs |
11
+ | `e2e` | `playwright-mcp`, `none` | End-to-end test driver — run journeys, capture artifacts |
12
+ | `verify` | `make`, `pnpm`, `custom` | Verify command — typecheck + lint + unit tests in one |
13
+
14
+ Coming in v0.2: `jira`, `notion`, `plain` (issue-tracker); `gitlab`, `bitbucket` (pr); `cypress` (e2e); `slack`, `discord` (notification — new family).
15
+
16
+ ## Picking adapters
17
+
18
+ `/flow-init` asks during install. You can also pre-pick via the CLI:
19
+
20
+ ```
21
+ flow init --profile standard \
22
+ --with adapter:issue-tracker-linear \
23
+ --without adapter:issue-tracker-github-issues \
24
+ --yes
25
+ ```
26
+
27
+ Each family allows exactly one active adapter at a time. The catalog enforces this — picking a second adapter for the same family overrides the first.
28
+
29
+ ## Where adapters live
30
+
31
+ ```
32
+ adapters/
33
+ ├── issue-tracker/
34
+ │ ├── _interface.md # the contract every issue-tracker adapter implements
35
+ │ ├── linear.md
36
+ │ ├── github-issues.md
37
+ │ └── none.md
38
+ ├── pr/
39
+ │ ├── _interface.md
40
+ │ ├── github.md
41
+ │ └── none.md
42
+ ├── e2e/
43
+ │ ├── _interface.md
44
+ │ ├── playwright-mcp.md
45
+ │ └── none.md
46
+ └── verify/
47
+ ├── _interface.md
48
+ ├── make.md
49
+ ├── pnpm.md
50
+ └── custom.md
51
+ ```
52
+
53
+ Each adapter is a markdown file with sections for each operation in the family's `_interface.md`. `/flow-story` reads the active adapter at each phase and follows its instructions.
54
+
55
+ ## Swapping after install
56
+
57
+ ```
58
+ flow adapter swap pr github-issues # not yet implemented in v0.7
59
+ ```
60
+
61
+ Or hand-edit `flow.config.yaml`:
62
+
63
+ ```yaml
64
+ adapters:
65
+ issue_tracker: linear
66
+ pr: github
67
+ e2e: playwright-mcp
68
+ verify: make
69
+ ```
70
+
71
+ Then re-run `/flow-doctor` to verify the new adapter file is symlinked and any new MCPs / CLIs needed are installed.
72
+
73
+ ## Writing a custom adapter
74
+
75
+ 1. Read `adapters/<family>/_interface.md` — that's the contract.
76
+ 2. Copy the closest existing adapter (e.g., `pr/github.md`) to `pr/my-platform.md`.
77
+ 3. Replace each operation block with your platform's equivalent. Operations are markdown — they describe what `/flow-story` should do, not literal code.
78
+ 4. Add a `mcps:` and `requires_cli:` block at the top if your adapter needs external infra.
79
+ 5. Register the adapter in `catalog.yaml` under the right family.
80
+ 6. Add the catalog entry to your active profile via `--with adapter:pr-my-platform`.
81
+
82
+ ## The `none` adapter
83
+
84
+ Every family has a `none` adapter. It's not a no-op — it tells `/flow-story` to **not** invoke that phase at all. E.g., `pr-none` means commit the story directly to the current branch without opening a PR. Useful for solo work or for stories that just update docs.
85
+
86
+ ## Adapter inventory
87
+
88
+ | Adapter | Requires | MCPs | Notes |
89
+ |---|---|---|---|
90
+ | `issue-tracker-linear` | — | `linear` | Needs `LINEAR_API_KEY` in `~/.claude/.env.flow` |
91
+ | `issue-tracker-github-issues` | `gh` CLI | — | Uses `gh issue` commands |
92
+ | `issue-tracker-none` | — | — | Stories live only in `sprint.yaml` |
93
+ | `pr-github` | `gh` CLI | — | Uses `gh pr create / merge --auto` |
94
+ | `pr-none` | — | — | Commits directly to current branch |
95
+ | `e2e-playwright-mcp` | — | `playwright` | Reads `## E2E Journey` blocks from stories |
96
+ | `e2e-none` | — | — | E2E phase is skipped |
97
+ | `verify-make` | `make` | — | Runs `make verify` (you define the target) |
98
+ | `verify-pnpm` | `pnpm` | — | Runs configured script (default `verify`) |
99
+ | `verify-custom` | — | — | Runs the literal command from `integrations.verify.command` |
@@ -0,0 +1,95 @@
1
+ # Migrating from BMad
2
+
3
+ Flow doesn't replace BMad — it sits on top of it and adds a lightweight per-story state layer. If you already have a BMad project with `sprint-status.yaml` and stories under `docs/_bmad-output/`, here's how to move to Flow without losing work.
4
+
5
+ ## What stays the same
6
+
7
+ - Your BMad PRD, architecture, and epic documents — `/flow-init` does NOT touch these
8
+ - Your BMad story files in `docs/_bmad-output/stories/` — Flow reads them as references
9
+ - The BMad slash commands — `/bmad-create-prd`, `/bmad-create-epic`, `/bmad-create-story` still work
10
+ - `_bmad/_config/manifest.yaml` — Flow records the BMad version for repair
11
+
12
+ ## What changes
13
+
14
+ - A new `docs/flow/` directory with:
15
+ - `sprint.yaml` — replaces `sprint-status.yaml`
16
+ - `stories/` — new per-story stubs (~30 lines each) that link back to the BMad story file as a reference
17
+ - `journeys/`, `retros/`, `archive/`, `deferred.md`, `artifacts/`
18
+ - `flow.config.yaml` — adapter + profile config (committed; team-share safe)
19
+ - A new branch convention: `flow/<story-id>-<slug>` — used by `/flow-story` for auto-branching
20
+ - `/flow-story` becomes the per-story orchestrator instead of `/bmad-create-story` + manual stepping
21
+
22
+ ## Migration
23
+
24
+ ```
25
+ /flow-init --migrate-bmad
26
+ ```
27
+
28
+ This runs `/flow-init` in migration mode. In addition to the normal install flow, it:
29
+
30
+ 1. **Parses `sprint-status.yaml`** — extracts epic IDs, story IDs, status, tags
31
+ 2. **Maps statuses** — BMad `draft|approved|in-progress|done` → Flow `backlog|todo|doing|done`
32
+ 3. **Writes `docs/flow/sprint.yaml`** — single sprint with the migrated stories
33
+ 4. **Generates Flow story stubs** — one per BMad story, with a `references:` pointer to the original BMad markdown
34
+
35
+ After migration, `/flow-sprint status` should show your full backlog. Run `/flow-story <id>` on the first migrated story and Flow will auto-detect its phase from the existing git/PR state.
36
+
37
+ ## Manual migration
38
+
39
+ If `--migrate-bmad` fails (usually: malformed `sprint-status.yaml` or non-standard epic IDs), it falls back to "no migration" mode and prints the parse error. Fix the YAML, then re-run:
40
+
41
+ ```
42
+ /flow-init --update --migrate-bmad
43
+ ```
44
+
45
+ Or do it manually:
46
+
47
+ ```yaml
48
+ # docs/flow/sprint.yaml
49
+ version: 1
50
+ sprint:
51
+ id: S1
52
+ started: 2026-05-19
53
+ goal: <copy from BMad PRD>
54
+ epics:
55
+ - id: E1
56
+ title: <copy from BMad epic>
57
+ stories:
58
+ - id: E1-001
59
+ title: <copy from BMad story>
60
+ epic: E1
61
+ status: todo
62
+ tags: [<copy>]
63
+ references:
64
+ - docs/_bmad-output/stories/E1-001-<slug>.md
65
+ ```
66
+
67
+ Then create one story stub per entry — `templates/story.md.tmpl` is the shape.
68
+
69
+ ## Coexistence
70
+
71
+ Once migrated, you can still create new BMad stories with `/bmad-create-story` and import them into Flow:
72
+
73
+ ```
74
+ /bmad-create-story # writes docs/_bmad-output/stories/E1-002-<slug>.md
75
+ /flow-sprint import-bmad # detects new BMad story files, generates Flow stubs
76
+ ```
77
+
78
+ The reverse — Flow → BMad — isn't supported. Flow's story stubs are deliberately lighter than BMad's, so round-tripping would lose information. If you need a full BMad-shape story file later, run `/bmad-create-story` and Flow will detect + link it.
79
+
80
+ ## Rollback
81
+
82
+ `docs/flow/` is fully additive. To roll back:
83
+
84
+ ```
85
+ rm -rf docs/flow/ flow.config.yaml
86
+ git checkout sprint-status.yaml # if Flow wrote a backup
87
+ ```
88
+
89
+ Flow stages a backup at `sprint-status.yaml.flow-backup-<timestamp>` before any migration write, so you can always restore.
90
+
91
+ ## Known gotchas
92
+
93
+ - **Non-standard epic IDs:** BMad allows `E3-S9b` (sub-stories). Flow's `import-bmad` parser handles this, but other forms (`E1.a`, `Epic-1-Story-1`) need a `--epic-id-pattern` override.
94
+ - **Deferred stories:** BMad's `status: deferred` maps to Flow's `deferred.md` file, not `sprint.yaml`. The migration moves them automatically.
95
+ - **Story branches:** BMad uses `feature/<story-id>`; Flow uses `flow/<story-id>-<slug>`. The migration leaves existing branches alone — only NEW stories under `/flow-story` get the new naming.
@@ -0,0 +1,81 @@
1
+ # Profiles
2
+
3
+ Profiles are named bundles that pick the right adapters + upstream subsets + MCPs for your situation. All three are mode flags on the same skills — there is no different codepath per profile.
4
+
5
+ ## At a glance
6
+
7
+ | Profile | Best for | Tokens/story | Review | E2E | PR | Issue tracker |
8
+ |---|---|---:|---|---|---|---|
9
+ | `mini` | Solo, one repo, light review | ~20k | `code-review` only | none | GitHub | GitHub Issues |
10
+ | `standard` | Solo/small team, formal review | ~40k | `code-review` + language reviewer + security on risk tags | Playwright MCP | GitHub | GitHub Issues |
11
+ | `team` | Multi-repo, multi-LLM review | ~60k | + adversarial + edge-case + separate-model reviewer | Playwright MCP | GitHub (sibling PRs) | Linear |
12
+ | `minimal` | Bare Flow, no upstreams | <10k | none | none | none | none |
13
+
14
+ ## What each profile changes
15
+
16
+ ### `minimal`
17
+
18
+ - **Adapters:** `issue-tracker-none`, `pr-none`, `e2e-none`, `verify-custom`
19
+ - **MCPs:** none
20
+ - **BMad subset:** `none`
21
+ - **ECC subset:** `none`
22
+ - **Caveman:** `full`
23
+
24
+ Just `sprint.yaml` + story files. No upstream integration. Useful when you want Flow's state model without any of the per-story machinery.
25
+
26
+ ### `mini`
27
+
28
+ Extends `minimal`. Adds:
29
+
30
+ - **Adapters:** `issue-tracker-github-issues`, `pr-github`, `verify-make`
31
+ - **MCPs:** `context7`
32
+ - **ECC subset:** `flow-essentials` (just `/plan`, `/prp-implement`, `/code-review`, `/update-docs`)
33
+
34
+ What you get: full per-story orchestration through `/flow-story` with the lightest possible review. No E2E, no language-specific reviewers, no adversarial reviewers.
35
+
36
+ ### `standard`
37
+
38
+ Extends `mini`. Adds:
39
+
40
+ - **Adapters:** `e2e-playwright-mcp`
41
+ - **MCPs:** + `playwright`
42
+ - **BMad subset:** `planning-only` (PRD, architecture, epic generation; no per-story BMad re-reads)
43
+ - **ECC subset:** `flow-essentials-plus-tdd` (adds `/tdd` and TDD harness)
44
+
45
+ What you get: full orchestration + E2E coverage for tagged stories + BMad planning artifacts on demand.
46
+
47
+ ### `team`
48
+
49
+ Extends `standard`. Adds:
50
+
51
+ - **Adapters:** overrides `issue-tracker-github-issues` → `issue-tracker-linear`
52
+ - **MCPs:** + `linear`
53
+ - **BMad subset:** `full`
54
+ - **Review:** `use_separate_model: true` — spawns one reviewer with a different model (e.g., Sonnet alongside Opus) for cross-model perspective on tagged-risky stories
55
+
56
+ What you get: full orchestration + Linear-driven sprint sync + cross-model code review on high-risk stories.
57
+
58
+ > **What you don't get (despite earlier docs promising it):** multi-repo coordinated sibling PRs and per-adapter-call audit logs. Those were aspirational features in the team-profile description through v0.7.0 with zero implementation behind them. Stripped on 2026-05-19 (sprint story E5-007). Read-only multi-repo awareness (story-id touches N repos → aggregate PR status) is tracked as a deferred backlog item; surface a real use case and we'll design it properly.
59
+
60
+ ## Swapping profiles
61
+
62
+ ```
63
+ /flow-init --update --profile <name>
64
+ ```
65
+
66
+ The installer diffs your current state against the new profile and applies only the deltas: removes obsolete adapter files, installs new ones, updates `flow.config.yaml`, re-registers MCPs.
67
+
68
+ ## Custom adjustments
69
+
70
+ You don't have to pick a stock profile. Use `--with` / `--without` to layer on top:
71
+
72
+ ```
73
+ flow init --profile mini --with adapter:e2e-playwright-mcp --yes
74
+ flow plan --profile team --without adapter:issue-tracker-linear --json
75
+ ```
76
+
77
+ `flow plan` prints the resolved bundle without executing — useful for previewing what `/flow-init` will install.
78
+
79
+ ## Inheritance
80
+
81
+ Profiles inherit via the `extends:` key in `catalog.yaml`. The merge rule for adapters is **family override** — `team` says `adapter:issue-tracker-linear`, and that replaces `mini`'s `adapter:issue-tracker-github-issues` because both belong to the `issue-tracker` family. Other lists (MCPs, components) union.