Context — the current session workspace
Claude Code does not retain a complete “memory” of the project. It works with the data present in the current session window: messages, files it has read, command results, rules, memory, code fragments, and other supplied materials.
A new session is not complete amnesia: persistent instructions may be loaded again. But previous reasoning, logs, and hypotheses do not transfer automatically unless they are recorded in an accessible artifact.
| Included in context | Example |
|---|---|
| Conversation history | Prompts, clarifications, and accepted decisions |
| Files and code | Read modules, tests, and configurations |
| Tool results | Commands, logs, and search results |
| Instructions | CLAUDE.md, rules, and memory |
| Multimedia materials | Supplied fragments, screenshots, and UI context |
Why Claude may not know the obvious
- The fact, file, or log was not supplied in the current session.
- An important detail was lost among a large number of messages.
- The new request conflicts with project rules or earlier constraints.
- The assumption was phrased unclearly and has no way to be verified.
A task header for a new session
- Clearly state the goal and the observable problem.
- List the files or directories to inspect.
- State the change boundaries, prohibitions, and hypotheses.
- Carry over decisions already made and verification results.
- Define one immediate action for the new session.
## Task
- Goal: what should change
- Scope: permitted files or modules
- Non-goals: what we are not changing
- Constraints: technical and process rules
- Evidence: verified facts and short logs
- Next step: the nearest actionArtifacts that preserve context
CLAUDE.md— stable project rules;- rules — instructions for specific areas;
TASK_SPEC.md— goal, scope, constraints, and criteria;EVIDENCE_LOG.md— facts, logs, reproduction steps, and open questions;- test results and a list of files for the next step.
Summary
Response quality depends on the presence, freshness, and consistency of signals in the context. Manage it deliberately: provide the needed data, avoid unnecessary logs, and record important decisions outside the session.
Canonical lesson source · JavaRush
Open JavaRush material