AgentContext.communicate response fix
Return response of chain for run_cli.py
frdel committed
Oct 18, 2024 at 16:20 UTC
31494490c08f2d8a43a8441ac11a7523c66e576e
1 file changed
+2
-1
agent.py
+2
-1
@@ -108,7 +108,8 @@ class AgentContext:
108
response = await agent.monologue(msg_template)
109
superior = agent.data.get("superior", None)
110
if superior:
111
- await self._process_chain(superior, response, False)
111
+ response = await self._process_chain(superior, response, False)
112
+ return response
113
except Exception as e:
114
agent.handle_critical_exception(e)
115