Skip to main content
Glama

save_memory

Saves persistent context notes, architectural decisions, task handoffs, or lessons to a local or global Memory Vault, masking secrets and isolating directories for reliable agent handoffs.

Instructions

Saves a persistent context note, architectural decision, task handoff, or lesson
into the workspace or global shared Memory Vault.
Masks secrets and provides directory isolation.

Args:
    title: Short descriptive title of the memory entry.
    content: Detailed markdown notes, architectural rationale, or handoff context.
    workspace_dir: Workspace root directory. Empty = engine.default_workspace
           from the config, else the server's current directory.
    kind: Entry category ('context' | 'decision' | 'handoff' | 'lesson').
    tags: Optional list of keyword tags for filtering and discovery.
    memory_id: Optional custom identifier (alphanumeric/hyphen/underscore). Auto-generated if omitted.
    scope: Storage scope ('local' for workspace, 'global' for cross-workspace). Default is 'local'.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "title": "<title>",
      "content": "<content>"
    },
    "name": "save_memory"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindNocontext
tagsNo
scopeNolocal
titleYes
contentYes
memory_idNo
workspace_dirNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.1.2
    • addedInput schema / properties / scope
      Added value: +{
      +  "default": "local",
      +  "title": "Scope",
      +  "type": "string"
      +}
  2. Changed1 schema field changedv1.1.1
    • changedInput schema / properties / workspace_dir / default
      Previous value: -"."New value: +""
  3. First observedv1.0.0

TDQS

A3.9/5.0
Behavior3/5

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

With no annotations, the description carries the full burden. It usefully discloses secret masking, directory isolation, and scope semantics, but omits what happens if memory_id already exists (overwrite vs. error), whether it is idempotent, and what permissions or failures an agent should expect from a persistent write.

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?

One front-loaded purpose sentence followed by a compact per-argument list; no filler, and the two behavior notes (masking, isolation) are placed where they are read first.

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?

Output schema exists so return values need no explanation, and all parameters are documented. The remaining gap for a 7-param mutation with no annotations is conflict/overwrite behavior on duplicate memory_id and any size limits on content.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must compensate entirely, and it does: every one of the 7 parameters gets a semantic explanation, including the kind enumeration, scope values and default, memory_id character constraints and auto-generation, and the empty-string fallback chain for workspace_dir.

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 (saves) and resource (persistent context note / Memory Vault entry) plus the kinds of content it holds. Sibling differentiation is only implicit — an agent can infer it is the write counterpart to search_memory/read_memory/delete_memory, but the description never names them.

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

Usage Guidelines3/5

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

Usage is implied by the enumerated content categories (context, decision, handoff, lesson), but there is no explicit 'use this when...' statement and no guidance on when to prefer patch_memory_section over saving a new entry, or when to choose global vs local scope beyond the one-line definition.

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