Building with AILesson 16 of 80

Module 2 · Prompting as engineering

Making the model quote before it answers

In this lesson

  • 9 min read
  • 6 reading sections
  • Knowledge check
  • Lesson 6 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

A little at a time

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

Step 1 of 7Free · no account needed
Lesson steps

Why an answer without a quote cannot be checked

Give a model ten passages and a question, and it will produce an answer that blends what it read with what it already knew from training. Both sources produce the same confident prose. Nothing in the output tells you which sentence came from where, and neither will the model if you ask it afterwards: it will generate a plausible attribution the same way it generated the answer.

The fix is structural rather than persuasive. Make quoting a required step that happens before the answer, and then verify the quote in code. That converts an unfalsifiable claim into a testable one.

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) ‘Making the model quote before it answers’, in Building with AI. Edited by M. Mun. Addaly. Available at: https://addaly.com/learn/building-with-ai/grounding-and-citations (Accessed: 29 November 2026).