osanseviero's picture
Update app.py
7f6447d
raw
history blame
353 Bytes
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)