Overview

In Chapter 4, we turned entire documents into single embedding vectors. That worked fine for tiny samples, but longer texts run into limits. If a document covers multiple topics or runs too long for an embedding model, turning the whole thing into one vector muddies the meaning.

This chapter is about chunking: breaking longer documents into smaller pieces before we embed them. In our RAG pipeline, this lets us search for the specific part of a text that answers a query instead of having to feed huge, noisy documents into an LLM later.


Key Concepts


What We Implemented


Why It Matters