mirror of
https://github.com/trycua/computer.git
synced 2026-01-01 19:10:30 -06:00
Ignore extra computers when running evals
This commit is contained in:
@@ -128,10 +128,11 @@ class MCPComputerAgent(MCPAgent):
|
||||
}
|
||||
agent_tools: list[Any] = [computer_shim]
|
||||
if tools:
|
||||
for tool in tools:
|
||||
if is_agent_computer(tool):
|
||||
raise ValueError(f"Too many Computer tools: MCPComputerAgent already includes a Computer interface. Received a Computer tool in tools= (e.g., {tool!r}). Remove it and retry.")
|
||||
agent_tools.extend(tools)
|
||||
agent_tools.extend([
|
||||
tool
|
||||
for tool in tools
|
||||
if not is_agent_computer(tool)
|
||||
])
|
||||
|
||||
agent_kwargs = {
|
||||
"model": self.model,
|
||||
|
||||
Reference in New Issue
Block a user