← Back to Skills Marketplace
inf-lucas

EPUB Read

by INF-Lucas · GitHub ↗ · v2.0.0 · MIT-0
linuxdarwinwin32 ✓ Security Clean
200
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install epub-read
Description
Task-mode-driven EPUB reading and analysis skill with overview, targeted reading, chunked full reading, extraction, complex-content inspection, and batch pro...
README (SKILL.md)

\x3Cobjective> Provide a strict, auditable EPUB workflow that safely handles long books through explicit task routing instead of loading full-book text by default. \x3C/objective>

\x3Cuse_when>

  • The user mentions an .epub file or ebook
  • The user wants a quick structural overview
  • The user wants chapter-specific or chunk-specific reading
  • The user wants full-book sequential reading with chunking
  • The user wants structured extraction
  • The user wants to inspect images, tables, or other complex content
  • The user wants to batch-process multiple EPUB files \x3C/use_when>

\x3Cprocess>

STEP 0 - Choose exactly one task mode before doing anything else

Mode Purpose Use when
overview Fast structural overview Metadata, TOC, themes, structure only
targeted_read Focused reading Specific chapters, chunk ranges, or keyword hits
full_read Sequential reading Long-book chunked reading with saved progress
extract Structured extraction Keywords, definitions, quotes, examples, action items, entities, tables, lists
complex_content Complex-layout inspection Images, tables, SVG, low-text sections
batch Multi-book planning Multiple EPUB files or folders

Default to overview or targeted_read when the user intent is ambiguous. Never load a long book's full body text by default.

STEP 1 - Parse if needed

  1. Check whether the output directory already exists and contains manifest.json.
  2. If not, run parse_epub.py.
  3. After parsing, report:
    • title
    • author
    • chapter count
    • chunk count if available
    • image count
    • table count
    • output directory

STEP 2 - Build an execution plan

Use task_router.py to decide whether parsing, chunking, or state updates are required:

python3 task_router.py \x3Cbook_dir> --mode \x3Cmode> [params...]

The plan should tell you:

  • whether parsing is required
  • whether chunking is required
  • which files are recommended to read
  • whether session state must be updated

STEP 3 - Mode-specific behavior

overview

  • Read only metadata, TOC, reading index, and other structural outputs
  • Do not load the whole book body by default
  • Return:
    • title
    • author
    • chapter count
    • TOC structure
    • theme overview
    • suggested next actions

targeted_read

Support:

  • --chapter
  • --chapter-id
  • --chunk-start
  • --chunk-end
  • --keyword

Return:

  • the requested section
  • short context
  • concise summary

full_read

  • Prefer chunk-based reading for long books
  • Support continue, previous, next, and jump flows
  • Always update session_state.json
  • Never pretend progress exists if the session state is missing

extract

Support extracting:

  • keywords
  • definitions
  • quotes
  • examples
  • action_items
  • names
  • locations
  • organizations
  • tables
  • lists

Return a hit list with chapter references and short context.

complex_content

Inspect:

  • images
  • SVG
  • tables
  • image-heavy sections
  • low-text / high-resource sections

Return a structured report. OCR is not required by default.

batch

Support:

  • multiple EPUB file paths
  • directory scanning
  • batch planning
  • batch extraction requests

Return success / failure counts and a concise overview.

STEP 4 - Long-book safety rules

  • Never push the full body of a long book into context at once
  • Prefer chunks/ over chapter markdown for full sequential reading
  • When chunking is required, run chunk_book.py first
  • Use reading_index.json to map chapters to chunk ranges

STEP 5 - State management rules

When running full_read or any progress-sensitive flow:

  1. Read session_state.json first
  2. Update it after every progress-changing action
  3. Respect existing saved progress unless the user explicitly asks to restart

STEP 6 - Output style

Be explicit about:

  • what files were used
  • what mode was selected
  • why a long book was chunked instead of loaded fully
  • what the user can do next

When possible, point the user toward the safest next step:

  • continue reading
  • jump to a chapter
  • inspect a chunk range
  • extract a structure
  • review complex content

