ChatChunk

@Serializable
data class ChatChunk(val index: Int, val delta: ChatDelta? = null, val contentFilterOffsets: ContentFilterOffsets? = null, val contentFilterResults: ContentFilterResults? = null, val finishReason: FinishReason? = null)

A completion generated by OpenAI.

documentation

Constructors

Link copied to clipboard
constructor(index: Int, delta: ChatDelta? = null, contentFilterOffsets: ContentFilterOffsets? = null, contentFilterResults: ContentFilterResults? = null, finishReason: FinishReason? = null)

Properties

Link copied to clipboard
@SerialName(value = "content_filter_offsets")
val contentFilterOffsets: ContentFilterOffsets? = null

Azure content filter offsets

Link copied to clipboard
@SerialName(value = "content_filter_results")
val contentFilterResults: ContentFilterResults? = null

Azure content filter results

Link copied to clipboard
@SerialName(value = "delta")
val delta: ChatDelta? = null

The generated chat message.

Link copied to clipboard
@SerialName(value = "finish_reason")
val finishReason: FinishReason? = null

The reason why OpenAI stopped generating.

Link copied to clipboard
@SerialName(value = "index")
val index: Int

Chat choice index.