Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -378,20 +378,20 @@ def process_and_query(input_language=None, audio_input=None, image_input=None, t
|
|
| 378 |
# Initialize the conditional variables
|
| 379 |
combined_text = ""
|
| 380 |
image_description = ""
|
| 381 |
-
|
| 382 |
-
|
| 383 |
-
|
| 384 |
-
combined_text
|
|
|
|
| 385 |
|
| 386 |
# Process audio input
|
| 387 |
if audio_input is not None:
|
| 388 |
audio_text = process_speech(input_language, audio_input)
|
| 389 |
combined_text += "\n\n**Audio Input:**\n" + audio_text
|
| 390 |
|
| 391 |
-
# Process
|
| 392 |
-
if
|
| 393 |
-
|
| 394 |
-
combined_text += "\n\n**Image Input:**\n" + image_text
|
| 395 |
|
| 396 |
# Check if combined text is empty
|
| 397 |
if not combined_text.strip():
|
|
|
|
| 378 |
# Initialize the conditional variables
|
| 379 |
combined_text = ""
|
| 380 |
image_description = ""
|
| 381 |
+
# Process image input
|
| 382 |
+
if image_input is not None:
|
| 383 |
+
image_text = process_image(image_input)
|
| 384 |
+
combined_text += "\n\n**Image Input:**\n" + image_text
|
| 385 |
+
|
| 386 |
|
| 387 |
# Process audio input
|
| 388 |
if audio_input is not None:
|
| 389 |
audio_text = process_speech(input_language, audio_input)
|
| 390 |
combined_text += "\n\n**Audio Input:**\n" + audio_text
|
| 391 |
|
| 392 |
+
# Process text input
|
| 393 |
+
if text_input is not None:
|
| 394 |
+
combined_text = "The user asks the following to his health adviser: " + text_input
|
|
|
|
| 395 |
|
| 396 |
# Check if combined text is empty
|
| 397 |
if not combined_text.strip():
|