Prefect Workflows
Build Python-native data workflows with Prefect 3. Generates flows, tasks, deployments, work pools, automations, and event-driven triggers — with retries, caching, and observability baked in.
Prefect 3 is a modern alternative to Airflow with first-class Python ergonomics. This skill scaffolds @flow and @task decorators, configures work pools and workers (process, Docker, Kubernetes), sets up deployments via prefect.yaml, builds event-driven automations, and migrates Prefect 2 code to 3.x. Covers Prefect Cloud and self-hosted setups.
When to use
Use when building Python-first data pipelines, replacing cron jobs with observable workflows, setting up event-driven data flows, or migrating from Airflow to a lighter framework.
Examples
ELT flow with retries
Extract, load, transform with caching
Write a Prefect 3 flow that pulls from a REST API, caches successful pulls for 1 hour, loads raw JSON to S3, then triggers a dbt run — with exponential retry backoff and Slack alerts on failure
Event-driven automation
Trigger a flow when an upstream flow completes
Set up a Prefect automation that runs my reporting flow whenever the upstream ingest flow finishes successfully, and pages me if it fails twice in a row