Provides an interface to Tesseract OCR for high-accuracy text extraction from various image formats.
Install
mkdir -p .claude/skills/ocr && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/1835" && unzip -o skill.zip -d .claude/skills/ocr && rm skill.zipInstalls to .claude/skills/ocr
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Extract text from images using Tesseract OCRKey capabilities
- →Extract text from PNG, JPG, GIF, BMP, TIFF, and WEBP files
- →Support extraction for over 100 languages
- →Apply grayscale and thresholding image preprocessing
- →Generate output in plain text or JSON format
- →Include confidence scores in JSON output
How it works
The skill utilizes the Tesseract OCR engine to process images, optionally applying preprocessing steps like grayscale and thresholding to improve character recognition accuracy.
Inputs & outputs
When to use ocr
- →Extract text from scanned documents
- →Digitize image-based data
- →Process images from URLs
About this skill
OCR Image Text Extraction Skill
Extract text from images using Tesseract OCR engine.
Capabilities
- Extract text from image files (PNG, JPG, JPEG, GIF, BMP, TIFF)
- Support for 100+ languages
- Optional image preprocessing for better accuracy
- Output in plain text or JSON format with confidence scores
Usage
Basic OCR
python3 scripts/ocr.py <image_file> <output_file>
With Options
# Specify language (default: eng)
python3 scripts/ocr.py image.png text.txt --lang eng
# Chinese text
python3 scripts/ocr.py image.png text.txt --lang chi_sim
# Multiple languages
python3 scripts/ocr.py image.png text.txt --lang eng+chi_sim
# With image preprocessing (improves accuracy)
python3 scripts/ocr.py image.png text.txt --preprocess
# JSON output with confidence scores
python3 scripts/ocr.py image.png output.json --format json
Download and OCR from URL
# OCR from remote image
python3 scripts/ocr_url.py <image_url> <output_file>
# With options
python3 scripts/ocr_url.py https://example.com/image.jpg text.txt --lang eng --preprocess
Parameters
image_file/image_url(required): Path to local image or image URLoutput_file(required): Path to output text/JSON file--lang: Language code (e.g., eng, chi_sim, jpn, fra, deu). Default: eng--preprocess: Apply image preprocessing (grayscale, thresholding) for better accuracy--format: Output format (text/json, default: text)
Common Languages
| Language | Code |
|---|---|
| English | eng |
| Chinese (Simplified) | chi_sim |
| Chinese (Traditional) | chi_tra |
| Japanese | jpn |
| Korean | kor |
| French | fra |
| German | deu |
| Spanish | spa |
| Russian | rus |
| Arabic | ara |
Supported Image Formats
PNG, JPG, JPEG, GIF, BMP, TIFF, WEBP
Dependencies
- Python 3.8+
- pytesseract
- Pillow (PIL)
- tesseract-ocr (system package)
Installation
# Python packages
pip install pytesseract Pillow
# Tesseract OCR engine
sudo apt-get install tesseract-ocr # Ubuntu/Debian
sudo yum install tesseract # CentOS/RHEL
brew install tesseract # macOS
When not to use it
- →When processing non-image document formats
- →When high-accuracy extraction is required for low-quality, noisy images
Prerequisites
Limitations
- →Accuracy depends on image quality and preprocessing settings
- →Requires installation of system-level Tesseract engine
How it compares
This approach automates the digitization of image-based text through a command-line interface, whereas manual methods require manual transcription or GUI-based tools.
Compared to similar skills
ocr side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| ocr (this skill) | 35 | 6mo | Review | Beginner |
| data-engineering | 13 | 7mo | Review | Advanced |
| crawl4ai | 21 | 8mo | Review | Intermediate |
| data-cleaning-pipeline | 13 | 5mo | Review | Intermediate |
Try saying
Example prompts that trigger this skill in your AI assistant.
More by trpc-group
View all by trpc-group →You might also like
data-engineering
pluginagentmarketplace
ETL pipelines, Apache Spark, data warehousing, and big data processing. Use for building data pipelines, processing large datasets, or data infrastructure.
crawl4ai
basher83
This skill should be used when users need to scrape websites, extract structured data, handle JavaScript-heavy pages, crawl multiple URLs, or build automated web data pipelines. Includes optimized extraction patterns with schema generation for efficient, LLM-free extraction.
data-cleaning-pipeline
aj-geddes
Build robust processes for data cleaning, missing value imputation, outlier handling, and data transformation for data preprocessing, data quality, and data pipeline automation
paddle-ocr-validation
jgtolentino
PaddleOCR-based receipt and BIR form extraction with validation
airflow-dag-patterns
wshobson
Build production Apache Airflow DAGs with best practices for operators, sensors, testing, and deployment. Use when creating data pipelines, orchestrating workflows, or scheduling batch jobs.
instrument-data-to-allotrope
anthropics
Convert laboratory instrument output files (PDF, CSV, Excel, TXT) to Allotrope Simple Model (ASM) JSON format or flattened 2D CSV. Use this skill when scientists need to standardize instrument data for LIMS systems, data lakes, or downstream analysis. Supports auto-detection of instrument types. Outputs include full ASM JSON, flattened CSV for easy import, and exportable Python code for data engineers. Common triggers include converting instrument files, standardizing lab data, preparing data for upload to LIMS/ELN systems, or generating parser code for production pipelines.