Autogen agent chat termination not terminating the way I want it to. #6568
Unanswered
AbhijitAlok
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have a society of mind agent which internally has 2 assistant agents. More specifically a code writer agent and a code critic agent. Once the critic approves the code, it executes it using a tool provided to it. I want the chat to terminate as soon as the critic agent is satisfied with the execution but for some reason, after executing, it is calling the code writer agent again unnecessarily, I am not sure what is triggering it. No amount of system instructions is able to solve this.
Output after the critic agent deems the code executable:
source='code_critic_agent' models_usage=None metadata={} content=[FunctionExecutionResult(content='Number of items with Cost Percentage between 2-5%: 228\nNumber of items with Cost Percentage between 5-10%: 303\nNumber of items with Cost Percentage above 10%: 314\n', name='modified_code_executor', call_id='call_AVTnbI3A1u3Spz2N7yoX2WPN', is_error=False)] type='ToolCallExecutionEvent'
---------- message ----------
source='code_critic_agent' models_usage=None metadata={} content='Number of items with Cost Percentage between 2-5%: 228\nNumber of items with Cost Percentage between 5-10%: 303\nNumber of items with Cost Percentage above 10%: 314\n' type='ToolCallSummaryMessage'
---------- message ----------
(I do not want this call)
source='code_writer_agent' models_usage=RequestUsage(prompt_tokens=1083, completion_tokens=26) metadata={} content='The script runs successfully and produces the desired results for each specified range. If you have any other questions, feel free to ask!' type='TextMessage'
---------- message ----------
(Termination Condition)
source='code_critic_agent' models_usage=RequestUsage(prompt_tokens=1591, completion_tokens=5) metadata={} content='code-executed' type='TextMessage'
---------- message ----------
Beta Was this translation helpful? Give feedback.
All reactions