miwojc commited on
Commit
a90542c
1 Parent(s): cc8b13a

Update app_gradio.py

Browse files
Files changed (1) hide show
  1. app_gradio.py +6 -8
app_gradio.py CHANGED
@@ -1,11 +1,9 @@
1
  import gradio as gr
2
-
3
- title = "papuGaPT2 Demo"
4
- description = "Demo for polish GPT2 for text generation. To use it, simply add your text, or click one of the examples to load them."
5
  examples = [
6
- ['Dialogi niedobre… Bardzo niedobre dialogi są. W ogóle brak akcji jest. Nic się nie dzieje.'],
7
- ["Na przykład w jednym sklepie na półkach po rocznym leżeniu cukier ma 80 proc. cukru w cukrze,"],
8
- ["Moja jest tylko racja i to święta racja. Bo nawet jak jest twoja,"]
9
  ]
10
-
11
- gr.Interface.load("huggingface/flax-community/papuGaPT2", inputs=gr.inputs.Textbox(lines=5, label="Input Text"),title=title,description=description, examples=examples).launch()
1
  import gradio as gr
2
+ title = "papuGaPT2 (Polish GPT2) language model demo"
3
+ description = "This demo showcases the text generation capabilities for papuGaPT2, a GPT2 model pre-trained from scratch using Polish subset of the multilingual Oscar corpus. To use it, add your text to 'Input Text' box, or click one of the below examples to load them and clik 'Submit' button. The model will generate text based on the entered text (prompt). For more information including dataset, training and evaluation procedure, intended use, limitations and bias analysis see the model card at https://huggingface.co/flax-community/papuGaPT2)"
 
4
  examples = [
5
+ ["Najsmaczniejszy owoc to"],
6
+ ["Największym polskim poetą był"],
7
+ ["Cześć mam na imię"]
8
  ]
9
+ gr.Interface.load("huggingface/flax-community/papuGaPT2", inputs=gr.inputs.Textbox(lines=5, label="Input Text"),title=title, description=description, examples=examples).launch()