Spec-Driven Development: Write Down What You Want Before AI Builds It

When Code Gets Cheap, the Spec Is the Scarce Asset

AI can now write software very fast. The hard part is telling it clearly what to build. McKinsey’s Rewired calls this spec-driven development. Here is what it means, in technical and plain language.

Ranjit Nethi

·

Spec-Driven Development: Write Down What You Want Before AI Builds It

The short version

  • AI coding tools write software fast, but they build what you ask for, not what you meant.
  • Spec-driven development means writing down what you want, with examples and tests, before the AI writes any code.
  • The business owner should approve that one-page document. It is a business document, not a technical one.

The problem

You have probably seen this demo. An engineer types two sentences into a coding agent, and ten minutes later a working quoting screen appears. The room is impressed. Three weeks later the same team is stuck in review, because nobody can say whether four thousand lines of generated code do what the business wanted. Nobody wrote down what the business wanted.

The agent did its job. The request was the weak part.

A coding agent is an AI tool that writes software from a written request. It is like a very fast builder. If you give a builder a vague sketch, you get a house, but it may not be the house you wanted.

What McKinsey’s Rewired says

McKinsey published the second edition of Rewired in April 2026, revised for a world of generative and agentic AI. The material on software development is the one I would hand to every business leader who funds a technology team.

It describes four levels of AI support for developers. Level 1 is no AI. Level 2 speeds up individual tasks, such as suggesting the next lines of code, and the book says most companies are here. Level 3 automates whole steps: a first version of the code, the tests and the documentation from a plain-language description. Level 4 is a small team directing coordinated agents that deliver an application end to end. Level 4 is where the book’s figure of 20 times leverage sits, and the authors call it largely experimental.

The more useful part is the division of labor. People state intent and boundaries, write specifications, break the work into pieces an agent can finish, set the guardrails and review the result. Agents write, test, scan and document. The authors compare the human role to an editor-in-chief.

Most companies use AI today to help a developer type faster. The next steps let AI do whole pieces of the work, while people decide what to build and check the result.

Then comes the instruction that prompted this post. Among the skills teams need, the book lists this one: “Master spec-driven development and context engineering.” It is also the practical meaning of the eleventh theme in the book’s manifesto, that agentic engineering becomes the next capability to master.

Spec-driven development in plain language

Spec-driven development means you write what the software must do, and how you will know it does it, before an agent writes any code. The specification is the source of truth for the person and for the agent.

The common tools follow the same sequence. A specification says what and why. A plan says how, within your architecture. A task list cuts the plan into pieces small enough to verify. The agent builds each piece. Tests that come from the specification decide whether the piece is done.

Write the brief, agree the plan, cut it into small jobs, let the AI do each job, and check each one against the brief.

The spec-driven loop: intent, spec, plan, tasks, build, verify
The spec-driven loop: intent, spec, plan, tasks, build, verify

Two kinds of written context sit underneath. One is the specification for a single change. The other is standing context that applies to every change: architecture, coding standards, the domain vocabulary, and the things an agent must never do. GitHub’s Spec Kit calls this a constitution. Amazon’s Kiro calls it steering. Giving the agent the right background this way is called context engineering.

There are two documents. One is the brief for this job. The other is the house rules that apply to every job.

Birgitta Böckeler of Thoughtworks gave the field its most useful vocabulary in October 2025. She separates three levels of commitment.

LevelWhat it meansWhere it fits
Spec-firstWrite the spec, build from it, then let it goMost feature work
Spec-anchoredKeep the spec alive beside the code, with tests that catch driftSystems that carry money, customers or compliance
Spec-as-sourcePeople edit only the spec; code is always regeneratedNarrow cases with trusted generators; early for business software

What the evidence shows

The evidence for the problem is strong. DORA’s 2025 research, drawn from nearly 5,000 technology professionals, found that AI adoption now raises delivery throughput and still raises delivery instability. Its summary is that AI amplifies whatever an organization already is. Teams ship more, and more of it breaks.

AI makes good teams faster and makes messy teams messier.

The evidence for the payoff of doing this well comes from the book itself. McKinsey studied nearly 300 public companies. The top fifth report gains of 16 to 30 percent in productivity, time to market and customer experience, and 31 to 45 percent in software quality. About 80 percent of those leaders tie AI goals to how product managers and developers are evaluated.

The evidence for spec-driven development as a specific method is thinner, and I would rather say so. Thoughtworks has placed both the technique and Spec Kit in “Assess” on its Technology Radar, which means worth exploring and not yet a default. Its teams report long generated specifications that are tedious to review, and instruction files that grow until the agent starts ignoring them. Böckeler found the tools turning a small bug fix into several user stories. A January 2026 technical report by Deepak Babu Piskala calls the research on outcomes nascent. Its headline case, a 75 percent cut in cycle time, is self-reported by the team involved.

