Get the FREE Ultimate OpenClaw Setup Guide →

mcp -readbooks

MCP server from unclevicky/mcp-server-readbooks

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio unclevicky-mcp-server-readbooks python readbooks_server.py \
  --env PYTHONUNBUFFERED="1"

How to use

This MCP server provides a multi-format e-book parsing service. It supports parsing PDFs, EPUBs, Word documents, MOBI, TXT, and CHM formats, and can perform OCR on scanned PDFs to extract text. The server is implemented in Python and exposes a readbooks_server entry point that coordinates the parsing workflows via components such as the ebook_parser and the OCR engine. To use it, install the required Python dependencies, start the server, and send requests to the API endpoints exposed by readbooks_server.py (the README references a test suite to verify configuration and operation). If OCR is needed, ensure an OCR engine is properly configured and accessible by the server so scanned PDFs can be processed with text recognition in addition to standard parsing.

Once running, you can use the server to convert input documents into a structured, accessible representation (e.g., extracted text, metadata, and possibly converted formats). The included modules suggest support for caching, file conversion, and multiple parser backends, enabling flexible handling of a variety of input formats and use cases such as full-text extraction, format normalization, and OCR-assisted text retrieval.

How to install

Prerequisites:

  • Python 3.8+ installed on your system
  • Access to the project repository containing readbooks_server.py and requirements.txt
  • Optional: Tesseract OCR (or another OCR engine) if you intend to OCR scanned PDFs

Installation steps:

  1. Clone the repository: git clone <repository-url> cd <repository-dir>

  2. Create and activate a virtual environment (recommended): python -m venv venv

    On Windows

    venv\Scripts\activate

    On macOS/Linux

    source venv/bin/activate

  3. Install Python dependencies: pip install -r requirements.txt

  4. (Optional) Install and configure OCR dependencies if you plan to OCR documents. For Tesseract:

    • On macOS: brew install tesseract
    • On Ubuntu/Debian: sudo apt-get install tesseract-ocr
    • On Windows: install from the official Tesseract installer and ensure the tesseract executable is in your PATH
  5. Run the MCP server: python readbooks_server.py

  6. Verify the server is running and accessible, for example by running the provided tests or sending a basic request to the server's endpoints as described in the repository's test suite (test/test_server.py).

Notes:

  • The project relies on requirements.txt for dependencies; ensure your environment can install them without network restrictions.
  • If your environment requires specific environment variables (e.g., OCR engine paths, cache settings), configure them before starting the server.

Additional notes

Tips and common issues:

  • Ensure Python and pip are up to date. Use a virtual environment to avoid dependency conflicts.
  • If OCR is enabled, verify that the OCR engine (e.g., Tesseract) is correctly installed and accessible from the system PATH.
  • Check for required environment configurations such as cache directories or any external service endpoints used by the ebook_parser or cache_manager.
  • The repository includes a test suite (test/test_server.py); running tests can help validate configuration and basic operation before deploying.
  • If you encounter parsing failures on certain formats, confirm that the corresponding parser modules (PDF, EPUB, Word, MOBI, TXT, CHM) are properly installed and that any optional dependencies (e.g., for Word or CHM formats) are present.

Related MCP Servers

Sponsor this space

Reach thousands of developers