Interface AssistantStreamEventSubscriber


public interface AssistantStreamEventSubscriber
An interface which is used to subscribe to assistant events emitted when streaming a Run.
See Also:
  • Method Details

    • onThread

      void onThread(String event, Thread thread)
      Will be called when the event data is Thread
    • onThreadRun

      void onThreadRun(String event, ThreadRun threadRun)
      Will be called when the event data is ThreadRun
    • onThreadRunStep

      void onThreadRunStep(String event, ThreadRunStep threadRunStep)
      Will be called when the event data is ThreadRunStep
    • onThreadRunStepDelta

      void onThreadRunStepDelta(String event, ThreadRunStepDelta threadRunStepDelta)
      Will be called when the event data is ThreadRunStepDelta
    • onThreadMessage

      void onThreadMessage(String event, ThreadMessage threadMessage)
      Will be called when the event data is ThreadMessage
    • onThreadMessageDelta

      void onThreadMessageDelta(String event, ThreadMessageDelta threadMessageDelta)
      Will be called when the event data is ThreadMessageDelta
    • onUnknownEvent

      void onUnknownEvent(String event, String data)
      Will be called when an unsupported assistant event is emitted.
      Parameters:
      data - the raw data which was emitted
    • onException

      void onException(Throwable ex)
      Will be called if any exception happens while processing
    • onComplete

      void onComplete()
      Will be called when the stream is complete or an exception has happened