AssistantAgent
and UserProxyAgent
: Agents that facilitate communication in the AG2 framework.Interoperability
: This module acts as a bridge, making it easier to integrate PydanticAI tools with AG2’s architecture.config_list
defines the LLM configurations, including the model and API key.UserProxyAgent
simulates user inputs without requiring actual human interaction (set to NEVER
).AssistantAgent
represents the AI agent, configured with the LLM settings.Player
model using BaseModel to structure the input data.Player
instance) securely into the tool.get_player
function defines the tool’s functionality, retrieving injected data through ctx.deps
.Interoperability
.user_proxy
and chatbot
.UserProxyAgent
and the AssistantAgent
:
user_proxy
sends a message to the chatbot
.Player
data is securely injected into the tool, and the chatbot can access and use it during the chat.