Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -50,10 +50,14 @@ def rag_bot(query):
|
|
| 50 |
|
| 51 |
return final_answer
|
| 52 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 53 |
if __name__ == "__main__":
|
| 54 |
chatbot = gr.Chatbot(avatar_images=["user.jpg", "bot.png"], height=600)
|
| 55 |
demo = gr.ChatInterface(
|
| 56 |
-
fn=
|
| 57 |
title="TraderFyles AI Assistant",
|
| 58 |
multimodal=False,
|
| 59 |
chatbot=chatbot,
|
|
|
|
| 50 |
|
| 51 |
return final_answer
|
| 52 |
|
| 53 |
+
def chat(query, chat_history):
|
| 54 |
+
response = rag_bot(query)
|
| 55 |
+
return response
|
| 56 |
+
|
| 57 |
if __name__ == "__main__":
|
| 58 |
chatbot = gr.Chatbot(avatar_images=["user.jpg", "bot.png"], height=600)
|
| 59 |
demo = gr.ChatInterface(
|
| 60 |
+
fn=chat,
|
| 61 |
title="TraderFyles AI Assistant",
|
| 62 |
multimodal=False,
|
| 63 |
chatbot=chatbot,
|