Class: RunApi::Elevenlabs::Client
- Inherits:
-
Core::Client
- Object
- Core::Client
- RunApi::Elevenlabs::Client
- Defined in:
- lib/runapi/elevenlabs/client.rb
Overview
ElevenLabs audio API client for speech synthesis, multi-speaker dialogue, sound effects, transcription, and vocal isolation.
Instance Attribute Summary collapse
-
#isolate_audio ⇒ Resources::IsolateAudio
readonly
Vocal isolation operations.
-
#speech_to_text ⇒ Resources::SpeechToText
readonly
Audio transcription operations.
-
#text_to_dialogue ⇒ Resources::TextToDialogue
readonly
Multi-speaker dialogue synthesis operations.
-
#text_to_sound ⇒ Resources::TextToSound
readonly
Sound effect generation operations.
-
#text_to_speech ⇒ Resources::TextToSpeech
readonly
Single-speaker speech synthesis operations.
Instance Method Summary collapse
-
#initialize(api_key: nil, **options) ⇒ Client
constructor
A new instance of Client.
Constructor Details
#initialize(api_key: nil, **options) ⇒ Client
Returns a new instance of Client.
27 28 29 30 31 32 33 34 35 |
# File 'lib/runapi/elevenlabs/client.rb', line 27 def initialize(api_key: nil, **) super @text_to_speech = Resources::TextToSpeech.new(http) @text_to_dialogue = Resources::TextToDialogue.new(http) @text_to_sound = Resources::TextToSound.new(http) @speech_to_text = Resources::SpeechToText.new(http) @isolate_audio = Resources::IsolateAudio.new(http) end |
Instance Attribute Details
#isolate_audio ⇒ Resources::IsolateAudio (readonly)
Returns Vocal isolation operations.
25 26 27 |
# File 'lib/runapi/elevenlabs/client.rb', line 25 def isolate_audio @isolate_audio end |
#speech_to_text ⇒ Resources::SpeechToText (readonly)
Returns Audio transcription operations.
23 24 25 |
# File 'lib/runapi/elevenlabs/client.rb', line 23 def speech_to_text @speech_to_text end |
#text_to_dialogue ⇒ Resources::TextToDialogue (readonly)
Returns Multi-speaker dialogue synthesis operations.
19 20 21 |
# File 'lib/runapi/elevenlabs/client.rb', line 19 def text_to_dialogue @text_to_dialogue end |
#text_to_sound ⇒ Resources::TextToSound (readonly)
Returns Sound effect generation operations.
21 22 23 |
# File 'lib/runapi/elevenlabs/client.rb', line 21 def text_to_sound @text_to_sound end |
#text_to_speech ⇒ Resources::TextToSpeech (readonly)
Returns Single-speaker speech synthesis operations.
17 18 19 |
# File 'lib/runapi/elevenlabs/client.rb', line 17 def text_to_speech @text_to_speech end |