From the course: Building Applications Using Amazon Bedrock

Unlock the full course today

Join today to access over 24,900 courses taught by industry experts.

Retrieval-augmented generation (RAG)

Retrieval-augmented generation (RAG)

- [Presenter] Retrieval-augmented generation or RAG is one of the most popular AI frameworks for retrieving facts from an external knowledge base or data source. RAG helps to provide large language models with the most accurate up-to-date information. LMS can be inconsistent. They may answer questions correctly, but at other times, they may generate random facts from their training data, providing incorrect responses resulting in a process called hallucination. This is because LLMs understand how words relate statistically, but do not know what they mean. One of the main reasons that RAG is needed is that large language models are trained on a vast corpus of data, but training of the models were as of a specific cutoff date. Implementing RAG in an LLM-based question answering system has two main benefits. One, it ensures that the model has access to the most current reliable facts, and two, that users have access…

Contents