OCR models for forms and handwriting: layout and reading order
A wrong field beats a wrong letter, every time, in cost. I'd defend that on a whiteboard, one qualifier attached: character accuracy still counts, less than people assume. A system can read every glyph right and still be worthless if it can't tell which box a lone "4" belongs to. Forms, surveys, delivery slips, checklists, handwriting added to a printed field: it carries meaning in position, not just ink. Crossed-out numbers, touching characters, faint pencil, ambiguous check marks, a note outside its box: ordinary input, not an edge case. A vision-language model may sort that out, or swap an uncertain character for something smoother than the document.
Start with boxes, not sentences
OCR output needs blocks, coordinates, hierarchy, and reading order, because on a form layout carries as much meaning as the marks. First pass, keep it boring: template registration, region cropping, a printed-text engine, a separate handwriting recognizer. A generative model earns a slot only where it beats those stages, hard handwriting, irregular layouts, a distant label linked to a value, exceptions the rules can't resolve, and nowhere else.
Keep the source file immutable, assign page and document identifiers, and log the path each value travels:
source hash, page, capture device
crop, dewarp, denoise version
OCR / layout / VLM model + revision
raw text, region, order, confidence, reviewer change
Never let normalization overwrite what the recognizer saw: an ambiguous O or 0, an I or 1, a decimal against a minus sign, a unit, a diacritic, store the raw read and the business rule's guess as separate fields. Score structure on multi-column and sidebar pages on its own, since error rate treats a missing comma the same as a wrong account number, and those aren't the same mistake. The real gate is field association, checkbox state, blank detection, and exact-match scoring on identifiers, dates, and amounts.
The lie that reads smoothly
The failure worth losing sleep over isn't garbled text, it's a legible value sitting in the wrong field, or a mark the model decided was there when the page shows nothing. Neither looks broken. Models continue plausible patterns by training: a damaged surname or smudged total gets completed into whatever looks familiar, and reads fine to anyone not checking the source. Build an abstention path: low resolution, glare, unreadable handwriting, contradictory totals raise an exception, not a guess. Confidence scores run model-specific and poorly calibrated, so pair them with image-quality checks, format validators, cross-field arithmetic, and pass disagreement.
Provenance turns review into verification, not retyping: store the page number and bounding polygon per field that matters, and show the crop beside the value, so a reviewer resolves an uncertain digit fast. When a vision-language model handles a hard case, separate observation from inference, and keep tool calls and writes behind schema validation outside the model. Text in the document is untrusted input, not an instruction. Across a multi-page batch, preserve page order and header identity yourself; never let the model merge statements.
Version models, preprocessing, and validation together, and replay a stratified set, clean pages through known-impossible ones, whenever one piece changes. Local processing keeps documents under your roof, cheap at steady volume; hosted APIs buy elasticity and a higher exception ceiling for a price per page. A hybrid split earns its complexity only when the privacy line is real.
One discipline, kept above all: never let a value leave the pipeline without the coordinates that prove where it came from.