Skip to content

Github Copilot GPT4.1 incorrect context window #783

@bendews

Description

@bendews

In commit e5e859a Github Copilot GPT4.1 was updated to a context window of only 64k. The previous 128k context window was correct based on the API and general usage.

Models API output:

  {
    "billing": {
      "is_premium": false,
      "multiplier": 0
    },
    "capabilities": {
      "family": "gpt-4.1",
      "limits": {
        "max_context_window_tokens": 128000,
        "max_output_tokens": 16384,
        "max_prompt_tokens": 128000,
        "vision": {
          "max_prompt_image_size": 3145728,
          "max_prompt_images": 1,
          "supported_media_types": [
            "image/jpeg",
            "image/png",
            "image/webp",
            "image/gif"
          ]
        }
      },
      "object": "model_capabilities",
      "supports": {
        "parallel_tool_calls": true,
        "streaming": true,
        "structured_outputs": true,
        "tool_calls": true,
        "vision": true
      },
      "tokenizer": "o200k_base",
      "type": "chat"
    },
    "id": "gpt-4.1",
    "is_chat_default": true,
    "is_chat_fallback": true,
    "model_picker_category": "versatile",
    "model_picker_enabled": true,
    "name": "GPT-4.1",
    "object": "model",
    "policy": {
      "state": "enabled",
      "terms": "Enable access to the latest GPT-4.1 model from OpenAI. [Learn more about how GitHub Copilot serves GPT-4.1](https://docs.github.com/en/copilot/using-github-copilot/ai-models/choosing-the-right-ai-model-for-your-task#gpt-41)."
    },
    "preview": false,
    "vendor": "Azure OpenAI",
    "version": "gpt-4.1-2025-04-14"
  }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions