Skip to main content
Glama
lihongwen

PDF Reader MCP Server

by lihongwen

PDF Reader MCP Server

An MCP (Model Context Protocol) server that provides comprehensive PDF processing capabilities with 18 powerful tools for text extraction, OCR, image conversion, metadata management, and optimization.

🚀 Latest Updates

  • ✅ All 18 tools fully tested and working (September 2025)

  • 🔧 Fixed JSON serialization issues - 100% compatibility achieved

  • ⚡ Enhanced performance with intelligent caching system

  • 🌍 Multi-language OCR support with Chinese and English optimization

Related MCP server: PDF Reader MCP Server

Features

📖 Smart Text Extraction

  • Intelligent PDF parsing with pdfplumber for high-quality text extraction

  • Automatic quality detection to identify when OCR is needed

  • Page-wise processing with flexible page range syntax

🔍 Advanced OCR Support

  • Tesseract integration for scanned documents and image-based PDFs

  • Multi-language support with focus on Chinese and English

  • Confidence scoring for OCR quality assessment

  • Windows-friendly installation and setup

⚡ Performance Optimized

  • Smart caching system to avoid reprocessing unchanged files

  • Chunking strategies for handling large documents

  • Parallel page processing for improved performance

🎯 Flexible Page Selection

Support for complex page ranges:

  • "1,3,5" - Specific pages

  • "1-10" - Page ranges

  • "-1" - Last page

  • "1,3,5-10,-1" - Combined syntax

Installation

Install and run with uvx (easiest method):

# Install and run directly with uvx (no setup required)
uvx pdfmcp-tools

# Or install globally for repeated use
uv tool install pdfmcp-tools
pdfmcp-tools

Install from PyPI with pip:

# Install from PyPI
pip install pdfmcp-tools

# Run the server (both commands work)
pdfmcp-tools
# or
pdfreadermcp

Prerequisites

  • Python 3.11+ (automatically handled by uvx/pip)

  • Tesseract OCR engine (for OCR functionality)

Install Tesseract OCR Engine

macOS:

# Using Homebrew (recommended)
brew install tesseract tesseract-lang

Linux (Ubuntu/Debian):

sudo apt update
sudo apt install tesseract-ocr tesseract-ocr-chi-sim tesseract-ocr-chi-tra

Windows:

  1. Download from: https://github.com/UB-Mannheim/tesseract/wiki

  2. Install the latest version (recommended: tesseract-ocr-w64-setup-v5.3.3.20231005.exe)

  3. During installation, select "Additional Language Data" and install Chinese language packs

  4. Add Tesseract to your PATH, or note the installation path for configuration

Development Installation (Advanced)

For development or local modification:

  1. Install uv package manager (if not already installed):

    macOS/Linux:

    curl -LsSf https://astral.sh/uv/install.sh | sh

    Windows:

    powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
  2. Clone and install for development:

    git clone https://github.com/lihongwen/pdfreadermcp.git
    cd pdfreadermcp
    uv sync --dev
    uv run pdfreadermcp

Usage

🚀 Running the Server

With uvx (recommended):

# Run directly (auto-downloads and starts)
uvx pdfreadermcp

# Or if globally installed
pdfreadermcp

With pip installation:

# After pip install pdfreadermcp
pdfreadermcp

Development mode:

# In project directory
uv run pdfreadermcp

Integration with Claude Desktop

Add to your Claude Desktop MCP configuration file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%\Claude\claude_desktop_config.json

Option 1: Using uvx (recommended):

{
  "mcpServers": {
    "pdfreadermcp": {
      "command": "uvx",
      "args": ["pdfmcp-tools"]
    }
  }
}

Option 2: Using global installation:

{
  "mcpServers": {
    "pdfreadermcp": {
      "command": "pdfmcp-tools"
    }
  }
}

Option 3: Development/local installation:

{
  "mcpServers": {
    "pdfreadermcp": {
      "command": "uv",
      "args": [
        "--directory",
        "/path/to/your/pdfreadermcp",
        "run",
        "pdfreadermcp"
      ]
    }
  }
}

📚 Complete Tool Suite (18 Tools)

All tools have been thoroughly tested and are fully functional. The server provides comprehensive PDF processing capabilities across multiple categories:

📖 Text Processing Tools (5 tools)

  • read_pdf - Intelligent text extraction with chunking

  • extract_page_text - Single page text extraction with multiple modes

  • search_pdf_text - Advanced text search with regex and context support

  • find_and_highlight_text - Text search with highlighting coordinates

  • get_pdf_metadata - Comprehensive metadata reading with XMP support

📄 Document Operations Tools (5 tools)

  • split_pdf - Split PDFs into multiple files by page ranges

  • extract_pages - Extract specific pages to new PDF file

  • merge_pdfs - Combine multiple PDFs into single document

  • set_pdf_metadata - Write/update PDF metadata fields

  • remove_pdf_metadata - Remove specific or all metadata fields

🖼️ Image Conversion Tools (3 tools)

  • pdf_to_images - Convert PDF pages to high-quality images

  • images_to_pdf - Convert multiple images to single PDF

  • extract_pdf_images - Extract embedded images from PDF pages

🔍 OCR Tool (1 tool)

  • ocr_pdf - Advanced OCR with multi-language support and confidence scoring

⚡ Optimization Tools (4 tools)

  • optimize_pdf - Comprehensive PDF optimization with multiple levels

  • compress_pdf_images - Image compression within PDF documents

  • remove_pdf_content - Remove specific content to reduce file size

  • analyze_pdf_size - File size analysis and optimization recommendations

Tools

read_pdf - Text Extraction Tool

Extracts text from PDF files with intelligent processing.

Parameters:

  • file_path (required): Path to PDF file

  • pages (optional): Page range string (e.g., "1,3,5-10,-1")

  • chunk_size (optional): Maximum chunk size (default: 1000)

  • chunk_overlap (optional): Chunk overlap (default: 100)

