Spaces:
Runtime error
Runtime error
Commit
•
5621586
1
Parent(s):
203cf4a
Update app.py
Browse files
app.py
CHANGED
@@ -36,25 +36,25 @@ API_URL = os.getenv("API_URL")
|
|
36 |
|
37 |
examples = [
|
38 |
['To do a "farduddle" means to jump up and down really fast. An example of a sentence that uses the word farduddle is:',
|
39 |
-
64, "sampling",
|
40 |
-
['Recipe for a quick coconut pasta:', 64, "greedy",
|
41 |
['A poem about the beauty of science by Alfred Edgar Brittle\nTitle: The Magic Craft\nIn the old times', 64,
|
42 |
-
"sampling",
|
43 |
-
['استخراج العدد العاملي في لغة بايثون:', 64, "greedy",
|
44 |
-
["Pour déguster un ortolan, il faut tout d'abord", 64, "sampling",
|
45 |
['Traduce español de España a español de Argentina\nEl coche es rojo - el auto es rojo\nEl ordenador es nuevo - la computadora es nueva\nel boligrafo es negro -',
|
46 |
-
64, "sampling",
|
47 |
['Estos ejemplos quitan vocales de las palabras\nEjemplos:\nhola - hl\nmanzana - mnzn\npapas - pps\nalacran - lcrn\npapa -',
|
48 |
-
64, "sampling",
|
49 |
-
["Question: If I put cheese into the fridge, will it melt?\nAnswer:", 64, "greedy",
|
50 |
-
["Math exercise - answers:\n34+10=44\n54+20=", 64, "sampling",
|
51 |
-
["Python - code to compute the factorial of a number:", 64, "greedy",
|
52 |
["Question: Where does the Greek Goddess Persephone spend half of the year when she is not with her mother?\nAnswer:",
|
53 |
-
64, "sampling",
|
54 |
["spelling test answers.\nWhat are the letters in « language »?\nAnswer: l-a-n-g-u-a-g-e\nWhat are the letters in « Romanian »?\nAnswer:",
|
55 |
-
64, "sampling",
|
56 |
['A "whatpu" is a small, furry animal native to Tanzania. An example of a sentence that uses the word whatpu is:',
|
57 |
-
64, "sampling",
|
58 |
]
|
59 |
|
60 |
|
@@ -121,7 +121,7 @@ gr.Interface(
|
|
121 |
gr.inputs.Textbox(label="Input"),
|
122 |
gr.inputs.Radio([64], default=64, label="Tokens to generate"),
|
123 |
gr.inputs.Radio(["sampling", "greedy"], label="Sample or greedy", default="sampling"),
|
124 |
-
gr.Checkbox(label="Just output raw text", value=
|
125 |
],
|
126 |
["image", "text"],
|
127 |
examples=examples,
|
|
|
36 |
|
37 |
examples = [
|
38 |
['To do a "farduddle" means to jump up and down really fast. An example of a sentence that uses the word farduddle is:',
|
39 |
+
64, "sampling", False],
|
40 |
+
['Recipe for a quick coconut pasta:', 64, "greedy", False],
|
41 |
['A poem about the beauty of science by Alfred Edgar Brittle\nTitle: The Magic Craft\nIn the old times', 64,
|
42 |
+
"sampling", False],
|
43 |
+
['استخراج العدد العاملي في لغة بايثون:', 64, "greedy", False],
|
44 |
+
["Pour déguster un ortolan, il faut tout d'abord", 64, "sampling", False],
|
45 |
['Traduce español de España a español de Argentina\nEl coche es rojo - el auto es rojo\nEl ordenador es nuevo - la computadora es nueva\nel boligrafo es negro -',
|
46 |
+
64, "sampling", False],
|
47 |
['Estos ejemplos quitan vocales de las palabras\nEjemplos:\nhola - hl\nmanzana - mnzn\npapas - pps\nalacran - lcrn\npapa -',
|
48 |
+
64, "sampling", False],
|
49 |
+
["Question: If I put cheese into the fridge, will it melt?\nAnswer:", 64, "greedy", False],
|
50 |
+
["Math exercise - answers:\n34+10=44\n54+20=", 64, "sampling", False],
|
51 |
+
["Python - code to compute the factorial of a number:", 64, "greedy", False],
|
52 |
["Question: Where does the Greek Goddess Persephone spend half of the year when she is not with her mother?\nAnswer:",
|
53 |
+
64, "sampling", False],
|
54 |
["spelling test answers.\nWhat are the letters in « language »?\nAnswer: l-a-n-g-u-a-g-e\nWhat are the letters in « Romanian »?\nAnswer:",
|
55 |
+
64, "sampling", False],
|
56 |
['A "whatpu" is a small, furry animal native to Tanzania. An example of a sentence that uses the word whatpu is:',
|
57 |
+
64, "sampling", False],
|
58 |
]
|
59 |
|
60 |
|
|
|
121 |
gr.inputs.Textbox(label="Input"),
|
122 |
gr.inputs.Radio([64], default=64, label="Tokens to generate"),
|
123 |
gr.inputs.Radio(["sampling", "greedy"], label="Sample or greedy", default="sampling"),
|
124 |
+
gr.Checkbox(label="Just output raw text", value=False),
|
125 |
],
|
126 |
["image", "text"],
|
127 |
examples=examples,
|