Free courses in AI, Data Science & Machine Learning Written lessons · Quizzes · Final exams
Future Data Academy
Log inGet started ↗
← Retrieval-Augmented Generation (RAG)
FREE LESSON PREVIEW

Retrieval and generation are separate

RAG retrieves relevant material and supplies it as context to a generator. A basic flow is question, search, selected passages and answer with references. Search may use keywords, embeddings or both.

This can bring specialised information into an answer without retraining on every document, but does not guarantee correctness. Retrieval may omit needed evidence; generation may misread good evidence. Evaluate both stages separately. A plausible answer can conceal failed retrieval, and a retrieval hit alone does not prove the final answer is supported.

Try it yourself

If the correct document never reached the prompt, which stage should be investigated first?

Worked answer

Retrieval and collection coverage. Prompt wording alone cannot supply evidence that was never retrieved.

Explore the full course →