Skip to main content
Glama

recall

Search stored knowledge about a user, project, or topic by query to retrieve ranked memories and related keys, helping answer questions from past context.

Instructions

Search long-term memory for what is already known about the user, project, or topic — call this before your first reply and whenever the topic shifts. Always pass the active namespace when known. Returns {status, query, namespace, keys, memories}: ranked key clusters plus one passive Top-1 memory selected under the top key. The memory includes validity, matched_key, and connected_keys, each with a relevance score (cosine of that key to your query/context, sorted high→low). recall answers a question: check whether the Top-1 memory actually answers it. If it only points elsewhere, is partial, or the highest-relevance connected key is not the one you arrived by, take one more hop — read_key(that key_id, query, namespace) then read_memory — and stop as soon as the answer is complete. Each hop is one call; the store never fans out for you. Passive recall never reinforces links or changes access, depth, aliases, or confirmation — except: when context is a strong restatement of the returned memory, it is auto-confirmed (memories[0].auto_confirmed: true) without a separate confirm_memory call. An empty result includes empty keys/memories and nearest_keys.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes
top_kNo
contextNoThe raw user utterance or sentence this lookup serves. Keep query as short noun keywords; pass the sentence here — it drives content matching, which measures higher on sentence-shaped cues.
explainNoWhen true, also return namespace_memory_count; status distinguishes found, no_match, and empty_namespace.
max_charsNoTruncate the returned memory's content to this length.
namespaceNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv0.30.0
    • removedInput schema / properties / inject
      Removed value: -{
      -  "type": "boolean"
      -}
    • removedInput schema / properties / inject_explore_shallow
      Removed value: -{
      -  "type": "boolean"
      -}
    • removedInput schema / properties / inject_max_chars
      Removed value: -{
      -  "type": "number"
      -}
    • removedInput schema / properties / inject_min_rel_score
      Removed value: -{
      -  "type": "number"
      -}
    • removedInput schema / properties / inject_prefer_depth
      Removed value: -{
      -  "type": "boolean"
      -}
    • removedInput schema / properties / inject_top_k
      Removed value: -{
      -  "type": "number"
      -}
    • addedInput schema / properties / max_chars
      Added value: +{
      +  "description": "Truncate the returned memory's content to this length.",
      +  "type": "number"
      +}
  2. Changed2 schema fields changedv0.29.0
    • addedInput schema / properties / context
      Added value: +{
      +  "description": "The raw user utterance or sentence this lookup serves. Keep query as short noun keywords; pass the sentence here — it drives content matching, which measures higher on sentence-shaped cues.",
      +  "type": "string"
      +}
    • addedInput schema / properties / explain
      Added value: +{
      +  "description": "When true, also return namespace_memory_count; status distinguishes found, no_match, and empty_namespace.",
      +  "type": "boolean"
      +}
  3. Changed2 schema fields changedv0.17.1
    • addedInput schema / properties / inject_max_chars
      Added value: +{
      +  "type": "number"
      +}
    • addedInput schema / properties / inject_min_rel_score
      Added value: +{
      +  "type": "number"
      +}
  4. First observedv0.14.8

TDQS

A4.8/5.0
Behavior5/5

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

With no annotations, the description fully carries the side-effect burden. It states passive recall never reinforces links or changes access/depth/aliases/confirmation, except for the auto-confirm case, and clarifies there is no fan-out — each hop is one call.

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 description is dense but front-loaded: purpose and timing first, then return shape and hop behavior. Every sentence carries operational information; the length is justified by the tool's complexity.

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?

The description covers return shape, memory fields, relevance ordering, empty-result shape, and auto-confirmation, which is substantial for a tool with no output schema. It omits only minor detail such as the meaning of nearest_keys and explicit status values outside explain mode.

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 only 50%, so prose must compensate. The description adds meaning for query (short noun keywords), context (raw sentence that drives matching), and namespace (always pass when known), but top_k is left to inference and explain/max_chars are only covered by schema.

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?

The description opens with a specific verb and resource ('Search long-term memory') and immediately scopes it to known user/project/topic knowledge. It also distinguishes recall from sibling read_key/read_memory by framing it as the first-pass retrieval that answers a question.

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?

It explicitly says to call before the first reply and whenever the topic shifts, and to pass the active namespace when known. It also gives concrete hop logic: if the Top-1 memory doesn't answer, call read_key then read_memory and stop when complete.

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