Skip to content
Glossary · AI agents

Retrieval-augmented generation (RAG)

Retrieval-augmented generation (RAG) is a method where an AI looks up relevant passages in a knowledge base before answering, so answers come from your material. It lets an AI agent answer questions about one specific business without retraining the AI model.

How does retrieval-augmented generation work?

Retrieval-augmented generation works in two steps. First, the question is used to search the knowledge base for the passages most likely to hold the answer. Then those passages are given to the AI model alongside the question, and the model writes its reply from them. If nothing relevant turns up, a well-built agent says so instead of guessing.

The search usually runs over an index of your documents, split into small chunks and organised by meaning rather than exact keywords. That index can be self-hosted in a vector database or handled by a managed retrieval service.

Why does RAG matter for a small business?

RAG matters for a small business because it keeps an AI agent grounded in your own policies, prices and procedures rather than general internet knowledge. It also makes updates simple: change the source document and the agent's answers change with it, with no retraining. The trade-off is that the source has to be accurate.

What does RAG look like in practice?

Our chat agent for a Spanish study-abroad agency uses managed retrieval with Gemini File Search. The knowledge base document sits in Gemini's file storage and the agent queries it at runtime, so there's no vector database or chunking pipeline to host. Updating the knowledge base means replacing one file, which is why that file has to be right first.

Want answers that come from your own material?

Free · 30 min · No commitment

Thirty minutes on how your business runs today. You leave with a straight read on where AI pays off, and where it doesn't.