AI news and explainers at 7 AM weekdays, plus a Sunday weekly at 8Get it in your inbox

METAL LAB

Turning Technical Book PDFs Into AI Skills Cuts Token Use Up to 51x

book-to-skill is an open-source converter for Claude Code, Copilot CLI, and Amp

이미지: METAL LAB 생성

Summary

  • Developer virgiliojr94 has released book-to-skill, an open-source tool that turns technical book PDFs or folders of documents into skills that AI agents can use.
  • According to the developer's own measurements, it can answer the same questions using 24 to 51 times fewer tokens than loading the entire book into context.
  • It runs on the open Agent Skills standard (SKILL.md) shared by GitHub Copilot CLI, Amp, and Claude Code.
저장소
github.com/virgiliojr94/book-to-skill
제작자
virgiliojr94
라이선스
MIT (변환기 코드·스킬 정의에만 적용, 처리 대상 문서에는 미적용)
호환 호스트
GitHub Copilot CLI, Amp, Claude Code
토큰 절감
실제 책 기준 24배~51배 (책 전체를 컨텍스트에 넣는 방식 대비)
기본 명령
/book-to-skill <경로|폴더|글롭> [스킬이름]
표준 문서
SKILL.md (오픈 Agent Skills 포맷)

Instead of reopening a book you already bought, you just ask

You buy a thick technical book, read it once, and three months later you can barely remember what was in chapter 7. Rather than flipping back through the table of contents every time that happens, a new open-source tool lets you hand the entire book over to an AI agent and just ask it questions whenever you need to. It's posted at the virgiliojr94/book-to-skill repository. Built by developer virgiliojr94, book-to-skill is a converter that turns a technical book PDF, a folder of documents, or a bundle of reference materials into a single "agent skill."

The original thick PDF gets converted and split into chapter files. When a question comes in, only the relevant chapter is loaded. The final node sits small inside a large dashed border labeled "entire book," showing that actual usage is tiny compared to the full source.

Why you shouldn't just dump the PDF in

When you feed an AI agent an entire PDF, it ends up re-scanning the table of contents and re-locating the relevant section on every single turn. Answering one question means reprocessing tokens for the whole book, over and over. book-to-skill is designed to pay that structuring cost only once, at conversion time. The book gets split and saved as chapter-level files, and the agent only loads the relevant chapter when you actually ask about that topic. According to the developer, this means answering the same question takes 24 to 51 times fewer tokens than loading the full book into context.

How it works

The architecture splits into two parts. One is a deterministic Python extractor that converts the document into clean text and metadata. The other is a spec-driven generator, where the agent follows a SKILL.md document to assemble that text into a structured skill. Because this skill runs on the open Agent Skills standard shared by GitHub Copilot CLI, Amp, and Claude Code, all three hosts read the same SKILL.md format regardless of which one you use.

The tool also automatically picks different extraction engines depending on the format — Docling for technical books heavy with tables and code blocks, and the faster pdftotext for prose-heavy books. For scanned PDFs that are just page images with no extractable text, there's nothing to pull out in the first place, so the converter checks the opening pages, stops right there, and explains why. Rather than silently producing an empty skill, it tells you to run OCR first.

How to try it

Where to start — If you're already using GitHub Copilot CLI, Amp, or Claude Code, the repository's install docs (docs/install.md) walk you through attaching the book-to-skill converter to your host.

Step-by-step usage

  1. In your agent's chat window, run /book-to-skill <file path|folder|glob> [skill name]. You can pass a single file, an entire folder, or a list of multiple files.
  2. The converter detects the document format and automatically picks the right extraction engine to pull out text and metadata.
  3. The generator assembles the results into a SKILL.md file plus per-chapter files, saved into the skill directory appropriate for your host.
  4. From then on, ask /book-slug your question, and the agent will load only the chapter files it needs and answer based on the actual source text.

Who can use it — Any host that supports the open Agent Skills standard, including GitHub Copilot CLI, Amp, and Claude Code, and it's free under the MIT license. That said, the book content itself isn't included in the repository — you convert files you already own — so copyright and terms-of-use responsibility stays with the user.

HostSkill storage path
GitHub Copilot CLI~/.copilot/skills/<slug>/
Amp (cross-agent)~/.agents/skills/<slug>/
Claude Code~/.claude/skills/<slug>/

What you can do with it — Despite the name, the developer says any structured prose input works, not just books. Internal manuals, policy documents, or team documentation bundles you keep reopening can be turned into skills the same way. One example noted in the repository: a book on developer experience (DevEx) was converted and used to reference survey data from over 300 engineers.

Editor's view

What's interesting here isn't book-to-skill itself — it's the standard it's built on. As we covered in early August in GitHub Copilot's app now supports slash commands to shortcut workflows, Copilot's app is moving toward automatically managing context. And as we saw in AWS brings open-source Agent Skills to Bedrock's automated reasoning policies, Anthropic's proposed Agent Skills format is expanding in the other direction, pulling in infrastructure players like AWS. book-to-skill sits right at the intersection of those two trends — a single book's worth of personal knowledge now gets packaged using the same SKILL.md syntax as enterprise-grade skills.

Anyone who's actually tried this kind of tool knows the pattern. Dumping a whole PDF into context feels convenient for the first few exchanges, but the cost of re-scanning the same table of contents piles up as the conversation goes on. Splitting things into chapters that load on demand eliminates that accumulating cost, but it asks for an upfront conversion step in return. For teams that need to watch token spend, a reasonable starting point is converting the internal documents you reference most often. For a document you might check once in a blue moon, converting it probably isn't worth the trouble.

The design choice to flag scanned PDFs upfront and explain why is also worth noting. Stopping before conversion beats discovering an empty, useless skill later — that's real time saved in practice. As more hosts adopt the Agent Skills standard, we'd expect personal conversion tools like this one to keep showing up.

Code from this story

Comments