Skip to main content
Glama

Revert one block

geml_revert
Destructive

Revert one block to a previous version while leaving every other block unchanged, so you can fix a bad edit without losing surrounding good changes.

Instructions

Undo ONE block, leaving every other block byte-for-byte unchanged — recover a single block after a bad edit without losing the good edits around it. rev defaults to undoing this block's LAST change (its previous distinct version), which holds even when other blocks were edited afterwards; or pass 0 for the tip, a -N offset, or a revision id from geml_history. Reverting across a revision where the block was deleted restores it; across one where it did not exist removes it. A rev that matches no revision, or a document with no history yet, is refused. Returns {ok, file, diagnostics, revision}, with notes when the write did something to say out loud (a block it dropped, an address it changed); a refusal is ok: false with a hint, and the file is unchanged.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesBlock id to revert
revNoRevision selector: 0 (the tip) | -N (N revisions back) | id prefix. Omit to undo this block's last change (robust to edits of other blocks since).
fileYesDocument path relative to the server's --root directory, e.g. notes/spec.geml

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations disclose only destructive/not-idempotent; the description adds the edge-case semantics that matter — reverting across a deletion restores the block, across nonexistence removes it — plus the refusal behavior (ok:false with hint, file unchanged) and the return shape including `notes` for consequential side effects.

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 dense paragraph, front-loaded with the purpose and scope guarantee before the parameter and return details. Slightly long, but nearly every clause carries distinct semantic information (default rev, edge cases, refusal, return shape) rather than padding.

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

Completeness5/5

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

With no output schema, the description fully documents the return contract ({ok, file, diagnostics, revision}, optional notes, refusal with hint) and the mutation's edge-case outcomes. Nothing an agent needs to call this correctly is missing.

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?

Schema coverage is already 100%, but the description still adds value by spelling out the default-rev robustness semantics ('undo this block's LAST change... holds even when other blocks were edited afterwards') and the meaning of each selector form. It largely mirrors the schema text, so it earns an above-baseline but not maximal score.

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 (undo/revert) and resource (one block) plus a precise scope guarantee — 'leaving every other block byte-for-byte unchanged' — that immediately distinguishes it from geml_set, geml_delete, and geml_history. An agent can tell what this does and what it deliberately does not touch.

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

Usage Guidelines5/5

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

Gives the motivating scenario (recover a single block after a bad edit without losing surrounding edits), explains the default `rev` behavior and why it is robust to other blocks being edited, and enumerates the alternative selectors (0 tip, -N, revision id from geml_history). It also names the two conditions under which the tool refuses.

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