Skip to main content
Glama

goto_type_definition

Jump directly to the type definition of any symbol in your code by specifying its file, line, and column, making it easy to trace type origins.

Instructions

Go to the type definition of a symbol. Returns where the type of the symbol at the given position 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

A3.8/5.0
Behavior3/5

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

With no annotations provided, the description carries the full burden. It discloses that the tool returns the location of a type definition and implies a read-only lookup, but it does not mention navigation behavior, error cases, or whether multiple results are possible. Basic transparency is present, but richer behavioral context is missing.

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 with no filler. The core action and result are front-loaded, and every word contributes to understanding the tool's 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?

For a simple three-parameter navigation tool, the description is mostly complete: it states what the tool does and what it returns. It lacks an exact response format or edge-case behavior, but the low complexity and full schema coverage make this a minor gap.

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%, so the schema fully documents file, line, and col. The description adds only the contextual notion of 'the symbol at the given position,' which aligns with the parameters but does not deepen their meaning. Baseline 3 is appropriate.

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 states a specific verb ('Go to') and a precise resource ('type definition of a symbol'), and clarifies that it returns where the type is defined. This clearly distinguishes it from sibling tools like goto_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 Guidelines3/5

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

The description implies usage when one wants the type definition at a given position, but it does not explicitly state when to prefer this over goto_definition or goto_declaration, nor does it provide exclusions. Usage is inferable but not explicitly guided.

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