mozg.betaSign in

explore / AI & agents / mozg

Prompt Engineering

Answer how to write effective prompts for Claude, as Anthropic's own interactive tutorial teaches: basic structure and roles, separating data from instructions, output formatting, step-by-step thinking, few-shot examples, avoiding hallucinations, building complex prompts from scratch, chaining, and tool use — with the concrete techniques and example prompts, not generic advice.

136 notes · updated 2026-08-04 · trained 81%

since last sitting: +3 newly passed — this brain is learning

Ask it things like

answers 24/30 on its latest exam
How can you use citations to prevent hallucinations in document-based questions?Avoiding Hallucinations
What is the key difference between asking Claude to extract evidence first versus asking it to answer directly?Avoiding Hallucinations
What single principle underlies all effective prompt engineering according to the tutorial?Building Complex Prompts
Why is few-shot prompting more effective than descriptive instructions for output formatting tasks?Few-Shot Prompting
Why do XML tags prevent Claude from misinterpreting email text when given a politeness task?Separating Data from Instructions
What XML tag structure helps Claude work through brainstorming problems step-by-step?Step-by-Step Thinking
What is the two-part structure of a tool use system prompt?Tool Use
What 'out' should you give Claude to avoid hallucinations on uncertain facts?Avoiding Hallucinations
use this brain
# sign in to get a token
$ claude mcp add --transport http mozg \
https://mozg.sh/mcp --header "Authorization: Bearer …"
> use mozg/prompt-engineering — …
Get a token

Use this brain

Sign in and add it, and every agent you have connected can read it — nothing to download, and it stays current as the author updates it.

Sign in to add it

What it can answer

30 checks
81%
Avoiding Hallucinations5 / 5
Building Complex Prompts3 / 3
Few-Shot Prompting3 / 3
Output Formatting3 / 3
Step-by-Step Thinking3 / 3
Tool Use3 / 4
Separating Data from Instructions2 / 3
Basic Structure & Roles1 / 3
Tutorial Setup & API1 / 3
exam badge — share this score →

Inside

  • Substitute Claude's previous output into follow-up prompts · chaining
  • Prompt chaining enables function-like behavior · chaining
  • Messages array structure: required fields · messages api
  • Example: Chaining prompts to create and improve a story · chaining
  • Example: Chaining prompts to find and alphabetize names · chaining
  • Example: Chaining prompts to validate and correct word list · chaining
  • Give Claude an out to prevent unnecessary revisions · chaining
  • get_completion helper function signature and parameters · messages api
  • Multi-turn conversation structure for prompt chaining · chaining
  • Claude improves accuracy when asked to double-check responses · chaining
  • Use prompt chaining to improve response quality iteratively · chaining
  • Advanced RAG architectures available for Claude · tool use
  • Claude can search over custom documents and vector datastores · tool use
  • Claude can search Wikipedia and retrieve articles · tool use

Licence

CC BY-NC-SA 4.0

Use it, copy it, build on it, with credit. Selling it is not allowed.