π§ Memory
Last updated
Last updated
Memory is one of the important components of the Agentic framework, which gives the agents their own memory to recall and remember the tasks executed and feedback received. It helps the agent make "informed decisions" by recalling previous actions and their observations. It can also store the current execution. Memory helps the agent to avoid repeating mistakes for similar tasks and improves the overall user experience by providing results based on recalled memory.
The new update introduces Long-Term Memory (LTM), a breakthrough feature that enhances the way agents interact, adapt, and grow. LTM equips AI agents with the capability to store and recall information from previous interactions over extended periods, much like human memory.
Key Features of Long-Term Memory:
Seamless Integration: Enabling LTM within OpenAGI requires just a simple configuration update.
Customizable Memory Storage: Users have control over how and where their agent's memory is stored.
Smart Retrieval: LTM employs semantic similarity to retrieve and apply relevant information from past experiences.
Feedback-Driven Learning: Agents can incorporate user feedback to continuously enhance their performance.
Privacy Controls: Memory management is user-friendly, allowing easy deletion or modification of stored information.
The Memory class accepts several parameters that allow you to customize its behavior, particularly for Long-Term Memory:
Below we have shown how one can initiate and run using query with Long-Term Memory enabled:
With LTM activated, your agent will now retain knowledge from previous interactions and use that information to provide more relevant and intelligent responses. This enhancement allows for the creation of more sophisticated AI systems that can learn and improve over time, offering a new level of continuity and context-awareness in AI-driven applications.
long_term
bool
False
Enables or disables Long-Term Memory functionality. When set to True, the agent will store and retrieve information from past interactions.
ltm_threshold
float
0.7
Sets the semantic similarity threshold for memory retrieval. Higher values make the memory more selective, only retrieving highly similar past experiences.
long_term_dir
str
None
Specifies the directory for storing long-term memories. If not provided, a default location will be used.