Open oalexdoda opened 3 days ago
I also noticed that the content comes through as empty for chats that error out, so maybe it's related to this? https://github.com/vercel/ai/issues/3263#issuecomment-2459492995
Using node v20.16.0
Edit 1: Noticed that when it errors out & you enable error streaming to the client, it throws this:
Model tried to call unavailable tool 'multi_tool_use.parallel'.
I wonder if it's a tool hallucination coming from OpenAI?
Edit 2: Is there a way to turn off parallelToolCalls on streamText
/ useChat
/ result.toDataStreamResponse
?
@oalexdoda you can turn off parallel tool calls for openai models in the model settings: https://sdk.vercel.ai/providers/ai-sdk-providers/openai#chat-models
@oalexdoda you can turn off parallel tool calls for openai models in the model settings: https://sdk.vercel.ai/providers/ai-sdk-providers/openai#chat-models
Perfect, thanks @lgrammel - will try that asap.
Description
This is an inconsistent bug, but it triggers around 10% of the time. First, there's no error being thrown (maybe due to this https://github.com/vercel/ai/issues/3875). And if you add a console.error in that dist, here's the error being thrown server-side:
Code example
AI provider
"@ai-sdk/openai": "^1.0.4",
Additional context
It seems to happen when using a bunch of tools & streaming to useChat.