Explicit Criteria over Vague Instructions

Core

Design prompts with explicit criteria to improve precision and reduce false positives · Difficulty 2/5

0%
explicit-criteriaprecisionprompt-design

System prompts set Claude's behavior for an entire conversation, but vague instructions produce inconsistent results. Explicit criteria replace ambiguous goals with precise, actionable rules the model can apply deterministically.

The Problem with Vague Instructions

  • "Check that comments are accurate" flags TODOs and descriptive comments (false positives) while missing genuinely outdated comments (false negatives)
  • "Be conservative" and "only report high-confidence findings" sound specific but give the model no concrete decision boundary
  • The Solution: Categorical Criteria

  • "Flag comments only when their claimed behavior contradicts actual code behavior" eliminates false positives on acceptable patterns and catches genuinely misleading comments
  • Define which issues to report (bugs, security) versus skip (minor style, local patterns)
  • Provide concrete code examples for each severity level
  • Why General Instructions Fail

    Instructions like "be conservative" are subjective. The model has no calibrated internal threshold for "conservative." Specific categorical criteria ("flag X, skip Y") give the model a deterministic decision boundary.

    Key Takeaways

    • Replace vague goals with specific, categorical criteria the model can apply deterministically
    • Define what should NOT be flagged, not just what should be flagged
    • General instructions like 'be conservative' fail because the model has no calibrated threshold