{
 "schema_version": 1,
 "generated": "2026-10-31",
 "id": "microsoft-markitdown--ocr-images-inside-documents-with-an-llm",
 "repo": "microsoft/markitdown",
 "repo_url": "https://github.com/microsoft/markitdown",
 "repo_slug": "microsoft-markitdown",
 "title": "Pull text out of images inside PDFs and slides",
 "page_title": "How to pull text out of images inside PDFs and slides with Markitdown",
 "summary": "Add the markitdown-ocr plugin so text in embedded images is extracted with a vision LLM.",
 "who": "Someone converting slide decks and PDFs full of screenshots and scanned figures that come out blank.",
 "problem": "Text that lives inside embedded images is invisible to a normal converter, so key numbers and labels go missing.",
 "outcome": "Markdown that includes the text from images in PDF, DOCX, PPTX and XLSX files.",
 "steps": [
  "Install the plugin with `pip install markitdown-ocr` and an OpenAI-compatible client with `pip install openai`",
  "Check installed plugins with `markitdown --list-plugins`",
  "In Python, create a MarkItDown object with enable_plugins=True plus your llm_client and llm_model (the README uses OpenAI() and gpt-4o), then run `md.convert(\"document_with_images.pdf\")`",
  "Print `result.markdown` and compare it with the plain conversion",
  "Remember that without an llm_client the plugin still loads but OCR is silently skipped"
 ],
 "agent_prompt": "Using microsoft/markitdown with the markitdown-ocr plugin, convert <file> to Markdown with an OpenAI-compatible client and model <model>. Show me which text came from embedded images that the plain converter missed.",
 "agents": [
  "claude-code",
  "codex",
  "cursor"
 ],
 "difficulty": "Intermediate",
 "time": "20 minutes",
 "basis": "readme",
 "caveat": "OCR quality and cost depend on the vision model you pick; every image is a model call.",
 "category": "Research",
 "tags": [
  "Research"
 ],
 "lang": "python",
 "requirements": [
  "Python 3.10 through 3.14, ideally in a virtual environment",
  "Optional dependency groups for each format, or [all] for everything",
  "Optional: an OpenAI-compatible client for image descriptions and the markitdown-ocr plugin",
  "Optional: an Azure Document Intelligence or Content Understanding resource, which is billed per call"
 ],
 "risk": "none",
 "seen_in_the_wild": false,
 "mentioned_publicly": false,
 "risks": [
  {
   "tag": "credentials",
   "notice": "The plugin sends embedded images to the model provider behind your client, so do not run it on confidential files with a hosted model and keep the API key out of your code."
  }
 ],
 "best": false,
 "score": 0.9,
 "evidence": [],
 "url": "https://dedupedai.com/use-cases/microsoft-markitdown/ocr-images-inside-documents-with-an-llm/",
 "md": "https://dedupedai.com/use-cases/microsoft-markitdown/ocr-images-inside-documents-with-an-llm/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/microsoft-markitdown--ocr-images-inside-documents-with-an-llm.json",
 "api_version": "v1"
}
