git_diff_staged
Review staged changes before committing by showing the diff for a specified Git repository path.
Instructions
Shows changes that are staged for commit
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| repo_path | Yes | ||
| context_lines | No |
Review staged changes before committing by showing the diff for a specified Git repository path.
Shows changes that are staged for commit
| Name | Required | Description | Default |
|---|---|---|---|
| repo_path | Yes | ||
| context_lines | No |
Changes observed during successful MCP inspections.
v2.0.0Input schema / titlePrevious value: -"GitDiffStaged"New value: +"diff_stagedArguments"v1.0.0Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false and a closed world, so the safety profile is fully covered without the description. The description adds no further behavior (output format, behavior with nothing staged, pagination), so it is adequate but contributes little.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single short, front-loaded sentence with zero filler. It is appropriately sized, though it is so terse that it omits useful detail rather than trimming waste.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple read-only diff tool with full annotation coverage and no output schema, the essentials are inferable, but the description never mentions what the diff looks like, how paths are interpreted, or what happens when nothing is staged. Minimum viable rather than complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0% for both parameters, so the description must compensate and does not: neither repo_path nor context_lines (default 3) is explained, and there is no hint about path format or what context lines do. Only the obvious reading of the names carries any meaning.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb ('Shows') and resource ('changes that are staged for commit'), which is precise enough to separate it from git_diff_unstaged by the staged/unstaged qualifier. It does not explicitly name the sibling, so it stops short of a 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no when-to-use statement, no prerequisite (e.g. must have staged changes), and no mention of alternatives like git_diff_unstaged or git_status. The 'staged for commit' phrasing faintly implies a pre-commit review context, but nothing is stated explicitly.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.