# Episode 8 · Hand it a reference book

Source: https://learn.agentware.studio/ai-gacha/en/ep/ep08
Other languages: [中文](https://learn.agentware.studio/ai-gacha/zh/ep/ep08.md) · [日本語](https://learn.agentware.studio/ai-gacha/ja/ep/ep08.md)

[Graduating from AI Gacha](https://learn.agentware.studio/ai-gacha/en/) · Season 1 · How it works

## What this episode covers

- Your company rules were never in the training data. Without them on the desk, the AI answers the way a typical company would, and sounds sure of it.
- Too much to fit on the desk? Cut it into small passages on a shelf, find the few that match the question, label each with its source, put them on the desk, then answer. That is RAG.
- When an answer is wrong, check which passages it found. Wrong passages: reword, or name the document and version. Right passages, wrong answer: have it paste the exact sentence.
- Add "Answer only from the material I gave you; if it is not there, say so." No RAG set up at work? Drop the document into the chat yourself.

## This episode's game: Search Cards

How it plays: Keyword guessing

Read Ben's question, write a search card (keywords or a sentence), and see which 3 passages the librarian brings back from the shelf. Get the right passage onto the desk within 3 cards.

## Glossary

- **Retrieval-augmented generation (RAG)** (检索增强（RAG） / 検索拡張生成（RAG）): Find the relevant passages first, put them on the desk, then have the model answer from them.

Video coming soon

- Previous episode: [Episode 7 · Let it draft first](https://learn.agentware.studio/ai-gacha/en/ep/ep07)