So the honest position is this. Unclear requests cause more damage when AI builds fast, and that part is measured. A written spec is the cheapest known way to make a request clear. Which tool or template you use to write one is still an open question.

My view

I agree with the book’s main point. When writing code is no longer the slow part, knowing clearly what you want becomes the slow part. Four things I would add.

The spec is a business document. Rewired argues throughout that business leaders must own the domains being transformed. Spec-driven development is where that ownership becomes visible or doesn’t. If the product owner cannot state the outcome, the non-goals and the acceptance criteria on one page, the engineering team will invent them, and so will the agent. I would have the business owner in the chair sign the spec, the same way finance signs a benefit.

Twenty times is a ceiling. Plan with the floor. The 20 times figure belongs to an experimental level and to new applications. The measured gains for the best companies are 16 to 30 percent. Budget with those numbers. A plan built on the ceiling will meet the same fate as a business case built on gross hours saved.

Checking becomes the bottleneck. If agents produce ten times the code, people must judge ten times the output. Review capacity and test design become the scarce skills. A spec with acceptance tests is what makes that review affordable, because the reviewer checks the software against a written goal and does not have to guess the goal from the code.

An acceptance test is a check that a machine can run, such as “given this order, the price must be this.” If the checks pass, the reviewer has far less to read. This is the same discipline I argued for in Prompts Are Code: nothing ships without a run against the tests.

Use only as much process as you need. Piskala’s rule is the right one. In commercial systems I would anchor the spec for anything that touches price, a quote, an order or a customer record, because a small error there costs real money. I would write a spec first and then let it go for internal tools. I would skip the process for a prototype that will be thrown away.

One caution the book does not give. Passing tests prove that the code matches the spec. They say nothing about whether the spec was right. That judgment stays with the business owner, which is one more reason the document has to be short enough to read.

A one-page spec that works

Length is the common failure. A twelve-page generated specification moves the review burden from code to prose and removes nothing. A spec that can be reviewed in one sitting holds seven things.

  1. Outcome and owner. The decision or task that changes, and the named person who owns it.
  2. Scope and non-goals. What is in, and three things that are deliberately out.
  3. Behavior as examples. Five to ten cases in the form “given this, when that, then this”, including the awkward ones.
  4. Constraints. Systems it may touch, data it may read, permissions it runs under, and standards it must follow.
  5. Acceptance tests. The examples above, written so a machine can run them.
  6. Measure and baseline. The number that should move, and where it stands today. This is the link back to the Value Chain of Custody: a spec with no measure builds a system with no ledger line.
  7. Open questions. What is still unknown, so the agent asks and does not guess.

The standing context is a separate, shorter file. Keep it to architecture boundaries, versions, naming, the domain glossary and the hard prohibitions. Move anything long into reference documents the agent loads only when needed.

What changes in your organization

Rewired organizes a transformation around six capabilities. Spec-driven development touches each one, which is why a tools team cannot adopt it alone.

CapabilityWhat changes
RoadmapSmall tools that never cleared the funding bar become affordable. The backlog needs re-ranking
TalentProduct owners need to write precisely. Senior engineers spend more time reviewing and designing tests
Operating modelPods get smaller. Spec review becomes the gate that matters, ahead of code review
TechnologyTest harnesses, pipelines and agent context become platform products with owners
DataThe domain glossary and business rules have to exist in writing before an agent can respect them
AdoptionAcceptance criteria written with the people who will use the system raise the odds they do

What to do this week

Pick one feature already in your backlog, small enough to finish in a week. Sit the product owner and one senior engineer down for an hour and write the one-page spec together. Run it through whichever coding agent your team already uses. Then count three things: how many review rounds it took, how many defects reached test, and how long the owner needed to say “yes, that is what I meant.” Do the next feature the old way and compare.

One feature will not prove anything. It will show you whether your organization can still write down what it wants, which is the skill that will matter most in the next few years.

What has your team found: does a written spec shorten the review, or does it only move the argument earlier? I would like to hear the numbers.

The terms, in plain language

TermWhat it means
Coding agentAn AI tool that writes and tests software from a written request
Spec (specification)A short document that says what to build and how to check it
Acceptance testA check a machine can run to confirm the software does what the spec says
Standing contextThe house rules the AI reads on every job: architecture, standards, vocabulary
Context engineeringGiving the AI the right background so it does not have to guess
Agentic engineeringDesigning and running systems where AI agents do the work under human oversight

Sources

About the author

Ranjit Nethi leads AI and data for commercial operations at a global industrial manufacturer. He writes about the operating model that turns AI pilots into results finance will sign. Kellogg Executive MBA; MS in Computer Science. This site is his own perspective and view, with no affiliation with any organization.