Class AmazonBedrockTaskSettings.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<AmazonBedrockTaskSettings.Builder>
co.elastic.clients.elasticsearch.inference.AmazonBedrockTaskSettings.Builder
- All Implemented Interfaces:
WithJson<AmazonBedrockTaskSettings.Builder>
,ObjectBuilder<AmazonBedrockTaskSettings>
- Enclosing class:
- AmazonBedrockTaskSettings
public static class AmazonBedrockTaskSettings.Builder
extends WithJsonObjectBuilderBase<AmazonBedrockTaskSettings.Builder>
implements ObjectBuilder<AmazonBedrockTaskSettings>
Builder for
AmazonBedrockTaskSettings
.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds aAmazonBedrockTaskSettings
.maxNewTokens
(Integer value) For acompletion
task, it sets the maximum number for the output tokens to be generated.protected AmazonBedrockTaskSettings.Builder
self()
temperature
(Float value) For acompletion
task, it is a number between 0.0 and 1.0 that controls the apparent creativity of the results.For acompletion
task, it limits samples to the top-K most likely words, balancing coherence and variability.For acompletion
task, it is a number in the range of 0.0 to 1.0, to eliminate low-probability tokens.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
-
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
-
self
- Specified by:
self
in classWithJsonObjectBuilderBase<AmazonBedrockTaskSettings.Builder>
-
build
Builds aAmazonBedrockTaskSettings
.- Specified by:
build
in interfaceObjectBuilder<AmazonBedrockTaskSettings>
- Throws:
NullPointerException
- if some of the required fields are null.
-