Meet your cheerful chat buddy! This app is your optimistic friend who always sees the bright side. From everyday questions to life’s big moments, get uplifting responses and positive vibes that’ll make you smile, no matter what you’re asking about!

Update app.py
All checks were successful
society-ai-hub-container-cache Actions Demo / build (push) Successful in 26s

This commit is contained in:
LiorDav 2024-11-06 19:23:12 +00:00
parent 22c79ebf16
commit c6c991bc52

22
app.py

@ -14,9 +14,9 @@ SYSTEM_PROMPT = {
} }
# Background CSS to include a background image # Background CSS to include a background image
'''BACKGROUND_CSS = BACKGROUND_CSS = """
body { .gradio-container {
background-image: url('https://www.imghippo.com/i/Es4003HeI.png'); background-image: url('https://i.pinimg.com/originals/0c/6a/19/0c6a19fabcebb129c6b65d86c0b0fae6.jpg');
background-size: cover; background-size: cover;
background-position: center; background-position: center;
background-repeat: no-repeat; background-repeat: no-repeat;
@ -24,13 +24,19 @@ body {
} }
footer { footer {
visibility: hidden; visibility: hidden;
}''' }
"""
with gr.Blocks(
# Custom Gradio app with additional features css=BACKGROUND_CSS,
with gr.Blocks(css=BACKGROUND_CSS) as demo: theme=gr.themes.Soft(
primary_hue="pink",
secondary_hue="pink",
neutral_hue="purple",
)
) as demo:
# User input components # User input components
user_name = gr.Textbox(label="Enter your name", placeholder="Your name here...", value="What is your name?") user_name = gr.Textbox(label="Enter your name", placeholder="Your name here...", value="Guest")
emotion_picker = gr.Dropdown(choices=["😁", "😩", "😡", "😢","😭","😒","😣","🥰","😬"], label="Select your mood", value="🙂") emotion_picker = gr.Dropdown(choices=["😁", "😩", "😡", "😢","😭","😒","😣","🥰","😬"], label="Select your mood", value="🙂")
chatbot = gr.Chatbot(type="messages") chatbot = gr.Chatbot(type="messages")
msg = gr.Textbox(placeholder="Type your message here...") msg = gr.Textbox(placeholder="Type your message here...")