Skip to main content
Glama

Encode Memory

encode_memory

Store a new long-term memory with a chosen tier, salience weight, and key-value context so agents can retain structured, searchable knowledge across sessions.

Instructions

Store a new memory with tier classification (episodic, semantic, buffer, core), salience weight, and key-value context metadata.

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": {
      "content": "<content>"
    },
    "name": "encode_memory"
  }
}

Input Schema

NameRequiredDescriptionDefault
typeNoMemory tier: episodic, semantic, buffer, or core.episodic
contentYesMemory content to store.
contextNoOptional list of [key, value] metadata pairs.
salienceNoImportance weight between 0.0 and 1.0.
namespaceNoProject or workspace namespace (e.g. pwd with "/" replaced by "-").

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.9/5.0
Behavior2/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false, and idempotentHint=false, so the safety profile is covered. The description adds nothing behavioral beyond that — it does not say what happens when identical content is encoded twice (relevant given non-idempotency), how namespace defaults are resolved, or what the call returns.

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 well-formed sentence with the core action front-loaded and no filler. It is efficient, though its brevity is part of why guidance and behavior are underspecified rather than a sign of a tight, complete definition.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is a fairly simple single-record write with a fully documented schema and no output schema to explain. Still, for a non-idempotent mutation the description omits deduplication behavior, namespace defaulting, and what a successful store yields, which an agent would need to chain this into a workflow.

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 schema already documents every parameter including the tier enum, the 0.0–1.0 salience bounds, and the [key, value] context pair format. The description merely restates those field names in prose, adding no syntax, defaults, or edge-case meaning; the baseline 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?

The description names a specific verb and resource ("Store a new memory") and enumerates the salient attributes being persisted (tier, salience, context metadata). It is clear what the tool does, though it never contrasts itself with siblings like batch_encode or consolidate, so an agent must infer that this is the single-memory write path.

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

Usage Guidelines2/5

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

There is no when-to-use or when-not-to-use guidance. With siblings such as batch_encode and consolidate present, the description should say that this encodes one memory at a time, but it leaves the agent to guess the selection rule entirely.

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