Skip to main content
Glama

pdf_search

Search inside a PDF for a specific text query and return matching results as a JSON array.

Instructions

Searches for a text query inside a PDF. [Input: PDF (.pdf) | Output: JSON array]

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "input": "<input>",
      "query": "<query>"
    },
    "name": "pdf_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
inputYesThe input PDF file path.
queryYesThe text to search for.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.2/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full behavioral burden. It does disclose the input format (.pdf) and that results come back as a JSON array, which is useful, but it says nothing about matching semantics (case sensitivity, regex, whole-word), whether page numbers or context are returned, or behavior on encrypted/empty 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?

One sentence plus a bracketed I/O tag, front-loaded with the core action and free of filler. The bracketed notation is slightly terse but not wasteful.

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 simple two-parameter read tool this covers the essentials, but with no annotations and no output schema the description should say more about what a match looks like and how matching is performed. It is minimally adequate rather than complete.

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 description coverage is 100%, so both 'input' and 'query' are already documented in the schema. The description adds no syntax, format, or constraint details beyond what the schema provides, which is the baseline expectation.

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 states a specific verb and resource: searching for a text query inside a PDF. That is unambiguous for an agent, but it offers no differentiation from plausible siblings such as semantic_search, workspace_search, or pdf_extract_patterns.

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?

There is no guidance on when to choose this literal text search over semantic_search or pattern extraction, and no stated prerequisites or exclusions. The agent must infer the selection criteria entirely from the tool name.

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