Summary
search_long_term_memory results appear to be relevance-ordered only — we could not obtain recency ordering even with RecencyConfig(recency_weight=1.0, server_side_recency=True). Timestamped records came back oldest-first and inconsistently across calls.
Repro sketch
- Server 0.14.0 + agent-memory-client 0.14.0, redis-stack, Ollama
nomic-embed-text embeddings.
- Write N records over time with distinct
created_at.
search_long_term_memory(text="<query>", recency=RecencyConfig(recency_weight=1.0, server_side_recency=True), limit=10).
- Observed: ordering does not follow
created_at (descending or ascending consistently).
Ask
Document the ordering contract for search results (and what server_side_recency is expected to do in 0.14.x). If recency ordering isn't supported server-side, a doc note saying "sort client-side by created_at" would save consumers a debugging session — that's what we ended up shipping (Smart-AI-Memory/attune-ai#660).
Happy to PR a docs note if you point me at the right page. We run AMS in production for attune-ai's cross-session memory and are glad to contribute findings upstream.
Summary
search_long_term_memoryresults appear to be relevance-ordered only — we could not obtain recency ordering even withRecencyConfig(recency_weight=1.0, server_side_recency=True). Timestamped records came back oldest-first and inconsistently across calls.Repro sketch
nomic-embed-textembeddings.created_at.search_long_term_memory(text="<query>", recency=RecencyConfig(recency_weight=1.0, server_side_recency=True), limit=10).created_at(descending or ascending consistently).Ask
Document the ordering contract for search results (and what
server_side_recencyis expected to do in 0.14.x). If recency ordering isn't supported server-side, a doc note saying "sort client-side bycreated_at" would save consumers a debugging session — that's what we ended up shipping (Smart-AI-Memory/attune-ai#660).Happy to PR a docs note if you point me at the right page. We run AMS in production for attune-ai's cross-session memory and are glad to contribute findings upstream.