Skip to content
Docs menu

Tool reference · Save & recall

memory_explain_search

Runs a fast search and shows how each retrieval tier (keyword, semantic, graph, fuzzy, HyDE) scored the records and how they were merged.

local stdio server read-only

When to use

  • A record you expected did not show up and you want to know why.
  • You are tuning queries or tags and want to see which tier found what.

Parameters

NameTypeDefaultDescription
queryrequired string — —
project string — —
type "decision" | "fact" | "solution" | "lesson" | "convention" | "all" "all" —
limit integer 10 —
embedding_space string | array — —

Example

Arguments

{
  "query": "billing job lock",
  "project": "my-api",
  "limit": 5
}

Result shape

{
  "query": "billing job lock",
  "total": 1,
  "detail": "full",
  "fusion": "rrf",
  "total_tokens": 120,
  "results": {
    "decision": [
      {
        "id": 1842,
        "content": "Use PostgreSQL advisory locks…",
        "score": 0.912
      }
    ]
  },
  "_explain": {
    "fts": [
      {
        "id": 1842,
        "bm25": 7.4312
      }
    ],
    "semantic": [
      {
        "id": 1842,
        "cos": 0.8123
      }
    ],
    "graph": [],
    "fuzzy": [],
    "hyde": [],
    "merged": [
      {
        "id": 1842,
        "score": 0.0328,
        "via": [
          "fts",
          "semantic"
        ]
      }
    ],
    "rerank_applied": false,
    "embedding_space": null,
    "tiers_used": [
      "fts",
      "semantic"
    ]
  }
}

Explaining a search does not count as a recall, so it does not change the ranking of the records it reports on.

Values are illustrative; the keys follow the server's handler. MCP clients receive the result as JSON text content.

Server description

The description the server sends to your agent in tools/list, captured from the v14.7.0 source:

same as memory_search_fast but returns a per-tier breakdown (fts/semantic/graph/fuzzy/hyde with raw scores, the merged RRF list, rerank_applied flag, embedding_space). Use to debug why a record did or didn't surface for a query.

Found a mistake? Open an issue on GitHub.

Search