Skip to main content
Glama

goto_definition

Jump to the exact file and location where a symbol is defined. Provide a file path, line, and column to resolve the definition instantly.

Instructions

Go to the definition of a symbol at the given position. Returns the file and location where the symbol is defined.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
colYesColumn number (1-indexed)
fileYesRelative file path from project root
lineYesLine number (1-indexed)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

B3.3/5.0
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 disclosing behavior. It does state that the tool returns the file and location of the definition, which is meaningful, but it does not specify the return structure, what happens when multiple definitions exist, or whether any navigation side effect occurs.

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?

Two short sentences state the action and the return value with no filler. The description is concise and front-loaded, making it easy for an agent to process quickly.

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 is simple, but with no output schema and no sibling differentiation, the description leaves some gaps: the exact shape of the returned location is not defined, and the boundary against related goto_* tools is implicit. It is adequate for a well-known LSP-style operation, but not complete on its own.

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?

All three parameters are already fully described in the input schema, so the schema carries the semantic weight. The description only reinforces that the position is needed to locate the symbol, adding no extra meaning beyond what the schema provides.

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 the action ('Go to the definition of a symbol at the given position' and what is returned. It is unambiguous about the core purpose, but it does not explicitly differentiate itself from the closely related siblings goto_type_definition, goto_implementation, and goto_declaration.

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?

No guidance is given on when to use this tool versus alternatives. The presence of many sibling navigation tools means an agent must infer the difference from the name alone, since the description never mentions exclusions or preferred contexts.

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