Spaces:
Runtime error
Runtime error
Update pages/1_Simple-Gemini.py
Browse files- pages/1_Simple-Gemini.py +12 -12
pages/1_Simple-Gemini.py
CHANGED
@@ -168,18 +168,18 @@ def main():
|
|
168 |
)
|
169 |
|
170 |
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
|
176 |
-
|
177 |
-
|
178 |
-
|
179 |
-
|
180 |
-
|
181 |
-
|
182 |
-
|
183 |
|
184 |
#result = app.invoke({"input": input_text, "chat_history": [], "return_direct": False})
|
185 |
|
|
|
168 |
)
|
169 |
|
170 |
|
171 |
+
workflow.add_edge('action', 'agent')
|
172 |
+
workflow.add_edge('final', END)
|
173 |
+
# uncomment if you want to always calls a certain tool first
|
174 |
+
# workflow.add_edge('first_agent', 'action')
|
175 |
+
app = workflow.compile()
|
176 |
+
|
177 |
+
inputs = {"input": input_text, "chat_history": [], "return_direct": False}
|
178 |
+
results = []
|
179 |
+
for s in app.stream(inputs):
|
180 |
+
result = list(s.values())[0]
|
181 |
+
results.append(result)
|
182 |
+
st.write(result) # Display each step's output
|
183 |
|
184 |
#result = app.invoke({"input": input_text, "chat_history": [], "return_direct": False})
|
185 |
|