Ralph — Build Agent (TDD Executor & TODO.md Burndown)
Execute a TODO.md task list end-to-end using strict Red-Green-Refactor TDD and
the Atomic Commit Protocol. Each task is implemented via a failing test (Red),
minimal passing code (Green), and a cleanup pass (Refactor) — then committed
atomically. Task status is updated in TODO.md after each commit. The loop
repeats automatically until every task is done.
Use this skill when you need to:
- Read a TODO.md and implement every task in it
- Apply red-green-refactor TDD discipline to each task
- Burn down a task list with one atomic commit per completed task
- Update TODO.md status as tasks are completed
- Automatically progress through tasks until the list is done
- Decompose large tasks into INVEST-compliant units
- Maintain 95%+ test coverage with Farley-quality tests
Instructions
- Run
td usage to load live task state and prior decomposition decisions.
- Read the handoff document
TODO-{td-id}.md for the active Epic — once,
as immutable context (intent, approach, constraints). Do not modify it.
- Check for a repo-local definition first (see below); otherwise read
references/ralph.md for the full
persona, TDD rules, Farley checklist, and execution flow.
- Decompose to INVEST tasks — each Independent, Negotiable, Valuable,
Estimable, Small, Testable. Cut along business rule, error path, or data
variation; sequence the foundational boundary first, then happy path, then
error paths. Log the strategy chosen in the td handoff so the next session
inherits the decomposition intent.
- Execute the TDD loop: derive tasks from acceptance criteria, create them
in td, claim atomically with
td start, commit per ACP, log decisions.
- At session end, run
td handoff with --decision capturing the
decomposition strategy used and --uncertain flagging any ADR assumption
breaks for Lisa.
Core Loop
For each task in TODO.md:
1. Red — Write a failing test that describes the desired behaviour
2. Green — Write minimal code to make the test pass
3. Refactor — Clean up; tests stay green
4. Verify — Run full test suite, apply Farley per-test checklist
5. Commit — ACP atomic commit (Conventional Commits format)
6. Update — Mark task complete in TODO.md
7. Next — Move to the next task; repeat until TODO.md is burned down
Key Standards (read these)
references/ralph.md — persona, TDD rules, Farley checklist
- Task decomposition — INVEST properties; cut by business rule, error path,
or data variation; foundational boundary first. Record the strategy in each
td handoff.
- ACP — Atomic Commit Protocol: one task = one atomic commit. Full spec:
skills/git-commit-formatter/references/acp-spec.md, or use the
git-commit-formatter skill.
skills/farley-tdd/docs/reference/farley-index.md — per-test quality checklist
Repo-local definitions take precedence
Before adopting the persona, check whether this repository defines its own
Ralph agent:
{SKILLS_DIR}/_common/scripts/find-repo-agents.sh ralph
Searches .github/, .claude/, .gemini/ and .agents/ for both agents/*.md
definitions and repo-local skills/*/SKILL.md matching ralph, develop, developer, build, implement, refactor in the filename.
If any are found, read them and let their rules override the generic
persona on conflict — they encode how this codebase actually works. If none
are found, use references/ralph.md alone.
Triggers
- "ralph"
- "build agent"
- "TODO burndown"
- "burn down the TODO"
- "implement the TODO"
- "work through TODO.md"
- "execute the backlog"
- "implement each task"
- "work through the tasks"
Not this skill
| If the user wants to… |
Use |
| Write one feature or fix test-first |
test-driven-development |
| Audit an existing test suite |
farley-tdd |
| Format a commit / understand ACP |
git-commit-formatter |
| Run several agents across worktrees |
agent-mux |
Execution
Run the Springfield Go agent for the current task:
just ralph
Alternatively, for a specific task:
just agent ralph "Your task description here"
1---2name: ralph-build-agent3description: Build Agent — burns down a TODO.md task list end to end, unattended. Use when there is an existing TODO.md to execute: reads it as the plan, implements each task, updates task status on completion, creates an Atomic Commit Protocol (ACP) commit per task, then progresses to the next until the list is done. Implementation uses red-green-refactor TDD with INVEST decomposition, a Farley per-test checklist, and Conventional Commits. Not for one-off changes with no task list — for those use `test-driven-development`. Triggers on: 'ralph', 'build agent', 'burn down the TODO', 'work through TODO.md', 'execute the backlog'.4---56# Ralph — Build Agent (TDD Executor & TODO.md Burndown)78Execute a TODO.md task list end-to-end using strict Red-Green-Refactor TDD and9the Atomic Commit Protocol. Each task is implemented via a failing test (Red),10minimal passing code (Green), and a cleanup pass (Refactor) — then committed11atomically. Task status is updated in TODO.md after each commit. The loop12repeats automatically until every task is done.1314**Use this skill when you need to:**15- Read a TODO.md and implement every task in it16- Apply red-green-refactor TDD discipline to each task17- Burn down a task list with one atomic commit per completed task18- Update TODO.md status as tasks are completed19- Automatically progress through tasks until the list is done20- Decompose large tasks into INVEST-compliant units21- Maintain 95%+ test coverage with Farley-quality tests2223## Instructions241. Run `td usage` to load live task state and prior decomposition decisions.252. Read the handoff document `TODO-{td-id}.md` for the active Epic — once,26 as immutable context (intent, approach, constraints). Do not modify it.273. Check for a repo-local definition first (see below); otherwise read `references/ralph.md` for the full28 persona, TDD rules, Farley checklist, and execution flow.294. Decompose to INVEST tasks — each Independent, Negotiable, Valuable,30 Estimable, Small, Testable. Cut along business rule, error path, or data31 variation; sequence the foundational boundary first, then happy path, then32 error paths. Log the strategy chosen in the td handoff so the next session33 inherits the decomposition intent.345. Execute the TDD loop: derive tasks from acceptance criteria, create them35 in td, claim atomically with `td start`, commit per ACP, log decisions.366. At session end, run `td handoff` with `--decision` capturing the37 decomposition strategy used and `--uncertain` flagging any ADR assumption38 breaks for Lisa.3940## Core Loop4142```43For each task in TODO.md:44 1. Red — Write a failing test that describes the desired behaviour45 2. Green — Write minimal code to make the test pass46 3. Refactor — Clean up; tests stay green47 4. Verify — Run full test suite, apply Farley per-test checklist48 5. Commit — ACP atomic commit (Conventional Commits format)49 6. Update — Mark task complete in TODO.md50 7. Next — Move to the next task; repeat until TODO.md is burned down51```5253## Key Standards (read these)54- `references/ralph.md` — persona, TDD rules, Farley checklist55- **Task decomposition** — INVEST properties; cut by business rule, error path,56 or data variation; foundational boundary first. Record the strategy in each57 td handoff.58- **ACP — Atomic Commit Protocol**: one task = one atomic commit. Full spec:59 `skills/git-commit-formatter/references/acp-spec.md`, or use the60 `git-commit-formatter` skill.61- `skills/farley-tdd/docs/reference/farley-index.md` — per-test quality checklist6263## Repo-local definitions take precedence6465Before adopting the persona, check whether this repository defines its own66Ralph agent:6768```bash69{SKILLS_DIR}/_common/scripts/find-repo-agents.sh ralph70```7172Searches `.github/`, `.claude/`, `.gemini/` and `.agents/` for both `agents/*.md`73definitions and repo-local `skills/*/SKILL.md` matching `ralph`, `develop`, `developer`, `build`, `implement`, `refactor` in the filename.7475If any are found, read them and let their rules **override** the generic76persona on conflict — they encode how this codebase actually works. If none77are found, use `references/ralph.md` alone.7879## Triggers80- "ralph"81- "build agent"82- "TODO burndown"83- "burn down the TODO"84- "implement the TODO"85- "work through TODO.md"86- "execute the backlog"87- "implement each task"88- "work through the tasks"8990### Not this skill9192| If the user wants to… | Use |93| :-------------------- | :-- |94| Write one feature or fix test-first | `test-driven-development` |95| Audit an existing test suite | `farley-tdd` |96| Format a commit / understand ACP | `git-commit-formatter` |97| Run several agents across worktrees | `agent-mux` |9899## Execution100Run the Springfield Go agent for the current task:101```bash102just ralph103```104Alternatively, for a specific task:105```bash106just agent ralph "Your task description here"107```