MCP PDF Reader Enhanced logo

MCP PDF Reader Enhanced

Community
gpetraroli

An MCP server to extraxt/search text from pdf

Publishergpetraroli
Repositorymcp_pdf_reader
LanguageJavaScript
Forks
8
Stars
32
Available tools
0
Transport typestdio
Categories
Links
  • Connect tools to AI workflows

    MCP PDF Reader Enhanced exposes MCP capabilities that can be used by compatible AI clients and agents.

  • 0 available tools

    Browse the callable actions below, including names and descriptions when provided by the server.

  • Ready-to-copy setup

    Use the installation snippets to configure this server in your preferred MCP client.

  • Open source signals

    32 stars and 8 forks from the linked repository.

MCP PDF Reader Enhanced

A comprehensive Model Context Protocol (MCP) server that provides advanced PDF text extraction, search, and analysis functionality.

Features

Core Functionality

  • ✅ Text Extraction: Extract text content from PDF files with customizable options
  • ✅ Text Search: Search for specific text within PDFs with advanced options
  • ✅ Metadata Extraction: Retrieve comprehensive PDF metadata
  • ✅ Page-specific Processing: Extract content from specific page ranges
  • ✅ Text Cleaning: Normalize and clean extracted text
  • ✅ File Size Limits: Protection against overly large files (50MB limit)
  • ✅ Async Processing: Non-blocking file operations

Advanced Features

  • 🔄 Multiple Tools: 3 specialized tools for different PDF operations
  • 🔍 Smart Search: Case-sensitive, whole-word, and regex search options
  • 📊 Rich Metadata: Extract author, title, creation date, keywords, and more
  • ⚡ Performance: Efficient processing with size limits and error handling
  • 🛡️ Security: File validation and path sanitization

Installation

bash
npm install

Tools Available

1. read-pdf - Enhanced PDF Reading

Extract text from PDF files with customizable options.

Parameters:

  • file (string, required): Path to the PDF file
  • pages (string, optional): Page range (e.g., '1-5', '1,3,5', 'all'). Default: 'all'
  • include_metadata (boolean, optional): Include PDF metadata. Default: true
  • clean_text (boolean, optional): Clean and normalize text. Default: false

Example Usage:

javascript
// Basic extraction
{ "file": "/path/to/document.pdf" }

// Extract with clean text and no metadata
{ 
  "file": "/path/to/document.pdf", 
  "clean_text": true, 
  "include_metadata": false 
}

2. search-pdf - Search Within PDFs

Search for specific text within PDF documents.

Parameters:

  • file (string, required): Path to the PDF file
  • query (string, required): Text to search for
  • case_sensitive (boolean, optional): Case sensitive search. Default: false
  • whole_word (boolean, optional): Match whole words only. Default: false

Example Usage:

javascript
// Case-insensitive search
{ "file": "/path/to/document.pdf", "query": "important term" }

// Whole word, case-sensitive search
{ 
  "file": "/path/to/document.pdf", 
  "query": "API", 
  "case_sensitive": true, 
  "whole_word": true 
}

3. pdf-metadata - Extract Metadata Only

Get comprehensive metadata from PDF files without extracting text.

Parameters:

  • file (string, required): Path to the PDF file

Returns:

  • Filename, file size, page count
  • Author, title, subject, creator, producer
  • Creation/modification dates, keywords
  • Encryption status, PDF version

Configuration

Cursor Integration

Add to your Cursor settings:

json
{
  "mcpServers": {
    "mcp-gp-pdf-reader": {
      "command": "node",
      "args": ["/absolute/path/to/mcp_gp_pdf_reader/index.js"]
    }
  }
}

Future Enhancements

Planned Features

  • 🔮 OCR Support: Extract text from scanned/image-based PDFs
  • 🔮 Image Extraction: Extract images from PDF documents
  • 🔮 Table Detection: Identify and extract tabular data
  • 🔮 Form Data: Extract form fields and values
  • 🔮 Password Support: Handle password-protected PDFs
  • 🔮 Batch Processing: Process multiple PDFs simultaneously
  • 🔮 Caching: Cache parsed results for better performance
  • 🔮 Page-by-Page: True page-specific text extraction

Technical Improvements

  • 🔧 Streaming: Handle very large PDFs with streaming
  • 🔧 Progress Tracking: Progress indicators for long operations
  • 🔧 Resource Management: Better memory usage optimization
  • 🔧 Configuration API: Runtime configuration updates

Usage Examples

Basic Text Extraction

bash
# Via MCP client
"Extract all text from /documents/report.pdf"

Searching PDFs

bash
# Via MCP client  
"Search for 'quarterly results' in /documents/financial-report.pdf"

Getting Metadata

bash
# Via MCP client
"Get metadata from /documents/contract.pdf"

Development

