You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you have computer use with another tool, the chat messages throw an error, due to invalid tool invocations
const result = await streamText({
model: anthropic("claude-3-5-sonnet-20241022"),
maxSteps: 100,
system:
"You are a helpful assistant working on a computer. With the ability to navigate the web, type, click, and move the mouse.",
messages: convertToCoreMessages(messages),
tools: {
computer: computerTool,
navigation: {
description: "Navigate to a specific url",
parameters: z.object({
url: z.string().describe("The url to navigate to"),
}),
execute: async ({ url }) => {
const result = await computerControl({
sessionId,
action: "navigate",
text: url,
});
return "Navigated to " + url;
},
},
},
});
You can invoke the tool once, but if you send 1 more chat message the error occurs:
⨯ MessageConversionError [AI_MessageConversionError]: ToolInvocation must have a result
{"state":"call","toolCallId":"toolu_01MwvrJfwyFqk8nEV6BPqzEA","toolName":"navigation","args":
{"url":"https://www.espn.com"}}
Code example
No response
AI provider
"@ai-sdk/anthropic": "^1.0.2"
Additional context
No response
The text was updated successfully, but these errors were encountered:
Description
If you have computer use with another tool, the chat messages throw an error, due to invalid tool invocations
You can invoke the tool once, but if you send 1 more chat message the error occurs:
Code example
No response
AI provider
Additional context
No response
The text was updated successfully, but these errors were encountered: