Class CreateEmbeddingResponse.Builder
-
- All Implemented Interfaces:
public final class CreateEmbeddingResponse.Builder
A builder for CreateEmbeddingResponse.
-
-
Method Summary
-
-
Method Detail
-
data
final CreateEmbeddingResponse.Builder data(List<Embedding> data)
The list of embeddings generated by the model.
-
data
final CreateEmbeddingResponse.Builder data(JsonField<List<Embedding>> data)
Sets Builder.data to an arbitrary JSON value.
You should usually call Builder.data with a well-typed
List<Embedding>
value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
addData
final CreateEmbeddingResponse.Builder addData(Embedding data)
Adds a single Embedding to Builder.data.
-
model
final CreateEmbeddingResponse.Builder model(String model)
The name of the model used to generate the embedding.
-
model
final CreateEmbeddingResponse.Builder model(JsonField<String> model)
Sets Builder.model to an arbitrary JSON value.
You should usually call Builder.model with a well-typed String value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
object_
final CreateEmbeddingResponse.Builder object_(JsonValue object_)
Sets the field to an arbitrary JSON value.
It is usually unnecessary to call this method because the field defaults to the following:
JsonValue.from("list")
This method is primarily for setting the field to an undocumented or not yet supported value.
-
usage
final CreateEmbeddingResponse.Builder usage(CreateEmbeddingResponse.Usage usage)
The usage information for the request.
-
usage
final CreateEmbeddingResponse.Builder usage(JsonField<CreateEmbeddingResponse.Usage> usage)
Sets Builder.usage to an arbitrary JSON value.
You should usually call Builder.usage with a well-typed Usage value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
additionalProperties
final CreateEmbeddingResponse.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final CreateEmbeddingResponse.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final CreateEmbeddingResponse.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final CreateEmbeddingResponse.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final CreateEmbeddingResponse.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final CreateEmbeddingResponse build()
Returns an immutable instance of CreateEmbeddingResponse.
Further updates to this Builder will not mutate the returned instance.
The following fields are required:
.data() .model() .usage()
-
-
-
-