Requirements

  • Node.js 18.0.0 or higher
  • Memory: Sufficient for PDF file size + processing overhead
  • Storage: Temporary space for file operations

Contributing

This MCP server is designed to be extensible. Key areas for contribution:

  • Additional PDF processing libraries integration
  • Performance optimizations
  • New extraction features
  • Better error handling
  • Test coverage

License

MIT License

Installation

TypingMind
{
  "mcpServers": {
    "mcp-pdf-reader": {
      "command": "node",
      "args": [
        "/absolute/path/to/mcp_gp_pdf_reader/index.js"
      ]
    }
  }
}

Use MCP PDF Reader Enhanced MCP with multiple AI models

TypingMind connects MCP tools at the workspace level, so once MCP PDF Reader Enhanced is connected, you can use it with different AI models in TypingMind instead of setting it up separately for each model. This MCP runs locally through the TypingMind MCP connector on your device.

Setup guide to use the local connector

Use this when the MCP server needs access to local files, apps, or private resources on your computer.

1

Open the MCP settings

In TypingMind, go to Settings, Advanced Settings, then Model Context Protocol and choose Setup Connector.

  1. Open TypingMind in your browser.
  2. Click the Settings icon.
  3. Go to Advanced Settings.
  4. Open the Model Context Protocol section.
  5. Click Setup Connector and choose This Device.
TypingMind MCP connector setup screen with This Device selected
2

Run the connector command

Choose This Device, copy the command from TypingMind, and run it in Terminal. Keep the process running while you use MCP.

  1. Copy the setup command shown by TypingMind.
  2. Open Terminal on macOS or Windows Terminal on Windows.
  3. Paste and run the command.
  4. Approve the package install if Terminal asks you to proceed.
  5. Keep the Terminal window running while using MCP tools.
3

Add MCP PDF Reader Enhanced as a server

When the connector status is Ready, click Edit Servers and paste the MCP server configuration.

  1. Wait until the connector status shows Ready.
  2. Click Edit Servers.
  3. Paste the MCP PDF Reader Enhanced MCP server configuration.
  4. Save the server list.
  5. Refresh if you want to confirm the connector is still ready.
TypingMind MCP settings showing active server and Edit Servers button
{
  "mcpServers": {
    "mcp-pdf-reader": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-gp-pdf-reader"
      ]
    }
  }
}
4

Use it across models

Save the server list, open Plugins, enable the MCP PDF Reader Enhanced MCP tools, then select any supported AI model in TypingMind and use the tools in chat or assign them to an AI agent.

  1. Open the Plugins page in TypingMind.
  2. Enable the MCP PDF Reader Enhanced MCP tools.
  3. Start a chat and choose the AI model you want to use.
  4. Use the MCP tools in chat or assign them to an AI agent.
  5. Switch to another AI model whenever needed without reconnecting MCP.
TypingMind chat using enabled MCP tools with a selected AI model
Can you use MCP PDF Reader Enhanced to help me with this task?
MCP PDF Reader Enhanced
Sure. I read it.
Here is what I found using MCP PDF Reader Enhanced.

Frequently asked questions

What is the MCP PDF Reader Enhanced MCP server used for?

MCP PDF Reader Enhanced is an MCP server that lets compatible AI clients connect to external tools and context. In TypingMind, you can add this MCP server once and make its tools available in your AI workspace.

Can I use MCP PDF Reader Enhanced MCP with multiple AI models in TypingMind?

Yes. TypingMind connects MCP tools at the workspace level, so you can use MCP PDF Reader Enhanced with different AI models such as Claude, ChatGPT, Gemini, or other models you have configured in TypingMind without setting up the MCP server separately for each model.

Why use MCP PDF Reader Enhanced MCP with TypingMind?

TypingMind is one of the best frontends for LLM chat because it brings multiple AI models, prompts, plugins, AI agents, API keys, and MCP tools into one workspace. With MCP PDF Reader Enhanced connected, you can use its MCP tools across your preferred models while keeping your chat workflow organized in TypingMind.

How do I connect MCP PDF Reader Enhanced MCP to TypingMind?

MCP PDF Reader Enhanced runs through the TypingMind local MCP connector. This is best when the MCP server needs access to local files, desktop apps, command-line tools, or private resources on your computer.

What tools does MCP PDF Reader Enhanced MCP provide in TypingMind?

MCP PDF Reader Enhanced exposes MCP capabilities that can be enabled from the TypingMind Plugins page and used in chat or assigned to AI agents.

Do I need to share my API keys with TypingMind to use MCP PDF Reader Enhanced MCP?

No. TypingMind is local-first and lets you keep your model providers, API keys, prompts, and MCP configuration under your control. If MCP PDF Reader Enhanced requires authentication, add the required headers, OAuth settings, or local configuration for that MCP server when you create the connection.

Related MCP Servers

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