redis / redis/agent-memory-server

docs: long-term search ordering is relevance-based — server_side_recency contract unclear

Open
#306 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
316
Forks
63
Avg merge
14d 23h
Merged PRs (30d)
1

Description

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.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the search_long_term_memory entry point and the RecencyConfig(server_side_recency=True) behavior described in the reproduction. Document the ordering contract for search results and clarify what server_side_recency does in 0.14.x; if server-side recency ordering is unsupported, record the client-side created_at sorting guidance.

Written by the indexing model from the issue text.

Assessment

Tech stack
ollama, python, redis
Domain
documentation
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.