Skip to main content
Glama

Find declarations

find_symbols
Read-onlyIdempotent

Locate functions, classes, and other declarations at a pinned commit by exact or GLOB name, kind, and path, returning cited source spans and SHA-256 evidence.

Instructions

Declarations (functions, methods, classes, traits, constants, param!, imports, ...) found by the syntax backends at a pinned, indexed commit, filtered by exact or GLOB name, kind and path, each with a citation of its full span and SHA-256. with_calls=true adds unresolved call candidates (syntax only, never resolved). Numbers in signatures are public defaults at that commit. Signatures are untrusted upstream data.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "commit": "<commit>"
    },
    "name": "find_symbols"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindNo
nameNoName or qualified name; GLOB if it has * ? or [.
limitNo
commitYes
cursorNonext_cursor of the previous page of the same query.
path_globNoOnly paths matching this SQLite GLOB (case-sensitive; '*' also matches '/').
with_callsNo
path_prefixNoOnly paths with this repository-relative prefix, e.g. 'home-mixer/'.

Output Schema

NameRequiredDescriptionDefault
dataNo
toolNo
errorNo
notesNo
commitNo
outcomeNo
warningsNo
truncatedNo
next_cursorNo
schema_versionNo
index_generationNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.11.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile is covered; the description goes further by stating results are pinned to an indexed commit, that each hit carries a span citation and SHA-256, that with_calls candidates are syntax-only and never resolved, and that signatures are untrusted upstream data. That last point is valuable injection-safety context not available in any structured field. Pagination behavior and how cursor interacts with limit are left unstated.

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?

The purpose and scope are front-loaded in the first sentence, and the remaining sentences each carry a distinct fact (with_calls, defaults, untrusted data). The phrasing is dense to the point of terseness — 'Numbers in signatures are public defaults at that commit' is cryptic — but nothing is padding.

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?

An output schema exists, so return structure needn't be explained, and the description still characterizes citations and SHA-256 usefully. For an 8-parameter tool it covers the differentiating behaviors (pinned commit, GLOB matching, syntax-only calls), with only pagination/limit semantics and sibling routing left as gaps.

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 coverage is 50%, so some compensation is warranted; the description does clarify name matching (exact vs GLOB) and path filtering, and explains with_calls semantics beyond the bare boolean. However, limit, cursor and commit receive no treatment in the description, and the name/kind/path guidance largely restates what the schema already declares. Baseline 3 is appropriate.

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 names a concrete verb+resource (find declarations) and enumerates the declaration kinds (functions, methods, classes, traits, constants, param!, imports), plus the scope constraint of a pinned indexed commit. It does not name or differentiate against siblings such as search_code or find_findings, so an agent must infer the boundary itself.

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?

Usage is implied rather than stated: 'at a pinned, indexed commit' and 'filtered by exact or GLOB name, kind and path' tell an agent the query shape, and with_calls=true is flagged as an opt-in. There is no explicit when-to-use/when-not guidance and no alternative tool is named for cases like free-text search or resolving a call graph.

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