Class AmazonBedrockTaskSettings
java.lang.Object
co.elastic.clients.elasticsearch.inference.AmazonBedrockTaskSettings
- All Implemented Interfaces:
JsonpSerializable
@JsonpDeserializable
public class AmazonBedrockTaskSettings
extends Object
implements JsonpSerializable
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final JsonpDeserializer<AmazonBedrockTaskSettings>
Json deserializer forAmazonBedrockTaskSettings
-
Method Summary
Modifier and TypeMethodDescriptionfinal Integer
For acompletion
task, it sets the maximum number for the output tokens to be generated.static AmazonBedrockTaskSettings
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
setupAmazonBedrockTaskSettingsDeserializer
(ObjectDeserializer<AmazonBedrockTaskSettings.Builder> op) final Float
For acompletion
task, it is a number between 0.0 and 1.0 that controls the apparent creativity of the results.final Float
topK()
For acompletion
task, it limits samples to the top-K most likely words, balancing coherence and variability.final Float
topP()
For acompletion
task, it is a number in the range of 0.0 to 1.0, to eliminate low-probability tokens.toString()
-
Field Details
-
_DESERIALIZER
Json deserializer forAmazonBedrockTaskSettings
-
-
Method Details
-
of
public static AmazonBedrockTaskSettings of(Function<AmazonBedrockTaskSettings.Builder, ObjectBuilder<AmazonBedrockTaskSettings>> fn) -
maxNewTokens
For acompletion
task, it sets the maximum number for the output tokens to be generated.API name:
max_new_tokens
-
temperature
For acompletion
task, it is a number between 0.0 and 1.0 that controls the apparent creativity of the results. At temperature 0.0 the model is most deterministic, at temperature 1.0 most random. It should not be used iftop_p
ortop_k
is specified.API name:
temperature
-
topK
For acompletion
task, it limits samples to the top-K most likely words, balancing coherence and variability. It is only available for anthropic, cohere, and mistral providers. It is an alternative totemperature
; it should not be used iftemperature
is specified.API name:
top_k
-
topP
For acompletion
task, it is a number in the range of 0.0 to 1.0, to eliminate low-probability tokens. Top-p uses nucleus sampling to select top tokens whose sum of likelihoods does not exceed a certain value, ensuring both variety and coherence. It is an alternative totemperature
; it should not be used iftemperature
is specified.API name:
top_p
-
serialize
Serialize this object to JSON.- Specified by:
serialize
in interfaceJsonpSerializable
-
serializeInternal
-
toString
-
setupAmazonBedrockTaskSettingsDeserializer
protected static void setupAmazonBedrockTaskSettingsDeserializer(ObjectDeserializer<AmazonBedrockTaskSettings.Builder> op)
-