Spaces:
Runtime error
Runtime error
Commit
·
496462c
1
Parent(s):
2d83c30
Add example
Browse files
app.py
CHANGED
@@ -83,10 +83,19 @@ output_model = gr.Text(label="Model output")
|
|
83 |
output_inference_time = gr.Text(label="Inference time in seconds")
|
84 |
|
85 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
86 |
demo = gr.Interface(
|
87 |
inference,
|
88 |
inputs=[model_field, input_text_field, input_question_field],
|
89 |
outputs=[output_model, output_inference_time],
|
|
|
90 |
)
|
91 |
|
92 |
demo.launch()
|
|
|
83 |
output_inference_time = gr.Text(label="Inference time in seconds")
|
84 |
|
85 |
|
86 |
+
examples = [
|
87 |
+
[
|
88 |
+
"Pruned ONNX Optimized FP16",
|
89 |
+
"The first little pig was very lazy. He didn't want to work at all and he built his house out of straw. The second little pig worked a little bit harder but he was somewhat lazy too and he built his house out of sticks. Then, they sang and danced and played together the rest of the day.",
|
90 |
+
"Who worked a little bit harder?",
|
91 |
+
]
|
92 |
+
]
|
93 |
+
|
94 |
demo = gr.Interface(
|
95 |
inference,
|
96 |
inputs=[model_field, input_text_field, input_question_field],
|
97 |
outputs=[output_model, output_inference_time],
|
98 |
+
examples=examples,
|
99 |
)
|
100 |
|
101 |
demo.launch()
|