Skip to main content
Glama

explain_symbol

Get a plain-English explanation of a C/C++ symbol's purpose using its name, signature, docstring, and call context.

Instructions

Read-only. No side effects — may call Ollama (optional external LLM) if configured. Returns a plain-English explanation of what a C/C++ symbol does, based on its name, signature, docstring, and call context. Requires Ollama to be running. For raw source code use get_source; for symbol metadata without explanation use lookup_symbol; for body+callers+callees use get_symbol_context.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesSymbol name to explain. E.g. 'uart_init', 'ModemMsg::send'.
project_rootNoProject root. Auto-detected if omitted.
context_linesNoLines of source context around the symbol definition.
Behavior5/5

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

Despite no annotations, the description fully discloses behavior: read-only, no side effects, may call an optional external LLM (Ollama) if configured, and requires Ollama to be running. No contradictions.

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 three sentences, each serving a distinct purpose: declare safety/side effects, state function and inputs, provide usage guidance and alternatives. No wasted words.

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 tool with no output schema and 3 parameters, the description covers purpose, behavior, prerequisites, and sibling differentiation well. It lacks details about the format or extent of the explanation output, but overall is quite complete.

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 100% and schema descriptions are already detailed. The description adds little new information beyond what the schema provides for each parameter. However, it does reinforce the purpose of context_lines by tying it to the amount of source context provided to the explanation.

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 clearly states the tool returns a plain-English explanation of what a C/C++ symbol does, based on its name, signature, docstring, and call context. It distinguishes from sibling tools like get_source, lookup_symbol, and get_symbol_context.

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 explicitly says when to use this tool (for explanations of symbols) and when not (for raw source use get_source; for metadata without explanation use lookup_symbol; for body+callers+callees use get_symbol_context). It also notes the dependency on Ollama being running.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/turbyho/fw-context-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server