motleycrew.agents.crewai.crewai_agent
Classes
|
MotleyCrew wrapper for CrewAI Agent. |
- class motleycrew.agents.crewai.crewai_agent.CrewAIMotleyAgent(role: str, goal: str, backstory: str, prompt_prefix: str | None = None, description: str | None = None, delegation: bool = False, tools: Sequence[MotleySupportedTool] | None = None, force_output_handler: bool = False, llm: Any | None = None, verbose: bool = False)
Bases:
CrewAIMotleyAgentParentMotleyCrew wrapper for CrewAI Agent.
This wrapper is made to mimic the CrewAI agent’s interface. That is why it has mostly the same arguments.
- __init__(role: str, goal: str, backstory: str, prompt_prefix: str | None = None, description: str | None = None, delegation: bool = False, tools: Sequence[MotleySupportedTool] | None = None, force_output_handler: bool = False, llm: Any | None = None, verbose: bool = False)
- Parameters:
role –
roleparam of the CrewAI Agent.goal –
goalparam of the CrewAI Agent.backstory –
backstoryparam of the CrewAI Agent.prompt_prefix – Prefix to the agent’s prompt. Can be used for providing additional context, such as the agent’s role or backstory.
description –
Description of the agent.
Unlike the prompt prefix, it is not included in the prompt. The description is only used for describing the agent’s purpose when giving it as a tool to other agents.
delegation – Whether to allow delegation or not. Delegation is not supported in this wrapper. Instead, pass the agents you want to delegate to as tools.
tools – Tools to add to the agent.
llm – LLM instance to use.
force_output_handler – Whether to force the use of an output handler. NOTE: This is currently not supported for CrewAI agents.
verbose – Whether to log verbose output.