Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customizing voices #246

Open
captainshin90 opened this issue Feb 24, 2025 · 0 comments
Open

Customizing voices #246

captainshin90 opened this issue Feb 24, 2025 · 0 comments

Comments

@captainshin90
Copy link

Default voices can be configured in conversation_config.yaml but not programmatically.

It will be great if different voices can be passed as new conversation_config parameters to generate_podcast().

For example:

conv_config = {
'question': 'en-GB-Standard-B',
'answer': 'en-GB-Standard-A'
}

debate_podcast = generate_podcast(
text=["/sample.txt"],
conversation_config=conv_config,
tts_model="gemini"
)

To support this, it seems only a simple change in _generate_audio_segments() is needed:

# voice = provider_config.get("default_voices", {}).get(speaker_type)
# model = provider_config.get("model")
voice = provider_config.get(speaker_type)
model = provider_config.get("tts_model")

audio_data = self.provider.generate_audio(content, voice, model)
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant