03 / 10Foundation18 min lesson + 60 min lab

Turn Intent Into a Build Specification

Translate business judgment into a bounded task packet Claude Code can implement and verify without guessing at the important decisions.

By the end

A self-contained implementation brief with a user outcome, relevant evidence, constraints, non-goals, acceptance cases, and a proof-based finish line.

01

Bring domain knowledge, not technical performance

You do not need to disguise a business problem as an architectural solution. Your most valuable input is often knowing who performs the work, what arrives, which judgment matters, what can go wrong, and what makes the result useful. Claude can help locate technical seams; it cannot recover business meaning that was never stated.

Describe the workflow in the language of evidence and consequences. Instead of asking for an AI dashboard, explain that an operations manager receives incomplete requests in three channels, must compare them with a policy, and needs a reviewable recommendation before Friday. This gives the agent a problem to model rather than a fashionable interface to imitate.

02

Separate outcome from implementation

An outcome describes the observable change for a person. An implementation describes how the system might create it. Keep them separate so Claude can inspect existing patterns before introducing new components. If the repository already has authentication, storage, or form primitives, the safest solution may reuse them rather than follow your guessed stack.

Constraints and non-goals prevent useful exploration from becoming uncontrolled expansion. State what must remain compatible, which files or services are out of scope, whether new dependencies are allowed, and which actions require approval. Naming what the first version will not do is often more powerful than adding another feature requirement.

  • User: the person who experiences the result.
  • Trigger: the event or input that begins the workflow.
  • Outcome: what becomes observably different for that person.
  • Constraints: boundaries the solution must respect.
  • Non-goals: attractive work deliberately excluded from this change.
  • Proof: evidence that lets a skeptical reviewer decide whether the outcome exists.
03

Write the task packet

A useful task packet contains enough context to execute but not every fact in the organization. Point to the canonical files, current behavior, representative examples, and existing pattern the agent should follow. Include the exact error or screenshot when behavior is broken. Ask Claude to inspect referenced sources rather than repeating their entire contents in the prompt.

Acceptance criteria should be observable. `Make it robust` is not a test. `A signed-out user receives a 401, the session is not created, and the existing authentication tests remain green` gives Claude and the reviewer a shared finish line. Include normal, missing-data, permission, and failure cases proportional to the risk of the change.

04

Explore, plan, implement, verify

Anthropic's best-practices guidance recommends separating exploration and planning from implementation for work whose shape is uncertain. In plan mode, ask Claude to trace the current path, identify affected files, surface tradeoffs, and propose tests without editing. Review the model before paying the cost of code changes.

Then switch to implementation with the accepted plan and require the checks in the same request. Finish by reviewing the diff against the original task packet, not merely the plan Claude wrote for itself. A plan can be internally coherent and still drift from the user's outcome; the initial acceptance criteria remain the authority.

05

Use interviews and course correction

For a larger feature, ask Claude to interview you before writing the specification. Good questions expose states, edge cases, permissions, mobile behavior, failure recovery, and tradeoffs that a short idea omits. Ask it to avoid obvious questions and keep going until the hard decisions are explicit, then save the result as a file that a fresh implementation session can use.

During execution, interrupt early when the work moves outside the boundary. Correcting one mistaken assumption after the first file is cheaper than reviewing ten files built on it. If the same misunderstanding survives two corrections, start a clean session with a revised written brief instead of compounding a confused conversation.

Working reference

Commands and patterns

Begin an exploration-only session

claude --permission-mode plan "Trace the current workflow described in SPEC.md. Cite the owning files, identify unknowns, and propose a verification plan. Do not edit files."

Plan mode keeps investigation separate from implementation while the system model is still being corrected.

Ask Claude to build the specification

claude "Interview me about this feature until the user, states, edge cases, authority boundaries, non-goals, and proof are explicit. Then write the agreed specification to SPEC.md. Do not implement it."

