pdf

Create, read, merge, fill, and secure PDF files using pypdf, reportlab, and pdfplumber.

Updated Aug 22, 2026
One-click install
npx skills add https://github.com/vivekgoquest/hermes-agent-stable --skill pdf-vivekgoquest
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: pdf
Source: https://github.com/vivekgoquest/hermes-agent-stable/tree/main/skills/productivity/pdf
Command: npx skills add https://github.com/vivekgoquest/hermes-agent-stable --skill pdf-vivekgoquest

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires pypdf, reportlab, pdfplumber, pypdfium2, Pillow, and includes scripts (resource) and references (resource) components.

What problem does it solve? Working with PDFs programmatically is fragmented across many libraries and error-prone tasks — generating reports, building fillable forms, extracting tables, merging documents, and encrypting files each require different tools and careful handling of edge cases like scanned pages and encrypted inputs. ## Core Features & Use Cases - PDF Generation & Forms: Build multi-page documents from JSON specs with reportlab, and create fillable AcroForm forms (text, checkbox, radio, dropdown) with layout linting and visual overlay review before building. - Extraction & Manipulation: Extract per-page text, tables (JSON/CSV), metadata, and form-field values; merge, split, rotate, watermark, stamp, compress, and export pages as PNG images. - Security & Metadata: Encrypt/decrypt with AES-256 passwords, set or clear DocInfo metadata, and embed or extract file attachments. - Use Case: Generate an invoice PDF from a JSON spec, build a fillable intake form with validated layout, then merge it with supporting documents and encrypt the final package with a user password. ## Quick Start Use the pdf skill to extract all text and tables from the attached report.pdf and save the tables as CSV files.

Frequently Asked Questions about pdf

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I extract text and tables from a PDF in Python?▼

Use pdfplumber for per-page text extraction and table detection, which outputs rows as JSON arrays or CSV files. The pdf_read.py script wraps this with --text and --tables flags, returning structured JSON to stdout.

How to create a fillable PDF form with Python?▼

Define fields in a JSON spec with entry_box coordinates in PDF points, lint the layout with pdf_form_layout.py, then build the AcroForm with pdf_make_form.py using reportlab. It supports text, checkbox, radio, and dropdown fields.

Can pypdf extract text from scanned PDF documents?▼

No, scanned PDFs are image-only and contain no text layer, so pypdf and pdfplumber return empty text. Export pages as PNGs with pdf_page_image.py and route them to an OCR skill instead of reporting empty content.

How do I encrypt a PDF with a password using Python?▼

Use pypdf's PdfWriter.encrypt with AES-256, setting distinct user and owner passwords. The pdf_secure.py script handles this via --encrypt with --user-password, and --decrypt removes encryption when the password is known.

Why does PDF form flattening lose field values?▼

pypdf's flattening merges widget appearances into page content but can drop exotic widgets like rich text or some radio groups. Verify flattened output visually, and use Ghostscript as a fallback for bulletproof rendering.

What are the limitations of PDF compression with pypdf?▼

pypdf's compress_content_streams only deflates content streams, typically saving 0-20%. It does not recompress images, so image-dominated PDFs see little benefit; use Ghostscript for image downsampling instead.