Skip to main content
Glama

search_memory

Retrieve relevant memories by querying with keywords or phrases. Results are ranked by relevance and importance, and searches are tracked for access patterns.

Instructions

Search stored memories using SQLite full-text search (FTS5). Returns results ranked by relevance with higher-importance memories boosted. Each search increments the retrieval_count on matched memories, tracking which memories are accessed most. Use at session start to load relevant context, or mid-session to recall specific information. Returns an array of matching memories with id, content, category, importance, project, created_at, and retrieval_count. Returns an empty array if no matches are found.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesFull-text search query. Supports keywords, phrases, and SQLite FTS5 syntax (e.g., 'database AND migration', '"exact phrase"'). Broader queries return more results.
categoryNoFilter results to a single category. Omit to search across all categories.
projectNoFilter results to a specific project. Omit to search across all projects.
limitNoMaximum number of results to return. Default 10. Results are ranked by relevance and importance before truncation.
Behavior5/5

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

Discloses key behaviors: uses FTS5, results ranked by relevance and importance, increments retrieval_count on matched memories, returns specific fields, and returns empty array on no match. This is comprehensive given no annotations.

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?

Concise and well-structured (~90 words), each sentence serves a purpose: purpose, ranking info, side effect, usage, return structure, and empty case. No redundancy.

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?

Covers all essential aspects: search mechanism, ranking criteria, side effect (increment retrieval_count), return fields, and empty result handling. No output schema but description adequately describes return structure.

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 already has descriptions for all parameters (100% coverage). The description adds value by explaining query semantics ('Broader queries return more results') and limit behavior ('Results are ranked by relevance and importance before truncation').

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 clearly states the tool performs a full-text search on stored memories using SQLite FTS5, distinguishing it from sibling tools like list_memories (which likely lists all memories) and other CRUD tools.

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?

Provides explicit usage scenarios: 'Use at session start to load relevant context, or mid-session to recall specific information.' While it does not explicitly exclude alternatives, the guidance is clear and actionable.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Skitchy/rekindle'

If you have feedback or need assistance with the MCP directory API, please join our Discord server