Skip to main content
Glama

Compare with a Saved Snapshot

compare_with_previous
Read-onlyIdempotent

Diff the current session against a previously saved snapshot of the same solution to find added/removed types and methods, optionally narrowed to one type or method.

Instructions

Diff the current session against a previously saved snapshot of the SAME solution - the newest by default, or the N-th previous via snapshotsBack (0=newest saved, 1=the one before, ...). Optionally narrow the diff to a single type and/or method. Returns added/removed types plus, per changed type, added/removed methods and signature changes. Requires a sessionId and at least one earlier save_session; dbPath is optional and defaults to the server's standard config DB when omitted. Name-based, syntactic (no method-body diff).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dbPathNoOptional absolute path to the aicb SQLite DB holding the saved snapshots. Omit to use the server's standard config DB.
typeNameNoOptional: restrict the diff to this type (simple name, case-insensitive). Omit for the whole-solution diff. A simple name ALSO matches the namespace-qualified form the diff renders for a type whose simple name collides in the solution - then the answer spans every type of that name and 'note' says which; pass one of those qualified names to narrow to a single type. Not a substring match: 'MyApi' never matches 'MyApiExtensions'. When a filter EMPTIES a diff that did have changes, 'note' says so and names the axis that missed, because 'isIdentical: true' then describes the filtered view and not the solution. On a diff that was ALREADY empty there is no note and none is owed: 'your filter matched nothing' and 'nothing changed' are the same state there, so a typo'd name and a real one answer identically - check the spelling with find_symbol rather than reading that agreement as confirmation.
sessionIdYesThe current session_id (the 'after' side of the diff). Also takes an absolute .sln/.slnx/.slnf path, analyzed on first use.
methodNameNoOptional: within that type, restrict to this method name (case-insensitive). Omit for all methods of the type. Same disclosure rule as typeName: if the type matched and this name matches none of its added/removed/signature-changed methods, the type is dropped from the answer and 'note' says which of the two filters came up empty - an empty view here is never evidence that the method is unchanged.
snapshotsBackNo0 = newest saved snapshot, 1 = the one before it, etc. (index into the per-solution history, newest first).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.5.46513
    • changedInput schema / properties / sessionId / description
      Previous value: -"The current session_id (the 'after' side of the diff)."New value: +"The current session_id (the 'after' side of the diff). Also takes an absolute .sln/.slnx/.slnf path, analyzed on first use."
  2. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Annotations already cover the safety profile (readOnly/idempotent/non-destructive/openWorld=false), and the description adds real behavioral detail on top: the exact return shape (added/removed types, per-type added/removed methods and signature changes), the dbPath default, and the important limitation that the diff is name-based and syntactic with no method-body diff.

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 that front-loads the core purpose before defaults, filtering, return shape and the syntactic-only caveat. Every sentence contributes, though the block is information-heavy and could be more scannable.

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 present, the description carries the full burden and does so by enumerating the returned structure and the syntactic-only scope. It also covers the optional dbPath default and prerequisite, so nothing needed to call it correctly is missing.

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% and its parameter descriptions are already highly detailed (snapshotsBack indexing, typeName/methodName disclosure rules), so the schema does the heavy lifting. The description adds the cross-parameter constraint that an earlier save_session must exist, but otherwise largely restates what the schema documents.

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 (diff) and both operands (current session vs. a previously saved snapshot of the SAME solution), which cleanly separates it from save_session and other siblings. The scope of what is compared is unambiguous.

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 the concrete prerequisite ('Requires a sessionId and at least one earlier save_session') and the default behavior (newest snapshot, or N-th via snapshotsBack), plus a redirect to find_symbol for spelling checks. It stops short of explicitly naming alternative tools or when-not-to-use cases, so it is clear but not fully routing.

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