# MAI Code 2

> MAI Code 2 is a proprietary language model from Microsoft, released on 17 Nov 2026. It accepts text and images and generates text, with a 1.1M-token context window and up to 128K output tokens per response.

Source page: https://www.aimodel.directory/models/mai-code-2
Last verified: 19 Nov 2026

## Specifications

- **Developer:** Microsoft
- **Release date:** 17 Nov 2026 (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Status:** Generally available (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Weights:** Proprietary (API only) (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Context window:** 1.1M (1,050,000 tokens) (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Max output:** 128K tokens (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Input:** Text and images (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Output:** Text (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Reasoning mode:** Yes (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Tool calling:** Yes (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)
- **Structured output:** Yes (source: models.dev, https://github.com/sst/models.dev/blob/dev/providers/github-copilot/models/mai-code-2.toml)

## API pricing (USD per 1M tokens)

| Provider | Input | Output | Cached input | Context |
|---|---|---|---|---|

## FAQ

### What is the context window of MAI Code 2?

MAI Code 2 has a context window of 1,050,000 tokens (1.1M) and can generate up to 128,000 tokens in a single response, according to models.dev.

### Is MAI Code 2 open source?

No. MAI Code 2 is a proprietary model; Microsoft has not released its weights.

### When was MAI Code 2 released?

Microsoft released MAI Code 2 on 17 Nov 2026, according to models.dev.

---
Data licensed CC BY 4.0. Cite as: AI Model Directory, "MAI Code 2", https://www.aimodel.directory/models/mai-code-2