Skip to main content
Glama

apply_agent_run

Merge an agent's isolated worktree changes back into the main branch to finalize delegated task outcomes.

Instructions

Merge the changes from the agent's worktree back into the main branch.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
worker_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

With no annotations, the description must fully disclose the tool's behavior. It only states that the merge happens, but does not mention potential side effects like whether the worktree is deleted, if the merge is destructive, or how conflicts are handled. The mutation is implied but its consequences are not disclosed.

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 a single sentence that is direct and front-loaded. It contains no unnecessary words or filler, making it highly concise.

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

Completeness3/5

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

For a tool with only one parameter and an output schema, the description is minimal but functional. However, it lacks usage context and behavioral details that would make it complete, such as when to apply the run and what happens to the worktree afterward.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema has 0% description coverage for 'worker_id', and the description does not explicitly explain it. Although the phrase 'agent's worktree' indirectly suggests worker_id identifies the agent run, the description adds no concrete meaning beyond the parameter name itself.

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's purpose with a specific verb ('Merge') and identifies the resource ('agent's worktree') and target ('main branch'). This effectively distinguishes it from sibling tools like continue_agent_run or cleanup_agent_run, which have different actions.

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?

No guidance is provided on when to use this tool versus alternatives. It doesn't mention any prerequisites (e.g., after an agent run completes) or contrast with 'continue_agent_run' or 'cleanup_agent_run'. The usage context is entirely implicit.

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/psychofanPLAYS/gemini4codex-mcp'

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