binxu.wang
commited on
Commit
•
cb2ce74
1
Parent(s):
3a34f41
add examples
Browse files
app.py
CHANGED
@@ -30,7 +30,17 @@ def generate(prompt, num_beams, max_length, repetition_penalty, seed):
|
|
30 |
output_all = "\n\n".join(output_texts)
|
31 |
return output_all
|
32 |
|
33 |
-
examples = ["子曰",
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
34 |
|
35 |
iface = gr.Interface(fn=generate,
|
36 |
inputs=[gr.inputs.Textbox(lines=2, label="Prompt"),
|
|
|
30 |
output_all = "\n\n".join(output_texts)
|
31 |
return output_all
|
32 |
|
33 |
+
examples = [["子曰", 10, 50, 1.5, 42],
|
34 |
+
["子墨子曰", 10, 50, 1.5, 42],
|
35 |
+
["孟子", 10, 50, 1.5, 42],
|
36 |
+
["秦王", 10, 50, 1.5, 42],
|
37 |
+
["子路问仁", 10, 50, 1.5, 42],
|
38 |
+
["孙行者笑道", 10, 50, 1.5, 42],
|
39 |
+
["牛魔王与红孩儿", 10, 50, 1.5, 42],
|
40 |
+
["鲲鹏", 10, 50, 1.5, 42],
|
41 |
+
["宝玉道", 10, 50, 1.5, 42],
|
42 |
+
["黛玉行至贾母处", 10, 50, 1.5, 42],]
|
43 |
+
|
44 |
|
45 |
iface = gr.Interface(fn=generate,
|
46 |
inputs=[gr.inputs.Textbox(lines=2, label="Prompt"),
|