原典: Anthropic’s Prompt Engineering Interactive Tutorial
一行要約
9章 + 付録の演習付きコース。章の並びを prompting の学習順序に使える(ただし Claude 3 世代向け) — 基本構造 → 明確さ → role → データと指示の分離 → 出力形式 → 段階的思考 → 例 → hallucination 回避 → 複雑なプロンプトの組み立て。
要点
After completing this course, you will be able to:
- Master the basic structure of a good prompt
- Recognize common failure modes and learn the ‘80/20’ techniques to address them
- Understand Claude’s strengths and weaknesses
- Build strong prompts from scratch for common use cases
このコースを終えると、良いプロンプトの基本構造を身につけ、よくある失敗の型を見分けてそれに効く「80/20」の技法を学び、Claude の強みと弱みを理解し、よくあるユースケース向けの強いプロンプトをゼロから組めるようになる。
章の順に進める設計で、各レッスンに “Example Playground”(手を動かす場所)がある。答えの鍵(answer key)も公開されている。
章立て
Beginner
- Basic Prompt Structure
- Being Clear and Direct
- Assigning Roles
Intermediate
- Separating Data from Instructions
- Formatting Output & Speaking for Claude
- Precognition (Thinking Step by Step)
- Using Examples
Advanced
- Avoiding Hallucinations
- Building Complex Prompts (Industry Use Cases)
- Complex Prompts from Scratch — Chatbot
- Complex Prompts for Legal Services
- 演習: Complex Prompts for Financial Services
- 演習: Complex Prompts for Coding
Appendix — Beyond Standard Prompting
- Chaining Prompts
- Tool Use
- Search & Retrieval
現在の文書群との対応
| 章 | 現在の対応文書 |
|---|---|
| 1–2. 基本構造 / 明確さ | claude-prompting-best-practices「Be clear and direct」 |
| 3. role | 同「Give Claude a role」 |
| 4. データと指示の分離 | 同「Structure prompts with XML tags」、mitigate-jailbreaks(信頼できないコンテンツの扱い) |
| 5. 出力形式 / Speaking for Claude | 同「Control the format of responses」。prefill 部分は increase-consistency の移行先を参照 |
| 6. 段階的思考 | thinking。推論を書き出させる形は Fable 5.1 / Fable 5 / Opus 5.5 / Opus 5 / Sonnet 5.5 で断られうるので、thinking に任せる |
| 7. 例 | claude-prompting-best-practices「Use examples effectively」、define-tools の input_examples |
| 8. hallucination 回避 | reduce-hallucinations |
| 9. 複雑なプロンプト | use-case-guides |
| 付録: chaining / tool use / retrieval | claude-prompting-best-practices「Chain complex prompts」、define-tools、contextual-retrieval |
注意: このチュートリアルは Claude 3 Haiku を前提に書かれている。章5の “Speaking for Claude”(prefill)は Claude 4.6 以降では非対応、章6の推論を書き出させる形は上の5モデルで断られうるので、この2章は新しいモデルを対象にした文書(claude-prompting-best-practices)で読み替える必要がある。
そのまま使える具体例
学習順序として使う:
| 章 | 扱うもの |
|---|---|
| 1. Basic Prompt Structure | プロンプトの骨格 |
| 2. Being Clear and Direct | 曖昧さを消す |
| 3. Assigning Roles | system prompt での role |
| 4. Separating Data from Instructions | XML タグによる分離 |
| 5. Formatting Output | 出力形式の制御 |
| 6. Precognition | 段階的思考。推論を書き出させる形は、Fable 5.1 / Fable 5 / Opus 5.5 / Opus 5 / Sonnet 5.5 では断られうる(claude-prompting-best-practices)ので thinking に任せる |
| 7. Using Examples | few-shot |
| 8. Avoiding Hallucinations | 接地と「わからない」の許可 |
| 9. Building Complex Prompts | 実際のユースケースへの組み立て |
| 付録 | Chaining / Tool Use / Search & Retrieval |
原典で言及されている関連文書
- claude-prompting-best-practices — 現在の living reference
- prompt-engineering-overview — この教材への導線
- best-practices-for-prompt-engineering — 一般論版
- reduce-hallucinations / increase-consistency / define-tools — 各章の現代版