Prompt Diff
Highlight differences between two prompt versions to iterate faster.
Done calculating? Check these tools
ChatGPT
ChatGPT is an advanced AI chatbot developed by OpenAI, capable of understanding…
Claude
Claude is Anthropic's AI assistant focused on being helpful, harmless, and…
Notion AI
Notion AI brings artificial intelligence to your workspace, helping with…
Related categories
About Prompt Diff
Paste two prompt versions side by side and get a line-by-line diff with inline highlights: red removals, green additions, blue modifications — Chinese marked per character, English per word. Line stats (unchanged / added / removed / modified) and an LCS similarity come along, clearly labelled as textual overlap rather than semantic similarity. The diff is our hand-rolled longest-common-subsequence implementation — zero third-party dependencies, running entirely in your browser.
FAQ
- Why diff prompts instead of just reading version history?
- Version history tells you WHICH version; a diff tells you exactly WHICH WORDS changed. Prompt engineering traps hide in small edits: swapping "concise" for "detailed", dropping a constraint line, changing the output format — each can swing model behaviour while being nearly invisible in two long texts. Locate every change with a diff first, then validate output shifts one by one; that's the standard iteration loop.
- What does "similarity 85%" mean? Is higher better?
- It's purely the longest-common-subsequence ratio: 100% identical, 0% disjoint, and anything between measures textual overlap. It says nothing about meaning — a full paraphrase keeps the sense while scoring maybe 50%. So no, higher is not "better": the goal of editing a prompt is editing it RIGHT, not editing it little. Use the number as a rough sense of change magnitude, read alongside the line diff.
- Why not use an off-the-shelf diff library?
- We avoid dependencies when we can (project discipline): the LCS core is ~60 lines and we tailor it for Chinese — no word boundaries, so inline highlights run per character for CJK and per word for Latin, while stock libraries default English-first. A hand-rolled pass also keeps the accounting (what counts as a modification vs a delete+add) fully transparent and testable. The trade-off: LCS is O(n·m), so don't diff entire books.