Retrieval
Vector Index
The vector index provides fast semantic candidate retrieval for paraphrase-heavy queries.
Embedding path
A bi-encoder converts memory text and queries into a shared dense space. Vector similarity retrieves semantically close passages even when wording differs.
Normalize vectors consistently for both ingest and query paths to avoid score drift.
HNSW tradeoffs
- Higher `ef_search` improves recall but increases latency.
- Higher `M` improves graph connectivity but uses more memory.
- Batch insertion patterns influence graph quality and cold-start behavior.
vector_index:
metric: cosine
m: 24
ef_construction: 200
ef_search_default: 64Operational checks
- Track recall@k on a fixed evaluation set.
- Monitor p95 query latency by entity size bucket.
- Verify vector-id to memory-id mapping consistency after restarts.