Spaces:
Runtime error
Runtime error
Commit
·
7c12ff5
1
Parent(s):
ae894e5
Update app.py
Browse files
app.py
CHANGED
@@ -150,11 +150,12 @@ with gr.Blocks() as demo:
|
|
150 |
proceed_button = gr.Button("Summarize")
|
151 |
proceed_button.click(fn=summarize_text, inputs=inputs, outputs=outputs)
|
152 |
gr.Markdown("This model summarizes Chinese text using the MT5 language model. Enter a Chinese text in the input box and click the 'Summarize' button to get the summary.")
|
153 |
-
|
154 |
gr.Markdown("""<h4><center>❓Chinese Q&A</center></h4>""")
|
155 |
text_button = gr.Button("proceed")
|
156 |
text_button.click(fn=cqa, inputs=[gr.Textbox(lines=1,label="Question Input", placeholder="Enter the question you want to ask"),gr.Textbox(lines=9,label="Answer Soruce", placeholder="Enter the answer source article in here")],outputs=gr.Textbox(label="Answer Output"))
|
157 |
gr.Markdown("This is a pre-trained Roberta Base Chinese Extractive question answering model. Enter the answer source and the question you want to ask and click the 'Proceed' button to get the answer of your question")
|
|
|
158 |
gr.Markdown('''
|
159 |
We are happy to share with you some Chinese language models that we've made using NLP. When we looked online, we noticed that there weren't many resources available for Chinese NLP, so we hope that our models can be useful to you.
|
160 |
We want to mention that these models aren't perfect and there is still room for improvement. Because of limited resources, there might be some mistakes or limitations in the models.
|
|
|
150 |
proceed_button = gr.Button("Summarize")
|
151 |
proceed_button.click(fn=summarize_text, inputs=inputs, outputs=outputs)
|
152 |
gr.Markdown("This model summarizes Chinese text using the MT5 language model. Enter a Chinese text in the input box and click the 'Summarize' button to get the summary.")
|
153 |
+
with gr.Tab("❓Chinese Q&A"):
|
154 |
gr.Markdown("""<h4><center>❓Chinese Q&A</center></h4>""")
|
155 |
text_button = gr.Button("proceed")
|
156 |
text_button.click(fn=cqa, inputs=[gr.Textbox(lines=1,label="Question Input", placeholder="Enter the question you want to ask"),gr.Textbox(lines=9,label="Answer Soruce", placeholder="Enter the answer source article in here")],outputs=gr.Textbox(label="Answer Output"))
|
157 |
gr.Markdown("This is a pre-trained Roberta Base Chinese Extractive question answering model. Enter the answer source and the question you want to ask and click the 'Proceed' button to get the answer of your question")
|
158 |
+
|
159 |
gr.Markdown('''
|
160 |
We are happy to share with you some Chinese language models that we've made using NLP. When we looked online, we noticed that there weren't many resources available for Chinese NLP, so we hope that our models can be useful to you.
|
161 |
We want to mention that these models aren't perfect and there is still room for improvement. Because of limited resources, there might be some mistakes or limitations in the models.
|