Spaces:
Running
Running
mrfakename
commited on
Commit
•
7b13d40
1
Parent(s):
73c13c3
fix "/s" issue
Browse files
app.py
CHANGED
@@ -41,7 +41,8 @@ async def generate1(prompt):
|
|
41 |
formatted_prompt, **generate_kwargs, stream=True, details=True, return_full_text=True)
|
42 |
output = ""
|
43 |
for response in stream:
|
44 |
-
|
|
|
45 |
|
46 |
communicate = edge_tts.Communicate(output)
|
47 |
with tempfile.NamedTemporaryFile(delete=False, suffix=".wav") as tmp_file:
|
|
|
41 |
formatted_prompt, **generate_kwargs, stream=True, details=True, return_full_text=True)
|
42 |
output = ""
|
43 |
for response in stream:
|
44 |
+
if not response.token.text == "</s>":
|
45 |
+
output += response.token.text
|
46 |
|
47 |
communicate = edge_tts.Communicate(output)
|
48 |
with tempfile.NamedTemporaryFile(delete=False, suffix=".wav") as tmp_file:
|