Skip to main content
Glama

revise_memory

Supersede an existing entry with a revised one (supersession, not mutation). Creates a NEW entry carrying metadata.supersedes=<target_id> and marks the target with superseded_by and superseded_at.

Instructions

Supersede an existing entry with a revised one (supersession, not mutation). Creates a NEW entry carrying metadata.supersedes=<target_id> and marks the target with superseded_by and superseded_at. The old entry stays readable: it is not hidden and is_live is not cleared. Recall, query_layer and semantic_recall return it marked with that end date and the id of the new entry. The current entry is listed first. Episodic revision is prohibited - events are immutable.

Input Schema

NameRequiredDescriptionDefault
layerYesLayer of the entry being revised (episodic is prohibited)
contentYesFull revised content - must stand alone without the superseded entry
exchangeNoThe exchange (turn) this write belongs to, counting from 1. A write for exchange n while exchange n-1 was never appended is refused by the session graph until n-1 is appended.
metadataNoMetadata for the new entry (supersedes is set automatically; include source tag)
target_idYesID of the entry this revision supersedes
session_idNoYour transcript session id from emet_session_open. The session graph reads this session's state before the write and returns `session_graph.next` - the next step. A governed write with no session is refused (open one with emet_session_open and load_id).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.2.2
    • changedInput schema / properties / exchange / description
      Previous value: -"The exchange (turn) this write belongs to, counting from 1. A write for exchange n while exchange n-1 was never appended is flagged by the session graph."New value: +"The exchange (turn) this write belongs to, counting from 1. A write for exchange n while exchange n-1 was never appended is refused by the session graph until n-1 is appended."
    • changedInput schema / properties / session_id / description
      Previous value: -"Your transcript session id from emet_session_open. The session graph reads this session's state before the write and returns `session_graph.next` - the next step."New value: +"Your transcript session id from emet_session_open. The session graph reads this session's state before the write and returns `session_graph.next` - the next step. A governed write with no session is refused (open one with emet_session_open and load_id)."
  2. First observedv0.1.0

TDQS

A4.4/5.0
Behavior5/5

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

Goes well beyond the annotations by disclosing the exact side effects: a NEW entry is created rather than the target being mutated, the target is marked with superseded_by/superseded_at, and crucially the old entry stays readable (not hidden, is_live not cleared). It also explains how recall/query_layer/semantic_recall surface the superseded entry, which is non-obvious behavior an agent needs.

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?

Front-loads the most decision-relevant fact (supersession, not mutation) and each following sentence carries distinct behavioral information. It is dense rather than padded, though the trailing sentence about ordering ('The current entry is listed first') sits slightly oddly at the end.

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?

For a 6-parameter, nested-object write tool with no output schema, the description covers the mutation model, the after-state of both entries, downstream read behavior, and the layer restriction. Nothing essential for correct invocation appears to be 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 description coverage is 100%, so the baseline is 3 and the schema already documents layer, content, exchange, metadata, target_id and session_id semantics. The description restates that metadata.supersedes is set automatically, which largely duplicates the schema text rather than adding format or value guidance.

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 ('Supersede an existing entry with a revised one') and immediately draws the key distinction 'supersession, not mutation', which separates it from the mutation-style siblings. It then specifies the concrete mechanism (new entry with metadata.supersedes=<target_id>, target marked with superseded_by/superseded_at).

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 a clear negative constraint ('Episodic revision is prohibited - events are immutable') which routes the agent away from episodic-layer targets. However, it never explicitly contrasts with siblings like save_to_layer or revise_transcript, so the agent must infer when supersession is preferred over a plain write.

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