Expand description
Session management and QA-history storage for Cognee.
Tracks search/answer history and feedback per session so retrieval can use prior context. Trait-based so the store backend is pluggable.
SessionStore— async trait for session persistenceFsSessionStore(featurefs),RedisSessionStore,SeaOrmSessionStore— the backing implementations
Structs§
- Improve
Lock Guard - RAII guard that releases the improve-lock on drop.
- Session
Context - Session context passed to retrievers: the session ID and any loaded conversation history (as LLM messages).
- Session
Manager - Orchestrates session operations using an
Arc<dyn SessionStore>. - SessionQA
Entry - A single question-answer entry stored in a session.
- SessionQA
Update - Partial update DTO for a QA entry.
- Session
Trace Step - One agent-trace step persisted in a session — mirrors Python’s
SessionAgentTraceEntry(nocreated_at; ordering is positional). - Used
Graph Element Ids - Graph element IDs that were used to produce the answer for a Q&A entry.
Enums§
Traits§
- Session
Store - Abstraction over session Q&A storage backends (SQLite, Redis, filesystem, etc.).
Functions§
- release_
improve_ lock - Release the improve-lock for
session_id. Idempotent. - try_
acquire_ improve_ lock - Atomically claim the improve-lock for
session_id.