Skip to content

Workflow Overview

The ACT workflow is a structured pipeline where each stage produces artifacts that feed the next. Humans review between stages — AI does the work, you make the decisions.

Spec → Refine Spec → Plan → Work → Compound
Command/act:workflow:spec
InputA task description (text or file)
OutputA detailed specification in ai_specs/

The spec command transforms a vague idea into a precise document:

  • Asks 2-4 clarifying questions to fill gaps
  • Maps user flows (happy path, errors, edge cases)
  • Produces numbered requirements
  • Specifies validation criteria and test expectations

Human checkpoint: Review the spec. Is this what you want built?

Command/act:workflow:refine-spec
InputA spec file
OutputFindings organized by severity, with suggested fixes

An adversarial review that catches problems before implementation:

  • Gaps — missing requirements or underspecified behavior
  • Wrong assumptions — things the spec assumes that don’t match your codebase
  • UX incoherence — flows that don’t make sense from a user’s perspective
  • Data model issues — models that don’t support the described UX
  • Codebase misalignment — patterns that conflict with how your project actually works

Human checkpoint: Decide which findings to address before planning.

Command/act:workflow:plan
InputA spec file (or task description)
OutputA phased implementation plan in ai_specs/

The plan command analyzes your codebase and creates a concrete implementation strategy:

  • Researches project structure, state management, and conventions
  • Breaks work into phases with specific file paths and tasks
  • Includes TDD test-first tasks where applicable
  • Each phase has verification steps (flutter analyze && flutter test)

Use --use-subagents for deeper research with parallel background agents.

Human checkpoint: Review the plan. Does the approach make sense?

Command/act:workflow:work
InputA plan file
OutputWorking code with commits and a pull request

The work command executes the plan phase by phase:

  • Loads Flutter knowledge (patterns, principles, breaking changes)
  • Executes the plan phase by phase, with commits at logical checkpoints
  • Runs flutter analyze and flutter test at each phase
  • Creates a pull request when all phases are complete

Human checkpoint: Run the app and smoke test. Request visual tweaks or fixes as needed.

Command/act:workflow:compound
InputCurrent session context (optionally: spec/plan path, hints)
OutputA reusable insight document in ai_docs/solutions/

The compound command captures what was learned during the session:

  • Extracts key decisions and tradeoffs
  • Documents patterns and pitfalls
  • Saves reusable insights organized by category
  • Future sessions can reference these insights

Each command produces artifacts that the next command consumes:

StageReadsProduces
SpecTask description*-spec.md
Refine Spec*-spec.md + codebaseFindings + updated spec
Plan*-spec.md + codebase*-plan.md
Work*-plan.md + *-spec.mdCode + commits + PR
CompoundSession contextai_docs/solutions/*.md

This chain reduces ambiguity at each step. By the time code is written, the AI has a spec with clear requirements, a plan with concrete tasks, and knowledge of your codebase’s patterns.

Not every task needs the full pipeline:

  • Quick fix: Skip spec and plan — just describe the fix and use /act:workflow:work with a task description
  • Simple feature: Write a spec, skip refine-spec, go straight to plan
  • Complex feature: Use the full pipeline including refine-spec and --use-subagents for planning
  • Bug investigation: Start with spec to document what’s wrong, then plan the fix