spring-projects / spring-projects/spring-ai

Add SORTABLE to Redis chat memory timestamp index field

Open Beginner friendly
#5,652 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

status: waiting-for-triage
Dominant language
Java
Stars
9.5k
Forks
2.9k
Avg merge
1d 7h
Merged PRs (30d)
6

Description

RedisChatMemoryRepository frequently executes search queries sorted by timestamp (for conversation history ordering), but the schema currently defines timestamp as NUMERIC without SORTABLE.

SORTABLE indicates that the field can be sorted. This is useful for performing range queries and sorting search results based on numeric values.

Ref: https://redis.io/docs/latest/develop/ai/search-and-query/indexing/field-and-type-options/

Contributor guide

Open the contributing guide

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 by locating RedisChatMemoryRepository and reading how its index schema defines the timestamp field and how conversation-history searches sort results. Confirm the relevant Redis search behavior from the linked documentation; done means the timestamp schema supports the required numeric sorting and range-query use.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, redis
Domain
backend, databases
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.