To decompose a product idea into an AI system: break the goal into single-job stages, decide at each stage whether the model or your code does the work, define exactly what passes between stages, add validation where output feeds the next step, and close the loop so the system improves from its own results.
01 / Why start with decomposition, not the prompt
Because the prompt is the last decision, not the first. Start at the prompt and you build a demo that works on the one input you had in mind. Start with decomposition and you design a system that holds on the inputs you didn't.
Decomposition is the design work. Once the stages, roles, and handoffs are clear, the prompts almost write themselves, because each one now has a single, defined job. Skip it and every prompt tries to do everything, which is exactly why it does nothing reliably.
You don't write a better prompt. You give each prompt less to do.
02 / The five-step method
This is a sequence. Each step depends on the one before it, so run them in order. By the end you'll have a system on paper: stages, roles, handoffs, checks, and a return path, before you write a line of prompt.
01. Break the goal into stages
Write the end goal as a single sentence. Then list every distinct thing that has to happen to get there. Split each item until every stage has exactly one job. If a stage has two verbs, it's two stages.
Example. "Turn a product database into a shareable catalogue" splits into: read the data, structure each entry, generate the layout, render the output. Four stages, four jobs.
02. Decide model versus you
For each stage, decide who does it: the model or your code. The model handles judgment, language, and ambiguity. Code handles anything that must be exact, repeatable, or verifiable. When in doubt, give it to code, it's the part you can trust to behave the same way twice.
Example. Reading the data is code. Deciding how to describe a messy entry is the model. Rendering the final file is code. The model touches only the stage that needs judgment.
03. Define the handoff
For every boundary between two stages, write down exactly what crosses it and in what format. The output of one stage is the input contract of the next. This is the single most skipped step, and it's where systems quietly break.
Example. The model's stage outputs a fixed set of fields in a defined structure, never free text. The render stage knows precisely what to expect, so it never has to guess.
04. Add validation
Wherever a model stage feeds the next stage, add a check that the output matches the expected shape. Then decide what happens when it fails: retry, fall back to a default, or stop. A model stage with no check downstream is a silent failure waiting to ship.
Example. Before the render stage runs, verify every required field is present and correctly shaped. Missing field? Retry the model once, then fall back to a safe default rather than shipping a broken entry.
05. Close the loop
Add a return path that captures what the system produced and what happened next, then feeds that signal back to improve the earliest stage it can. Without it, the system runs once and never improves. With it, the system compounds.
Example. Capture which generated entries got edited by hand. Feed the edits back as examples into the model stage. Next run, fewer edits. The loop tightens itself.
03 / The mistakes that break decomposition
The method is simple. The ways it goes wrong are consistent. Watch for these four.
- Stages with two jobs. If you can't name one verb for a stage, it hasn't been split yet.
- Giving the model an exact task. Anything that must be right every time belongs to code, not judgment.
- Undefined handoffs. "The model outputs some text and the next part figures it out" is the failure, written down.
- No return path. A pipeline that never learns is a system frozen at its worst version.
A clean decomposition is boring on paper and unbreakable in production.
Read next
- The Scaffold Model. The theory this method comes from. Architect the system around the model, not the prompt.
- Prompts are not the system. The five components your decomposition produces, and the failure when each is missing.
Want the system decomposed for you?
Conversion landing pages and AI automations from €500. I map the stages, set the handoffs, and close the loop. Same outcome your agency promises, in days instead of quarters.
Drop me a line →