What is Retrieval-Augmented Generation (RAG) in AI?

Retrieval-Augmented Generation (RAG) is like having a super-smart friend who can look up answers before telling you what they think.

Imagine you're playing a game of 20 Questions. Your friend knows a lot, but sometimes they get confused. That's when they pull out a big book, full of facts and clues, to help them figure it out. They read through the book, find the best clue that fits the question, and then use that clue to answer you.

In RAG, the "super-smart friend" is the AI. The "big book" is a database with lots of information. When the AI gets a question, it first "looks up" in the database, this part is called retrieval. Then, using what it found, it creates a well-thought-out answer, this part is called generation.

So RAG combines two powers:

  • Retrieval: Finding useful information from a big collection.
  • Generation: Creating an answer that makes sense, using the info it found.

It’s like having a robot who can read books and then explain things in their own words, just like your friend did in the game!

Take the quiz →

Examples

  1. A child looks up a fact in a book before answering a question.
  2. A student uses notes to help explain a math problem.
  3. A teacher checks a textbook for information during a lesson.

Ask a question

See also

Discussion

Recent activity