virgiliojr94/book-to-skill
64.0
Adequate · 15 November 2026
4.9k
lines of production code
Python
primary language
5
measurements over time
What this system is
Features
Initial release of the book\_to\_skill extraction tool
Introduces the book\_to\_skill package, providing a CLI and library to extract text and metadata from books (PDF, EPUB, DOCX, HTML, etc.) into a format suitable for AI skills. Key capabilities include CJK-aware token estimation, robust chapter heading detection across multiple languages, and security hardening via sanitization of invisible Unicode code points and bidirectional controls to prevent prompt injection. The tool also features optional integration with pdf-inspector for high-confidence native PDF extraction and ensures concurrent runs use isolated work directories.
_book\_to\skill · high confidence
Introduce dedicated parsers for DOCX, EPUB, HTML, PDF, RTF, and plain text
The \book\_to\_skill/parsers\ package now provides specialized extractors for DOCX, EPUB, HTML, PDF, RTF, and plain text files. DOCX extraction includes self-defending XML safety checks to prevent XXE attacks and preserves inline tabs and breaks. EPUB extraction respects the spine reading order and resolves encoded manifest hrefs. HTML extraction uses trafilatura for robust boilerplate removal, falling back to BeautifulSoup or a stdlib parser. PDF extraction applies cleanup to pdftotext, pypdf, and pdfminer outputs, including dehyphenation and edge-of-page number removal, and aborts early on scanned PDFs. RTF extraction decodes hex-escaped text and skips metadata destination groups. Plain text reading now detects UTF-16/UTF-32 files by BOM.
_book\_to\skill/parsers · high confidence
Introduce deterministic evaluation tools for manifest generation, paper processing, and trajectory scoring
Added four new Python scripts in tools/evals to support deterministic, offline evaluation runs. manifest.py creates secret-free, reproducible run manifests by validating configuration, hashing sources, and rejecting potential secrets. paper\_flat.py splits synthetic paper sources into chunks based on chapter headings, ensuring text before the first heading is included in the first chunk. replay.py loads versioned trajectory fixtures and runs them through the scoring engine. score.py provides pure scoring logic that classifies trajectories (correct, wrong\_routing, etc.) and aggregates usage metrics, while strictly avoiding inventing counts for missing or invalid data (e.g., treating non-integer or negative values as unknown rather than estimating them).
tools/evals · high confidence
New tools for measuring context costs, scanning generated skills, and validating agent skill compatibility
Added three new command-line tools in the \tools/\ directory to improve the safety, efficiency, and compatibility of generated agent skills. \discovery\_tax.py\ quantifies the token overhead of different retrieval strategies (context-dump, discovery-loop, and book-to-skill) to help users understand context costs. \scan\_generated\_skill.py\ performs security audits on generated skills to detect prompt injection, unsafe authority, and exfiltration attempts. \validate\_skill.py\ checks \SKILL.md\ files against specific host rules (Claude, Copilot, Amp, Hermes, OpenClaw, OpenCode) to ensure compatibility and correct tool grants.
tools · high confidence
Behavioural changes
Improved search engine visibility and social sharing previews
The documentation site now generates dynamic, SEO-friendly page titles that include descriptive keywords rather than just short navigation labels, ensuring better search engine results. Additionally, all pages now share a single, consistent social media preview card (for platforms like Twitter and Facebook) that displays the correct page title and description, replacing the previous behavior which often showed generic or misleading previews.
overrides · high confidence
scripts/extract.py refactored into a backward-compatible wrapper with UTF-8 and clean-install safeguards
The standalone extraction script in scripts/extract.py has been refactored from a monolithic PDF extractor into a backward-compatible entrypoint wrapper. It now sets sys.dont\_write\bytecode=True when run directly to prevent \\pycache\\_ artifacts from polluting deployed skill directories, and forces UTF-8 encoding on stdout/stderr to avoid UnicodeEncodeError on Windows consoles. The previous inline logic for PDF extraction (pdftotext, PyPDF2, pdfminer.six), page counting, token estimation, and structure detection has been removed from this file, indicating a shift to a modular extractor package while preserving the existing CLI contract for downstream consumers.
scripts · high confidence
Test coverage
Added tests for batch resilience, chapter detection accuracy, and EPUB extraction fixes; Added tests for evaluation stability, replay, and scoring robustness.
Dependencies
Introduce pyproject.toml with dependency and tooling configuration
The project now uses a pyproject.toml file to define its build system (hatchling), project metadata, and optional dependencies for various formats (HTML, EPUB, PDF, DOCX, RTF, technical). It also configures ruff for linting and pytest for testing, ensuring local development matches CI requirements.
(dependencies) · high confidence
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 64 → 64 (+0.3)
- Rubric changed (rubric-2026.11.2 → rubric-2026.11.4) — scores are not directly comparable.
Lenses
- Code Health 74 → 69 (-5.0)
- Architecture 100 → 100 (+0.0)
- Maturity 58 → 62 (+3.9)
- Readiness 57 → 57 (+0.0)
- Security 83 → 83 (+0.0)
Resolved (8)
- Dependency hygiene PARTLY measured — Python dependencies read, no exact pin to grade for currency
- No ADRs found
- discovery_tax.main (cognitive 23) (tools/discovery_tax.py)
- scan_generated_skill._collect_skill_files (cognitive 20) (tools/scan_generated_skill.py)
- scan_generated_skill._collect_skill_files (cyclomatic 16) (tools/scan_generated_skill.py)
- scan_generated_skill._scan_text (cognitive 22) (tools/scan_generated_skill.py)
- validate_skill.audit (cognitive 44) (tools/validate_skill.py)
- validate_skill.audit (cyclomatic 28) (tools/validate_skill.py)
New (3)
- Dependency hygiene PARTLY measured — Python dependencies read, dependency currency not (the index lookup answered not published)
- No ADRs found (pyproject.toml)
- Repeated repair: book_to_skill/parsers/pdf.py (book_to_skill/parsers/pdf.py)
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
virgiliojr94/book-to-skill was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 15 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit e7bb659d3261491c8b28793dcb9102fa64a46c22 — the exact code this score is about.
- Scored under rubric-2026.11.4 — the same rubric and the same method as every other entry in this index.
- Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.73+preprod-52de90b74216.