Agentic Pattern Libraryby Vikas Goyal
← All patterns
75

Requirement Interrogator

Also known as: requirement gap finder, question-first planning, spec interrogation

An agent reads a requirement and lists the missing scenarios and decisions to take to the business before coding.

TrackAI-native software delivery FamilyPlan & Design Maturity Emerging ChangesDecisionContext
01

Problem

Coding agents build exactly what they are told, so gaps in a requirement turn into confident, wrong code. In many teams the slowest step isn’t building at all: it is waiting weeks for the business to settle details nobody asked about until development was underway. The questions surface late, one at a time, and each one costs another round of rework.

  • Business stakeholders are busy and answer in batches.
  • Engineers can’t spot every gap in someone else’s domain.
  • Too many questions get ignored.
  • Some decisions can only be made once people see working software.
02

Solution

Before planning starts, give an agent the requirement, the relevant context (existing system, data and its meaning, past decisions) and a checklist of what a buildable requirement must settle: user roles, edge cases, error paths, data rules, permissions and non-functional needs. The agent returns a short, ranked list of open questions. Each states why it matters, what the team will assume if nobody answers, and whether it blocks the work. The team removes what it can answer itself and sends the rest to the business as one batch. Answers go into the spec, and the unanswered questions with their stated assumptions become the default, so work can start without waiting.

03

Diagram

Requirementshort or partial Contextsystem · data · decisions Interrogator agentchecks for gaps Ranked questionswhy it mattersdefault if unanswered Team filtersanswers what it can Businessrest in one batch Specanswers + defaultsready to build

Questions arrive in one ranked batch before coding, each with a default the team will use if nobody answers.

04

When to use

Use it when

  • Requirements arrive as short descriptions or partial documents
  • Business decisions are a known source of delay or rework
  • Agents build most of the code, so gaps turn into code quickly
  • Domain rules are complex (finance, legal, compliance)

Avoid it when

  • Small, well-understood changes
  • Exploratory work where a prototype will answer the questions faster
  • When nobody on the business side will answer; fix ownership first
05

Trade-offs

Latency Minutes of agent time, then one round with the business
Cost One agent run per requirement
Complexity A checklist and a question format
Reliability Gaps found before code, not after

Gains

  • Gaps surface in one batch, early, instead of one by one during build
  • Stated defaults let work start without waiting
  • Business stakeholders get specific questions, not vague requests

Costs

  • Business people may tire of question lists
  • Agent questions can miss domain subtleties
  • Answers still depend on someone deciding
06

Worked example

Scenario
The Linkwatch team gets a one-line request: "Let partners upload their own link lists."
  1. AgentReads the request, the upload code and the data model, then returns 9 questions. Three are blocking: maximum file size, what happens to duplicate links, and whether partners can see each other’s lists.
  2. TeamAnswers 4 questions itself from existing behaviour, and sends the other 5 to the product owner in one message, each with a proposed default.
  3. BusinessReplies within a day, confirms 3 defaults and changes 2: duplicates are merged, not rejected, and the limit is 50,000 rows.
  4. BuildThe answers go into the spec. The agent builds against it, and the partner demo shows no surprises.
  5. ResultThe team’s previous upload feature had needed 4 rounds of business questions during build; this one needed one round before it.
07

Failure modes

FailureSymptomMitigation
Question floodBusiness ignores long lists of questionsRank questions, cap the list, and give a default for each
Questions the team could answerStakeholders asked things the code already settlesGive the agent the existing system context; team filters first
Answers not recordedThe same questions come up again laterWrite answers into the spec or a decision record
Waiting for every answerWork stalls on non-blocking questionsStart with the stated defaults; only blocking questions wait