import gradio as gr | |
def fuduji(name): | |
return name | |
demo = gr.Interface( | |
title = "这是一个中文复读机", | |
description = """ | |
1.输入中文,它会复读你所说的话\n | |
2.我爱huggingface | |
""", | |
fn=fuduji, | |
inputs=[ | |
gr.Textbox( | |
label="输入要复读的中文", | |
lines=10, | |
), | |
], | |
outputs=[ | |
gr.Textbox( | |
label="复读结果", | |
lines=10, | |
), | |
], | |
) | |
demo.launch() |