Large Language Models possess extensive general knowledge, but this knowledge is typically frozen at the time of their training. They lack access to real time information, internal company documents, or specific datasets created after their training concluded. This limitation restricts their usefulness in applications requiring current or proprietary context.
This chapter introduces Retrieval Augmented Generation (RAG), a technique designed to address this gap. RAG enables LLMs to access and utilize information from external sources dynamically. Instead of relying solely on their internal parameters, models can incorporate relevant, retrieved data into their generation process.
You will learn the core components and workflow of a RAG system. We will cover:
By the end of this chapter, you will understand how to connect LLMs to external knowledge sources, significantly expanding their applicability for tasks like question answering over specific documents or accessing up to date information.
6.1 Limitations of Standard LLM Knowledge
6.2 Introduction to Retrieval Augmented Generation (RAG)
6.3 Document Loading and Splitting
6.4 Text Embedding Models
6.5 Introduction to Vector Stores
6.6 Implementing Semantic Search/Retrieval
6.7 Combining Retrieved Context with Prompts
6.8 Basic RAG Pipeline Implementation
6.9 Hands-on practical: Build a RAG Q&A System for Documents
© 2025 ApX Machine Learning