Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -12,8 +12,27 @@ def answer_question(contexto, pergunta):
|
|
| 12 |
iface = gr.Interface(
|
| 13 |
fn=answer_question,
|
| 14 |
inputs=[
|
| 15 |
-
gr.Textbox(
|
| 16 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 17 |
],
|
| 18 |
outputs=gr.Textbox(type="text", label="Resposta")
|
| 19 |
)
|
|
|
|
| 12 |
iface = gr.Interface(
|
| 13 |
fn=answer_question,
|
| 14 |
inputs=[
|
| 15 |
+
gr.Textbox(
|
| 16 |
+
type="text",
|
| 17 |
+
lines=3
|
| 18 |
+
label="Contexto"),
|
| 19 |
+
gr.Textbox(
|
| 20 |
+
type="text",
|
| 21 |
+
lines=4
|
| 22 |
+
label="Pergunta",
|
| 23 |
+
info="Escreva o que quer saber...")
|
| 24 |
+
],
|
| 25 |
+
[
|
| 26 |
+
gr.Slider(2, 20, value=4, label="Count", info="Choose between 2 and 20"),
|
| 27 |
+
gr.Dropdown(
|
| 28 |
+
["cat", "dog", "bird"], label="Animal", info="Will add more animals later!"
|
| 29 |
+
),
|
| 30 |
+
gr.CheckboxGroup(["USA", "Japan", "Pakistan"], label="Countries", info="Where are they from?"),
|
| 31 |
+
gr.Radio(["park", "zoo", "road"], label="Location", info="Where did they go?"),
|
| 32 |
+
gr.Dropdown(
|
| 33 |
+
["ran", "swam", "ate", "slept"], value=["swam", "slept"], multiselect=True, label="Activity", info="Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed auctor, nisl eget ultricies aliquam, nunc nisl aliquet nunc, eget aliquam nisl nunc vel nisl."
|
| 34 |
+
),
|
| 35 |
+
gr.Checkbox(label="Morning", info="Did they do it in the morning?")
|
| 36 |
],
|
| 37 |
outputs=gr.Textbox(type="text", label="Resposta")
|
| 38 |
)
|