Skip to main content
Glama

PDF Read

pdf_read
Read-only

Reads and extracts text from a PDF document (.pdf file). Reads the PDF's text layer only — a scanned or image-only PDF returns little or no text, since this tool does not run OCR. Reads up to 50 pages and ~100 KB of text by default (max_pages changes the page cap); when a cap truncates the result, the header says how many of the total pages were included.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesAbsolute path to the PDF file
max_pagesNoMax pages to extract (default: all)
force_downloadNoIf the file is stored in the cloud and evicted from this Mac (dataless), request the download and wait for it instead of failing. Off by default: a download can take minutes and use metered data, so it is the caller's decision.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesExtracted text content
charsYesNumber of characters in the extracted text
pagesNoTotal number of pages in the PDF

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / force_download
      Added value: +{
      +  "description": "If the file is stored in the cloud and evicted from this Mac (dataless), request the download and wait for it instead of failing. Off by default: a download can take minutes and use metered data, so it is the caller's decision.",
      +  "type": "boolean"
      +}
  2. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, so the safety profile is covered. The description adds meaningful behavioral details beyond that: it explicitly states no OCR, the default 50-page and ~100 KB limits, and that truncation is reported in the header. This goes beyond the annotations and helps the agent anticipate results.

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 three sentences, front-loaded with the core purpose, then limitations and cap behavior. It is efficient with no fluff, but the max_pages default contradiction could have been avoided, making it slightly less clean.

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 that an output schema exists and the annotations cover safety, the description covers the essential behavioral aspects: text-layer-only extraction, no OCR, page/byte caps, and truncation reporting. It does not mention force_download in the description, but the schema covers that thoroughly. It is complete enough for an agent to call correctly.

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 coverage is 100% and the schema already documents all three parameters. The description adds a nuance about max_pages (changing the page cap) but directly contradicts the schema's 'default: all' by saying the default is 50 pages. This inconsistency could mislead an agent. The description does not add helpful info about force_download beyond what the schema already states. Since it introduces a conflict rather than clarifying, it reduces reliability.

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?

States a specific verb and resource: reads and extracts text from a PDF. It also distinguishes itself by clarifying it reads only the text layer (no OCR), which sets clear expectations and separates it from generic file readers like file_read or other format-specific readers.

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?

Provides clear context on when to use the tool (for PDF text extraction) and when not (scanned/image-only PDFs, since no OCR). It also describes the default page/byte limits and the truncation header, which helps the agent decide if this tool is appropriate for the task. However, it does not explicitly name alternative tools or state conditions for switching to a sibling.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources