Retrieval-augmented generation

Retrieval-augmented generation (RAG)

AI

A technique where an AI looks up relevant documents or records first, then writes its answer from what it found. Often shortened to RAG.

What is Retrieval-augmented generation?

RAG has two steps. Retrieval searches a knowledge source, such as help articles, policies, product data or past conversations, for the passages most relevant to the question. Search can use keywords, meaning-based (vector) search or both. Generation gives those passages to the language model, which writes an answer based on them. Why it helps: the model does not need to have memorized your business. Updating an article updates future answers, and answers can point back to their sources. Quality depends on the content, so out-of-date or conflicting articles lead to poor answers.

Example

For example, a customer asks "Do you ship to Canada?" The system retrieves the shipping policy section on international orders and the model replies using that text, including the delivery times it lists.

Why Retrieval-augmented generation Matters

RAG keeps AI answers tied to your own, current information instead of the model's general guesses.

Explore More Terms

Browse our complete glossary of e-commerce and subscription terms.

Space, at your fingertips

What would you do with 22% more revenue?