The Prompt BakeryTemplates and prompts

Fix · Problems with AI tools

The AI rewrote a whole file when I asked for a small edit

What you may see

  • My custom code inside the file is gone

Most likely cause

Some tools produce the whole file again instead of a precise edit, and silently drop parts they did not "see".

Check first (about two minutes)

  1. Compare the file with its saved version: git diff <file>.

The fix prompt

What you type here never leaves your browser. The search runs on this page, and nothing is sent to a server or to an AI.

Kept only in this browser, on this device. Keys and passwords are removed before anything is saved.

Prompt language

Paste it into Claude, ChatGPT, Gemini or Cursor, then follow what it says.

After you tried it, did it work?

Steps

  1. Show git diff for the file and list every removed line group, explaining what each did.
  2. Restore the removed parts into the new version, keeping the requested edit (a small, precise patch).
  3. In the future, I will ask for "a minimal patch, change only these lines".

Do not do this

  • Do not paste a whole file back from the chat over the original without comparing.
  • Do not reformat the whole file.

Related

Try another entry

How can we help?

What do you need?
Your email, so we can reply (optional)Only enter your own email. We reply there.