Dataset Quality Audit Before Analysis or ML
Find what's wrong with a dataset before you analyze or train on it: ranked issues with counts, causes, and exact fixes.
Before & after
Same prompt, same agent — the only difference is the skill.
Auditing data quality before training is a smart move. Here's what to check: - **Completeness** — how many missing values, and in which columns - **Consistency** — conflicting or contradictory values - **Accuracy** — values that are wrong or out of expected ranges - **Validity** — values that don't match the expected format or type - **Duplicates** — repeated records that could skew training - **Outliers** — extreme values that may be errors or genuine edge cases I'd start by profiling the dataset — get distributions, null counts, and unique value counts per column. Then investigate anything that looks off. Can you share the dataset or describe its structure?
DATA QUALITY AUDIT — profile first, judge second. Numbers below are the
shape of a real audit; run against your file for actuals.
COMPLETENESS
column null % verdict
email 0.2% fine
signup_date 0% fine
last_purchase 34% ⚠ — is null "never purchased" or missing data?
This distinction changes your model. Confirm
before imputing.
region 11% investigate — clustered in one signup source?
CONSISTENCY
• 47 rows: last_purchase BEFORE signup_date. Impossible. Data error,
not an outlier — exclude or fix, don't feature-engineer around it.
• account_status has "active", "Active", "ACTIVE" — 3 spellings, one
state. Silent cardinality inflation; models will treat them as
distinct.
VALIDITY
• 12 emails don't parse. • 3 signup_dates in the future.
OUTLIERS — and the trap here
lifetime_value has 8 values above $2M against a $340 median. Before
you clip them: are they real whales or a currency/units bug? An
outlier that's a data error and an outlier that's your best customer
look identical in a boxplot. Check the source, don't just winsorize.
DISTRIBUTION RISK FOR TRAINING
region is 78% one value. A model trained on this won't generalize
off that region — that's a sampling problem no cleaning fixes, and
it's the finding most likely to bite you post-deployment.
REMEDIATION PLAN, ORDERED
1. Exclude the 47 impossible-date rows (errors, non-negotiable)
2. Normalize account_status casing
3. Decide last_purchase null semantics WITH a domain owner — don't
impute blind
4. Verify the 8 LTV outliers at source before any clipping
5. Flag the region skew to whoever owns the model's scope
Point me at the file and I'll run the real profile.About this skill
Your dashboard total is off by 8%, your churn model scores 0.97 AUC, and nobody trusts the numbers. The cause is usually a duplicated join, a column that is half cents and half dollars, or a field that only gets filled in after the outcome happens. A basic null count will not show any of these. This skill audits the data the way a senior data engineer would and returns a ranked list of what will actually change your answer.
What it does
- Tests the grain first: what one row should represent, whether the key is really unique, and whether a join fanned out your rows
- Finds disguised nulls ("N/A", -1, 0, 1900-01-01, blank strings) that make a null-rate check look fine
- Checks why values are missing (by source, time, and segment) before anyone imputes a mean
- Catches coercion damage: lost leading zeros, IDs mangled into scientific notation, swapped day and month, epoch seconds vs milliseconds, mixed units
- Separates real errors from legitimate extremes using robust outlier methods plus domain bounds
- For ML data: flags target leakage, entities split across train and test, and label definition drift
What you get
A severity-ranked findings table (Blocking / Fix before use / Monitor / Accept) where every row has evidence counts, a likely cause, a fix, and a check to stop it recurring. You also get paste-ready pandas or SQL to produce the evidence when you have not shared the data yet.
Best for
Analysts, data scientists, and analytics engineers who are about to report on or train on a CSV, warehouse table, or export they did not build themselves.
SKILL.md preview
---
name: dataset-quality-audit
description: Audits a dataset for fitness for a specific use (analysis, reporting, or model training). It checks grain and keys first, then disguised nulls, missingness mechanisms, type coercion damage, units, timestamps, cross-field rules, outliers, and ML leakage, and returns severity-ranked findings with counts, causes, and fixes. Use when the user says "is this data ready to train on", "profile this dataset", "check this CSV for problems", "my totals don't match finance", "my model accuracy is suspiciously high", "why are there so many duplicates after my join", "find outliers and missing values", or "can I trust this table".
---
… (sign up to view the full skill)Featured in
More development skills
View all Development skills →Pandas Data Wrangling Without Silent Errors
Correct, fast pandas code for merging, cleaning, groupby, reshaping, and time series, with checks that catch silent row loss.
Apache Spark Job Tuning and Debugging
Finds why a Spark job is slow or failing from the plan and UI metrics, then gives the code and config fix plus how to verify it.
Reliable Data Pipelines and Analytics Models
Build and repair ETL/ELT pipelines with replay-safe writes, explicit data contracts, and actionable quality checks.
Statistical Tests, Power & A/B Readouts
Get hypothesis tests, effect sizes, confidence intervals, and sample-size calculations with experiment validity checks.