Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for async group chat resume - full chat history for each agent #3558

Merged
merged 2 commits into from
Sep 25, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 4 additions & 5 deletions autogen/agentchat/groupchat.py
Original file line number Diff line number Diff line change
Expand Up @@ -1398,13 +1398,12 @@ async def a_resume(
if not message_speaker_agent and message["name"] == self.name:
message_speaker_agent = self

# Add previous messages to each agent (except their own messages and the last message, as we'll kick off the conversation with it)
# Add previous messages to each agent (except the last message, as we'll kick off the conversation with it)
if i != len(messages) - 1:
for agent in self._groupchat.agents:
if agent.name != message["name"]:
await self.a_send(
message, self._groupchat.agent_by_name(agent.name), request_reply=False, silent=True
)
await self.a_send(
message, self._groupchat.agent_by_name(agent.name), request_reply=False, silent=True
)

# Add previous message to the new groupchat, if it's an admin message the name may not match so add the message directly
if message_speaker_agent:
Expand Down