pdf

Extract, merge, split, create, and fill PDF documents using Python libraries and command-line tools.

1|Updated Feb 5, 2026
One-click install
npx skills add https://github.com/ankur3-101106/dotfiles-hypr --skill pdf-ankur3-101106
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: pdf
Source: https://github.com/ankur3-101106/dotfiles-hypr/tree/main/Claude/local-agent-mode-sessions/skills-plugin/ab436dd0-752a-4b9b-8503-dc6695d483cb/cedd2988-3bab-48aa-884f-cc7b3bfb8e81/skills/pdf
Command: npx skills add https://github.com/ankur3-101106/dotfiles-hypr --skill pdf-ankur3-101106

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve? Working with PDF files programmatically is fragmented across many libraries and tools, and tasks like filling forms, extracting tables, or handling scanned documents each require different approaches. This Skill consolidates PDF processing into one guide with ready-to-run scripts and code examples. ## Core Features & Use Cases - Text, Table & Image Extraction: Pull text, structured tables, and embedded images from PDFs using pypdf, pdfplumber, and poppler-utils, with OCR support for scanned documents via pytesseract. - PDF Manipulation: Merge, split, rotate, watermark, encrypt, decrypt, and create new PDFs with pypdf, reportlab, and qpdf. - PDF Form Filling: Fill both fillable forms (via field extraction and validation scripts) and non-fillable forms (via structure extraction, coordinate-based annotations, and bounding box validation). - Use Case: You receive a non-fillable government form as a PDF. The Skill extracts the form structure, determines precise field coordinates, validates bounding boxes, and produces a completed PDF with text annotations placed accurately. ## Quick Start Use the pdf skill to extract all tables from the attached report.pdf and save them to a spreadsheet.

Frequently Asked Questions about pdf

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

FAQPage Schema
How do I fill a PDF form that has no fillable fields?▼

Extract the form structure with the extract_form_structure.py script to get label, line, and checkbox coordinates, then build a fields.json with entry bounding boxes. Validate with check_bounding_boxes.py and fill using fill_pdf_form_with_annotations.py, which adds text annotations at the specified positions.

How do I extract tables from a PDF in Python?▼

Use pdfplumber's page.extract_tables() method, which detects table structure and returns rows as lists. You can convert the results to pandas DataFrames and export them to Excel, with custom table settings available for complex layouts.

What is the difference between pypdf and pdfplumber?▼

pypdf handles structural operations like merging, splitting, rotating, encryption, and form field updates. pdfplumber focuses on content extraction, providing text with precise coordinates and table detection based on page layout.

Can I extract text from a scanned PDF?▼

Scanned PDFs contain images rather than text layers, so standard extraction fails. Convert pages to images with pdf2image, then run pytesseract OCR on each image to recover the text content.

Why do subscript characters render as black boxes in reportlab PDFs?▼

ReportLab's built-in fonts lack Unicode subscript and superscript glyphs, so those characters render as solid boxes. Use the <sub> and <super> XML markup tags inside Paragraph objects instead of Unicode characters.

How do I merge or split PDFs from the command line?▼

Use qpdf: merge with 'qpdf --empty --pages file1.pdf file2.pdf -- merged.pdf' and split page ranges with 'qpdf input.pdf --pages . 1-5 -- output.pdf'. The pdftk tool offers similar merge, burst, and rotate operations if installed.