pdf-reader

pdf-reader is a skill for Claude Code, Codex from Kocoro-lab/Kocoro. It costs 38 tokens per session (473 once invoked), scanned A, original, MIT.

A guide for analyzing PDF files supplied by the user, including documents made of selectable text and scanned pages that are really images.

In plain words
What is it for?
Use it to read and summarize PDFs, inspect scanned pages, or extract exact text from text-heavy documents.
Why use it?
It lets you examine text, tables, charts, forms, signatures, and stamps without assuming the PDF contains searchable text.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/kocoro-lab/kocoro/pdf-reader
Any agent
npx skills add Kocoro-lab/Kocoro --skill pdf-reader
Clone the repo
git clone --depth 1 https://github.com/Kocoro-lab/Kocoro

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pdf-reader

README.md
[![agentmods](https://agentmods.dev/badge/skills/kocoro-lab/kocoro/pdf-reader.svg)](https://agentmods.dev/skills/kocoro-lab/kocoro/pdf-reader)
Your own site
<a href="https://agentmods.dev/skills/kocoro-lab/kocoro/pdf-reader"><img src="https://agentmods.dev/badge/skills/kocoro-lab/kocoro/pdf-reader.svg" alt="Measured on agentmods" height="20"></a>
Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 473 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00038 $0.00473
Opus 5 $0.00019 $0.00236
Sonnet 5 $0.00008 $0.00095
Haiku 4.5 $0.00004 $0.00047

Measured 5d ago against content hash 59361e9e1857, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

pdf-reader scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

subprocess.check_call(['pip3', 'install', 'pymupdf', '-q'])
internal/skills/bundled/skills/pdf-reader/SKILL.md · 53 lines

What it actually says

PDF Reader

Analyze PDF files using the file_read tool which natively supports PDF rendering.

How file_read handles PDFs

  • file_read with a .pdf path renders pages as images for vision analysis
  • Parameters: offset = start page (0-based), limit = max pages (default 5)
  • Each page is rendered at 144 DPI, resized to 1568px max dimension
  • Returns image blocks that you can analyze with vision

Workflow

  1. Read the PDF: Call file_read with the PDF path. It will render pages as images automatically.

    {"path": "/path/to/file.pdf"}
    
  2. For multi-page PDFs: Read in batches using offset and limit.

    {"path": "/path/to/file.pdf", "offset": 5, "limit": 5}
    
  3. Analyze the content: The rendered pages come back as images. Describe what you see — text, tables, charts, forms, signatures, stamps, etc.

  4. Extract text if needed: For text-heavy PDFs where you need exact content, use bash with python:

    python3 -c "
    import subprocess
    subprocess.check_call(['pip3', 'install', 'pymupdf', '-q'])
    import fitz
    doc = fitz.open('/path/to/file.pdf')
    for i, page in enumerate(doc):
        text = page.get_text()
        if text.strip():
            print(f'--- Page {i+1} ---')
            print(text)
    "
    

Tips

  • Always start with file_read — it handles both scanned and text PDFs via vision
  • For scanned PDFs (image-based), vision analysis through file_read is the primary method
  • For text PDFs where exact character-level accuracy matters, supplement with python text extraction
  • When summarizing, note the total page count and which pages you've analyzed
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 53 lines · 38 tokens per session scan A 59361e9e1857

Subscribe to this mod's changes

pdf-reader is a skill published in the GitHub repository Kocoro-lab/Kocoro (406 stars, last pushed 2d ago), licensed MIT. It adds 38 tokens to every session and 473 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.