Skip to main content
Glama

Search memory

memory_search
Read-onlyIdempotent

Search all remembered facts by content across every project scope. Use before assuming something is unknown; blends keyword and semantic matching to find entries even without shared terms.

Instructions

Search all remembered facts by content, across every project scope.

The default entry point. Use it before assuming something is not known: it searches EVERY scope at once, so there is no need to guess which project a fact was recorded under. Use memory_get instead when you already know the exact scope and name, memory_list to browse without a query, and memory_recent for what changed lately.

Two layers, blended by default:

  • Lexical (FTS5): multi-word queries first require ALL terms in one entry, then fall back to ANY term (ranked by how many match), so one non-verbatim word doesn't zero the result.

  • Semantic (if embeddings are present): vector nearest neighbours on a multilingual sentence model, which finds entries about the same idea even with no shared keywords.

Read-only. Archived entries are never returned. Returns a list of entries, best match first; an empty list when nothing matches or the query is invalid.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
debugNoIf true, return {results, mode, ...} instead of a plain list; `mode` tells which path matched (and / or_fallback / hybrid / vector / lexical).
limitNoMaximum number of results to return (default 20). Values are clamped to 1-200.
queryYesSearch terms or a natural-language question, in French or English.
scopeNoRestrict to one project/topic scope (list them with memory_scopes). Omit to cover every scope. On a scope-locked connection (--scope), this argument is ignored and the connection's own scope is used.
semanticNonull = hybrid lexical + semantic (default), true = vector search only, false = lexical (FTS5) only. Semantic search needs the optional embeddings; without them the search is lexical.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.2.0
    • addedInput schema / properties / debug / description
      Added value: +"If true, return {results, mode, ...} instead of a plain list; `mode` tells which path matched (and / or_fallback / hybrid / vector / lexical)."
    • addedInput schema / properties / limit / description
      Added value: +"Maximum number of results to return (default 20). Values are clamped to 1-200."
    • addedInput schema / properties / query / description
      Added value: +"Search terms or a natural-language question, in French or English."
    • addedInput schema / properties / scope / description
      Added value: +"Restrict to one project/topic scope (list them with memory_scopes). Omit to cover every scope. On a scope-locked connection (--scope), this argument is ignored and the connection's own scope is used."
    • addedInput schema / properties / semantic / description
      Added value: +"null = hybrid lexical + semantic (default), true = vector search only, false = lexical (FTS5) only. Semantic search needs the optional embeddings; without them the search is lexical."
  2. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already cover read-only/idempotent/non-destructive, but the description adds substantial behavior: the two-layer FTS5 + semantic blend, the ALL-terms-then-ANY-term fallback, that embeddings are optional, that archived entries are never returned, and that an empty list is returned on no match or invalid query.

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?

Front-loaded with the core purpose and the routing guidance, then the two-layer mechanics. Slightly long, but every sentence (fallback logic, archived exclusion, return shape) adds distinct value rather than restating structured fields.

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

Completeness5/5

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

With no output schema, the description compensates by specifying the return shape (list of entries, best match first, empty list on no match/invalid query). Combined with the annotations and full schema coverage, an agent has everything needed to call this correctly.

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 100%, so the baseline is 3, but the description adds real meaning: it explains the two search layers that drive the `semantic` default and notes that searching every scope is the norm, reinforcing the `scope` omission behavior beyond the schema text.

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?

States a specific verb (search) and resource (remembered facts) with explicit scope ('across every project scope'). It explicitly differentiates itself from siblings by naming memory_get, memory_list, and memory_recent with their distinct conditions.

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?

Declares itself 'the default entry point' and instructs the agent to use it before assuming something is unknown. It then routes to three named alternatives with the exact condition that selects each (known scope/name, browse without query, recent changes).

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