name: pdf-extract-skill description: "OpenClaw PDF extraction skill using OpenDataLoader. Use when the user wants to extract and process PDF content for RAG, embeddings, or coordinate-based citations." license: "Apache-2.0" metadata: {"openclaw":{"emoji":"📄","requires":{"bins":["java","python3","opendataloader-pdf"],"runtimes":["Java 11+","Python 3.10+"]}},"clawdbot":{"emoji":"📄","requires":{"bins":["java","python3","opendataloader-pdf"],"runtimes":["Java 11+","Python 3.10+"]}}}
To improve maintainability and allow targeted calls to specific .md files, this skill relies on helper documents:
Usage rules: - If the task is setup/startup: load quickstart-cli.md - Before any installation: load security-before-install.md - If the task is command execution by scenario: load profiles-openclaw.md - If the task involves scanned or complex table PDFs: load hybrid-mode-ocr.md - If the task is RAG/citations: load rag-citations.md - If there are errors: load troubleshooting.md
This skill maximizes PDF reading quality for OpenClaw in ClawHub using OpenDataLoader PDF.
Pillars: - Local extraction (no cloud) for privacy. - High-quality reading order and structure (columns, tables, layout). - RAG and LLM-ready outputs (json + markdown). - Simple end-user flow (CLI, no MCP).
Use this skill when the user needs to: - Extract clean text from PDFs. - Improve table and multi-column parsing. - Prepare data for RAG, embeddings, or coordinate-based citations. - Process scanned PDFs with OCR. - Describe images/charts to make them searchable.
Do not use this skill for: - OCR of standalone image files outside PDF workflows. - Cloud-only pipelines where local Java execution is not allowed.
Since the MCP does not exist yet, this skill must operate with CLI only: - Client command: opendataloader-pdf - Hybrid backend command: opendataloader-pdf-hybrid
Do not create complex wrappers or intermediate services unless strictly needed.
Always validate before conversion: - Java 11+ in PATH. - Python 3.10+. - Package install policy: - Do not use unpinned installs in production. - Use isolated environments (venv/container/VM). - Prefer pinned versions and verified sources. - See: docs/security-before-install.md
Quick checks: - java -version - pip index versions opendataloader-pdf - pip show opendataloader-pdf - opendataloader-pdf --help
If Java fails on Windows, reopen the terminal and verify PATH.
Always process multiple files in a single invocation to avoid JVM startup overhead per call.
Recommended example: opendataloader-pdf file1.pdf file2.pdf ./folder/ -o ./output -f json,markdown
Suggested response: 1. Status: ok or warning 2. Processed files 3. Output path 4. Generated formats 5. Suggested next action
Template: "Processing completed. N PDFs were converted to ./output with json,markdown format. If you want, I can now extract specific pages or enable OCR for scanned files."
opendataloader-pdf ./pdfs/ -o ./output -f markdown
opendataloader-pdf ./pdfs/ -o ./output -f json,markdown
opendataloader-pdf report.pdf -o ./output -f json --pages "1,3,5-7"
opendataloader-pdf report.pdf -o ./output -f markdown --sanitize
opendataloader-pdf report.pdf -o ./output -f markdown --keep-line-breaks
opendataloader-pdf report.pdf -o ./output -f json --image-output external opendataloader-pdf report.pdf -o ./output -f json --image-output embedded
Use it when: - Tables are complex or borderless. - PDFs are scanned. - Multi-language OCR is required. - Image/chart descriptions are required.
Standard: opendataloader-pdf-hybrid --port 5002
Forced OCR: opendataloader-pdf-hybrid --port 5002 --force-ocr
Multi-language OCR: opendataloader-pdf-hybrid --port 5002 --force-ocr --ocr-lang "es,en"
With image descriptions: opendataloader-pdf-hybrid --port 5002 --enrich-picture-description
Hybrid auto mode: opendataloader-pdf --hybrid docling-fast file1.pdf file2.pdf ./folder/ -o ./output -f json,markdown
With timeout and fallback: opendataloader-pdf --hybrid docling-fast --hybrid-timeout 120000 --hybrid-fallback file1.pdf ./folder/ -o ./output -f json
Image descriptions enabled (full required): opendataloader-pdf --hybrid docling-fast --hybrid-mode full file1.pdf ./folder/ -o ./output -f json,markdown
Critical note: If the backend starts with --enrich-picture-description, the client must use --hybrid-mode full to include descriptions in output.
小蔥技能站7w4.net每天更新,海量AI技能等你發現。
Problem: Java not found. Solution: install Java 11+ and verify with java -version.
Problem: Hybrid backend connection error. Solution: start opendataloader-pdf-hybrid in another terminal and verify port 5002.
Problem: Too slow. Solution: process in batches, increase hybrid timeout, and verify backend RAM.
Problem: Mixed columns. Solution: use default reading mode (xycut) and try --use-struct-tree for tagged PDFs.
Problem: Poor table quality. Solution: use json output + hybrid mode.
This skill uses and credits the excellent OpenDataLoader project: https://opendataloader.org/
Official documentation used for this version: https://opendataloader.org/docs
這個Skill質量不錯,文件分類清晰、查詢方便,使用前安全提示到位,提供的命令模板可以直接複製使用。但缺少實際效果示例,部分說明文字偏簡略。對於需要快速處理PDF的使用者來說基本夠用,但想了解具體效果和引數細節時可能需要額外參考。總體屬於中上水平,核心功能覆蓋全面,文件易讀性較好。