Hi,
I’m reading the guided tour for Smolagents. I learned we have two ways to call a tool:
CodeAgent and ToolCallingAgent. It mentioned that ToolCallingAgent doesn’t execute code here:
We also support the widely-used way of writing actions as JSON-like blobs: this is ToolCallingAgent, it works much in the same way like CodeAgent, of course without
additional_authorized_imports
since it doesn’t execute code:
But on a different page, it shows that we can provide tools for the ToolCallingAgent, which I assume can call the code.
web_agent = ToolCallingAgent(
tools=[DuckDuckGoSearchTool(), visit_webpage],
model=model,
max_steps=10,
name="search",
description="Runs web searches for you. Give it your query as an argument.",
)
Ref: Orchestrate a multi-agent system 🤖🤝🤖
I’m not really sure what’s the different between these two and when to use what. Thanks!