All Topics

Context & Reasoning

Manage what goes into the context window and get maximum reasoning out of it — the engineers who master both stop hitting walls.

0/11
The Token Budget — What Costs What

Your context window is a finite resource that starts draining before you type a word. Understanding what loads at startup, what accumulates per turn, and how the 1M window changes the math is the foundation of every context engineering decision.

intermediate9 min
.claudeignore — Cutting Context Overhead at the Source

.claudeignore stops files from auto-loading into context during Claude's tool searches. One well-tuned file can cut your working context by 30–40% on the first search.

intermediate6 min
What Compaction Preserves and What It Destroys

Compaction is a one-way door. Understanding exactly what survives — and what doesn't — determines whether you lose critical context or walk away clean.

intermediate7 min
Compact, Branch, or Clear — A Decision Framework

Three commands for managing a degrading session — each with a different cost, a different loss profile, and a different use case. Choosing the wrong one compounds the problem.

intermediate7 min
Subagents as Context Isolation

The primary reason to use subagents isn't parallelism — it's keeping investigation noise out of your main context window. A subagent that reads 20 files returns a 200-token summary instead of 20,000 tokens inline.

intermediate7 min
Side Channels — /btw, /copy, and Context-Zero Queries

Not every question needs to live in the main conversation thread. Side channels let you get answers, extract results, and inject background context without polluting the session that matters.

intermediate5 min
Prompt Caching TTL Controls

Claude Code's prompt cache keeps the stable portion of your context cheap to re-send. Two environment variables control the TTL — and choosing the wrong one can cost you significantly on long sessions.

intermediate6 min
Conversation Hygiene for Long Sessions

Long sessions degrade. The file path assumptions get fuzzy, earlier instructions fade, and Claude starts contradicting decisions it made an hour ago. These practices prevent that — or help you recover when it happens anyway.

intermediate7 min
ultrathink — Allocating Extended Reasoning Budget

Extended thinking gives Claude a scratchpad to reason before responding. The thinking budget ladder goes from 'think' to 'ultrathink' — and knowing where on that ladder your problem lives is the difference between a great answer and an expensive one.

advanced8 min
Extended Reasoning in Practice — Real Use Cases

Extended reasoning is most valuable on a specific class of problems. Understanding which ones — and which ones don't benefit — prevents expensive waste and unlocks the cases where ultrathink genuinely changes the outcome.

advanced8 min
Effort Levels — The Reasoning Slider

Effort levels are a session-wide reasoning depth control — separate from ultrathink's per-prompt override. Opus 4.7 introduced xhigh as the new default, sitting between high and max. Understanding the five levels prevents both under-spending on hard problems and over-spending on easy ones.

advanced8 min