Class EasyInputMessage
-
- All Implemented Interfaces:
public final class EasyInputMessage
A message input to the model with a role indicating instruction following hierarchy. Instructions given with the
developer
orsystem
role take precedence over instructions given with theuser
role. Messages with theassistant
role are presumed to have been generated by the model in previous interactions.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final class
EasyInputMessage.Builder
A builder for EasyInputMessage.
public final class
EasyInputMessage.Content
Text, image, or audio input to the model, used to generate a response. Can also contain previous assistant responses.
public final class
EasyInputMessage.Role
The role of the message input. One of
user
,assistant
,system
, ordeveloper
.public final class
EasyInputMessage.Type
The type of the message input. Always
message
.
-
Method Summary
Modifier and Type Method Description final EasyInputMessage.Content
content()
Text, image, or audio input to the model, used to generate a response. final EasyInputMessage.Role
role()
The role of the message input. final Optional<EasyInputMessage.Type>
type()
The type of the message input. final JsonField<EasyInputMessage.Content>
_content()
Returns the raw JSON value of content. final JsonField<EasyInputMessage.Role>
_role()
Returns the raw JSON value of role. final JsonField<EasyInputMessage.Type>
_type()
Returns the raw JSON value of type. final Map<String, JsonValue>
_additionalProperties()
final EasyInputMessage.Builder
toBuilder()
final EasyInputMessage
validate()
final Boolean
isValid()
Boolean
equals(Object other)
Integer
hashCode()
String
toString()
final static EasyInputMessage.Builder
builder()
Returns a mutable builder for constructing an instance of EasyInputMessage. -
-
Method Detail
-
content
final EasyInputMessage.Content content()
Text, image, or audio input to the model, used to generate a response. Can also contain previous assistant responses.
-
role
final EasyInputMessage.Role role()
The role of the message input. One of
user
,assistant
,system
, ordeveloper
.
-
type
final Optional<EasyInputMessage.Type> type()
The type of the message input. Always
message
.
-
_content
final JsonField<EasyInputMessage.Content> _content()
Returns the raw JSON value of content.
Unlike content, this method doesn't throw if the JSON field has an unexpected type.
-
_role
final JsonField<EasyInputMessage.Role> _role()
Returns the raw JSON value of role.
Unlike role, this method doesn't throw if the JSON field has an unexpected type.
-
_type
final JsonField<EasyInputMessage.Type> _type()
Returns the raw JSON value of type.
Unlike type, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final EasyInputMessage.Builder toBuilder()
-
validate
final EasyInputMessage validate()
-
builder
final static EasyInputMessage.Builder builder()
Returns a mutable builder for constructing an instance of EasyInputMessage.
The following fields are required:
.content() .role()
-
-
-
-