SreyanG-NVIDIA commited on
Commit
e6023f9
·
verified ·
1 Parent(s): 8ba4304

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -54,7 +54,7 @@ def speech_prompt_infer(audio_prompt_file):
54
  def think_infer(audio_file, prompt_text):
55
  try:
56
  sound = llava.Sound(audio_file)
57
- full_prompt = f"<sound>\n{prompt_text}"
58
  response = model_think.generate_content([sound, full_prompt], generation_config=generation_config_single)
59
  return response
60
  except Exception as e:
@@ -183,7 +183,7 @@ with gr.Blocks(css="""
183
  ["static/think/audio1.wav", "What are the two people doing in the audio Choose the correct option from the following options:\n(A) One person is demonstrating how to use the equipment\n(B) The two people are discussing how to use the equipment\n(C) The two people are disassembling the equipment\n(D) One person is teaching another person how to use a piece of equipment\nPlease think and reason about the input audio before you respond."],
184
  ["static/think/audio2.wav", "Is the boat in the video moving closer or further away? Choose the correct option from the following options:\n(A) Closer\n(B) Further\nPlease think and reason about the input audio before you respond."],
185
  ],
186
- inputs=[audio_input_think, prompt_input_think+"\nPlease think and reason about the input music before you respond."],
187
  label="🧪 Try Examples"
188
  )
189
 
 
54
  def think_infer(audio_file, prompt_text):
55
  try:
56
  sound = llava.Sound(audio_file)
57
+ full_prompt = f"<sound>\n{prompt_text}\nPlease think and reason about the input music before you respond."
58
  response = model_think.generate_content([sound, full_prompt], generation_config=generation_config_single)
59
  return response
60
  except Exception as e:
 
183
  ["static/think/audio1.wav", "What are the two people doing in the audio Choose the correct option from the following options:\n(A) One person is demonstrating how to use the equipment\n(B) The two people are discussing how to use the equipment\n(C) The two people are disassembling the equipment\n(D) One person is teaching another person how to use a piece of equipment\nPlease think and reason about the input audio before you respond."],
184
  ["static/think/audio2.wav", "Is the boat in the video moving closer or further away? Choose the correct option from the following options:\n(A) Closer\n(B) Further\nPlease think and reason about the input audio before you respond."],
185
  ],
186
+ inputs=[audio_input_think, prompt_input_think],
187
  label="🧪 Try Examples"
188
  )
189