@@ -7,16 +7,18 @@ A Redis-powered memory server built for AI agents and applications. It manages b
77- ** Short-Term Memory**
88 - Storage for messages, token count, context, and metadata for a session
99 - Automatically and recursively summarizes conversations
10- - Token limit management based on specific model capabilities
10+ - Client model-aware token limit management (adapts to the context window of the client's LLM)
11+ - Supports all major OpenAI and Anthropic models
1112
1213- ** Long-Term Memory**
1314 - Storage for long-term memories across sessions
14- - Semantic search to retrieve memories, with filters such as topic, entity, etc.
15+ - Semantic search to retrieve memories with advanced filtering system
16+ - Filter by session, namespace, topics, entities, timestamps, and more
17+ - Supports both exact match and semantic similarity search
1518 - Automatic topic modeling for stored memories with BERTopic
1619 - Automatic Entity Recognition using BERT
1720
1821- ** Other Features**
19- - Support for OpenAI and Anthropic model providers
2022 - Namespace support for session and long-term memory isolation
2123 - Both a REST interface and MCP server
2224
@@ -56,6 +58,11 @@ The following endpoints are available:
5658- ** GET /sessions/{session_id}/memory**
5759 Retrieves conversation memory for a session, including messages and
5860 summarized older messages.
61+ _ Query Parameters:_
62+ - ` namespace ` (string, optional): The namespace to use for the session
63+ - ` window_size ` (int, optional): Number of messages to include in the response (default from config)
64+ - ` model_name ` (string, optional): The client's LLM model name to determine appropriate context window size
65+ - ` context_window_max ` (int, optional): Direct specification of max context window tokens (overrides model_name)
5966
6067- ** POST /sessions/{session_id}/memory**
6168 Adds messages (and optional context) to a session's memory.
@@ -81,6 +88,40 @@ The following endpoints are available:
8188 }
8289 ```
8390
91+ - ** POST /long-term-memory/search**
92+ Performs semantic search on long-term memories with advanced filtering options.
93+ _ Request Body Example:_
94+ ``` json
95+ {
96+ "text" : " Search query text" ,
97+ "limit" : 10 ,
98+ "offset" : 0 ,
99+ "session_id" : {"eq" : " session-123" },
100+ "namespace" : {"eq" : " default" },
101+ "topics" : {"any" : [" AI" , " Machine Learning" ]},
102+ "entities" : {"all" : [" OpenAI" , " Claude" ]},
103+ "created_at" : {"gte" : 1672527600 , "lte" : 1704063599 },
104+ "last_accessed" : {"gt" : 1704063600 },
105+ "user_id" : {"eq" : " user-456" }
106+ }
107+ ```
108+
109+ _ Filter options:_
110+ - Tag filters (session_id, namespace, topics, entities, user_id):
111+ - ` eq ` : Equals this value
112+ - ` ne ` : Not equals this value
113+ - ` any ` : Contains any of these values
114+ - ` all ` : Contains all of these values
115+
116+ - Numeric filters (created_at, last_accessed):
117+ - ` gt ` : Greater than
118+ - ` lt ` : Less than
119+ - ` gte ` : Greater than or equal
120+ - ` lte ` : Less than or equal
121+ - ` eq ` : Equals
122+ - ` ne ` : Not equals
123+ - ` between ` : Between two values
124+
84125## MCP Server Interface
85126Agent Memory Server offers an MCP (Model Context Protocol) server interface powered by FastMCP, providing tool-based long-term memory management:
86127
0 commit comments