Update rag_langgraph.py
Browse files- rag_langgraph.py +4 -1
rag_langgraph.py
CHANGED
@@ -128,6 +128,8 @@ def run_multi_agent(prompt):
|
|
128 |
|
129 |
graph = workflow.compile()
|
130 |
|
|
|
|
|
131 |
for s in graph.stream(
|
132 |
{
|
133 |
"messages": [
|
@@ -137,6 +139,7 @@ def run_multi_agent(prompt):
|
|
137 |
):
|
138 |
if "__end__" not in s:
|
139 |
print(s)
|
|
|
140 |
print("----")
|
141 |
|
142 |
-
return
|
|
|
128 |
|
129 |
graph = workflow.compile()
|
130 |
|
131 |
+
result = ""
|
132 |
+
|
133 |
for s in graph.stream(
|
134 |
{
|
135 |
"messages": [
|
|
|
139 |
):
|
140 |
if "__end__" not in s:
|
141 |
print(s)
|
142 |
+
result += s
|
143 |
print("----")
|
144 |
|
145 |
+
return result
|