Skip to main content
Glama

diff_context

Analyze the impact of file changes in a repository. Pass file paths or use git scopes to auto-detect changes and return structured context for code review or modifications.

Instructions

Impact analysis for changed files. Pass comma-separated paths OR use scope to auto-detect from git.

changed_files: comma-separated file paths (overrides scope if provided)
scope: git detection mode — "unstaged" (default), "staged", "commit", "branch"
max_tokens: cap output length (default 6000)
output_format: "text" (default) or "json" for structured response

NOTE: When using scope (git auto-detect), the repo must be a git repository.
Returns a NOT_GIT_REPO error if it isn't. If changed_files is provided,
git is not required.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
repo_pathNo/demo
changed_filesNo
scopeNounstaged
max_tokensNo
exclude_dirsNo
output_formatNotext

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

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

With no annotations, the description bears the full burden of behavioral disclosure. It mentions error conditions (NOT_GIT_REPO) and default values, but does not discuss authorization, rate limits, or whether the operation is read-only. This is adequate but could be more transparent.

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?

The description is well-structured: purpose first, then parameter explanations. It is front-loaded with the core concept. While slightly lengthy, every sentence adds value. A bit more conciseness could be achieved, but overall it is efficient.

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?

The description covers the main functionality and key parameters, but leaves out two parameters (repo_path, exclude_dirs). The presence of an output schema partially compensates for return value documentation. Given the tool's complexity (6 parameters, no annotations), the description is adequate but not fully 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?

The description explains changed_files, scope, max_tokens, and output_format with clear semantics and defaults. However, it omits repo_path and exclude_dirs, two of six parameters. Since schema description coverage is 0%, the description should cover all parameters; the omission is a gap.

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

Purpose5/5

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

The description clearly states the tool's purpose as 'Impact analysis for changed files' with two distinct input methods (comma-separated paths or git auto-detection). This differentiates it from sibling tools like dependencies or dead_code that focus on static analysis, making the purpose unambiguous.

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

Usage Guidelines4/5

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

The description provides clear guidance on when to use changed_files vs scope, noting that changed_files overrides scope and scope requires a git repository. It also warns about the NOT_GIT_REPO error. However, it does not explicitly compare with sibling tools, which would elevate the score.

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/Elmoaid/TempoGraph'

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