Class Completion.Builder
-
- All Implemented Interfaces:
public final class Completion.BuilderA builder for Completion.
-
-
Method Summary
Modifier and Type Method Description final Completion.Builderid(String id)A unique identifier for the completion. final Completion.Builderid(JsonField<String> id)A unique identifier for the completion. final Completion.Builderchoices(List<CompletionChoice> choices)The list of completion choices the model generated for the input prompt. final Completion.Builderchoices(JsonField<List<CompletionChoice>> choices)The list of completion choices the model generated for the input prompt. final Completion.BuilderaddChoice(CompletionChoice choice)The list of completion choices the model generated for the input prompt. final Completion.Buildercreated(Long created)The Unix timestamp (in seconds) of when the completion was created. final Completion.Buildercreated(JsonField<Long> created)The Unix timestamp (in seconds) of when the completion was created. final Completion.Buildermodel(String model)The model used for completion. final Completion.Buildermodel(JsonField<String> model)The model used for completion. final Completion.Builderobject_(JsonValue object_)The object type, which is always "text_completion" final Completion.BuildersystemFingerprint(String systemFingerprint)This fingerprint represents the backend configuration that the model runs with. final Completion.BuildersystemFingerprint(JsonField<String> systemFingerprint)This fingerprint represents the backend configuration that the model runs with. final Completion.Builderusage(CompletionUsage usage)Usage statistics for the completion request. final Completion.Builderusage(JsonField<CompletionUsage> usage)Usage statistics for the completion request. final Completion.BuilderadditionalProperties(Map<String, JsonValue> additionalProperties)final Completion.BuilderputAdditionalProperty(String key, JsonValue value)final Completion.BuilderputAllAdditionalProperties(Map<String, JsonValue> additionalProperties)final Completion.BuilderremoveAdditionalProperty(String key)final Completion.BuilderremoveAllAdditionalProperties(Set<String> keys)final Completionbuild()-
-
Method Detail
-
id
final Completion.Builder id(String id)
A unique identifier for the completion.
-
id
final Completion.Builder id(JsonField<String> id)
A unique identifier for the completion.
-
choices
final Completion.Builder choices(List<CompletionChoice> choices)
The list of completion choices the model generated for the input prompt.
-
choices
final Completion.Builder choices(JsonField<List<CompletionChoice>> choices)
The list of completion choices the model generated for the input prompt.
-
addChoice
final Completion.Builder addChoice(CompletionChoice choice)
The list of completion choices the model generated for the input prompt.
-
created
final Completion.Builder created(Long created)
The Unix timestamp (in seconds) of when the completion was created.
-
created
final Completion.Builder created(JsonField<Long> created)
The Unix timestamp (in seconds) of when the completion was created.
-
model
final Completion.Builder model(String model)
The model used for completion.
-
model
final Completion.Builder model(JsonField<String> model)
The model used for completion.
-
object_
final Completion.Builder object_(JsonValue object_)
The object type, which is always "text_completion"
-
systemFingerprint
final Completion.Builder systemFingerprint(String systemFingerprint)
This fingerprint represents the backend configuration that the model runs with.
Can be used in conjunction with the
seedrequest parameter to understand when backend changes have been made that might impact determinism.
-
systemFingerprint
final Completion.Builder systemFingerprint(JsonField<String> systemFingerprint)
This fingerprint represents the backend configuration that the model runs with.
Can be used in conjunction with the
seedrequest parameter to understand when backend changes have been made that might impact determinism.
-
usage
final Completion.Builder usage(CompletionUsage usage)
Usage statistics for the completion request.
-
usage
final Completion.Builder usage(JsonField<CompletionUsage> usage)
Usage statistics for the completion request.
-
additionalProperties
final Completion.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final Completion.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final Completion.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final Completion.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final Completion.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final Completion build()
-
-
-
-