agents.memory_v2.react_memory_agentยถ
ReactAgent with memory tools for dynamic memory management.
This implementation follows LangChainโs long-term memory patterns but uses ReactAgent with tools for flexible memory operations.
Classesยถ
ReactAgent with memory management tools. |
Functionsยถ
Example of basic ReactMemoryAgent usage. |
|
Example with custom tools added. |
Module Contentsยถ
- class agents.memory_v2.react_memory_agent.ReactMemoryAgent(name='react_memory_agent', engine=None, user_id=None, memory_store_path=None, k=5, decay_rate=0.01, use_time_weighting=True)ยถ
ReactAgent with memory management tools.
This agent uses tools to: - Load relevant memories before responding - Store new memories from conversations - Update existing memories - Delete outdated memories - Search memories by semantic similarity - Search memories by time range
Init .
- Parameters:
name (str) โ [TODO: Add description]
engine (haive.core.engine.aug_llm.AugLLMConfig | None) โ [TODO: Add description]
user_id (str | None) โ [TODO: Add description]
memory_store_path (str | None) โ [TODO: Add description]
k (int) โ [TODO: Add description]
decay_rate (float) โ [TODO: Add description]
use_time_weighting (bool) โ [TODO: Add description]
- async arun(query, auto_save=True, include_metadata=False)ยถ
Run the ReactAgent with memory tools.
- classmethod create_with_custom_tools(name='custom_memory_agent', engine=None, custom_tools=None, **kwargs)ยถ
Create ReactMemoryAgent with additional custom tools.
- Parameters:
- Returns:
ReactMemoryAgent with custom tools
- Return type:
- async agents.memory_v2.react_memory_agent.example_basic_usage()ยถ
Example of basic ReactMemoryAgent usage.
- async agents.memory_v2.react_memory_agent.example_with_custom_tools()ยถ
Example with custom tools added.