with gr.Blocks(css="#chatbot {overflow:auto; height:500px;}") as demo:
gr.Markdown("
Visual ChatGPT
")
gr.Markdown(
"""This is a demo to the work [Visual ChatGPT: Talking, Drawing and Editing with Visual Foundation Models](https://github.com/microsoft/visual-chatgpt).
This space connects ChatGPT and a series of Visual Foundation Models to enable sending and receiving images during chatting.
"""
)
chatbot = gr.Chatbot(elem_id="chatbot", label="Visual ChatGPT")
state = gr.State([])
with gr.Row(visible=False) as input_raws:
with gr.Column(scale=0.7):
txt = gr.Textbox(show_label=False, placeholder="Enter text and press enter, or upload an image").style(container=False)
with gr.Column(scale=0.10, min_width=0):
run = gr.Button("🏃♂️Run")
with gr.Column(scale=0.10, min_width=0):
clear = gr.Button("🔄Clear️")
demo.queue(concurrency_count=10).launch(server_name="0.0.0.0", server_port=7860)