Class VoyageAIServiceSettings
java.lang.Object
co.elastic.clients.elasticsearch.inference.VoyageAIServiceSettings
- All Implemented Interfaces:
JsonpSerializable
@JsonpDeserializable
public class VoyageAIServiceSettings
extends Object
implements JsonpSerializable
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final JsonpDeserializer<VoyageAIServiceSettings>
Json deserializer forVoyageAIServiceSettings
-
Method Summary
Modifier and TypeMethodDescriptionfinal Integer
The number of dimensions for resulting output embeddings.final Float
The data type for the embeddings to be returned.final String
modelId()
Required - The name of the model to use for the inference task.static VoyageAIServiceSettings
final RateLimitSetting
This setting helps to minimize the number of rate limit errors returned from VoyageAI.void
serialize
(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) Serialize this object to JSON.protected void
serializeInternal
(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) protected static void
toString()
-
Field Details
-
_DESERIALIZER
Json deserializer forVoyageAIServiceSettings
-
-
Method Details
-
of
public static VoyageAIServiceSettings of(Function<VoyageAIServiceSettings.Builder, ObjectBuilder<VoyageAIServiceSettings>> fn) -
dimensions
The number of dimensions for resulting output embeddings. This setting maps tooutput_dimension
in the VoyageAI documentation. Only for thetext_embedding
task type.API name:
dimensions
-
modelId
Required - The name of the model to use for the inference task. Refer to the VoyageAI documentation for the list of available text embedding and rerank models.API name:
model_id
-
rateLimit
This setting helps to minimize the number of rate limit errors returned from VoyageAI. Thevoyageai
service sets a default number of requests allowed per minute depending on the task type. For bothtext_embedding
andrerank
, it is set to2000
.API name:
rate_limit
-
embeddingType
The data type for the embeddings to be returned. This setting maps tooutput_dtype
in the VoyageAI documentation. Permitted values: float, int8, bit.int8
is a synonym ofbyte
in the VoyageAI documentation.bit
is a synonym ofbinary
in the VoyageAI documentation. Only for thetext_embedding
task type.API name:
embedding_type
-
serialize
Serialize this object to JSON.- Specified by:
serialize
in interfaceJsonpSerializable
-
serializeInternal
-
toString
-
setupVoyageAIServiceSettingsDeserializer
protected static void setupVoyageAIServiceSettingsDeserializer(ObjectDeserializer<VoyageAIServiceSettings.Builder> op)
-