Claude Code lets you pick the auto mode classifier's model

Claude Code 2.1.302 (October 16, 2026) adds CLAUDE_CODE_AUTO_MODE_MODEL, an environment variable that chooses the model the client-side auto mode classifier uses. The release before it, 2.1.301 (October 15), added the telemetry to see what that classifier decided.

The model knob

The changelog entry reads:

Added CLAUDE_CODE_AUTO_MODE_MODEL to choose the model the client-side auto mode classifier uses; it does not change the model for server-side auto mode

Two things follow from that sentence.

Without the variable, the permission modes docs say the classifier runs on Claude Sonnet 5 rather than on your /model selection. A classifier model that Anthropic configures server-side takes precedence over that default. If your session model is Sonnet 4.6, or availableModels excludes Sonnet 5, the classifier falls back to the session's model, or to an Opus model when the session runs on a Fable model.

The permission modes page did not yet mention the new variable when this was written. The changelog line is the only source for its behavior, including which values it accepts, so confirm accepted values on your install before relying on one.

Why you would set it

On the Claude API, Bedrock, Vertex, and Foundry, the docs say classifier calls count toward your token usage. Each check sends part of the transcript plus the pending action. The model that does the checking is now a cost and latency choice you can make per environment, for example in a CI image that runs claude -p with auto mode.

Telling classifier blocks from rule blocks

Two earlier changes make the classifier's decisions visible in OpenTelemetry tool_decision events.

If you export these events and set that limit, check that the attributes you depend on survive on 2.1.302 or later.

Related fix in the same release

2.1.302 also improved server-side auto mode. A conversation too long for the safety check is now compacted, instead of every checked tool call being denied.

See the Claude Code sheet for the current environment variable and settings surface.