pdf-ocr

Extract text, formulas, and images from PDF documents using OCR.

Updated Mar 6, 2026
One-click install
npx skills add https://github.com/ghjghjghkimo/skills --skill pdf-ocr
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: pdf-ocr
Source: https://github.com/ghjghjghkimo/skills/tree/main/.gemini/skills/pdf-ocr
Command: npx skills add https://github.com/ghjghjghkimo/skills --skill pdf-ocr

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires docling, docling_core, and includes scripts (resource) components.

What problem does it solve?

将 PDF 的內容提取工作自動化,結合 OCR、公式識別與圖片辨識,降低手動轉錄與校對成本,提升工作效率。

Core Features & Use Cases

  • 高品質 OCR:使用 PP-OCRv5 進行中英文識別與排版保留。
  • 公式提取:支援科學公式轉為 MathML,或保留 LaTeX 原始格式。
  • 路徑自動修正與穩定化:內建 clean_path 類型邏輯,處理不規範的檔案路徑。
  • 硬體加速:預設使用 CUDA,優化高端顯示卡的性能。

Quick Start

在專案目錄下執行 pdf-ocr 的工具,輸入待處理的 PDF 路徑並指定輸出目錄。

Frequently Asked Questions about pdf-ocr

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

FAQPage Schema
How do I extract text and formulas from scanned PDF documents using OCR?

To extract text and formulas from scanned PDFs, this tool automates OCR using PP-OCRv5 for text recognition and converts scientific formulas into MathML or LaTeX. It handles document digitization by processing the input PDF path and outputting editable content.

Does PDF OCR support Chinese and English text recognition with layout retention?

Yes, PDF OCR supports high-quality Chinese and English text recognition using PP-OCRv5. It preserves the original document layout during the text extraction process, ensuring the digitized output maintains structural fidelity to the source material.

Do I need CUDA to run Python-based document processing and OCR on scientific papers?

CUDA is not strictly required but is used by default for hardware acceleration. A CUDA-compatible GPU optimizes performance during high-volume document processing and OCR tasks, significantly speeding up extraction from scientific papers.

What is the best way to convert scientific formulas in PDFs to LaTeX or MathML?

Converting scientific formulas to LaTeX or MathML is handled through an OCR pipeline with formula enrichment. This process identifies formulas within PDF documents and outputs them directly in MathML or preserves the original LaTeX format.

Can docling handle image extraction alongside text extraction from PDF files?

Yes, the pipeline built on docling and docling_core handles image extraction alongside text and formula extraction. It automates the complete extraction of visual elements, text, and formulas from PDF documents into a designated output directory.