CloudYetiFREE
God tier prompt #1

This 10-word prompt keeps finding bugs in people's apps

Steve Ruiz posted a one-line prompt on X: find all of the implicit state machines in my app. People who ran it on their own code found real bugs. Here is the prompt, a longer version that gives you a ranked report, and what to do with the results.

Why it matters

A state machine is the states something can be in and the rules for moving between them. A subscription can be trial, active, past due or cancelled.

It is implicit when nobody wrote those rules down, so the state lives in booleans, timestamps and if-checks spread across many files.

That is where bugs like these come from: a cancelled user who still has access, a failed payment that starts a new free trial, a late webhook that moves an account back to an older state, two requests that race and both change the state.

Do this

  1. Open your coding agent (Claude Code, Codex or similar) in your app's folder.
  2. Paste the prompt below. Keep the last line: it tells the agent to report, not to change code.
  3. Read the ranked list. Start with the highest bug risk and check the files and lines it points to.
  4. Fix one state machine at a time: write its states and allowed moves down in one place, then make the code follow that list.

The prompt (with the full-report add-on)

find all of the implicit state machines in my app

For each one: list the states, show the files and lines, find invalid states and race conditions, rank by bug risk. Do not change code.

One thing to keep in mind: The agent can name a state machine that is not really there, or miss one. Treat the report as a list of places to look, and check each file yourself before you change anything.

Prompt by Steve Ruiz on X (Oct 31, 2026; the post showed 1.1M views when I captured it). One reply reported about 70 implicit state machines in one app. More one-sentence prompts: github.com/ravsau/god-tier-prompts. Source: The god tier prompts collection on GitHub.

Free · by emailGet the next AI tip by emailOne short tip like this one when a new one is ready. Free. Unsubscribe any time.

Ask me anything about AI and cloudA paid call on your own setup: your agents, your bill, your plan.Book a call →

All tips in: Prompt lines to copy

More free AI resources

Send me the tips: free →