{
 "schema_version": 1,
 "generated": "2026-10-31",
 "id": "ocrmypdf-ocrmypdf--batch-ocr-an-archive-with-in-place-updates",
 "repo": "ocrmypdf/OCRmyPDF",
 "repo_url": "https://github.com/ocrmypdf/OCRmyPDF",
 "repo_slug": "ocrmypdf-ocrmypdf",
 "title": "OCR a whole archive in place, safely",
 "page_title": "How to oCR a whole archive in place, safely with OC Rmy PDF",
 "summary": "Process thousands of pages across all CPU cores, updating files only when OCR succeeds.",
 "who": "An office manager digitising years of paper records into a shared drive.",
 "problem": "Large archives take forever one file at a time, and a crash halfway can leave broken files.",
 "outcome": "An archive where every PDF is searchable, processed in parallel and replaced only on success.",
 "steps": [
  "Install OC Rmy PDF and the language packs you need",
  "Update a file in place with `ocrmypdf myfile.pdf myfile.pdf`; it only modifies the file on success",
  "Use the --jobs option to control how many cores it uses; it uses multiple cores by default",
  "Pair it with paperless-ngx, which integrates OC Rmy PDF into a searchable document management system",
  "Swap the engine with a plugin such as OCRmyPDF-EasyOCR if you have a GPU"
 ],
 "agent_prompt": "Write a script that runs ocrmypdf/OCRmyPDF in place on every PDF under <archive folder>, logs successes and failures to a CSV, and never overwrites a file when OCR fails. Run it on a small test folder first and show me the log.",
 "agents": [
  "claude-code",
  "codex",
  "cursor"
 ],
 "difficulty": "Intermediate",
 "time": "1 hour",
 "basis": "readme",
 "caveat": "Speed depends on your CPU and page count; the README does not give throughput numbers.",
 "category": "Life admin",
 "tags": [
  "Life admin"
 ],
 "lang": "python",
 "requirements": [
  "Linux, Windows (or WSL), macOS or FreeBSD, or the Docker image",
  "Ghostscript and Tesseract OCR installed",
  "Tesseract language packs for non-English documents"
 ],
 "risk": "none",
 "seen_in_the_wild": false,
 "mentioned_publicly": false,
 "risks": [
  {
   "tag": "data-loss",
   "notice": "In place mode rewrites your originals; it only modifies a file on success, but back up the archive before a large run."
  }
 ],
 "best": false,
 "score": 0.8,
 "evidence": [],
 "url": "https://dedupedai.com/use-cases/ocrmypdf-ocrmypdf/batch-ocr-an-archive-with-in-place-updates/",
 "md": "https://dedupedai.com/use-cases/ocrmypdf-ocrmypdf/batch-ocr-an-archive-with-in-place-updates/index.md",
 "disclaimer": "Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked \"Seen in the wild\", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email hello@dedupedai.com and we will look at it promptly.",
 "api": "https://dedupedai.com/api/v1/usecases/ocrmypdf-ocrmypdf--batch-ocr-an-archive-with-in-place-updates.json",
 "api_version": "v1"
}