\x3C/process>

\x3Cvalidation>

Before considering the task complete, check:

  • parsing outputs exist
  • chunk files exist when required
  • reading index and session state are coherent
  • extraction targets match the requested type
  • complex-content reports are generated from real parsed outputs

\x3C/validation>

Usage Guidance
This skill appears coherent and safe for EPUB processing: it runs local Python scripts, writes output under a dedicated book directory, and does not request secrets or make network calls. Before installing: (1) install its Python dependencies in an isolated venv (pip install -r requirements.txt), (2) run test_integration.py with a non-sensitive local EPUB to confirm behavior, and (3) only run it on EPUB files you trust (it will write parsed content and state files to disk). If you want extra assurance, review the omitted truncated files (remaining parse/chunk logic) or run the scripts in a sandbox/container.
Capability Analysis
Type: OpenClaw Skill Name: epub-read Version: 2.0.0 The epub-read skill bundle is a well-structured tool designed for parsing, chunking, and analyzing EPUB files. It implements a multi-mode workflow (overview, targeted_read, full_read, etc.) to handle large ebooks efficiently without exceeding AI context limits. The Python scripts (parse_epub.py, chunk_book.py, task_router.py) use standard libraries and BeautifulSoup for HTML processing, and no evidence of data exfiltration, unauthorized network access, or malicious prompt injection was found. The use of subprocess.run in test_integration.py is limited to executing local scripts for validation purposes.
Capability Assessment
Purpose & Capability
Name/description (EPUB reading, chunking, extraction) match the included scripts (parse_epub.py, chunk_book.py, task_router.py, update_session_state.py, utils.py). Requested binary is python3 which is appropriate; no unrelated binaries or secrets are required.
Instruction Scope
SKILL.md instructs the agent to parse, chunk, route tasks, and manage session state using the included Python scripts and to read/write files under the book output directory. The instructions do not attempt to read system-wide config, environment secrets, or transmit data to external endpoints. All file reads/writes are confined to the parsed-book output tree.
Install Mechanism
There is no install spec (no automatic downloads), which is low risk. The repository includes a requirements.txt (beautifulsoup4, lxml) so the user must install Python dependencies manually or via pip. No external installers, URL downloads, or extracted archives are used by the skill.
Credentials
The skill declares no required environment variables or credentials and the code does not reference environment secrets. All required resources are local files and Python packages, which is proportionate to the stated functionality.
Persistence & Privilege
always is false and the skill does not modify other skills or global agent settings. It writes/reads session_state.json and various parse artifacts inside the book output directory, which is expected for a reading-progress feature.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install epub-read
  3. After installation, invoke the skill by name or use /epub-read
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v2.0.0
epub-read 2.0.0 is a major update introducing task-mode-driven EPUB processing for safer and more flexible ebook analysis. - Adds explicit task selection (overview, targeted_read, full_read, extract, complex_content, batch) before any book loading. - Greatly improves safety for long books by never loading full-body text by default; uses chunked reading strategies. - Supports detailed structural overview, targeted or chunked reading, structured extraction, and complex content reporting. - Enables batch processing of multiple EPUBs or folders. - Enforces strict state and progress management for seamless sequential reading. - Includes clear, structured output and next-action suggestions for every task mode.
Metadata
Slug epub-read
Version 2.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is EPUB Read?

Task-mode-driven EPUB reading and analysis skill with overview, targeted reading, chunked full reading, extraction, complex-content inspection, and batch pro... It is an AI Agent Skill for Claude Code / OpenClaw, with 200 downloads so far.

How do I install EPUB Read?

Run "/install epub-read" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is EPUB Read free?

Yes, EPUB Read is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does EPUB Read support?

EPUB Read is cross-platform and runs anywhere OpenClaw / Claude Code is available (linux, darwin, win32).

Who created EPUB Read?

It is built and maintained by INF-Lucas (@inf-lucas); the current version is v2.0.0.

💬 Comments