EmbeddingUsage class
The usage information for the request.
- Annotations
-
- @freezed
Constructors
- EmbeddingUsage.new({@JsonKey(name: 'prompt_tokens') required int promptTokens, @JsonKey(name: 'total_tokens') required int totalTokens})
-
Factory constructor for EmbeddingUsage
constfactory
-
EmbeddingUsage.fromJson(Map<
String, dynamic> json) -
Object construction from a JSON representation
factory
Properties
-
copyWith
→ $EmbeddingUsageCopyWith<
EmbeddingUsage> -
Create a copy of EmbeddingUsage
with the given fields replaced by the non-null parameter values.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- promptTokens → int
-
The number of tokens used by the prompt.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- totalTokens → int
-
The total number of tokens used by the request.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
Serializes this EmbeddingUsage to a JSON map.
inherited
-
toMap(
) → Map< String, dynamic> - Map representation of object (not serialized)
-
toString(
) → String -
A string representation of this object.
inherited
-
validateSchema(
) → String? - Perform validations on the schema property values
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
-
propertyNames
→ const List<
String> - List of all property names of schema