Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -68,7 +68,7 @@ def answer_question(image, question, max_crops, num_tokens):
|
|
68 |
for new_text in streamer:
|
69 |
buffer += new_text
|
70 |
if len(buffer) > 1:
|
71 |
-
yield buffer
|
72 |
|
73 |
|
74 |
with gr.Blocks() as demo:
|
@@ -95,4 +95,4 @@ with gr.Blocks() as demo:
|
|
95 |
submit.click(answer_question, [img, prompt, max_crops, num_tokens], output)
|
96 |
prompt.submit(answer_question, [img, prompt, max_crops, num_tokens], output)
|
97 |
|
98 |
-
demo.queue().launch(debug=True)
|
|
|
68 |
for new_text in streamer:
|
69 |
buffer += new_text
|
70 |
if len(buffer) > 1:
|
71 |
+
yield buffer.replace(prompt, "")
|
72 |
|
73 |
|
74 |
with gr.Blocks() as demo:
|
|
|
95 |
submit.click(answer_question, [img, prompt, max_crops, num_tokens], output)
|
96 |
prompt.submit(answer_question, [img, prompt, max_crops, num_tokens], output)
|
97 |
|
98 |
+
demo.queue().launch(debug=True, share=True)
|