Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -1,13 +1,9 @@
|
|
1 |
-
import
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
response = requests.request("POST", API_URL, headers=headers, data=data)
|
11 |
-
return json.loads(response.content.decode("utf-8"))
|
12 |
-
|
13 |
-
data = query("Can you please let us know more details about your ")
|
|
|
1 |
+
import gradio as gr
|
2 |
+
title = "papuGaPT2 Demo"
|
3 |
+
description = "Demo for polish GPT2 for text generation. To use it, simply add your text, or click one of the examples to load them."
|
4 |
+
examples = [
|
5 |
+
['Dialogi niedobre… Bardzo niedobre dialogi są. W ogóle brak akcji jest. Nic się nie dzieje.'],
|
6 |
+
["Na przykład w jednym sklepie na półkach po rocznym leżeniu cukier ma 80 proc. cukru w cukrze,"],
|
7 |
+
["Moja jest tylko racja i to święta racja. Bo nawet jak jest twoja,"]
|
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()
|
|
|
|
|
|
|
|