File size: 1,084 Bytes
af40894
 
27c78c7
42528e1
a4e0c15
524b1bf
a4e0c15
fb05ecc
 
fc1aea8
 
 
 
a4e0c15
27c78c7
af40894
badd9c9
121d761
4342456
42528e1
4342456
badd9c9
af40894
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import gradio as gr


def greet(description,color,features):
    
    final = 'white background '
    
    description = 'description:' + description.replace(' ', '-')

    color = ' color:' + '-'.join(color)
   

    final += description + color
    
    return final

iface = gr.Interface(fn=greet, 
                     inputs=[gr.Textbox(label='Description'),
                            gr.Dropdown(label='Color',choices=['Beige','Black','Blue','Brown','Green','Grey','Orange','Pink','Purple','Red','White','Yellow'],multiselect=True),
                            gr.Dropdown(label='Features',choices=['3/4-sleeve','Babydoll','Closed-Back','Corset','Crochet','Cutouts','Draped','Floral','Gloves','Halter','Lace','Long','Long-Sleeve','Midi','No-Slit','Off-The-Shoulder','One-Shoulder','Open-Back','Pockets','Print','Puff-Sleeve','Ruched','Satin','Sequins','Shimmer','Short','Short-Sleeve','Side-Slit','Square-Neck','Strapless','Sweetheart-Neck','Tight','V-Neck','Velvet','Wrap'],multiselect=True)
                            ], 
                     outputs="text")
iface.launch()