Agent skill

PDF Ingestion

by Archive228 in Archive228/loopkit

Get a PDF into the model without blowing the context window or losing structure.

MITAuto-check passedDocuments & Office

Install PDF Ingestion

skills CLI
$ npx skills add Archive228/loopkit --skill pdf-ingestion -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install Archive228/loopkit pdf-ingestion --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/Archive228/loopkit.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/pdf-ingestion .claude/skills/pdf-ingestion && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
pdf-ingestion
GitHub stars
755
Token cost
~969 tokens
SKILL.md length
521 words
Files
1
Skills in repo
43
Repo updated
First seen
Licence
MIT

At a glance

Get a PDF into the model without blowing the context window or losing structure.

  • Works in 3 steps: Native PDF input — pass the file… → Text extraction then send — pdftotext /… → Extract → chunk → summarize → send — for…
  • Tasks that involve PDF
  • SKILL.md covers Deciding which path, Native PDF — the good defaults, Extract-then-send — the traps and Extract → chunk → summarize…, plus 2 more sections
  • Calls pdftotext

What it does

PDF Ingestion is an agent skill from Archive228/loopkit. Get a PDF into the model without blowing the context window or losing structure. Native PDF beats OCR-then-text for most cases; extract-then-summarize beats native for very long docs.

Its SKILL.md is about 970 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Documents & Office, covering PDF and Context engineering. The repository describes itself as: 33 battle-tested skills + minimal .claude harness for any coding agent (Claude Code, Cursor, Codex, Gemini CLI). The licence is MIT.

When your agent uses it

  • Tasks that involve PDF
  • Tasks that involve Context engineering

Example prompts

  • “/pdf-ingestion”

Workflow steps

3 steps, taken from the first numbered list in SKILL.md.

  1. Native PDF input — pass the file directly. Model sees pages as images + extracted text. Best for docs under ~100 pages with meaningful…
  2. Text extraction then send — pdftotext / pypdf / equivalent, then send the text. Loses layout but cheap. Fine for prose-heavy docs where…
  3. Extract → chunk → summarize → send — for docs >100 pages or when you'll query the same doc many times. Preprocess once, cache the summary.

What it can do on your machine

Read from SKILL.md and the folder at commit 5ae033e. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • pdftotext

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

PDF Ingestion loads about 969 tokens when it runs. Until then it costs about 49 tokens; SKILL.md has 521 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~49
When it runs · the whole SKILL.md, loaded when a task matches
~969

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from Archive228/loopkit at commit 5ae033e, republished under its MIT licence (© Archive228). 521 words, ~969 tokens.

