Fabio A.F
Convex Community6mo ago
7 replies
Fabio A.

Obtaining stream failure from AI Agent

Hi all,
I'm building using the AI Agent Component and part of what I want to do is show the user the reason for a stream failure. I can see that when I go to the agent component, there's a streamingMessages table that contains the state which (when aborted) contains an object like this:
{
  kind: "aborted",
  reason: "user_aborted"
}

I'd like for an API to exist for me to be able to query this status, but I'm not sure how I'd go about doing this as there's no documentation and I can't find a method that extracts this state. Any help is greatly appreciated.
Was this page helpful?