Skip to content

LeoLin990405/mineru-skill

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MinerU Skill

mineru-skill

A Claude Code skill for parsing documents with the MinerU API

License Stars Issues Claude Code Skill MinerU v2.7.6

Convert PDF, DOC, DOCX, PPT, PPTX, and images into clean Markdown/JSON
with OCR, formula recognition, table extraction, and batch processing.


Features

Feature Description
Cloud API No GPU needed — uses mineru.net hosted service
Local API Self-hosted with mineru-api for full control
Smart Models hybrid (default), pipeline, vlm, MinerU-HTML
Rich Extraction OCR (109 languages), LaTeX formulas, cross-page tables
Batch Processing Parse up to 200 files per request
Extra Formats Export to DOCX, HTML, or LaTeX alongside Markdown
CLI Script mineru-parse.sh for quick command-line usage
Auto-Extract Download + unzip + display markdown in one step

Quick Start

1. Install the Skill

cd ~/.claude/skills
git clone https://github.com/LeoLin990405/mineru-skill.git mineru

2. Set Up API Token

Get a free token at mineru.net/apiManage/token, then:

mkdir -p ~/.config/mineru
echo "YOUR_TOKEN" > ~/.config/mineru/token
chmod 600 ~/.config/mineru/token

3. Use It

In Claude Code — just ask naturally:

Parse this PDF to markdown: https://arxiv.org/pdf/2301.00001.pdf
Extract tables from report.pdf using the vlm model with OCR

Via CLI script:

# Parse from URL
./scripts/mineru-parse.sh https://example.com/paper.pdf --output ./parsed --extract

# Parse local file with VLM model
./scripts/mineru-parse.sh report.pdf --model vlm --ocr --output ./out

# Extra output formats
./scripts/mineru-parse.sh slides.pptx --format docx --format html

CLI Reference

mineru-parse.sh <url_or_file> [options]

Options

Option Description Default
--model <m> Model version hybrid
--ocr Enable OCR off
--no-formula Disable formula recognition on
--no-table Disable table recognition on
--output <dir> Download results to directory -
--extract Auto-extract zip, show markdown off
--pages <range> Page ranges, e.g. "1-5,8" all
--format <fmt> Extra format: docx/html/latex -
--callback <url> Webhook for async notification -
--data-id <id> Custom tracking identifier -
--quiet Suppress progress output off

Environment Variables

Variable Default Description
MINERU_TOKEN_FILE ~/.config/mineru/token Token file path
MINERU_API_BASE https://mineru.net/api/v4 API base URL
MINERU_POLL_INTERVAL 5 Poll interval (seconds)
MINERU_MAX_POLL 360 Max poll attempts

Models

Model Best For Speed Notes
hybrid General use Medium Default since v2.7.0, recommended
pipeline CPU-only environments Fast No GPU required
vlm Complex layouts, scanned docs Slower Needs 10GB+ VRAM
MinerU-HTML Preserving HTML structure Medium Web content

API Limits (Cloud)

Item Limit
File size 200 MB
Pages per file 600
Daily priority pages 2,000 / account
Batch upload 200 files / request
Token validity 90 days

Examples

See the examples/ directory for:

Project Structure

mineru-skill/
├── SKILL.md                 # Claude Code skill definition (full API reference)
├── scripts/
│   └── mineru-parse.sh      # CLI helper script
├── examples/
│   ├── parse_single.sh      # Single URL parsing example
│   ├── parse_local.sh       # Local file parsing example
│   └── parse_batch.py       # Batch processing example (Python)
├── .github/
│   ├── ISSUE_TEMPLATE/      # Bug report & feature request templates
│   └── PULL_REQUEST_TEMPLATE.md
├── CONTRIBUTING.md
├── CHANGELOG.md
├── LICENSE                  # MIT
└── README.md

Documentation

Full API reference including all endpoints, request/response formats, error codes, and Python/curl examples is in SKILL.md.

Contributing

Contributions are welcome! Please read the Contributing Guide before submitting a PR.

Related Projects

  • MinerU — The document parsing engine by OpenDataLab
  • Claude Code — Anthropic's CLI for Claude

License

MIT © 2026 LeoLin990405

About

Claude Code skill for MinerU document parsing API - convert PDF/DOC/PPT/images to Markdown/JSON

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages