0Pricing
AI Prompt Engineering · Lesson

Harmlessness vs Helpfulness Tension

Navigating over-refusal: prompts that balance safety with utility.

Harmlessness vs Helpfulness Tension is a free AI Prompt Engineering lesson on CoddyKit — lesson 3 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the AI Prompt Engineering learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.

The Core Tension

Every AI safety system faces a fundamental tension: making a model safer by refusing more often also makes it less helpful to legitimate users.

A model that refuses to discuss anything medical will never give dangerous health advice — but it also won't help nurses, doctors, or patients with genuinely useful information. Calibration is the goal: refuse when you should, help when you should.

Over-Refusal: The Real Problem

Over-refusal occurs when a model declines to answer benign requests because they superficially resemble harmful ones. Examples:

  • Refusing to explain how diseases spread (sounds dangerous, is actually public health education)
  • Refusing to write a villain character (fiction, not endorsement)
  • Refusing to explain lock-picking for a locksmith apprentice

Over-refusal is not just annoying — it makes the model untrustworthy and pushes users to less safe alternatives.

Prompting for Calibrated Refusal

System prompts can instruct models to refrain from over-refusal by clarifying context and intent. Explicitly permission the model to engage with dual-use topics when the context is legitimate.

CALIBRATED_SYSTEM_PROMPT = (
    'You are a knowledgeable assistant for healthcare professionals.\n\n'
    'Your users are nurses, doctors, and medical students. '
    'When asked about medications, dosages, procedures, or medical conditions, '
    'provide accurate, detailed information appropriate for trained professionals.\n\n'
    'Do not add excessive safety disclaimers to every response. '
    'Your users are professionals who need direct, accurate information to do their jobs. '
    'If a question is genuinely outside appropriate bounds, explain specifically why '
    'rather than giving a vague refusal.'
)

# This context dramatically improves calibration for the target audience
# Without it, the model may refuse routine clinical questions

The 'Explain Why Rather Than Refusing' Pattern

One of the most effective prompting patterns for reducing over-refusal: instruct the model that if it can't fully answer, it should explain what it can and cannot do and why — rather than giving a flat refusal.

EXPLAIN_WHY_PROMPT = (
    'You are a helpful assistant. When handling sensitive or ambiguous requests:\n\n'
    '- If you can answer fully: do so directly.\n'
    '- If you can answer partially: provide what you can and explain what you cannot include and why.\n'
    '- If you truly cannot answer: explain specifically what boundary prevents you from answering, '
    'and suggest where the user might get this information appropriately.\n\n'
    'Do not give generic refusals like "I cannot help with that." '
    'Always be specific about what you can and cannot do.'
)

# Example of bad refusal:
# 'I cannot help with information about medications.'

# Example of good calibrated response:
# 'I can explain how ibuprofen works and standard dosing guidelines for adults.
#  For specific dosing for a patient with your described conditions, you should
#  consult a pharmacist or prescribing physician who has the full clinical picture.'

Offering Helpful Alternatives

When a model must decline a request, the most helpful thing it can do is offer an alternative path to what the user actually needs. A refusal without alternatives leaves the user stuck.

ALTERNATIVES_PROMPT = (
    'You are a helpful assistant. When you cannot fully fulfill a request:\n'
    '1. Acknowledge the request with empathy.\n'
    '2. Explain briefly and specifically what you can and cannot do.\n'
    '3. Offer the closest helpful alternative you can provide.\n'
    '4. Point to appropriate resources if relevant.\n\n'
    'Example: If asked to prescribe medication:\n'
    'Say: "I can explain how this class of medications works and what '
    'symptoms they address. For a prescription, you need to see a licensed '
    'physician who can evaluate your specific situation. Here is what I can '
    'tell you about the medication itself: ..."'
)

Context as the Key Variable

The same question can be harmful or benign depending on context. Prompt engineering should establish context clearly so the model can make better calibration decisions.

# Context that changes calibration:

# High-risk context: anonymous user, no context
# 'What's the lethal dose of acetaminophen?'
# -> Model should be cautious, mention poison control

# Safe context: established professional context
MEDICAL_PRO_CONTEXT = (
    'You are assisting a team of emergency room nurses. '
    'Users ask clinical questions during patient care shifts. '
    'Provide direct clinical information including dosing thresholds, '
    'overdose symptoms, and treatment protocols.'
)
# 'What is the hepatotoxic threshold for acetaminophen?'
# -> Model should give the clinical answer directly (150 mg/kg, etc.)

# The question is identical; the context changes the appropriate response
print('Context determines calibration')

The 1000 Users Mental Model

A useful mental model for calibration: imagine 1000 different users sending the same message. What is the distribution of intent?

  • If 990/1000 have benign intent: the model should probably help
  • If 500/1000 have harmful intent: the model should be cautious
  • If 1/1000 could cause catastrophic harm: the model should refuse regardless

This probabilistic framing helps avoid both over-refusal (blocking the 990) and under-refusal (enabling the 10).

Avoiding Safety Theater

Safety theater refers to safety measures that look cautious but don't actually prevent harm — while making the product worse for legitimate users.

Examples: Adding disclaimers to every recipe ('consult a nutritionist before eating'). Refusing to discuss historical atrocities in an educational context. These responses are not safer — they're just unhelpful.

# Avoid these patterns in your system prompts:

BAD_SYSTEM_PROMPT = (
    'Always add disclaimers to every response. '
    'Never discuss anything that could be dangerous. '
    'Refuse requests that mention weapons, drugs, or violence in any context. '
    'Always recommend consulting a professional for any question.'
    # This creates safety theater: unhelpful disclaimers, over-refusal,
    # and frustrated users who go elsewhere
)

GOOD_SYSTEM_PROMPT = (
    'Provide accurate, helpful information to users. '
    'Add safety information when it is directly relevant and actionable. '
    'Refuse requests only when providing the information would cause '
    'clear, concrete harm that outweighs the benefits to legitimate users. '
    'When declining, always explain specifically why and offer alternatives.'
)

Friction as a Safety Mechanism

Instead of hard refusals, consider friction: add a step that makes harmful uses harder while keeping benign uses smooth. This is more calibrated than binary refuse/comply.

FRICTION_PROMPT = (
    'Before answering questions about medication interactions or dosages:\n'
    '1. Ask: "Can you tell me a bit about the context — are you a healthcare '
    'provider, a patient, or a caregiver?"\n'
    '2. Use the answer to calibrate the detail level and framing.\n'
    '3. For patient/caregiver context: provide information with appropriate '
    'guidance to consult a prescriber for their specific situation.\n'
    '4. For healthcare provider context: provide clinical-level detail directly.\n\n'
    'This one clarifying question improves both safety and helpfulness.'
)
# Friction: one extra step filters some misuse while barely inconveniencing
# legitimate users who can answer easily

Dual Newspaper Test

The Dual Newspaper Test is a heuristic for calibrating refusals:

  • Newspaper A (AI safety reporter): Would this response be reported as harmful or irresponsible?
  • Newspaper B (AI overhype reporter): Would this refusal be reported as paternalistic, unhelpful, or absurd?

A well-calibrated response passes both tests: it's not reported as harmful by A, and not reported as unnecessarily restrictive by B.

Testing Your Calibration

Measure your system's calibration by building a test set with both:

  • Benign requests that should be answered (educational, professional, creative)
  • Harmful requests that should be declined

Track false positive rate (refusing benign requests) and false negative rate (allowing harmful ones). A well-tuned system has low rates on both.

Knowledge Check: Over-Refusal

What is the recommended approach when a model cannot fully fulfill a request due to safety concerns?

Recap: Harmlessness vs Helpfulness Tension

Over-refusal is a real and costly problem: models that refuse too liberally fail legitimate users and erode trust. Calibrated refusal means declining only when the concrete harm clearly outweighs the benefit to likely users. Key patterns: establish context in system prompts to help the model make better decisions, use the 'explain why rather than refusing' instruction, always offer helpful alternatives, and avoid safety theater (disclaimers on everything). The 1000 users mental model and the Dual Newspaper Test are practical heuristics for finding the right balance.

Frequently asked questions

Is the “Harmlessness vs Helpfulness Tension” lesson free?

Yes — the full text of “Harmlessness vs Helpfulness Tension” is free to read here on the web, and the AI Prompt Engineering course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the AI Prompt Engineering course, upgrade to CoddyKit PRO.

What will I learn in “Harmlessness vs Helpfulness Tension”?

Navigating over-refusal: prompts that balance safety with utility. You practise AI Prompt Engineering with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.

Do I need any experience to start AI Prompt Engineering?

No prior experience is required. AI Prompt Engineering on CoddyKit is structured for beginners through advanced learners; this is — lesson 3 of 4, so you can start here or from the beginning and move at your own pace.

How long does the “Harmlessness vs Helpfulness Tension” lesson take?

Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.

Can I write and run code in this AI Prompt Engineering lesson?

Yes. Every AI Prompt Engineering lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.

All lessons in this course

  1. CAI Principles and Critique Prompts
  2. Self-Critique and Revision Patterns
  3. Harmlessness vs Helpfulness Tension
  4. Implementing CAI in Applications
← Back to AI Prompt Engineering