claude-code-ultimate-guide/quiz/questions/10-reference.yaml
Florian BRUNIAUX a7962d5560 release: v3.20.4 - 30 new quiz questions (227 → 257)
Add 30 questions across 11 categories covering recent guide content:
Advanced Patterns (+8), MCP Servers (+3), Architecture (+3),
Reference (+3), Hooks (+2), Learning (+2), Security (+2),
AI Ecosystem (+3), Memory (+2), Agents (+1), Privacy (+1).

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 22:17:32 +01:00

516 lines
17 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

category: "Reference"
category_id: 10
source_file: "guide/ultimate-guide.md"
questions:
- id: "10-001"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "What keyboard shortcut enters Plan Mode (toggles plan/execute)?"
options:
a: "Ctrl+P"
b: "Shift+Tab"
c: "Alt+P"
d: "Ctrl+Shift+P"
correct: "b"
explanation: |
`Shift+Tab` toggles between Plan Mode and Execute Mode.
Plan Mode navigation:
- `Shift+Tab` once: Toggle plan/execute
- `Shift+Tab` twice: Enter deep Plan Mode (with Opus in OpusPlan)
Plan Mode allows safe, read-only exploration before making changes.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.2 Keyboard Shortcuts"
anchor: "#session-control"
- id: "10-002"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "What keyboard shortcut rewinds to a previous checkpoint (undo Claude's changes)?"
options:
a: "Ctrl+Z"
b: "Esc (double-tap)"
c: "Ctrl+R"
d: "Alt+Z"
correct: "b"
explanation: |
Double-tap `Esc` (Esc×2) rewinds to the previous checkpoint.
This is equivalent to the `/rewind` command.
It undoes Claude's recent changes in the current session without creating git commits.
Use when Claude made a mistake and you want to try a different approach.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.2 Keyboard Shortcuts"
anchor: "#session-control"
- id: "10-003"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "What does `/compact` do?"
options:
a: "Compresses files on disk"
b: "Summarizes and compresses the conversation context"
c: "Minimizes the terminal window"
d: "Reduces Claude's response length"
correct: "b"
explanation: |
`/compact` summarizes and compresses the conversation context.
Use `/compact` when:
- Context usage reaches 70-90%
- Responses become slow
- Claude starts forgetting earlier context
This frees up context space while preserving important information.
Check context usage with `/status`.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.1 Commands Table"
anchor: "#built-in-commands"
- id: "10-004"
difficulty: "senior"
profiles: ["senior", "power"]
question: "At what context percentage should you run /compact according to best practices?"
options:
a: "50%"
b: "70-90%"
c: "95%+"
d: "Only when errors occur"
correct: "b"
explanation: |
Context management guidelines:
| Context Level | Action |
|--------------|--------|
| 0-50% | Work freely |
| 50-75% | Be selective |
| **75-90%** | **Use `/compact`** |
| 90%+ | Use `/clear` |
Proactive compaction at 70% prevents context degradation and maintains performance.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.4 Troubleshooting"
anchor: "#context-recovery"
- id: "10-005"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "What keyboard shortcut cancels the current operation?"
options:
a: "Esc"
b: "Ctrl+C"
c: "Ctrl+Z"
d: "Alt+C"
correct: "b"
explanation: |
`Ctrl+C` cancels the current operation.
Important shortcuts:
- `Ctrl+C`: Cancel operation
- `Ctrl+D`: Exit Claude Code
- `Ctrl+R`: Retry last operation
- `Ctrl+L`: Clear screen (keeps context)
- `Esc`: Dismiss current suggestion
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.2 Keyboard Shortcuts"
anchor: "#session-control"
- id: "10-006"
difficulty: "senior"
profiles: ["senior", "power"]
question: "What is the correct permission pattern to allow ALL git commands?"
options:
a: 'Bash(git)'
b: 'Bash(git *)'
c: 'git:*'
d: 'Bash(*git*)'
correct: "b"
explanation: |
The pattern `Bash(git *)` allows any git command.
Permission pattern examples:
- `Bash(git *)` - Any git command
- `Bash(npm test)` - Exactly "npm test"
- `Edit` - All file edits
- `mcp__serena__*` - All Serena tools
Wildcards (*) enable flexible permission matching.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.3 Configuration Reference"
anchor: "#permission-patterns"
- id: "10-007"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "Where should project-specific CLAUDE.md be placed (committed to git)?"
options:
a: "~/.claude/CLAUDE.md"
b: "/project/.claude/CLAUDE.md"
c: "/project/CLAUDE.md"
d: "~/.config/claude/project.md"
correct: "c"
explanation: |
CLAUDE.md locations:
| Location | Scope | Committed |
|----------|-------|-----------|
| `~/.claude/CLAUDE.md` | All projects | N/A (global) |
| `/project/CLAUDE.md` | This project | **Yes** |
| `/project/.claude/CLAUDE.md` | Personal | No |
The root `CLAUDE.md` is committed and shared with the team.
The `.claude/CLAUDE.md` is personal and should be in `.gitignore`.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.3 Configuration Reference"
anchor: "#claudemd-locations"
- id: "10-008"
difficulty: "senior"
profiles: ["senior", "power"]
question: "What does the --mcp-debug flag do?"
options:
a: "Disables MCP servers"
b: "Debugs MCP server connections with verbose output"
c: "Tests MCP configurations"
d: "Enables MCP auto-discovery"
correct: "b"
explanation: |
The `--mcp-debug` flag enables debug mode for MCP server connections.
MCP debugging techniques:
```bash
claude --mcp-debug # Debug all MCP connections
/mcp # View MCP status inside Claude Code
```
Use when MCP servers aren't connecting or tools aren't appearing.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.4 Troubleshooting"
anchor: "#mcp-debugging-techniques"
- id: "10-009"
difficulty: "power"
profiles: ["power"]
question: "If an MCP server name validation fails with pattern error, what characters ARE allowed?"
options:
a: "Letters only"
b: "Letters, numbers, underscores, hyphens (max 64 chars)"
c: "Any characters except spaces"
d: "Alphanumeric and periods"
correct: "b"
explanation: |
MCP server names must match: `^[a-zA-Z0-9_-]{1,64}`
Allowed:
- Letters (a-z, A-Z)
- Numbers (0-9)
- Underscores (_)
- Hyphens (-)
- Maximum 64 characters
Not allowed:
- Spaces
- Special characters (@, #, etc.)
- More than 64 characters
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.4 Troubleshooting"
anchor: "#error-1-tool-name-validation-failed"
- id: "10-010"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "What command shows session info including context usage and cost?"
options:
a: "/info"
b: "/status"
c: "/stats"
d: "/session"
correct: "b"
explanation: |
The `/status` command shows session information.
Output includes:
- Model being used
- Context usage percentage
- Session cost
- Token counts
Example output:
`Model: Sonnet | Ctx: 45.2k | Cost: $1.23 | Ctx(u): 42.0%`
Use `/stats` for usage statistics with activity graphs.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.1 Commands Table"
anchor: "#built-in-commands"
- id: "10-011"
difficulty: "senior"
profiles: ["senior", "power"]
question: "What flag limits maximum API spend in headless mode?"
options:
a: "--cost-limit"
b: "--max-budget-usd"
c: "--spending-cap"
d: "--budget"
correct: "b"
explanation: |
The `--max-budget-usd` flag sets maximum API spend (only with `--print`):
```bash
claude -p "analyze" --max-budget-usd 5.00
```
This prevents runaway costs in automated pipelines.
The operation stops if the budget is exceeded.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.3 Configuration Reference"
anchor: "#cli-flags-reference"
- id: "10-012"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "How do you run a shell command directly from Claude Code prompt?"
options:
a: "shell: command"
b: "!command"
c: "$command"
d: "run command"
correct: "b"
explanation: |
The `!command` prefix runs a shell command directly.
Quick actions:
- `!command` - Run shell command
- `@filename` - Reference file
- `Ctrl+C` - Cancel operation
- `Ctrl+R` - Retry last
Example: `!git status` runs git status without Claude interpreting it.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.1 Commands Table"
anchor: "#quick-actions"
- id: "10-013"
difficulty: "senior"
profiles: ["senior", "power"]
question: "What is the correct way to resume a specific session by ID?"
options:
a: "claude --session abc123"
b: "claude -r abc123"
c: "claude --load abc123"
d: "claude -s abc123"
correct: "b"
explanation: |
Use `-r` or `--resume` to resume a specific session:
```bash
claude -r abc123 # Resume session abc123
claude --resume abc123 # Same as above
claude -c # Resume last session (short)
claude --continue # Resume last session (long)
```
Combine with `-p` for scripting: `claude -r abc123 -p "check status"`
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.3 Configuration Reference"
anchor: "#cli-flags-reference"
- id: "10-014"
difficulty: "power"
profiles: ["power"]
question: "What is the recommended .gitignore pattern for Claude Code files?"
options:
a: "Ignore all .claude/ contents"
b: "Ignore settings.local.json and .claude/CLAUDE.md, keep agents/commands/hooks"
c: "Don't ignore anything"
d: "Ignore only agents/"
correct: "b"
explanation: |
Recommended .gitignore:
```gitignore
# Claude Code - Personal (ignore)
.claude/settings.local.json
.claude/CLAUDE.md
.claude/.serena/
# Claude Code - Team (keep/commit)
# .claude/agents/
# .claude/commands/
# .claude/hooks/
# .claude/settings.json
```
This keeps team workflows shared while personal settings stay private.
doc_reference:
file: "guide/ultimate-guide.md"
section: "9.11 Common Pitfalls & Best Practices"
anchor: "#recommended-gitignore"
- id: "10-015"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "What is the daily workflow morning setup according to the guide?"
options:
a: "Just start coding"
b: "Git pull, /status, load project memory, review yesterday's progress"
c: "Run all tests first"
d: "Clear all context"
correct: "b"
explanation: |
Morning setup workflow:
1. Git pull latest changes
2. Review context with `/status`
3. Load project memory (`/sc:load` if using Serena)
4. Review yesterday's progress
This ensures you start with fresh code and full context awareness.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.6 Daily Workflow & Checklists"
anchor: "#daily-workflow-pattern"
- id: "10-016"
difficulty: "senior"
profiles: ["senior", "power"]
question: "What flag allows Claude's tools to access directories outside the current working directory?"
options:
a: "--include-dir"
b: "--add-dir"
c: "--context-dir"
d: "--load-dir"
correct: "b"
explanation: |
Use `--add-dir` to allow tool access to additional directories:
```bash
claude --add-dir ../shared ../utils
claude --add-dir packages/api
```
By default, Claude can only access files in the current working directory.
Use --add-dir to extend permissions to other directories (e.g., shared libraries in a monorepo).
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.3 Configuration Reference"
anchor: "#cli-flags-reference"
- id: "10-017"
difficulty: "power"
profiles: ["power"]
question: "When Sequential Thinking MCP seems slow or unresponsive, what should you expect?"
options:
a: "It's broken and needs restart"
b: "10-30 second responses are normal due to significant compute"
c: "Switch to a different MCP"
d: "Reduce the query complexity"
correct: "b"
explanation: |
Sequential Thinking uses significant compute - expect 10-30 second responses.
This is not an error, just be patient.
Tips for Sequential:
- Works best with specific, well-defined problems
- Good: "Debug why user authentication fails on mobile"
- Bad: "Make the app better"
The longer response time reflects deeper analysis.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.4 Troubleshooting"
anchor: "#sequential-thinking-mcp-issues"
- id: "10-018"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "What shortcut opens an external editor for composing long text input?"
options:
a: "Ctrl+E"
b: "Ctrl+G"
c: "Ctrl+O"
d: "Ctrl+L"
correct: "b"
explanation: |
`Ctrl+G` opens an external editor for composing long text.
Useful input shortcuts:
- `Ctrl+A`: Jump to beginning of line
- `Ctrl+E`: Jump to end of line
- `Ctrl+W`: Delete previous word
- `Ctrl+G`: Open external editor
- `Tab`: Autocomplete file paths
The external editor allows comfortable editing of complex prompts.
doc_reference:
file: "guide/ultimate-guide.md"
section: "10.2 Keyboard Shortcuts"
anchor: "#input--navigation"
- id: "10-019"
difficulty: "junior"
profiles: ["junior", "senior", "power"]
question: "What does the '--from-pr' flag do in Claude Code v2.1.27?"
options:
a: "Creates a new pull request"
b: "Resumes sessions linked to a GitHub PR number or URL"
c: "Fetches all PR comments into context"
d: "Closes a pull request"
correct: "b"
explanation: |
The `--from-pr` flag (v2.1.27) lets you resume Claude Code sessions linked to a specific GitHub PR. Usage: `claude --from-pr 123` or `claude --from-pr https://github.com/org/repo/pull/123`. This loads the PR context (diff, comments, checks) directly into the session.
doc_reference:
file: "guide/claude-code-releases.md"
section: "v2.1.27"
anchor: "#v2127"
- id: "10-020"
difficulty: "senior"
profiles: ["senior", "power"]
question: "What breaking change was introduced in Claude Code v2.1.19 for hook/command arguments?"
options:
a: "Arguments removed entirely"
b: "Migration from $ARGUMENTS.0 (dot syntax) to $ARGUMENTS[0] (bracket syntax)"
c: "New $PARAMS variable replaced $ARGUMENTS"
d: "Arguments now require JSON format"
correct: "b"
explanation: |
Claude Code v2.1.19 changed argument access syntax from dot notation (`$ARGUMENTS.0`) to bracket notation (`$ARGUMENTS[0]`). This breaking change affects all custom commands and hooks that reference arguments. Update your scripts to use the new bracket syntax.
doc_reference:
file: "guide/ultimate-guide.md"
section: "Breaking Changes"
anchor: "#breaking-changes"
- id: "10-021"
difficulty: "junior"
profiles: ["junior", "senior", "power", "pm"]
question: "According to the guide's 'Myths vs Reality' section, what is the truth about 'hidden Claude Code features'?"
options:
a: "Secret flags exist for power users"
b: "Hidden features require an enterprise plan"
c: "There are no hidden features - Anthropic uses progressive rollout, not secret flags"
d: "Beta flags are stored in .claude/config"
correct: "c"
explanation: |
The Myths vs Reality section debunks the "hidden features" myth. Anthropic uses progressive rollout (features gradually enabled for users) rather than secret flags or hidden configurations. All features are documented in release notes. There is no secret power-user mode.
doc_reference:
file: "guide/ultimate-guide.md"
section: "Myths vs Reality"
anchor: "#myths-vs-reality"