Update app.py
Browse files
app.py
CHANGED
|
@@ -52,9 +52,12 @@ def main():
|
|
| 52 |
}
|
| 53 |
)
|
| 54 |
|
| 55 |
-
# Add a question to the payload
|
| 56 |
-
|
| 57 |
-
|
|
|
|
|
|
|
|
|
|
| 58 |
|
| 59 |
# Send the request to the API and get the output
|
| 60 |
if st.button("Submit"):
|
|
|
|
| 52 |
}
|
| 53 |
)
|
| 54 |
|
| 55 |
+
# Add a question to the payload with a unique key
|
| 56 |
+
question = st.text_input("Enter your question", "Can you describe the image?", key="question_input")
|
| 57 |
+
|
| 58 |
+
# Add the question to the payload if provided
|
| 59 |
+
if question:
|
| 60 |
+
payload["question"] = question
|
| 61 |
|
| 62 |
# Send the request to the API and get the output
|
| 63 |
if st.button("Submit"):
|