Skip to main content
Glama

get_diff

Read-onlyIdempotent

Compare a project's current code to its prior snapshot or an empty project, optionally for one file. Reuse an opaque handle to review changes without numbered versions.

Instructions

Review the latest code changes against the preceding state; no numbered versions needed. Omit snapshot for current code or reuse its opaque handle. With only one initial state, compare against an empty project. Optional path limits the comparison to one file.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNo
snapshotNo
project_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already establish readOnlyHint=true, idempotentHint=true, destructiveHint=false, so the safety profile is covered. The description goes beyond that by disclosing two real behaviors: no version numbering is required, and a single-state project diffs against an empty project. It does not mention result format or size, but the output schema exists for that.

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?

Three sentences, front-loaded with the core purpose before the parameter conditions. Slightly dense and the phrase "no numbered versions needed" is a bit oblique, but no sentence is wasted.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With an output schema present, return values need not be explained, and the description covers all three parameters plus the edge case of a single initial state. What remains missing is any indication of comparison scope limits or relationship to sibling tools.

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 description coverage is 0%, so the description must carry the parameters, and it does: snapshot is an opaque handle that can be omitted for current code, and path narrows the diff to one file. project_id is only implicitly covered, which is the one small gap.

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+resource ("Review the latest code changes against the preceding state"), which reads as a diff-retrieval operation and is distinguishable from read_file/search_code/repo_overview by its comparative scope. It never names a sibling explicitly, so differentiation is inferential rather than stated.

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?

It gives conditional usage for parameters ("Omit snapshot for current code", "With only one initial state, compare against an empty project"), which is real guidance, but it never says when to prefer get_diff over repo_overview or search_code. Usage is implied through parameter conditions rather than stated as a routing decision.

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