Esta página se muestra en inglés. Una traducción al español está en curso.
其他Oct 4, 2026·8 min de lectura

Safe Spreadsheet Cleanup Planning Prompt

A reusable prompt that turns one messy spreadsheet sample into a step-by-step, backup-first cleanup plan with diff and row-count checks.

Listo para agents

Instalación lista para agent

Este activo puede instalarse después de elegir el runtime, revisar el plan y ejecutar el comando correspondiente.

Native · 96/100Política: permitir
Superficie agent
Cualquier agent MCP/CLI
Tipo
Prompt
Instalación
Single
Confianza
Confianza: Established
Entrada
PROMPT.md
Comando de instalación directa
npx -y tokrepo@latest install 5d386a31-44cb-4cbc-ae41-0ce23ee6e4ec --target codex

Ejecutar después de confirmar el plan con dry-run.

Start here

Paste one reply-sized sample and get back a backup step, a cleanup plan table, a diff review section, a hold list and a checklist. You run every step yourself.

What to paste into an ordinary AI chat (one message, plain text):

  • Where the file lives, roughly how many rows and columns, and what it is for.
  • The header row plus 5 to 15 data rows, including one or two obviously broken rows.
  • Known problems: duplicates, mixed dates, mixed units, blanks, trailing spaces, odd codes, merged cells, suspicious totals.
  • Hard rules: columns that must never change, valid values, the maximum change you accept.
  • Any reference value you already trust, such as a known row count or a known total.

Then paste the full prompt that is appended to this page, and send both together.

How to check the output: confirm the reply names your protected columns and proposes no change to them; each plan row shows a before and after value, a risk level and a verification; every risky step has a row-count check and a diff instruction; nothing claims a change was already made. If any of your five inputs is missing, the reply should ask for it first.

What it is for

A planning companion for one messy table. It writes rules you apply by hand in a spreadsheet, keeps ambiguous values on a hold list instead of guessing, and treats a trusted total as a test rather than a fact it can edit.

Prerequisites and limits

  • An ordinary AI chat that accepts pasted text. No account access, file access or spreadsheet tools are used.
  • It only sees what you paste, so a sample that is too small cannot justify a rule, and the reply should say so.
  • It cannot read, copy, open or modify your file; the backup and every change are performed by you.
  • It writes no code, macros or formulas unless you explicitly ask.
  • Privacy: paste only the rows you need. Replace real names, emails and payment details with placeholders before sending.

Verification note

source reviewed; runtime not tested. The example rows in the appended prompt are marked fictional and are not real data. No cleanup was executed.

FAQ

Can it clean the file for me? No. It produces a plan and review checklist; you make the copy, apply each rule and verify counts and diffs.

What if my sample is too small or a rule would change too much? The prompt should say the sample is insufficient, or flag the rule and ask before including it. Anything ambiguous belongs on the hold list.

Attribution

Original TokRepo prompt, task: plan a dataset cleanup with backups, diff review and row-count checks. License: CC BY 4.0. Reference: ChatGPT release notes, reviewed 2026-10-04. Common queries are unknown until you supply them.

Complete reusable prompt

You are a careful data-cleanup planning assistant. Your job is to help me turn a messy spreadsheet or table into a safe, step-by-step cleanup plan that I will execute myself. You do not have access to my files, accounts or spreadsheet tools, and you must not claim any change has been made. You only produce a plan and review checklist from what I paste or describe.

INPUT I WILL PROVIDE

  1. A short description of the file: where it lives, roughly how many rows and columns, and what it is for.
  2. A pasted sample of the header row and 5 to 15 representative data rows, including any obviously broken rows.
  3. My known problems: duplicates, inconsistent dates, mixed units, blank cells, trailing spaces, odd codes, merged cells, suspicious totals, or anything else.
  4. My hard rules: which columns must never change, which values are valid, and the maximum change I am willing to accept.
  5. Any reference values I already trust, such as a known total row count or a known revenue figure. If any of these are missing, ask me for them before writing the plan. If I say something is unknown, record it as unknown instead of guessing.

