Claude Code v2.1.334 compacts 1M-context sessions near 400K tokens

1 day ago

Claude Code's auto-compact now starts near 400K tokens on most current 1M-context models, with a new row in /config to change it. Also: a search box in /model, local /code-review following REVIEW.md files in subfolders, worktree and Code Mode fixes, requests that now get resent instead of failing, and Try again, Mermaid diagrams and a session diff in VS Code. Covers Claude Code v2.1.334.

Ask about this presentation

Chapters

Show transcript
  1. Claude Code's auto-compact now starts near 400K tokens on most current 1M token models, print mode and SDK runs included. It's still rolling out, and a new row in /config shows that window and lets you change it.

    Slide text
    Claude Code

    Claude Code now compacts 1M-context sessions near 400K tokens

    https://github.com/anthropics/claude-code/releases/tag/v2.1.334

    Applies to
    most current 1M models, -p and SDK runs too
    Rolling out
    on now with third-party providers or telemetry off
    Change it
    a new Auto-compact window row in /config
    CHANGELOG.md, Dec 1 · anthropics/claude-code
  2. The /model picker now opens with a search box once the list passes twenty-five models. It matches names and model IDs. Press the down arrow first to get the letter and number shortcuts back.

    Slide text
    Claude Code

    > /model gets a search box once the list passes 25 models

    Matches
    model names and model IDs
    Shortcuts
    press ↓ first to use s and the number keys
    Issues
    #99239 · #107237
    CHANGELOG.md, Dec 1 · anthropics/claude-code
  3. Review rules can now live next to the code they cover. Local runs of /code-review follow each REVIEW.md file in the folders above a committed change, so one part of a repository can carry its own rules.

    Slide text
    Claude Code

    >Local code reviews follow REVIEW.md files in the folders above each change

    Reads
    REVIEW.md in folders above a committed change
    Applies to
    local runs of /code-review
    CHANGELOG.md, Dec 1 · anthropics/claude-code
  4. Resuming an unchanged worktree could lose an unpushed commit that only its branch held, and that's fixed. New worktrees also start from the right branch after Claude moves to another repository, and /cd after a worktree loads the new folder's CLAUDE.md.

    Slide text
    Claude Code

    >Worktrees start from the right branch and keep unpushed commits

    Resuming a worktree
    keeps an unpushed commit that only its branch had
    New worktrees
    start from the right branch after Claude moves to another repository
    /cd after a worktree
    loads the new folder’s CLAUDE.md
    CHANGELOG.md, Dec 1 · anthropics/claude-code
  5. In Code Mode, subagents had started failing again with an agent stalled error when a script ran past ten minutes. That's fixed, and a script's tool calls stop counting toward context size, which had set off early compaction.

    Slide text
    Claude Code

    >Code Mode subagents stop stalling when a script runs past 10 minutes

    Long scripts
    subagents keep their command instead of failing with “Agent stalled”
    Context size
    a script’s tool calls stop counting toward it, so compaction comes later
    After /compact
    fewer scripts overwrite a file you edited outside Claude
    CHANGELOG.md, Dec 1 · anthropics/claude-code
  6. Turning thinking off used to break requests to models that can't turn it off. Claude Code now resends them without that setting, so the model may think. Sessions behind gateways that rewrite errors stop getting stuck too.

    Slide text
    Claude Code

    >Requests that used to fail now get resent

    Thinking turned off
    resent without that setting, so the model may think
    Gateways that rewrite errors
    an unknown 400 or 422 is resent instead of sticking
    A tool input that isn’t an object
    stops breaking every request after it
    CHANGELOG.md, Dec 1 · anthropics/claude-code
  7. In the VS Code extension, the new look puts a Try again button under failed replies and draws Mermaid diagrams. A Review Session Changes command opens every file Claude edited in one diff tab.

    Slide text
    Claude Code

    >VS Code adds Try again, Mermaid diagrams and a one-tab session diff

    Try again
    under replies that failed on a server error, overload or lost connection
    Mermaid
    diagrams drawn in Claude’s replies, with Show source
    Review Session Changes
    opens every file Claude edited in one diff tab
    CHANGELOG.md, Dec 1, [VSCode] entries · anthropics/claude-code
  8. The Claude Code changelog lists the rest of this release, including Claude Code on the web, which can now run a scheduled task once or on a cron schedule, plus Remote Control and Claude Tag.

    Slide text
    Claude Code

    Every change is in the changelog

    https://github.com/anthropics/claude-code/blob/main/CHANGELOG.md

    CHANGELOG.md in anthropics/claude-code

    Waiting on the 400K window? It’s on now with third-party providers or telemetry off.

    CHANGELOG.md, Dec 1 · anthropics/claude-code

What happened in AI today, in your inbox

One short email each evening. Read it and you’re caught up.

Built with ❤️ in New York