ocr-and-documents

Extract text from PDFs and scanned documents via OCR or direct parsing into Markdown/structured data.

27|2|Updated Jan 15, 2024
One-click install
npx skills add https://github.com/erfanzar/Xerxes-Agents --skill ocr-and-documents-erfanzar
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ocr-and-documents
Source: https://github.com/erfanzar/Xerxes-Agents/tree/main/src/python/xerxes/skills/productivity/ocr-and-documents
Command: npx skills add https://github.com/erfanzar/Xerxes-Agents --skill ocr-and-documents-erfanzar

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires marker-pdf, pymupdf, pymupdf4llm, and includes scripts (resource) components.

What problem does it solve?

Extracts text from PDFs and scanned documents to turn unindexed files into searchable, machine-readable content for research, documentation, and data extraction workflows.

Core Features & Use Cases

  • Remote URL extraction via web_extract for online PDFs and reports.
  • Local text-based PDF extraction using pymupdf, with optional Markdown output and table or image extraction.
  • OCR-based extraction with marker-pdf for scanned documents, including multi-language support and layout-aware outputs.
  • Use Case: You have a batch of research PDFs containing figures and references; extract clean text and metadata for ingestion into a knowledge base.

Quick Start

Extract all text from the provided PDF or scanned document using the most suitable extractor path (web_extract for URLs, pymupdf for local PDFs, or marker-pdf for OCR-enabled documents).

Frequently Asked Questions about ocr-and-documents

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I extract text from scanned PDFs for research data processing?

You can extract text from scanned PDFs using OCR-based extraction via marker-pdf. It handles multi-language support and layout-aware outputs, turning unindexed files into machine-readable content for research data processing and indexing workflows.

What is the best way to convert a remote PDF URL to Markdown?

The best way to convert a remote PDF URL to Markdown is using the web_extract path. It fetches online reports and research papers directly, extracting clean text and metadata for immediate ingestion into your knowledge base or downstream data pipeline.

Can I use pymupdf for local text-based PDF extraction?

Yes, you can use pymupdf for local text-based PDF extraction. It provides optional Markdown output and supports extracting tables and images, making it suitable for processing local research documents and archived reports without requiring OCR.

Does this PDF extraction tool handle complex layouts and figures?

Yes, the tool handles complex layouts and figures using marker-pdf for advanced layout extraction. It processes research papers containing figures and references, outputting structured Markdown that preserves document layout for downstream data extraction.

When do I need OCR for document text extraction?

You need OCR for document text extraction when working with scanned documents or image-based files that lack embedded text layers. The Skill automatically applies marker-pdf for OCR-enabled documents, while using pymupdf for standard text-based local PDFs.

What are the limitations of extracting text from archived PDFs?

Limitations of extracting text from archived PDFs depend on document quality and whether files are text-based or scanned. While pymupdf handles local text PDFs and marker-pdf applies OCR for scans, severely degraded scans may still produce imperfect layout extraction.