BuildMidData / MLAuto-graded
Chunk a document into overlapping retrieval passages
Tests whether documents can be split for AI search without losing information at the joins or dropping the ending.Every retrieval system starts by chunking: splitting a document into pieces small enough to embed, overlapping enough that a fact straddling a boundary still lands whole in at least one chunk. It is the ingestion step, it runs once per document, and it is quietly load-bearing — bad chunks mean bad retrieval however good the embedding model is. Make the chunker correct, including on the edges where naive implementations loop forever or lose text.30 min
python
You're done when
- A document shorter than the chunk size produces a single chunk containing all of it.
- An overlap as large as or larger than the chunk size is handled without looping forever.
- Consecutive chunks overlap by the configured amount, so boundary-straddling content survives.
- Every part of the document appears in at least one chunk — nothing is dropped.
What it measures
RAG and retrieval systemsUnderstanding why overlap exists and what a bad chunk boundary costs downstream.
Data integration and ETLWriting an ingestion step that is safe on the whole range of real documents, not just typical ones.
Edge-case rigourHandling the degenerate configurations — empty input, oversized overlap — that turn a chunker into an infinite loop in production.
Your environment
Terminal + editorA full shell in the browser
Claude CodePre-authenticated, no key setup
Isolated microVMYours alone, wiped afterwards
Start this lab
30 min
Start labYou'll sign in to Anthropos to start. The lab opens in a private cloud workspace with Claude Code ready to use.AI Labs is part of Anthropos Workforce. Not on your plan yet? Book a demo