โญโญ Intermediate โฑ๏ธ 4 min read Constraint Prompting

๐Ÿšง Set Constraints โ€” Define the Boundaries

Learn constraint prompting โ€” how to set limits, boundaries, and rules that keep AI responses focused and useful. Hands-on practice included.

โšก TL;DR

Set boundaries โ€” word limits, topic scope, content rules โ€” to get focused, useful output instead of a wall of text.

What Is It?

Setting Constraints means telling AI what NOT to do, or putting limits on its response. Without constraints, AI tends to be verbose, generic, and unfocused.

Think of it like a garden fence. Without boundaries, a garden grows wild and messy. With the right constraints, you get a beautiful, focused space. Constraints don’t limit creativity โ€” they channel it.

๐Ÿ’ก Constraints are liberating. Paradoxically, the more constraints you give, the more focused and useful the output. “Write about cloud computing” is overwhelming. “Write 3 benefits of cloud computing for small businesses, in plain English, under 150 words” is specific and actionable.

When to Use It

  • โœ… When AI responses are too long or verbose
  • โœ… When you need output for a specific audience
  • โœ… When you want to avoid certain content (jargon, code, opinions)
  • โœ… When you need a specific word count or scope

Before & After

โŒ Before (No Constraints)

Write about cloud computing

โœ… After (With Constraints)

Write 3 key benefits of migrating to cloud computing for small businesses with under 50 employees. Maximum 150 words. Use plain English โ€” no technical jargon. Don’t mention specific vendors. Focus on cost savings, flexibility, and security.

What’s better: The AI will deliver exactly what you need โ€” concise, jargon-free, and focused on what matters to the audience. No wasted words.

Platform Tips

Microsoft 365 Copilot

  • In Word, “Keep it under 300 words” and “Use simple language” are particularly effective
  • In Outlook, “Reply in 3 sentences or fewer” keeps emails concise
  • In PowerPoint, “Maximum 5 bullet points per slide, no more than 8 words each”

ChatGPT

  • ChatGPT respects word limits fairly well but may go slightly over โ€” use “strictly under X words”
  • Negative constraints work well: “Do NOT include code examples” or “Avoid marketing language”

Claude

  • Claude follows constraints precisely โ€” it’s excellent at “exactly 3 paragraphs” or “no more than 5 items”
  • Use explicit boundaries: “Only discuss X, Y, and Z. Nothing else.”

Gemini

  • Be very explicit with constraints โ€” “IMPORTANT: Keep under 100 words”
  • Gemini sometimes ignores soft constraints, so use firm language

Real Examples from the Prompt Library

  1. Email โ€” Word count constraints for concise emails
  2. Summarising โ€” Scope constraints for focused summaries
  3. Writing โ€” Tone and audience constraints

๐Ÿงช Try It Yourself

Rewrite this vague prompt using the Set Constraints technique:

Starter prompt (needs improvement):
Write about cloud computing
Checklist โ€” does your prompt include:
โฌœ Includes a length or scope constraint
โฌœ Sets a content rule (do/don't)
โฌœ Narrows the topic focus
๐Ÿ’ก Stuck? Show example answer

Write 3 key benefits of migrating to Microsoft 365 for small businesses with under 50 employees. Maximum 150 words. Use plain English โ€” no technical jargon or acronyms. Don't mention competitors. Focus on: cost predictability, remote work enablement, and built-in security.

๐Ÿ”ง Fix This Prompt

This prompt is broken. Can you spot what's wrong and fix it?

Write about cloud computing benefits
โฌœ Adds a length constraint
โฌœ Narrows the topic scope
โฌœ Sets a content rule

โ“ Frequently Asked Questions

What kinds of constraints can I set?

Common constraints include: length (max 200 words), scope (focus only on security), audience (written for non-technical managers), format (no bullet points), content rules (don't use jargon), and tone (professional but friendly).

Can constraints make responses worse?

Overly restrictive constraints can. If you say 'explain quantum computing in 10 words,' quality suffers. Set constraints that help focus without crippling the response.

๐Ÿ’ฌ