Skip to main content
Glama

retrieve_memory

Read-only

Hybrid semantic + full-text search. Returns names + metadata only.

Use get_memory(name=...) to fetch full content of a specific result. Pass workspace= to search only within a specific workspace.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo
queryYesQuery string
workspaceNo
memory_typeNo
similarity_thresholdNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed12 schema fields changed
    • addedInput schema / properties / limit / minimum
      Added value: +1
    • changedInput schema / properties / memory_type / anyOf
      Previous value: -[
      -  {
      -    "description": "fact: established fact about user, project, or system.\npreference: user's likes, dislikes, habits.\ninstruction: persistent rule Claude must follow.\nfeedback: evaluation of Claude's output.\ndecision: a choice made with reasoning ('chose X over Y because Z').",
      -    "enum": [
      -      "fact",
      -      "preference",
      -      "instruction",
      -      "feedback",
      -      "decision"
      -    ],
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "description": "fact: established fact about user, project, or system.\npreference: user's likes, dislikes, habits.\ninstruction: persistent rule Claude must follow.\nfeedback: evaluation of Claude's output.\ndecision: a choice made with reasoning ('chose X over Y because Z').\ninsight: consolidated conclusion distilled from several existing memories.",
      +    "enum": [
      +      "fact",
      +      "preference",
      +      "instruction",
      +      "feedback",
      +      "decision",
      +      "insight"
      +    ],
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / query / description
      Added value: +"Query string"
    • removedInput schema / properties / snippet_length
      Removed value: -{
      -  "default": 200,
      -  "type": "integer"
      -}
    • removedOutput schema / properties / result / items / properties / content
      Removed value: -{
      -  "type": "string"
      -}
    • removedOutput schema / properties / result / items / properties / id
      Removed value: -{
      -  "type": "integer"
      -}
    • changedOutput schema / properties / result / items / properties / memory_type / description
      Previous value: -"fact: established fact about user, project, or system.\npreference: user's likes, dislikes, habits.\ninstruction: persistent rule Claude must follow.\nfeedback: evaluation of Claude's output.\ndecision: a choice made with reasoning ('chose X over Y because Z')."New value: +"fact: established fact about user, project, or system.\npreference: user's likes, dislikes, habits.\ninstruction: persistent rule Claude must follow.\nfeedback: evaluation of Claude's output.\ndecision: a choice made with reasoning ('chose X over Y because Z').\ninsight: consolidated conclusion distilled from several existing memories."
    • changedOutput schema / properties / result / items / properties / memory_type / enum
      Previous value: -[
      -  "fact",
      -  "preference",
      -  "instruction",
      -  "feedback",
      -  "decision"
      -]New value: +[
      +  "fact",
      +  "preference",
      +  "instruction",
      +  "feedback",
      +  "decision",
      +  "insight"
      +]
    • addedOutput schema / properties / result / items / properties / name
      Added value: +{
      +  "type": "string"
      +}
    • addedOutput schema / properties / result / items / properties / workspace
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null
      +}
    • removedOutput schema / properties / result / items / properties / workspace_id
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "type": "integer"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null
      -}
    • changedOutput schema / properties / result / items / required
      Previous value: -[
      -  "id",
      -  "content",
      -  "memory_type",
      -  "tags",
      -  "metadata",
      -  "created_at",
      -  "rrf_score"
      -]New value: +[
      +  "name",
      +  "memory_type",
      +  "tags",
      +  "metadata",
      +  "created_at",
      +  "rrf_score"
      +]
  2. Changed6 schema fields changed
    • changedInput schema / properties / memory_type / anyOf
      Previous value: -[
      -  {
      -    "enum": [
      -      "fact",
      -      "preference",
      -      "instruction",
      -      "feedback"
      -    ],
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "description": "fact: established fact about user, project, or system.\npreference: user's likes, dislikes, habits.\ninstruction: persistent rule Claude must follow.\nfeedback: evaluation of Claude's output.\ndecision: a choice made with reasoning ('chose X over Y because Z').",
      +    "enum": [
      +      "fact",
      +      "preference",
      +      "instruction",
      +      "feedback",
      +      "decision"
      +    ],
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • removedInput schema / properties / snippet_length / anyOf
      Removed value: -[
      -  {
      -    "type": "integer"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedInput schema / properties / snippet_length / type
      Added value: +"integer"
    • removedOutput schema / properties / result / items / properties / created_at / format
      Removed value: -"date-time"
    • addedOutput schema / properties / result / items / properties / memory_type / description
      Added value: +"fact: established fact about user, project, or system.\npreference: user's likes, dislikes, habits.\ninstruction: persistent rule Claude must follow.\nfeedback: evaluation of Claude's output.\ndecision: a choice made with reasoning ('chose X over Y because Z')."
    • changedOutput schema / properties / result / items / properties / memory_type / enum
      Previous value: -[
      -  "fact",
      -  "preference",
      -  "instruction",
      -  "feedback"
      -]New value: +[
      +  "fact",
      +  "preference",
      +  "instruction",
      +  "feedback",
      +  "decision"
      +]
  3. First observed

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already establish readOnlyHint=true and destructiveHint=false, so safety is covered. The description adds a genuinely useful behavioral trait beyond the annotations: results are truncated to "names + metadata only," which tells the agent why a follow-up call is needed. It omits pagination/limit behavior and any rate or auth context.

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?

Three short lines, zero filler, and the core mechanism and the "metadata only" caveat are front-loaded before the pointers to the alternative tool. Every sentence earns its place.

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?

An output schema exists, so return values need not be described, and the description correctly focuses on routing and scoping. The remaining gap is the undocumented tuning parameters (limit, similarity_threshold), which is the one thing an agent needs before calling this search tool correctly.

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

Parameters2/5

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

Schema description coverage is only 20%, so the description carries the burden for the other parameters. It explains workspace scoping semantics, but says nothing about limit (result count/pagination), similarity_threshold (what it controls or how the default 0.25 behaves), while memory_type is documented only inside the schema enum text. Two of five parameters remain undocumented anywhere.

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 the retrieval mechanism precisely ("Hybrid semantic + full-text search") and, together with the tool name retrieve_memory, makes the resource unambiguous. It also distinguishes itself from get_memory, so an agent can separate the two siblings without opening schemas. It stops just short of 5 because it never restates the resource explicitly (memories).

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?

It gives an explicit alternative and the condition for choosing it: "Use get_memory(name=...) to fetch full content of a specific result," plus a scoping condition for workspace. It does not address other plausible siblings (recall_memory, search_by_tag, list_memories), so coverage is good but not exhaustive.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources