By Abhijith N M · Reviewed 24 October 2026 · Editorial standards
Decomposition is the highest-leverage skill in this course. A vague task produces a vague agent; a task broken into steps with explicit inputs, outputs and checks produces something you can actually test.
Start with: 'Research whether mid-market retailers are adopting AI chat support, and write a short brief.' Now break it into steps a new analyst could follow:
Clarify scope. Which region, which size of retailer, what counts as adoption?
Search for sources and record where each came from.
Read the promising ones and extract claims with their source.
Synthesise the claims into findings, flagging anything only one source supports.
Draft a 300-word brief with citations.
Check the draft against the sources: unsupported claim? missing citation?
Publish or send back to step 5.
Now mark each step with what it needs: a model, a tool, or plain code.
| Step | Needs | Why |
|---|---|---|
| Clarify scope | Model | Judgement about ambiguity |
| Search | Tool | Deterministic API call |
| Read and extract | Model + tool | Fetch, then interpret |
| Synthesise | Model | Judgement |
| Draft | Model | Language |
| Check | Model + code | Rules for citations, judgement for support |
| Publish | Code | A function call |
For every step, answer these before you build it. Steps you cannot answer are where your agent will misbehave.
A good step is small enough to test alone, large enough to be worth a model call, and has a check that does not depend on the step's own opinion. If step 4's only quality check is 'step 4 said it was fine', you have not decomposed anything.
Key takeaways
Decompose before prompting: steps with inputs, outputs and checks.
Mark each step as model, tool or code — that is your architecture.
Every step needs a failure behaviour, not just a success path.
Step count × loops = your cost and latency budget.
Written and edited by the nexGenCoders team. Spotted a mistake? Tell us and we will fix it.
Don't lose this lesson
Create a free account to save your progress, keep your streak, and work toward a shareable certificate.