Create app.py
Browse files
app.py
ADDED
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import gradio as gr
|
2 |
+
|
3 |
+
description = "Gradio demo for Roberta, A Robustly Optimized BERT Pretraining Approach. To use it, simply add your text, or click one of the examples to load them. Read more at the links below."
|
4 |
+
article = "<p style='text-align: center'><a href='https://arxiv.org/abs/1907.11692'>RoBERTa: A Robustly Optimized BERT Pretraining Approach</a> | <a href='https://github.com/pytorch/fairseq/'>Github Repo</a></p>"
|
5 |
+
|
6 |
+
|
7 |
+
|
8 |
+
gr.Interface.load("huggingface/roberta-base", inputs=gr.inputs.Textbox(lines=5), description=description, article=article, analytics_enabled=False, examples=[
|
9 |
+
["Life is like a box of <mask>"],
|
10 |
+
["The capital of France is <mask>"]
|
11 |
+
]).launch()
|