跳到主要内容
知仓学习社ZHICANG

prompt-debugging

Figure out why a prompt isn't working and fix it — diagnose the actual failure (ambiguity, missing context, wrong format, conflicting instructions) …

不碰外部(只输出文字)无严重或高危命中mohitagw15856/pm-claude-skills

它会碰到什么

扫了多少1 个文本文件,4 KB
它会碰到什么不碰外部(只输出文字)
命中总数0 处
命中统计严重 0 · 高 0 · 中 0 · 低 0

这一栏是扫描器报的事实,不是结论。命中多不等于有毒(安全工具、规则库、示例脚本本来就会包含危险写法),命中少也不等于干净。它和你手上的凭据、文件、网络有什么关系,需要你自己看。

技能内容

Prompt Debugging

When a prompt misbehaves, most people randomly reword it until something sticks — slow, and it doesn't teach you anything. Prompts fail in diagnosable ways: ambiguity, missing context, a format the model can't follow, or instructions that contradict each other. This finds the actual failure, applies the targeted fix, and names the principle — so you fix it once and stop hitting the same wall.

What This Skill Produces

  • A diagnosis — the specific failure mode: ambiguous ask, missing context, unspecified output format, conflicting instructions, buried key instruction, or too much at once
  • The targeted fix — the change that addresses that failure, not a superstitious reword
  • A corrected prompt — rewritten to fix the diagnosed problem, with the change explained
  • A generalization check — testing that the fix works across cases, not just the one example (the trap of overfitting to a single output)
  • The principle — the underlying rule (be specific, show the format, resolve conflicts, front-load the key instruction) so you recognize it next time
  • When it's the model, not the prompt — the honest call when the task is beyond what prompting fixes

Required Inputs

Ask for these if not provided:

  • The prompt — the actual text that's misbehaving
  • What it's doing wrong — ignoring an instruction, wrong format, inconsistent, off-topic
  • What you want — the correct output, ideally with an example
  • The pattern — does it fail always or sometimes (points at ambiguity vs. a hard miss)

Framework: Diagnose Before You Reword

  1. Name the failure mode. Match the symptom to a cause — ignored instructions often mean it's buried or conflicting; inconsistent output usually means ambiguity; wrong shape means the format wasn't specified.
  2. Fix that cause specifically. Ambiguous → add specificity; missing context → add it; no format → show the exact format; conflict → resolve it; buried → move the key instruction up front.
  3. Show, don't just tell. For format and quality problems, an example of the desired output fixes more than paragraphs of description.
  4. Check it generalizes. Re-test on several cases — a fix that only works on your one example is overfitting, not a fix.
  5. Extract the principle. Name the rule behind the fix so the next prompt starts right.
  6. Know when to stop. If the task genuinely exceeds the model or needs tools/context it can't have, say so instead of endless rewording.

Output Format

Prompt debug: [what's failing]

Diagnosis: [the specific failure mode — ambiguity / missing context / no format / conflict / buried / overloaded].

The fix: [the targeted change for that cause].

Corrected prompt:

> [rewritten prompt].

Generalization check: [test across cases, not just the one example].

Principle: [the rule — so you avoid it next time].

If it's not the prompt: [when the task exceeds prompting → what's actually needed].

Quality Checks

  • [ ] Diagnoses a specific failure mode before rewriting
  • [ ] Applies the fix that matches the cause
  • [ ] Uses an example where the problem is format/quality
  • [ ] Checks the fix generalizes beyond one case
  • [ ] Names the principle; flags when it's a model limit, not a prompt one

Anti-Patterns

  • Randomly rewording until something works, learning nothing.
  • Fixing to one example and overfitting.
  • Adding more words when the issue is a conflict or buried instruction.
  • Describing the format instead of showing it.
  • Blaming the model when the prompt is fixable — or the reverse.

Example Trigger Phrases

  • "Why isn't my prompt working?"
  • "The AI keeps ignoring one of my instructions — why?"
  • "My prompt gives me different results every time."
  • "Help me fix this prompt, it's not doing what I want."
  • "How do I get consistent output from this prompt?"

想直接用这个技能?

本站把开放许可(MIT / Apache 等)的技能按仓库打包整理到网盘,点一下转存到你自己的网盘,不用一个个从 GitHub 拉。许可未声明的技能只给原始仓库链接,不打包。

同名技能的其他版本

有 3 个不同仓库或目录里都有叫 prompt-debugging 的技能。它们内容并不相同,别混用: