Skip to main content
Glama

ScorpTech x402 Tools

Text Diff

text_diff
Read-onlyIdempotent

Diff two texts: unified line diff byte-compatible with GNU diff -u (hunks, context, "No newline at end of file"), or word-level / character-level diff with [-removed-]{+added+} inline markup and merged ops. Myers shortest edit script with a patience fallback for very different inputs; options to ignore whitespace, case and CRLF/LF. Returns added/removed/unchanged counts and a similarity ratio. Offline; 20,000 lines or tokens per text. Price: $0.005 USDC per successful call (x402, Solana). Same tool over HTTPS: POST https://scorptech.it.com/api/x402/v1/text-diff

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
aYesOriginal text (aliases: old, before)
bYesNew text (aliases: new, after)
modeNounified (default, alias line), word or char
a_labelNoLabel for the --- header (default a)
b_labelNoLabel for the +++ header (default b)
contextNoContext lines for unified mode, 0-20 (default 3)
ignore_eolNoTreat CRLF and LF as equal (default true)
ignore_caseNoCase-insensitive comparison
ignore_whitespaceNoTreat runs of whitespace as equal

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare readOnly/idempotent/non-destructive, and the description still adds substantial context: offline operation, a 20,000 line/token limit per text, the Myers + patience algorithm, return payload (added/removed/unchanged counts and similarity ratio), and the x402 payment model with an HTTPS endpoint. That is far beyond what annotations convey.

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?

Front-loaded with purpose and modes, then options, limits, and pricing in a tight sequence. It is dense and long, but nearly every clause (algorithm, limits, pricing, endpoint) carries information an agent needs; only the redundant naming of markup symbols is padding.

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?

There is no output schema, so describing the return shape (counts + similarity ratio) is essential and present, along with limits, sandbox/offline status, and cost. Nothing required to call it correctly is missing.

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 coverage is 100%, so the baseline is 3, but the description adds real meaning: what 'unified' mode means concretely (hunks, context, 'No newline at end of file'), what the inline markup looks like, and that ignore options cover whitespace/case/CRLF-LF. The label and context parameters are left to the schema, so not a 5.

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?

Opens with a specific verb+resource ('Diff two texts') and immediately enumerates the output variants: GNU diff -u-compatible unified line diff, word-level, and character-level with inline markup. An agent can distinguish this from siblings like text_stats or text_chunk without opening the schema.

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 which mode produces which output (unified vs word/char inline markup) and notes the patience fallback for very different inputs, giving clear selection context. It does not explicitly state when to prefer this over neighboring text tools, hence not a 5.

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