What is retrieval-augmented generation (RAG)?
Published . Updated .
Retrieval-augmented generation (RAG): A method where a language model first retrieves relevant documents, from a search engine or a database, and then writes its answer using them.
The term comes from a 2020 paper by Patrick Lewis and colleagues, which paired a model's built-in knowledge with a searchable index of documents. AI search in ChatGPT, Claude and Grok works the same way, with the live web as the store.
The retrieval step is where fan-out queries are sent and pages are fetched. Fetched vs cited sources covers what happens to those pages next.
Read next
- What is grounding in AI?
- What is an embedding?
- Fetched vs cited sources: why AI answers leave out pages they read
Sources
See the fan-out for your own prompts
Only Fan Out is a free Chrome side panel that lists the queries, fetched pages and cited pages behind each ChatGPT, Claude or Grok answer. Nothing leaves your browser.
Add to Chrome, it's free