Back to Glossary

Retrieval-Augmented Generation (RAG)

Synonyms: retrieval-augmented generation, grounded generation, retrieval-augmented LLM, knowledge-grounded AI, document-grounded generation

Do not index

Definition

Retrieval-Augmented Generation (RAG) is an AI architecture that fetches relevant documents from a knowledge base and hands them to a language model before it answers. Rather than relying only on what the model memorized in training, it grounds each response in real, current sources.

Use cases

Skip grounding and your AI confidently makes things up, which kills trust the moment a user catches it. The cost is hallucinated answers, stale info, and no way for users to verify.
  • The support bot that invents policies. A chatbot answers refund questions from training data and gets your actual policy wrong. RAG pulls the real help article so the answer matches your docs, with a link to prove it.
  • The "as of when?" problem. A user asks about something that changed last week, and a plain LLM answers from a year-old cutoff. RAG retrieves the latest doc, so the answer reflects today.

How it's used in practice

  • Design the citation UI: show which sources the answer came from, linked and clickable, so users verify instead of trusting blindly.
  • Design the empty-retrieval state: when nothing relevant is found, say "I couldn't find that in our docs" rather than letting the model guess.
  • Budget for the extra latency: retrieval adds a step before generation, so build loading or streaming states that cover the wait.
  • Surface freshness: answers are only as good as what's indexed, so show "last updated" on sources and flag stale ones.
🪄
Pro-tip: RAG lowers hallucination but never fully removes it. The model can misread a retrieved passage, or the retriever can pull the wrong doc, and the bad answer still sounds confident.
Design for the mismatch: link the actual source passage so a user can catch when the answer drifts from it, instead of just asserting it's grounded.
 

Challenges & limitations

  • Garbage in, garbage out. RAG only retrieves what you indexed. Outdated, contradictory, or badly chunked docs mean the AI grounds its answer in bad material.
  • Retrieval can miss. If vector search pulls the wrong passages or none, the model falls back to guessing, and that failure is invisible to the user.
  • It adds cost and complexity. You're now running an embedding model, a vector database, and a retrieval step, plus keeping the index fresh. That's infrastructure, not a prompt tweak.

Free resources

 
 
notion image

Share this post

Get free UX resources

Get portfolio templates, list of job boards, UX step-by-step guides, and more.

Download for FREE
 
 
 

The best email 📮 for growing 🌱 designers

 
Honest notes about the work behind the work. Read in 2 minutes, weekly. Free forever.
 
 
     
    notion image
     
    Join 13,045 designers and get tactics, hacks, and tips.