OpenAIStreamOptions

class OpenAIStreamOptions(val includeUsage: Boolean? = null)(source)

Options for streaming response.

Constructors

Link copied to clipboard
constructor(includeUsage: Boolean? = null)

Properties

Link copied to clipboard
val includeUsage: Boolean? = null

If set, an additional chunk will be streamed before the data: [DONE] message. The usage field on this chunk shows the token usage statistics for the entire request, and the choices field will always be an empty array.