visheratin commited on
Commit
67e4fcc
1 Parent(s): e4536f3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -73,7 +73,7 @@ def answer_question(image, question, max_crops, num_tokens):
73
  output_started = False
74
  for new_text in streamer:
75
  if not output_started:
76
- if "<assistant>" in new_text:
77
  output_started = True
78
  continue
79
  buffer += new_text
@@ -105,4 +105,4 @@ with gr.Blocks() as demo:
105
  submit.click(answer_question, [img, prompt, max_crops, num_tokens], output)
106
  prompt.submit(answer_question, [img, prompt, max_crops, num_tokens], output)
107
 
108
- demo.queue().launch(debug=True)
 
73
  output_started = False
74
  for new_text in streamer:
75
  if not output_started:
76
+ if "<|im_start|>assistant" in new_text:
77
  output_started = True
78
  continue
79
  buffer += new_text
 
105
  submit.click(answer_question, [img, prompt, max_crops, num_tokens], output)
106
  prompt.submit(answer_question, [img, prompt, max_crops, num_tokens], output)
107
 
108
+ demo.queue().launch(debug=True, share=True)