Data & BI

Verified against ChatGPT · 2026-08-08

Turn a messy spreadsheet column into a defensible cleaning plan you can hand to someone else

Produces a step-by-step data cleaning plan for a specific messy column — with the exact transformation rule for each pattern of mess and a log of what changed, so the cleaning is reproducible instead of a one-off manual fix.

ChatGPT (GPT-5.1)4 fillable variables

The prompt

Ready to copy — highlighted parts are example details you can swap.

Act as a senior data analyst writing a cleaning plan for one messy column in a dataset — not performing the cleaning silently, but producing a plan specific enough that someone else (or a future me) could apply it consistently and audit what changed.

COLUMN NAME AND PURPOSE
region — should be the sales region an order shipped to, used to roll up revenue by territory.

MESS PATTERNS OBSERVED
APAC, Apac, Asia Pacific, EMEA, emea, N/A, (blank), West-Coast, west coast

DOWNSTREAM USE
A pivot table grouping revenue by region currently shows 9 groups for what should be 4 real regions.

VALUES THAT SHOULD NOT BE TOUCHED
"N/A" specifically means the order had no assigned region yet and should stay separate from real regions, not get merged into one.

Steps:

1. Group the mess patterns you were given into distinct categories (e.g. casing inconsistency, whitespace, near-duplicate free-text entries meaning the same thing, out-of-range values, placeholder values disguised as real data). For each category, write the exact transformation rule in plain language, precise enough to implement in a formula, script, or find-and-replace.
2. For any near-duplicate free-text values (misspellings, abbreviations, different formats of the same entity), propose a canonical value and list which observed variants should map to it — flag any case where you're genuinely unsure two variants mean the same thing rather than guessing.
3. Identify which rows should be excluded or flagged rather than cleaned — a value that isn't messy, it's actually invalid or contradicts the do-not-touch list.
4. Write the cleaning as an ordered sequence (order matters when one rule could interact with another — e.g. trimming whitespace before checking for exact duplicates).

WHAT NOT TO DO
Do not silently fix everything into one lump "data was cleaned" statement — every rule must be traceable to a specific observed pattern. Do not invent a canonical mapping for a value you were not given evidence for; say it needs a human decision instead of guessing.

OUTPUT FORMAT
1. Ordered cleaning steps (numbered, each with: pattern -> rule -> example before/after)
2. Canonical value mapping table for free-text entries, with an "uncertain" flag column
3. Rows to exclude or flag, with reason
4. A one-paragraph audit note summarizing what changed and what still needs a human decision

Customize

Optional — swap in your own details for the highlighted parts above.

Why this works

Asking for a cleaning plan rather than cleaned output matters because GPT-5.1 cannot see your actual full dataset — if you ask it to just clean the column, it will either fabricate cleaned rows that look plausible but aren't real, or hedge everything into vagueness; asking for an explicit, ordered rule set instead produces something you can mechanically apply to the real data yourself, in a spreadsheet formula, a script, or a find-and-replace pass, and something a colleague can audit later without re-deriving the logic. The ordering requirement (trim whitespace before checking duplicates) exists because cleaning rules genuinely do interact, and a model asked for an unordered list of fixes will frequently produce a set that's individually correct but wrong in combination when applied in the wrong sequence, e.g. checking for exact duplicates before normalizing case, which would miss matches. Requiring an "uncertain" flag on the canonical mapping table specifically counters a known model tendency to complete pattern-matching tasks with unwarranted confidence — without being told explicitly that guessing is worse than flagging uncertainty, the model will resolve every ambiguous abbreviation into a guessed canonical form rather than admitting two variants might refer to different real-world things. The do-not-touch input is the safeguard against the most damaging cleaning failure mode: a model, seeing an odd-looking value like "N/A," will often want to normalize it away entirely, silently destroying a meaningful distinction (missing vs. assigned) that the person building the dashboard actually needs preserved.

What you get back

Step 1 — Casing/whitespace: rule = trim leading/trailing whitespace, then title-case all region values. Example: 'west coast' -> 'West Coast'. Step 2 — Canonical mapping: APAC/Apac/Asia Pacific -> 'APAC' (confident); EMEA/emea -> 'EMEA' (confident); West-Coast/west coast -> 'West Coast' (confident). Rows to flag: blank and 'N/A' values should NOT be merged into any region per your do-not-touch instruction — flag as 'Unassigned' distinct from the four real regions. Audit note: 4 canonical regions established from 9 observed variants; blanks and N/A preserved as a separate Unassigned bucket per instruction; no uncertain mappings required a human decision in this pass.

Verified against

ChatGPT GPT-5.1 · 2026-08-08

Changelog

  • 2026-08-08 Initial publish, verified against ChatGPT GPT-5.1.

Need this built into your business?

If a prompt isn't enough — what Scult builds, built and maintained for you — that's Scult's day job.

EXPLORE WHAT SCULT BUILDS
All Data & BI prompts

Check your AI visibility

One URL in, a 0–100 score and the exact fixes out.

RUN THE CHECK

Browse all the tools

15 tools across six categories
13 of them never send your data anywhere

Free · No signup · No trial clock

SEE THE DIRECTORY