pdf-reader
Skill0 starsChanged 4 months agoApache-2.0View on GitHub
Read PDF files without flooding context — extract page-range text as markdown, pull out figures by ID, render pages to images. Use whenever the user asks about the contents of a PDF file.
- Installs packages
13 other projects use a version of this.
Adopted by
Most recently taken up by
- Damon-GSY/skillstheir own version, first seen Nov 8, 2026
- shkodnik1917/claude-brainlabtheir own version, first seen Nov 8, 2026
- drinkspiller/skillstheir own version, first seen Nov 6, 2026
- Vepricov/claude-brainlabtheir own version, first seen Nov 1, 2026
- amosblomqvist/pi-configtheir own version, first seen Oct 8, 2026
- themusecatcher/ai-coding-kittheir own version, first seen Sep 15, 2026
Other versions13 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 13
- amosblomqvist/pi-config★ 1.1ksame name
- shkodnik1917/claude-brainlab★ 35same name
- Vepricov/claude-brainlab★ 35same name
- BluebagAI/skills★ 33same name
- phanghonghao/THU-Awesome-Skills★ 8same name
- vichhka-git/pdf-reader-skills★ 3same name
- themusecatcher/ai-coding-kit★ 2same name
- tunnckoCore/skills★ 2same name
- Damon-GSY/skills★ 1same name
- drinkspiller/skills★ 1same name
3 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository2 other files it gives its agents.
- cf-temp-deploySkill
- reviewSkill
The file
We split this skill into the rules it gives an agent
4 rules. 0 are common, 1 is distinctive, and 3 are very specific to this project.
0
Common
Most of the 10 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 7
Use the pdfread.py tool next to this file to read PDFs.
- Very specific: line 18
Run pdfread.py --help for full usage.
- Very specific: line 45
Run info to get the page count and outline, and partition the document into sensible ranges (by chapter, or ~15–25 pages).
- Distinctive: line 51
Keep only the summaries/answers in the main conversation and synthesize from those.
“Common” is measured: kept by at least 6 in 10 of the 10 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Use the pdfread.py tool next to this file to read PDFs. Run it either way:
- With uv 0.11+ (preferred): invoke
pdfread.pydirectly — the shebang runs it viauv run, and the first invocation downloads dependencies and may take a minute. - Without uv:
python3 pdfread.py …works on any Python 3.10+ that haspymupdf4llm>=0.0.17installed (pip install pymupdf4llm).
The search command needs SQLite with FTS5; uv-managed and nearly all
modern system Pythons include it, and the script errors clearly if not.
Run pdfread.py --help for full usage. In short:
pdfread.py info FILE— page count, metadata, outline/TOC. Start here.pdfread.py search FILE "terms"— pages mentioning the keywords, BM25-ranked with a snippet per hit. The first search builds a cached index (seconds); later searches are instant. Terms are ANDed,term*matches prefixes,--rawunlocks full FTS5 syntax ("exact phrase", OR, NEAR). Text layer only — scanned pages are invisible to search.pdfread.py text FILE --pages 10-25— markdown text for a 1-based page range. Figures appear as[image: p12-img2 640x480px]placeholders.pdfread.py image FILE p12-img2— write that figure as a PNG and print its path; view it with your file-reading tool.pdfread.py images FILE --pages 12— list figure IDs on pages.pdfread.py render FILE 7— render a whole page (or--rect x0,y0,x1,y1crop) to a PNG; the fallback for scanned pages and anything the text layer misses.
Preserving context on large PDFs
For pinpoint questions ("where does the contract mention termination fees?"),
run search first and read only the hit pages with text --pages — no
subagent fan-out needed. The index cache is shared, so subagents can search
too without rebuilding.
For broad synthesis, do not dump a whole document into the main conversation. Instead:
- Run
infoto get the page count and outline, and partition the document into sensible ranges (by chapter, or ~15–25 pages). - Spawn a subagent per range with instructions like: "Run
<path>/pdfread.py text <file> --pages 10-25and answer <the user's question> / summarize in at most N words. If a[image: ...]placeholder looks relevant, extract it with theimagecommand and look at it." - Keep only the summaries/answers in the main conversation and synthesize from those. Re-target specific pages yourself only when a summary indicates the answer lives there.
Notes
- There is no OCR: a page with no text layer comes back as just its full-page
[image: ...]placeholder (or a "no extractable text" note) — extract orrenderit and read the image visually. - Extraction is deterministic: image IDs are stable across runs, so a subagent's reported ID can be extracted later from the main conversation.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

