Skip to content
This repository was archived by the owner on Apr 11, 2026. It is now read-only.

Commit 030daa5

Browse files
z23ccclaude
andcommitted
feat: implement 7 BMAD-METHOD patterns + write-file command (v0.1.43)
New features inspired by BMAD-METHOD deep analysis: 1. project-context.md shared context — Worker Phase 2 reads .flow/project-context.md 2. Zero-findings-halt review rule — reviewers must find issues, zero = reanalysis 3. Structured DoD checklist — flowctl checklist init/check/verify (8 items, 4 categories) 4. Quick-dev fast path — --quick flag skips brainstorm/plan for trivial changes 5. Advanced elicitation — Pre-mortem, First Principles, Inversion in brainstorm 6. Step-file architecture — 15 step files across plan/work/brainstorm (JIT loading) 7. 3-layer parallel code review — Blind Hunter + Edge Case Hunter + Acceptance Auditor Also adds flowctl write-file command for zero-interaction pipeline file I/O, and 3 deep comparison documents (vs compound-engineering, vs BMAD-METHOD). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent a05d4ac commit 030daa5

46 files changed

Lines changed: 3401 additions & 1499 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.claude-plugin/marketplace.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@
66
},
77
"metadata": {
88
"description": "Structured plan-first development plugin for Claude Code with .flow/ task tracking, Agent Teams, and Ralph autonomous mode",
9-
"version": "0.1.42"
9+
"version": "0.1.43"
1010
},
1111
"plugins": [
1212
{
1313
"name": "flow-code",
1414
"description": "Zero-dependency planning + execution with .flow/ task tracking. Three-layer quality (guard + RP plan-review + Codex adversarial). Full-auto, zero questions. Teams auto-parallel, DAG mutation, Codex-driven decisions, auto draft-PR, session summary. 5 prompt templates. 24 subagents, 22 commands, 74 skills.",
15-
"version": "0.1.42",
15+
"version": "0.1.43",
1616
"source": "./",
1717
"category": "workflow",
1818
"tags": [
@@ -26,5 +26,5 @@
2626
"strict": true
2727
}
2828
],
29-
"version": "0.1.42"
29+
"version": "0.1.43"
3030
}

.claude-plugin/plugin.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "flow-code",
3-
"version": "0.1.42",
3+
"version": "0.1.43",
44
"description": "Zero-dependency planning + execution with .flow/ task tracking and Ralph autonomous mode (multi-model review gates). Worker subagent per task with git worktree isolation for parallel execution. Three-layer quality system (guard + RP plan-review + Codex adversarial). Full-auto by default — AI decides from context, zero questions. Teams-default with file locking, DAG mutation, Codex-driven conflict resolution, auto draft-PR. Auto-detected stack profiles with one-command guard (test/lint/typecheck). Enhanced agent definitions with permissionMode/maxTurns/effort. Lifecycle hooks with state preservation (PreCompact injects .flow state into compaction, TaskCompleted auto-unlocks files, SubagentStart context injection). Memory v2 with atomic entries, dedup, and progressive disclosure. TDD enforcement mode. Multi-epic queue with dependency visualization. Includes 24 subagents, 22 commands, 74 skills.",
55
"author": {
66
"name": "z23cc",

.codex-plugin/plugin.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "flow-code",
3-
"version": "0.1.42",
3+
"version": "0.1.43",
44
"description": "Zero-dependency planning + execution with .flow/ task tracking and Ralph autonomous mode (multi-model review gates). Worker subagent per task with git worktree isolation for parallel execution. Three-layer quality system (guard + RP plan-review + Codex adversarial). Full-auto by default. Teams-default with file locking, DAG mutation, Codex-driven conflict resolution, auto draft-PR.",
55
"author": {
66
"name": "z23cc",

CLAUDE.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ All three must pass (or be skipped via `flowctl config set review.backend none`)
6060
| `--research=rp\|grep` | plan | Override research backend |
6161
| `--depth=short\|standard\|deep` | plan | Override plan depth |
6262
| `--review=rp\|codex\|none` | plan, run | Override review backend |
63+
| `--quick` | go, run | Fast path for trivial changes (skip brainstorm, plan review, impl review) |
6364

6465
## Worker Protocol (Teams Mode)
6566

@@ -149,6 +150,7 @@ Rust: clippy for linting, cargo test for tests. No TypeScript, no npm. Skills an
149150
- **Worker timeout**: Workers have a 30-minute default timeout per task (configurable via `worker.timeout_minutes`). On timeout: task marked failed, file locks released, wave continues
150151
- **Stale lock recovery**: Runs at wave start AND on worker completion — detects locks held by done/failed/blocked tasks and releases them to prevent deadlocks
151152
- **Worker phase mapping**: Workers execute 12 internal phases (via `flowctl worker-phase next/done`) within the epic "Work" phase. Epic phases and worker phases are independent systems operating at different levels
153+
- **Project context**: Optional `.flow/project-context.md` (template in `templates/project-context.md`) provides shared technical standards (stack, rules, architecture decisions, non-goals) that all worker agents read during Phase 2 re-anchoring. Keeps agents aligned on conventions code alone can't convey
152154

153155
## Files to Never Commit
154156

agents/worker.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,13 @@ git log -5 --oneline
209209
<FLOWCTL> config get memory.enabled --json
210210
```
211211

212+
**Read project context** (if `.flow/project-context.md` exists):
213+
```bash
214+
# Load shared technical standards (non-negotiable rules, stack details, architecture decisions)
215+
cat .flow/project-context.md 2>/dev/null
216+
```
217+
If the file exists, treat its contents as authoritative project-wide constraints. Apply any rules from "Critical Implementation Rules" and "Non-Goals" throughout all subsequent phases.
218+
212219
**If memory.enabled is true**, inject relevant memory (L1: compact index):
213220
```bash
214221
<FLOWCTL> memory inject --json

bin/flowctl

16.4 KB
Binary file not shown.

codex/skills/flow-code-brainstorm/SKILL.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,33 @@ Wait for each answer before asking the next question.
9494
9595
After all 3 answers, summarize the key insights in 2-3 bullets before proceeding.
9696

97+
## Structured Deepening
98+
99+
After self-interview completes, apply 1-2 named reasoning methods to pressure-test the output:
100+
101+
### Method Selection Guide
102+
| Method | Best for | Prompt |
103+
|--------|----------|--------|
104+
| **Pre-mortem Analysis** | Specs, plans, new features | "Assume this shipped and failed 6 months later. What are the 3 most likely causes?" |
105+
| **First Principles** | Architecture, major refactors | "Strip all assumptions. What's the simplest possible solution from ground truth?" |
106+
| **Inversion** | Risk assessment, refactoring | "How would you guarantee this fails? Now avoid those things." |
107+
| **Red Team** | Security, APIs, public surfaces | "You're an attacker. How do you break this?" |
108+
| **Constraint Removal** | Innovation, scope decisions | "Remove all constraints (time, tech, team). What changes? What stays the same?" |
109+
| **Stakeholder Mapping** | Multi-user features | "Re-evaluate from each stakeholder's perspective. Who loses?" |
110+
111+
### Auto-Selection Rules
112+
- For spec/plan tasks → Pre-mortem (default)
113+
- For architecture tasks → First Principles
114+
- For refactoring tasks → Inversion
115+
- For security-sensitive → Red Team
116+
- For scope decisions → Constraint Removal
117+
118+
### Execution
119+
1. Auto-select the most relevant method based on task type
120+
2. Apply the method's prompt to the current brainstorm output
121+
3. Append insights to requirements doc under "## Deepening Insights" section
122+
4. If insights reveal significant gaps, re-run self-interview for those specific areas
123+
97124
## Phase 2: Approach Generation
98125

99126
Generate 2-3 concrete approaches based on the answers from Phase 1 and your codebase analysis.

codex/skills/flow-code-plan/SKILL.md

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -113,13 +113,12 @@ Proceed to Step 4 immediately.
113113

114114
## Workflow
115115

116-
Read [steps.md](steps.md) and follow each step in order.
117-
118-
**CRITICAL — Step 4 (Research)**: You MUST launch ALL scouts listed in steps.md in ONE parallel Task call. Do NOT skip scouts or run them sequentially. Each scout provides unique signal.
119-
120-
If review was decided (rp/codex/export):
121-
- rp or codex: run `/flow-code:plan-review` after Step 9, fix issues until it passes
122-
- export: run `/flow-code:plan-review` with export mode after Step 9
116+
Execute steps from `steps/` directory one at a time (JIT loading — only read the current step):
117+
1. Read `steps/step-01-init.md` and execute
118+
2. Read `steps/step-02-research.md` and execute
119+
3. Read `steps/step-03-gap-analysis.md` and execute
120+
4. Read `steps/step-04-task-breakdown.md` and execute
121+
5. Read `steps/step-05-output.md` and execute
123122

124123
## Output
125124

0 commit comments

Comments
 (0)