You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> Learn more about [semantic caching]((https://docs.redisvl.com/en/stable/user_guide/03_llmcache.html))for LLMs.
266
266
267
-
### LLM Session Management
267
+
### LLM Memory History
268
268
269
-
Improve personalization and accuracy of LLM responses by providing user chathistory as context. Manage access to the session data using recency or relevancy, *powered by vector search* with the [`SemanticSessionManager`](https://docs.redisvl.com/en/stable/api/session_manager.html).
269
+
Improve personalization and accuracy of LLM responses by providing user messagehistory as context. Manage access to message history data using recency or relevancy, *powered by vector search* with the [`MessageHistory`](https://docs.redisvl.com/en/stable/api/message_history.html).
270
270
271
271
```python
272
-
from redisvl.extensions.session_manager import SemanticSessionManager
272
+
from redisvl.extensions.message_history import SemanticMessageHistory
273
273
274
-
session = SemanticSessionManager(
274
+
history = SemanticMessageHistory(
275
275
name="my-session",
276
276
redis_url="redis://localhost:6379",
277
277
distance_threshold=0.7
278
278
)
279
279
280
-
session.add_messages([
280
+
history.add_messages([
281
281
{"role": "user", "content": "hello, how are you?"},
0 commit comments