Class: OpenAI::Models::Live::InitialItem::Developer
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- OpenAI::Models::Live::InitialItem::Developer
- Defined in:
- lib/openai/models/live/initial_item.rb,
sig/openai/models/live/initial_item.rbs
Defined Under Namespace
Modules: Status, Type Classes: Content
Instance Attribute Summary collapse
-
#content ⇒ ::Array[OpenAI::Live::InitialItem::Developer::Content]
The message content.
-
#id ⇒ String?
An optional identifier for the supplied history message.
-
#role ⇒ :developer
The author of this history message.
-
#status ⇒ OpenAI::Models::Live::InitialItem::Developer::status?
The supplied message’s status.
-
#type ⇒ OpenAI::Models::Live::InitialItem::Developer::type_?
The history item type.
Attributes inherited from Internal::Type::BaseModel
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ Developer
constructor
A new instance of Developer.
- #to_hash ⇒ { content: ::Array[OpenAI::Live::InitialItem::Developer::Content], ?role: :developer, ?id: String?, ?status: OpenAI::Models::Live::InitialItem::Developer::status?, ?type: OpenAI::Models::Live::InitialItem::Developer::type_ }
Methods inherited from Internal::Type::BaseModel
==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, fields, hash, #hash, inherited, #inspect, inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, coerce_cached, coerce_with_error, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, resolve_type, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize ⇒ Developer
Returns a new instance of Developer.
58 59 60 61 62 63 64 |
# File 'sig/openai/models/live/initial_item.rbs', line 58
def initialize: (
content: ::Array[OpenAI::Live::InitialItem::Developer::Content],
?id: String?,
?status: OpenAI::Models::Live::InitialItem::Developer::status?,
?type: OpenAI::Models::Live::InitialItem::Developer::type_,
?role: :developer
) -> void
|
Instance Attribute Details
#content ⇒ ::Array[OpenAI::Live::InitialItem::Developer::Content]
The message content. Supply exactly one text part for the initial Live conversation history.
28 |
# File 'lib/openai/models/live/initial_item.rb', line 28 required :content, -> { OpenAI::Internal::Type::ArrayOf[OpenAI::Live::InitialItem::Developer::Content] } |
#id ⇒ String?
An optional identifier for the supplied history message. Live uses the message’s role and text to initialize the conversation.
41 |
# File 'lib/openai/models/live/initial_item.rb', line 41 optional :id, String, nil?: true |
#role ⇒ :developer
The author of this history message. Always developer.
34 |
# File 'lib/openai/models/live/initial_item.rb', line 34 required :role, const: :developer |
#status ⇒ OpenAI::Models::Live::InitialItem::Developer::status?
The supplied message’s status. Live uses its text as history and does not resume an incomplete message.
48 |
# File 'lib/openai/models/live/initial_item.rb', line 48 optional :status, enum: -> { OpenAI::Live::InitialItem::Developer::Status }, nil?: true |
#type ⇒ OpenAI::Models::Live::InitialItem::Developer::type_?
The history item type. Always message.
54 |
# File 'lib/openai/models/live/initial_item.rb', line 54 optional :type, enum: -> { OpenAI::Live::InitialItem::Developer::Type } |
Class Method Details
.values ⇒ Array<Symbol>
|
|
# File 'lib/openai/models/live/initial_item.rb', line 106
|
Instance Method Details
#to_hash ⇒ { content: ::Array[OpenAI::Live::InitialItem::Developer::Content], ?role: :developer, ?id: String?, ?status: OpenAI::Models::Live::InitialItem::Developer::status?, ?type: OpenAI::Models::Live::InitialItem::Developer::type_ }
66 67 68 69 70 71 72 |
# File 'sig/openai/models/live/initial_item.rbs', line 66
def to_hash: -> {
content: ::Array[OpenAI::Live::InitialItem::Developer::Content],
?role: :developer,
?id: String?,
?status: OpenAI::Models::Live::InitialItem::Developer::status?,
?type: OpenAI::Models::Live::InitialItem::Developer::type_
}
|