Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -35,10 +35,10 @@ def generate(prompt,history,max_new_tokens,seed):
|
|
35 |
stream = client.text_generation(formatted_prompt, **generate_kwargs, stream=True, details=True, return_full_text=False)
|
36 |
output = ""
|
37 |
|
38 |
-
|
39 |
-
output += response.token.text
|
40 |
-
#yield output
|
41 |
-
|
42 |
|
43 |
with gr.Blocks() as iface:
|
44 |
gr.HTML("""""")
|
|
|
35 |
stream = client.text_generation(formatted_prompt, **generate_kwargs, stream=True, details=True, return_full_text=False)
|
36 |
output = ""
|
37 |
|
38 |
+
for response in stream:
|
39 |
+
#output += response.token.text
|
40 |
+
#yield output
|
41 |
+
yield from pp.stream_tts(response.token.text)
|
42 |
|
43 |
with gr.Blocks() as iface:
|
44 |
gr.HTML("""""")
|