Skip to main content
Glama

git_diff

Inspect local changes by showing the diff for a GitHub repository, choosing unstaged or staged changes.

Instructions

Show the local diff. Use staged=false for unstaged changes and staged=true for staged changes.

Input Schema

NameRequiredDescriptionDefault
stagedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A3.7/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. 'Local diff' implies a read-only, local-only operation, but it does not explicitly state that there are no side effects, nor does it describe the output format or any prerequisites.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences with no wasted words. The core purpose is front-loaded, followed immediately by the parameter guidance.

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?

For a single-parameter read-only tool, the description covers the main behavioral choice. Since there is no output schema, it could say more about the returned diff format, but the tool's purpose is simple enough that this is a minor gap.

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?

The schema provides no parameter descriptions, but the description compensates by explaining both boolean values: staged=false for unstaged changes and staged=true for staged changes. This adds clear meaning beyond the bare boolean schema.

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 and resource: 'Show the local diff.' This clearly distinguishes it from write-oriented siblings, though it does not explicitly contrast with the closely related git_status tool.

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 explains how to use the staged parameter for staged versus unstaged changes, which implies usage. However, it does not say when to choose git_diff over git_status or other siblings.

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