finishReason

@SerialName(value = "finish_reason")
val finishReason: FinishReason? = null

The reason the model stopped generating tokens. This will be FinishReason.Stop if the model hit a natural stop point or a provided stop sequence, or FinishReason.Length if the maximum number of tokens specified in the request was reached.