Haseeb Sultan ← Back to writing

Spec-Driven Development

A visual guide · 2 pages

Give the agent a clear path

  1. 01IdeaName the need
  2. 02SpecificationDefine the behavior
  3. 03BuildImplement the plan
  4. 04VerifyCheck the result

02 From a prompt to a specification

Make the request testable.

A vague prompt leaves important choices unstated. A small specification describes observable behavior so the agent and the reviewer know what “done” means.

Example: a personal task list

The prompt

“Build me a task list.”

What can I do with a task? Should it still be there after a refresh?

A small specification

  • Add a task with a non-empty title.
  • Mark it complete or delete it.
  • Keep tasks in this browser after a refresh.
  • Leave accounts and sharing out of scope.

One acceptance check: add “Read chapter one,” refresh the page, and confirm the task is still there. A specification guides the work; testing checks whether it was followed.

Haseeb SultanPage 2 of 2 · End of this preview