Skip to main content
Glama

find_symbol

Use when the symbol name is known: resolve an exact function, class, or struct against vex's index to retrieve its record, not fuzzy ranked search or grep scan results.

Instructions

Resolve a symbol by exact name (with prefix fallback) against the FST inverted index (~4ms). Prefer over search when the symbol name is known and you want exactly that record back, not a fused-rank list. Prefer over grep for git grep 'class Foo'-style definition lookup — grep scans every byte; this is a constant-time index probe.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameNoDEPRECATED — use `symbol`. Pre-v1.7 alias, still accepted; emits a deprecated_args notice in _meta.
symbolYesExact symbol name (function/class/struct/etc.) — canonical key (v1.7+). Use search for partial or fuzzy names.
excludeNoBlacklist results by path glob; wins over include (repeatable)
includeNoWhitelist results by path glob, gitignore syntax (repeatable)
auto_updateNoAuto-update the index if stale, or bootstrap it if missing, before running (default: true)
async_updateNoWith auto_update, refresh a stale index in the background instead of waiting for it: results come from the index already on disk and _meta.vex.dev/stale says so (default: false)
project_rootNoAbsolute path to the project root (defaults to the MCP working directory)
exclude_testsNoDrop test files from the results (tests/ dirs, *_test.*, test_*.py, *.spec.ts, __tests__/, tests.rs, ...; same set as tests_for). Composes with include/exclude. Path-based only: Rust unit tests inside a `#[cfg(test)] mod tests` block of a non-test file are not excluded.
no_stale_checkNoSkip the staleness check that runs before each call; assumes the index is fresh. Redundant when `auto_update` is true.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.27.3

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does disclose real behavior: prefix fallback on exact match, index-based resolution, ~4ms latency, and constant-time probing vs. grep's byte scan. It omits that it is a read-only operation and any mention of index staleness/bootstrapping, but the core behavioral profile is well communicated.

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?

Three tight sentences, front-loaded with the core verb+resource and mechanism, then routing guidance. Every sentence earns its place with no redundancy.

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 9-parameter tool with no output schema, the description covers the primary use case and alternatives well; the remaining parameters (include/exclude globs, auto_update, async_update, no_stale_check) are fully covered by the 100% schema. Return values needn't be explained since none are promised.

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 all 9 parameters in detail. The description only reinforces the canonical `symbol` semantics ('exact name with prefix fallback') beyond that, so the 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?

States a specific verb (resolve) and resource (a symbol by exact name) plus scope and mechanism (FST inverted index, ~4ms). It explicitly distinguishes itself from two siblings, search and grep, so an agent can choose without opening the schema.

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?

Gives explicit when-to-prefer conditions: over search 'when the symbol name is known and you want exactly that record back, not a fused-rank list', and over grep for definition-style lookup. It names the alternatives and the conditions that select them.

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