Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -37,8 +37,8 @@ def chat_hf(audio, custom_token, language):
|
|
37 |
# to voice
|
38 |
if language == 'cn' or 'jp':
|
39 |
text = infer.clean_text(gpt_response)
|
40 |
-
|
41 |
-
voice_out = (hps.data.sampling_rate, audio)
|
42 |
else:
|
43 |
with tempfile.NamedTemporaryFile(suffix=".wav", delete=False) as fp:
|
44 |
coquiTTS.get_tts(gpt_response, fp, speaker = {"language" : language})
|
|
|
37 |
# to voice
|
38 |
if language == 'cn' or 'jp':
|
39 |
text = infer.clean_text(gpt_response)
|
40 |
+
voice_out = infer.infer(text, net_g_ms, 2, "demo")
|
41 |
+
#voice_out = (hps.data.sampling_rate, audio)
|
42 |
else:
|
43 |
with tempfile.NamedTemporaryFile(suffix=".wav", delete=False) as fp:
|
44 |
coquiTTS.get_tts(gpt_response, fp, speaker = {"language" : language})
|