Library › Coding AI › Product managers

Ask an AI builder to fix one bug without a rewrite

  • For Product managers
  • You practice Setting limits and rules
  • Time about 5 minutes

About this exercise

Your AI-built feedback board has one bug, and last time the builder rewrote the whole app. Write a follow-up prompt as exactly 4 numbered lines labeled Bug, Where, Change only, Check. Name the component, say what must not change, and give one check you can click. No code blocks, under 110 words.

Common mistakes when you ask AI for this

  • A vague fix request. 'Fix the voting bug' lets the builder rewrite whatever it wants. Try: Add: "Bug: double-click adds 2 votes. Where: VoteButton.tsx."
  • No fence around the change. Builders 'improve' nearby code, styles and features. Try: Add: "Change only VoteButton.tsx. Don't touch other files, colors or sorting."
  • Bundling other fixes. The AI adds search and dark mode fixes 'while it's there'. Try: Add: "Fix only this bug. Leave search and dark mode alone."
  • No way to verify. The AI ends the prompt without a test you can run. Try: Add: "Check: double-click the upvote; count goes up by 1."
  • A long explanation. The AI writes headings and code snippets of a possible fix. Try: Say: "Exactly 4 numbered lines, no code blocks."

What a strong prompt includes

  • Names the file
  • Fences the change
  • Gives a check
  • Uses the line labels
  • Caps the length

Practice this now ↑

Related exercises