Interface ToolChoice.Builder
- All Superinterfaces:
Buildable
,CopyableBuilder<ToolChoice.Builder,
,ToolChoice> SdkBuilder<ToolChoice.Builder,
,ToolChoice> SdkPojo
- Enclosing class:
ToolChoice
-
Method Summary
Modifier and TypeMethodDescriptiondefault ToolChoice.Builder
any
(Consumer<AnyToolChoice.Builder> any) The model must request at least one tool (no text is generated).any
(AnyToolChoice any) The model must request at least one tool (no text is generated).default ToolChoice.Builder
auto
(Consumer<AutoToolChoice.Builder> auto) (Default).auto
(AutoToolChoice auto) (Default).default ToolChoice.Builder
The Model must request the specified tool.tool
(SpecificToolChoice tool) The Model must request the specified tool.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFields
-
Method Details
-
auto
(Default). The Model automatically decides if a tool should be called or whether to generate text instead.
- Parameters:
auto
- (Default). The Model automatically decides if a tool should be called or whether to generate text instead.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
auto
(Default). The Model automatically decides if a tool should be called or whether to generate text instead.
This is a convenience method that creates an instance of theAutoToolChoice.Builder
avoiding the need to create one manually viaAutoToolChoice.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed toauto(AutoToolChoice)
.- Parameters:
auto
- a consumer that will call methods onAutoToolChoice.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
any
The model must request at least one tool (no text is generated).
- Parameters:
any
- The model must request at least one tool (no text is generated).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
any
The model must request at least one tool (no text is generated).
This is a convenience method that creates an instance of theAnyToolChoice.Builder
avoiding the need to create one manually viaAnyToolChoice.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed toany(AnyToolChoice)
.- Parameters:
any
- a consumer that will call methods onAnyToolChoice.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
tool
The Model must request the specified tool. Only supported by Anthropic Claude 3 models.
- Parameters:
tool
- The Model must request the specified tool. Only supported by Anthropic Claude 3 models.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
tool
The Model must request the specified tool. Only supported by Anthropic Claude 3 models.
This is a convenience method that creates an instance of theSpecificToolChoice.Builder
avoiding the need to create one manually viaSpecificToolChoice.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed totool(SpecificToolChoice)
.- Parameters:
tool
- a consumer that will call methods onSpecificToolChoice.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-