Skip to main content
Glama

explain_impact

Trace the exact import chain from a changed source file to a test file to explain why the test is affected. Get the step-by-step import path.

Instructions

Finds the exact import chain that connects a changed source file to a test file. Use to answer: why does changing file X cause test Y to be affected? Returns the step-by-step import path from the test to the changed file.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
test_fileYesThe test file to explain the connection for
changed_fileYesThe source file that was changed (absolute or relative to project_root)
project_rootYesAbsolute path to the TypeScript project root (must contain tsconfig.json)
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It implies a read-only analysis but does not explicitly state that it does not modify the project, nor does it disclose any limitations, prerequisites (like needing a fresh index), or error behavior. The description focuses on purpose and output rather than behavioral traits.

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?

The description is two sentences, front-loaded with the core function, and adds a concrete use case and output expectation. Every word earns its place with no redundancy.

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 tool has 3 parameters, no output schema, and no annotations. The description explains the output ('step-by-step import path') but does not address edge cases (e.g., no import chain exists) or prerequisites (e.g., project must be indexed via refresh_project). While sufficient for a simple tool, it leaves gaps in operational context.

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?

Schema description coverage is 100%, with each parameter (test_file, changed_file, project_root) already well-documented. The description adds minimal semantic value, only linking changed_file to 'X' and test_file to 'Y' in the example question. This slightly enriches context but does not go beyond the schema's baseline.

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 function: 'Finds the exact import chain that connects a changed source file to a test file.' It uses a specific verb and resource, and the example question 'why does changing file X cause test Y to be affected?' distinguishes it from sibling tools that list affected tests or show dependency graphs.

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 context by explicitly saying 'Use to answer: why does changing file X cause test Y to be affected?' This indicates when to use the tool. However, it does not mention alternatives or exclusions, so it falls short of an explicit when-not-to-use guidance.

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/vola-trebla/ast-impact-mapper-mcp'

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