|
|
@ -248,8 +248,8 @@ class GroupChat:
|
|
|
|
Raises:
|
|
|
|
Raises:
|
|
|
|
ValueError: If any required components are missing or invalid
|
|
|
|
ValueError: If any required components are missing or invalid
|
|
|
|
"""
|
|
|
|
"""
|
|
|
|
if not self.agents:
|
|
|
|
if len(self.agents)<2:
|
|
|
|
raise ValueError("No agents provided")
|
|
|
|
raise ValueError("At least two agents are required for a group chat")
|
|
|
|
if self.speaker_fn is None:
|
|
|
|
if self.speaker_fn is None:
|
|
|
|
raise ValueError("No speaker function provided")
|
|
|
|
raise ValueError("No speaker function provided")
|
|
|
|
if self.max_loops <= 0:
|
|
|
|
if self.max_loops <= 0:
|
|
|
|