Lattice
Skip to content

Chunking

Splitting documents into retrievable pieces, which is where RAG quality is mostly won and lost.

By Entry last reviewedmethod

What it implies

Fixed token count with overlap is close to the worst reasonable option: it cuts through sentences, tables and arguments. Chunk on structure (headings, paragraphs, table rows), and carry the heading path in the chunk metadata so retrieved text has its own context. Then check the number that correlates most with answer quality: how many chunks you actually feed the model. Fifty is almost always worse than five.

Tools in this index

Related terms

Rules of thumb

  • A definition is only useful next to the decision it changes. Read the linked layer to see where this term bites.
  • If a vendor's definition differs from this one, ask what it measures. Marketing definitions rarely name a number.
  • Every optimisation spends latency, memory or quality somewhere. Find out which before you turn it on.

Ask an AI about this page

Opens the assistant with this page’s link and a question already filled in.