Optimism needs an evidence boundary
An optimistic interface feels responsive, yet its labels must survive network failure. Users may leave the page after seeing Accepted. Your app needs to explain whether that means a saved local command, an upstream job or a completed result.
What to do next
- 01
Name local and remote states
Use distinct internal states for command saved, dispatching and remote job known. Choose visible wording that matches the evidence you have, and preserve the last confirmed state if the next network hop becomes uncertain.
- 02
Commit local ownership first
If you tell users their action is saved for processing, persist the approved command before returning that message. A transient browser event or uncommitted database row is insufficient evidence for a return-later promise.
- 03
Update with confirmed evidence
When the remote job is known, attach its identity and show accepted or the documented stage. If acceptance remains uncertain, explain the uncertainty and recovery path instead of reverting to a fresh Generate button.
A concrete example
Illustrative example: the browser receives Action saved from your backend before dispatch. The page says Waiting to submit. Only after the dispatcher records the remote job does it say Generation accepted, retaining the same local action throughout.
Before you call it ready
- Visible labels match stored evidence.
- Saved-for-processing survives a reload.
- Uncertainty does not enable an unreviewed new action.
When to stop or choose another method
Stop claiming remote acceptance from an optimistic local update; persist evidence or use a truthful submitting or uncertain state.