Example:

Extract text from document.pdf, pages 1-5 and last page

ocr_pdf - OCR Recognition Tool

Performs OCR on PDF pages using Tesseract for scanned documents and image-based PDFs.

Parameters:

  • file_path (required): Path to PDF file

  • pages (optional): Page range string (e.g., "1,3,5-10,-1")

  • language (optional): OCR language code (default: "chi_sim" for Chinese)

  • chunk_size (optional): Maximum chunk size (default: 1000)

  • chunk_overlap (optional): Chunk overlap (default: 100)

  • dpi (optional): DPI for PDF to image conversion (default: 200)

Supported Languages:

  • chi_sim: Simplified Chinese (默认)

  • chi_tra: Traditional Chinese

  • eng: English

  • chi_sim+eng: Chinese and English mixed

Example:

Perform OCR on scanned_doc.pdf with Chinese text recognition

split_pdf - PDF Splitting Tool

Split PDF into multiple files based on page ranges.

Parameters:

  • file_path (required): Path to source PDF file

  • split_ranges (required): List of page ranges (e.g., ["1-5", "6-10", "11-15"])

  • output_dir (optional): Output directory (defaults to source file directory)

  • prefix (optional): Output file prefix (defaults to source filename)

Example:

Split document.pdf into multiple files: pages 1-10, 11-20, 21-30

extract_pages - Page Extraction Tool

Extract specific pages from PDF to a new file.

Parameters:

  • file_path (required): Path to source PDF file

  • pages (required): Page range (e.g., "1,3,5-7")

  • output_file (optional): Output filename (auto-generated if not provided)

  • output_dir (optional): Output directory (defaults to source file directory)

Example:

Extract pages 1, 5-8, and 15 from document.pdf

merge_pdfs - PDF Merging Tool

Merge multiple PDF files into a single file.

