Skip to main content
Glama

undo

Revert the project to just before its last change—whether a person, agent, or outside edit made it—and record the reversal as a commit so it can be redone. Run again to step further back.

Instructions

Take back the last change to the project, whoever made it (the person, an agent, an edit outside MOGA): its files go back to just before it. Recorded as a commit, so redo puts it back. Undo again takes back the one before.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "undo"
  }
}

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare non-read-only, non-destructive, non-idempotent behavior; the description earns credit by explaining why nothing is lost — the undo is itself recorded as a commit, so redo restores it. It also discloses scope (it applies to changes by anyone, including out-of-band edits), which the annotations cannot convey. It leaves out edge cases such as what happens when there is nothing left to undo.

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?

Three short sentences, each doing distinct work: what is undone and for whom, that it is reversible via redo, and the repeat behavior. Front-loaded and free of filler.

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?

With no output schema and no parameters, the description covers what an agent needs to call it: scope, reversibility, and repeat semantics. Minor gaps remain around failure modes (empty history) and whether uncommitted working state is affected.

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

Parameters4/5

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

The tool takes zero parameters, so the schema carries no semantics to supplement; baseline applies. The description correctly implies the operation is parameterless and targets only 'the last change'.

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 — 'take back the last change to the project' — and immediately scopes it to any author (person, agent, or an edit outside MOGA). An agent can tell this apart from a redo or a commit-history tool without opening any 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 clear operating context: it undoes the most recent change, repeating it walks further back one change at a time, and redo is the inverse. It doesn't state exclusions or alternatives explicitly (e.g. what to use to selectively revert a specific older change), so it stops short of a full when/when-not rubric.

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

Deploy Server

Other Tools