diff --git a/autogen/agentchat/groupchat.py b/autogen/agentchat/groupchat.py index b0f0b9520aa..a648c95e758 100644 --- a/autogen/agentchat/groupchat.py +++ b/autogen/agentchat/groupchat.py @@ -1264,6 +1264,10 @@ async def a_run_chat( else: # admin agent is not found in the participants raise + except NoEligibleSpeaker: + # No eligible speaker, terminate the conversation + break + if reply is None: break # The speaker sends the message without requesting a reply