OCR for scanned books and PDFs

If your scans come out interleaved, or Tesseract is fast but wrong on indexes and endnotes, I build the layout step and score it against hand-transcribed pages.

Mean character error rate on 14 hand-checked pages. Lower is better.

  1. B.L.A.S.T. · RapidOCR + layout0.108
  2. Tesseract 4.1.1 · raw0.177
  3. Tesseract 4.1.1 · restored0.187
  4. RapidOCR 1.4.4 · raw defaults0.458
One book, CPU only. Without its two outlier pages, a near-blank index and a cloth cover, raw Tesseract edges ahead: 0.074 against 0.077.

Measured proof & related work

B.L.A.S.T. OCR Engine

0.108 CER

down from 0.499 (14 hand-checked pages)

An OCR pipeline built with RapidOCR, ONNX, and PyMuPDF. Across versions adding layout handling and changing the OCR engine, character error rate fell from 0.499 (initial EasyOCR build) to 0.108 on 14 hand-checked pages from one 1959 book. The suite has 914 collected tests. Table extraction is supported; table accuracy is not yet benchmarked.

RapidOCR vs Tesseract Benchmark

0.177 vs 0.108

Tesseract vs B.L.A.S.T. CER

Published empirical benchmark on 14 hand-checked pages from one 1959 book. Out-of-the-box Tesseract 4.1.1 scored CER 0.177, won 9 of 14 pages and ran at 3.7 seconds per page (~4.5x faster than B.L.A.S.T. at 16.5 seconds per page). B.L.A.S.T. is ahead on average because Tesseract failed on two nearly empty pages.

Scanned-Book OCR Guide

Gutter splitting, reading-order checks and measured Tesseract vs RapidOCR tradeoffs for two-page book spreads.

Menu Data Pipeline

17 sources

restaurant sites extracted concurrently

Data extraction and normalization pipeline pulling from 17 concurrent restaurant menu sites with HTTP/2 and Pydantic validation into Google Sheets.

Is this a fit?

Good fit

  • Scanned books, historical archives, and double-page document spreads that break conventional OCR line detection.
  • Multi-column documents where reading order must be preserved without interleaving adjacent columns.
  • Teams that require measurable accuracy against transcribed ground truth rather than subjective claims.
  • Pipelines processing batches of scanned PDFs, presentations, or images into structured Markdown, DOCX, or JSON.

Not a fit

  • Unconstrained handwritten notes or cursive script without clear character boundaries.
  • Projects expecting sub-second OCR on low-power CPUs without layout analysis.
  • Teams wanting a generic desktop click-and-drag GUI instead of a Python pipeline or API.

What you get

  • Gutter-splitting preprocessor that isolates two-page book spreads into single pages.
  • Deterministic multi-column reading order and bounding box correction.
  • CLI, FastAPI endpoint, or web interface deployment for running document batches.
  • RapidOCR ONNX or Tesseract engine integration tuned to your specific document type.
  • Structured table normalization with export to clean Markdown, DOCX, or JSON.
  • Automated evaluation harness with CER (character error rate) and WER benchmark scripts.

What I need from you

  • Representative sample scans or PDFs showing typical page condition, column layouts, and print quality.
  • Desired output format specifications (Markdown headings, Word styles, or JSON table schemas).
  • Any hand-transcribed ground truth pages you have for objective benchmark scoring.
  • Deployment constraints (CPU-only vs GPU server, batch CLI vs real-time FastAPI endpoint).

Limits and failure modes

Every system has boundaries where it breaks or degrades. Here is what to expect and how the pipeline responds.

Faint ink and bleed-through
Severely faded text or ink leaking through thin paper requires aggressive binarization that may occasionally drop punctuation or thin serifs.
Pre-processing latency
The published OCR-call timings are 3.7 seconds per page for raw Tesseract and 16.5 for B.L.A.S.T. on CPU. They exclude image restoration, so full-pipeline processing takes additional time and needs a separate measurement.
Engine performance variance
In my published benchmark, out-of-the-box Tesseract won 9 of 14 pages against the B.L.A.S.T. layout pipeline. Different document corpuses require testing to pick the best engine.
Borderless complex tables
Tables without clear lines or with multi-line merged cells require custom bounding-box heuristics and may need manual review on edge cases.

Working process

  1. Sample document review

    Describe your documents in the contact inquiry or email sample pages to ibrahim.pk848@gmail.com. I inspect the page layouts and reply by email.

  2. Benchmark assessment

    If it fits, we set up a call to review format requirements, column structures, and accuracy benchmarks.

  3. Milestone agreement

    You receive a written scope and fixed price agreed before any pipeline code is written.

  4. Pipeline engineering & benchmarking

    I build the image preprocessing, OCR engine routing, table parsing, and automated evaluation test suite.

  5. Pipeline handover & benchmark check

    Work starts with half paid at kickoff, and the final half upon delivery of the pipeline, test harness, and source code.

Scope and pricing approach

OCR engagements are scoped as fixed deliverables for specific document batches, ongoing development sprints, or accuracy audits.

For a defined OCR pipeline, half is paid at kickoff and the remainder after the pipeline passes accuracy checks on your sample pages and is handed over with the test suite.

First working OCR pipeline (MVP)

1-2 weeks

One end-to-end extraction path for representative document batches.

Production build

2-3 weeks

Layout correction, table parsing, CLI/FastAPI interfaces, and benchmark evaluation suite.

Architecture audit

3-5 days to 1-2 weeks

A review of an existing OCR pipeline's accuracy, CER/WER scoring, and failure modes.

OCR pipeline prices are quoted after inspecting sample scans. Full engagement terms: pricing.md.

Have a project or problem like this?

Send a brief →

Frequently asked questions

How do you handle two-page scanned spreads?

The pipeline scans the central gutter between pages, splits the image into two independent single pages, and processes each page in natural reading order before recombining the output.

When does a custom self-hosted OCR pipeline make sense over cloud APIs?

A self-hosted pipeline (like RapidOCR or Tesseract on your own servers) keeps document processing inside your own infrastructure without per-page cloud API calls. It also lets you customize preprocessing, such as gutter splitting and column reordering, for your specific document formats before text extraction.

Can the pipeline extract tables into structured data?

Yes. The pipeline identifies bounding boxes for table rows and columns, normalizes the text cells, and outputs clean Markdown tables, CSVs, or structured JSON.

How is OCR accuracy verified?

We score character error rate (CER) and word error rate (WER) against hand-transcribed gold pages using an automated evaluation script, so accuracy gains are empirically measured.