Retrieval-augmented generation — RAG, in the inevitable acronym — is the technique doing the real work in legal AI. It is also routinely misdescribed by vendors as “our AI understands your documents.” Here is what actually happens, in four steps a lawyer can audit.
The four steps
- Index: the matter's documents are parsed into passages and a searchable representation, stored beside the matter. In local mode this index lives on your disk and nowhere else.
- Retrieve: when you ask a question, the system finds the passages most relevant to it. This is search — sophisticated, embedding-based search — not understanding.
- Ground: the found passages are placed in front of the model, and the model is instructed to answer using them. The model never answers from its general training about “contracts in general” when it has your clause in front of it.
- Cite: the answer is linked back to the passages that produced it — page, line, clause. If no passage supports a claim, the honest system reports not found.
Why this shape suits law
Because it matches the profession's own epistemology. A legal answer is supposed to trace to authority; RAG's citation step is that discipline, enforced by software. It also matches confidentiality: retrieval can run entirely on-device, so the reading layer of the technique never requires transmission. The model itself runs locally too, in our local mode — which is why the boundary test exists.
The failure mode that matters
RAG fails by retrieval miss: the right passage exists but is not found, and the system must then say so rather than improvise around the gap. This is the failure we handle explicitly — an answer without a resolvable span is not asserted as fact — and it is the question to put to any vendor: “what does your product do when retrieval comes back empty?” If the answer is anything other than “it says not found,” the demo you were shown was running on luck.
Retrieval is search, not understanding. Grounding is discipline, not magic. The citation is the product.