Skip to main content
Glama

driftguard_preview_rollback

Preview a rollback by showing a detailed line-by-line diff of changes, restorations, or deletions before applying a workspace snapshot.

Instructions

Mostra un diff dettagliato riga per riga di ciò che cambierà, verrà ripristinato o cancellato PRIMA di eseguire il rollback effettivo.

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": "driftguard_preview_rollback"
  }
}

Input Schema

NameRequiredDescriptionDefault
snapshotIdNoID dello snapshot da confrontare. Se omesso, usa il più recente.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv2.0.0

TDQS

A4/5.0
Behavior4/5

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

With no annotations, the description carries the full disclosure burden and does it reasonably well: the capitalized 'PRIMA' makes clear this is a non-mutating inspection step and that nothing is applied yet, and it names the three outcome categories the diff can contain. It does not say what happens when a snapshot is absent or how the diff is returned, which are minor gaps given no output schema exists.

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?

A single dense sentence with no filler, front-loading both what is produced and the critical timing constraint. Every clause (what changes, what is restored, what is deleted) contributes distinct information.

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?

For a one-optional-parameter preview tool with no annotations and no output schema, the description covers purpose, timing, and the nature of the output, which is sufficient to call it correctly. It stops short of stating that snapshots must exist or how a missing snapshot is handled.

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%, and the single optional snapshotId parameter is already documented in the schema, including its fallback to the most recent snapshot. The description adds no additional meaning about the parameter, 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?

States a specific verb+resource ('diff dettagliato riga per riga' of a rollback preview) and explicitly scopes it as occurring BEFORE the real rollback, which implicitly separates it from driftguard_rollback. It never names that sibling outright, so the differentiation is inferred rather than stated.

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?

The usage context is explicit: run this before executing the actual rollback so you can inspect changes, restorations and deletions. It gives no when-not guidance and does not address the overlapping siblings driftguard_dry_run_command or driftguard_selective_rollback, leaving some ambiguity about which preview-style tool to pick.

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