"Prompt Engineering 101 (2026) — Five Patterns for Asking Better Questions"

Distilled from Anthropic and OpenAI's official guides, with copy-paste templates anyone can use


ํ•ต์‹ฌ ์š”์•ฝ

  • Audience: Anyone using ChatGPT, Claude, or Gemini who keeps getting answers that miss the point — plus developers writing their first prompts.
  • What you'll get: 1) Five patterns for better prompts (per Anthropic/OpenAI official docs), 2) copy-paste templates for each, 3) the seven most common mistakes, 4) a before/after example, 5) what 2026 research changed.
  • Mental model: An LLM isn't a wizard. It's a brand-new intern. Brief it the way you'd brief a smart human who has zero context.

1. Why the same question gives different answers

LLMs continue your input statistically. Vague prompt → vague answer. Specific prompt → specific answer. "Write something good" and "Write a 50-character SNS ad headline targeting 30-something professionals, casual tone, one emoji" share intent — but the output gap is enormous.

Anthropic's official guide lists five core techniques: be clear and direct, give examples, let the model think step by step, assign a role, use structure (XML tags). The five patterns below are exactly those, translated for everyday users.


2. Pattern 1 — Be clear and direct

Bad

"Write a marketing post."

Good

"Write an SNS ad caption for newly-released wireless earbuds, targeted at women in their 30s who work full-time. Highlight three core values. One sentence under 50 characters. Include one emoji. Friendly but professional tone."

Checklist

  • [ ] Audience: Who's reading? (women in their 30s, full-time workers)
  • [ ] Format: What kind of output? (SNS ad caption)
  • [ ] Constraints: Length, count, structure (50 chars, 1 emoji)
  • [ ] Style: Tone, voice, register (friendly-professional)

If retyping this every time is annoying, save it once: ChatGPT Custom GPTs, Claude Projects, Gemini Gems.


3. Pattern 2 — Show examples (few-shot)

A few examples beat paragraphs of explanation.

Bad

"Turn my journal entry into a tweet."

Good

"Convert journal entries into tweets in this style.

Example 1. Journal: "Had ramen for lunch. 30-minute line. Worth it." Tweet: "30 minutes in line for ramen. One bite forgave everything ๐Ÿœ"

Example 2. Journal: "Saw a movie with a friend on the weekend. Moving." Tweet: "Old friend + unexpected masterpiece. Wish weekends were longer."

Now convert: "Worked until dawn. Looked up — already 6 AM.""

Why it works

2026 research shows 1–2 examples deliver an average 7.48% accuracy lift over zero-shot, with diminishing returns past 4–5 examples (Few-Shot Prompting 2026 guide). 2–3 diverse examples is the sweet spot.


4. Pattern 3 — Let it think (chain of thought)

For anything involving reasoning or calculation, adding "think step by step" raises accuracy with almost zero effort.

Bad

"Is this remodeling quote reasonable? (quote attached)"

Good

"Decide whether this remodeling quote is reasonable.

Walk through the analysis in this order: 1. Compare each line item against market rates 2. Flag missing or duplicated items 3. Check whether material grade matches the price 4. Final verdict (fair / overpriced / underbid + why)

Quote: ..."

What changed in 2026

Recent research suggests strong models (GPT-5, Claude 4) usually need only "think step by step" — not full chain-of-thought examples (Zero-shot CoT paper). Add demonstrations only for hard problems or weaker models.


5. Pattern 4 — Assign a role

"You are [role]" upfront aligns tone, perspective, and expertise in one shot.

Bad

"Review this contract."

Good

"You are a contract lawyer specializing in IT startups. Review the SaaS agreement below and produce: 1. Clauses that are risky from the supplier (us) perspective 2. Phrasing that's ambiguous or could be read multiple ways 3. Protective clauses we should add

Output in plain English, bulletized."

Cautions

  • Be specific: "lawyer" < "IT startup contract lawyer."
  • Roles don't fix knowledge gaps. A "doctor" persona still hallucinates if the underlying training didn't cover it.
  • Avoid impersonating real people / celebrities — ethics + IP issues.

6. Pattern 5 — Add structure (XML tags or sections)

Long inputs need separators. Without them, the model can confuse instructions with content.

Bad

"Use the document below to draft a reply to this email." (everything pasted as plain text)

Good

``` [Full company refund policy]

[Original customer email]

Draft a reply that respects the policy. Polite but firm. ```

XML tags are Anthropic's recommendation. Markdown headers (### Context, ### Email, ### Task) work fine for OpenAI. Pick one and use it consistently.


7. The seven most common mistakes

Mistake Result Fix
1. Cramming many requests into one prompt Shallow or partial answers One prompt = one task
2. Negative instructions ("don't do X") Often ignored Reframe as positive ("do Y instead")
3. Vague qualifiers ("make it nice", "well") Inconsistent output Measurable criteria ("3 bullets," "under 300 words")
4. No context, just a directive Generic answer Lead with 1–2 lines of background and goal
5. Stacking unrelated questions in one chat Earlier turns bias the model New chat per topic
6. "Be accurate" Confident guesses "If unsure, reply 'uncertain'"
7. Restarting from scratch when unsatisfied Wasted tokens "From the previous answer, change only X"

8. Before / After — one more

Before

"Make me a presentation."

After

"You are a B2B SaaS sales coach.

Build a 30-minute pitch outline for a sales meeting.

Audience: a 50-person IT company — 1 CTO, 2 engineering leads. Our product: a cloud security automation SaaS at $500/month. Goal: book a follow-up PoC meeting after the 30 minutes.

Output as a slide-by-slide outline: - Slide number - Slide title (under 10 words) - Core message (one line) - Audience-engagement moment (if any)

8–12 slides total."

The wins are specificity and forced output structure. Same model, same cost, ~5× quality difference.


Developer notes

For API users:

  1. System vs. user prompts: Persona, rules, persistent constraints → system. Per-request input → user. Better for caching too.
  2. XML tags are more reliable than Markdown in mixed-content prompts. Claude 4 series is especially good at XML. OpenAI handles either fine.
  3. Few examples, but diverse: Two distinct cases beats five near-duplicates.
  4. Force JSON Schema when format matters: OpenAI response_format, Anthropic tool_use with a strict schema.
  5. Temperature: 0–0.3 for accuracy-critical tasks, 0.7–1.0 for creative work.
  6. Anthropic's interactive tutorial — free 9-chapter course. Worth one full pass if you're going deep.

References


This is part 3 of 11 in the AI Basics series. Next: Advanced prompting — roles, examples, and chaining in practice (extension).

๋Œ“๊ธ€

์ด ๋ธ”๋กœ๊ทธ์˜ ์ธ๊ธฐ ๊ฒŒ์‹œ๋ฌผ

Agent Memory Engine (2/10) — Building an AI Agent Memory System with SQLite Alone

"ML Foundations (9/9) — PyTorch vs TensorFlow, and the Road to Local LLMs"

"RAG Core Study (14/26) — Evaluation Sets with RAGAS & DeepEval"

"ML Foundations (8/9) — Deep Learning Architectures: CNN, RNN, Attention"

"ML Foundations (7/9) — Deep Learning Training: Optimizers, Regularization, Initialization"

OpenClaw to Hermes Migration (2/13) — What to Preserve, Partially Port, or Discard

AI Agents I Built (5/7) — Building an Automated Blogger API Publishing System