Skip to main content
Glama

pdf_hash

Calculates an integrity hash for a PDF and outputs it as plain text to verify file integrity.

Instructions

Calculates integrity hash for a PDF. [Input: PDF (.pdf) | Output: Plain Text (.txt)]

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>"
    },
    "name": "pdf_hash"
  }
}

Input Schema

NameRequiredDescriptionDefault
inputYesThe input PDF file path.

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?

With no annotations present, the description must carry the behavioral burden. It does disclose the input format and that the result is plain text, which hints that a text file is produced rather than a value returned inline. However, the hash algorithm (MD5, SHA-1, SHA-256), encoding (hex/base64), and whether the output file is written to disk or returned are all unstated — significant omissions for an integrity tool.

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?

Two terse sentences with the action front-loaded and the I/O contract bracketed at the end. Nothing is wasted, though the extreme brevity is achieved partly by omitting details an agent would need, so it is concise rather than complete.

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?

This is a low-complexity, one-parameter tool with no output schema, so the description needn't explain return values. Still, for a hashing tool the algorithm identity and output destination are core facts, and neither is stated, leaving a real gap for an agent that must report a verifiable hash.

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?

The single parameter is fully documented in the schema as 'The input PDF file path,' so the schema does the heavy lifting. The description only reinforces that the input must be a PDF, adding no new meaning about path resolution, accepted encodings, or whether remote paths are supported. Baseline 3 applies at 100% coverage.

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?

States a specific verb and resource: 'Calculates integrity hash for a PDF.' An agent can immediately tell this is a hashing/verification tool, distinct from sibling converters and page-manipulation tools. It stops short of naming a sibling or explaining the hash's role in workflows, but the purpose itself is 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?

There is no when-to-use guidance, no prerequisites, and no mention of alternatives such as pdf_compare for content comparison or pdf_dedup_streams for duplicate detection. The I/O line ('Input: PDF | Output: Plain Text') implies a file-in/text-out workflow but doesn't say when an agent should reach for this tool.

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