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

Commit 39c18be

Browse files
z23ccclaude
andcommitted
fix(pipeline): close 3 doc/code gaps — GO_MODE, dual-phase clarity, Phase 3 PhaseDef (v0.1.37)
1. GO_MODE: remove phantom flag from go.md, document actual input-type detection behavior (natural language / Flow ID / spec file / --plan-only) 2. Dual-phase system: add explicit table in flow-code-run and worker.md distinguishing epic-level (6 phases) vs worker-level (12 phases) 3. Phase 3 PhaseDef: add missing Investigation phase definition to PHASE_DEFS so `flowctl worker-phase next` returns instructions for Phase 3 — consistent with all other phases instead of inline-only 4. Update work section to reference all domain skills, not just frontend Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 36b86d6 commit 39c18be

6 files changed

Lines changed: 22 additions & 4 deletions

File tree

agents/worker.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ effort: high
1212
<!-- section:core -->
1313
# Task Implementation Worker
1414

15-
You implement a single flow-code task. Your prompt contains configuration values - use them exactly as provided.
15+
You implement a single flow-code task within the epic's "work" phase. You operate at the **worker-level** (12 phases via `flowctl worker-phase next/done`), which is independent from the **epic-level** phases (brainstorm→plan→work→review→close via `flowctl phase next/done`). Multiple workers run their phases in parallel — one per task.
16+
17+
Your prompt contains configuration values - use them exactly as provided.
1618

1719
**Configuration from prompt:**
1820
- `TASK_ID` - the task to implement (e.g., fn-1.2)

bin/flowctl

0 Bytes
Binary file not shown.

commands/flow-code/go.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,8 @@ The ONLY purpose of this command is to call the flow-code-run skill. You MUST us
1010

1111
**User request:** $ARGUMENTS
1212

13-
Pass the user request to the skill with GO_MODE=true. The skill handles all pipeline logic including the brainstorm phase.
13+
Pass the user request to the skill. The skill auto-detects mode from input type:
14+
- Natural language → full pipeline (brainstorm → plan → work → review → close)
15+
- Flow ID (fn-N-*) → resume existing epic from current phase
16+
- Spec file path → plan from spec (skip brainstorm)
17+
- `--plan-only` → stop after planning

flowctl/crates/flowctl-cli/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "flowctl-cli"
3-
version = "0.1.36"
3+
version = "0.1.37"
44
description = "CLI entry point for flowctl"
55
edition.workspace = true
66
rust-version.workspace = true

flowctl/crates/flowctl-cli/src/commands/workflow/phase.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ struct PhaseDef {
6464
const PHASE_DEFS: &[PhaseDef] = &[
6565
PhaseDef { id: "1", title: "Verify Configuration", done_condition: "OWNED_FILES verified and configuration validated", instructions: "Validate OWNED_FILES list and confirm task configuration matches the epic spec." },
6666
PhaseDef { id: "2", title: "Re-anchor", done_condition: "Run flowctl show <task> and verify spec was read", instructions: "Read the task spec via flowctl show and re-anchor on acceptance criteria before coding." },
67+
PhaseDef { id: "3", title: "Investigation", done_condition: "Target files read and related patterns identified", instructions: "Read investigation targets from the task spec. If targets exist, follow them. If not, do a lightweight scan: read files listed in **Files:** and grep for 2-3 related patterns. If RP_CONTEXT is available, use context_builder for deep context. Skip only for trivial one-line config changes." },
6768
PhaseDef { id: "4", title: "TDD Red-Green", done_condition: "Failing tests written and confirmed to fail", instructions: "Write failing tests that encode the acceptance criteria, then confirm they fail." },
6869
PhaseDef { id: "5", title: "Implement", done_condition: "Feature implemented and code compiles", instructions: "Implement the feature to satisfy the spec and ensure the code compiles cleanly." },
6970
PhaseDef { id: "6", title: "Verify & Fix", done_condition: "flowctl guard passes and diff reviewed", instructions: "Run flowctl guard (lint, type-check, tests) and review the diff for correctness." },

skills/flow-code-run/SKILL.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,17 @@ Accepts:
2626
- Flow epic ID: fn-1-add-oauth (resume existing epic)
2727
- --plan-only flag to stop after planning
2828

29+
## Two-Level Phase System
30+
31+
This plugin has TWO independent phase systems operating at different levels:
32+
33+
| Level | Phases | Managed by | Scope |
34+
|-------|--------|-----------|-------|
35+
| **Epic-level** | brainstorm → plan → plan_review → work → impl_review → close (6 phases) | `flowctl phase next/done` | One epic's lifecycle |
36+
| **Worker-level** | 1→2→3→5→6→7→10→12 (up to 12 phases, varies by size/flags) | `flowctl worker-phase next/done` | One task within the Work epic-phase |
37+
38+
Epic phases are sequential. Worker phases run INSIDE the epic "work" phase — multiple workers execute their 12 phases in parallel (one per task).
39+
2940
## Phase Loop
3041

3142
Claude is the outer loop; flowctl provides phase content.
@@ -86,7 +97,7 @@ Detect input type to decide whether to execute or skip:
8697
3. Lock files: `$FLOWCTL lock --task <task-id> --files "file1,file2" --json`
8798
4. Spawn ALL ready workers in ONE parallel Agent call with isolation worktree and team_name
8899
- Include task domain in worker prompt (from task JSON `domain` field)
89-
- Frontend-domain tasks: worker auto-loads `flow-code-frontend-ui` skill
100+
- Workers auto-load domain-specific skills (frontend→UI engineering, backend→API design, etc.)
90101
5. Wait for workers, merge worktree branches back
91102
6. Mark tasks complete: `$FLOWCTL done <task-id> --summary "what was done" --json`
92103
7. Wave checkpoint: verify done, run guards

0 commit comments

Comments
 (0)