CrewAI — Agent, Task, Crew, Process + Flow for production
four primitives
Agent
role + goal + backstory + tools
backstory shapes tone + judgment
keep it tight (<200 words)
Task
description + expected_output
assigned to one Agent
reusable; composes into Crews
Crew
container: Agents + Tasks
owns the Process
Sequential | Hierarchical | Consensual
Process
execution strategy
Hierarchical adds manager
reach only for 4+ specialists
Crew autonomous collaboration
researcher outliner drafter
free-form; Process picks shape at runtime
Hierarchical: manager Agent picks next specialist
good for: exploration, first drafts, brainstorming
bad for: prod replay, deterministic audits, SLAs
output variance: high
LLM picks Task order if Process=Hierarchical
debug path: read the trace; no graph to read
Flow event-driven deterministic
@start researched outlined drafted
code owns the graph; engineers own the shape
@listen("researched"): fires when that topic emits
good for: production, replay, SLAs, audits
bad for: open-ended creativity
2026 docs: start production with Flow
fold Crews in as sub-steps when autonomy earns cost
observability: every event is a span
same three-step task; Crew is fluid, Flow is fixed. choice is operational, not architectural.