EpisodicMemoryManager
provides methods for managing and querying your episodic memory. It’s the central class for performing actions like searching for specific episodes.
This module provides the EpisodicMemoryMemoryManager
, a singleton class that
acts as a central factory and registry for EpisodicMemory
objects. It
is responsible for:
- Loading and merging configurations from files.
- Creating, retrieving, and managing context-specific memory instances based on group, agent, user, and session IDs.
- Ensuring that each unique conversational context has a dedicated memory instance.
- Interacting with a
SessionManager
to persist and retrieve session information.
Initialization
You can access theEpisodicMemoryManager
instance through the episodic_memory_manager
property of your MemMachineClient
.
Searching for Episodes
To find episodes, use thesearch_episodes
method. This method allows you to query episodes based on a natural language prompt, returning a list of relevant results.
EpisodicMemoryManager Objects
__init__
create_memory_manager
instead.
Arguments:
config
- A configuration dictionary containing all necessary settings for models, storage, and memory parameters.
create_episodic_memory_manager
config_path
- The path to the configuration file.
get_episodic_memory_instance
group_id
- The identifier for the group context.agent_id
- The identifier for the list of agent context.user_id
- The identifier for the list of user context.session_id
- The identifier for the session context.config_path
- Optional path to a session-specific config file to override defaults.
delete_context_memory
context
- The memory context of the instance to delete.
get_all_sessions
get_user_sessions
user_id
- The ID of the user.
get_agent_sessions
agent_id
- The ID of the agent.
get_group_sessions
group_id
- The ID of the group.