Skip to main content
Glama

decompile

Read-only

Converts one function at a given address into pseudo-C, including locals, arguments, warnings, and unmodeled assembly, so you can inspect its logic.

Instructions

Decompile one function to pseudo-C. Locals are local_N/arg_N (N hex bytes below the entry sp: higher N, lower address); /* asm */ marks unmodeled code. Line 2 says what was checked, // warn: what is wrong. Not for a first look (use function_summary).

Input Schema

NameRequiredDescriptionDefault
limitNoReturn at most this many lines (default 300; more than the text has for all).
detailNo`skeleton` for flow and calls only; `full` or absent for all of it.
filterNoKeep only lines containing this text, case-insensitively.
offsetNoSkip this many lines of the answer.
addressYesFunction entry or any address inside it.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.1

TDQS

A4.2/5.0
Behavior4/5

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

With readOnlyHint and openWorldHint already covering the safety profile, the description instead spends its words on non-obvious output semantics: local_N/arg_N naming with hex byte offsets, /* asm */ for unmodeled code, line 2 as a check summary, and // warn: for problems. It does not mention failure modes (e.g., functions that cannot be decompiled) or output size expectations, which keeps it just short of the top score.

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?

Four tight sentences, front-loaded with what the tool does, then the decoding conventions an agent needs to read the output. Nothing is redundant with the schema or annotations.

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?

There is no output schema, so the description carries the burden of explaining the returned text, and it largely does via the naming scheme and marker conventions. What's missing is only edge-case behavior, such as what a failed or partial decompilation looks like, which is a minor gap for a read-only single-function tool.

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 description coverage is 100% and all five parameters (address, limit, detail, filter, offset) are already documented in the schema, so the baseline of 3 applies. The description adds no parameter-level guidance such as when to prefer skeleton over full or how filter interacts with limit.

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 and resource ("Decompile one function to pseudo-C") with an explicit unit-of-work (one function). The closing clause distinguishing it from function_summary lets an agent separate it from the summary sibling without opening either schema.

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?

Gives an explicit exclusion and a named alternative: "Not for a first look (use function_summary)." The positive trigger is only implied by "one function," and alternatives like disassemble_function or decompile_batch for multiple functions are not mentioned, so routing is clear but not exhaustive.

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