Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -45,8 +45,9 @@ def get_top_chunks(query):
|
|
| 45 |
|
| 46 |
def chatbot_response(message, history):
|
| 47 |
top_chunks = get_top_chunks(message)
|
| 48 |
-
|
| 49 |
-
|
|
|
|
| 50 |
|
| 51 |
chatbot = gr.ChatInterface(fn=chatbot_response, title="RAG Chatbot")
|
| 52 |
chatbot.launch()
|
|
|
|
| 45 |
|
| 46 |
def chatbot_response(message, history):
|
| 47 |
top_chunks = get_top_chunks(message)
|
| 48 |
+
intro = "Hi! I’m your Rochester food assistant 🍽️ Here are some great nearby options:\n\n"
|
| 49 |
+
response = intro + "\n".join([f"• {chunk}" for chunk in top_chunks])
|
| 50 |
+
return [{"role": "assistant", "content": response}]
|
| 51 |
|
| 52 |
chatbot = gr.ChatInterface(fn=chatbot_response, title="RAG Chatbot")
|
| 53 |
chatbot.launch()
|