# Claude Code in Action 受講ノート（2026-07-02 修了）

> **全文ナレッジ（DA式）完成**: 全19レッスンの日本語要点整理＋英語逐語 → [claude-code-in-action/README.md](claude-code-in-action/README.md)

- 修了証: https://verify.skilljar.com/c/cw5bokenygwf （NAOKI NAKASHIMA / July 2, 2026 / Anthropic Education）
- PDF: docs/anthropic-guide/certificates/claude-code-in-action-certificate.pdf
- 21レッスン（動画 約1時間）＋満足度サーベイ＋修了クイズ8問（合格）
- 動画は当初字幕なしだったが、HLS から音声を取得し mlx_whisper で全文文字起こし済み（→ 全文ナレッジ）。本ノートは「コース構成」「修了クイズ完全収録」「講座A設計への学び」の概要版。

## コース構成（educator 視点＝講座A設計の参考）

### Module 1: What is Claude Code?（概念）
1. Introduction（0:38）— コース全体の予告
2. What is a coding assistant?（5:53）— **コーディングアシスタントの内部構造**。LLM はテキスト入出力しかできない→ツールシステム（ファイル読取・コマンド実行・編集）で外界と接続する、というアーキテクチャ理解が最初
3. Claude Code in action — 実際の動作デモ

### Module 2: Getting Hands On（実践）
4. Claude Code setup ／ 5. Project setup — 導入と対象プロジェクト準備
6. Adding context — /init・CLAUDE.md・@メンションでコンテキストを与える
7. Making changes — 変更依頼の型
8. （Course satisfaction survey）
9. Controlling context — /clear・/compact 等でコンテキストを制御
10. Custom commands — .claude/commands/ の markdown コマンド。**$ARGUMENTS プレースホルダでランタイム引数**
11. MCP servers with Claude Code — 外部ツール接続（Playwright 等でブラウザ自動化の例）
12. GitHub integration — @claude メンション・PR レビュー。**GitHub Actions で MCP を使う時は各ツールを個別に allowedTools に列挙**

### Module 3: Hooks and the SDK（拡張・自動化）
13. Introducing hooks → 14. Defining hooks → 15. Implementing a hook → 16. Gotchas → 17-18. Useful hooks ×2 — コースの1/3が hooks。**「教える価値が最も高い拡張機構」として位置づけ**
19. The Claude Code SDK — プログラムからの実行（headless / Python / TS）

### Module 4: Wrapping Up
20. Quiz（8問・修了要件） ／ 21. Summary and next steps

## 修了クイズ8問（完全収録・全選択肢＋正答）

**Q1. What is the fundamental limitation of language models that necessitates the use of a tool system in coding assistants?**
- They can only generate code in specific programming languages
- They have limited memory capacity for large codebases
- They cannot understand complex programming concepts
- ✅ **They can only process text input/output and cannot directly interact with external systems**

**Q2. What permission configuration is required when integrating MCP servers with Claude Code in GitHub Actions?**
- ✅ **Each MCP server tool must be individually listed in the permissions**
- No special permissions are needed if running in GitHub Actions
- Permissions are automatically inherited from the GitHub repository settings
- A single blanket permission for all MCP operations

**Q3. What is the primary difference between Plan Mode and Thinking Mode in Claude Code?**
- Plan Mode is for writing code while Thinking Mode is for debugging
- Plan Mode is faster while Thinking Mode is more accurate
- Plan Mode uses fewer tokens while Thinking Mode uses more tokens
- ✅ **Plan Mode handles breadth (multi-step tasks) while Thinking Mode handles depth (complex logic)**

**Q4. Which of the following correctly describes the three types of Claude.md files and their usage?**
- Project level (debugging), Local level (testing), Machine level (production)
- Project level (personal use), Local level (team sharing), Machine level (repository specific)
- ✅ **Project level (shared with team, committed), Local level (personal, not committed), Machine level (global for all projects)**
- Project level (configuration), Local level (documentation), Machine level (automation)

**Q5. How do you create a custom command in Claude Code that accepts runtime parameters?**
- Use the @parameters decorator in the command file
- Define parameters in settings.json configuration
- Add command line flags when executing the command
- ✅ **Include $ARGUMENTS placeholder in the markdown command file**

**Q6. Which type of hook can prevent a tool call from happening if certain conditions are met?**
- PostToolUse hook ／ Project hook ／ Global hook
- ✅ **PreToolUse hook**

**Q7. A developer wants to prevent Claude from reading sensitive .env files. Which type of hook should they set up, and what tool names would they likely match?**
- PostToolUse hook, matching Write and Edit
- PreToolUse hook, matching Write and Create
- ✅ **PreToolUse hook, matching Read and Grep**
- PostToolUse hook, matching Read and Delete

**Q8. What is the primary purpose of hooks in Claude Code?**
- To manage project dependencies.
- To automatically generate new code snippets.
- ✅ **To run commands before or after Claude executes a tool.**
- To provide a user interface for Claude.

（受験結果: 全問正答で合格 "You have passed!" ／ 2026-07-02）

## 講座A設計への学び（教え方の観察）

- 「概念（なぜ）→ 最小セットアップ → コンテキスト → 変更 → 拡張（MCP/GitHub）→ 自動化（hooks/SDK）→ クイズ→修了証」の段階設計
- 1レッスン=1トピック・2〜6分の短尺動画。ハンズオンは「自分のプロジェクトでやる」前提
- サーベイをコース中盤（Making changes 直後）に挟む＝完走前に感想を取る
- クイズは「概念の言語化」を問う4択8問・不合格でも再挑戦可・修了証は自動発行＋検証URL＋LinkedIn 追加
- 動画に字幕なし（非英語話者には不親切）→ 講座Aでは日本語ネイティブ＋資料配布で優位に立てる
