Collaborative agent frameworks in CAMEL: autonomous social behaviors, role-based task solving, and turn-based agent societies.
The society module simulates agent social behaviors and collaborative workflows.
It powers autonomous, multi-role agents that can plan, debate, critique, and solve tasks together, minimizing human intervention while maximizing alignment with your goals.
Task: An objective or idea, given as a simple prompt.
AI User: The role responsible for providing instructions or challenges.
AI Assistant: The role tasked with generating solutions, plans, or step-by-step responses.
Critic (optional): An agent that reviews or critiques the assistant’s responses for quality control.
<ASSISTANT_ROLE>
, I am <USER_ROLE>
Solution: <YOUR_SOLUTION>
Next request.
All RolePlaying Parameters
Attribute | Type | Description |
---|---|---|
assistant_role_name | str | Name of assistant’s role |
user_role_name | str | Name of user’s role |
critic_role_name | str | Name of critic’s role (optional) |
task_prompt | str | Prompt for the main task |
with_task_specify | bool | Enable task specification agent |
with_task_planner | bool | Enable task planner agent |
with_critic_in_the_loop | bool | Include critic in conversation loop |
critic_criteria | str | How the critic scores/evaluates outputs |
model | BaseModelBackend | Model backend for responses |
task_type | TaskType | Type/category of the task |
assistant_agent_kwargs | Dict | Extra options for assistant agent |
user_agent_kwargs | Dict | Extra options for user agent |
task_specify_agent_kwargs | Dict | Extra options for task specify agent |
task_planner_agent_kwargs | Dict | Extra options for task planner agent |
critic_kwargs | Dict | Extra options for critic agent |
sys_msg_generator_kwargs | Dict | Options for system message generator |
extend_sys_msg_meta_dicts | List[Dict] | Extra metadata for system messages |
extend_task_specify_meta_dict | Dict | Extra metadata for task specification |
output_language | str | Target output language |
Tips & Best Practices
with_task_specify
and with_task_planner
options for highly complex tasks.More Examples & Advanced Use
examples/society/
in the CAMEL repo for advanced agent society demos.