Skip to main content
Glama

Find Code Symbols and Ontology Identifiers

find_symbol
Read-onlyIdempotent

Search the indexed workspace graph for code declarations and architectural entities using exact substring matching or hybrid fuzzy semantic search to locate classes, functions, endpoints, tables, and topics by name.

Instructions

Search the indexed workspace graph for code declarations and architectural entities ('Class', 'Interface', 'Type', 'Function', 'Variable'/'Member', 'Endpoint', 'Table', 'Topic', or 'Project') using deterministic substring matching ('substring') or hybrid trigram and semantic vector similarity ('hybrid'). Use 'substring' when locating symbols by known or partial identifier name, and 'hybrid' for fuzzy or keyword discovery across routes, tables, topics, and code; to list all symbols inside a known file or folder path use get_file_outline, and to read source implementation lines use fetch_code_snippets. Queries .codeexplorer/graph.db case-insensitively (automatically routing 'Endpoint'/'Table'/'Topic'/'Project' filters or matchMode='hybrid' through ranked lexical-vector search and capping output at limit rows), returning YAML matches with kind, qualified name, file_path, and line coordinates (or an empty list if none match).

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": {
      "name": "<name>"
    },
    "name": "find_symbol"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesRequired symbol name, substring, URL route fragment, table name, or domain keyword (e.g. 'OrderController', 'ValidateToken', or '/api/orders').
limitNoMaximum number of matching symbols to return (1 to 500, default: 50; clamped to 200 in 'hybrid' mode).
matchModeNoSearch strategy: 'substring' (exact and substring AST symbol match) or 'hybrid' (fuzzy trigram + semantic vector similarity across code, routes, tables, and topics). Default: 'substring'.substring
symbolTypeNoOptional entity filter: 'Class', 'Interface', 'Type', 'Function', 'Variable', 'Member', 'Endpoint', 'Table', 'Topic', or 'Project' ('Variable' and 'Member' are aliases). Omit to search all kinds.
workspacePathNoOptional absolute path to the target workspace root directory. Omit to use the bound workspace, active client root, or sticky session workspace.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv1.87.4
    • changedInput schema / properties / limit / description
      Previous value: -"Maximum number of matching symbols to return (1 to 500, default: 50)."New value: +"Maximum number of matching symbols to return (1 to 500, default: 50; clamped to 200 in 'hybrid' mode)."
    • addedInput schema / properties / matchMode
      Added value: +{
      +  "default": "substring",
      +  "description": "Search strategy: 'substring' (exact and substring AST symbol match) or 'hybrid' (fuzzy trigram + semantic vector similarity across code, routes, tables, and topics). Default: 'substring'.",
      +  "enum": [
      +    "substring",
      +    "hybrid"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / name / description
      Previous value: -"Required symbol name or case-insensitive substring to match (e.g. 'OrderController' or 'ValidateToken')."New value: +"Required symbol name, substring, URL route fragment, table name, or domain keyword (e.g. 'OrderController', 'ValidateToken', or '/api/orders')."
    • changedInput schema / properties / symbolType / description
      Previous value: -"Optional symbol category filter: 'Class', 'Interface', 'Function', 'Variable', or 'Member' ('Variable' and 'Member' are aliases). Omit to search all symbol kinds."New value: +"Optional entity filter: 'Class', 'Interface', 'Type', 'Function', 'Variable', 'Member', 'Endpoint', 'Table', 'Topic', or 'Project' ('Variable' and 'Member' are aliases). Omit to search all kinds."
    • changedInput schema / properties / symbolType / enum
      Previous value: -[
      -  "Class",
      -  "Interface",
      -  "Function",
      -  "Variable",
      -  "Member"
      -]New value: +[
      +  "Class",
      +  "Interface",
      +  "Type",
      +  "Function",
      +  "Variable",
      +  "Member",
      +  "Endpoint",
      +  "Table",
      +  "Topic",
      +  "Project"
      +]
  2. Changed7 schema fields changedv1.85.1
    • changedInput schema / properties / limit / description
      Previous value: -"Max results (default: 50)."New value: +"Maximum number of matching symbols to return (1 to 500, default: 50)."
    • addedInput schema / properties / limit / maximum
      Added value: +500
    • addedInput schema / properties / limit / minimum
      Added value: +1
    • changedInput schema / properties / name / description
      Previous value: -"Symbol name or partial name."New value: +"Required symbol name or case-insensitive substring to match (e.g. 'OrderController' or 'ValidateToken')."
    • changedInput schema / properties / symbolType / description
      Previous value: -"Optional type: 'Class', 'Interface', 'Function', 'Variable' (or 'Member')."New value: +"Optional symbol category filter: 'Class', 'Interface', 'Function', 'Variable', or 'Member' ('Variable' and 'Member' are aliases). Omit to search all symbol kinds."
    • addedInput schema / properties / symbolType / enum
      Added value: +[
      +  "Class",
      +  "Interface",
      +  "Function",
      +  "Variable",
      +  "Member"
      +]
    • changedInput schema / properties / workspacePath / description
      Previous value: -"Optional workspace root path."New value: +"Optional absolute path to the target workspace root directory. Omit to use the bound workspace, active client root, or sticky session workspace."
  3. Changed1 schema field changedv1.85.0
    • changedInput schema / properties / symbolType / description
      Previous value: -"Optional type: 'Class', 'Interface', 'Function', 'Variable'."New value: +"Optional type: 'Class', 'Interface', 'Function', 'Variable' (or 'Member')."
  4. First observedv1.80.5

TDQS

A4.7/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, closed-world), and the description still adds real behavior: case-insensitive querying, automatic routing of Endpoint/Table/Topic/Project filters or hybrid mode through ranked lexical-vector search, row capping, and a described YAML return shape (kind, qualified name, file_path, line coordinates) or empty list. Minor redundancy with the schema on the limit clamp keeps it off a 5.

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?

Dense but every clause earns its place: purpose first, then mode selection, then alternative routing, then execution/return semantics. Parenthetical lists are the only slight drag on 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 exists, yet the description specifies the return format, the empty-match case, and the row cap, so an agent can consume results without further documentation. For a 5-parameter read tool this is complete.

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 semantics the schema does not: which matchMode suits which intent, and that certain symbolType filters (Endpoint/Table/Topic/Project) and hybrid mode are silently rerouted through a different ranked search path. workspacePath is left to the schema, which is acceptable given full coverage.

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 ('Search the indexed workspace graph for code declarations and architectural entities') and enumerates the exact entity kinds covered. It also distinguishes itself from siblings by name: get_file_outline for listing symbols within a known path and fetch_code_snippets for reading source lines.

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 selection rules: 'substring' when locating symbols by known or partial identifier name, 'hybrid' for fuzzy or keyword discovery across routes, tables, topics, and code. It also names two alternatives (get_file_outline, fetch_code_snippets) with 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.