In this section
01 / BUILD

Build Loop

Describe, implement, and accept a small, testable change.

  1. Purpose
  2. Small Spec
  3. Build
  4. Review
  5. Acceptance

Agent Instructions & Guardrails

AI agents need explicit project context and boundaries. A repository AGENTS.md collects lasting conventions, allowed actions and quality rules. The confirmed spec describes the specific change; the task selects the context it needs. Check that your AI tool actually uses the file.

  • Definition of Ready: Before B4, check context and instructions, resolve conflicts and update affected files where needed.
  • Definition of Done: Include any .md updates required by implementation and review them in B8.

The file supports the Build Loop. Requirements, priorities and approvals remain human decisions, even with neatly formatted guardrails. Open the AGENTS.md starter template

Prevent Feedback Debt: agree in the spec who will evaluate impact after release and when. Make it visible in practice →

Show all Build Loop steps B1–B10

The ten existing steps with responsibilities, AI support, evidence, and handoffs:

  1. B1Select a problem

    Work can come from the board, executive team, company strategy, higher-level initiatives, or the team itself. The Product Owner and team clarify the task and set priorities within their agreed mandate.

    For bug fixes, a reproduction, expected behavior, and test case are often enough for a work card.

    Before starting, they align with the accountable decision-makers on goals, fixed constraints, decision rights, and the investment boundary: human effort, AI costs, expected value, and review points.

    Scope can be negotiated within the explicitly approved space. Conflicts about goals or budget go to the appropriate decision-maker.

    Human responsibility
    PO + Delivery Team
    AI support
    Scout
    Evidence
    Bounded task with the next piece of evidence.
    Handoff
    Clarify first when uncertainty is high.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  2. B2Understand the need

    Collect real examples from users and Feature Partners. Try a small prototype if needed.

    Human responsibility
    PO + Feature Partner + Team
    AI support
    Scout
    Evidence
    Confirmed problem and concrete examples.
    Handoff
    Alongside V1: What improvement do we expect?
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  3. B3Agree on the spec

    Record behavior, examples, failure cases, and acceptance criteria. Include the measurement requirements from V2. For critical components, also agree on observability, useful alert triggers, and failure behavior; the optional Reliability & Observability section can help. Finish with a quick slice check: is the spec small enough for a bounded context and an independent review? If needed, split it into coherent, independently verifiable specs. The Product Owner and team confirm the split. Version the agreed source spec clearly so people and AI work from the same agreement. The Definition of Ready includes reviewing relevant project and context files, such as .md files, and updating them where needed. People and agents start with current, consistent context.

    Human responsibility
    PO + Feature Partner + Team
    AI support
    Scout
    Evidence
    A jointly confirmed spec with an ID, version, owner and a fixed reference to the valid version.
    Handoff
    Clarify critical unresolved rules before implementation. For contradictions or budget pressure, use the Spec Clinic: preserve the useful core, postpone convenience features, and update the spec and tests together.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  4. B4Plan implementation

    Review the repository, dependencies, and risks. Select suitable, versioned AI skills and assemble only the relevant context: the current spec, relevant files, examples, and errors. Give each split spec its own task and context while keeping shared interfaces and dependencies visible. Define small changes, test commands, budget, and agent boundaries. The Workmaster inspects relevant files, existing tests, and change history when needed. Before implementation, the team agrees in the existing “Test command or evidence” field: criteria ID, test command or steps, expected result, and evidence, such as a regression test, reproducible error, or browser check with screenshot.

    Human responsibility
    Delivery Team
    AI support
    Planner + Workmaster
    Evidence
    Reviewed plan and clear AI agent brief.
    Handoff
    Humans make new architecture decisions.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  5. B5Red · Write tests

    Turn confirmed criteria into test cases. The test should fail because the behavior is missing. For critical components, also test the agreed failure, fallback, and recovery behavior.

    Human responsibility
    Delivery Team
    AI support
    Reviewer
    Evidence
    A meaningful failing test.
    Handoff
    Return to B3 for a contradiction; fix infrastructure failures first.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  6. B6Green · Implement

    Build the smallest suitable implementation. Use specific test failures as feedback. Include the agreed logs, metrics, monitoring configuration, alerts, and failure behavior. The Workmaster runs the agreed self-check, corrects deviations within scope, and repeats the same check. Existing stop rules and budgets also apply to these corrections.

    Human responsibility
    Delivery Team
    AI support
    Workmaster
    Evidence
    Relevant tests pass.
    Handoff
    Do not weaken agreed criteria on your own. Under budget pressure, agree on scope shaping in the Spec Clinic. Stop at the attempt limit; do not silently extend the budget.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  7. B7Refactor · Simplify

    Improve structure and maintainability while preserving the agreed behavior. Run the tests again. Repeat the agreed self-check after refactoring too; correct deviations within the same task and its limits.

    Human responsibility
    Delivery Team
    AI support
    Workmaster
    Evidence
    Understandable code with tests still passing.
    Handoff
    Return to B6 for a regression, to B3 for a new requirement.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  8. B8Review independently

    Independently review a small, cohesive change with its spec reference, tests and evidence. Assess integration, security, architecture and, where operations are affected, observability, alert response and recovery according to risk. The Definition of Done includes updating documentation and context files affected by implementation and checking them during PR review. In the existing PR Evidence field, record each criteria ID, executed check, actual result, and evidence link where relevant. Checks that cannot run stay open. Independent review assesses criteria coverage; domain acceptance remains in B9.

    PR review & merge approval

    A pull request (PR) presents a proposed code change for review before it is integrated into the shared codebase (merged).

    A named human reviewer in the Delivery Team reviews the change according to its risk and decides on merge approval. Passing tests are important evidence, but do not replace technical judgement.

    Workflow, review scope & boundaries

    Small Specs need Small PRs too.

    Keep changes cohesive and easy to review. Rigid line limits do not achieve this; split large, mixed changes into meaningful pieces.

    1. Present a small change with a current spec reference, explicit boundaries and evidence.
    2. Automated checks and a separate agent review prepare the human review. Results and open findings remain visible on the PR.
    3. The named human reviewer in the Delivery Team assesses the change and remaining risks. They document merge approval for the reviewed version or request corrections.
    4. Resolve blocking findings and review again. Resubmit relevant changes made after approval; the earlier approval does not automatically cover them.

    What is reviewed?

    • Spec & scope: Does the change meet the spec and stay within the agreed scope?
    • Clarity & architecture: Are the change’s structure, maintainability and architecture sound?
    • Documentation & context: Definition of Done: have project and context files affected by implementation, e.g. README.md, architecture notes and AGENTS.md, been updated to match the reviewed version? If no update is needed, briefly explain why.
    • Security & data access: Are security, data access and permissions adequately protected?
    • Tests & failure cases: Are tests and checks meaningful, including relevant failure cases? Does the evidence cover each acceptance criterion? Checks that cannot run remain visible as open verification steps.
    • Interfaces & existing functionality: Have effects on interfaces and existing functionality been checked?
    • Operations & rollback: Where operations are affected: are monitoring, alerting, rollback and recovery defined and supported by evidence?

    Review depth follows risk: a text change needs less scrutiny than a change to permissions, payments or data migrations. Conditional items may be marked “not relevant” with a brief reason.

    Agents support. Humans approve.

    The agent review is a separate review task with access to the spec, changes and relevant evidence, in a separate AI context. The generating agent’s self-assessment is not sufficient. A separate agent does not guarantee correctness either. Agents provide findings and proposed corrections; humans decide on approval.

    The Workmaster coordinates the workflow and makes open reviews or missing evidence visible. This does not grant automatic approval authority. Merge approval in B8 and controlled release in B10 remain separate decisions.

    Three checks, three questions

    PR-Review · B8
    Is the technical change sound and ready for integration?
    Domain acceptance · B9
    Does the solution meet the agreed requirement?
    Value Loop
    Does the released solution achieve the expected impact?

    These checks complement one another. None replaces the others.

    Long-waiting or oversized PRs delay feedback and increase the risk of rework. Keep open reviews visible and address them promptly to limit feedback debt early. Make feedback debt visible →

    Human responsibility
    Named human reviewer in the Delivery Team
    AI support
    Reviewer with a separate review task in a separate AI context; Workmaster coordinates open reviews
    Evidence
    Documented technical merge approval for the reviewed version with evidence.
    Handoff
    Return blocking findings to B3, B5 or B6, resolve and recheck them. Relevant changes after approval require another review.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  9. B9Accept the business outcome

    Use the Acceptance Slot to test real scenarios with a prepared test version, data, and roles. The Feature Partner confirms the criteria or describes specific gaps. Handle new requests separately. For critical components, completion also requires evidence for the agreed observability and tested failure behavior, alongside the business functionality.

    Human responsibility
    Feature Partner; Product Owner clarifies changes
    AI support
    Reviewer prepares
    Evidence
    Confirmed criteria or a specific correction brief.
    Handoff
    Silence is not acceptance. Agree on a deputy and a response time.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗
  10. B10Release in a controlled way

    Activate the change and record the release and user group. Check operations and data collection. Verify the agreed monitoring signals, alerts, and recovery paths. Scale the depth and effort to the criticality.

    Human responsibility
    Team + named release owner
    AI support
    Workmaster within the permitted scope
    Evidence
    Stable activation and verified measurement data.
    Handoff
    Hand over to V3. In an incident, use the agreed rollback path.
    Open in the interactive explorer ↗ · View in the CART 1.0 example ↗