Skip to main content
Glama

search_symbols

Read-only

Find code symbols by name, word match, or path, returning file:line, kind, and signature without bodies. Filter by kind or directory to locate definitions in Java and Python repositories.

Instructions

Find symbols by name: 'save', 'Order.add', or words ('get user' finds get_user_by_id). Returns file:line, kind, signature; no bodies. Ranked exact name, then word match; non-test first. kind: class|interface|enum|record|annotation|method|constructor|function|field. path: only in this dir, file or package ('model/', 'com.x.model'); with query '' it lists what path defines, types first. <= 1500 tokens.

Input Schema

NameRequiredDescriptionDefault
kindNo
pathNo
limitNo
queryYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

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

With only readOnlyHint provided, the description carries most of the burden and does so: return shape (file:line, kind, signature, no bodies), ranking rules (exact name then word match, non-test first), and a hard output cap ('<= 1500 tokens'). These are behaviors an agent cannot get from the annotation or the bare schema.

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?

Front-loaded with the core action and packed with dense, useful detail in a handful of sentences. The inline kind enumeration is long but functional; nothing is padded, though the terse shorthand costs some readability.

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 and no param descriptions exist, yet the description covers return format, ranking, scoping, the empty-query mode, and truncation. Nothing an agent needs to call or interpret this tool is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must compensate and does: it enumerates valid kind values, defines path semantics including the empty-query listing mode ('types first'), and illustrates query matching. Only limit is left to its schema default, which is minor.

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+resource ('Find symbols by name') and immediately disambiguates from the get_symbol sibling by showing query forms ('save', 'Order.add', 'get user'). An agent can tell it is a ranked search over an index rather than a by-id fetch.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

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

Gives concrete usage context: query syntax with word-matching, path scoping ('only in this dir, file or package'), and the special query '' behavior. It never names when to prefer get_symbol or find_references instead, so routing to alternatives is left to inference.

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