Wootang01's picture
Update app.py
23e95e5
raw
history blame
669 Bytes
import gradio as gr
from gradio.mix import Series
translator = gr.Interface.load("huggingface/Helsinki-NLP/opus-mt-zh-en")
model4 = gr.Interface.load("huggingface/ckiplab/gpt2-base-chinese")
title = "Chinese Text Generator and Translator"
description = "Input Chinese language text, submit and the machine will generate additional English language text."
examples = [''從前,大衛在香港一所中學工作。 他','一天,這隻狗仰望天空,看到了一艘太空船。 宇宙飛船', '洪水退去。 每個人都很安全。 沒有人死亡。'']
gr.Series(model4, translator, title=title, description=description,examples=examples).launch(debug=True)