Skip to content

Opus 4.7 capped at 200K context instead of 1M (GitHub Copilot offers 1M, Zed does not) #54390

Description

@anilpai

Reproduction steps

  1. Start Zed with Opus 4.7 (either via built-in assistant with Anthropic key or Copilot extension).
  2. Load a coding project, interact in the assistant/chat, and let the conversation grow.
  3. Once the context reaches ~144K tokens, observe Zed asking to start a new context, while the session should support up to 1M tokens (as seen in GitHub Copilot's Opus 4.7 integration with 1M context windows).

Current vs. Expected behavior

Current behavior: Zed assistant prompts for a new context at ~144K tokens, reflecting a 200K hard cap (72% threshold trigger), instead of supporting Opus 4.7's full 1M window. This limitation is likely due to legacy token denominator logic for Anthropic models from Opus 4.6.

Expected behavior: Zed should allow the context window to reach the full 1M tokens available for Opus 4.7, just as GitHub Copilot and Claude Code CLI already support.

Zed version and system specs

Zed build: v0.215.0+ (or most recent)
OS: macOS/Linux/Windows (reproducible across environments)
Memory: N/A
Architecture: x86_64/aarch64

Attach Zed log file

Zed.log

Relevant Zed settings

settings.json
"assistant": {
  "default_model": {
    "provider": "anthropic",
    "model": "claude-opus-4-7-1m" 
  },
  "max_tokens": 1000000
}

Relevant Keymap

keymap.json

(for AI issues) Model provider details

  • Provider: Anthropic via ZedPro (or API key), Copilot extension
  • Model Name: Claude Opus 4.7
  • Mode: Assistant Panel, Copilot Bridge
  • Workaround: None ; Copilot Pro+ , Business and Enterprise tiers on VS Code and CLI already leverage the full 1M window.

Metadata

Metadata

Assignees

Labels

state:needs researchFeedback that requires further investigation

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions