Skip to main content

CrewAI

The CrewAI integration wraps a Crew in an Arclasp Chain and records task-level governance events using the callback or compatibility hooks available in the installed CrewAI version. There is an important enforcement boundary: The current CrewAI adapter is not a strict pre-execution barrier for every task body. Read the limitation below before using it for irreversible side effects.

Install

The current package constraint is crewai>=1.10.0,<2.0.0. The CrewAI optional dependency is installed only on Python versions below 3.14.

Add Arclasp to an existing Crew

This is an integration fragment. Build your Agent, Task, and Crew objects normally before wrapping the Crew.

How the adapter works

The integration supports the CrewAI lifecycle hooks available in the supported package range and retains a compatibility patching path for versions where those hooks are insufficient. The goal is to associate task activity with one Arclasp Chain without requiring you to rewrite the entire Crew.

Critical limitation: do not assume universal pre-side-effect interception

The adapter instruments CrewAI task lifecycle through the hooks and compatibility paths available in the installed CrewAI version. That is useful for Chain context and task evidence, but it should not be treated as a universal guarantee that every side effect inside every task is intercepted before execution. If a financial transaction, production write, external communication, or other irreversible operation must not execute before governance resolves, place the Arclasp boundary inside your task/tool implementation immediately before the side effect:
The important part is that send_payment(...) happens only after the governance call returns successfully.

Sync and async

Prefer:
Synchronous kickoff is available for synchronous applications:
Do not use the synchronous wrapper from inside an already running async event loop.

Tool calls inside tasks

The CrewAI adapter is task-oriented. Individual CrewAI tool calls are not automatically guaranteed to appear as separate governed tool events. Instrument consequential tool calls directly when you need precise pre-execution control and evidence.

When to use the CrewAI adapter

Use the wrapper when task-level Chain context and evidence are useful. Use manual arclasp.Chain instrumentation at the exact side-effect boundary when prevention must happen before an irreversible operation.