Capstone: Ship a Feature End to End with an AI Agent
On this page
Learning Objective
Combine every practice in this course into one professional workflow: from a written spec through plan mode, test-first implementation, hooks and quality gates, independent review and a pull request that passes CI and human review, with a final checklist you can reuse on any team.
Concept Explanation
The capstone feature is realistic and slightly risky: add a customer-facing data export to a SaaS product's account settings. It touches personal data, needs authorization, involves background work for large accounts, and changes the UI, so it exercises security, testing, review and verification. The goal is not only to ship it, but to ship it in a way you would be comfortable defending to a security reviewer, a teammate who inherits the code and a customer whose data it handles.
Preparation happens before the first prompt. The repository has a concise AGENTS.md with commands, conventions, boundaries and the definition of done (Day 7). Shared settings deny reads of secrets and ask before pushes (Day 20). Hooks format edited files, protect applied migrations and keep the agent working until checks pass (Day 17). CI runs type checks, linting, tests with coverage, security scanning and architecture rules as required checks (Days 21, 24 and 25). A reviewer subagent and a review workflow exist (Days 18 and 27). This setup is the real multiplier: it makes every task safer, not only this one.
The work follows the flow from the course. Write the specification with EARS acceptance criteria, including the security requirements (Day 10). Start in plan mode: the agent explores, then proposes a plan with files, steps, tests and open questions, which you correct and approve (Day 9). Implement task by task with tests first, committing after each green step (Days 11 and 15). For the UI, the agent verifies the flow in a browser through the Playwright server (Day 19). Before opening the pull request, the reviewer subagent checks the branch with fresh context, and you read the diff yourself in the order from Day 14: summary and size, tests, core logic, edges. The pull request explains what changed, why, how it was verified and what to look at closely; CI and a human reviewer decide whether it merges.
Throughout, keep the human decisions human. You decide the scope, the data that may be exported, the authorization model, the trade-off between synchronous and background export, and whether the result is good enough. The agent explores, drafts, implements, tests and checks, at a speed no person can match. That division of labor is the core idea of agentic engineering, and the reason the last thirty days focused as much on specifying, verifying and protecting as on generating.
| Stage | Practice | Lesson |
|---|---|---|
| Prepare the repository | Instruction file, settings, hooks, gates, subagents | Days 7, 16 to 20, 24 |
| Specify | EARS requirements, security criteria, tasks | Days 8, 10 |
| Plan | Plan mode, explore, approve a specific plan | Day 9 |
| Implement | Tests first, small commits, checkpoints | Days 11, 15 |
| Verify | Local checks, browser verification, CI | Days 17, 19, 24 |
| Review | Reviewer subagent, human diff review, review bot | Days 14, 18, 27 |
| Ship and learn | PR with evidence, measure outcomes | Days 26, 28 |
Worked Example: The Session, Step by Step
These are the human inputs to a full session, with the agent's work summarized in comments. Each step maps to a lesson and leaves evidence a reviewer can check.
$ git switch -c feat/account-export
$ claude --permission-mode plan
> Read specs/account-export/requirements.md and AGENTS.md. Explore how account settings,
background jobs and file storage work today. Do not edit anything yet.
# agent reads the spec, settings page, job queue and storage helpers; reports findings
> Propose a plan as a checklist in specs/account-export/tasks.md: files, steps, tests per step,
and decisions you need from me. Cover every acceptance criterion.
# plan: serializer, endpoint with policy.can(), background job for > 10k rows, signed URL,
# UI button, e2e check. Question: include deleted projects? -> "No, active data only."
> Approved. Implement task 1 test-first: write the failing tests, show they fail,
then implement until green. Commit when done.
# hooks format files; Stop hook runs pnpm check; commit "export: serializer with field allowlist"
> Continue with tasks 2 to 4, one commit each, same discipline.
# endpoint, job and signed URL, each with tests; a PreToolUse hook blocks an edit to an
# applied migration, so the agent creates a new migration instead
> Task 5: add the Export button. Start pnpm dev and use the playwright server to request an
export as a normal user and as a user from another account. Include screenshots.
# browser check confirms the 403 for the other account and the email link flow
> Use the reviewer agent on this branch, then fix anything rated high or medium.
# reviewer flags request ids logged with email addresses; agent removes them; tests still pass
> Run the full checks, then open a draft PR: what changed, why, how it was verified,
screenshots, and what reviewers should look at closely (authorization and the job).
$ # CI runs required checks; review bot comments; a teammate reviews and approves; merge.The final pull request carries its own evidence: tests for every acceptance criterion, browser screenshots, a reviewer report and green required checks. The human time went into the spec, the plan correction about deleted projects, reading the diff and the final review, which is where judgment matters most.
Real-World Examples
- Anthropic's Claude Code best practices combine the elements of this capstone, specific instructions and CLAUDE.md files, explore-plan-code-commit, test-driven iteration, visual verification and multiple Claude instances reviewing each other's work, as the workflow that produces the most reliable results.
- The 2025 DORA report concluded that teams benefit most from AI when it sits inside a strong engineering system of version control, small batches, automated testing and fast feedback, the same system this capstone assembles around the agent.
Review Questions & Answers
Instruction files, permissions, hooks, quality gates and review agents apply to every task, not just this one, making every future agent session safer and more effective.
The scope, which data may be exported, the authorization model, design trade-offs such as background versus synchronous export, and the final judgment of whether the result is good enough to merge.
Tests covering each acceptance criterion, results of local and CI checks, browser verification screenshots for the UI, a review report, and an explanation of what changed, why and what reviewers should examine closely.
They formatted edited files automatically, kept the agent working until the checks passed, and blocked an edit to an already applied migration, steering the agent to create a new migration instead.