Plain-English AI definitions for legal professionals. For what bars actually require, see the Legal AI Compliance Register.

Retrieval-augmented generation (RAG)

How models work Last reviewed 2026-06-11

Definition A technique that has an AI model answer using documents fetched from a trusted source at question time, instead of relying only on its training. It grounds responses in citable material and reduces—but does not eliminate—hallucination.

In more depth

A RAG system first searches a designated corpus—case law, firm documents, a contract repository—usually via embeddings in a vector database, then passes the best matches to the model along with the question. Because answers are tied to retrieved sources, they are easier to verify, which is why most legal research and document-question tools are built this way. Quality depends on the retrieval step: if the right passage is not found, the model may still guess, so verification duties remain.

Further reading: Wikipedia.

Related terms

About the editor: MHSB Solutions, Research desk. MHSB Solutions is not a law firm. This glossary is educational information, not legal advice.

Educational information, not legal advice. AI terminology and tools change quickly; definitions reflect usage as of the last-updated date. For what bar associations and courts actually require of lawyers using AI, see legalaicompliance.help and consult a licensed attorney in your jurisdiction.