Skip to main content
Marvin 3 combines Marvin’s structured-output helpers with a task engine derived from ControlFlow. Model access is provided by Pydantic AI.

Marvin 2.x

The cast, classify, extract, generate, and fn entry points remain available. Check their current signatures; do not assume every model, image, or audio integration from 2.x is present. For a general task, use marvin.run with a result_type:
generate returns a list even when requesting one value. Helpers such as extract accept agent=...; run and Task accept agents=[...].

ControlFlow

Replace model identifiers with Pydantic AI’s provider:model-name format. Replace Flow contexts with Thread contexts:
Use ordinary Python functions in place of a @flow decorator. For work with dependencies, construct tasks and call run_tasks.

Storage and teams

Thread/message history is stored in a database, SQLite by default. Vector memory is separate and depends on a provider; see memory. Setting MARVIN_DATABASE_URL does not configure vector memory. All team classes are deprecated. Coordinate individual agents explicitly rather than porting team or swarm orchestration. See model configuration, database migrations, and the examples for current usage.