Skip to main content
Glama

rollback_feature

Restore files changed by a feature worker to their pre-worker state using Git snapshot branches, optionally targeting only specific files.

Instructions

Roll back files changed by a feature worker to their pre-worker state using git. Each worker creates a snapshot branch before starting that can be used for rollback.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "projectDir": "<projectDir>",
      "featureId": "<featureId>"
    },
    "name": "rollback_feature"
  }
}

Input Schema

NameRequiredDescriptionDefault
filesNoSpecific files to rollback. If not provided, all files changed by the worker will be rolled back.
featureIdYesID of the feature to rollback
projectDirYesAbsolute path to the project directory

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.1/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden. It discloses the underlying mechanism (a snapshot branch created before the worker starts), which is genuinely useful, but never states whether the rollback is itself reversible, whether uncommitted work is discarded, whether the snapshot branch is cleaned up, or what permissions/state the project must be in. For a destructive git mutation that 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.

Conciseness5/5

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

Two tight sentences, with the action and scope front-loaded and the mechanism as supporting detail. Nothing is redundant or padded.

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?

The description covers what the tool does and how the rollback is possible, which is enough to attempt a call on a simple destructive tool. With no annotations and no output schema, however, it should also state failure modes and data-loss implications, which are absent.

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%, so projectDir, featureId and files are already documented in the schema, and the description adds only the scoping notion of "files changed by the worker". That is a marginal addition over the existing parameter descriptions, so the baseline of 3 applies.

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?

The description names a specific verb and resource ("Roll back files changed by a feature worker") and states the target state ("pre-worker state") and mechanism (git). It does not, however, distinguish itself from the sibling check_rollback_conflicts, so an agent cannot fully rule out overlap from the text alone.

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 explicit when-to-use or when-not-to-use guidance, no mention of the sibling check_rollback_conflicts as a prerequisite or alternative, and no stated preconditions (clean working tree, completed worker, etc.). The sentence about snapshot branches explains the mechanism rather than telling the agent when to invoke the tool.

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