Spaces:
Paused
Paused
Fixed image size and layout issues
Browse files
app.py
CHANGED
@@ -159,7 +159,7 @@ if OPENAI_API_KEY:
|
|
159 |
print("OPENAI_API_KEY found in environment variables. Starting agent.")
|
160 |
bot.init_agent(OPENAI_API_KEY)
|
161 |
|
162 |
-
with gr.Blocks(css="#chatbot {overflow:auto; height:500px;}") as demo:
|
163 |
gr.Markdown("<h3><center>Visual ChatGPT</center></h3>")
|
164 |
gr.Markdown(
|
165 |
"""This is based on the [demo](https://huggingface.co/spaces/microsoft/visual_chatgpt) to the work [Visual ChatGPT: Talking, Drawing and Editing with Visual Foundation Models](https://github.com/microsoft/visual-chatgpt).<br>
|
@@ -181,11 +181,11 @@ with gr.Blocks(css="#chatbot {overflow:auto; height:500px;}") as demo:
|
|
181 |
with gr.Row(visible=getattr(bot, 'agent', False)) as input_raws:
|
182 |
with gr.Column(scale=0.7):
|
183 |
txt = gr.Textbox(show_label=False, placeholder="Enter text and press enter, or upload an image").style(container=False)
|
184 |
-
with gr.Column(scale=0.10, min_width=
|
185 |
run = gr.Button("🏃♂️Run")
|
186 |
-
with gr.Column(scale=0.10, min_width=
|
187 |
clear = gr.Button("🔄Clear️")
|
188 |
-
with gr.Column(scale=0.10, min_width=
|
189 |
btn = gr.UploadButton("🖼️Upload", file_types=["image"])
|
190 |
|
191 |
gr.Examples(
|
|
|
159 |
print("OPENAI_API_KEY found in environment variables. Starting agent.")
|
160 |
bot.init_agent(OPENAI_API_KEY)
|
161 |
|
162 |
+
with gr.Blocks(css="#chatbot {overflow:auto; height:500px;} .message img {max-width:90% !important; max-height:initial !important;}") as demo:
|
163 |
gr.Markdown("<h3><center>Visual ChatGPT</center></h3>")
|
164 |
gr.Markdown(
|
165 |
"""This is based on the [demo](https://huggingface.co/spaces/microsoft/visual_chatgpt) to the work [Visual ChatGPT: Talking, Drawing and Editing with Visual Foundation Models](https://github.com/microsoft/visual-chatgpt).<br>
|
|
|
181 |
with gr.Row(visible=getattr(bot, 'agent', False)) as input_raws:
|
182 |
with gr.Column(scale=0.7):
|
183 |
txt = gr.Textbox(show_label=False, placeholder="Enter text and press enter, or upload an image").style(container=False)
|
184 |
+
with gr.Column(scale=0.10, min_width=100):
|
185 |
run = gr.Button("🏃♂️Run")
|
186 |
+
with gr.Column(scale=0.10, min_width=100):
|
187 |
clear = gr.Button("🔄Clear️")
|
188 |
+
with gr.Column(scale=0.10, min_width=100):
|
189 |
btn = gr.UploadButton("🖼️Upload", file_types=["image"])
|
190 |
|
191 |
gr.Examples(
|