Specification-driven development

Why clearer specifications matter when AI writes code

A useful specification makes the intended behaviour, boundaries and evidence clear before implementation begins.

Start with the behaviour, not the implementation

A request such as “build a membership service” describes an ambition, but leaves most of the system undecided. Who can join? When does membership become active? What happens when payment fails? An implementation can appear convincing while quietly choosing answers that the people using it never agreed.

A specification makes those decisions visible. It gives everyone a shared reference for what should happen, what must not happen and how to judge whether the result is acceptable.

Turn a broad request into observable rules

Consider the instruction “members can pause their subscription”. A more useful definition answers several separate questions:

  • Who is permitted to request a pause?
  • Does it begin immediately or at the next renewal?
  • What access remains during the pause?
  • What happens to a payment already in progress?
  • How and when does membership resume?

The goal is not to write the longest possible document. It is to resolve the uncertainty that would otherwise turn into an accidental product decision.

Connect decisions to evidence

Example

Given an active member whose next renewal is on 1 October, when an authorised pause request is accepted on 20 September, access remains active until the renewal boundary and no new renewal charge is initiated for the paused period.

This example still needs decisions about time zones, payments already in progress and resuming access. Its value is that those missing questions are easier to identify and discuss.

Link each important rule to an observable outcome. A reviewer should be able to explain what evidence would demonstrate success, and which failure paths still need attention.

Use AI to explore, then review the choices

AI can help propose questions, compare alternatives and explore scenarios. Those suggestions are inputs to a decision, rather than evidence that the decision is correct. Review assumptions with the people who understand the service, its constraints and its users.

When requirements change, update the connected rules and acceptance criteria. Otherwise a clear specification can become an outdated description of a system that no longer exists.

Try this on your next feature

  1. Write the intended user outcome in one sentence.
  2. List the actors and the permissions each needs.
  3. Describe the main journey and at least two failure paths.
  4. Mark every unresolved assumption.
  5. Define the evidence needed before accepting the work.

If two readers still expect different behaviour, use that disagreement to find the next decision to resolve.

Practise the decisions behind the idea.

Work through interactive scenarios that connect requirements, decisions and evidence.

Explore career tracks

Find a useful next step.

Take the free skills check for an initial view of your strengths and development areas. Normally 10-15 minutes. No account or AI connection required.