A two-hundred-page client scan splits into the wrong number of documents
In short
Reconcile counts before touching the splitter: how many physical documents went in, how many came out, sliced by document type. Boundary errors are uneven — single-page receipts are nearly perfect, while multi-page invoices and runs of near-identical statements carry almost all the error — so a batch-level accuracy figure says nothing about the documents that break.
Key takeaways
- Boundary detection and classification are separate failures; only one of them is fixed downstream.
- Count documents in against documents out per type — batch-level accuracy hides the type that breaks.
- Over-splitting is visible and cheap; under-splitting is silent and corrupts the merged document's data.
- A page-of-n marker is an assertion the splitter can check, not decoration on the page.
- 3 seconds of separation at capture is cheaper than 4 minutes of review a week later.
Reconcile counts before you look at the splitter. A 200-page batch that should have produced 63 documents and produced 58 has under-split by 5 boundaries; the same batch producing 71 has over-split by 8. Those two faults have different causes, different costs and different fixes, and the difference is invisible in any accuracy figure computed over the whole batch — because the error rate is not uniform across document types, it is concentrated in 2 or 3 of them.
The failure usually gets logged as a multi page PDF splitting document classification error, which quietly conflates two separate questions: where the boundary was drawn, and what the resulting document was called. Only the second is a classifier problem. A perfectly trained classifier handed a document containing the last page of one invoice and the first 2 pages of another has already lost, and no amount of retraining recovers it.
Count what went in against what came out, sliced by type
- Get a physical count at capture. Whoever feeds the scanner writes the document count on the batch sheet, or the portal records 1 upload per document. Without a number from the input side, every check downstream is comparing your output against your own output.
- Compare emitted documents to that count for the batch as a whole. A match proves nothing on its own — 1 merge and 1 split cancel out — but a mismatch is definitive and free.
- Sample 30 documents per type and mark each as correct, merged or fragmented. Type here means the thing that determines page structure: single-page receipt, multi-page invoice, monthly statement, multi-page form, covering letter.
- Score each type separately and never blend. A batch at 94% overall can be 99% on receipts, which are most of the volume, and 61% on multi-page invoices, which are most of the value. The same arithmetic that hides locale faults behind a low overall error rate hides this.
- Split the failures into over and under. Record which, because the two point at opposite adjustments and a single boundary accuracy number cannot tell you which direction to move.
Over-splitting is loud, under-splitting is silent
| Direction | What you see | Typical cause | What it costs |
|---|---|---|---|
| Over-split | More documents than went in; page-2 fragments with no supplier and no total | A repeated header on a continuation page, or a layout change mid-document | Visible: a reviewer sees an obviously partial document and merges it |
| Under-split | Fewer documents than went in; a document whose page count is unusually high | Consecutive documents of the same type and layout, or a blank verso that was dropped | Silent: the second document is never recorded at all, and the first extracts wrong totals |
| Boundary off by one | Correct document count, wrong page assignment at the seam | A duplex scan whose reverse side sorts to the wrong side of the break | Worst of both: nothing looks missing and 2 documents are quietly wrong |
Tune for under-splitting, not for accuracy. An over-split document announces itself: it has no header, no supplier, no total, and it fails every completeness check you already run. An under-split document looks entirely normal, extracts the first page's supplier and the last page's total, and the document that vanished inside it is not in any queue because nothing knows it existed.
Five places the boundary gets guessed wrong
- Multi-page documents with no page-of-n marking. A 3-page invoice whose pages 2 and 3 carry only line items and a footer gives the splitter no positive evidence of continuation. Many suppliers print page numbers on page 1 only, which is the worst possible arrangement.
- Continuation pages that repeat the header. The opposite fault: a supplier that reprints its logo, address and invoice number on every page hands the splitter what looks like the start of a new document, 3 pages in a row.
- Duplex scans with blank versos. Blank-page detection uses an ink-coverage threshold, and a faint bleed-through, a scanner artefact or a stray staple shadow puts a blank page over it. Drop a verso that was not blank and the boundary moves by 1 page; keep a blank that should have gone and a document acquires a page that belongs to nothing.
- Stapled bundles that are physically 1 document and logically 3. A remittance advice, the invoice it pays and a delivery note travel together, and a person scanning them sees 1 item. Whether they should be 1 document or 3 is a policy decision, and until somebody makes it, the count reconciliation has no defined right answer.
- Runs of near-identical documents. 12 monthly statements from the same account, or 20 invoices from the same supplier on the same template, defeat every layout-similarity signal at once — consecutive pages look alike precisely because they are alike, which is the signal the splitter was relying on.
Separator sheets are unglamorous and still the cheapest answer
A separator sheet moves the boundary decision from a model that is inferring it to a person who already knows it. The mechanism is old and reliable: a printed sheet carrying a barcode, commonly Code 128 or a QR code, or a patch-code pattern the scanner driver recognises, placed between documents by whoever is loading the feeder. The sheet is detected, the boundary is certain, and the sheet is discarded from the output.
Do the arithmetic before dismissing it as manual work. Placing a sheet takes about 3 seconds per document; finding and repairing 1 merged document later takes a reviewer several minutes, and that assumes it is noticed at all. At 60 documents in a batch, separation costs roughly 3 minutes of somebody's hands. One undetected merge that reaches the ledger costs more than that in a single query. Where the scanner supports it, per-document scanning — one press per document — removes the boundary problem outright and is faster than sheets for small batches.
Every boundary a person knows and does not record is a boundary a model has to guess, and the guess is made where the evidence is thinnest.
The durable fix sits where the pages are produced
Splitting is a recovery operation. It reconstructs information that existed at capture and was thrown away, which is why the returns on a better splitter fall off quickly while the returns on better capture do not. The practical moves are unglamorous: a portal that accepts 1 document per upload rather than 1 file per month, a mobile capture flow that ends a document explicitly, a scanner profile per client that matches how that client's paperwork actually arrives, and a standing request that clients send bank statements as separate downloads rather than 1 merged file.
Where the pages cannot be controlled — a client who will always send a 200-page scan — the answer is a review step designed for boundaries specifically, not a general document review. A reviewer shown page thumbnails with proposed breaks, who can drag a break 1 page either way, will correct a batch in a fraction of the time it takes to open and re-file documents one at a time. That is a small, specific interface, and building it is the sort of scoped AI agents and automation work that pays for itself in one filing season.
What a better splitter will not fix
A merged document does not fail loudly; it fails in the numbers. An invoice that absorbed the first page of the next invoice extracts a plausible supplier, a plausible date and a total that does not agree with its own line items — which is exactly the arithmetic fault described in line items that do not sum to the invoice total. A statement split mid-period fails balance continuity, which is why a statement-to-transactions pipeline that gates itself catches boundary damage that no splitting metric reports.
The under-split document has a worse ending. A purchase invoice that was never emitted as its own document is a purchase that was never recorded, and nothing downstream can miss what it never saw. On a tax return that turns up as a claim that does not agree with the counterparty's record — the shape of an input credit mismatch between the books and the portal, discovered late and reconciled by hand.
This is also the right question to put to any vendor demonstrating document intake. A clean 20-page batch of distinct layouts splits perfectly for everyone. Ask for the boundary error rate on 200 pages of your own worst client's paperwork, broken down by document type, and ask what the system does when it is unsure — the same evidence-over-claims test that applies to choosing an AI development partner generally. The rest of this sits in extraction and classification of source documents, part of the accounting and tax systems we build.
Frequently asked questions
Short answers to the follow-ups this page tends to raise.
How do you measure whether a batch scan was split correctly?
Compare a document count taken at capture against the count your pipeline emitted, then sample by document type. The batch-level number only tells you something is wrong; the per-type breakdown tells you where. Expect single-page receipts to be near-perfect and multi-page invoices, forms and runs of near-identical statements to carry almost all the error, which is why a blended accuracy figure is misleading.
Is it better to over-split or under-split a scanned batch?
Over-split. A fragment with no header, no supplier and no total fails your existing completeness checks and reaches a reviewer, so it costs a merge. An under-split document extracts as a normal-looking document with wrong totals, and the document swallowed inside it is never recorded anywhere — nothing can queue a document that no system knows exists.
Are barcode separator sheets still worth using?
Yes, when documents are batch-fed by a person who already knows where each one ends. A printed barcode or patch-code sheet takes roughly 3 seconds to place and makes the boundary certain rather than inferred, against several minutes to find and repair a single merge later. Where the scanner supports per-document capture, that is better still, because it removes the boundary decision instead of encoding it.
Why do 12 monthly statements from the same account split so badly?
Because most boundary detection relies on the page after a break looking different from the page before it, and consecutive statements from one account look identical by design — same header, same layout, same account number, only the period changes. Use the fields that must change between documents: statement period, page-of-n markers restarting, and the opening balance of one statement equalling the closing balance of the previous.
- document intake
- batch scanning
- document boundaries
- capture
The work behind this page
Builds from our portfolio that this page draws on.
AP Copilot
An AI accounts-payable copilot that reads invoices, matches them to POs, and routes clean approvals
FintechAskVault
An AI internal knowledge-search platform that answers employee questions from your own docs — grounded in citations, with knowledge gaps surfaced and deflection tracked.
Productivity AIScanQueue
An AI radiology worklist that flags suspected critical findings on incoming CT, MR and X-ray studies and orders every read by acuity and SLA — so the sickest patient is read first, not FIFO.
Healthcare AIRead next
- Extracted statement: closing balance does not equal opening plus movementsA bank statement proves its own completeness. Foot it page by page, and the size and sign of the difference tell you which row was dropped, duplicated, inverted or invented.diagnostic
- Half the client bank statements will not open in the pipeline at allA pile of failed jobs at the first step is four different problems wearing one error message. Classify by failure class before anyone retries, re-requests or asks a client for a password.diagnostic
- A credit note is not a negative invoice: where the sign really livesModel it as an invoice with a minus in front and three things break: allocation, tax reporting, and every aging report that reads the ledger afterwards.definition
- Dates and amounts come out wrong, but only for one client's suppliersA locale fault cannot corrupt every document, which is exactly why it survives. Sample the ambiguous cases only, sliced by supplier, and the fault appears at once.diagnostic
- Line items extract cleanly but they do not sum to the invoice totalThe lines are right, the total is right, and the two disagree. Divide the difference by the subtotal before opening the document — the ratio usually identifies the fault on its own.diagnostic
- One supplier arrives under six names, and none of them match the ledgerA supplier's name is the least stable field on its invoice. Match on the registration number, the remittance account and the address, and let name similarity break ties nothing else can.diagnostic
Working on something in this space?
Tell us where you are in a sentence or two. We'll tell you honestly whether we're the right team, and what a sensible first slice of the work looks like.
Start the conversation