Spaces:
Sleeping
Sleeping
broadfield
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -3,6 +3,7 @@ import xmltodict
|
|
3 |
import requests
|
4 |
import json
|
5 |
import uuid
|
|
|
6 |
style="""
|
7 |
.title_div{
|
8 |
font-size: x-large;
|
@@ -66,7 +67,6 @@ def search(q,rn,st):
|
|
66 |
def next_show(cur):
|
67 |
new=int(cur)+10
|
68 |
return gr.update(interactive=True),new
|
69 |
-
|
70 |
def prev_show(cur):
|
71 |
if int(cur)-10 <=0:
|
72 |
new=0
|
@@ -79,6 +79,11 @@ def show_num(cur):
|
|
79 |
new=int(cur)+10
|
80 |
html_out=f"<div><center>Showing {cur} through {new}</center></div>"
|
81 |
return html_out
|
|
|
|
|
|
|
|
|
|
|
82 |
|
83 |
with gr.Blocks(css=style,head=head) as b:
|
84 |
with gr.Group():
|
|
|
3 |
import requests
|
4 |
import json
|
5 |
import uuid
|
6 |
+
|
7 |
style="""
|
8 |
.title_div{
|
9 |
font-size: x-large;
|
|
|
67 |
def next_show(cur):
|
68 |
new=int(cur)+10
|
69 |
return gr.update(interactive=True),new
|
|
|
70 |
def prev_show(cur):
|
71 |
if int(cur)-10 <=0:
|
72 |
new=0
|
|
|
79 |
new=int(cur)+10
|
80 |
html_out=f"<div><center>Showing {cur} through {new}</center></div>"
|
81 |
return html_out
|
82 |
+
def stream_aud(inp):
|
83 |
+
txt=inp[0]['text']
|
84 |
+
pp=PyPiper()
|
85 |
+
pp.load_mod()
|
86 |
+
yield(pp.stream_tts(in_text=txt,model="en_US-joe-medium"))
|
87 |
|
88 |
with gr.Blocks(css=style,head=head) as b:
|
89 |
with gr.Group():
|