Skip to main content
Glama
dibun75
by dibun75

get_dependency_chain

Traverses import edges from a given symbol's source file to reveal its full transitive dependency chain, answering what a file ultimately depends on.

Instructions

    Traverses the import edges graph from the file containing ``symbol``
    and returns the full transitive dependency chain (max depth 5).

    Useful for answering: *"What does `auth.py` ultimately depend on?"*

    Args:
        symbol: Name of a class or function. Its source file becomes the
                root of the BFS traversal.
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
symbolYes

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 discloses key behaviors: it traverses the import graph, uses BFS, and has a max depth of 5. However, it omits whether the tool is read-only, handles circular dependencies, or any authentication or performance constraints. These gaps limit transparency.

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 concise at 8 lines, with clear separation of purpose, usage hint, and parameter explanation. It avoids unnecessary fluff. The structure is front-loaded with the core action, making it quick to parse.

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?

Given that an output schema exists (not shown), the description doesn't need to detail return values. However, it lacks information on failure conditions (e.g., symbol not found), handling of circular dependencies, or scope of 'import edges graph' (e.g., only Python imports?). This makes it somewhat incomplete for a complex tool.

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?

Schema coverage is 0%, so the description must compensate. It explains 'symbol' as 'Name of a class or function. Its source file becomes the root of the BFS traversal.' This adds significant meaning beyond the raw schema, though it could clarify if it requires fully qualified names or module paths.

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 clearly states it 'traverses the import edges graph ... and returns the full transitive dependency chain', specifying a verb and resource. It distinguishes from siblings like 'get_architecture_map' or 'get_drift_report' by focusing on dependency chains. However, it could be more explicit about the exact type of dependencies (e.g., file-level only).

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?

The description provides a use case example: 'What does auth.py ultimately depend on?' which implies when to use. But it offers no guidance on when not to use this tool or alternatives among the listed siblings like 'get_architecture_map' for higher-level views, or 'impact_analysis' for change effects.

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/dibun75/visor'

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