Class ResponseUsage.InputTokensDetails.Builder
-
- All Implemented Interfaces:
public final class ResponseUsage.InputTokensDetails.BuilderA builder for InputTokensDetails.
-
-
Method Summary
-
-
Method Detail
-
cacheWriteTokens
final ResponseUsage.InputTokensDetails.Builder cacheWriteTokens(Long cacheWriteTokens)
The number of input tokens that were written to the cache.
-
cacheWriteTokens
final ResponseUsage.InputTokensDetails.Builder cacheWriteTokens(JsonField<Long> cacheWriteTokens)
Sets Builder.cacheWriteTokens to an arbitrary JSON value.
You should usually call Builder.cacheWriteTokens with a well-typed Long value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
cachedTokens
final ResponseUsage.InputTokensDetails.Builder cachedTokens(Long cachedTokens)
The number of tokens that were retrieved from the cache. More on prompt caching.
-
cachedTokens
final ResponseUsage.InputTokensDetails.Builder cachedTokens(JsonField<Long> cachedTokens)
Sets Builder.cachedTokens to an arbitrary JSON value.
You should usually call Builder.cachedTokens with a well-typed Long value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
additionalProperties
final ResponseUsage.InputTokensDetails.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final ResponseUsage.InputTokensDetails.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final ResponseUsage.InputTokensDetails.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final ResponseUsage.InputTokensDetails.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final ResponseUsage.InputTokensDetails.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final ResponseUsage.InputTokensDetails build()
Returns an immutable instance of InputTokensDetails.
Further updates to this Builder will not mutate the returned instance.
The following fields are required:
.cacheWriteTokens() .cachedTokens()
-
-
-
-