Merged
Conversation
…g unused agents, and updating documentation for clarity
…r improved tool management and clarity; update related documentation and examples accordingly.
…cy and clarity; ensure ToolNode initialization is validated before skill setup.
…rganization - Moved agent imports to the end of the __all__ list for better readability. - Ensured consistency in the order of exports by grouping tools and agents separately.
- Introduced MemoryConfig, UserMemoryConfig, and AgentMemoryConfig for managing user and agent memory. - Updated Agent class to accept MemoryConfig and handle memory initialization. - Added user_memory_tool and agent_memory_tool for model-facing memory operations. - Refactored memory handling in the agent to support preload and search functionalities. - Enhanced tests to cover new memory configurations and tool behaviors. - Created MemoryPlan.md to outline the new memory architecture and implementation strategy.
…afe arithmetic calculations
…d clarity; remove unnecessary dynamic imports.
…ry handling; enhance long-term memory prompts and version bump
…memory tool imports for improved organization
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request refactors the way tools are configured and injected into the
Agentclass, moving from the previoustoolsparameter to a new, more flexibletool_nodeparameter. It also introduces first-class support for agent-level memory integration and improves error handling for tool resolution. The changes clarify the API, simplify the code, and enhance extensibility for advanced use cases.Tool configuration and API refactor:
Agentclass now accepts atool_nodeparameter, which can be aToolNodeinstance or a string referencing a named graph node, instead of the previoustoolsandtool_node_nameparameters. This makes tool wiring explicit and more flexible, both for inline and graph-based workflows. [1] [2] [3] [4]_setup_toolsmethod inAgentExecutionMixinis updated to normalize and handle the newtool_nodeparameter, supporting both direct instances and lazy DI resolution via string names.get_tool_node()method now simply returns the agent-ownedToolNodeif configured.Agent memory integration:
memoryparameter (of typeMemoryConfig) in theAgentconstructor and initializing it via the newAgentMemoryMixin. This enables long-term memory tools and system prompts to be injected into the agent. [1] [2] [3]Improved error handling:
RuntimeErrorif the referenced node is missing or not aToolNode, instead of logging a warning and continuing. This prevents silent failures and surfaces misconfigurations early.Documentation and examples:
Agentclass docstring and usage examples are updated to reflect the newtool_nodeAPI, including both inline and named ToolNode patterns, and to clarify the role of thememoryparameter. [1] [2] [3] [4]Cleanup and modernization:
toolsparameter are removed, and type annotations are modernized for clarity and correctness. [1] [2]These changes modernize the agent interface, improve reliability, and lay the groundwork for more advanced agent memory and tool composition features.