Tonic commited on
Commit
3c3d6da
1 Parent(s): 749f0e0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -372,6 +372,10 @@ def process_and_query(input_language=None, audio_input=None, image_input=None, t
372
  # Convert the Vectara response to Markdown
373
  markdown_output = convert_to_markdown(vectara_response_json)
374
 
 
 
 
 
375
  # Process the summary with OpenAI
376
  final_response = process_summary_with_openai(markdown_output)
377
  print("Final Response:", final_response) # Debug print
@@ -382,10 +386,6 @@ def process_and_query(input_language=None, audio_input=None, image_input=None, t
382
 
383
  return final_response, hallucination_label
384
 
385
- except Exception as e:
386
- print("Exception:", e) # Debug print
387
- return str(e), "Error in processing"
388
-
389
 
390
 
391
  welcome_message = """
 
372
  # Convert the Vectara response to Markdown
373
  markdown_output = convert_to_markdown(vectara_response_json)
374
 
375
+ # Append the original image description to the markdown output
376
+ if image_description:
377
+ markdown_output += "\n\n**Original Image Description:**\n" + image_description
378
+
379
  # Process the summary with OpenAI
380
  final_response = process_summary_with_openai(markdown_output)
381
  print("Final Response:", final_response) # Debug print
 
386
 
387
  return final_response, hallucination_label
388
 
 
 
 
 
389
 
390
 
391
  welcome_message = """