A prompt that gets Claude to only edit the passages you named
Every prompt you've tried has the same shape. Some variant of "Only edit the bit about X, leave the rest alone, don't rewrite everything." It works maybe 40% of the time. On the sixty you get a different document back, sigh audibly, and try a sharper variant. Which also works maybe 40% of the time. Brace yourself: there is no magic phrase.
The thing that works is not a better prompt. It is a format. (And no, it's not a magic phrase.)
Prose instructions like "only edit X" are weak signals on long documents. The reliable recipe pairs a short instruction with verbatim quoted passages: "Apply these edits. Leave everything else unchanged." Then each block is a quote of the exact passage, followed by your note, separated by ---. Copy-pasteable templates below for Claude, ChatGPT, Cursor, and Gemini — the format is identical across all of them. Full explanation in the guide; the browser tool that builds these blocks in one click is OMGfixMD.
The prompts you've already tried, ranked by reliability
On a long document (call it 1,800+ words), here is roughly what each variant gets you. These are the patterns anyone who has tried this fifty times will recognize.
| Prompt attempt | Roughly works… | Why it's weak |
|---|---|---|
| "Only edit X." | 30% | "Only" is a soft word. No positive target. The model decides what counts. |
| "Edit X. Leave everything else unchanged." | 45% | Two constraints; still no coordinate. On a long doc the model regenerates for "consistency." |
| "Do not rewrite any paragraph you are not explicitly editing." | 50% | A negative. Negatives are weaker than positive targets in attention. |
| "Respond with only the edited version of the passage, not the full document." | 70% | Constrains output shape, which helps. Still lets the model choose which passage "the passage" is. |
| "Apply these edits, leave everything else unchanged." + verbatim quote of the passage |
~98% | The quote is the coordinate. Match is by exact-text, not prose interpretation. |
The jump from 70% to 98% is the one that matters. It is not a prompt-wording jump. It is a format jump — the moment you stop describing the passage and start quoting it, the reliability ceiling moves.
If you want the full argument for why this is a format problem and not a prompting problem — including the attention mechanics under the hood — the piece is here. The rest of this playbook is templates you can paste.
The template (one passage, one edit)
Apply this edit to your last answer. Leave everything else unchanged.
"<paste the exact passage, verbatim, including punctuation>"
<your note about what should change>
Three things make this reliable:
- The prefix is short and specific. Not "please carefully consider…" Just what the model should do.
- The quoted passage is verbatim. Typos in the quote are the #1 reason this format fails — the model can't find the match, and silently skips the edit.
- The note is directly under the quote, so attention localizes the instruction to that region.
The template (five passages, one message)
When the list gets long, the same pattern scales — just add a separator between pairs so the model cannot bleed context between them:
Apply these edits to your last answer. Leave everything else unchanged.
---
"The system leverages a cross-functional synergy touchpoint"
[Off tone] Rewrite as "connects to X". Delete the corporate phrasing.
---
"delight velocity"
[Delete] We do not measure this. Remove the phrase entirely.
---
"The FAQ opens with three questions about pricing."
Move this paragraph to the end of the product-overview section.
---
"moreover,"
[Delete] Third "moreover" in this section. Pick one, delete the rest.
---
"Users will onboard via a Slack-first flow"
[Factually wrong] We do not have a Slack integration. Change to "via an email-first onboarding flow."
---
Five passages. One message. One round-trip. No "not that one, the other one" follow-up.
The [Label] in brackets is optional — it is a shorthand the model parses easily (Delete, Off tone, Made it up, Too vague, Too long). You can skip it and just write the note. The quote and the note are the load-bearing parts.
If you have system-prompt control
If you're hitting the model through the API, a custom GPT, a Claude Project's instructions, or a Cursor .cursorrules — you have one extra lever the chat-only user doesn't. A short system-prompt rule lets you skip the per-message "leave everything else unchanged" ritual.
When the user provides feedback as paired blocks of "quoted passage" + note,
separated by ---, treat each block as an atomic edit:
- Locate the quoted passage in the document by exact string match.
- Apply the note's instruction to that passage only.
- Leave every byte outside quoted passages unchanged.
- If a quoted passage cannot be matched verbatim, skip it and report the failure
at the end. Do not approximate.
When the user does not use this format, you may apply edits more liberally
but must summarize what you changed.
This is the kind of rule that lives well in a .cursorrules file at the repo root, in a Claude Project's "instructions" field, or in a custom GPT's system prompt. It generalizes the paired-passage discipline across every conversation, so you stop typing the prefix manually. It's the highest-leverage change in this whole post if you have access to the system layer.
Per-model notes
Claude (Sonnet / Opus)
Handles the format cleanly out of the box. On very long documents (10k+ words in a single turn), append "Return the full edited document after applying all edits." if you want the whole thing back; otherwise Claude sometimes returns just the edited passages, which is often what you actually wanted. Anthropic's own prompt-engineering guide covers the underlying preference for explicit, structured instructions in more depth.
ChatGPT (GPT-4 / GPT-5 class)
Works identically. One quirk: ChatGPT has a slight bias toward "improving" adjacent sentences for flow. The "Leave everything else unchanged" prefix is not optional — drop it and the behavior creeps back in.
Cursor (chat mode)
Works in chat mode. In Composer or Agent mode the model has file-editing tools and will sometimes apply the edit as a diff you have to accept. That is usually what you want. For long markdown files specifically, there is a separate playbook because Cursor's tool-call behavior on prose vs code is worth its own piece.
Gemini (Pro / Ultra)
Works. Gemini occasionally returns the full document with the edits applied even when you didn't ask — this is usually fine, sometimes annoying. Adding "Only show the edited passages in your response" to the prefix gets you the compact form.
What can still go wrong
- Quote mismatch. Your quote has a typo, a smart-quote, or a whitespace difference the original doesn't have. The model silently skips that block. Diff the reply, find the skipped ones, fix the quote, resend the missing blocks specifically.
- Overlapping quotes. Two of your quoted passages overlap — same sentence referenced twice with different notes. The model usually handles this, occasionally gets confused. If you need overlaps, make the notes unambiguous about which aspect of the passage you're editing ("[Tone]" vs "[Fact]").
- Asking for a restructure. If your note is "move this paragraph to a different section," the model has to do more than a local edit. This still works, just less reliably than a phrasing change. For restructures, it is often cleaner to split into two passes: fix the local edits first, then ask for the move.
The cruel twist
Claude, ChatGPT, Cursor, and Gemini will all, almost certainly, ship a native "click here to leave a comment on this passage" surface inside of a year. Probably some of them in the next quarter. The prompt-as-a-format workaround in this post will then look quaint — the way "save as HTML, open in Word, use Track Changes" looks quaint now.
Fine. Until then, the templates above are what work. If you're tired of typing them by hand, OMGfixMD is a browser-only tool that builds the paired-passage block in one click — paste the model's answer, highlight every passage, attach a note per highlight, press ⌘⇧C.
OMG.