Skip to main content
Glama

decompile_function

Convert a named function into C pseudocode for reverse engineering. If the function name is ambiguous, switch to the address-based alternative.

Instructions

Decompile a function by name and return C pseudocode. Fails if the name is ambiguous; use decompile_function_by_address in that case.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

A4/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It usefully discloses a failure mode (ambiguous names fail rather than guess), which is real behavioral context. It says nothing about permissions, performance, or read-only nature, though for a decompile operation those are lower-stakes.

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?

Two tight sentences, front-loaded with purpose and followed by the failure/alternative clause. Every sentence earns its place with zero 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 values needn't be described. For a simple one-parameter read tool, the description covers what it does, what it returns, and how it fails — only the general name-vs-address selection heuristic is missing.

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?

The single 'name' parameter has 0% schema description coverage, but the description implies its meaning ('decompile a function by name') and its constraint (must be unambiguous). That compensates partially, though it doesn't say whether the name is fully qualified, case-sensitive, or namespace-aware.

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 (decompile), resource (function), input selector (by name) and output format (C pseudocode). It also names the sibling it is not — decompile_function_by_address — so an agent can distinguish it without opening schemas.

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?

Explicitly covers the when-not case and the alternative: 'Fails if the name is ambiguous; use decompile_function_by_address in that case.' Clear context is given, but it doesn't state the general condition for preferring name-based lookup (e.g. when you already have a symbol) versus address-based lookup.

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