Parameters:

  • file_paths (required): List of PDF file paths to merge

  • output_file (optional): Output filename (auto-generated if not provided)

  • output_dir (optional): Output directory (defaults to first file's directory)

Example:

Merge file1.pdf, file2.pdf, and file3.pdf into a single document

pdf_to_images - PDF to Images Converter

Convert PDF pages to high-quality images using pdf2image.

Parameters:

  • file_path (required): Path to PDF file

  • pages (optional): Page range (e.g., "1,3,5-10,-1")

  • dpi (optional): Resolution for conversion (default: 200)

  • image_format (optional): Output format ('PNG', 'JPEG', etc.)

  • output_dir (optional): Directory to save images

  • save_to_disk (optional): Save to disk or keep in memory (default: True)

Example:

Convert first 5 pages of document.pdf to PNG images at 300 DPI

images_to_pdf - Images to PDF Converter

Convert multiple images into a single PDF document.

Parameters:

  • image_paths (required): List of image file paths

  • output_file (required): Output PDF file path

  • page_size (optional): Page size ('A4', 'Letter', 'Legal', 'auto')

  • quality (optional): JPEG compression quality (1-100, default: 95)

  • title (optional): PDF document title

  • author (optional): PDF document author

Example:

Convert scan1.jpg, scan2.jpg, scan3.jpg to a single PDF with A4 pages

extract_pdf_images - PDF Image Extractor

Extract all embedded images from PDF pages.

Parameters:

  • file_path (required): Path to PDF file

  • pages (optional): Page range (e.g., "1,3,5-10,-1")

  • min_size (optional): Minimum image size ("WIDTHxHEIGHT", default: "100x100")

  • output_dir (optional): Directory to save extracted images

Example:

Extract all images larger than 200x200 pixels from PDF pages 1-10

get_pdf_metadata - PDF Metadata Reader

Read comprehensive metadata information from PDF documents.

Parameters:

  • file_path (required): Path to PDF file

  • include_xmp (optional): Include advanced XMP metadata (default: False)

Example:

Read all metadata from document.pdf including title, author, creation date

set_pdf_metadata - PDF Metadata Writer

Write or update PDF metadata fields.

Parameters:

  • file_path (required): Path to source PDF file

  • output_file (optional): Output PDF file path

  • title (optional): Document title

  • author (optional): Document author

  • subject (optional): Document subject

  • creator (optional): Creator application name

  • producer (optional): Producer application name

  • keywords (optional): Keywords or tags

  • preserve_existing (optional): Preserve existing metadata (default: True)

Example:

Set metadata for report.pdf with title "Annual Report 2024" and author "John Doe"

remove_pdf_metadata - PDF Metadata Remover

Remove specific metadata fields or all metadata from PDF.

Parameters:

  • file_path (required): Path to source PDF file

  • output_file (optional): Output PDF file path

  • fields_to_remove (optional): List of specific fields to remove

  • remove_all (optional): Remove all metadata (default: False)

Example:

Remove author and title metadata from sensitive_document.pdf

search_pdf_text - PDF Text Search Engine

Search for text content across PDF pages with detailed match information.

Parameters:

  • file_path (required): Path to PDF file

  • query (required): Text to search for (or regex pattern)

  • pages (optional): Page range (e.g., "1,3,5-10,-1")

  • case_sensitive (optional): Case-sensitive search (default: False)

  • regex_search (optional): Treat query as regex pattern (default: False)

  • context_chars (optional): Context characters around matches (default: 100)

  • max_matches (optional): Maximum matches to return (default: 100)

Example:

Search for "financial report" in document.pdf with case-insensitive matching

extract_page_text - Single Page Text Extractor

Extract text from a specific PDF page with various extraction options.

Parameters:

  • file_path (required): Path to PDF file

  • page_number (required): Page number to extract (1-based)

  • extraction_mode (optional): Extraction mode ("default", "layout", "simple")

Example:

Extract text from page 5 of document.pdf with layout preservation

find_and_highlight_text - Text Highlighting Tool

Find text and return information for highlighting matches.

Parameters:

  • file_path (required): Path to PDF file

  • query (required): Text to search for

  • pages (optional): Page range (e.g., "1,3,5-10,-1")

  • case_sensitive (optional): Case-sensitive search (default: False)

Example:

Find all instances of "important" in document.pdf for highlighting

optimize_pdf - PDF Optimization Tool

Optimize PDF file using various compression techniques.

Parameters:

  • file_path (required): Path to source PDF file

  • output_file (optional): Output PDF file path

  • optimization_level (optional): Optimization preset ("light", "medium", "heavy", "maximum")

Example:

Optimize large_document.pdf using medium compression level

compress_pdf_images - PDF Image Compression

Compress images in PDF while preserving document structure.

Parameters:

  • file_path (required): Path to source PDF file

  • output_file (optional): Output PDF file path

  • quality (optional): Image compression quality (1-100, default: 80)

Example:

Compress images in photo_heavy.pdf to 60% quality

remove_pdf_content - PDF Content Remover

Remove specific content from PDF to reduce file size.

Parameters:

  • file_path (required): Path to source PDF file

  • output_file (optional): Output PDF file path

  • remove_images (optional): Remove all images (default: False)

  • remove_annotations (optional): Remove annotations (default: False)

  • compress_streams (optional): Compress content streams (default: True)

Example:

Remove all images and annotations from document.pdf to reduce size

analyze_pdf_size - PDF Size Analysis Tool

Analyze PDF file to identify optimization opportunities.

Parameters:

  • file_path (required): Path to PDF file to analyze

Example:

Analyze large_file.pdf to get optimization recommendations

Output Format

All tools return structured JSON containing relevant data. Text extraction and OCR tools return:

{
  "success": true,
  "file_path": "/path/to/file.pdf",
  "total_pages": 10,
  "processed_pages": [1, 2, 3],
  "chunks": [
    {
      "content": "Extracted text...",
      "page_number": 1,
      "chunk_index": 0,
      "metadata": {
        "quality_score": 0.95,
        "word_count": 150
      }
    }
  ],
  "summary": {
    "total_chunks": 5,
    "total_chars": 2500,
    "pages": [1, 2, 3]
  },
  "extraction_method": "text_extraction"
}

Language Support

OCR Languages

The ocr_pdf tool supports multiple languages via Tesseract:

  • Chinese: chi_sim (Simplified), chi_tra (Traditional)

  • English: eng

  • Combined: chi_sim+eng (mixed Chinese and English)

  • Others: Available based on your Tesseract installation

Performance Features

Caching System

  • File-based invalidation - Cache automatically invalidates when files change

  • Operation-specific caching - Different cache entries for different operations

  • Memory management - Configurable cache size and TTL

Text Quality Analysis

The system automatically analyzes extracted text quality using:

  • Character-to-word ratios

  • Sentence structure analysis

  • Letter-to-character ratios

  • Special character detection

Low-quality text triggers OCR recommendations.

Chunking Strategy

  • Recursive character splitting with semantic separators

  • Configurable overlap to preserve context

  • Metadata preservation including page numbers and positions

Error Handling

The server provides detailed error information:

  • Missing file errors

  • Invalid page range errors

  • OCR engine initialization errors

  • Processing timeout errors

Development

Project Structure

pdfreadermcp/
 pyproject.toml              # uv project configuration
 README.md
 src/pdfreadermcp/
     __init__.py
     __main__.py             # Entry point
     server.py               # MCP server implementation
     tools/
        pdf_reader.py       # Text extraction tool
        pdf_ocr.py          # OCR processing tool
          pdf_operations.py   # PDF splitting, merging, extraction
          pdf_image_converter.py  # PDF-image conversion tools
          pdf_metadata.py         # PDF metadata management
          pdf_text_search.py      # PDF text search and highlighting
          pdf_optimizer.py        # PDF compression and optimization
     utils/
         chunker.py          # Text chunking utilities
         cache.py            # Caching system
         file_handler.py     # File operations

Running Tests

# Install with dev dependencies
uv sync --dev

# Run tests (when available)
uv run pytest

Dependencies

Core Dependencies

  • mcp - Model Context Protocol server framework

  • pypdf - PDF text extraction and manipulation

  • pdf2image - PDF to image conversion

  • pytesseract - Python wrapper for Tesseract OCR

  • tesseract - OCR engine

  • pillow - Image processing and manipulation

System Requirements

  • For OCR: Tesseract OCR engine must be installed

  • For PDF conversion: poppler-utils may be required on some systems

Troubleshooting

Common Issues

1. Tesseract OCR Installation Issues

If Tesseract is not found, you may see errors like "TesseractNotFoundError". Solutions:

Windows:

  • Ensure Tesseract is installed and added to PATH

  • Or set the path manually in your environment:

import pytesseract
pytesseract.pytesseract.tesseract_cmd = r'C:\Program Files\Tesseract-OCR\tesseract.exe'

macOS/Linux:

  • Install via package manager: brew install tesseract (macOS) or apt install tesseract-ocr (Ubuntu)

  • Make sure Chinese language packs are installed

2. pdf2image Dependencies On Linux, you may need to install poppler:

# Ubuntu/Debian
sudo apt-get install poppler-utils

# CentOS/RHEL  
sudo yum install poppler-utils

3. Chinese Language Pack Issues

If OCR fails for Chinese text or produces poor results:

  • Windows: During Tesseract installation, select "Additional Language Data" and install Chinese packs

  • macOS: brew install tesseract-lang

  • Linux: sudo apt install tesseract-ocr-chi-sim tesseract-ocr-chi-tra

Verify language packs are installed:

tesseract --list-langs

4. Memory Issues with Large PDFs

  • Reduce chunk_size parameter

  • Process pages in smaller ranges

  • Ensure sufficient system memory

  • Lower dpi parameter for faster processing

Performance Tips

  1. Use caching - The same file with same parameters will use cached results

  2. Process specific pages - Use page ranges instead of processing entire documents

  3. Adjust chunk sizes - Smaller chunks for memory-constrained environments

  4. Choose appropriate tools - Use read_pdf first, then ocr_pdf if needed

  5. OCR optimization:

    • Lower dpi (150-200) for faster processing

    • Use chi_sim only if document is purely Chinese

    • Process problematic pages only, not entire document

🧪 Testing & Quality Assurance

This project has been thoroughly tested with comprehensive test coverage:

  • ✅ 18/18 tools fully functional (100% success rate)

  • 🔧 All JSON serialization issues resolved

  • 📋 Extensive testing with real PDF documents

  • ⚡ Performance validation with caching system

  • 🌍 Multi-language OCR testing (Chinese/English)

License

This project is licensed under the MIT License.

Contributing

Contributions are welcome! Please feel free to submit issues and enhancement requests.

Support

For questions and support:

Available Tools

18 tools
analyze_pdf_sizeA

Analyze PDF file to identify optimization opportunities.

Provides detailed size breakdown by content type (text, images, metadata, etc.)
and recommends specific optimization strategies for file size reduction.

Args:
    file_path: Path to PDF file to analyze
    
Returns:
    JSON string with size analysis breakdown and optimization recommendations
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A3.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, and the description does not explicitly state that the tool is read-only or disclose any side effects. It focuses on output but omits behavioral traits like file existence requirements or performance implications.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Description is four sentences with front-loaded purpose. No redundant information; each sentence adds value.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the single parameter and presence of an output schema, the description adequately explains the tool's input (file path) and output (JSON string with breakdown and recommendations). Minor gap: no mention of error handling for missing files.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, and the description adds 'Path to PDF file to analyze' which clarifies the parameter's purpose beyond the schema's string type. However, for a single parameter, the description is minimal and does not specify format or validation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states 'analyze PDF file to identify optimization opportunities' and details the breakdown by content type. It distinguishes from sibling tools like compress_pdf_images and optimize_pdf by focusing on analysis rather than transformation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Implies usage before optimization but lacks explicit when-to-use or when-not-to-use guidance. No mention of alternatives despite having sibling tools like optimize_pdf.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

compress_pdf_imagesA

Compress images in PDF while preserving document structure.

Args:
    file_path: Path to source PDF file
    output_file: Output PDF file path (optional, auto-generated)
    quality: Image compression quality (1-100, where 100=best quality)
    
Returns:
    JSON string with compression results and statistics
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
output_fileNo
qualityNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A3.8/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description must bear full burden. It mentions preserving document structure, which is a key behavioral promise. However, it does not disclose side effects (e.g., whether input file is modified), permissions needed, or limitations. The description is moderately transparent but lacks depth.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is extremely concise and well-structured. It opens with a clear one-line purpose, followed by a brief Args block and a Returns line. Every sentence adds value with no redundancy. The front-loading of the main action is ideal for quick scanning.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (3 parameters, simple behavior) and the presence of an output schema (which reduces need to detail return values), the description is mostly complete. It covers parameters and behavior, but lacks usage guidelines and minor return details. The instruction allows relying on output schema, so this is acceptable.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It explains all three parameters: file_path (source), output_file (optional, auto-generated), quality (1-100 with 100=best). This adds significant meaning beyond the schema's types and defaults. A slight deduction for not detailing the auto-generation logic further.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's action: 'Compress images in PDF while preserving document structure.' This is a specific verb-resource pair that distinguishes it from sibling tools like 'optimize_pdf' (general optimization) or 'images_to_pdf' (creating PDFs). The focus on images is explicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It does not mention when not to use it, nor does it reference sibling tools like 'optimize_pdf' for more comprehensive compression. The context is entirely derived from the tool's name and description, offering no explicit selection criteria.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

extract_pagesA

Extract specific pages from PDF to a new file.

Args:
    file_path: Path to the source PDF file
    pages: Page range (e.g., "1,3,5-7" for pages 1, 3, and 5 to 7)
    output_file: Output filename (optional, auto-generated if not provided)
    output_dir: Output directory (defaults to source file directory)
    
Returns:
    JSON string with extraction results and output file information
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
pagesYes
output_fileNo
output_dirNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description explains the extraction process, return value (JSON string), and optional parameter defaults. No annotations are provided, so the description carries full burden; however, it does not mention permissions or whether the original file is modified.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise and well-structured, using a list format for parameters and including return value info without any wasted words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's low complexity, the description covers purpose, parameters, and return value completely. The existence of an output schema is indicated by the return description.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description fully compensates for the 0% schema coverage by explaining each parameter with examples, including the page range format and default behaviors for output_file and output_dir.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'Extract specific pages from PDF to a new file,' which is a specific verb and resource. It distinguishes from siblings like split_pdf (whole PDF splitting) and extract_page_text (text extraction).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for page extraction but does not explicitly state when to use this tool versus alternatives like split_pdf or extract_page_text. No exclusion or comparative guidance is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

extract_page_textC

Extract text from a specific PDF page with various extraction options.

Args:
    file_path: Path to PDF file
    page_number: Page number to extract (1-based)
    extraction_mode: Text extraction mode ('default', 'layout', 'simple')
    
Returns:
    JSON string with extracted text and statistics
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
page_numberYes
extraction_modeNodefault

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description must carry the burden. It mentions extraction modes but does not explain their behavior or differences. It says returns statistics but does not specify what those are. Lacks disclosure of side effects or performance implications.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise and well-structured as a docstring with sections for args and returns. No superfluous sentences, though it could be more compact.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations, 3 parameters, and an output schema, the description should provide more context. It mentions a JSON return but does not describe the structure or any error conditions. The tool's behavior regarding page validation, encoding, or performance is absent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema has 0% description coverage, so description must compensate. It adds '1-based' for page_number, which is helpful. However, it does not explain the extraction_mode options beyond listing their names, and file_path is simply restated. Missing details on allowed values, format, or constraints.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool extracts text from a specific PDF page, using a specific verb and resource. It distinguishes from sibling tools like 'read_pdf' (full document) and 'search_pdf_text' (search).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives like 'read_pdf' for full document extraction or 'ocr_pdf' for scanned pages. The description does not mention exclusions or prerequisites.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

extract_pdf_imagesA

Extract images from PDF pages.

Args:
    file_path: Path to PDF file
    pages: Page range (e.g., '1,3,5-10,-1' for specific pages)
    min_size: Minimum image size to extract (format: 'WIDTHxHEIGHT', e.g., '100x100')
    output_dir: Directory to save extracted images (default: auto-generated)
    
Returns:
    JSON string with extraction results and file paths
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
pagesNo
min_sizeNo100x100
output_dirNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A3.9/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full burden. It describes the return format (JSON with extraction results and file paths) but lacks details on error handling, side effects, or performance.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with a summary, parameter list, and return info. It is concise, though could be slightly more succinct without losing clarity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description covers input parameters and return type, but does not explain the output schema in detail or mention prerequisites like PDF readability. Adequate for basic use, but gaps remain.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, but the description adds significant meaning: examples for pages ('1,3,5-10,-1') and min_size ('100x100'), and clarifies output_dir default behavior. All 4 parameters are well explained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'Extract images from PDF pages' with a specific verb and resource. It distinguishes from sibling tools like pdf_to_images (converts pages to images) and extract_page_text.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No explicit when-to-use or when-not-to-use guidance. The parameter descriptions imply usage (e.g., page ranges, size filtering), but no alternatives or exclusions are mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

find_and_highlight_textB

Find text and return information for highlighting matches.

Args:
    file_path: Path to PDF file
    query: Text to search for
    pages: Page range (e.g., '1,3,5-10,-1') or None for all pages
    case_sensitive: Whether search is case-sensitive (default: False)
    
Returns:
    JSON string with page highlights and position information
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
queryYes
pagesNo
case_sensitiveNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

B3.3/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description does not clarify whether the tool actually highlights the PDF or only returns coordinates for highlighting. It also does not specify if the file is modified, despite the name suggesting modification. With no annotations provided, the description should clearly state the tool's side effects or lack thereof.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise and well-structured, with a clear one-line purpose followed by an Args/Returns block. However, the first sentence could be more direct, and some redundancy exists (e.g., repeating parameter names in Args).

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description explains all parameters and provides a return format, but it lacks context about sibling tool differentiation, file prerequisites, and whether highlighting is actual or simulated. Given the tool has an output schema, the return description is adequate but incomplete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0% description coverage, but the description fully compensates by explaining each parameter: file_path, query, pages, and case_sensitive. It provides default values and usage hints, adding significant meaning beyond the raw schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool finds text and returns information for highlighting matches. It specifies the resource (PDF) and the action (find and return highlight info). However, it does not differentiate from the sibling tool 'search_pdf_text', which likely performs a similar search function.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives like 'search_pdf_text' or 'read_pdf'. The description lacks context about prerequisites, expected file state, or situations where this tool is preferred.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_pdf_metadataA

Read PDF metadata including standard fields and optionally XMP metadata.

Args:
    file_path: Path to PDF file
    include_xmp: Whether to include advanced XMP metadata (default: False)
    
Returns:
    JSON string with comprehensive metadata information
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
include_xmpNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, but the description clearly states 'Read' indicating a non-destructive operation. It also specifies the return format (JSON string with comprehensive metadata). No behavioral contradictions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is extremely concise with two sentences plus a structured docstring. Every sentence adds value, and the core purpose is front-loaded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (2 parameters, output schema present, no nested objects), the description fully covers what the agent needs to know. No missing elements.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It explains both parameters: file_path as path to PDF, include_xmp as flag for XMP metadata. While basic, it adds sufficient meaning beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses specific verb 'Read' and resource 'PDF metadata', clearly distinguishing from sibling tools like set_pdf_metadata (write) or remove_pdf_metadata (delete). The scope includes standard fields and optional XMP metadata.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies when to use (to read metadata) but does not explicitly discuss when not to use or provide alternatives. However, the context is clear given sibling tool names.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

images_to_pdfA

Convert multiple images to a single PDF.

Images are processed in the order specified in the image_paths list,
preserving their sequence in the final PDF document.

Args:
    image_paths: List of image file paths to convert
    output_file: Output PDF file path
    page_size: Page size ('A4', 'Letter', 'Legal', or 'auto')
    quality: JPEG quality for compression (1-100)
    title: PDF document title (optional)
    author: PDF document author (optional)
    
Returns:
    JSON string with conversion results
ParametersJSON Schema
NameRequiredDescriptionDefault
image_pathsYes
output_fileYes
page_sizeNoA4
qualityNo
titleNo
authorNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4.2/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden. It discloses processing order, parameter explanations, and that output is a JSON string. It does not cover error handling or side effects, but overall it is transparent enough for typical use.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the core purpose and uses a structured docstring format. It is slightly verbose due to parameter listings, but each sentence adds value.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description covers the tool's main behavior, parameters, and return type. It lacks details on error handling or constraints like supported image formats, but given the parameter count and absence of annotations, it is fairly complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must add meaning. It does so by listing each parameter with its type and semantics (e.g., page_size allowed values, quality range), fully compensating for schema lack.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'Convert multiple images to a single PDF' and specifies that images are processed in order, which distinguishes it from sibling tools like pdf_to_images or merge_pdfs.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description does not explicitly mention when to use this tool versus alternatives. It implies usage for creating a PDF from images but lacks guidance on exclusions or when not to use it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

merge_pdfsA

Merge multiple PDF files into a single file.

Pages are processed in the order specified in the file_paths list,
preserving the original page sequence in the merged document.

Args:
    file_paths: List of PDF file paths to merge
    output_file: Output filename (optional, auto-generated if not provided)
    output_dir: Output directory (defaults to first file's directory)
    
Returns:
    JSON string with merge results and output file information
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathsYes
output_fileNo
output_dirNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A3.9/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden. It discloses optional parameters and default behavior for output_dir, but does not mention whether existing files are overwritten, that original PDFs remain unchanged, or any safety traits. Adequate but not thorough.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is relatively concise, front-loading the purpose. The Args and Returns sections are useful but slightly redundant with the schema. However, every sentence serves a purpose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (merge, 3 params, 1 required) and no annotations, the description explains order, optional parameters, and return format. It leverages the output schema mention. Missing a note on non-destructiveness, but fairly complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description compensates for 0% schema coverage by adding an Args section that explains each parameter's role (order, optional output_file, default directory). This adds meaning beyond the bare schema, though parameter types are already in schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool merges multiple PDFs into one, specifying the order-based processing. It distinguishes from sibling tools like split_pdf and extract_pages by its unique merging function.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains the page order based on file_paths, but does not provide explicit guidance on when to use this tool versus alternatives (e.g., images_to_pdf for other formats) or any prerequisites or limitations.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

ocr_pdfA

Perform OCR on PDF pages using Tesseract for scanned documents.

Args:
    file_path: Path to the PDF file
    pages: Page range (e.g., '1,3,5-10,-1' for pages 1, 3, 5 to 10, and last page)
    language: OCR language code (default: 'chi_sim' for simplified Chinese)
    chunk_size: Maximum size of text chunks
    chunk_overlap: Overlap between chunks to preserve context
    dpi: DPI for PDF to image conversion (higher = better quality, slower)
    
Returns:
    JSON string with OCR results and metadata
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
pagesNo
languageNochi_sim
chunk_sizeNo
chunk_overlapNo
dpiNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A3.7/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are present, so the description carries full burden. It mentions Tesseract, default language, and DPI trade-off, but lacks details on error handling, output format specifics, or performance beyond DPI.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the main purpose but contains an Args section that lists parameters. It is readable but could be more concise; some parameter descriptions are redundant with the schema.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 6 parameters, no annotations, and an existing output schema, the description covers all parameters but lacks usage context, failure scenarios, and comprehensive behavioral info. It is adequate but has gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description adds explanations for all six parameters, including page range format, default language, and DPI effect. Chunk_size and chunk_overlap definitions are somewhat vague but still add value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool performs OCR on PDF pages using Tesseract for scanned documents. It distinguishes from siblings like read_pdf (likely for digital text extraction) and pdf_to_images (conversion only).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies it is for scanned documents but does not explicitly contrast with alternatives like read_pdf or extract_page_text. No direct 'when to use' or 'when not to use' guidance is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

optimize_pdfA

Optimize PDF file using various compression techniques.

Args:
    file_path: Path to source PDF file
    output_file: Output PDF file path (optional, defaults to '_optimized' suffix)
    optimization_level: Optimization preset ('light', 'medium', 'heavy', 'maximum')
    
Returns:
    JSON string with optimization results and file size statistics
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
output_fileNo
optimization_levelNomedium

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A3.7/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Given no annotations, the description partially compensates by noting it uses compression techniques and returns results with file size statistics. However, it does not disclose potential data loss, quality degradation, or required permissions, leaving gaps in understanding behavioral implications.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise (two sentences plus structured Args/Returns) and front-loaded with the main purpose. It uses minimal but effective prose, earning its keep.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple 3-parameter tool, the description covers inputs and outputs (JSON result). It does not explain edge cases or error handling, but given the straightforward nature, it is sufficiently complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The parameter descriptions add significant meaning beyond the schema: file_path is identified as source, output_file's default suffix is explained, and optimization_level's preset options are listed. With 0% schema coverage, the description effectively compensates.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'Optimize PDF file using various compression techniques.' The verb 'optimize' and resource 'PDF' are specific, and it distinguishes from siblings like compress_pdf_images (which is image-specific) and analyze_pdf_size (which only analyzes).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives like compress_pdf_images or other PDF tools. There is no mention of prerequisites or when not to use it, leaving the agent without decision support.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

pdf_to_imagesA

Convert PDF pages to images.

Args:
    file_path: Path to PDF file
    pages: Page range (e.g., '1,3,5-10,-1' for pages 1, 3, 5 to 10, and last page)
    dpi: Resolution for image conversion (default: 200)
    image_format: Output format ('PNG', 'JPEG', etc.)
    output_dir: Directory to save images (default: auto-generated)
    save_to_disk: Whether to save images to disk or keep in memory
    
Returns:
    JSON string with conversion results and file paths
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
pagesNo
dpiNo
image_formatNoPNG
output_dirNo
save_to_diskNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A3.8/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden. It discloses basic behavior (conversion, parameter defaults) but lacks details on error handling, required permissions, or memory usage for large files. Adequate but not comprehensive.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description starts with a clear purpose, then lists parameters with explanations, followed by return type. It is well-structured and not verbose, though the returns description is somewhat vague.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

All 6 parameters are explained, and the return type is mentioned. Given the presence of an output schema, the description covers most aspects needed by an AI agent, though edge cases and error conditions are not addressed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description provides all parameter meaning. It explains the pages syntax with examples, default values for dpi and image_format, and distinguishes between saving to disk vs memory.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states 'Convert PDF pages to images' which is a specific verb+resource combination. It clearly distinguishes from siblings like extract_pages (extract pages as PDF) and extract_page_text (extract text).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool vs alternatives like extract_pdf_images or split_pdf. The description only states what the tool does, not when it is appropriate.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

read_pdfA

Extract text from PDF files with intelligent page handling and chunking.

Args:
    file_path: Path to the PDF file
    pages: Page range (e.g., '1,3,5-10,-1' for pages 1, 3, 5 to 10, and last page)
    chunk_size: Maximum size of text chunks
    chunk_overlap: Overlap between chunks to preserve context
    
Returns:
    JSON string with extracted text and metadata
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
pagesNo
chunk_sizeNo
chunk_overlapNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A3.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden. It mentions returns JSON with extracted text and metadata but does not disclose side effects, permissions, file size limits, or error handling, leaving significant behavioral gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with purpose and structured as a docstring with Args and Returns. It is reasonably concise, though the Returns section could be trimmed since an output schema exists, but it still adds value.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool has 4 parameters and no annotations, the description covers parameter semantics and return type but lacks context on prerequisites (e.g., file must exist), error conditions, and safety traits, making it adequate but not fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0% coverage (no descriptions in properties), but the description provides explanations for all 4 parameters, including the format for 'pages' (with examples), and context for chunk_size and chunk_overlap, adding significant meaning beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Extract' and resource 'text from PDF files', and mentions intelligent page handling and chunking, which distinguishes it from sibling tools like extract_pages or search_pdf_text that have different purposes.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for PDF text extraction with specific page and chunking needs, but does not explicitly state when to use this tool versus alternatives, nor does it provide when-not-to-use guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

remove_pdf_contentB

Remove specific content from PDF to reduce file size.

Args:
    file_path: Path to source PDF file
    output_file: Output PDF file path (optional, auto-generated)
    remove_images: Whether to remove all images
    remove_annotations: Whether to remove annotations
    compress_streams: Whether to compress content streams
    
Returns:
    JSON string with content removal results and statistics
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
output_fileNo
remove_imagesNo
remove_annotationsNo
compress_streamsNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

B3.1/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description must disclose behavioral traits. The description mentions removal of images and annotations and compression of streams, but does not state important aspects like whether the original file is preserved, what happens to the output file if already exists, or any required permissions. The behavioral disclosure is minimal.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise with a clear top-level statement followed by structured parameter documentation. It avoids unnecessary verbosity. However, it could be slightly more front-loaded by emphasizing the primary use case (size reduction) before listing parameters.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description mentions an output JSON with results and statistics, but does not detail what those statistics are. It lacks information about file prerequisites, error conditions, or side effects. Given the complexity (5 parameters, mutation), more context would be beneficial.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema properties lack descriptions (0% coverage), but the description's Args section provides clear explanations for each of the 5 parameters, including defaults and optionality. This adds significant meaning beyond the schema titles and types.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool removes specific content from PDF to reduce file size. The verb 'remove' and resource 'specific content from PDF' are explicit. However, it does not explicitly differentiate from sibling tools like compress_pdf_images or optimize_pdf, which have overlapping goals.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. There are no examples, no when-not-to-use instructions, and no mention of prerequisites or context. This is a significant gap, especially given the number of sibling tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

remove_pdf_metadataA

Remove specific metadata fields or all metadata from PDF.

The fields_to_remove and remove_all parameters are mutually exclusive:
use either fields_to_remove for selective removal OR remove_all for complete removal.

Args:
    file_path: Path to source PDF file
    output_file: Output PDF file path (optional, defaults to overwrite source)
    fields_to_remove: List of specific fields to remove (e.g., ['title', 'author'])
    remove_all: Remove all metadata if True (default: False)
    
Returns:
    JSON string with operation results
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
output_fileNo
fields_to_removeNo
remove_allNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4.1/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description bears full burden. It warns about overwriting the source file if output_file is omitted, which is critical. But it doesn't disclose error behavior, permissions needed, or that this is a destructive operation beyond removal.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Structured with Args/Returns sections, but the extra formatting is typical and clear. Could be slightly more concise, but no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the output schema exists, the description suffices by stating return type. It covers parameter roles and the overwrite-behavior. Missing details on error handling or prerequisites, but acceptable.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema has 0% description coverage, so description adds essential meaning: explains mutual exclusivity, defaults for output_file and remove_all, and clarifies that fields_to_remove is a list of strings.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description states 'Remove specific metadata fields or all metadata from PDF' with a clear verb-object structure. This distinguishes it from sibling tools like set_pdf_metadata (which modifies) and get_pdf_metadata (which reads).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explains mutual exclusivity between fields_to_remove and remove_all, which guides usage. However, it does not mention when to prefer this tool over set_pdf_metadata or other alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

search_pdf_textA

Search for text content across PDF pages with detailed match information.

Args:
    file_path: Path to PDF file
    query: Text to search for (or regex pattern if regex_search=True)
    pages: Page range (e.g., '1,3,5-10,-1') or None for all pages
    case_sensitive: Whether search is case-sensitive (default: False)
    regex_search: Whether to treat query as regex pattern (default: False)
    context_chars: Number of characters to show around matches (default: 100)
    max_matches: Maximum number of matches to return (default: 100)
    
Returns:
    JSON string with search results, match locations, and context
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
queryYes
pagesNo
case_sensitiveNo
regex_searchNo
context_charsNo
max_matchesNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the burden of behavioral disclosure. It mentions that it returns 'JSON string with search results, match locations, and context' and specifies defaults for optional parameters. However, it omits details like error handling (e.g., invalid file path, malformed regex) or performance implications for large PDFs.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with a brief intro followed by an Args list and a Returns line. It is concise but covers all important details. Minor redundancy: the Args list repeats parameter names already in the schema, but this is acceptable for clarity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 7 parameters, no annotations, and a complex tool, the description is fairly complete. It explains all parameters and return format. However, it lacks guidance on edge cases (e.g., query not found) and doesn't fully distinguish from siblings like 'find_and_highlight_text', which searches and highlights.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0% coverage (no descriptions), but the description's Args section explains all 7 parameters in detail, including format (e.g., page range '1,3,5-10,-1'), defaults, and behavior (e.g., 'context_chars: Number of characters to show around matches'). This fully compensates for the missing schema descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Search for text content across PDF pages with detailed match information.' It uses a specific verb ('Search') and a resource ('text content across PDF pages'), and distinguishes from siblings like 'find_and_highlight_text' (which highlights) and 'extract_page_text' (which extracts full text).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides detailed parameter usage in the Args section, explaining how to use each option (e.g., page ranges, regex flag). However, it does not explicitly state when to use this tool over alternatives like 'extract_page_text' or 'find_and_highlight_text', nor does it provide any 'when to use' or 'when not to use' guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

set_pdf_metadataB

Write or update PDF metadata fields.

Args:
    file_path: Path to source PDF file
    output_file: Output PDF file path (optional, defaults to overwrite source)
    title: Document title
    author: Document author
    subject: Document subject  
    creator: Creator application name
    producer: Producer application name
    keywords: Keywords or tags (comma-separated)
    preserve_existing: Whether to preserve existing metadata (default: True)
    
Returns:
    JSON string with operation results
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
output_fileNo
titleNo
authorNo
subjectNo
creatorNo
producerNo
keywordsNo
preserve_existingNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

B3.4/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description must cover behavioral traits. It mentions preservation behavior and output file defaults, but lacks details on file handling (e.g., overwrite risks, error conditions, permissions). Does not fully disclose potential destructive actions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Structured as a docstring with Args and Returns sections. Each line is purposeful and front-loaded with action. Could be slightly more concise but remains readable and efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with 9 parameters and no annotations, the description covers key aspects like output file handling and preservation. However, it lacks information on error handling, file validation, and return value specifics beyond stating 'JSON string with operation results'.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description adds value by explaining each parameter (e.g., 'Path to source PDF file', 'Keywords or tags (comma-separated)'). This compensates for the schema's lack of descriptions, though some descriptions are minimal.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description explicitly states 'Write or update PDF metadata fields,' providing a clear verb and resource. This action is distinct from siblings like 'get_pdf_metadata' and 'remove_pdf_metadata', making purpose unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives. There is no mention of prerequisites, scenarios, or when to avoid using it. Siblings like 'get_pdf_metadata' and 'remove_pdf_metadata' exist but no comparative advice.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

split_pdfB

Split PDF into multiple files based on page ranges.

Args:
    file_path: Path to the source PDF file
    split_ranges: List of page ranges (e.g., ["1-5", "6-10", "11-15"])
    output_dir: Output directory (defaults to source file directory)
    prefix: Output file prefix (defaults to source filename)
    
Returns:
    JSON string with split operation results and output file information
ParametersJSON Schema
NameRequiredDescriptionDefault
file_pathYes
split_rangesYes
output_dirNo
prefixNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description must fully disclose behaviors. It does not specify whether the original file is modified, handling of edge cases (e.g., overlapping ranges, invalid page numbers), or performance implications. The return type (JSON string) is mentioned but lacks details on structure or error responses.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a well-structured docstring with Args and Returns sections. It is concise and front-loaded with the core purpose. The two-sentence summary at the top is effective, but the bullet list could be slightly tightened.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 4 parameters, 2 required, and an output schema, the description covers parameter defaults and return type. However, it lacks differentiation from sibling extract_pages, missing context on when to use each. It also omits behavioral details that an agent would need for correct invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must compensate. It adds meaning by explaining split_ranges with an example and stating defaults for output_dir and prefix. However, it does not clarify the file_path format (must be an existing file?) or constraints on ranges (e.g., sorted, non-overlapping).

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'Split PDF into multiple files based on page ranges,' which uses a specific verb and resource. Among sibling tools like extract_pages, it distinguishes itself by splitting into multiple files rather than extracting pages into a single file.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no explicit guidance on when to use this tool versus alternatives like extract_pages. It does not mention prerequisites, when not to use, or context where another tool would be more appropriate.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

TDQS

A3.8/5.0
Disambiguation5/5

Each tool has a clear and distinct purpose; overlapping functions like read_pdf and extract_page_text are differentiated by scope and arguments, preventing confusion.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern with underscores, e.g., analyze_pdf_size, compress_pdf_images. Even compound verbs maintain the pattern.

Tool Count5/5

18 tools cover a wide range of PDF operations without being excessive; each tool serves a specific need and the count is well-scoped for a PDF utility server.

Completeness4/5

Covers reading, extraction, search, metadata management, splitting, merging, compression, OCR, and image conversion. Missing creation from scratch and annotations, but core workflows are well-supported.

Maintenance

ActivityInactive
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    An MCP server that provides comprehensive PDF processing capabilities including text extraction, image extraction, table detection, annotation extraction, metadata retrieval, page rendering, and document structure analysis.
  • A
    license
    Not graded
    quality
    B
    maintenance
    An MCP server for PDF form filling, basic editing, and OCR text extraction. It enables users to merge, rotate, annotate, and sign PDFs, while also supporting text extraction from both searchable and scanned image-based documents.
    3
    Apache 2.0
  • A
    license
    Not graded
    quality
    D
    maintenance
    An MCP server that provides tools for reading, writing, and manipulating PDF files, including text extraction, metadata retrieval, and merging or splitting documents. It also enables users to create PDFs from plain text and convert specific pages or entire documents into images.
    53
    ISC

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/lihongwen/pdfreadermcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server