Spaces:
Sleeping
Sleeping
File size: 353 Bytes
edf578e 685edaf edf578e 7f6447d 685edaf edf578e 7f6447d |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
import gradio as gr
import time
def generate():
text = "Hello, this is a demo without using streaming that emulates a model"
results = ""
for word in text.split():
time.sleep(0.2)
results.append(word + " ")
yield results
gr.Interface(
generate,
inputs=None,
outputs="text"
).launch(debug=True) |