Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -78,9 +78,11 @@ def respond(message, history):
|
|
78 |
|
79 |
return response['choices'][0]['message']['content'].strip()
|
80 |
|
81 |
-
#
|
82 |
-
|
83 |
|
84 |
-
#
|
85 |
-
|
86 |
-
|
|
|
|
|
|
78 |
|
79 |
return response['choices'][0]['message']['content'].strip()
|
80 |
|
81 |
+
# Create a Chatbot component with an initial message
|
82 |
+
chatbot_ui = gr.Chatbot(value=[("🤖", "Hey! I’m your Gen-Z watch buddy.\nI help you find your next favorite TV show based on what you like, your age, or your favorite genre. Just tell me what you're into!")])
|
83 |
|
84 |
+
# Create the ChatInterface using the custom chatbot component
|
85 |
+
chat_interface = gr.ChatInterface(fn=respond, chatbot=chatbot_ui, type="messages")
|
86 |
+
|
87 |
+
# Launch it
|
88 |
+
chat_interface.launch()
|