Building with AILesson 13 of 80

Module 2 · Prompting as engineering

One big prompt, or four small ones

In this lesson

  • 9 min read
  • 6 reading sections
  • Knowledge check
  • Lesson 3 of 10 in this chapter

This chapter’s goalTurn a prompt that works once into a versioned, cached, example-driven interface with a stated behaviour when the model does not know, and justify with cost and latency numbers whether a given task needs a longer prompt, a chain of smaller ones, a reasoning budget, or a fine-tune.

This chapter’s media

The film explains chapter ideas. The audiobook narrates the complete teaching text.

FormatEnglishहिंदी
Chapter filmNot availableNot available
Full audiobookNot availableNot available
Four small prompts, or one big oneSplit it whenThe steps deserve different modelsA step’s output can be checked in codeHalf of requests can skip a stepA step’s result is reused across questionsAn intermediate value must be loggedKeep it as one prompt whenStep two depends on nuance step one woulddiscardThe intermediate representation throwsinformation awayThe chain would run past three or four linksNobody on the team can hold the diagram intheir headSplitting is a debuggability decision before it is anything else. It is also a cost decision, becausea chain lets a cheap model do the cheap steps. Four steps at 95 per cent each is 81 per cent end toend, so a check between every link is what keeps the arithmetic survivable.
Splitting is a debuggability decision before it is anything else. It is also a cost decision, because a chain lets a cheap model do the cheap steps. Four steps at 95 per cent each is 81 per cent end to end, so a check between every link is what keeps the arithmetic survivable.

Figure

A little at a time

Explore an idea, try it, then check what stays.

Step 1 of 7Free · no account needed
Lesson steps

The mega-prompt and how it fails

A prompt that asks for six things at once (read this ticket, classify it, check it against policy, draft a reply, decide whether to escalate, and output JSON) fails in a characteristic way. It does not fail on all six. It degrades on two of them, usually the ones in the middle, and because the output still looks complete you do not notice for a month.

The mechanism is attention and instruction competition. Everything you asked for is competing for the same generation, and the parts that are hardest or least emphasised lose. You also cannot debug it: when the JSON has a wrong escalate flag, you have no way to know whether the classification was wrong, the policy lookup was wrong, or only the final decision was wrong.

Your place and first choices stay on this browser. Classroom credit is recorded separately.

Every lesson here is open. Your progress is recorded once you pass the Python, from Zero, for AI exam.

Stuck on something?Ask Sayali, your AI tutor

How to cite: Addaly (2026) ‘One big prompt, or four small ones’, in Building with AI. Edited by M. Mun. Addaly. Available at: https://addaly.com/learn/building-with-ai/decomposition-and-chaining (Accessed: 29 November 2026).