Streaming
VaikerAI’s API supports server-sent event streams (SSEs) for language models, allowing you to receive real-time output as it’s generated. This guide will walk you through how to consume streaming output.
What is Streaming Output?
Streaming output enables you to receive progressive updates in real-time as a language model processes your input. Instead of waiting for the entire prediction to complete, you can access results as they’re produced, which is especially useful for applications like chatbots that require immediate feedback.
How Streaming Output Works
Initiate a Prediction with Streaming: Start by creating a prediction using the stream option.
Receive a Streaming URL: VaikerAI will return a prediction object that includes a URL for accessing the streaming output.
Connect to the Stream: Connect to the provided URL to receive a continuous stream of updates as the prediction progresses.
Last updated