Skip to main content
Glama

Search memory

search_memory
Read-onlyIdempotent

Search memory keys, JSON values, descriptions and summaries. Defaults to current, non-archived memories. scope='archived' searches archived entries and previous versions; scope='all' searches both. Results include memory_at and history_id (null for current entries). Use get_memory_history for one key's previous versions, or read_memory for its current value. Pass playbook_id as the UUID or GUID of the playbook this call should target.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagsNoFilter by tags (any match)
tierNoFilter by memory tier
afterNoInclusive lower bound on memory_at
limitNoPage size
scopeNoactive: current; archived: archived and previous versions; all: bothactive
beforeNoInclusive upper bound on memory_at
offsetNoResults to skip, for paging
searchNoLiteral text in keys, JSON values, descriptions and summaries
statusNoFilter by task status (hierarchical only)
memory_typeNoFilter by memory type
playbook_idYesUUID or GUID of the target playbook
include_childrenNoInclude child memories in results

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / limit / description
      Added value: +"Page size"
    • addedInput schema / properties / offset / description
      Added value: +"Results to skip, for paging"
    • addedInput schema / properties / scope / description
      Added value: +"active: current; archived: archived and previous versions; all: both"
  2. Changed6 schema fields changed
    • addedInput schema / properties / after
      Added value: +{
      +  "description": "Inclusive lower bound on memory_at",
      +  "format": "date-time",
      +  "type": "string"
      +}
    • addedInput schema / properties / before
      Added value: +{
      +  "description": "Inclusive upper bound on memory_at",
      +  "format": "date-time",
      +  "type": "string"
      +}
    • addedInput schema / properties / limit
      Added value: +{
      +  "default": 100,
      +  "maximum": 200,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / offset
      Added value: +{
      +  "default": 0,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • addedInput schema / properties / scope
      Added value: +{
      +  "default": "active",
      +  "enum": [
      +    "active",
      +    "archived",
      +    "all"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / search / description
      Previous value: -"Search in keys, descriptions, and summaries"New value: +"Literal text in keys, JSON values, descriptions and summaries"
  3. Changed6 schema fields changed
    • addedInput schema / properties / include_children
      Added value: +{
      +  "default": false,
      +  "description": "Include child memories in results",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / memory_type
      Added value: +{
      +  "description": "Filter by memory type",
      +  "enum": [
      +    "flat",
      +    "hierarchical"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / playbook_id / description
      Previous value: -"UUID of the playbook"New value: +"UUID or GUID of the target playbook"
    • changedInput schema / properties / search / description
      Previous value: -"Search in keys and descriptions"New value: +"Search in keys, descriptions, and summaries"
    • addedInput schema / properties / status
      Added value: +{
      +  "description": "Filter by task status (hierarchical only)",
      +  "enum": [
      +    "pending",
      +    "running",
      +    "completed",
      +    "failed",
      +    "blocked"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / tier
      Added value: +{
      +  "description": "Filter by memory tier",
      +  "enum": [
      +    "working",
      +    "contextual",
      +    "longterm"
      +  ],
      +  "type": "string"
      +}
  4. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and openWorldHint=false, so the safety profile is covered. The description adds real context beyond that: the default scope filter, the fact that archived scope surfaces previous versions, and that results carry memory_at and a history_id that is null for current entries. It stops short of describing result ordering or paging behavior, so it is not a 5.

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?

Four dense sentences, zero filler, and the most decision-relevant facts (what is searched, default scope, scope variants) are front-loaded ahead of the sibling routing and the playbook_id note.

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?

For a 12-parameter, no-output-schema search tool, the description covers the discriminating behavior (scope semantics, result fields, alternative tools) well. It omits result ordering and how search matching is done (the schema says 'literal text'), which are minor gaps rather than blockers for correct invocation.

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 all 12 parameters are already documented, including the scope enum and playbook_id. The description's prose about scope and playbook_id restates rather than extends the schema; the extra return-field note (memory_at, history_id) is output information, not parameter semantics. Baseline 3 is correct.

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 the exact fields searched ('keys, JSON values, descriptions and summaries'), and its scope semantics ('archived searches archived entries and previous versions') clearly separate it from siblings like get_memory_history and read_memory. An agent can distinguish it from the other memory tools without opening a 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?

It states the default behavior ('Defaults to current, non-archived memories'), defines what each scope value does, and routes the agent to explicit alternatives with the condition that selects them: get_memory_history for one key's prior versions, read_memory for its current value. That is the full when/when-not/alternatives triad.

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.