Topic 4 of 5 · 5 min read
Undo, checkpoints and reversible AI changes
Goal: Audit an AI bulk-edit feature for actions with no undo path and specify a checkpoint, delay or confirmation for each.
Every AI change should be reversible in one step, and any change that cannot be reversed should say so before it happens.
Check yourself · 1 of 3
An AI tool is about to change 300 spreadsheet cells. What should happen first?
Why it matters
An AI feature is fast, and speed multiplies mistakes. One request can rename 200 files, rewrite every row in a spreadsheet column or reformat a whole codebase. If the result is wrong, the user needs to get back to where they started without detective work. The usability heuristic of user control and freedom says people need a clearly marked emergency exit. Apple's guidance for machine-learning features says the same: let people reverse an action.
How to do it
- Take a checkpoint before a bulk change. Save the state before the AI touches many items: a snapshot, a version, a git commit, a copy of the old values.
- Offer one-step undo for the whole batch. After a bulk edit, show "Updated 214 rows. Undo" for long enough to be found. Undo restores the whole batch, not row by row.
- Keep version history. For documents and settings, store versions the user can browse and restore. Label them by what happened ("AI rewrote section 2"), not by time alone.
- Add a delay for sends. For email and messages, hold the item for a short window, so a "Sending in 10 seconds. Undo" bar can stop it. This turns an irreversible action into a reversible one for a moment.
- Name what cannot be undone. Some actions have no way back: a payment sent, a message delivered, a record deleted without backup. Mark these before the action, use a gate, and avoid hiding them among reversible ones.
- Test the undo. Undo that fails halfway is worse than none. Check that restore brings back data and side effects such as notifications and counts.
Before and after
Before: An "AI clean-up" button rewrites 214 product titles in a catalogue. Old titles are overwritten. Titles that were right are changed too. The team restores from last night's backup and loses a day of edits.
After: Before the run, the tool saves the old titles under checkpoint "pre-AI-cleanup". After it, a bar says "214 titles changed. Undo all." History lists the checkpoint. Titles can also be reverted one at a time.
What goes wrong
- Undo that covers only the last row, while the AI changed hundreds.
- Checkpoints stored only in memory, lost on refresh.
- Hidden irreversible steps, such as the tool also emailing customers about the title change.
- Undo window too short for the user to notice the problem.
For engineers, a bulk edit can be a transaction: write old values to an audit table, apply, return a batch id, and make undo a single call that restores by batch id.
Examples
Reading a bulk-edit spec for gaps
async function aiCleanupTitles(products: Product[]) {
for (const p of products) {
p.title = await rewriteTitle(p.title);
await db.save(p);
}
await notifySubscribers("Catalogue updated");
}
Gaps: old titles are overwritten with no checkpoint, there is no batch id for undo, and notifySubscribers cannot be recalled. Fix: save a snapshot first, return a batch id, make undo restore it, and either delay or gate the notification.
A send delay
A mail assistant queues each AI-drafted message for 10 seconds. A bar shows "Sending to Ana Ruiz in 10s. Undo". The user sees the wrong attachment name and clicks Undo in time. After the delay the message is delivered and no longer recallable, and the interface should say so.
Key points
- Take a checkpoint before any AI change that touches many items, so the whole batch can be restored.
- One-step undo should reverse an entire bulk edit, not only the last item.
- Send delays turn an irreversible send into a short reversible window.
- Tell the user before an action that cannot be undone, and gate it.
- Test undo as carefully as the feature itself, including side effects.
Common mistakes
- Overwriting old values in a bulk edit with no snapshot.
- Giving undo for single items but not for the batch.
- Letting an AI action trigger emails or payments as a hidden side effect.
- Keeping the undo window so short that users miss it.
Check yourself · 2 of 3
Why do many mail apps hold a sent message for a few seconds with an Undo bar?
Check yourself · 3 of 3
After an AI bulk edit, which undo design is best?
Practice items, not counted towards your mastery.
Start here
- People + AI Guidebook: Feedback and control (opens in a new tab)DocsFree
Google PAIR chapter on letting users give feedback and keep control of AI behaviour.
- User Control and Freedom (NN/g) (opens in a new tab)ArticleFree
The usability heuristic behind undo, cancel and clearly marked exits.
- Accordion Editing and Apple Picking (NN/g) (opens in a new tab)ArticleFree
Research on how people really edit generated text: expand, shorten and cherry-pick.