File size: 466 Bytes
9ceeeea
 
09b04d0
 
65c5efc
20bfbdf
 
 
09b04d0
021d2eb
 
 
 
51d51b1
d7a28ac
021d2eb
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import gradio as gr

api = gr.Interface.load("models/Linaqruf/anything-v3.0")

def model(prompt, ngPrompt):
    data = [prompt, ngPrompt]
    result = api([a for a in data if a != ""])
    return result

with gr.Blocks() as anything:
    prompt = gr.Textbox(label="Prompt")
    ngPrompt = gr.Textbox(label="Negative Prompt")
    btn = gr.Button(value="Submit")
    image = gr.Image()
    btn.click(fn=api, inputs=[prompt, ngPrompt], outputs=image)

anything.launch()