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
Hello, actually useObject doesn't have messages like useChat.
I also tried to set data on message but it's only possible when you use assistant (with part code = 6)
I don't know if it's possible to improve useChat because currently the message content only receive the deltas that's why I had to create a function getTextDiff
Feature Description
Thanks to the recent version of AI SDK we can now set the
experimental_output
to streamText function.According to the docs we can then get the streamed object from
experimental_partialOutputStream
.If we implement the useChat response we can do something like this:
But in the front, you end by displaying stream stringified json which cannot be parsed because the json is incomplete.
So I found a work around where I can stream the answer text and send the suggestedUserAnswers through annotation...
It works... but it's very hacky...
Use Cases
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: