Package com.openai.models
Class ChatCompletionAssistantMessageParam.Content
-
- All Implemented Interfaces:
public final class ChatCompletionAssistantMessageParam.Content
The contents of the assistant message. Required unless
tool_calls
orfunction_call
is specified.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public interface
ChatCompletionAssistantMessageParam.Content.Visitor
An interface that defines how to map each variant of Content to a value of type T.
public final class
ChatCompletionAssistantMessageParam.Content.ChatCompletionRequestAssistantMessageContentPart
Learn about text inputs.
-
Method Summary
-
-
Method Detail
-
arrayOfContentParts
final Optional<List<ChatCompletionAssistantMessageParam.Content.ChatCompletionRequestAssistantMessageContentPart>> arrayOfContentParts()
An array of content parts with a defined type. Can be one or more of type
text
, or exactly one of typerefusal
.
-
isArrayOfContentParts
final Boolean isArrayOfContentParts()
-
asArrayOfContentParts
final List<ChatCompletionAssistantMessageParam.Content.ChatCompletionRequestAssistantMessageContentPart> asArrayOfContentParts()
An array of content parts with a defined type. Can be one or more of type
text
, or exactly one of typerefusal
.
-
accept
final <T extends Any> T accept(ChatCompletionAssistantMessageParam.Content.Visitor<T> visitor)
-
validate
final ChatCompletionAssistantMessageParam.Content validate()
-
ofText
final static ChatCompletionAssistantMessageParam.Content ofText(String text)
The contents of the assistant message.
-
ofArrayOfContentParts
final static ChatCompletionAssistantMessageParam.Content ofArrayOfContentParts(List<ChatCompletionAssistantMessageParam.Content.ChatCompletionRequestAssistantMessageContentPart> arrayOfContentParts)
An array of content parts with a defined type. Can be one or more of type
text
, or exactly one of typerefusal
.
-
-
-
-