A model's weights are a frozen, lossy snapshot of the internet. RAG fixes that by retrieving relevant text at query time and putting it in the prompt, so answers are grounded, current, citable, and permission-aware.
The minimal pipeline: 1. Ingest — load documents, clean them, split into chunks. 2. Embed — turn each chunk into a vector. 3. Index — store vectors plus metadata in a vector store. 4. Retrieve — embed the question, fetch the nearest chunks (often plus keyword hits). 5. Generate — answer using only those chunks, with citations.
text question ──embed──▶ vector search ──▶ top-k chunks ──▶ prompt(+cite) ──▶ answer
RAG beats fine-tuning for facts because you can update, delete, and access-control a document instantly — you cannot un-train a weight update the same way.
Gotcha: RAG does not stop hallucination by itself. You must instruct the model to answer *only* from the context and to say when the answer is not present.