Interface ConverseTokensRequest.Builder
- All Superinterfaces:
Buildable
,CopyableBuilder<ConverseTokensRequest.Builder,
,ConverseTokensRequest> SdkBuilder<ConverseTokensRequest.Builder,
,ConverseTokensRequest> SdkPojo
- Enclosing class:
ConverseTokensRequest
-
Method Summary
Modifier and TypeMethodDescriptionmessages
(Collection<Message> messages) An array of messages to count tokens for.messages
(Consumer<Message.Builder>... messages) An array of messages to count tokens for.An array of messages to count tokens for.system
(Collection<SystemContentBlock> system) The system content blocks to count tokens for.system
(Consumer<SystemContentBlock.Builder>... system) The system content blocks to count tokens for.system
(SystemContentBlock... system) The system content blocks to count tokens for.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
-
messages
An array of messages to count tokens for.
- Parameters:
messages
- An array of messages to count tokens for.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
messages
An array of messages to count tokens for.
- Parameters:
messages
- An array of messages to count tokens for.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
messages
An array of messages to count tokens for.
This is a convenience method that creates an instance of theMessage.Builder
avoiding the need to create one manually viaMessage.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed tomessages(List<Message>)
.- Parameters:
messages
- a consumer that will call methods onMessage.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
system
The system content blocks to count tokens for. System content provides instructions or context to the model about how it should behave or respond. The token count will include any system content provided.
- Parameters:
system
- The system content blocks to count tokens for. System content provides instructions or context to the model about how it should behave or respond. The token count will include any system content provided.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
system
The system content blocks to count tokens for. System content provides instructions or context to the model about how it should behave or respond. The token count will include any system content provided.
- Parameters:
system
- The system content blocks to count tokens for. System content provides instructions or context to the model about how it should behave or respond. The token count will include any system content provided.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
system
The system content blocks to count tokens for. System content provides instructions or context to the model about how it should behave or respond. The token count will include any system content provided.
This is a convenience method that creates an instance of theSystemContentBlock.Builder
avoiding the need to create one manually viaSystemContentBlock.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed tosystem(List<SystemContentBlock>)
.- Parameters:
system
- a consumer that will call methods onSystemContentBlock.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-