Skip to main content
Glama

memory_search

Read-only

Search persistent project and personal memory by keyword before asking users about past decisions, conventions, or preferences. Run multiple phrasings and check both scopes to find stored context.

Instructions

Search persistent memory by keyword (BM25 full-text). Returns matching memories from the current project and/or personal scope. Call before asking the user about past decisions, conventions, or preferences they may have told you before. Search well: break the question into its concepts and try 2–3 phrasings per concept — synonyms, the user's other language, shorter keyword forms — and check the other scope too, before concluding nothing is stored.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
typeNoRestrict to memories of this type.
limitNo
queryYesFree-text query. File paths, error strings, identifiers work well.
scopeNoWhich scope(s) to search. Default: both.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior4/5

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

Annotations only declare readOnlyHint=true, so the description carries the rest. It adds real behavioral context: keyword/BM25 matching (not semantic), results span project and personal scope, and the implicit warning that recall is phrasing-sensitive (hence the multi-phrasing advice). It stops short of describing ranking, scores, or result limits.

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 return behavior, then the usage trigger, then the search strategy. Every sentence earns its place, though the strategy sentence is long and could be tightened.

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?

No output schema, so the description must cover returns — and it does state that matching memories from project/personal scope come back. With 4 params and 75% schema coverage, the remaining gaps (type and limit behavior) are minor and mostly covered by the schema itself.

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 75%, so the schema documents most fields. The description still adds value on query semantics ('break the question into concepts... synonyms, shorter keyword forms') and on scope ('current project and/or personal scope', 'check the other scope too'), which maps to the scope enum's project/personal/both values. It does not mention the type or limit parameters.

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), resource (persistent memory), and mechanism (BM25 full-text keyword matching), plus the return scope (current project and/or personal scope). This clearly distinguishes it from siblings like memory_list, memory_add, and memory_forget.

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?

Explicitly tells the agent when to call it ('before asking the user about past decisions, conventions, or preferences') and gives concrete strategy: break the question into concepts, try 2-3 phrasings, check the other scope before concluding nothing is stored. That is actionable when-to-use guidance rare in tool descriptions.

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