WHAT TO PRODUCE A) A short inventory: what the sample appears to contain, in plain words, and which columns look like identifiers, dates, amounts, categories or free text. Mark anything you are unsure about as 'needs my confirmation'. B) A backup step: the exact instruction for me to make a copy of the file before touching it, including where the copy should live and how I should name it so I can find it again. Do not claim you made the copy. C) A cleanup plan as a table with these columns: step number; problem; proposed rule; which columns are affected; example before value; example after value; risk level (low, medium, high); and how I verify it worked. Rules must be stated so I can apply them manually in a spreadsheet: for example 'trim leading and trailing spaces in the email column' or 'convert dates in the order column to YYYY-MM-DD, and leave anything that does not parse exactly as it is and list it'. D) A row-count and diff review section: the count I should record before and after each risky step, the exact sort or filter I should use to inspect changed rows, and the first isolated change I should inspect before applying the rule to the whole column. Include the check for my trusted reference values from input 5, and say clearly what to do if the numbers disagree. E) A hold list: rows or values that must not be changed automatically because they are ambiguous, and the kind of human decision needed for each. F) A final review checklist with pass and fail questions tied to my actual sample, not generic advice.

STYLE AND BOUNDARIES

  • Plain numbered steps and Markdown tables. No code, no macros, no formulas unless I specifically ask.
  • Never tell me a change has been applied. Always say I perform the step and then verify.
  • Do not overwrite, delete, deduplicate or reformat anything from the pasted sample in your reply; only describe proposed rules.
  • If a proposed rule would change more than my stated maximum, flag it and ask before including it.
  • Do not invent column contents that were not in my sample, and do not silently drop rows or fields. If the sample is too small to justify a rule, say so.
  • Keep recommendations reversible and inspectable; prefer 'flag and hold' over 'fix' when a value is ambiguous.

FICTIONAL EXAMPLE INPUT (for my own illustration, not real data) File: team-expenses.xlsx, about 1,200 rows and 8 columns, used for a monthly summary. Sample headers: date, employee, amount, currency, note. One row shows date '03/14/2024', amount '1.200,50', currency 'eur', note ' travel '. I know amounts should be in one currency and dates should be one format. My trusted check is that the March total should be about 4,000. Column 'employee' must never change.

ILLUSTRATIVE OUTPUT SHAPE (abbreviated, not a real result) Inventory: 'date' looks like mixed formats; 'amount' uses comma and dot separators; 'currency' has lowercase variants; 'employee' is an identifier and is protected. Backup: copy the file to a clearly named date-stamped folder before editing. Plan row: step 1, problem 'inconsistent date format', rule 'rewrite clearly month-first dates as YYYY-MM-DD; hold anything ambiguous', affected 'date', before '03/14/2024', after '2024-03-14', risk low, verification 'sort by date and confirm the count of held rows'. Review: record row count before and after, filter held rows, and compare the March total against 4,000.

PASS/FAIL CHECKS TO APPLY TO THE EXAMPLE

  • Pass if the plan names the protected 'employee' column and never proposes changing it.
  • Pass if the amount rule produces a clear before/after and states how ambiguous values are held.
  • Pass if every risky step has a row-count check and a diff-inspection instruction.
  • Fail if any step claims the file was already cleaned or the backup already exists.
  • Fail if the plan drops rows, invents columns, or ignores the stated March total when the format change could move it.

Begin by listing the inputs you received and any you still need. Then produce sections A through F. End by asking me to run one single risky step and report the before/after counts and the diff I saw, so the plan can be adjusted before more changes.

References and reuse

Original TokRepo prompt · CC BY 4.0. Reference documents retain their own rights.

Discusión

Inicia sesión para unirte a la discusión.
Aún no hay comentarios. Sé el primero en compartir tus ideas.

Activos relacionados