Skip to main content
Glama

tool_diff

Compare two text inputs to identify added, removed, and unchanged parts, returning a detailed diff and change counts.

Instructions

[text] Diff

Parameters:

  • text1 (string): Text 1

  • text2 (string): Text 2

Outputs:

  • added (number): Added

  • removed (number): Removed

  • unchanged (number): Unchanged

  • diff (json): Diff

  • changes (json): Changes

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
diffNoDiff
addedNoAdded
text1NoText 1
text2NoText 2
changesNoChanges
removedNoRemoved
unchangedNoUnchanged
Behavior2/5

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

With no annotations, the description must carry the burden of behavioral disclosure. It only lists output fields (added, removed, unchanged, diff, changes) without explaining how the diff is computed (e.g., line-level vs character-level, case sensitivity, output format of 'diff' and 'changes'). This leaves significant ambiguity about the tool's exact behavior.

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 compact and organized into Parameters and Outputs sections, which clarifies the input/output separation. However, it lacks a leading explanatory sentence and reads more like a structured list than a cohesive description. It is not verbose but also not well-rounded.

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 the lack of annotations and output schema, the description should provide a complete picture of the tool's behavior. It clarifies that only text1 and text2 are inputs (while the schema confusingly includes output properties), but it does not define the structure of 'diff' or 'changes' values, leaving the tool's functionality underspecified.

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 100%, so the baseline is 3. The description mostly repeats the schema property descriptions ('Text 1', 'Text 2', etc.) but adds type clarity for 'diff' and 'changes' as 'json', which the schema lacks. This minor addition keeps it at baseline without exceeding it.

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

Purpose2/5

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

The description starts with '[text] Diff' which is a vague label rather than a clear statement of functionality. It lists parameters and outputs but never explicitly says 'computes the difference between two texts'. The purpose is implied by the tool name and parameter names, but not clearly articulated.

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

Usage Guidelines1/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 any context, prerequisites, or exclusions. There is no comparison to sibling tools like tool_string or tool_hash.

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

Install Server

Other Tools

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/maple-awa/tool-mcp'

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