My Agent is not stopping even i use TERMINATE #5778
Unanswered
sunilsvsnlr
asked this question in
Q&A
Replies: 1 comment 2 replies
-
Please read the section in tutorial about termination, and consider creating your own custom termination condition. https://microsoft.github.io/autogen/stable/user-guide/agentchat-user-guide/tutorial/termination.html Most likely, each application scenario requires a different type of termination setting, relying on model to generate |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm using RoundRobinGroupChat, here I'm using two agents QueryAssistant and CodeExectuor. Its working fine but after successful execution of code it should terminate and ask for new question, if code execution is failed it should again call QueryAssistant to generate new version of code to execute properly. Once successful execution it should terminate and ask new question. Below is my code for reference. Please suggest me.
Below is the code
https://github.com/sunilsvsnlr/autogendemos/blob/main/roundrobingroupchat_demo.py
Console output:
---------- assistant ----------
To find the maximum project cost from the merged data, we need to follow these steps:
cost
column to a numeric format if it's not already.cost
column.Here's how you can implement this using Python:
This script will load the data, convert the
cost
column to a numeric format, and then find and print the maximum value in thecost
column. If there are any errors converting the values, they will be handled by setting them to NaN and ignored during calculations.---------- code_executor ----------
The maximum project cost till now is: 990639.66
---------- assistant ----------
Great! It looks like the script successfully loaded the data from the JSON file and found the maximum project cost, which is $990,639.66.
If you have any more questions or need further analysis, feel free to ask! If you're done with this task, I'll terminate.
---------- code_executor ----------
No code blocks found in the thread. Please provide at least one markdown-encoded code block to execute (i.e., quoting code in
python or
sh code blocks).---------- assistant ----------
I apologize for any confusion earlier. Here's a simple Python script that finds the maximum project cost from the merged data:
To execute this script, you can copy and paste it into a Python environment like Jupyter Notebook, PyCharm, or any other Python IDE. Make sure you have Pandas installed (
pip install pandas
) before running the code.---------- code_executor ----------
The maximum project cost till now is: 990639.66
Beta Was this translation helpful? Give feedback.
All reactions