BitSize Python · Data & MLOps
Build pipelines. Ship models. Keep them working.
Everything around the model, on one map of the whole system.
The big picture
What a data/ML system is, batch vs streaming, ETL vs ELT, who does what, the app database vs the analytics store, and why every pipeline should behave like a function.
- 01 The map: from a click to a predictionthe System Map Up next
- 02 Batch or streaming: how fresh must it be?cron · micro-batch · Kafka Free account
- 03 ETL vs ELT: transform before or after loadingPython ETL · loaders + SQL (ELT) Free account
- 04 Who does what: the four rolesCODEOWNERS 🔒 Subscribe
- 05 OLTP vs OLAP: the app’s database is not for analyticsPostgres · read replica · warehouse · DuckDB 🔒 Subscribe
- 06 A pipeline is a function: run it twice, get the same answerappend · delete-and-insert · upsert 🔒 Subscribe
Storing data
Rows vs columns, CSV and JSON, Parquet, Arrow, partitions, warehouses, lakes and lakehouses, and schemas that change.
- 07 Rows vs columns: why analytics stores data sidewaysrow stores · column stores 🔒 Subscribe
- 08 CSV and JSON: good for exchange, bad for analyticsCSV · JSON · JSON Lines 🔒 Subscribe
- 09 Parquet: columns, compression and skippingParquet · PyArrow 🔒 Subscribe
- 10 Arrow: one table format in memoryApache Arrow · PyArrow · Polars · DuckDB 🔒 Subscribe
- 11 Partitioning: folders that let queries skip workHive-style partitions · PyArrow datasets · DuckDB 🔒 Subscribe
- 12 Warehouse, lake, lakehouseBigQuery · Snowflake · S3 · Delta Lake · Iceberg 🔒 Subscribe
- 13 Schemas and schema evolutionschemas · union by name · table formats · schema registries 🔒 Subscribe
Processing
When pandas is enough, lazy query plans, Polars, DuckDB, SQL transformations with dbt, going distributed, Spark, and choosing an engine.
- 14 When pandas is enoughpandas · dtypes · chunks 🔒 Subscribe
- 15 Eager vs lazy: query planslazy frames · EXPLAIN · predicate and projection pushdown 🔒 Subscribe
- 16 Polars: expressions and lazy framesPolars · expressions · LazyFrame · streaming 🔒 Subscribe
- 17 DuckDB: SQL straight on filesDuckDB · read_parquet · read_csv 🔒 Subscribe
- 18 SQL transformations with dbtdbt · models · ref · tests 🔒 Subscribe
- 19 When one machine isn’t enoughpartitions · shuffle · skew · salting 🔒 Subscribe
- 20 Spark in one lessonApache Spark · PySpark · Databricks · EMR · Dataproc 🔒 Subscribe
- 21 Choosing an enginepandas · Polars · DuckDB · dbt · Spark 🔒 Subscribe
Ingestion & APIs
Pulling from APIs, incremental loads, building and validating an API with FastAPI and Pydantic, webhooks and queues, Kafka, delivery guarantees.
- 22 Pulling from REST APIshttpx · requests · pagination · Retry-After 🔒 Subscribe
- 23 Incremental loads: watermarks and CDCwatermarks · upserts · CDC (Debezium) 🔒 Subscribe
- 24 Building an API with FastAPIFastAPI · uvicorn · OpenAPI 🔒 Subscribe
- 25 Validating input with PydanticPydantic · Field constraints · validators · strict mode 🔒 Subscribe
- 26 Push vs pull: webhooks and queuespolling · webhooks · HMAC signatures · queues (SQS, Pub/Sub, RabbitMQ) 🔒 Subscribe
- 27 Streaming with KafkaApache Kafka · Redpanda · confluent-kafka · consumer groups 🔒 Subscribe
- 28 Delivery guarantees: at least once, then idempotentat-least-once · offsets · idempotency keys 🔒 Subscribe
Orchestration
Why cron isn’t enough, DAGs, Airflow, retries and alerts, backfills, idempotent tasks, and Airflow vs Prefect vs Dagster.
- 29 Why cron isn’t enoughcron · crontab · systemd timers 🔒 Subscribe
- 30 DAGs: tasks and dependenciesDAGs · topological order · graphlib 🔒 Subscribe
- 31 Airflow: DAG files, operators, the schedulerApache Airflow · TaskFlow API · operators · scheduler 🔒 Subscribe
- 32 Retries, timeouts and alertsretries · exponential backoff · timeouts · alerts 🔒 Subscribe
- 33 Backfills and the logical datelogical date · data interval · catchup · airflow dags backfill 🔒 Subscribe
- 34 Idempotent taskspartition overwrite · MERGE · atomic swaps 🔒 Subscribe
- 35 Airflow vs Prefect vs DagsterAirflow · Prefect · Dagster · assets 🔒 Subscribe
Data quality
What goes wrong with data, validation checks, data contracts, testing pipeline code, logging, freshness and lineage.
- 36 What goes wrong with datacompleteness · validity · uniqueness · consistency · timeliness · accuracy 🔒 Subscribe
- 37 Validation checkspandera · Great Expectations · dbt tests · Soda 🔒 Subscribe
- 38 Data contracts between teamsdata contracts · schema checks in CI · ownership 🔒 Subscribe
- 39 Testing pipeline code with pytestpytest · fixtures · parametrize · CI 🔒 Subscribe
- 40 Logging pipelines for 2 a.m.logging · JSON logs · run ids · log search 🔒 Subscribe
- 41 Freshness, lineage and observabilityfreshness SLAs · lineage graphs · data observability 🔒 Subscribe
Reproducibility & containers
Pinned environments, configuration and secrets, Docker images, Dockerfiles and the build cache, smaller images, Compose, versioning data and models.
- 42 Works on my machine: pinned environmentspyproject.toml · uv · pip-tools · lock files · conda 🔒 Subscribe
- 43 Configuration and secretsenvironment variables · pydantic-settings · secret managers 🔒 Subscribe
- 44 Docker: images and containersDocker · images · containers · registries 🔒 Subscribe
- 45 Writing a Dockerfile: layers and the cacheDockerfile · layers · build cache · .dockerignore 🔒 Subscribe
- 46 Smaller, safer imagesslim bases · multi-stage builds · non-root users · image scanning 🔒 Subscribe
- 47 Docker Compose: an app and its databaseDocker Compose · services · volumes · health checks 🔒 Subscribe
- 48 Versioning data and modelscontent hashes · DVC · object storage · lakehouse time travel 🔒 Subscribe
Experiment tracking & models
Why track experiments, MLflow runs, comparing runs honestly, packaging a model, the model registry, features and training/serving skew.
- 49 Why track experimentsrun logs · MLflow · hosted trackers 🔒 Subscribe
- 50 MLflow tracking: params, metrics, artifactsMLflow · experiments · runs · artifacts · autolog 🔒 Subscribe
- 51 Comparing runs honestlycross-validation · seeds · held-out test sets · MLflow compare 🔒 Subscribe
- 52 Packaging a modelpickle · joblib · MLflow models · ONNX · skops 🔒 Subscribe
- 53 The model registryMLflow Model Registry · versions · aliases · cloud registries 🔒 Subscribe
- 54 Features and training/serving skewshared feature code · feature stores · point-in-time joins 🔒 Subscribe
Shipping
Serving patterns, a model behind FastAPI, batch scoring, Git for ML code, CI with GitHub Actions, CD, safe rollouts, and where it runs.
- 55 Serving patterns: batch, online, streamingbatch scoring · model APIs · stream processors · on-device models 🔒 Subscribe
- 56 Serving a model with FastAPIFastAPI · Pydantic · uvicorn · BentoML · managed endpoints 🔒 Subscribe
- 57 A batch scoring joborchestrated jobs · Parquet partitions · DuckDB · Spark for big batches 🔒 Subscribe
- 58 Git for ML codegit · branches · pull requests · code review · .gitignore 🔒 Subscribe
- 59 CI with GitHub ActionsGitHub Actions · GitLab CI · ruff · pytest · branch protection 🔒 Subscribe
- 60 CD: build, push, deployGitHub Actions · container registries · environments · deploy scripts 🔒 Subscribe
- 61 Safe rollouts: shadow, canary, blue-greenshadow deployments · canary releases · blue-green · A/B tests · Argo Rollouts 🔒 Subscribe
- 62 Where it runs: VM, serverless, KubernetesVMs · serverless containers · managed container services · Kubernetes 🔒 Subscribe
Production
What to monitor, logs, metrics and traces, data drift, concept drift, alerts people trust, retraining, incidents and cost.
- 63 What to monitorsystem metrics · input checks · prediction monitoring · dashboards 🔒 Subscribe
- 64 Logs, metrics and tracesPrometheus · Grafana · OpenTelemetry · log platforms 🔒 Subscribe
- 65 Data driftPSI · Kolmogorov–Smirnov (ks_2samp) · drift reports 🔒 Subscribe
- 66 Concept drift and delayed labelslabel joins · performance by cohort · proxy metrics · backtesting 🔒 Subscribe
- 67 Alerts people trustSLOs · error budgets · burn-rate alerts · on-call 🔒 Subscribe
- 68 Retraining: schedule or triggerscheduled retraining · drift and performance triggers · champion/challenger 🔒 Subscribe
- 69 Incidents, rollbacks and postmortemsrollbacks · incident roles · blameless postmortems · action items 🔒 Subscribe
- 70 What it costsbilling exports · cost per unit · spot instances · lifecycle rules · autoscaling 🔒 Subscribe
Case files
Whole systems end to end, traced across the map: a daily pipeline, a model that ships, a broken Monday, and a stack for three companies.
- 71 Case file: the daily sales pipelineAPI pull · validation · Parquet partitions · DuckDB / dbt · orchestration · freshness 🔒 Subscribe
- 72 Case file: the churn model shipsMLflow · registry · FastAPI · Docker · CI/CD · canary · monitoring 🔒 Subscribe
- 73 Case file: the broken Mondaylineage · structured run logs · volume checks · backfills · postmortems 🔒 Subscribe
- 74 Case file: a stack for three companiesevery chip on the map · the deciding questions · “upgrade when…” 🔒 Subscribe