pi-mono/packages
robopipi[bot] b317575fd1
fix(ai): use Azure Foundry 1.05M context window for GPT-6 models (#11781)
Azure's OpenAI models are copied from the direct `openai` provider. That
provider caps the GPT-6 family at 272K so requests stay in OpenAI's
short-context pricing tier.

The Azure provider overrides this cap through
`CONTEXT_WINDOW_OVERRIDES`, but that list only covered gpt-5.4, gpt-5.5
and gpt-5.6. As a result, `azure/gpt-6-astra`, `gpt-6-luna`,
`gpt-6-sol`, `gpt-6.1-sol` and `gpt-6.1-terra` showed a 272K context
window, and pi compacted sessions far earlier than needed. Azure Foundry
deploys these models with a 1,050,000-token context window.

This change adds the five models to the Azure override list.
OpenAI-direct is unchanged.

Testing:
- Added a test in `packages/ai/test/supports-xhigh.test.ts` that checks
each of these Azure models has a 1,050,000 context window. It fails on
all five models without the override (5 failed) and passes with it.
- After regenerating the model data, the generated Azure catalog lists
all five models at 1050000. Before the change they were at 272000.
- `npm run check` passes.

Fixes #11742

Requested by @badlogic

Co-authored-by: triagent <triagent@localhost>
2026-11-04 09:34:35 +01:00
..
agent Anthropic message threads (#11545) 2026-11-03 14:07:57 +01:00
ai fix(ai): use Azure Foundry 1.05M context window for GPT-6 models (#11781) 2026-11-04 09:34:35 +01:00
chord docs(chord): slice 9 spec, telemetry with spans across hosts 2026-11-04 07:46:53 +00:00
codemode Add [Unreleased] section for next cycle 2026-11-02 11:38:21 +01:00
coding-agent fix(coding-agent): keep ctrl+v as a paste key on Windows and WSL (#11780) 2026-11-04 09:33:31 +01:00
durable feat(chord): Chord v2 is the package's root 2026-11-02 22:36:55 +00:00
env fix(env): kill what a process program left running when it exits 2026-11-03 14:17:21 +01:00
evals Release v1.5.0 2026-11-02 11:38:21 +01:00
mcp fix(mcp): recognize CR-only line endings in Streamable HTTP SSE (#11775) 2026-11-04 09:18:01 +01:00
schema fix(schema): apply a relative root $id only once when resolving references (#11726) 2026-11-03 23:14:11 +01:00
telemetry Add [Unreleased] section for next cycle 2026-11-02 11:38:21 +01:00
tui fix(tui): detect Alacritty for OSC 8 hyperlinks without TERM_PROGRAM (#11777) 2026-11-04 09:26:27 +01:00