graph_utils
autogen.graph_utils.check_graph_validity
check_graph_validity
allowed_speaker_transitions_dict: A dictionary of keys and list as values. The keys are the names of the agents, and the values are the names of the agents that the key agent can transition to. agents: A list of Agents
Checks for the following: Errors
- The dictionary must have a structure of keys and list as values
- Every key exists in agents.
- Every value is a list of Agents (not string).
Warnings:
- Warning if there are isolated agent nodes
- Warning if the set of agents in allowed_speaker_transitions do not match agents
- Warning if there are duplicated agents in any values of
allowed_speaker_transitions_dict
Name | Description |
---|---|
allowed_speaker_transitions_dict | Type: dict |
agents | Type: list[autogen.agentchat.agent.Agent] |