Class: OpenAI::Models::Live::InstructionsAppendEvent

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/live/instructions_append_event.rb,
sig/openai/models/live/instructions_append_event.rbs

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

Instance Method Summary collapse

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(content:, delegation_id:, event_id: nil, type: :"session.instructions.append") ⇒ InstructionsAppendEvent

Returns a new instance of InstructionsAppendEvent.

Parameters:

  • content —

    Instruction text to append, limited to 500 tokens. This is a plain string, not an array of content parts.

  • delegation_id —

    Required, nullable. Set null for general session context, or use the ID from session.delegation.created for an existing client delegation. Non-null IDs are not accepted with Responses delegation.

  • event_id (defaults to: nil) —

    Optional client identifier for correlating this command with a server event's client_event_id or error.client_event_id.

  • type (defaults to: :"session.instructions.append") —

    The Live client event type. Always session.instructions.append.

  • content: (String)
  • delegation_id: (String, nil)
  • event_id: (String, nil) (defaults to: nil)
  • type: (:"session.instructions.append") (defaults to: :"session.instructions.append")


# File 'lib/openai/models/live/instructions_append_event.rb', line 35

Instance Attribute Details

#content ⇒ String

Instruction text to append, limited to 500 tokens. This is a plain string, not an array of content parts.

Returns:

  • (String)


12
# File 'lib/openai/models/live/instructions_append_event.rb', line 12

required :content, String

#delegation_id ⇒ String?

Required, nullable. Set null for general session context, or use the ID from session.delegation.created for an existing client delegation. Non-null IDs are not accepted with Responses delegation.

Returns:

  • (String, nil)


20
# File 'lib/openai/models/live/instructions_append_event.rb', line 20

required :delegation_id, String, nil?: true

#event_id ⇒ String?

Optional client identifier for correlating this command with a server event's client_event_id or error.client_event_id.

Returns:

  • (String, nil)


33
# File 'lib/openai/models/live/instructions_append_event.rb', line 33

optional :event_id, String, nil?: true

#type ⇒ :"session.instructions.append"

The Live client event type. Always session.instructions.append.

Returns:

  • (:"session.instructions.append")


26
# File 'lib/openai/models/live/instructions_append_event.rb', line 26

required :type, const: :"session.instructions.append"

Instance Method Details

#to_hash ⇒ { content: String, delegation_id: String?, ?type: :"session.instructions.append", ?event_id: String? }

Returns:

  • ({ content: String, delegation_id: String?, ?type: :"session.instructions.append", ?event_id: String? })


48
49
50
51
52
53
# File 'sig/openai/models/live/instructions_append_event.rbs', line 48

def to_hash: -> {
  content: String,
  delegation_id: String?,
  ?type: :"session.instructions.append",
  ?event_id: String?
}