Skip to main content
Glama

gograph_node

Read-onlyIdempotent

Fetch AST metadata such as kind, file path, line number, and signature for a Go symbol, package, or file without reading the full source body.

Instructions

Fetch AST metadata for a named symbol, package, or file: kind, file path, line number, full signature, doc comment, and struct fields if applicable. The MCP server checks freshness before this call and refreshes in the current requested analysis mode; precise and precise_fallback graphs retry CHA/SSA after source changes. Read-only; no side effects. WHEN TO USE: When you need structural metadata (kind, signature, line number) without the full source body — lighter than gograph_source for metadata-only lookups. NOT TO USE: For full source code (use gograph_source); for call relationships (use gograph_callers/gograph_callees). RETURNS: Node properties array with kind, file, line, and signature; empty when the name is not found.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesThe exact symbol, package path, or Go file name to inspect (e.g., 'Graph', 'internal/search', 'server.go')
limitNoMaximum rows per page; the byte budget may return fewer.
cursorNoOpaque next_cursor for the same graph snapshot and result selection.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv1.7.5
    • addedInput schema / properties / cursor
      Added value: +{
      +  "description": "Opaque next_cursor for the same graph snapshot and result selection.",
      +  "maxLength": 128,
      +  "type": "string"
      +}
    • addedInput schema / properties / limit
      Added value: +{
      +  "default": 100,
      +  "description": "Maximum rows per page; the byte budget may return fewer.",
      +  "maximum": 200,
      +  "minimum": 1,
      +  "type": "integer"
      +}
  2. Addedv1.5.3
  3. Removedv1.5.3
  4. Changed1 schema field changedv1.4.70
    • changedInput schema / properties / name / description
      Previous value: -"The symbol, package, or file name to look up"New value: +"The exact symbol, package path, or Go file name to inspect (e.g., 'Graph', 'internal/search', 'server.go')"
  5. First observedv1.0.0

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already establish read-only, idempotent, non-destructive behavior, but the description adds meaningful context: the MCP server checks freshness before the call, refreshes in the requested analysis mode, and precise graphs retry CHA/SSA after source changes. It also states empty return when the name is not found.

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?

Purpose is front-loaded, followed by WHEN TO USE, NOT TO USE, and RETURNS sections. The structure is clean and every sentence contributes selection or behavior information.

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?

No output schema exists, but the description explains the return shape (node properties array with kind, file, line, signature) and the empty-result case. Combined with the schema covering pagination parameters, it is complete for correct invocation.

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 already documents name, limit, and cursor in detail. The description's 'symbol, package, or file' phrase loosely maps to the name parameter but adds no syntax or format detail beyond the schema, making baseline 3 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 and resource (fetch AST metadata for symbol/package/file) and enumerates returned fields. It explicitly distinguishes itself from gograph_source and gograph_callers/gograph_callees, so an agent can choose correctly without opening schemas.

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?

It has explicit WHEN TO USE and NOT TO USE sections, names the relevant alternatives (gograph_source, gograph_callers, gograph_callees), and gives the selecting condition (metadata-only lookups vs full source or call relationships).

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