Who it is forA researcher, paralegal, or office worker with a folder of scanned PDFs who needs editable text without a GPU or a cloud upload.
The problemScanned PDFs cannot be searched, quoted, or edited, and manual retyping is slow.
The outcomeOne .md file per input PDF in a results folder, with headings, paragraphs, lists, and tables kept where the layout allows.
What you need first
- Python 3.10 or newer (the README says it is tested on Linux and macOS)
- pip to install the indra-ocr package
- An internet connection for the first run, which downloads about 76 MB of models from Hugging Face
- The PDFs or images to read
Steps
- Run
pip install indra-ocr. - Move the scanned PDFs into one folder and open a terminal in that folder.
- Run
indra-ocr *.pdf --out results/to write one .md file per input. - Open a few files in results/ and compare them with the original pages.
- If a run hits an unreadable file, note its name; the CLI continues past it and exits with 1 if any failed.
Prompt for your agent
In the repo datalab-to/indra, install indra-ocr with pip and run `indra-ocr <folder>/*.pdf --out results/`. Expected output: one .md file per input PDF in results/. Verify that each .md file is non-empty and that the CLI exit code is 0, or list the files that failed.
Caveat. The code is Apache 2.0, but the model weights use a modified OpenRAIL-M license that limits some commercial and competitive uses, so check the license before using it in a product.
Use this in your AI agent
Ask your agent
Using the Deduped MCP, get the setup steps for datalab-to/indra and "Turn a folder of scanned PDFs into markdown files"
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