Skip to main content
Glama

Restore an entry

memory_restore
Idempotent

Restore an archived entry so it appears in normal reads and search again; reverses archiving and logs your reason.

Instructions

Restore one archived entry so it appears again in normal reads and search. The inverse of memory_archive.

Find archived entries with memory_list(archived=true). The restore is logged in memory_events with your reason. Returns {"ok": true} if the entry is now active (also when it was not archived), {"ok": false} if no entry has that scope and name, or {"ok": false, "error": ...} when the reason is empty. Not available on read-only connections.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesEntry name: the short kebab-case slug that identifies the entry within its scope.
scopeYesProject/topic scope the entry belongs to, e.g. a project folder name (list them with memory_scopes). On a scope-locked connection (--scope), this argument is ignored and the connection's own scope is used.
reasonYesWhy you are doing this, in a few words. Required and must not be empty; stored in the audit log (memory_events).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.2.0
    • addedInput schema / properties / name / description
      Added value: +"Entry name: the short kebab-case slug that identifies the entry within its scope."
    • addedInput schema / properties / reason / description
      Added value: +"Why you are doing this, in a few words. Required and must not be empty; stored in the audit log (memory_events)."
    • addedInput schema / properties / scope / description
      Added value: +"Project/topic scope the entry belongs to, e.g. a project folder name (list them with memory_scopes). On a scope-locked connection (--scope), this argument is ignored and the connection's own scope is used."
  2. First observedv0.1.0

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already declare the safety profile (readOnlyHint=false, idempotentHint=true, destructiveHint=false), yet the description goes further by disclosing audit logging into memory_events with the supplied reason, the read-only-connection restriction, and all three response shapes with their trigger conditions. It clarifies idempotency in practice ("also when it was not archived"), which the annotation only signals abstractly.

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?

The effect is front-loaded in the first sentence, the relationship to memory_archive comes second, and follow-up sentences are short and single-purpose. Dense with information but free of filler or repeated annotation content.

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 takes responsibility for return values and does so fully (success, not-archived, missing entry, empty reason). Combined with the discovery workflow and connection restriction, nothing an agent needs to call this correctly is absent.

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 100%, so the baseline is 3; however, the description adds consequences the schema does not, namely that an empty reason yields {"ok": false, "error": ...} and that scope/name misses yield {"ok": false}. It does not restate the kebab-case or scope-locked-connection details, so the gain is modest but real.

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 ("Restore one archived entry") plus the observable effect ("appears again in normal reads and search"), and explicitly frames itself as "The inverse of memory_archive." An agent can distinguish it from memory_archive and memory_list 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 Guidelines5/5

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

Names the prerequisite discovery path ("Find archived entries with memory_list(archived=true)") and the environment precondition ("Not available on read-only connections"), which is exactly the context an agent needs before attempting the call. It also covers the no-op case so the agent does not misread a successful restore of a non-archived entry as failure.

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