ChatBot / app.py
Antonio49's picture
Update app.py
c678721 verified
raw
history blame contribute delete
643 Bytes
import gradio as gr
import time
def slow_echo(message, history):
for i in range(len(message)):
time.sleep(0.05)
yield "Tu escribiste: " + message[: i+1]
demo = gr.ChatInterface(slow_echo,
title="Chat básico",
description= 'Autor: <a href=\"https://huggingface.co/Antonio49\">Antonio Fernández</a> de <a href=\"https://saturdays.ai/\">SaturdaysAI</a>. Formación: <a href=\"https://cursos.saturdays.ai/courses/\">Cursos Online AI</a> Aplicación desarrollada con fines docentes'
).queue()
if __name__ == "__main__":
demo.launch()