autogen_agentchat.task#

class autogen_agentchat.task.MaxMessageTermination(max_messages: int)[source]#

Bases: TerminationCondition

Terminate the conversation after a maximum number of messages have been exchanged.

Parameters:

max_messages – The maximum number of messages allowed in the conversation.

async reset() None[source]#

Reset the termination condition.

property terminated: bool#

Check if the termination condition has been reached

class autogen_agentchat.task.StopMessageTermination[source]#

Bases: TerminationCondition

Terminate the conversation if a StopMessage is received.

async reset() None[source]#

Reset the termination condition.

property terminated: bool#

Check if the termination condition has been reached

class autogen_agentchat.task.TextMentionTermination(text: str)[source]#

Bases: TerminationCondition

Terminate the conversation if a specific text is mentioned.

Parameters:

text – The text to look for in the messages.

async reset() None[source]#

Reset the termination condition.

property terminated: bool#

Check if the termination condition has been reached