Interactive widget · free · embeddable
RAG: watch a frozen model answer from documents it never read
Four private documents, one frozen model. Tap the snippet you think answers the question, then watch the pipeline find it by similarity and paste it into the context.
When and where is the team offsite?
What you will do
- 1A frozen model and four private docs it never trained on. Tap the snippet that answers the question.
- 2See how the system finds it: the question and every snippet become vectors, and a dot product scores each one.
- 3Watch one annotated run: question in, retrieved snippet pasted into the context window, grounded answer out.
What it shows
A support bot cannot answer questions about your product, and all the answers live in your help-center articles. The instinct is to retrain the model on them. This widget shows the cheaper move. The model's weights never change. Retrieval finds the right snippet by similarity and pastes it into the context window, so the same frozen model reads the answer instead of guessing it.
You spot the winning snippet first, by meaning rather than keywords; the right passage never contains the word you searched for. Then the stage shows how the system does the same thing: meaning lives as direction in a coordinate space, so the dot product that compares two embeddings can score every snippet against your question. The highest score wins and gets pasted in.
The final beat runs the whole pipeline once, annotated, so you can see where the retrieved text enters and why the answer comes out grounded. Swap in a plausible but outdated snippet and the answer comes out confidently wrong. Retrieval quality decides answer quality.
Why it matters
This is the concrete difference between RAG and fine-tuning. RAG changes what the model reads at answer time; fine-tuning changes the weights. Add a new document tonight and RAG answers from it tomorrow, with a citation, and forgets it the moment you delete it. Fine-tuning is for teaching a style or a format, not for storing facts that change. Modern assistants often search agentically, writing several queries and reading results in a loop, but the principle on the stage is the same: find the right text and put it in the window.
Key takeaway
RAG is the similarity trick plus paste into context. No retraining, and the model reads the answer instead of guessing it.
Honest note: This is a toy: whole documents and a single winner. Real systems split documents into chunks, retrieve the top few instead of one, and often rerank them before the model sees anything.
This widget is one stage of a full lesson, with the story around it.
Free, no code, no signup.
Embed this widget
Paste this into any HTML page, course platform, wiki or slide tool that accepts an iframe. It runs with no account, sets no cookies of its own, and links back here.
Attribution is built in. If you write about it, a link to this page is all we ask.
Common questions
- When should I fine-tune instead of using RAG?
- When the problem is behavior, not knowledge: a tone, a format, a narrow skill the model gets wrong even with the right facts in front of it. For facts that change, private documents and anything that needs a citation, retrieval wins because you can update it without a training run.
- Why does RAG sometimes give a confidently wrong answer?
- Because the model faithfully reads whatever wins retrieval. If an outdated or off-topic snippet scores highest, the model grounds its answer in that. Chunking, reranking and evals on retrieval quality exist to catch exactly this failure.
- Can I embed this RAG demo in my documentation or course?
- Yes. Use the iframe snippet on this page. It works anywhere an iframe is allowed, needs no account, and links back to the full lesson and the RAG versus fine-tuning explainer.
Related explainers
One idea at a time, in your inbox
New lessons and explainers, written the way these pages are. Now and then, not daily, and never a sales sequence.
We email you a confirmation link first. Unsubscribe in one click, any time. Privacy.
Part of See How AI Works, a free interactive course, where you learn how modern AI works by operating it, not watching videos.