Who it is forSomeone with a drawer of scanned bills, letters and manuals saved as image-only PDFs.
The problemScanned PDFs are just pictures, so search, copy and paste do not work.
The outcomeSearchable PDF/A files that look the same as the originals and are often smaller.
What you need first
- Linux, Windows (or WSL), macOS or FreeBSD, or the Docker image
- Ghostscript and Tesseract OCR installed
- Tesseract language packs for non-English documents
Steps
- Install it, for example
apt install ocrmypdfon Debian or Ubuntu, orbrew install ocrmypdfon macOS - Add an OCR layer with
ocrmypdf --output-type pdfa input.pdf output.pdf - Straighten crooked scans with
ocrmypdf --deskew input.pdf output.pdf - Turn a photo into a one page PDF with
ocrmypdf input.jpg output.pdf - See every option with
ocrmypdf --help
Prompt for your agent
Install ocrmypdf/OCRmyPDF and run it on every PDF in <folder> with `--output-type pdfa` and `--deskew`, writing results to <output folder>. Skip files that already have text and report the size before and after.
Caveat. OCR accuracy depends on scan quality; Tesseract struggles with handwriting and very low resolution images.
Use this in your AI agent
Ask your agent
Using the Deduped MCP, get the setup steps for ocrmypdf/OCRmyPDF and "Make your scanned PDFs searchable"
Add Deduped to Claude Code once
claude mcp add --transport http deduped https://dedupedai.com/mcp
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer