Class RealtimeSessionAbstract

Hierarchy

  • EventEmitter
    • RealtimeSession

    Constructors

    Accessors

    Methods

    • Clear the input audio buffer to the server

      Returns Promise<void>

    • Commit the input audio buffer to the server

      Returns Promise<void>

    • Cancel the current generation (do nothing if no generation is in progress)

      Returns Promise<void>

    • Parameters

      • frame: AudioFrame

      Returns void

    • Parameters

      • audioStream: ReadableStream<AudioFrame>

      Returns void

    • Notifies the model that user activity has started

      Returns void

    • Truncate the message at the given audio end time

      Parameters

      • options: {
            audioEndMs: number;
            messageId: string;
        }
        • audioEndMs: number
        • messageId: string

      Returns Promise<void>

    • Parameters

      Returns Promise<void>

      Throws

      RealtimeError on Timeout

    • Parameters

      • instructions: string

      Returns Promise<void>