Skip to content

Claude 4.6 appears capped at 200k input context while direct Anthropic supports 1M #512

@ShivamB25

Description

@ShivamB25

What's happening

Claude 4.6 through opencode-antigravity-auth behaves like a ~200k input lane. Once input history gets near that point, sessions compact or fail with prompt-too-long style errors.

The same model family on direct Anthropic can go beyond 200k when long-context beta is enabled (context-1m-2025-08-07) and the account is eligible.

Why this is confusing

From a user perspective, the model name is the same, so people expect similar context behavior. In practice, effective limits differ by provider path.

Requested changes

  1. Confirm whether the antigravity path can expose/pass the equivalent long-context capability for supported Claude models.
  2. If it cannot, make the 200k cap explicit in provider model metadata and UI text.
  3. Show provider-path-specific context limits in model selection so users can choose intentionally.

Repro (minimal)

  1. Use Claude 4.6 via antigravity-auth.
  2. Keep growing input context past ~200k.
  3. Observe compaction/overflow behavior.
  4. Compare with direct Anthropic + long-context beta enabled.

Current workaround that works

Until this is fixed in provider behavior/docs, this split setup is reliable:

  1. Keep google/antigravity-* as the 200k lane.
  2. Use anthropic/* for long-context runs.
  3. Inject context-1m-2025-08-07 only for direct Anthropic requests via plugin hooks.
  4. For direct Anthropic model overrides, set both limit.context=1048576 and limit.input=1048576.

High-level plugin logic:

  • If input.model.providerID !== "anthropic", do nothing.
  • For Claude 4.x long-context-capable models, add anthropicBeta plus anthropic-beta header value context-1m-2025-08-07.

This keeps antigravity behavior unchanged while enabling a 1M path for direct Anthropic where entitlement allows it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/modelsModel access, Claude/Gemini specificduplicateThis issue or pull request already existsquestionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions