import gradio as gr
import spaces
from chatbot import model_inference, chatbot
from voice_chat import respond
# Define Gradio theme
theme = gr.themes.Soft(
primary_hue="sky",
secondary_hue="violet",
neutral_hue="gray",
font=[gr.themes.GoogleFont('orbitron')]
)
# Create Gradio blocks for different functionalities
# Chat interface block
# with gr.Blocks(
# # css=""".gradio-container .avatar-container {height: 40px width: 40px !important;} #duplicate-button {margin: auto; color: white; background: #f1a139; border-radius: 100vh; margin-top: 2px; margin-bottom: 2px;}""",
# ) as chat:
# gr.HTML("")
with gr.Blocks() as chat:
gr.HTML("")
# Voice chat block
with gr.Blocks() as voice:
gr.HTML("")
with gr.Blocks() as image:
gr.HTML("")
with gr.Blocks() as instant2:
gr.HTML("")
with gr.Blocks() as video:
gr.Markdown("""More Models are coming""")
gr.TabbedInterface([ instant2], ['Instant🎥'])
# Main application block
with gr.Blocks(theme=theme, title="Welcome to the Future of Fashion") as demo:
gr.Markdown("# AI Wardrobe")
gr.TabbedInterface([chat, voice, image, video], ['💬 SuperChat - StyleDialogue','🗣 Voice Chat- SilkTalk', '🖼 Image Engine - StyleVision', '🎥 Video Engine - ShowcaseVision'])
demo.queue(max_size=300)
demo.launch()