Skip to main content
Glama

Apply Patch

apply_patch

Apply IDB byte patches to a copied input file and export the patched result. Use when persisting IDA Pro patch changes without altering the original binary.

Instructions

Apply IDB byte patches to a copied input file and export it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
timeoutNoTimeout in seconds
overwriteNoOverwrite output_path if it already exists
instance_idNoInstance id override
output_pathNoOutput file path. Defaults to '<input>.patched<ext>'; relative paths are resolved next to the input file.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.9.7

TDQS

C2.9/5.0
Behavior2/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 hints at a copy-then-export flow, but never says whether the open IDB is modified, whether the input file on disk is touched, whether existing output is clobbered (the overwrite parameter implies risk but the description is silent), or what permissions/state are required. For a file-writing mutation tool with zero annotation coverage this is a significant gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single efficient sentence with no filler and the core action front-loaded. It is perhaps too compressed for a file-mutating operation, but there is no wasted wording.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With four optional parameters, no annotations, and no output schema, the description should explain the copy/export lifecycle, what happens on failure or existing output, and how it relates to patch_bytes. Almost none of that is present, leaving the agent to guess at a mutating, disk-writing operation.

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%, so every parameter (timeout, overwrite, instance_id, output_path) is already documented in the schema and the baseline of 3 applies. The description adds only the vague 'copied input file' hint and nothing about parameter behavior beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (Apply), a specific resource (IDB byte patches), and a distinct effect (to a copied input file, then export). That is clearer than a tautology, but it never distinguishes itself from the sibling tools patch_bytes and patch_asm, which sound like they also apply patches — an agent cannot tell from this sentence which of the three to pick.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no guidance on when to use this rather than patch_bytes/patch_asm, no stated prerequisites (does the IDB need to be open or saved first? must patches already exist?), and no note on when not to use it. The agent must infer the offline-copy workflow from a single clause.

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