Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Mistral Workflows

Build reliable, production-grade AI workflows with Python.

Overview

Mistral Workflows is a Python SDK for building AI-powered workflows with built-in reliability, observability, and scalability. It provides fault tolerance, durability, and exactly-once execution guarantees.

Features

  • Simple Python API: Define workflows using Python decorators
  • Built-in Reliability: Automatic retries, timeouts, and error handling
  • Distributed Execution: Scale workflows across multiple workers
  • LLM Integration: Native support for Mistral AI and other LLM providers
  • Observability: Distributed tracing, structured logging, and event streaming
  • Type Safety: Full type hints and Pydantic validation

Installation

pip install mistralai-workflows

Quick Start

from datetime import timedelta

from mistralai.workflows import workflow, activity


@activity
async def get_weather(city: str) -> str:
    # Your activity implementation
    return f"Weather in {city}: Sunny"


@workflow.define
class WeatherWorkflow:
    @workflow.run
    async def run(self, city: str) -> str:
        weather = await workflow.execute_activity(
            get_weather,
            city,
            start_to_close_timeout=timedelta(seconds=10),
        )
        return weather

Documentation

For full documentation, visit docs.mistral.ai/workflows/getting-started/introduction

Examples

The SDK includes comprehensive examples in the mistralai/workflows/examples directory. You can run all examples with a single command:

# Run all example workflows in a single worker
python -m mistralai_workflow_tests.examples.all_workflows_worker

Worker configuration

By default, run_worker reads configuration from environment variables when it starts:

from mistralai import workflows

await workflows.run_worker([WeatherWorkflow])

Applications can also pass configuration in code. Values provided in code override environment variables; all other values use the environment or SDK defaults:

from mistralai import workflows

config = workflows.WorkflowsConfig(
    worker=workflows.WorkerConfig(
        deployment_name=app_config.deployment_name,
        server_url=app_config.mistral_server_url,
    )
)

await workflows.run_worker([WeatherWorkflow], config=config)

Process limitations

Within one process:

  • The same workflow type and task queue must use the same configuration.
  • The same workflow type may use a different configuration on another task queue, but its name, sandboxing, and versioning settings must stay the same.
  • A workflow type name is reserved for the lifetime of the process. Do not reuse it for another workflow implementation.

License

Apache License 2.0 - see LICENSE for details.

Metadata

Release files for mistralai-workflows 4.0.0a2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mistralai-workflows 4.0.0a2
File Size Uploaded Provenance Actions
mistralai_workflows-4.0.0a2.tar.gz 642.5 kB With provenance Details for mistralai_workflows-4.0.0a2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for mistralai-workflows 4.0.0a2
File Interpreter ABI Platform Actions
mistralai_workflows-4.0.0a2-py3-none-any.whl Python 3 none any Details for mistralai_workflows-4.0.0a2-py3-none-any.whl

Total release size: 1.1 MB

Release files / mistralai_workflows-4.0.0a2.tar.gz

Download URL mistralai_workflows-4.0.0a2.tar.gz
Size 642.5 kB
Tags Source
SHA-256 checksum
How to use checksums
53c8abee5a14c2c33e8dbad7277558d485bc2cb75fbb756854209973ec5165ba
BLAKE2b-256 checksum
How to use checksums
b881cf78fcf650bb45cc9e55d210900ff29cef655963c7059b406f19c35c53be
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.

Transparency log

Release files / mistralai_workflows-4.0.0a2-py3-none-any.whl

Download URL mistralai_workflows-4.0.0a2-py3-none-any.whl
Size 499.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ae6146a61935c9d23126c70253d0a6237ff38eeac16825a2fd2c44294c90a25c
BLAKE2b-256 checksum
How to use checksums
e7c0b6e271da2d2d93d39f8394c2beb950b9528ba8f94045d7d922bfe2ac8905
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.

Transparency log

Security for mistralai-workflows 4.0.0a2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for mistralai_workflows-4.0.0a2.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page