Download SKILL.mdSave it as .claude/skills/pdf-ingestion/SKILL.md (or your agent's skills folder).
name
pdf-ingestion
description
Get a PDF into the model without blowing the context window or losing structure. Native PDF beats OCR-then-text for most cases; extract-then-summarize beats native for very long docs.
when_to_use
user drops a PDF, "read this report", extracting tables/figures from a doc, long-form doc summarization, spec document that lives as PDF

PDF Ingestion

Three ways to feed a PDF to the model, in increasing order of preprocessing:

  1. Native PDF input — pass the file directly. Model sees pages as images + extracted text. Best for docs under ~100 pages with meaningful layout (tables, figures, forms). Preserves structure.

  2. Text extraction then send — pdftotext / pypdf / equivalent, then send the text. Loses layout but cheap. Fine for prose-heavy docs where tables don't matter.

  3. Extract → chunk → summarize → send — for docs >100 pages or when you'll query the same doc many times. Preprocess once, cache the summary.

Deciding which path

Doc shapePath
<20 pages, layout matters (report, form, invoice)Native
<20 pages, pure prose (article, memo)Text extraction
20-100 pages, mixedNative, but chunk if context tight
>100 pagesExtract → chunk → summarize
Scanned PDF (no text layer)OCR first (Tesseract or vision model), then treat as extracted text
Tables are the pointNative — text extractors mangle tables
Figures/diagrams are the pointNative + explicit "describe the figure on page N" prompt

Native PDF — the good defaults

  • Cache the PDF at a prompt-caching breakpoint (see prompt-caching). Native PDFs are large — every uncached turn costs full input price on the whole doc.
  • Ask about specific pages ("summarize section 3.2 on page 14") rather than the whole doc. The model handles targeted queries better than "summarize this 80-page report".
  • Follow up with page-cited claims — "on which page does the doc say X?" — as a sanity check the model isn't hallucinating.

Extract-then-send — the traps

  • pdftotext reading order. Multi-column PDFs come out as interleaved lines. Use pdftotext -layout for column preservation, or pdftotext -raw for straight reading order — pick per doc, don't guess.
  • Tables become word soup. If tables are load-bearing, native or per-table image extraction. Not text.
  • Headers/footers repeat on every page. Strip them before sending, or the model will treat them as content.
  • Footnotes drift to random positions in the extracted stream. Filter or accept the noise.
Show full SKILL.md (202 more words)Show less

Extract → chunk → summarize (long docs)

  • Chunk by section, not by token count. A section-aware split respects the doc's logic; a naive 4K-token split cuts sentences and tables.
  • Summarize per section into a "map" — 1-2 paragraphs each. Keep the map short enough to fit in context whole (~2-4K tokens for a 200-page doc).
  • Store the full section text alongside the map (paths in a manifest). Fetch on demand when a question needs detail beyond the summary.
  • Cache the map at a prompt-caching breakpoint so multi-turn Q&A over the doc doesn't reprocess.

Red flags

  • Sending a 200-page PDF native to answer one question. Extract the relevant page range first.
  • Trusting the text extractor on a form or invoice. Layout carries meaning. Use native.
  • OCR'ing a PDF that already has a text layer. Check pdftotext -q file.pdf - first — if text comes out, no OCR needed.
  • No page citations in output. Model can hallucinate confidently across long PDFs. Force page numbers into the response format.
  • Re-uploading the same PDF every turn without caching. Cost climbs linearly; a 5-minute cache fixes it.

Loopkit-adjacent

If the PDF is a spec, extract it into PROMPT.md via spec-first — the agent should re-read prose, not re-scan the PDF, on every turn.

© Archive228, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/pdf-ingestion of Archive228/loopkit.

Open the folder on GitHubat commit 5ae033e

Compare with similar skills

PDF Ingestion next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

PDF Ingestion compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
PDF Ingestion this skillArchive228/loopkit755—~969Automated safety check: PassMIT
Split PDFscunning1975/MixtapeTools4742 repos~2.9kAutomated safety check: PassNone
MarkitdownImCa0/just-laws78114 repos~3.2kAutomated safety check: NotesMIT
Gzh Designisjiamu/gzh-design-skill4k—~2.2kAutomated safety check: PassAGPL-3.0
GenOffice Document CLIgenspark-ai/genoffice9.2k—~19kAutomated safety check: PassApache-2.0
Harness Book Best Practicewquguru/harness-books3.2k—~4.1kAutomated safety check: PassNone

Similar skills

  • Split PDF

    scunning1975/MixtapeTools

    Download, split, and deeply read academic PDFs. An agent skill from scunning1975/MixtapeTools.

    474 GitHub starsUsed in 2 repos~2.9k tokens
    Documents & OfficeAuto-check passed
  • Markitdown

    ImCa0/just-laws

    Convert files and office documents to Markdown. An agent skill from ImCa0/just-laws.

    781 GitHub starsUsed in 14 repos~3.2k tokens
    Documents & OfficeAuto-check: notes
  • Gzh Design

    isjiamu/gzh-design-skill

    微信公众号文章排版引擎,将 Markdown 转换为可直接粘贴到公众号编辑器的 HTML。主题风格从 references/theme-index.md 注册的自定义主题库中选取,自动章节编号、关键词下划线标记、引言卡片、目录导航、代码块、图片/GIF、作者签名。支持 Markdown / Word(.docx) / PDF / 纯文本输入(非 Markdown…

    4k GitHub stars~2.2k tokensUpdated yesterday
    Documents & OfficeAuto-check passed
  • GenOffice Document CLI

    genspark-ai/genoffice

    Creates, converts, reads and edits real pptx, xlsx, docx and PDF files locally through the genoffice command line.

    9.2k GitHub stars~19k tokensUpdated today
    Documents & OfficeAuto-check passed
  • Harness Book Best Practice

    wquguru/harness-books

    Best practices for working on the Harness books repo. An agent skill from wquguru/harness-books.

    3.2k GitHub stars~4.1k tokensUpdated 5 mo ago
    Documents & OfficeAuto-check passed
  • Produces book-style Korean ebook PDFs from a topic or finished manuscript, with six design styles, real book parts and quality-check gates before output.

    316 GitHub starsUsed in 1 repo~1.7k tokens
    Documents & OfficeAuto-check passed

More from Archive228/loopkit

All 43 skills in this repo
  • Hitl Escalate

    Archive228/loopkit

    Escalate blocked runs to a human via configured channel or fallback to BLOCKED.md and exit the loop.

    755 GitHub stars~1.2k tokensUpdated 2 mo ago
    Auto-check passed
  • Structured Output

    Archive228/loopkit

    Get JSON out of the model reliably. An agent skill from Archive228/loopkit.

    755 GitHub stars~830 tokensUpdated 2 mo ago
    Auto-check passed
  • Using Loopkit

    Archive228/loopkit

    A skill your agent uses when starting any conversation in a loopkit-enabled project - establishes how to find and use loopkit's 49 skills, requiring skill invocation before ANY response including…

    755 GitHub stars~1.4k tokensUpdated 2 mo ago
    Auto-check passed
  • Active Memory Reminder

    Archive228/loopkit

    Before compaction Loopkit extracts decisions into claude-decisions.json (machine-readable).

    755 GitHub stars~1.2k tokensUpdated 2 mo ago
    Auto-check passed
  • Eval Harness

    Archive228/loopkit

    Build a repeatable eval loop that grades agent output with an LLM judge, so prompt/skill changes get scored against a baseline instead of eyeballed.

    755 GitHub stars~876 tokensUpdated 2 mo ago
    Auto-check passed
  • Feature List JSON

    Archive228/loopkit

    Enumerate every end-to-end feature as strict JSON entries with passes:false, editable-passes-only discipline, and priority order.

    755 GitHub stars~1.2k tokensUpdated 2 mo ago
    Auto-check passed

Questions about PDF Ingestion

What does PDF Ingestion do?

Get a PDF into the model without blowing the context window or losing structure. PDF Ingestion is an agent skill from Archive228/loopkit. Get a PDF into the model without blowing the context window or losing structure.

When should I use PDF Ingestion?

PDF Ingestion fits situations like: tasks that involve PDF; tasks that involve Context engineering.

How do I install PDF Ingestion in Claude Code?

Run `npx skills add Archive228/loopkit --skill pdf-ingestion -a claude-code`. Or copy the skill folder (skills/pdf-ingestion in Archive228/loopkit) into .claude/skills/pdf-ingestion in your project. Claude Code loads it when a task matches its description.

How do I install PDF Ingestion in Codex?

Run `npx skills add Archive228/loopkit --skill pdf-ingestion -a codex`. Or copy the skill folder (skills/pdf-ingestion in Archive228/loopkit) into .agents/skills/pdf-ingestion in your project. Codex loads it when a task matches its description.

Can I use PDF Ingestion in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Archive228/loopkit --skill pdf-ingestion -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/pdf-ingestion, .gemini/skills/pdf-ingestion, .github/skills/pdf-ingestion and .opencode/skills/pdf-ingestion in your project.

What does PDF Ingestion need to run?

Going by SKILL.md and its folder, PDF Ingestion needs the command-line tools its instructions call (pdftotext).

Does PDF Ingestion access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is PDF Ingestion safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does PDF Ingestion use?

PDF Ingestion is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does PDF Ingestion use?

About 969 tokens (SKILL.md is roughly 3.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to PDF Ingestion?

Skills that share tags, products or a category with PDF Ingestion: Split PDF (scunning1975/MixtapeTools, 474 stars), Markitdown (ImCa0/just-laws, 781 stars), Gzh Design (isjiamu/gzh-design-skill, 4k stars) and GenOffice Document CLI (genspark-ai/genoffice, 9.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains PDF Ingestion?

Archive228 (a GitHub user) maintains it in Archive228/loopkit, which has 755 GitHub stars. The repository holds 43 skills in this directory. The repository was last updated on July 14, 2026.

Source: Archive228/loopkit on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.