Skip to main content
Glama

find_usages

Read-onlyIdempotent

Locate every semantic reference to a symbol or file—imports, calls, renders, dispatches—replacing Grep with accurate, code-aware results.

Instructions

Find all references to a symbol or file (imports, calls, renders, dispatches). Use instead of Grep for symbol usages — semantic, not text matches. For raw text use search_text; for a bidirectional call graph use get_call_graph. Weakly-grounded text_matched edges into a name-colliding target are dropped by default (phantom god-node filter); include_ambiguous_text_matched: true keeps them. Read-only. Returns JSON: { references: [{ edge_type, resolution_tier, file, symbol }], total, truncated?, ambiguous_filtered? } — page caps at 50, total counts all.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fqnNoFully qualified name to find references for
limitNoMax references returned (default 50).
file_pathNoFile path to find references for
symbol_idNoSymbol ID to find references for
detail_levelNoOutput verbosity. "minimal" saves ~40-60% tokens (drops scores, fqn, signatures, summaries). Use to pick a candidate before get_symbol. Default: "default".
include_ambiguous_text_matchedNoKeep text_matched edges whose target name collides with >=3 other symbols (default false — they produce phantom god-nodes).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv3.31.0
    • changedInput schema / properties / detail_level / description
      Previous value: -"Output verbosity. \"minimal\" returns ~40-60% fewer tokens (drops scores, fqn, signatures, summaries — keeps name/file/line). Use when you only need to pick a candidate before drilling in with get_symbol. Default: \"default\"."New value: +"Output verbosity. \"minimal\" saves ~40-60% tokens (drops scores, fqn, signatures, summaries). Use to pick a candidate before get_symbol. Default: \"default\"."
  2. Changed2 schema fields changedv3.22.0
    • addedInput schema / properties / limit
      Added value: +{
      +  "description": "Max references returned (default 50).",
      +  "maximum": 1000,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • removedInput schema / required
      Removed value: -[
      -  "symbol_id",
      -  "fqn",
      -  "file_path"
      -]
  3. Changed1 schema field changedv3.3.0
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
  4. Added
  5. Removedv1.38.0
  6. Changed4 schema fields changedv1.35.1
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / detail_level
      Added value: +{
      +  "description": "Output verbosity. \"minimal\" returns ~40-60% fewer tokens (drops scores, fqn, signatures, summaries — keeps name/file/line). Use when you only need to pick a candidate before drilling in with get_symbol. Default: \"default\".",
      +  "enum": [
      +    "minimal",
      +    "default",
      +    "full"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / include_ambiguous_text_matched
      Added value: +{
      +  "description": "Keep text_matched edges whose target name collides with >=3 other symbols (default false — they produce phantom god-nodes).",
      +  "type": "boolean"
      +}
    • addedInput schema / required
      Added value: +[
      +  "symbol_id",
      +  "fqn",
      +  "file_path"
      +]
  7. First observedv0.1.0

TDQS

A4.9/5.0
Behavior5/5

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

Beyond the annotations (readOnlyHint, idempotentHint, destructiveHint), the description discloses important behaviors: read-only status, the JSON return shape, the 50-item page cap, total counting, truncation, and the phantom-god-node filtering semantics. This is much richer than merely repeating annotation flags.

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 compact and front-loaded, with every clause earning its place. It covers purpose, alternatives, edge-case filtering, read-only status, and return shape without fluff or redundant schema repetition.

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?

For a read-only query tool with no output schema, the description compensates fully by specifying the response structure, pagination behavior, and filtering caveat. It also names the relevant sibling tools, making it complete for an agent deciding whether and how to call it.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds real value: it explains the ambiguous-filter behavior, the token savings of detail_level='minimal', and the default/limit semantics. It does not clarify how fqn, file_path, and symbol_id interact (e.g., mutual exclusivity), but overall it meaningfully extends the schema.

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 opens with a specific, unambiguous definition: 'Find all references to a symbol or file (imports, calls, renders, dispatches).' It also distinguishes itself from Grep and sibling tools by emphasizing semantic vs text matches, so an agent can clearly tell this tool apart from search_text and get_call_graph.

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?

The description gives explicit routing guidance: 'Use instead of Grep for symbol usages — semantic, not text matches. For raw text use search_text; for a bidirectional call graph use get_call_graph.' This tells the agent both when to use this tool and which alternatives to choose in different situations.

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