Class TextEmbeddingRequest.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<BuilderT>
co.elastic.clients.elasticsearch._types.RequestBase.AbstractBuilder<TextEmbeddingRequest.Builder>
co.elastic.clients.elasticsearch.inference.TextEmbeddingRequest.Builder
- All Implemented Interfaces:
WithJson<TextEmbeddingRequest.Builder>
,ObjectBuilder<TextEmbeddingRequest>
- Enclosing class:
- TextEmbeddingRequest
public static class TextEmbeddingRequest.Builder
extends RequestBase.AbstractBuilder<TextEmbeddingRequest.Builder>
implements ObjectBuilder<TextEmbeddingRequest>
Builder for
TextEmbeddingRequest
.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds aTextEmbeddingRequest
.inferenceId
(String value) Required - The inference IdRequired - Inference input.Required - Inference input.protected TextEmbeddingRequest.Builder
self()
taskSettings
(JsonData value) Optional task settingsSpecifies the amount of time to wait for the inference request to complete.Specifies the amount of time to wait for the inference request to complete.Methods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJson
Methods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
inferenceId
Required - The inference IdAPI name:
inference_id
-
input
Required - Inference input. Either a string or an array of strings.API name:
input
Adds all elements of
list
toinput
. -
input
Required - Inference input. Either a string or an array of strings.API name:
input
Adds one or more values to
input
. -
taskSettings
Optional task settingsAPI name:
task_settings
-
timeout
Specifies the amount of time to wait for the inference request to complete.API name:
timeout
-
timeout
Specifies the amount of time to wait for the inference request to complete.API name:
timeout
-
self
- Specified by:
self
in classRequestBase.AbstractBuilder<TextEmbeddingRequest.Builder>
-
build
Builds aTextEmbeddingRequest
.- Specified by:
build
in interfaceObjectBuilder<TextEmbeddingRequest>
- Throws:
NullPointerException
- if some of the required fields are null.
-