Chunking Visualizer

See exactly where a document is cut into passages for RAG. Nothing is uploaded.

Document

Passages

Each colour is one passage. Underlined words are repeated from the passage before.

The three methods at this size

MethodPassagesAverageRangeEnd mid-sentence

How it works

Before a document can be searched by a RAG system it is cut into short passages, usually called chunks. Where the cuts fall decides what can be found later: a passage that stops halfway through a sentence, or mixes two topics, is harder to match to a question.

This visualizer shows the cuts on your own text. Each passage gets its own colour, words repeated by overlap are underlined, and the numbers above show how many passages you get, how even they are and how many end in the middle of a sentence. The table compares the three splitting methods at the size you chose.

When the passages look right, export them as JSON or CSV, or carry the same settings into the RAG tool to ask questions.

Questions

What is chunking?

Chunking is splitting a document into short passages so that each one can be turned into a vector and searched. It is the first step of retrieval-augmented generation.

What chunk size should I use?

There is no single best size. Small passages match precisely but lose context; large ones keep context but mix topics. Start around 40 to 100 words, look at where the cuts fall, then test with real questions.

What is chunk overlap?

Overlap repeats the last few words of one passage at the start of the next, so a sentence cut in two still appears whole in one of them. It makes the stored text larger, shown here as the repeated percentage.

What is the difference between the three methods?

Fixed size cuts every set number of words and can break a sentence. Sentence keeps sentences whole. Heading keeps each section together and adds its heading to every passage.

Are sizes measured in words or tokens?

In words, because they are easier to picture. The token figure above is an estimate of the total a model would process to embed all the passages.

Is my text uploaded?

No. Everything runs in your browser tab. Your documents and questions never leave your device.

More

Try RAG on your own document · Token Counter & Cost Estimator · What is RAG? · How to choose a chunk size for RAG