Spaces:
Sleeping
Sleeping
Nguyen Nhu Trung
commited on
Commit
·
8e8b0af
1
Parent(s):
d78e24c
fix bug
Browse files
agent.py
CHANGED
|
@@ -64,8 +64,8 @@ graph = builder.compile()
|
|
| 64 |
|
| 65 |
def get_answer(query):
|
| 66 |
messages = [HumanMessage(content=query)]
|
| 67 |
-
|
| 68 |
-
return
|
| 69 |
|
| 70 |
if __name__ == "__main__":
|
| 71 |
question = "In the video https://www.youtube.com/watch?v=L1vXCYZAYYM, what is the highest number of bird species to be on camera simultaneously?"
|
|
|
|
| 64 |
|
| 65 |
def get_answer(query):
|
| 66 |
messages = [HumanMessage(content=query)]
|
| 67 |
+
results = graph.invoke({"messages": messages})
|
| 68 |
+
return results["messages"][-1].content
|
| 69 |
|
| 70 |
if __name__ == "__main__":
|
| 71 |
question = "In the video https://www.youtube.com/watch?v=L1vXCYZAYYM, what is the highest number of bird species to be on camera simultaneously?"
|