Skip to main content
Glama
reflex-search

Reflex

Official

get_transitive_deps

Find transitive dependencies of any file up to a specified depth. Traverses the full dependency tree, mapping files to their depth, to understand deep coupling and plan refactoring.

Instructions

Get transitive dependencies of a file up to a specified depth.

Purpose: Find not just direct dependencies, but dependencies of dependencies (the full dependency tree).

Returns: Object mapping file IDs to their depth in the dependency tree.

Use this when:

  • Understanding full dependency chain

  • Analyzing deep coupling

  • Planning refactoring impact

IMPORTANT: Only follows static imports (string literals). Dynamic imports are filtered. See CLAUDE.md section "Dependency/Import Extraction" for details.

Example: depth=2 finds: file → deps → deps of deps

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
depthNoMaximum depth to traverse (default: 3, max recommended: 5)
pathYesFile path (supports fuzzy matching)
Behavior5/5

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

Discloses dynamic import filtering, depth limits, and return format (object mapping IDs to depths). Transparent about limitations beyond schema.

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?

Well-organized with headers and bullet points. Every sentence provides value without redundancy. Front-loaded with purpose.

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

Completeness4/5

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

Describes return format despite no output schema. Covers dynamic import filtering. Could mention behavior on files outside project, but overall complete.

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 already documents parameters clearly (100% coverage). Description adds default depth, max recommended, and fuzzy matching detail, adding value.

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?

Clearly states it gets transitive dependencies up to a specified depth, distinguishing it from direct dependency tools like get_dependencies. Uses specific verb-resource combination.

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

Usage Guidelines5/5

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

Explicitly lists use cases (understanding full chain, analyzing coupling, planning refactoring) and caveats (static imports only), guiding appropriate usage.

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/reflex-search/reflex'

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