update task done logic

This commit is contained in:
Wendong
2025-03-17 19:11:57 +08:00
parent 3641e4b04f
commit fcbf87f028

View File

@@ -450,12 +450,6 @@ def run_society(
"""
input_msg = society.init_chat(init_prompt)
for _round in range(round_limit):
# Check if previous user response had TASK_DONE before getting next assistant response
if _round > 0 and (
"TASK_DONE" in input_msg.content or "任务已完成" in input_msg.content
):
break
assistant_response, user_response = society.step(input_msg)
overall_completion_token_count += (
assistant_response.info["usage"]["completion_tokens"]