A structured interview turns tacit domain judgment into an artifact that can survive a fresh session and human review.

Execute against the written contract

claude "Read SPEC.md and the project instructions. Restate the allowed scope and acceptance checks, implement only that scope, run the checks, and report the changed files plus evidence."

The written specification remains the reference while Claude discovers implementation details inside the repository.

When the happy path breaks

Failure modes

01

Symptom

The result is visually or technically impressive but solves the wrong workflow.

Likely cause

The prompt named a solution category instead of the user's trigger, decision, outcome, and proof.

Recovery

Return to the real work, write one observable user outcome, and make implementation choices subordinate to it.

02

Symptom

Claude introduces a new framework, service, or abstraction even though the repository already has a pattern.

Likely cause

The task over-specified the desired technology or failed to direct Claude to inspect nearby examples first.

Recovery

Require a pattern search and dependency justification during planning; prohibit new dependencies unless the accepted plan demonstrates a concrete need.

03

Symptom

One request changes dozens of files and cannot be reviewed confidently.

Likely cause

Several outcomes, cleanup ideas, and future features were bundled into a single task.

Recovery

Split the work into vertical slices, each with its own acceptance check, and complete one reviewable slice before starting the next.

04

Symptom

Claude says the task is complete, but no one can decide whether it works.

Likely cause

The brief described implementation activities but omitted observable acceptance criteria and required receipts.

Recovery

Add representative input/output examples and name the exact test, build, screenshot, or live observation required before completion.

Hands-on lab

Convert one frustrating workflow into an executable brief

Choose a repeated task from your own domain and create a specification a coding agent can implement without making consequential business decisions on your behalf.

  1. 01Describe one real instance of the work, including the trigger, people, inputs, decisions, exceptions, output, and current evidence.
  2. 02Write the user outcome without naming a model, framework, or interface.
  3. 03Ask Claude in plan mode to interview you about missing states, permissions, failure paths, and tradeoffs.
  4. 04Define the smallest complete vertical slice and at least three explicit non-goals.
  5. 05Write normal, missing-data, and consequential-edge acceptance examples.
  6. 06Name the files or systems Claude should inspect and the actions it may not take without approval.
  7. 07Have a fresh Claude Code session critique the brief for ambiguity without implementing it, then revise once.

Deliverable: A reviewed `SPEC.md` that another person can use to explain the problem, scope, constraints, acceptance examples, verification, and escalation boundary.

Reusable artifact

Agent-ready build specification

A reusable contract for a bounded implementation task, written in product language first and technical evidence second.

# Outcome
User: [one person or role]
Trigger: [what starts the work]
Observable result: [what becomes different]
Why it matters: [cost, risk, or opportunity]

# Current behavior and evidence
Current path: [what happens today]
Representative examples: [inputs, screenshots, errors, records]
Canonical sources to inspect: [paths, docs, APIs]

# Scope
Included: [smallest complete vertical slice]
Non-goals: [explicit exclusions]
Files or systems off limits: [boundaries]
Dependency policy: [reuse existing / approval required]

# Behavior
Normal case: [given / when / then]
Missing-data case: [given / when / then]
Permission or failure case: [given / when / then]

# Authority
Allowed without asking: [read, edit, test scope]
Must pause before: [external, irreversible, costly, sensitive actions]

# Verification
Commands: [targeted test, typecheck, lint, build]
Human observation: [UI, output, live behavior]
Required receipts: [diff, logs, screenshots, URLs, versions]

Before you move on

Receipt checklist

  • The specification states a user outcome without depending on a predetermined implementation.
  • Included scope and at least three non-goals are explicit.
  • Normal, missing-data, and failure or permission acceptance examples are testable.
  • Authority boundaries name the actions that require a pause or approval.
  • A fresh review identifies no consequential decision that Claude would still need to guess.

Primary sources

Continue with the source

Home
Book
Blog
Calugaru Labs
GitHub
LinkedIn
Email
Theme