Skip to main content
Glama

devanvil_semantic_diff

Compares two JSON payloads with order-independent structural diffing or runs a line-by-line LCS text diff to reveal meaningful changes.

Instructions

Compute order-independent Semantic JSON Structural Diff or line-by-line LCS diff between two payloads.

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": {
      "left": "<left>",
      "right": "<right>"
    },
    "name": "devanvil_semantic_diff"
  }
}

Input Schema

NameRequiredDescriptionDefault
leftYesOriginal text or JSON.
modeNoDiff mode (default "json").
rightYesModified text or JSON.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it does disclose one meaningful behavioral trait: the JSON comparison is order-independent (semantic) while the text mode is a line-by-line LCS. It omits other behavior an agent needs, such as whether JSON keys/arrays are normalized, how invalid JSON is reported, and what the diff output looks like.

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?

A single front-loaded sentence with no filler; the core verb and both algorithm names appear immediately. It is dense capitalization-heavy phrasing but nothing is redundant.

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?

There is no output schema and no annotations, so the description should say more about the returned diff representation (structure, patch format, or summary counts). What it covers — inputs and algorithm choice — is correct and complete, but the result side is left unaddressed for a tool whose whole purpose is producing output.

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 baseline is 3, but the description adds real meaning by mapping the two modes to distinct algorithms: the "json" mode is a semantic, order-independent structural diff and the "text" mode is an LCS line diff. That lets an agent choose a mode value based on behavior rather than the schema's terse "Diff mode" label.

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 uses a specific verb ("Compute") with a named resource ("Semantic JSON Structural Diff or line-by-line LCS diff") and states the input shape ("between two payloads"). It is clear enough to distinguish this from siblings like devanvil_convert_data or devanvil_check_contract_drift, though it does not explicitly name an alternative.

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

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied by the two named diff algorithms, but the description never says when to choose this over a sibling tool or when each mode is appropriate beyond the mode enum in the schema. No prerequisites or exclusions are given.

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