OpenAIStreamCompletionModelChoice class final

This class is used to represent a choice generated by an OpenAI stream completion.

Annotations
  • @immutable

Constructors

OpenAIStreamCompletionModelChoice({required String text, required int index, required int? logprobs, required String? finishReason})
This class is used to represent a choice generated by an OpenAI stream completion.
const
OpenAIStreamCompletionModelChoice.fromMap(Map<String, dynamic> json)
This class is used to represent a choice generated by an OpenAI stream completion. This method is used to convert a Map<String, dynamic> object to a OpenAIStreamCompletionModelChoice object.
factory

Properties

finishReason String?
The reason the completion finished.
final
hashCode int
The hash code for this object.
no setteroverride
index int
The index of the choice.
final
logprobs int?
The log probabilities of the tokens in the completion.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
text String
The text generated by the completion.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

operator ==(covariant OpenAIStreamCompletionModelChoice other) bool
The equality operator.
override