A visual, example-driven guide to Claude Code — from basic concepts to advanced agents, with copy-paste templates that bring immediate value.
fix: apply 2026-04-09 documentation accuracy updates
Luong NGUYENe015f39c687b
diff --git a/02-memory/README.md b/02-memory/README.mdindex 5371518..424a7f4 100644--- a/02-memory/README.md+++ b/02-memory/README.md@@ -25,9 +25,7 @@ The memory system operates at multiple levels, from global personal preferences|---------|---------|-------|-------------|| `/init` | Initialize project memory | `/init` | Starting new project, first-time CLAUDE.md setup || `/memory` | Edit memory files in editor | `/memory` | Extensive updates, reorganization, reviewing content |-| `#` prefix | Quick single-line memory add | `# Your rule here` | Adding quick rules during conversation |-| `# new rule into memory` | Explicit memory addition | `# new rule into memory<br/>Your detailed rule` | Adding complex multi-line rules |-| `# remember this` | Natural language memory | `# remember this<br/>Your instruction` | Conversational memory updates |+| `#` prefix | ~~Quick single-line memory add~~ **Discontinued** | — | Use `/memory` or ask conversationally instead || `@path/to/file` | Import external content | `@README.md` or `@docs/api.md` | Referencing existing documentation in CLAUDE.md |## Quick Start: Initializing Memory@@ -82,49 +80,39 @@ CLAUDE_CODE_NEW_INIT=1 claude- Git workflow conventions```-### Quick Memory Updates with `#`+### Quick Memory Updates-You can quickly add information to memory during any conversation by starting your message with `#`:+> **Note**: The `#` shortcut for inline memory was discontinued. Use `/memory` to edit memory files directly, or ask Claude conversationally to remember something (e.g., "remember that we always use TypeScript strict mode").-**Syntax:**+The recommended ways to add information to memory are:-```markdown-# Your memory rule or instruction here-```--**Examples:**+**Option 1: Use `/memory` command**-```markdown-# Always use TypeScript strict mode in this project+```bash+/memory+```-# Prefer async/await over promise chains+Opens your memory files in your system editor for direct editing.-# Run npm test before every commit+**Option 2: Ask conversationally**-# Use kebab-case for file names+```+Remember that we always use TypeScript strict mode in this project.+Please add to memory: prefer async/await over promise chains.```-**How it works:**+Claude will update the appropriate CLAUDE.md file based on your request.-1. Start your message with `#` followed by your rule-2. Claude recognizes this as a memory update request-3. Claude asks which memory file to update (project or personal)-4. The rule is added to the appropriate CLAUDE.md file-5. Future sessions automatically load this context+**Historical reference** (no longer functional):-**Alternative patterns:**+The `#` prefix shortcut previously allowed adding rules inline:```markdown-# new rule into memory-Always validate user input with Zod schemas--# remember this-Use semantic versioning for all releases--# add to memory-Database migrations must be reversible+# Always use TypeScript strict mode in this project ← no longer works```+If you relied on this pattern, switch to the `/memory` command or conversational requests.+### The `/memory` CommandThe `/memory` command provides direct access to edit your CLAUDE.md memory files within Claude Code sessions. It opens your memory files in your system editor for comprehensive editing.diff --git a/05-mcp/README.md b/05-mcp/README.mdindex c2dff16..8ebc5a2 100644--- a/05-mcp/README.md+++ b/05-mcp/README.md@@ -105,14 +105,6 @@ Server-Sent Events transport is deprecated in favor of `http` but still supporteclaude mcp add --transport sse legacy-server https://example.com/sse```-### WebSocket Transport--WebSocket transport for persistent bidirectional connections:--```bash-claude mcp add --transport ws realtime-server wss://example.com/mcp-```-### Windows-Specific NoteOn native Windows (not WSL), use `cmd /c` for npx commands:diff --git a/06-hooks/notify-team.sh b/06-hooks/notify-team.shindex 3e1d43a..1894218 100644--- a/06-hooks/notify-team.sh+++ b/06-hooks/notify-team.sh@@ -1,6 +1,8 @@#!/bin/bash# Send notifications on events-# Hook: PostPush+# Hook: PostToolUse (matcher: Bash) — run after bash commands; filter for git push in script logic+# Note: Claude Code has no native PostPush event. To trigger on git push, check the bash command+# string for "git push" using a matcher or conditional logic within this script.REPO_NAME=$(basename $(git rev-parse --show-toplevel 2>/dev/null) 2>/dev/null)COMMIT_MSG=$(git log -1 --pretty=%B 2>/dev/null)diff --git a/09-advanced-features/config-examples.json b/09-advanced-features/config-examples.jsonindex 30b53ff..a67f08c 100644--- a/09-advanced-features/config-examples.json+++ b/09-advanced-features/config-examples.json@@ -7,7 +7,7 @@"description": "Configuration for active development work","config": {"general": {- "model": "claude-sonnet-4-5",+ "model": "claude-sonnet-4-6","temperature": 0.7},"planning": {@@ -24,8 +24,7 @@},"hooks": {"PreToolUse:Write": "prettier --write ${file_path}",- "PostToolUse:Write": "eslint ${file_path}",- "PreCommit": "npm test"+ "PostToolUse:Write": "eslint ${file_path}"}}},@@ -35,7 +34,7 @@"description": "Configuration for reviewing code without modifications","config": {"general": {- "model": "claude-sonnet-4-5",+ "model": "claude-sonnet-4-6","temperature": 0.3},"permissions": {@@ -56,7 +55,7 @@"description": "Configuration for learning and experimentation","config": {"general": {- "model": "claude-sonnet-4-5",+ "model": "claude-sonnet-4-6","temperature": 0.5},"permissions": {@@ -90,9 +89,7 @@"requireConfirmationFor": ["Bash", "Git", "Write", "Edit"]},"hooks": {- "PreCommit": "npm test && npm run lint && npm run build",- "PrePush": "npm run test:e2e",- "PostPush": "~/.claude/hooks/notify-team.sh"+ "PreToolUse": "~/.claude/hooks/pre-commit.sh"},"checkpoints": {"autoCheckpoint": true@@ -109,7 +106,7 @@"description": "Configuration for automated CI/CD operations","config": {"general": {- "model": "claude-sonnet-4-5",+ "model": "claude-sonnet-4-6","temperature": 0},"permissions": {@@ -158,7 +155,7 @@"description": "Configuration for performance analysis and optimization","config": {"general": {- "model": "claude-sonnet-4-5",+ "model": "claude-sonnet-4-6","temperature": 0.4},"planning": {@@ -180,7 +177,7 @@"description": "Configuration for collaborative development","config": {"general": {- "model": "claude-sonnet-4-5",+ "model": "claude-sonnet-4-6","temperature": 0.6},"permissions": {@@ -255,7 +252,7 @@"description": "Configuration for writing documentation","config": {"general": {- "model": "claude-sonnet-4-5",+ "model": "claude-sonnet-4-6","temperature": 0.7},"permissions": {diff --git a/CATALOG.md b/CATALOG.mdindex 92244a7..d78bfa4 100644--- a/CATALOG.md+++ b/CATALOG.md@@ -63,7 +63,6 @@ Commands are user-invoked shortcuts that execute specific actions.| `/login` | Authenticate with Anthropic | Access features || `/logout` | Sign out | Switch accounts || `/sandbox` | Toggle sandbox mode | Safe command execution |-| `/vim` | Toggle vim mode | Vim-style editing || `/doctor` | Run diagnostics | Troubleshoot issues || `/reload-plugins` | Reload installed plugins | Plugin management || `/release-notes` | Show release notes | Check new features |@@ -453,7 +452,6 @@ cp 02-memory/personal-CLAUDE.md ~/.claude/CLAUDE.md| **Agent Hook Type** | Hooks that spawn a subagent instead of running a shell command | Set `"type": "agent"` in hook configuration || **Prompt Hook Type** | Hooks that inject prompt text into the conversation | Set `"type": "prompt"` in hook configuration || **MCP Elicitation** | MCP servers can request user input during tool execution | Handle via `Elicitation` and `ElicitationResult` hook events |-| **WebSocket MCP Transport** | WebSocket-based transport for MCP server connections | Use `"transport": "websocket"` in MCP server config || **Plugin LSP Support** | Language Server Protocol integration via plugins | Configure LSP servers in `plugin.json` for editor features || **Managed Drop-ins** | Organization-managed drop-in configurations (v2.1.83) | Admin-configured via managed policies; auto-applied to all users |diff --git a/QUICK_REFERENCE.md b/QUICK_REFERENCE.mdindex d0a8474..e1459d9 100644--- a/QUICK_REFERENCE.md+++ b/QUICK_REFERENCE.md@@ -389,9 +389,8 @@ cp -r 03-skills/code-review ~/.claude/skills/| **Auto Mode** | Fully autonomous operation with background classifier | `--enable-auto-mode` flag, `Shift+Tab` to cycle modes || **Channels** | Discord and Telegram integration | `--channels` flag, Discord/Telegram bots || **Voice Dictation** | Speak commands and context to Claude | `/voice` command |-| **Hooks (25 events)** | Expanded hook system with 4 types | command, http, prompt, agent hook types |+| **Hooks (26 events)** | Expanded hook system with 4 types | command, http, prompt, agent hook types || **MCP Elicitation** | MCP servers can request user input at runtime | Auto-prompted when server needs clarification |-| **WebSocket MCP** | WebSocket transport for MCP connections | Configure in `.mcp.json` with `ws://` URLs || **Plugin LSP** | Language Server Protocol support for plugins | `userConfig`, `${CLAUDE_PLUGIN_DATA}` variable || **Remote Control** | Control Claude Code via WebSocket API | `claude --remote` for external integrations || **Web Sessions** | Browser-based Claude Code interface | `claude web` to launch |@@ -444,8 +443,8 @@ echo $GITHUB_TOKEN| Team standards | Memory | `02-memory/project-CLAUDE.md` || Auto workflow | Skill | `03-skills/code-review/` || Specialized task | Subagent | `04-subagents/code-reviewer.md` |-| External data | MCP (+ Elicitation, WebSocket) | `05-mcp/github-mcp.json` |-| Event automation | Hook (25 events, 4 types) | `06-hooks/pre-commit.sh` |+| External data | MCP (+ Elicitation) | `05-mcp/github-mcp.json` |+| Event automation | Hook (26 events, 4 types) | `06-hooks/pre-commit.sh` || Complete solution | Plugin (+ LSP support) | `07-plugins/pr-review/` || Safe experiment | Checkpoint | `08-checkpoints/checkpoint-examples.md` || Fully autonomous | Auto Mode | `--enable-auto-mode` or `Shift+Tab` |diff --git a/zh/01-slash-commands/README.md b/zh/01-slash-commands/README.mdindex 910a1ec..5bd0354 100644--- a/zh/01-slash-commands/README.md+++ b/zh/01-slash-commands/README.md@@ -81,7 +81,6 @@ Claude Code 目前提供 55+ 个内置命令和 5 个内置 Skills。你可以| `/tasks` | 列出/管理后台任务 || `/terminal-setup` | 配置终端快捷键 || `/theme` | 更改颜色主题 |-| `/vim` | 切换 Vim/Normal 模式 || `/voice` | 切换按住说话语音输入 |### 内置 Skills@@ -103,6 +102,7 @@ Claude Code 目前提供 55+ 个内置命令和 5 个内置 Skills。你可以| `/review` | 已弃用,已被 `code-review` 插件替代 || `/output-style` | 自 v2.1.73 起弃用 || `/fork` | 已重命名为 `/branch`(别名仍可用,v2.1.77) |+| `/vim` | 自 v2.1.92 起移除;改用 `/config → Editor mode` |### 最近变化diff --git a/zh/CATALOG.md b/zh/CATALOG.mdindex 4045b84..a157012 100644--- a/zh/CATALOG.md+++ b/zh/CATALOG.md@@ -63,7 +63,6 @@| `/login` | 通过 Anthropic 认证 | 访问功能 || `/logout` | 登出 | 切换账号 || `/sandbox` | 切换 sandbox 模式 | 安全执行命令 |-| `/vim` | 切换 vim 模式 | 类 Vim 编辑 || `/doctor` | 运行诊断 | 排查问题 || `/reload-plugins` | 重新加载已安装的 plugins | 插件管理 || `/release-notes` | 显示更新说明 | 查看新功能 |