HakimHa commited on
Commit
079a629
Β·
1 Parent(s): c48ac83

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -3
app.py CHANGED
@@ -42,13 +42,14 @@ def handle_audio(audio):
42
  return handle_text(transcriptions)
43
 
44
  def chatbot(text, img, audio):
45
- text_output = handle_text(text) if text else ''
46
- img_output = handle_image(img) if img else ''
47
- audio_output = handle_audio(audio) if audio else ''
48
 
49
  outputs = [o for o in [text_output, img_output, audio_output] if o]
50
  return "\n".join(outputs)
51
 
 
52
  iface = gr.Interface(
53
  fn=chatbot,
54
  inputs=[
 
42
  return handle_text(transcriptions)
43
 
44
  def chatbot(text, img, audio):
45
+ text_output = handle_text(text) if text.any() else ''
46
+ img_output = handle_image(img) if img.any() else ''
47
+ audio_output = handle_audio(audio) if audio.any() else ''
48
 
49
  outputs = [o for o in [text_output, img_output, audio_output] if o]
50
  return "\n".join(outputs)
51
 
52
+
53
  iface = gr.Interface(
54
  fn=chatbot,
55
  inputs=[