Spaces:
Build error
Build error
| import gradio as gr | |
| import outetts | |
| interface = outetts.Interface( | |
| config=outetts.ModelConfig.auto_config( | |
| model="OuteAI/OuteTTS-1.0-0.6B", | |
| backend=outetts.Backend.HF | |
| ) | |
| ) | |
| def tts(text): | |
| speaker = interface.load_default_speaker("EN-FEMALE-1-NEUTRAL") | |
| output = interface.generate( | |
| config=outetts.GenerationConfig( | |
| text=text, | |
| speaker=speaker, | |
| ) | |
| ) | |
| return output.audio | |
| gr.Interface( | |
| fn=tts, | |
| inputs=gr.Textbox(label="Texte"), | |
| outputs=gr.Audio(label="Voix générée"), | |
| title="OuteTTS Cloud TTS" | |
| ).launch() |