We use analytics to count visits and form use. It is on unless you reject it. We show no ads on this site.

Glossary

Spec-driven development

Published . Last updated . Published by Zapple.Tech, founded by the founders of CodeceptJS and Codeception, open-source testing frameworks.

Also called
specification-driven development, SDD
Published
Updated
Related service
AI QA adoption
Definition

Spec-driven development is a way of building software in which a written specification, not the code, is the main artifact. You write the spec first, then an AI coding tool generates a plan, code and tests from it. In our view the spec needs a reviewer, and the code needs tests that do not come from the same spec.

What is spec-driven development?

Spec-driven development (SDD) is a way of building software in which a written specification is the main artifact and the code follows from it. A Microsoft for Developers post describes it as a “spec-first approach”: teams define “guardrails, requirements, constraints, acceptance criteria, and edge cases up front, then use AI to generate code, tests, and supporting artifacts from that shared context”.

The decision this page helps with is where a spec fits in your process and who checks it. An arXiv paper from January 2026 separates three levels: spec-first, where the spec guides the first build and may then drift; spec-anchored, where it is kept alongside the code and tests enforce the alignment; and spec-as-source, where people edit only the spec. When a vendor says “spec-driven”, ask which level it means.

How is spec-driven development different from TDD, BDD and specification by example?

All four put something in writing before the code. They differ in what is written, by whom, and what checks the result. The table is our summary.

Approach Written first Who writes it What is generated What verifies the result
Test-driven development A failing unit test The developer Nothing; the developer writes the code The unit tests
Behavior-driven development Examples in plain language Business, developers and testers together Test automation linked to the examples The examples run as tests
Specification by example Concrete examples of behavior Business, developers and testers together Living documentation and acceptance tests The examples, run against the system
Spec-driven development A written spec: requirements, design, tasks A person, alone or with AI help A plan, code and tests, by an AI tool Depends on the team; see below

Cucumber’s BDD documentation says BDD produces “system documentation that is automatically checked against the system’s behaviour”. Gojko Adzic wrote up specification by example in his book of that name. Look at the last cell of the table. In the older approaches a check is built in. In spec-driven development it is a choice you make.

Spec-driven development compared with test-driven development, behavior-driven development and specification by example: what is written first, what is generated and what verifies the result; in the older approaches a check is built in, and in spec-driven development, where an AI tool generates a plan, code and tests from a written spec, it depends on the team

Is spec-driven development worth it for your team, and for which kind of work?

Our rule of thumb: the more people, the longer the life and the more AI involved, the more a spec pays back. The arXiv paper gives a similar test. It says SDD adds value when “using AI coding assistants”, for complex requirements and for systems with multiple maintainers. It also lists where it “may be overkill”: throwaway prototypes, solo short-lived projects, and exploratory coding, where early specifying can constrain learning.

The Microsoft post adds a limit from practice: “Not every change needs the full lifecycle”, so adoption should be right-sized. If you are choosing a first area, pick a feature with unclear requirements and several people touching it, not a prototype. A quality gate in your pipeline then decides whether the generated code ships. The AI QA adoption service is the matching one.

What goes into a spec for an AI coding agent?

Requirements, constraints, acceptance criteria and edge cases, as the Microsoft post lists them. Kiro’s documentation on specs shows one concrete layout: a requirements file with “user stories, acceptance criteria, or bug analysis”, a design file for architecture and sequence diagrams, and a tasks file with trackable tasks. GitHub’s Spec Kit runs a similar flow from a project constitution through specify, plan, tasks and implement.

Two of those inputs are ones a tester already writes. In our reading, good acceptance criteria are the part of the spec you can turn into checks, and a requirements traceability matrix shows which spec items have a test. In our view an unclear spec produces unclear code quickly. That is the same problem as with vibe coding, only better organized.

Who reviews the spec, and who tests that the code matches it?

Our view: two different people, and neither is the AI tool. Someone with product knowledge reviews the spec, because that is where intent is decided. Someone with test knowledge checks that each requirement can be verified, and writes or reviews tests that do not come from the generated code. Spec Kit’s own flow, which asks you to run the steps “one at a time, reviewing each result before continuing”, puts a person at each step.

Where services talk to each other, a contract test checks the implementation against an API spec, independently of the code. For AI-written code that reaches review, our AI code review checklist lists what to look at. Our guide to acceptance test-driven development shows how testers and business can agree on examples before any AI is involved.

What does spec-driven development not solve?

In our view a spec the AI follows exactly can still be the wrong spec. Tests generated from the same spec check the code against that spec, so an error in the spec passes every one of them. A tool does not remove ambiguity either. The Microsoft post says the quality of the outcome is closely tied to the quality of the spec. Independent tests and a person who challenges the spec remain your safeguards.

What does Zapple.Tech do about it?

If you are moving to spec-first work and want to know where your tests and release process stand, start with the evidence. Zapple.Tech starts with a one-week QA audit of one product area. It looks at its tests, pipeline and release process, and ends in a written report on what is at risk and what to fix first, plus a pilot plan you can run with Zapple.Tech or without it. Read more on the QA audit and assessment page.

Tell us about your product in the form below.

  • Acceptance criteria

    Acceptance criteria are the conditions that an implementation of a user story must meet to be accepted by stakeholders. The ISTQB syllabus says they may be viewed as the test conditions the tests should exercise. Written well, each one states an outcome a check can observe, and each one becomes at least one test.

  • Behavior-driven development

    Behavior-driven development (BDD) is a way of working in which developers, testers and business people agree how software should behave by writing concrete examples in plain language, usually as Given/When/Then scenarios, and then automate those examples as tests. The conversation comes first; Gherkin and Cucumber are its notation and tooling, not BDD itself.

  • Test-driven development

    Test-driven development (TDD) is a programming workflow in which a developer turns one planned scenario into a failing automated test, writes just enough code to make it pass, optionally refactors, and repeats until the test list is empty. The tests direct the design of the code, so TDD is a way of writing code, not a test phase run afterwards.

  • Contract testing

    Contract testing checks an integration point by testing each application in isolation against a shared contract that records the messages one side sends and the other expects. The caller is the consumer and the responder is the provider. It catches a breaking API change without deploying both services, but it does not prove the whole flow works.

  • Context engineering

    Context engineering is deciding what an AI model sees when it answers: instructions, message history, tools, retrieved documents and memory. LangChain's documentation defines it as providing the right information and tools in the right format so the model can finish a task. The context is an artefact you can test, review and version.

All terms in the glossary

Adopt AI

AI QA adoption

Help your QA team adopt AI in testing. Tool choice on your own code, a measured pilot, written working rules and training. One-week assessment first.

See the service

Questions about spec-driven development

What is spec-driven development?

Spec-driven development is a way of building software where a written specification is the main artifact and code is generated or checked against it. A Microsoft for Developers post describes teams defining requirements, constraints, acceptance criteria and edge cases up front, then using AI to generate code, tests and supporting artifacts from that shared context.

How is spec-driven development different from TDD and BDD?

TDD starts from a failing unit test and BDD starts from shared examples in plain language. Spec-driven development starts from a written spec that an AI tool turns into a plan and code. An arXiv paper notes that spec-first thinking is not new, and that TDD and BDD have advocated it for years.

What goes into a spec for an AI coding agent?

Requirements, constraints, acceptance criteria and edge cases. Kiro's documentation, for example, describes a spec as three files: requirements with user stories and acceptance criteria, a design document, and a task list.

Does spec-driven development replace testing?

No. A spec says what the software should do. Tests show whether it does. Our view is that tests written independently of the spec, and a person who challenges the spec itself, are still needed.

What tools support spec-driven development?

Vendors document spec workflows. GitHub publishes the open-source Spec Kit and Kiro documents its specs feature. Cucumber documents the older, example-based form. This answer lists documentation, not a ranking.

Request a QA audit quote

Tell us what you ship and what worries you.

What happens after you send this

  1. You send the form: your situation and what you need tested, then your name and work email.
  2. Within one business day, we reply with a suggested first step, its scope, timeline and a quote.
  • Fixed scope
  • You decide after each step
  • The tests live in your repository
  • An NDA signed before access

“They helped us to close the positions and consult our team how to proceed further. High-quality quick feedbacks with the deep checking of the required tasks, professional approach, great understanding of the company's technologies and product, detailed reports.”

Kristina Lavrentieva, Manager at keepgo.com, Israel
  • Rated 4.9 out of 5 on Clutch, from 7 client reviews
  • 42 completed test automation and infrastructure projects
  • Founded by the founders of CodeceptJS and Codeception, open-source testing frameworks

Request a QA audit quote

    What is closest to your situation?
    Optional. The product, the platforms, how often you release, what broke last.

    You decide after our reply whether to go ahead.

    Prefer to talk first? Book a call

    One-week QA audit · written report

    Request a QA audit quote