CourseAI Engineering: The Complete Course · Module 2: Data Handling · part 19 of 105
Part 19 · Module 2: Data Handling

Lab: Clean, validate and version the help centre

19 min read·13 Oct 2026
Module 2 · Lab · About 45 minutes · Needs: lessons 1 and 2 (pandas, explicit dtypes, the four gates: validate, dedupe, redact, version)

What you are building

THREE EXPORTS, FOUR GATES, ONE VERSIONED FOLDER articles 16 records orders.csv 5 rows tickets.csv 42 rows read validate dedupe redact version brightcart_data/a6249428 12 articles, 5 orders 40 tickets, manifest.json one-page data report
Three messy exports pass through the read step and the four gates into one folder named by its version, with a data report printed from the same counts. Blue is the pipeline, green is what comes out.

Priya has sent the help-centre export, Dev has sent the orders table as a CSV, and the forty labelled tickets arrive as a second CSV. All three are messy in the ways the two lessons showed: an article with no category, an id turned into a number, two copies of old articles, a pasted email and phone number, a blank ticket, a resent ticket, and order numbers that a CSV reader will guess are integers. By the end of this lab the three tables have passed through the four gates and the pandas steps, and sit in one folder named by a version id: articles.parquet, orders.parquet, tickets.parquet and a manifest.json that records the row count and content hash of each. A one-page data report, printed from code, says what went in, what was held back and why. This is the clean, versioned dataset a production pipeline would hand to Modules 3, 5 and 8 (the lessons paste the same shared data so each runs alone). No model is called, so no key is needed.

The rest of this course is yours to keep

This course is bought on its own, once, and stays readable afterwards, including the parts added to it later.