Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
|
4 |
import os
|
5 |
import openai
|
6 |
-
import gradio
|
7 |
|
8 |
import torch
|
9 |
from diffusers import StableDiffusionPipeline
|
@@ -77,13 +77,13 @@ def predict(input, manual_query_repacement, history=[]):
|
|
77 |
|
78 |
|
79 |
|
80 |
-
inputText =
|
81 |
-
manual_query =
|
82 |
|
83 |
output_img = gr.Gallery(label="Generated image")
|
84 |
output_img.style(grid=2)
|
85 |
|
86 |
-
|
87 |
inputs=[inputText,manual_query,'state'],
|
88 |
|
89 |
outputs=["chatbot",'state', output_img]).launch()
|
|
|
3 |
|
4 |
import os
|
5 |
import openai
|
6 |
+
import gradio as gr
|
7 |
|
8 |
import torch
|
9 |
from diffusers import StableDiffusionPipeline
|
|
|
77 |
|
78 |
|
79 |
|
80 |
+
inputText = gr.Textbox(value="tmp")
|
81 |
+
manual_query = gr.Textbox(placeholder="Input any query here, to replace the image generation query builder entirely.")
|
82 |
|
83 |
output_img = gr.Gallery(label="Generated image")
|
84 |
output_img.style(grid=2)
|
85 |
|
86 |
+
gr.Interface(fn=predict,
|
87 |
inputs=[inputText,manual_query,'state'],
|
88 |
|
89 |
outputs=["chatbot",'state', output_img]).launch()
|