SystemContentBlock

sealed class SystemContentBlock

Contains configurations for instructions to provide the model for how to handle input. To learn more, see Using the Converse API.

Inheritors

Types

Link copied to clipboard

CachePoint to include in the system prompt.

Link copied to clipboard

A content block to assess with the guardrail. Use with the Converse or ConverseStream API operations.

Link copied to clipboard
Link copied to clipboard
data class Text(val value: String) : SystemContentBlock

A system prompt for the model.

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun asText(): String

Casts this SystemContentBlock as a Text and retrieves its kotlin.String value. Throws an exception if the SystemContentBlock is not a Text.

Link copied to clipboard

Casts this SystemContentBlock as a Text and retrieves its kotlin.String value. Returns null if the SystemContentBlock is not a Text.