Class: OpenAI::Models::Audio::VoiceCreateParams::Body::AudioSample
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- OpenAI::Models::Audio::VoiceCreateParams::Body::AudioSample
- Defined in:
- lib/openai/models/audio/voice_create_params.rb,
sig/openai/models/audio/voice_create_params.rbs
Defined Under Namespace
Modules: Type
Instance Attribute Summary collapse
-
#audio_sample ⇒ OpenAI::Internal::file_input
The sample audio recording file.
-
#consent ⇒ String
The consent recording ID (for example,
cons_1234). -
#name ⇒ String
The name of the new voice.
-
#type ⇒ OpenAI::Models::Audio::VoiceCreateParams::Body::AudioSample::type_?
The voice creation method.
Attributes inherited from Internal::Type::BaseModel
Instance Method Summary collapse
-
#initialize(audio_sample:, consent:, name:, type: nil) ⇒ AudioSample
constructor
A new instance of AudioSample.
- #to_hash ⇒ { audio_sample: OpenAI::Internal::file_input, consent: String, name: String, ?type: OpenAI::Models::Audio::VoiceCreateParams::Body::AudioSample::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(audio_sample:, consent:, name:, type: nil) ⇒ AudioSample
Returns a new instance of AudioSample.
|
|
# File 'lib/openai/models/audio/voice_create_params.rb', line 81
|
Instance Attribute Details
#audio_sample ⇒ OpenAI::Internal::file_input
The sample audio recording file. Maximum size is 10 MiB.
Supported MIME types: audio/mpeg, audio/wav, audio/x-wav, audio/ogg,
audio/aac, audio/flac, audio/webm, audio/mp4.
String, StringIO, and pathless IO inputs are sent with generic upload
metadata. Use OpenAI::FilePart when you need to override the filename or
content type.
61 |
# File 'lib/openai/models/audio/voice_create_params.rb', line 61 required :audio_sample, OpenAI::Internal::Type::FileInput |
#consent ⇒ String
The consent recording ID (for example, cons_1234).
67 |
# File 'lib/openai/models/audio/voice_create_params.rb', line 67 required :consent, String |
#name ⇒ String
The name of the new voice.
73 |
# File 'lib/openai/models/audio/voice_create_params.rb', line 73 required :name, String |
#type ⇒ OpenAI::Models::Audio::VoiceCreateParams::Body::AudioSample::type_?
The voice creation method. Defaults to audio_sample when omitted.
79 |
# File 'lib/openai/models/audio/voice_create_params.rb', line 79 optional :type, enum: -> { OpenAI::Audio::VoiceCreateParams::Body::AudioSample::Type } |
Instance Method Details
#to_hash ⇒ { audio_sample: OpenAI::Internal::file_input, consent: String, name: String, ?type: OpenAI::Models::Audio::VoiceCreateParams::Body::AudioSample::type_ }
138 139 140 141 142 143 |
# File 'sig/openai/models/audio/voice_create_params.rbs', line 138
def to_hash: -> {
audio_sample: OpenAI::Internal::file_input,
consent: String,
name: String,
?type: OpenAI::Models::Audio::VoiceCreateParams::Body::AudioSample::type_
}
|