mineru-extract
MinerUのAPIを活用し、URL先のウェブページやPDFなどの情報を、レイアウトや表、数式、OCR処理を含めて、より正確なMarkdown形式に変換して整理されたデータを取り出すSkill。
📜 元の英語説明(参考)
Use the official MinerU (mineru.net) parsing API to convert a URL (HTML pages like WeChat articles, or direct PDF/Office/image links) into clean Markdown + structured outputs. Use when web_fetch/browser can’t access or extracts messy content, and you want higher-fidelity parsing (layout/table/formula/OCR).
🇯🇵 日本人クリエイター向け解説
MinerUのAPIを活用し、URL先のウェブページやPDFなどの情報を、レイアウトや表、数式、OCR処理を含めて、より正確なMarkdown形式に変換して整理されたデータを取り出すSkill。
※ jpskill.com 編集部が日本のビジネス現場向けに補足した解説です。Skill本体の挙動とは独立した参考情報です。
下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o mineru-extract.zip https://jpskill.com/download/8445.zip && unzip -o mineru-extract.zip && rm mineru-extract.zip
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/8445.zip -OutFile "$d\mineru-extract.zip"; Expand-Archive "$d\mineru-extract.zip" -DestinationPath $d -Force; ri "$d\mineru-extract.zip"
完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。
💾 手動でダウンロードしたい(コマンドが難しい人向け)
- 1. 下の青いボタンを押して
mineru-extract.zipをダウンロード - 2. ZIPファイルをダブルクリックで解凍 →
mineru-extractフォルダができる - 3. そのフォルダを
C:\Users\あなたの名前\.claude\skills\(Win)または~/.claude/skills/(Mac)へ移動 - 4. Claude Code を再起動
⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。
🎯 このSkillでできること
下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。
📦 インストール方法 (3ステップ)
- 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
- 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
- 3. 展開してできたフォルダを、ホームフォルダの
.claude/skills/に置く- · macOS / Linux:
~/.claude/skills/ - · Windows:
%USERPROFILE%\.claude\skills\
- · macOS / Linux:
Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。
詳しい使い方ガイドを見る →- 最終更新
- 2026-05-18
- 取得日時
- 2026-05-18
- 同梱ファイル
- 1
📖 Skill本文(日本語訳)
※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。
MinerU Extract (公式 API)
MinerUをアップストリームの「コンテンツ正規化ツール」として使用します。 MinerUにURLを送信し、完了をポーリングし、結果のzipをダウンロードして、メインのMarkdownを抽出します。
クイックスタート (MCP準拠)
MinerU MCPのメンタルモデルに準拠していますが、MCPサーバーは実行しません。
- 主要スクリプト (MCPスタイル):
scripts/mineru_parse_documents.py- 入力:
--file-sources(カンマ/改行区切り) - 出力: stdoutへのJSONコントラクト:
{ ok, items, errors }
- 入力:
- 低レベルスクリプト (単一URL):
scripts/mineru_extract.py
認証:
MINERU_TOKENを設定 (mineru.netからのBearerトークン)
デフォルトのモデルヒューリスティック:
.pdf/.doc/.ppt/.png/.jpgで終わるURL →pipeline- それ以外 →
MinerU-HTML(WeChatの記事のようなHTMLページに最適)
1) トークンを設定 (スキルローカル)
スキルルートの.envにシークレットを配置します (チャット出力に貼り付けないでください):
# mineru-extractスキルのディレクトリ内: .env
MINERU_TOKEN=your_token_here
MINERU_API_BASE=https://mineru.net
2) URLを解析 → Markdown (推奨)
MCPスタイルのラッパー (JSONを返し、オプションでmarkdownテキストを含みます):
python3 mineru-extract/scripts/mineru_parse_documents.py \
--file-sources "<URL1>\n<URL2>" \
--language ch \
--enable-ocr \
--model-version MinerU-HTML
markdownコンテンツをJSONにインラインで含めたい場合 (大きくなる可能性があります):
python3 mineru-extract/scripts/mineru_parse_documents.py \
--file-sources "<URL>" \
--model-version MinerU-HTML \
--emit-markdown --max-chars 20000
低レベル (単一URL、markdownをstdoutに出力):
python3 mineru-extract/scripts/mineru_extract.py "<URL>" --model MinerU-HTML --print > /tmp/out.md
出力
スクリプトは常にMinerUの結果zipをダウンロードして以下に展開します:
~/.openclaw/workspace/mineru/<task_id>/
以下を書き込みます:
result.zip- 抽出されたファイル (Markdown + JSON + アセット)
stderrにパスを含むJSONサマリーを出力します:
task_id,full_zip_url,out_dir,markdown_path
パラメータ (共通)
--model:pipeline | vlm | MinerU-HTML(HTMLにはMinerU-HTMLが必要)--ocr/--no-ocr: OCRを有効にする (pipeline/vlmに有効)--table/--no-table: 表認識--formula/--no-formula: 数式認識--language ch|en|...--page-ranges "2,4-6"(非HTML)--timeout 600/--poll-interval 2
失敗モードとフォールバック
- MinerUは一部のURLの取得に失敗する可能性があります (アンチボット / 地域 / ログイン)。
- フォールバック: HTMLファイルまたはPDF/長いスクリーンショットを提供します。次に、MinerUバッチアップロードエンドポイントを使用して「アップロード+解析」フローを実装します。
- 常に失敗したURL + MinerUの
err_msgを報告し、出力に元のソースリンクを保持します。
参考文献
- MinerU APIドキュメント: https://mineru.net/apiManage/docs
- MinerU出力ファイル: https://opendatalab.github.io/MinerU/reference/output_files/
📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開
MinerU Extract (official API)
Use MinerU as an upstream “content normalizer”: submit a URL to MinerU, poll for completion, download the result zip, and extract the main Markdown.
Quick start (MCP-aligned)
We align to the MinerU MCP mental model, but we do not run an MCP server.
- Primary script (MCP-style):
scripts/mineru_parse_documents.py- Input:
--file-sources(comma/newline-separated) - Output: JSON contract on stdout:
{ ok, items, errors }
- Input:
- Low-level script (single URL):
scripts/mineru_extract.py
Auth:
- Set
MINERU_TOKEN(Bearer token from mineru.net)
Default model heuristic:
- URLs ending with
.pdf/.doc/.ppt/.png/.jpg→pipeline - Otherwise →
MinerU-HTML(best for HTML pages like WeChat articles)
1) Configure token (skill-local)
Put secrets in skill root .env (do not paste into chat outputs):
# In the mineru-extract skill directory: .env
MINERU_TOKEN=your_token_here
MINERU_API_BASE=https://mineru.net
2) Parse URL(s) → Markdown (recommended)
MCP-style wrapper (returns JSON, optionally includes markdown text):
python3 mineru-extract/scripts/mineru_parse_documents.py \
--file-sources "<URL1>\n<URL2>" \
--language ch \
--enable-ocr \
--model-version MinerU-HTML
If you want the markdown content inline in the JSON (can be large):
python3 mineru-extract/scripts/mineru_parse_documents.py \
--file-sources "<URL>" \
--model-version MinerU-HTML \
--emit-markdown --max-chars 20000
Low-level (single URL, print markdown to stdout):
python3 mineru-extract/scripts/mineru_extract.py "<URL>" --model MinerU-HTML --print > /tmp/out.md
Output
The script always downloads + extracts the MinerU result zip to:
~/.openclaw/workspace/mineru/<task_id>/
It writes:
result.zip- extracted files (Markdown + JSON + assets)
It prints a JSON summary to stderr with paths:
task_id,full_zip_url,out_dir,markdown_path
Parameters (common)
--model:pipeline | vlm | MinerU-HTML(HTML requiresMinerU-HTML)--ocr/--no-ocr: enable OCR (effective forpipeline/vlm)--table/--no-table: table recognition--formula/--no-formula: formula recognition--language ch|en|...--page-ranges "2,4-6"(non-HTML)--timeout 600/--poll-interval 2
Failure modes & fallbacks
- MinerU may fail to fetch some URLs (anti-bot / geo / login).
- Fallback: provide an HTML file or a PDF/long screenshot; then implement “upload + parse” flow with MinerU batch upload endpoints.
- Always report the failing URL + MinerU
err_msgand keep an original-source link in outputs.
References
- MinerU API docs: https://mineru.net/apiManage/docs
- MinerU output files: https://opendatalab.github.io/MinerU/reference/output_files/