Document Splitter
The Document Splitter component — break a long document into page chunks an agent can process piece by piece.
The Document Splitter component splits a document into smaller files. Give it a PDF and it produces a list of chunks, each a file of its own, in page order. It's a deterministic step — no model involved — built for one job: letting a long document fan out across several agent calls instead of one call that silently truncates.
Why split at all
A model call has a budget. Ask one agent to process a 200-page statement and the output gets cut off, or the middle gets skimmed. Split the document first and each chunk lands comfortably inside the model's limits — every page actually gets read, and the work runs in parallel.
How it works
The splitter takes one input, document — a file, usually wired from a file field on the Input or from an earlier step.
- PDFs are split by pages. The pages per chunk setting controls how many pages each chunk carries (default: one page per chunk).
- Other file types — images, text — pass through whole, as a single-element list. They're already one chunk.
- A PDF with no more pages than the chunk size also passes through unchanged.
The output is an array of files, in page order. Chunk names tell you where
each one came from: report-p3.pdf for a single page, report-p3-5.pdf for a
range.
Fan out over the chunks
The splitter's list output is made to feed a batching agent. Wire the splitter into an Agent node and set the agent to batch over its input: the agent runs once per chunk, a concurrency setting caps how many run at once, and the agent's output becomes an array of the per-chunk results, in the same order.
Input (file) → Document Splitter → Agent (batched) → OutputThat's the whole pattern for long-document processing: split, fan out, collect.
As a tool
The Document Splitter also supports tool mode. Connect it to an agent's tools handle and the agent can decide to split a file itself while it works, rather than the workflow splitting up front.