Skip to main content
Glama

compare_commits

Compare two Git commits with detailed analysis. Specify commit references, filter by file pattern, and choose output format (unified, stat, or name-only) to review code changes between any two points in your repository.

Instructions

Compare two commits with detailed analysis

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commit1YesFirst commit hash or reference
commit2YesSecond commit hash or reference
filePatternNoFile pattern to filter
formatNoOutput format
cwdNoWorking directory
Behavior2/5

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

With no annotations, the description bears full responsibility for disclosing behaviors. It only says 'detailed analysis' without explaining what the output is (e.g., diff text, statistics), whether it is read-only, or any side effects. This is insufficient for an agent to understand the tool's behavior.

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

Conciseness3/5

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

The description is a single sentence, which is concise but overly minimal for a tool with multiple parameters and no annotations. It could be expanded to include key details without being verbose. It is acceptable but not exemplary.

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

Completeness2/5

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

Given the tool has five parameters, no output schema, and no annotations, the description should provide more context about return values, behavior, and distinction from siblings. The current description is too sparse to be considered complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

All five parameters have descriptions in the input schema (100% coverage), so the schema already conveys meaning. The description adds no additional parameter info beyond what is in the schema, which meets the baseline for this dimension.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Compare two commits with detailed analysis' clearly states the verb and resource, but 'detailed analysis' is vague and does not differentiate from sibling tools like git_diff or enhanced_git_diff. It lacks specificity about the type of comparison, making it only minimally clear.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus the many sibling comparison tools (e.g., git_diff, analyze_file_differences). The description does not mention alternatives or appropriate contexts.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/agentics-ai/code-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server