Class PutTrainedModelVocabularyRequest
java.lang.Object
co.elastic.clients.elasticsearch._types.RequestBase
co.elastic.clients.elasticsearch.ml.PutTrainedModelVocabularyRequest
- All Implemented Interfaces:
JsonpSerializable
@JsonpDeserializable public class PutTrainedModelVocabularyRequest extends RequestBase implements JsonpSerializable
Creates a trained model vocabulary. This API is supported only for natural
language processing (NLP) models. The vocabulary is stored in the index as
described in
inference_config.*.vocabulary
of the trained model
definition.- See Also:
- API specification
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
PutTrainedModelVocabularyRequest.Builder
Builder forPutTrainedModelVocabularyRequest
.Nested classes/interfaces inherited from class co.elastic.clients.elasticsearch._types.RequestBase
RequestBase.AbstractBuilder<BuilderT extends RequestBase.AbstractBuilder<BuilderT>>
-
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<PutTrainedModelVocabularyRequest>
_DESERIALIZER
Json deserializer forPutTrainedModelVocabularyRequest
static Endpoint<PutTrainedModelVocabularyRequest,PutTrainedModelVocabularyResponse,ErrorResponse>
_ENDPOINT
Endpoint "ml.put_trained_model_vocabulary
". -
Method Summary
Modifier and Type Method Description java.util.List<java.lang.String>
merges()
The optional model merges if required by the tokenizer.java.lang.String
modelId()
Required - The unique identifier of the trained model.static PutTrainedModelVocabularyRequest
of(java.util.function.Function<PutTrainedModelVocabularyRequest.Builder,ObjectBuilder<PutTrainedModelVocabularyRequest>> fn)
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
setupPutTrainedModelVocabularyRequestDeserializer(ObjectDeserializer<PutTrainedModelVocabularyRequest.Builder> op)
java.util.List<java.lang.String>
vocabulary()
Required - The model vocabulary, which must not be empty.Methods inherited from class co.elastic.clients.elasticsearch._types.RequestBase
toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Field Details
-
_DESERIALIZER
Json deserializer forPutTrainedModelVocabularyRequest
-
_ENDPOINT
public static final Endpoint<PutTrainedModelVocabularyRequest,PutTrainedModelVocabularyResponse,ErrorResponse> _ENDPOINTEndpoint "ml.put_trained_model_vocabulary
".
-
-
Method Details
-
of
public static PutTrainedModelVocabularyRequest of(java.util.function.Function<PutTrainedModelVocabularyRequest.Builder,ObjectBuilder<PutTrainedModelVocabularyRequest>> fn) -
merges
public final java.util.List<java.lang.String> merges()The optional model merges if required by the tokenizer.API name:
merges
-
modelId
public final java.lang.String modelId()Required - The unique identifier of the trained model.API name:
model_id
-
vocabulary
public final java.util.List<java.lang.String> vocabulary()Required - The model vocabulary, which must not be empty.API name:
vocabulary
-
serialize
Serialize this object to JSON.- Specified by:
serialize
in interfaceJsonpSerializable
-
serializeInternal
-
setupPutTrainedModelVocabularyRequestDeserializer
protected static void setupPutTrainedModelVocabularyRequestDeserializer(ObjectDeserializer<PutTrainedModelVocabularyRequest.Builder> op)
-