- Home
- Skills
- Jst Well Dan
- Skill Box
- Document Skills Pdf
document-skills-pdf_skill
- Python
7
GitHub Stars
2
Bundled Files
2 months ago
Catalog Refreshed
4 months ago
First Indexed
Readme & install
Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.
Installation
Preview and clipboard use veilstrat where the catalogue uses aiagentskills.
npx veilstrat add skill jst-well-dan/skill-box --skill document-skills-pdf- LICENSE.txt1.4 KB
- SKILL.md6.9 KB
Overview
This skill is a comprehensive PDF manipulation toolkit for extracting text and tables, creating and editing PDFs, merging and splitting documents, and handling forms and security. It combines Python libraries and command-line utilities to support programmatic PDF processing at scale. The toolkit targets common workflows like OCR for scanned PDFs, table extraction, watermarking, and password protection.
How this skill works
The skill uses pypdf for page-level reading, writing, merging, splitting, rotation, metadata and encryption. It uses pdfplumber for high-fidelity text and table extraction and supports converting tables to pandas DataFrames for export. reportlab creates new PDFs and multi-page reports. For OCR and image extraction it integrates pdf2image and pytesseract, and command-line tools (pdftotext, qpdf, pdfimages) are available for performance-sensitive or scriptable tasks.
When to use it
- Extract plain text or layout-preserved text from searchable PDFs.
- Extract tables and convert them into CSV, Excel, or pandas DataFrames.
- Merge multiple PDFs or split a large PDF into per-page files.
- Generate reports or programmatically create multi-page PDFs with images and formatted text.
- Perform OCR on scanned PDFs to produce searchable text.
- Apply watermarks, rotate pages, or add password protection to PDFs.
Best practices
- Prefer pdfplumber for table extraction and pypdf for structural edits like merge/split/rotate.
- When extracting tables, convert to pandas DataFrame and validate column headers before exporting.
- Use pdf2image + pytesseract for scanned documents; tune tesseract language and DPI for better accuracy.
- Keep original metadata; update only when necessary and document changes in processing logs.
- Test command-line tools (qpdf, pdftotext) on large batches for speed; use them in pipelines when CPU-bound.
Example use cases
- Batch-merge monthly statements into a single PDF and add a company watermark.
- Extract tables from invoices into structured CSVs for accounting ingestion.
- Split a long legal brief into individual pages and rotate scanned pages as needed.
- Create a templated multi-page PDF report from database records using reportlab.
- OCR a scanned archive and produce searchable text files for indexing and search.
FAQ
Use pdfplumber for table detection and extraction, then convert results to pandas for cleanup and export.
How do I handle scanned PDFs?
Convert pages to images with pdf2image and run pytesseract for OCR; adjust DPI and language settings to improve results.