用語集

CCA-F 試験の重要な用語。レッスンや学習ガイドから相互リンクされています。

.claude/rules/
A directory of scoped rule files (with YAML frontmatter and glob matching) that load only when matching files are in context. Per-path rules keep the prompt small while still steering behavior for the relevant code.
関連項目: claude md, path import, hooks
@path import
Syntax inside `CLAUDE.md` (e.g. `@docs/style-guide.md`) that pulls another file’s contents into context instead of pasting them inline. It keeps memory files small and lets shared docs stay single-sourced.
/compact
A Claude Code command that summarizes the conversation so far, shrinking the working context while preserving key decisions. Use it during long sessions to keep the context window focused before it fills up.
/memory
A Claude Code command for viewing and editing the loaded memory files (`CLAUDE.md` at each scope). It lets you inspect and curate the persistent instructions Claude carries into every turn.
関連項目: claude md, compact, path import
AgentDefinition
A declarative specification of a subagent — its name, system prompt/role, the tools it may use, and (optionally) model. Defining agents as configuration rather than ad-hoc code makes capabilities reviewable, reusable, and scoped to least privilege.
Agentic loop
The repeating cycle in which Claude reasons, emits a `tool_use`, receives a `tool_result`, and continues until `stop_reason` is `end_turn`. This loop — not a single call — is what turns the model into an agent that can act on the world.
Bash (tool)
A built-in Claude Code tool that runs shell commands (tests, builds, git). Because it can be destructive, it is a prime candidate for scoped permissions (e.g. `Bash(pnpm test:*)`) and hooks.
Batches for review
Using the Message Batches API to run large-scale, non-interactive review or evaluation jobs at the 50% batch discount. It suits offline grading, regression checks, or scoring many items where a 24-hour turnaround is acceptable.
Chain-of-thought
Prompting the model to reason step by step before answering, improving accuracy on multi-step problems. The reasoning can be requested in a scratchpad or visible plan; for code, ask for a brief plan before the diff.
CLAUDE.md
A Markdown memory file Claude Code auto-loads to learn project conventions, commands, and constraints. Files merge by precedence — enterprise/user (`~/.claude/CLAUDE.md`) then project (`./CLAUDE.md`) then nested directories — so versioned rules persist and are reviewable.
Context window
The maximum number of tokens (system prompt + conversation + tool results + the response) the model can attend to at once. Exceeding it causes truncation or errors, so managing what occupies the window is a core architecture concern.
custom_id
A caller-assigned identifier (1–64 chars, alphanumeric/hyphen/underscore) attached to each request in a Message Batch. Because batch results return in arbitrary order, the `custom_id` is how you map each result back to its originating request.
関連項目: message batches api
Edit (tool)
A built-in Claude Code tool that applies a precise string replacement to a file you have already read. It enables surgical, reviewable changes rather than rewriting whole files.
関連項目: read tool, bash tool, glob
end_turn
The `stop_reason` value indicating Claude completed its reply naturally and is handing control back. In an agentic loop, `end_turn` is the normal signal to stop iterating and surface the final answer.
関連項目: stop reason, agentic loop
Error propagation
The risk that an early mistake (a bad tool result, a wrong assumption) flows downstream and corrupts later steps in an agent loop. Surfacing structured errors, validating outputs, and escalating uncertainty all limit how far errors spread.
Explicit acceptance criteria
Stating concrete, checkable success conditions in the prompt (what "done" means) rather than relying on the model to infer intent. Sharp criteria reduce ambiguity and make outputs easier to validate automatically.
Explore subagent
A read-only subagent used for read-heavy codebase investigation, returning a concise summary so the main session’s context stays small. It embodies subagent isolation applied to exploration.
Few-shot prompting
Including a small number (typically 2–4) of input/output examples in the prompt to demonstrate the desired format and behavior. Examples drawn from real, in-style data steer output far more reliably than abstract instructions alone.
fork_session
Branching a session by copying its history up to a point into a new session with its own id, leaving the original untouched. Like `git branch`, it lets you explore alternative paths in parallel without losing prior work (CLI: `claude --resume <id> --fork-session`).
Glob (tool)
A built-in Claude Code tool that lists files matching a pattern (e.g. `src/**/*.ts`). It is the fast first step for locating files by name before reading or editing them.
Grep (tool)
A built-in Claude Code tool that searches file contents by regex, returning matching files or lines. It locates code by *what it does* rather than its filename, complementing Glob.
Hallucination
Confident generation of content that is unsupported or false — invented facts, APIs, or citations. Mitigations include grounding with retrieved context, provenance annotations, schema/validation checks, and asking the model to admit uncertainty.
Headless CI/CD
Using headless Claude Code inside pipelines to automate tasks like fixing tests or opening PRs, branching on JSON output (including `total_cost_usd`) and keeping the agent on a tight turn budget. The merge gate stays the same as for humans: the branch must pass CI.
Headless mode
Running Claude Code non-interactively via `claude -p "<task>"`, typically with `--output-format json` for a parseable result and `--allowedTools` to pre-approve tools. It is the entry point for CI/CD and scripted automation.
HITL escalation
A policy that routes a task to a human when the agent is uncertain, hits a permission boundary, or detects a high-risk action. Well-designed escalation captures the hard cases without forcing humans to review routine ones.
Hooks
Deterministic, event-driven callbacks (e.g. before/after a tool runs, or on session events) that execute code to enforce guarantees the model should not be trusted to self-impose. Use hooks for must-always rules like formatting, secret-blocking, or audit logging.
Hooks vs prompts
The design tradeoff between enforcing behavior with deterministic hooks versus requesting it in the prompt. Prefer hooks for non-negotiable, mechanically verifiable rules and prompts for judgment-based guidance the model should weigh.
関連項目: hooks, model vs hardcoded
Hub-and-spoke
A multi-agent topology where one orchestrator (the hub) delegates to specialized subagents (the spokes) that report back, with no spoke-to-spoke communication. It is the canonical pattern for parallelizable, decomposable work and contrasts with brittle deep agent chains.
Human-in-the-loop (HITL)
Inserting human approval or judgment at high-stakes or ambiguous points in an agent workflow. HITL gates (e.g. confirm before a destructive action, or escalate low-confidence cases) bound risk where full automation is unsafe.
Incremental investigation
A debugging workflow that narrows scope step by step — Glob/Grep to locate, Read to confirm, then a targeted Edit — instead of loading the whole codebase at once. It keeps context lean and reasoning focused.
isError / is_error
A boolean on a `tool_result` block that marks the tool execution as failed. It lets Claude distinguish a tool error from a successful-but-empty result and decide whether to retry, escalate, or adjust its plan.
JSON Schema
A vocabulary for describing the structure, types, and constraints of JSON data. In Claude, tool `input_schema` is JSON Schema; a well-specified schema is the contract that makes tool calls and structured output reliable.
Lost in the middle
The tendency of long-context models to attend best to information at the beginning and end of the context and overlook content buried in the middle. It motivates placing critical instructions and data near the edges of the prompt.
MCP configuration
Declaring which MCP servers a client connects to and how (command, args/url, transport, env/secrets), typically in a config file or `.mcp.json`. Scoping servers and their credentials carefully is part of least-privilege tool design.
MCP resource
One of the three MCP primitives (alongside tools and prompts): read-only, addressable context such as a file, database row, or document that a server exposes for the model to read. Resources supply data; tools perform actions.
関連項目: mcp, mcp transport, tool use
MCP transport
The channel carrying JSON-RPC messages between MCP client and server. Options are **stdio** (server runs as a local subprocess over stdin/stdout), **Streamable HTTP** (the current network standard), and **SSE** (the legacy HTTP transport, now deprecated).
Message Batches API
An asynchronous endpoint for submitting many Messages requests at once for processing within a 24-hour window at a 50% token discount. Each request carries a unique `custom_id`, and results are retrieved later — ideal for high-volume, non-interactive work like evaluation or bulk extraction.
Messages API
The primary Claude endpoint (`POST /v1/messages`) for sending a list of alternating `user`/`assistant` turns and receiving a model response. It returns structured content blocks (text, `tool_use`) plus metadata such as `stop_reason` and token usage.
Model Context Protocol (MCP)
An open, JSON-RPC-based protocol that standardizes how AI clients connect to external servers exposing tools, resources, and prompts. MCP decouples capability providers from clients, so one server (e.g. for a database or API) works across any MCP-aware host.
Model vs hardcoded logic
The decision of whether to let the model reason about a step or to implement it as fixed code/control flow. Hardcode the deterministic, high-stakes, or cheaply-specified parts; reserve the model for ambiguous, judgment-heavy decisions.
Multi-pass review
Improving output by running additional review passes — the model (or a separate reviewer agent) critiques and revises a first draft against criteria. It trades extra tokens/latency for higher quality on important deliverables.
Parallel execution
Running independent subtasks concurrently — e.g. fanning out several subagents or issuing multiple tool calls at once — to cut wall-clock latency. It only applies when subtasks have no ordering dependency; sequential work needs prompt chaining instead.
Permission model
Claude Code’s allow/ask/deny controls governing which tools can run with or without confirmation. Pre-approve safe, idempotent tools and gate destructive ones; in automation, pass `--allowedTools` explicitly so runs complete without prompts.
Plan mode
A Claude Code mode where the model explores and proposes a change set **without writing files or running mutating tools**, pending approval. It catches wrong-file or wrong-architecture mistakes before they cost a round-trip and is recommended for any non-trivial change.
Plan vs direct execution
The choice between proposing a plan first (safe, reviewable, better for multi-file or risky work) versus executing immediately (fast, fine for trivial edits). Matching mode to task risk is a Domain 3 design decision.
Progressive summarization
Periodically compressing accumulated conversation or work into a running summary so the context window stays small while key facts survive. It is the core technique behind `/compact` and long-running agent memory.
Prompt caching
A feature that caches stable prefix content (long system prompts, tool definitions, documents) via `cache_control` so repeated requests skip re-processing it. Cache reads cost a fraction of normal input tokens, cutting latency and price for prompts with a large fixed prefix.
Prompt chaining
Decomposing a complex task into a sequence of steps where each step’s output feeds the next. Chaining improves reliability for ordered, dependent work; use it when later steps genuinely require earlier results, otherwise prefer parallel fan-out.
Provenance annotations
Tagging facts in context (or in output) with their source so the model and reviewers can trace claims back to evidence. Provenance supports grounding, reduces hallucination, and makes outputs auditable.
Read (tool)
A built-in Claude Code tool that reads a file’s contents (optionally a line range) into context. Reading before editing is required so changes are grounded in the actual current text.
関連項目: edit tool, glob, grep, bash tool
Schema design
Crafting a JSON Schema with clear field names, descriptions, required fields, and enums so the model produces valid, unambiguous output. Good schema design — especially descriptive field docs — is one of the strongest levers for structured-output quality.
Scratchpad
A dedicated space (often a delimited section or hidden reasoning) where the model works through intermediate steps before producing a final answer. Scratchpads externalize chain-of-thought and keep reasoning separable from the deliverable.
Session
A persisted conversation thread (history, state, and context) that an agent runtime can resume later. Sessions let long-running or interrupted work continue without rebuilding context from scratch.
Session management
The practice of creating, persisting, resuming, and forking sessions to control an agent’s memory and continuity over time. Good session hygiene keeps context relevant and recoverable across long or multi-stage tasks.
Skill
A packaged, model-invoked capability — a folder with a `SKILL.md` (name + description) plus optional scripts and resources — that Claude loads on demand when its description matches the task. Skills extend behavior with reusable, progressively-disclosed expertise.
関連項目: slash command, claude md, mcp
Slash command
A reusable, parameterizable prompt template invoked with `/name`, defined as a Markdown file under `.claude/commands/`. Slash commands turn repeated workflows (e.g. `/review`, `/release`) into versioned, shareable shortcuts.
関連項目: claude md, skill, plan mode
stdio transport
An MCP transport where the client launches the server as a local subprocess and exchanges newline-delimited JSON-RPC over stdin/stdout. Best for local, single-user tools; it avoids network setup but does not serve remote clients.
stop_reason
A field on every Messages API response stating why generation stopped. Core values are `end_turn` (finished naturally), `tool_use` (Claude wants you to run a tool), `max_tokens` (hit the output cap), and `stop_sequence` (matched a custom stop string); `pause_turn` can appear with long-running server tools.
Stratified sampling
Selecting context (or evaluation items) so each meaningful subgroup is represented, rather than taking an arbitrary or front-loaded slice. In context engineering it ensures diverse, representative material fits within the token budget.
Streamable HTTP transport
The current recommended MCP network transport: the server is an independent process handling many clients over HTTP POST/GET, optionally streaming responses with SSE. It supersedes the older standalone SSE (HTTP+SSE) transport.
関連項目: mcp transport, mcp stdio, mcp
Streaming
Receiving a Messages API response incrementally as server-sent events (set `stream: true`) instead of one final payload. Streaming lowers perceived latency for interactive UIs and lets clients render tokens as they arrive.
Structured errors
Returning tool failures as machine-readable, descriptive payloads (with `is_error: true` and a clear message) instead of opaque strings or silent failures. Structured errors let Claude diagnose the cause and self-correct within the agentic loop.
Structured output
Output produced in a machine-readable schema (usually JSON), commonly obtained by forcing a schema-shaped tool with `tool_choice`. It lets downstream systems consume model results programmatically instead of parsing prose.
Subagent
A separate agent instance, with its own context window and tool set, that an orchestrator delegates a focused task to. Subagents isolate context (keeping the main thread clean) and enable parallelism, but cannot see each other directly.
Subagent isolation
The property that each subagent runs in a fresh, separate context window and returns only a summary to its caller. Isolation prevents context pollution and lets noisy, read-heavy work happen without bloating the orchestrator’s window.
Token budget
The deliberate allocation of the context window across system prompt, instructions, retrieved context, history, and response. Budgeting forces tradeoffs — what to keep, summarize, or drop — so the most relevant content stays in scope.
Tool descriptions
The natural-language `description` and per-parameter docs on a tool definition that tell the model when and how to use it. Clear, specific descriptions are the primary driver of correct tool selection and argument filling.
Tool scoping
Granting an agent or subagent only the minimal tool set it needs for its job (least privilege). Tight scoping reduces error surface, prevents unintended destructive actions, and keeps the model focused on relevant capabilities.
tool_choice
A request parameter that controls tool invocation: `auto` (model decides), `any` (must call some tool), `tool` (must call a named tool), or `none` (forbid tools). Forcing a tool is the standard way to coerce structured output via a single schema-shaped tool.
tool_result
A content block sent back in a `user` turn that returns the output of a `tool_use` request, keyed by its `tool_use_id`. Setting `is_error: true` signals the tool failed so Claude can recover or retry.
tool_use
A content block in which Claude requests that a named tool be invoked with a JSON `input`. When present, `stop_reason` is `tool_use`; the application executes the tool and returns the result as a `tool_result` block in the next user turn.
Validation-retry loop
Validating model output against a schema or checks (linter, tests), and feeding failures back so the model self-corrects. Distinguish syntax errors (always safe to retry) from semantic errors (may need a sharper criterion or a human).