Skip to main content
Glama

relevant_context

Read-only

Map the dependency context around given files by showing their imports, importers, and top symbols for code navigation and impact review.

Instructions

Show the files around the given files: what they import and what imports them, with their top symbols.

Args: files: Center file paths. depth: Number of hops, 1 or 2 (default 1). task_hint: Optional task text that orders the files.

Input Schema

NameRequiredDescriptionDefault
depthNo
filesYes
task_hintNo
workspaceNoProject path (default: this project)
max_tokensNo
include_symbolsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, so safety is covered structurally. The description does add real behavioral detail: the breadth expansion (imports and importers), depth as hop count, and that task_hint changes ordering rather than filtering. It omits the truncation behavior implied by max_tokens (default 2000, max 32000) and what happens when include_symbols is false, so it does not fully close the gap.

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 leading sentence front-loads the behavior and the Args block maps cleanly to parameters, with no filler prose. Slight redundancy with the schema in restating defaults, but it is short and structurally clear.

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

Completeness5/5

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

For a six-parameter read-only graph traversal with no output schema, the definition covers the core semantic levers: direction of traversal, hop depth, ordering, and workspace scope. Missing notes on truncation and symbol suppression are minor against annotations that already establish the non-destructive read profile.

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 only 17% (workspace alone), so the description must compensate, and it partially does: it explains files as center paths, constrains depth to 1 or 2 with a default of 1, and clarifies that task_hint orders rather than filters. However max_tokens, include_symbols, and workspace are left entirely to the schema, half the parameter surface is undocumented anywhere meaningful.

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?

A specific verb-plus-resource statement: it shows the files around the given files, both what they import and what imports them, plus top symbols. That pins down the traversal direction and payload better than a generic 'get context' name would. It never names or distinguishes itself from closely overlapping siblings such as dependencies, impact_analysis, or cross_references, which keeps it out of 5 territory.

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?

There is no statement of when to reach for this tool versus dependencies, impact_analysis, or cross_references, all of which sound like they operate on the same import graph. The only hint at usage is the optional task_hint parameter, which implies 'gather context around files for a task', but that is inference rather than guidance. No exclusions or prerequisites are given.

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