converse-mcp-server 4.2.1 → 4.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/.env.example CHANGED
@@ -91,11 +91,11 @@ TYPESAFE_API_KEY=your_typesafe_api_key_here
91
91
  # The model a bare provider name ("codex", "openai", ...) and "auto" use.
92
92
  # Each must be a model ID or alias from that provider's catalog; startup fails
93
93
  # with "did you mean" suggestions otherwise. Per request, use "provider:model".
94
- # CODEX_DEFAULT_MODEL=gpt-6-astra # gpt-6-sol, gpt-6-luna, gpt-6-astra, gpt-5.6-sol, gpt-5.6-terra, gpt-5.6-luna, gpt-5.5, gpt-5.3-codex-spark (CODEX_MODEL is the legacy name)
94
+ # CODEX_DEFAULT_MODEL=gpt-6-astra # gpt-6.1-sol, gpt-6-sol, gpt-6-luna, gpt-6-astra, gpt-5.6-sol, gpt-5.6-terra, gpt-5.6-luna, gpt-5.5, gpt-5.3-codex-spark (CODEX_MODEL is the legacy name)
95
95
  # CLAUDE_DEFAULT_MODEL=claude-opus-5-5
96
96
  # AGY_DEFAULT_MODEL=gemini-3.8-flash # Antigravity CLI: gemini-3.8-flash, gemini-3.1-pro-preview
97
- # COPILOT_DEFAULT_MODEL=gpt-6-sol # COPILOT_MODEL is the legacy name
98
- # OPENAI_DEFAULT_MODEL=gpt-6-sol
97
+ # COPILOT_DEFAULT_MODEL=gpt-6.1-sol # COPILOT_MODEL is the legacy name
98
+ # OPENAI_DEFAULT_MODEL=gpt-6.1-sol
99
99
  # GOOGLE_DEFAULT_MODEL=gemini-3.1-pro-preview
100
100
  # XAI_DEFAULT_MODEL=grok-4.5
101
101
  # ANTHROPIC_DEFAULT_MODEL=claude-opus-5-5
package/README.md CHANGED
@@ -230,7 +230,8 @@ SUMMARIZATION_MODEL=gpt-5-nano # Default: gpt-5-nano
230
230
 
231
231
  ### OpenAI Models
232
232
 
233
- - **gpt-6-sol** (default; aliases: `gpt-6`, `gpt-5`, `sol`): Default GPT-6 (1M context, 128K output) - Complex coding and agentic workflows; effort `none`–`max`
233
+ - **gpt-6.1-sol** (default; aliases: `gpt-6`, `gpt-6.1`, `gpt-5`, `sol`): GPT-6.1 Sol (1M context, 128K output) - Near-Astra coding, computer use, and professional work at a fifth of the Astra price; effort `low`–`max`
234
+ - **gpt-6-sol**: Previous GPT-6 Sol (1M context, 128K output), reachable by versioned name only; effort `none`–`max`
234
235
  - **gpt-6-luna** (alias: `luna`): Most efficient GPT-6 (1M context, 128K output) - Focused, high-volume tasks; effort `none`–`max`
235
236
  - **gpt-6-astra** (alias: `astra`): Frontier GPT-6 flagship (1M context, 128K output) - Hardest end-to-end work; effort `low`–`max` (EXPENSIVE: 5x Sol)
236
237
  - **gpt-5.6-sol** (alias: `gpt-5.6`): Previous flagship GPT-5.6 (1M context, 128K output)
@@ -274,7 +275,8 @@ SUMMARIZATION_MODEL=gpt-5-nano # Default: gpt-5-nano
274
275
  - **claude-opus-5** (alias: `opus-5`): Previous Opus generation (1M context, 128K output)
275
276
  - **claude-opus-4-8** / **claude-opus-4-7** / **claude-opus-4-6**: Earlier Opus generations with adaptive thinking (200K context, 1M via beta, 128K output)
276
277
  - **claude-opus-4-5** / **claude-opus-4-1**: Legacy Opus models with extended thinking (64K / 32K output)
277
- - **claude-sonnet-4-6** (alias: `sonnet`): Best combination of speed and intelligence with adaptive thinking (64K output)
278
+ - **claude-sonnet-5-5** (aliases: `sonnet`, `sonnet-5.5`): Current Sonnet with adaptive thinking and effort (1M context, 128K output)
279
+ - **claude-sonnet-4-6** (alias: `sonnet-4.6`): Previous Sonnet generation with adaptive thinking (64K output)
278
280
  - **claude-haiku-4-5** (alias: `haiku`): Fast and intelligent for simple queries (64K output)
279
281
 
280
282
  ### Mistral Models
@@ -306,9 +308,9 @@ Any other model works via its full `provider/model` slug or the `openrouter:` na
306
308
 
307
309
  OpenAI Codex agentic coding assistant. `codex` uses its default model (GPT-6 Astra, or `CODEX_DEFAULT_MODEL`); `codex:<model>` picks one (e.g. `codex:luna`, `codex:astra`, `codex:gpt-5.6-terra`):
308
310
 
309
- - **gpt-6-sol** (default; aliases: `sol`, `gpt-6`), **gpt-6-luna** (`luna`), **gpt-6-astra** (`astra`)
311
+ - **gpt-6.1-sol** (`sol`, `gpt-6`), **gpt-6-sol**, **gpt-6-luna** (`luna`), **gpt-6-astra** (`astra`)
310
312
  - **gpt-5.6-sol** (`gpt-5.6`), **gpt-5.6-terra** (`terra`), **gpt-5.6-luna**, **gpt-5.5**, **gpt-5.3-codex-spark** (`spark`)
311
- - `reasoning_effort` maps onto the tiers the chosen backend accepts (Sol/Luna: `none` through `max`; GPT-6 Astra: `low` through `max`, no `none`)
313
+ - `reasoning_effort` maps onto the tiers the chosen backend accepts (versioned GPT-6 Sol, Luna, and GPT-5.6: `none` through `max`; GPT-6.1 Sol and GPT-6 Astra: `low` through `max`, no `none`)
312
314
  - Thread-based sessions with persistent context
313
315
  - Direct filesystem access from working directory
314
316
  - Typical response time: 6-20 seconds (longer for complex tasks)
@@ -321,15 +323,16 @@ Claude via the Claude Agent SDK. `claude` uses its default model (Opus 5.5, or `
321
323
 
322
324
  - **claude-opus-5-5** (default; aliases: `opus`, `claude-opus`, `opus-5.5`), **claude-opus-5** (`opus-5`)
323
325
  - **claude-fable-5-1** (aliases: `fable`, `claude-fable`, `fable-5.1`), **claude-fable-5** (`fable-5`)
326
+ - **claude-sonnet-5-5** (aliases: `sonnet`, `claude-sonnet`, `sonnet-5.5`)
324
327
  - Uses Claude Code CLI authentication (`claude login`) - no API key needed
325
328
  - Direct filesystem access from working directory
326
329
 
327
330
  ### GitHub Copilot SDK Models
328
331
 
329
- Reach these only with the `copilot:` namespace (e.g. `copilot:gpt-6-sol`) — Copilot never serves bare model names. `copilot` alone uses GPT-6 Sol, or `COPILOT_DEFAULT_MODEL`. Uses your GitHub Copilot subscription (`gh auth login`) - no API key needed:
332
+ Reach these only with the `copilot:` namespace (e.g. `copilot:gpt-6.1-sol`) — Copilot never serves bare model names. `copilot` alone uses GPT-6.1 Sol, or `COPILOT_DEFAULT_MODEL`. Uses your GitHub Copilot subscription (`gh auth login`) - no API key needed:
330
333
 
331
- - **OpenAI**: `gpt-6-sol` (aliases: `gpt-6`, `gpt-5`, `sol`), `gpt-6-luna` (alias: `luna`), `gpt-5.6-sol` (alias: `gpt-5.6`), `gpt-5.6-terra`, `gpt-5.6-luna` (all support `reasoning_effort`)
332
- - **Anthropic**: `claude-opus-5.5` (aliases: `opus`, `claude`), `claude-fable-5` (alias: `fable`), `claude-sonnet-5` (alias: `sonnet`), `claude-opus-5`, `claude-opus-4.8`
334
+ - **OpenAI**: `gpt-6.1-sol` (aliases: `gpt-6`, `gpt-6.1`, `gpt-5`, `sol`), `gpt-6-sol`, `gpt-6-luna` (alias: `luna`), `gpt-5.6-sol` (alias: `gpt-5.6`), `gpt-5.6-terra`, `gpt-5.6-luna` (all support `reasoning_effort`)
335
+ - **Anthropic**: `claude-opus-5.5` (aliases: `opus`, `claude`), `claude-fable-5` (alias: `fable`), `claude-sonnet-5.5` (alias: `sonnet`), `claude-sonnet-5`, `claude-opus-5`, `claude-opus-4.8`
333
336
  - **Google**: `gemini-3.1-pro-preview` (aliases: `gemini`, `gemini-3.1-pro`), `gemini-3.8-flash` (aliases: `gemini-3.8`, `flash-3.8`), `gemini-3.5-flash` (alias: `gemini-flash`)
334
337
 
335
338
  ## 📚 Help & Documentation
@@ -391,8 +394,8 @@ CODEX_APPROVAL_POLICY=never # never (default), untrusted, on-fa
391
394
  CODEX_DEFAULT_MODEL=gpt-6-astra # CODEX_MODEL still works as a fallback
392
395
  CLAUDE_DEFAULT_MODEL=claude-opus-5-5
393
396
  AGY_DEFAULT_MODEL=gemini-3.8-flash # Antigravity CLI (gemini)
394
- COPILOT_DEFAULT_MODEL=gpt-6-sol # COPILOT_MODEL still works as a fallback
395
- OPENAI_DEFAULT_MODEL=gpt-6-sol
397
+ COPILOT_DEFAULT_MODEL=gpt-6.1-sol # COPILOT_MODEL still works as a fallback
398
+ OPENAI_DEFAULT_MODEL=gpt-6.1-sol
396
399
  GOOGLE_DEFAULT_MODEL=gemini-3.1-pro-preview
397
400
  XAI_DEFAULT_MODEL=grok-4.5
398
401
  ANTHROPIC_DEFAULT_MODEL=claude-opus-5-5
@@ -462,14 +465,14 @@ Every entry in `models` takes one of four forms:
462
465
  "codex"; // -> Codex (GPT-6 Astra)
463
466
  "claude"; // -> Claude Agent SDK (Claude Opus 5.5)
464
467
  "gemini"; // -> Antigravity CLI (Gemini 3.8 Flash); `agy` works too
465
- "openai"; // -> OpenAI API (GPT-6 Sol)
468
+ "openai"; // -> OpenAI API (GPT-6.1 Sol)
466
469
 
467
470
  // provider:model — that model on that provider only
468
471
  "codex:astra"; // -> Codex (GPT-6 Astra)
469
472
  "openai:gpt-6-astra"; // -> OpenAI API, even when Codex is available
470
473
  "gemini:pro"; // -> Antigravity CLI (Gemini 3.1 Pro)
471
474
  "google:gemini-3.1-pro-preview"; // -> Google API
472
- "copilot:sonnet"; // -> GitHub Copilot (Claude Sonnet 5)
475
+ "copilot:sonnet"; // -> GitHub Copilot (Claude Sonnet 5.5)
473
476
  "openrouter:z-ai/glm-5.2:online"; // -> OpenRouter with web search opt-in
474
477
 
475
478
  // A bare model ID or alias — the first configured provider that offers it
@@ -495,8 +498,8 @@ Provider priority order (subscription-based local providers first, then API-key
495
498
  1. Codex (`codex` → GPT-6 Astra)
496
499
  2. Gemini via Antigravity CLI (`gemini` / `agy` → Gemini 3.8 Flash)
497
500
  3. Claude Agent SDK (`claude` → Claude Opus 5.5)
498
- 4. Copilot (`copilot` → GPT-6 Sol; `auto` only, never bare names)
499
- 5. OpenAI (`openai` → GPT-6 Sol)
501
+ 4. Copilot (`copilot` → GPT-6.1 Sol; `auto` only, never bare names)
502
+ 5. OpenAI (`openai` → GPT-6.1 Sol)
500
503
  6. Google (`google` → Gemini 3.1 Pro)
501
504
  7. XAI (`xai` → Grok 4.5)
502
505
  8. Anthropic (`anthropic` → Claude Opus 5.5)
package/docs/API.md CHANGED
@@ -480,7 +480,8 @@ Provide models as plain name strings in the `models` array. Each entry is `auto`
480
480
 
481
481
  | Model | Aliases | Context | Output | Notes |
482
482
  |-------|---------|---------|--------|-------|
483
- | `gpt-6-sol` | `gpt-6`, `gpt-5`, `sol` | 1M | 128K | Default OpenAI model; effort `none`–`max` |
483
+ | `gpt-6.1-sol` | `gpt-6`, `gpt-6.1`, `gpt-5`, `sol` | 1M | 128K | Default OpenAI model; near-Astra coding, computer use, and professional work at a fifth of the Astra price; effort `low`–`max` |
484
+ | `gpt-6-sol` | — | 1M | 128K | Previous GPT-6 Sol; reachable by versioned name only; effort `none`–`max` |
484
485
  | `gpt-6-luna` | `luna` | 1M | 128K | Most efficient GPT-6; effort `none`–`max` |
485
486
  | `gpt-6-astra` | `astra` | 1M | 128K | Frontier flagship (expensive); effort `low`–`max`, no `none` |
486
487
  | `gpt-5.6-sol` | `gpt-5.6` | 1M | 128K | Previous flagship |
@@ -524,10 +525,11 @@ Provide models as plain name strings in the `models` array. Each entry is `auto`
524
525
  | `claude-opus-5` | `opus-5` | 1M | 128K | Previous Opus, adaptive thinking + effort, compaction |
525
526
  | `claude-opus-4-8`, `claude-opus-4-7`, `claude-opus-4-6` | `opus-4.8`, `opus-4.7`, `opus-4.6` | 200K (1M beta) | 128K | Previous Opus generations |
526
527
  | `claude-opus-4-5-20251101`, `claude-opus-4-1-20250805` | `opus-4.5`, `opus-4.1` | 200K | 64K / 32K | Earlier Opus tiers |
527
- | `claude-sonnet-4-6` | `sonnet`, `sonnet-4.6` | 200K (1M beta) | 64K | Best speed/intelligence balance, adaptive thinking |
528
+ | `claude-sonnet-5-5` | `sonnet`, `sonnet-5.5`, `claude-sonnet` | 1M | 128K | Current Sonnet, adaptive thinking + effort, compaction |
529
+ | `claude-sonnet-4-6` | `sonnet-4.6` | 200K (1M beta) | 64K | Previous Sonnet, adaptive thinking |
528
530
  | `claude-haiku-4-5-20251001` | `haiku`, `haiku-4.5` | 200K | 64K | Fast and intelligent |
529
531
 
530
- Models with adaptive thinking control depth via `reasoning_effort`, which is passed by name to Anthropic's `effort` parameter and clamped to what each model accepts: Opus 5.5, Fable 5, Opus 5, Opus 4.8, and Opus 4.7 take `low`–`max`; Opus 4.6 and Sonnet 4.6 lack `xhigh` (it becomes `max`); Opus 4.5 tops out at `high`. `none` and `minimal` become `low` everywhere. System prompts are automatically cached for 1 hour; cache stats appear in response metadata as `cache_creation_input_tokens` / `cache_read_input_tokens`.
532
+ Models with adaptive thinking control depth via `reasoning_effort`, which is passed by name to Anthropic's `effort` parameter and clamped to what each model accepts: Opus 5.5, Sonnet 5.5, Fable 5, Opus 5, Opus 4.8, and Opus 4.7 take `low`–`max`; Opus 4.6 and Sonnet 4.6 lack `xhigh` (it becomes `max`); Opus 4.5 tops out at `high`. `none` and `minimal` become `low` everywhere. System prompts are automatically cached for 1 hour; cache stats appear in response metadata as `cache_creation_input_tokens` / `cache_read_input_tokens`.
531
533
 
532
534
  ### Mistral Models
533
535
 
@@ -567,20 +569,20 @@ Any other model works via its full `provider/model` slug (e.g. `anthropic/claude
567
569
  **Codex** is an agentic coding assistant with direct filesystem access:
568
570
 
569
571
  - **Model**: `codex` (underlying model: GPT-6 Astra by default, or `CODEX_DEFAULT_MODEL`)
570
- - **Backend selection**: `codex:<model>` per request (e.g. `codex:luna`, `codex:astra`, `codex:gpt-5.6-terra`) from the Codex catalog: `gpt-6-sol` (`sol`, `gpt-6`), `gpt-6-luna` (`luna`), `gpt-6-astra` (`astra`), `gpt-5.6-sol` (`gpt-5.6`), `gpt-5.6-terra` (`terra`), `gpt-5.6-luna`, `gpt-5.5`, `gpt-5.3-codex-spark` (`spark`). Other names are rejected with suggestions. Bare IDs from this list (e.g. `gpt-6-astra`) go to Codex first, then the OpenAI API.
572
+ - **Backend selection**: `codex:<model>` per request (e.g. `codex:luna`, `codex:astra`, `codex:gpt-5.6-terra`) from the Codex catalog: `gpt-6.1-sol` (`sol`, `gpt-6`), `gpt-6-sol`, `gpt-6-luna` (`luna`), `gpt-6-astra` (`astra`), `gpt-5.6-sol` (`gpt-5.6`), `gpt-5.6-terra` (`terra`), `gpt-5.6-luna`, `gpt-5.5`, `gpt-5.3-codex-spark` (`spark`). Other names are rejected with suggestions. Bare IDs from this list (e.g. `gpt-6-astra`) go to Codex first, then the OpenAI API.
571
573
  - **Availability**: the Codex SDK is installed and `~/.codex/auth.json` exists (`$CODEX_HOME/auth.json` when set) or `CODEX_API_KEY` is set
572
574
  - **Thread-based sessions**: persistent conversation history via `continuation_id` in `chat` mode
573
575
  - **Direct file access**: reads files from the working directory (paths relative to `CLIENT_CWD`)
574
576
  - **Response times**: 6-20 seconds typical (complex tasks may take minutes)
575
577
  - **Authentication**: ChatGPT login OR `CODEX_API_KEY` (NOT `OPENAI_API_KEY`)
576
- - `reasoning_effort` is clamped onto the tiers the chosen backend accepts (GPT-6 Sol/Luna and GPT-5.6: `none`–`max`; GPT-6 Astra: `low`–`max`, no `none`); web search is not applicable — Codex manages its own execution
578
+ - `reasoning_effort` is clamped onto the tiers the chosen backend accepts (GPT-6 Sol/Luna and GPT-5.6: `none`–`max`; GPT-6 Astra and GPT-6.1 Sol: `low`–`max`, no `none`); web search is not applicable — Codex manages its own execution
577
579
 
578
580
  ### Claude Agent SDK (subscription)
579
581
 
580
582
  **Claude** is available through the Claude Agent SDK, using Claude Code CLI authentication instead of an API key:
581
583
 
582
584
  - **Model**: `claude` (namespaces: `claude`, `claude-code`, `claude-sdk`) — defaults to Claude Opus 5.5 (`claude-opus-5-5`), or `CLAUDE_DEFAULT_MODEL`
583
- - **Model selection**: `claude-opus-5-5` (`opus`, `claude-opus`, `opus-5.5`), `claude-opus-5` (`opus-5`), `claude-fable-5-1` (`fable`, `claude-fable`, `fable-5.1`), `claude-fable-5` (`fable-5`), e.g. `claude:opus`, `claude:fable`. Other names are rejected with suggestions.
585
+ - **Model selection**: `claude-opus-5-5` (`opus`, `claude-opus`, `opus-5.5`), `claude-opus-5` (`opus-5`), `claude-fable-5-1` (`fable`, `claude-fable`, `fable-5.1`), `claude-fable-5` (`fable-5`), `claude-sonnet-5-5` (`sonnet`, `claude-sonnet`, `sonnet-5.5`), e.g. `claude:opus`, `claude:fable`, `claude:sonnet`. Other names are rejected with suggestions.
584
586
  - **Authentication**: `claude login` — no `ANTHROPIC_API_KEY` needed
585
587
  - **Availability**: the Claude Agent SDK is installed and `~/.claude/.credentials.json` exists (`$CLAUDE_CONFIG_DIR` when set), or `CLAUDE_CODE_OAUTH_TOKEN`/`ANTHROPIC_API_KEY` is in the environment; on macOS the Keychain login is assumed. An expired login is caught at call time and bare-name/`auto` routing fails over.
586
588
  - **Permissions**: runs with `bypassPermissions`
@@ -618,10 +620,10 @@ agy
618
620
 
619
621
  ### GitHub Copilot SDK (subscription)
620
622
 
621
- Reach these only with the `copilot:` namespace (also `github-copilot:`, `copilot-sdk:`; e.g. `copilot:gpt-6-sol`) — Copilot never serves bare model names. `copilot` alone uses GPT-6 Sol, or `COPILOT_DEFAULT_MODEL`. Available when the Copilot SDK is installed; uses your GitHub Copilot subscription (`gh auth login`) — no API key needed:
623
+ Reach these only with the `copilot:` namespace (also `github-copilot:`, `copilot-sdk:`; e.g. `copilot:gpt-6.1-sol`) — Copilot never serves bare model names. `copilot` alone uses GPT-6.1 Sol, or `COPILOT_DEFAULT_MODEL`. Available when the Copilot SDK is installed; uses your GitHub Copilot subscription (`gh auth login`) — no API key needed:
622
624
 
623
- - **OpenAI**: `gpt-6-sol` (aliases: `gpt-6`, `gpt-5`, `sol`), `gpt-6-luna` (alias: `luna`), `gpt-5.6-sol` (alias: `gpt-5.6`), `gpt-5.6-terra`, `gpt-5.6-luna` (all accept `reasoning_effort`)
624
- - **Anthropic**: `claude-opus-5.5` (aliases: `opus`, `claude`), `claude-fable-5` (alias: `fable`), `claude-sonnet-5` (alias: `sonnet`), `claude-opus-5`, `claude-opus-4.8`
625
+ - **OpenAI**: `gpt-6.1-sol` (aliases: `gpt-6`, `gpt-6.1`, `gpt-5`, `sol`), `gpt-6-sol`, `gpt-6-luna` (alias: `luna`), `gpt-5.6-sol` (alias: `gpt-5.6`), `gpt-5.6-terra`, `gpt-5.6-luna` (all accept `reasoning_effort`)
626
+ - **Anthropic**: `claude-opus-5.5` (aliases: `opus`, `claude`), `claude-fable-5` (alias: `fable`), `claude-sonnet-5.5` (alias: `sonnet`), `claude-sonnet-5`, `claude-opus-5`, `claude-opus-4.8`
625
627
  - **Google**: `gemini-3.1-pro-preview` (aliases: `gemini`, `gemini-3.1-pro`), `gemini-3.8-flash` (aliases: `gemini-3.8`, `flash-3.8`), `gemini-3.5-flash` (alias: `gemini-flash`)
626
628
  - Any other `copilot:<id>` is rejected with suggestions
627
629
 
@@ -638,7 +640,7 @@ Every entry in `models` takes one of four forms:
638
640
 
639
641
  ```text
640
642
  "auto" // First available provider (chat); first 3 (consensus)
641
- "gpt-6" // Codex (-> gpt-6-sol), else OpenAI API
643
+ "gpt-6" // Codex (-> gpt-6.1-sol), else OpenAI API
642
644
  "openai:gpt-6" // OpenAI API only
643
645
  "gemini-2.5-flash" // Google API
644
646
  "pro" // Antigravity CLI (-> gemini-3.1-pro-preview), else Google API
@@ -655,7 +657,7 @@ Every entry in `models` takes one of four forms:
655
657
  "claude:fable" // Claude Agent SDK (Claude Fable 5.1)
656
658
  "codex:luna" // Codex (GPT-6 Luna)
657
659
  "gemini" // Antigravity CLI (Gemini 3.8 Flash)
658
- "copilot:gpt-6-sol" // GitHub Copilot SDK
660
+ "copilot:gpt-6.1-sol" // GitHub Copilot SDK
659
661
  ```
660
662
 
661
663
  **Local agent permissions:** bare names and `auto` reach the local agent providers whenever they are set up. The Antigravity CLI auto-approves every tool request and the Claude Agent SDK runs with `bypassPermissions`, so a read-only prompt is not an enforced boundary there. Name the API provider (`google:pro`, `anthropic:opus`, `openai:gpt-6-astra`) to keep a request on a plain API.
@@ -704,8 +706,8 @@ Each provider's default model (used for its bare provider name and for `auto`) c
704
706
  CODEX_DEFAULT_MODEL=gpt-6-astra # CODEX_MODEL is honored as a legacy fallback
705
707
  CLAUDE_DEFAULT_MODEL=claude-opus-5-5
706
708
  AGY_DEFAULT_MODEL=gemini-3.8-flash # Antigravity CLI (gemini)
707
- COPILOT_DEFAULT_MODEL=gpt-6-sol # COPILOT_MODEL is honored as a legacy fallback
708
- OPENAI_DEFAULT_MODEL=gpt-6-sol
709
+ COPILOT_DEFAULT_MODEL=gpt-6.1-sol # COPILOT_MODEL is honored as a legacy fallback
710
+ OPENAI_DEFAULT_MODEL=gpt-6.1-sol
709
711
  GOOGLE_DEFAULT_MODEL=gemini-3.1-pro-preview
710
712
  XAI_DEFAULT_MODEL=grok-4.5
711
713
  ANTHROPIC_DEFAULT_MODEL=claude-opus-5-5
package/docs/PROVIDERS.md CHANGED
@@ -9,7 +9,8 @@ This guide documents all supported AI providers in the Converse MCP Server and t
9
9
  - **Get Key**: [platform.openai.com/api-keys](https://platform.openai.com/api-keys)
10
10
  - **Environment Variable**: `OPENAI_API_KEY`
11
11
  - **Supported Models**:
12
- - `gpt-6-sol` (aliases: `gpt-6`, `gpt-5`, `sol`) - Default GPT-6 and the default OpenAI model (1M context, 128K output; effort `none`–`max`)
12
+ - `gpt-6.1-sol` (aliases: `gpt-6`, `gpt-6.1`, `gpt-5`, `sol`) - Default OpenAI model (1M context, 128K output); near-Astra coding, computer use, and professional work at a fifth of the Astra price; effort `low`–`max`
13
+ - `gpt-6-sol` - Previous GPT-6 Sol (1M context, 128K output), reachable by versioned name only; effort `none`–`max`
13
14
  - `gpt-6-luna` (alias: `luna`) - Most efficient GPT-6 for focused, high-volume tasks (1M context, 128K output; effort `none`–`max`)
14
15
  - `gpt-6-astra` (alias: `astra`) - Frontier GPT-6 flagship, 5x the Sol price (1M context, 128K output; effort `low`–`max`)
15
16
  - `gpt-5.6-sol` (alias: `gpt-5.6`) - Previous flagship GPT-5.6
@@ -53,7 +54,8 @@ This guide documents all supported AI providers in the Converse MCP Server and t
53
54
  - `claude-opus-5` (alias `opus-5`) - Previous Opus generation (1M context, 128K output)
54
55
  - `claude-opus-4-8`, `claude-opus-4-7`, `claude-opus-4-6` - Earlier Opus generations with adaptive thinking (128K output)
55
56
  - `claude-opus-4-5-20251101`, `claude-opus-4-1-20250805` - Legacy Opus models (64K / 32K output)
56
- - `claude-sonnet-4-6` (alias `sonnet`) - Best combination of speed and intelligence with adaptive thinking (64K output)
57
+ - `claude-sonnet-5-5` (aliases `sonnet`, `sonnet-5.5`, `claude-sonnet`) - Current Sonnet: speed and capability for everyday coding and agentic work; adaptive thinking, effort `low`–`max` (1M context, 128K output)
58
+ - `claude-sonnet-4-6` (alias `sonnet-4.6`) - Previous Sonnet generation with adaptive thinking (64K output)
57
59
  - `claude-sonnet-4-5-20250929` - Legacy Sonnet (64K output)
58
60
  - `claude-haiku-4-5-20251001` (alias `haiku`) - Fast and intelligent with extended thinking (64K output)
59
61
 
@@ -110,11 +112,11 @@ This guide documents all supported AI providers in the Converse MCP Server and t
110
112
  - **Supported Models**:
111
113
  - `codex` - OpenAI Codex agentic coding assistant (GPT-6 Astra by default)
112
114
  - `codex:<model>` - Same, with an explicit backend from the Codex catalog:
113
- - `gpt-6-sol` (aliases: `sol`, `gpt-6`), `gpt-6-luna` (`luna`), `gpt-6-astra` (`astra`)
115
+ - `gpt-6.1-sol` (`sol`, `gpt-6`), `gpt-6-sol`, `gpt-6-luna` (`luna`), `gpt-6-astra` (`astra`)
114
116
  - `gpt-5.6-sol` (`gpt-5.6`), `gpt-5.6-terra` (`terra`), `gpt-5.6-luna`, `gpt-5.5`, `gpt-5.3-codex-spark` (`spark`)
115
117
  - Names outside this catalog are rejected with suggestions
116
118
  - These IDs are also bare names: `gpt-6-astra`, `luna` or `terra` alone go to Codex first and fail over to the OpenAI API (see [Model Routing Logic](#model-routing-logic))
117
- - `reasoning_effort` is clamped onto what the backend accepts (Sol/Luna: `none`–`max`; GPT-6 Astra: `low`–`max`, no `none`)
119
+ - `reasoning_effort` is clamped onto what the backend accepts (versioned GPT-6 Sol, Luna, and GPT-5.6: `none`–`max`; GPT-6.1 Sol and GPT-6 Astra: `low`–`max`, no `none`)
118
120
  - Thread-based sessions with persistent context
119
121
  - Direct filesystem access from working directory
120
122
  - Typical response time: 6-20 seconds (longer for complex tasks)
@@ -215,7 +217,8 @@ agy
215
217
  - `claude-opus-5` (alias: `opus-5`) - Claude Opus 5
216
218
  - `claude-fable-5-1` (aliases: `fable`, `claude-fable`, `fable-5.1`) - Claude Fable 5.1 (`claude:fable`)
217
219
  - `claude-fable-5` (alias: `fable-5`) - Claude Fable 5.0
218
- - Names outside this catalog are rejected with suggestions (e.g. `claude:sonnet` suggests `copilot:sonnet` and `anthropic:sonnet`)
220
+ - `claude-sonnet-5-5` (aliases: `sonnet`, `claude-sonnet`, `sonnet-5.5`) - Claude Sonnet 5.5 (`claude:sonnet`)
221
+ - Names outside this catalog are rejected with suggestions (e.g. `claude:haiku` suggests `anthropic:haiku`)
219
222
 
220
223
  **Key Features:**
221
224
  - **Subscription Access**: Uses your Claude subscription instead of API credits
@@ -228,7 +231,7 @@ agy
228
231
  **Differences from Anthropic API Provider:**
229
232
  - **Authentication**: Claude Code login vs `ANTHROPIC_API_KEY`
230
233
  - **Billing**: Claude subscription vs pay-per-use API
231
- - **Model Routing**: `claude` and `claude:<model>` → SDK provider; `anthropic:<model>` → API provider; bare names both serve as the same model (`opus`, `claude-opus-5-5`, `claude-opus-5`, `claude-fable-5`) → SDK first, then the API on authentication/availability failure; bare names only the API serves (e.g., `sonnet`, `haiku`) → API provider. Bare `fable` is Fable 5.1 on the SDK but Fable 5 on the API, so it does not fail over between them.
234
+ - **Model Routing**: `claude` and `claude:<model>` → SDK provider; `anthropic:<model>` → API provider; bare names both serve as the same model (`opus`, `sonnet`, `claude-opus-5-5`, `claude-opus-5`, `claude-sonnet-5-5`, `claude-fable-5`) → SDK first, then the API on authentication/availability failure; bare names only the API serves (e.g., `haiku`, `sonnet-4.6`) → API provider. Bare `fable` is Fable 5.1 on the SDK but Fable 5 on the API, so it does not fail over between them.
232
235
  - **Permissions**: The SDK runs with `bypassPermissions`, and bare names and `auto` reach it whenever it is available. Use `anthropic:<model>` to keep a request on the plain API.
233
236
 
234
237
  ### GitHub Copilot SDK
@@ -236,11 +239,11 @@ agy
236
239
  - **Setup Required**: Authenticate the GitHub CLI and ensure your account has an active Copilot subscription
237
240
  - **Availability**: The Copilot SDK (`@github/copilot-sdk`) is installed
238
241
  - **Environment Variables**:
239
- - `COPILOT_DEFAULT_MODEL` - Model used for bare `copilot` and `auto` (default: `gpt-6-sol`). The legacy name `COPILOT_MODEL` is honored when `COPILOT_DEFAULT_MODEL` is unset.
240
- - **Supported Models** (namespace-only: reach them with `copilot:`, `github-copilot:` or `copilot-sdk:`, e.g. `copilot:gpt-6-sol`; Copilot never serves bare model names):
241
- - `copilot` - GPT-6 Sol, or `COPILOT_DEFAULT_MODEL`
242
- - OpenAI: `gpt-6-sol` (aliases: `gpt-6`, `gpt-5`, `sol`), `gpt-6-luna` (alias: `luna`), `gpt-5.6-sol` (alias: `gpt-5.6`), `gpt-5.6-terra`, `gpt-5.6-luna`
243
- - Anthropic: `claude-opus-5.5` (aliases: `opus`, `claude`; Copilot Pro+/Max/Business/Enterprise), `claude-fable-5` (alias: `fable`), `claude-sonnet-5` (alias: `sonnet`), `claude-opus-5`, `claude-opus-4.8`
242
+ - `COPILOT_DEFAULT_MODEL` - Model used for bare `copilot` and `auto` (default: `gpt-6.1-sol`). The legacy name `COPILOT_MODEL` is honored when `COPILOT_DEFAULT_MODEL` is unset.
243
+ - **Supported Models** (namespace-only: reach them with `copilot:`, `github-copilot:` or `copilot-sdk:`, e.g. `copilot:gpt-6.1-sol`; Copilot never serves bare model names):
244
+ - `copilot` - GPT-6.1 Sol, or `COPILOT_DEFAULT_MODEL`
245
+ - OpenAI: `gpt-6.1-sol` (aliases: `gpt-6`, `gpt-6.1`, `gpt-5`, `sol`), `gpt-6-sol`, `gpt-6-luna` (alias: `luna`), `gpt-5.6-sol` (alias: `gpt-5.6`), `gpt-5.6-terra`, `gpt-5.6-luna`
246
+ - Anthropic: `claude-opus-5.5` (aliases: `opus`, `claude`; Copilot Pro+/Max/Business/Enterprise), `claude-fable-5` (alias: `fable`), `claude-sonnet-5.5` (alias: `sonnet`), `claude-sonnet-5`, `claude-opus-5`, `claude-opus-4.8`
244
247
  - Google: `gemini-3.1-pro-preview` (aliases: `gemini`, `gemini-3.1-pro`), `gemini-3.8-flash` (aliases: `gemini-3.8`, `flash-3.8`), `gemini-3.5-flash` (alias: `gemini-flash`)
245
248
  - **Reasoning**: The GPT-6 and GPT-5.6 tiers accept `reasoning_effort` (clamped onto Copilot's `low`–`xhigh`).
246
249
  - **Unknown IDs**: Any other `copilot:<id>` is rejected with suggestions; only the IDs and aliases above are accepted.
@@ -281,8 +284,8 @@ Each provider has a `<PROVIDER>_DEFAULT_MODEL` variable that sets the model used
281
284
  CODEX_DEFAULT_MODEL=gpt-6-astra # CODEX_MODEL is honored as a legacy fallback
282
285
  CLAUDE_DEFAULT_MODEL=claude-opus-5-5
283
286
  AGY_DEFAULT_MODEL=gemini-3.8-flash # Antigravity CLI (gemini)
284
- COPILOT_DEFAULT_MODEL=gpt-6-sol # COPILOT_MODEL is honored as a legacy fallback
285
- OPENAI_DEFAULT_MODEL=gpt-6-sol
287
+ COPILOT_DEFAULT_MODEL=gpt-6.1-sol # COPILOT_MODEL is honored as a legacy fallback
288
+ OPENAI_DEFAULT_MODEL=gpt-6.1-sol
286
289
  GOOGLE_DEFAULT_MODEL=gemini-3.1-pro-preview
287
290
  XAI_DEFAULT_MODEL=grok-4.5
288
291
  ANTHROPIC_DEFAULT_MODEL=claude-opus-5-5
@@ -333,7 +336,7 @@ All providers support streaming responses for real-time output.
333
336
  - **Google**:
334
337
  - Gemini 3.0 Pro: Thinking levels (low/high) via `reasoning_effort` - always enabled
335
338
  - Gemini 2.5 Pro/Flash: Thinking budget (token-based) via `reasoning_effort`
336
- - **Anthropic**: Claude Fable 5, Opus 4.6+, and Sonnet 4.6 use adaptive thinking (depth controlled by `reasoning_effort` via Anthropic's `effort` parameter); older Claude 4 models use budget-based extended thinking
339
+ - **Anthropic**: Claude Fable 5, Opus 4.6+, and Sonnet 4.6+ use adaptive thinking (depth controlled by `reasoning_effort` via Anthropic's `effort` parameter); older Claude 4 models use budget-based extended thinking
337
340
  - **X.AI**: Grok 4.5 maps `reasoning_effort` to `low`/`medium`/`high` and always reasons (cannot be disabled)
338
341
  - **Mistral**: `mistral-medium-3-5` and `mistral-small-2603` map `reasoning_effort` to `high` (enabled) or `none` (disabled); `mistral-large-2512` has no adjustable reasoning
339
342
  - **DeepSeek**: V4 models use thinking mode via `reasoning_effort` (`none` disables; enabled levels use `high`, `max` uses `max`)
@@ -379,12 +382,12 @@ Routing is derived entirely from each provider's model list (canonical IDs plus
379
382
  Examples:
380
383
 
381
384
  ```text
382
- "gpt-6" // Codex (gpt-6-sol), else OpenAI API
385
+ "gpt-6" // Codex (gpt-6.1-sol), else OpenAI API
383
386
  "openai:gpt-6" // OpenAI API only
384
387
  "fable" // Claude Agent SDK (claude-fable-5-1) when set up, otherwise Anthropic API (claude-fable-5)
385
388
  "opus" // Claude Agent SDK (claude-opus-5-5), else Anthropic API
386
389
  "anthropic:opus" // Anthropic API only
387
- "sonnet" // Anthropic API (claude-sonnet-4-6)
390
+ "sonnet" // Claude Agent SDK (claude-sonnet-5-5), else Anthropic API
388
391
  "claude" // Claude Agent SDK (defaults to Claude Opus 5.5)
389
392
  "claude:fable" // Claude Agent SDK (Claude Fable 5.1)
390
393
  "pro" // Antigravity CLI (gemini-3.1-pro-preview), else Google API
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "converse-mcp-server",
3
- "version": "4.2.1",
3
+ "version": "4.4.0",
4
4
  "description": "Converse MCP Server - Converse with other LLMs with chat and consensus tools",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
@@ -93,16 +93,16 @@
93
93
  ".env.example"
94
94
  ],
95
95
  "dependencies": {
96
- "@anthropic-ai/claude-agent-sdk": "^0.3.282",
97
- "@anthropic-ai/sdk": "^0.128.0",
98
- "@github/copilot-sdk": "^1.0.14",
96
+ "@anthropic-ai/claude-agent-sdk": "^0.3.284",
97
+ "@anthropic-ai/sdk": "^0.129.0",
98
+ "@github/copilot-sdk": "^1.0.15",
99
99
  "@google/genai": "^2.24.0",
100
100
  "@lydell/node-pty": "1.2.0-beta.15",
101
101
  "@mistralai/mistralai": "^2.7.0",
102
- "@modelcontextprotocol/sdk": "^1.30.1",
103
- "@openai/codex-sdk": "^0.157.0",
102
+ "@modelcontextprotocol/sdk": "^1.31.0",
103
+ "@openai/codex-sdk": "^0.159.0",
104
104
  "cors": "^2.8.6",
105
- "dotenv": "^18.0.3",
105
+ "dotenv": "^18.0.4",
106
106
  "express": "^5.2.1",
107
107
  "lru-cache": "^11.5.3",
108
108
  "nanoid": "^6.0.1",
@@ -111,10 +111,10 @@
111
111
  "vite": "^8.3.1"
112
112
  },
113
113
  "devDependencies": {
114
- "@vitest/coverage-v8": "^5.0.1",
114
+ "@vitest/coverage-v8": "^5.0.2",
115
115
  "cross-env": "^10.1.0",
116
116
  "eslint": "^10.11.0",
117
117
  "rimraf": "^6.1.3",
118
- "vitest": "^5.0.1"
118
+ "vitest": "^5.0.2"
119
119
  }
120
120
  }
@@ -37,6 +37,7 @@ const SUPPORTED_MODELS = {
37
37
  effortTiers: EFFORT_TIERS_FULL,
38
38
  // Absent from Anthropic's compaction compatibility list, unlike Opus 5
39
39
  supportsCompaction: false,
40
+ supportsDefaultFallback: true,
40
41
  description:
41
42
  'Claude Opus 5.5 - Flagship Opus for complex agentic coding and deep reasoning; matches Fable 5.1 on most work at Opus pricing',
42
43
  aliases: [
@@ -93,6 +94,7 @@ const SUPPORTED_MODELS = {
93
94
  effortGA: true,
94
95
  effortTiers: EFFORT_TIERS_FULL,
95
96
  supportsCompaction: true,
97
+ supportsDefaultFallback: true,
96
98
  description:
97
99
  'Claude Opus 5 - Previous Opus generation for complex agentic coding and deep reasoning',
98
100
  aliases: [
@@ -103,6 +105,37 @@ const SUPPORTED_MODELS = {
103
105
  'claude-opus-5.0',
104
106
  ],
105
107
  },
108
+ 'claude-sonnet-5-5': {
109
+ modelName: 'claude-sonnet-5-5',
110
+ friendlyName: 'Claude Sonnet 5.5',
111
+ contextWindow: 1000000, // 1M context by default - no beta header required
112
+ maxOutputTokens: 128000,
113
+ supportsStreaming: true,
114
+ supportsImages: true,
115
+ supportsWebSearch: false,
116
+ supportsThinking: true,
117
+ supportsAdaptiveThinking: true, // {type: "disabled"} is rejected; adaptive is the only on-mode
118
+ timeout: 1800000,
119
+ supportsEffort: true,
120
+ effortGA: true,
121
+ effortTiers: EFFORT_TIERS_FULL,
122
+ supportsCompaction: true,
123
+ supportsDefaultFallback: true,
124
+ description:
125
+ 'Claude Sonnet 5.5 - Current Sonnet: speed and capability for everyday coding and agentic work',
126
+ aliases: [
127
+ 'claude-sonnet-5-5',
128
+ 'claude-sonnet-5.5',
129
+ 'claude-5.5-sonnet',
130
+ 'claude-5-5-sonnet',
131
+ 'sonnet-5.5',
132
+ 'sonnet-5-5',
133
+ 'sonnet5.5',
134
+ 'sonnet5-5',
135
+ 'sonnet',
136
+ 'claude-sonnet',
137
+ ],
138
+ },
106
139
  'claude-opus-4-8': {
107
140
  modelName: 'claude-opus-4-8',
108
141
  friendlyName: 'Claude Opus 4.8',
@@ -270,7 +303,7 @@ const SUPPORTED_MODELS = {
270
303
  supports1MContext: true, // Beta 1M context support
271
304
  supportsCompaction: true, // Beta server-side context compaction
272
305
  description:
273
- 'Claude Sonnet 4.6 - Best combination of speed and intelligence with adaptive thinking',
306
+ 'Claude Sonnet 4.6 - Previous Sonnet generation with adaptive thinking',
274
307
  aliases: [
275
308
  'claude-sonnet-4-6',
276
309
  'claude-4.6-sonnet',
@@ -280,8 +313,6 @@ const SUPPORTED_MODELS = {
280
313
  'sonnet4.6',
281
314
  'sonnet4-6',
282
315
  'claude-sonnet-4.6',
283
- 'sonnet',
284
- 'claude-sonnet',
285
316
  ],
286
317
  },
287
318
  'claude-sonnet-4-5-20250929': {
@@ -369,6 +400,24 @@ class AnthropicProviderError extends ProviderError {
369
400
  }
370
401
  }
371
402
 
403
+ /**
404
+ * A refusal arrives as a successful response whose text is empty or cut off
405
+ * mid-answer, so it must not be passed on as a (partial) answer. The category
406
+ * tells the caller whether rephrasing or another model is the way forward.
407
+ */
408
+ function refusalError(stopDetails) {
409
+ const category = stopDetails?.category
410
+ ? ` (category: ${stopDetails.category})`
411
+ : '';
412
+ const explanation = stopDetails?.explanation
413
+ ? `: ${stopDetails.explanation}`
414
+ : '';
415
+ return new AnthropicProviderError(
416
+ `Anthropic declined the request${category}${explanation}`,
417
+ ErrorCodes.REFUSED,
418
+ );
419
+ }
420
+
372
421
  /**
373
422
  * Resolve model name to canonical form, including aliases
374
423
  */
@@ -661,6 +710,13 @@ export const anthropicProvider = {
661
710
  );
662
711
  }
663
712
 
713
+ // A safety-classifier decline is retried server-side on the model Anthropic
714
+ // recommends for that refusal category; only a decline by the whole chain
715
+ // comes back as a refusal.
716
+ if (modelConfig.supportsDefaultFallback) {
717
+ betas.push('server-side-fallback-2026-07-01');
718
+ }
719
+
664
720
  // Add effort beta feature for models that need it (not GA yet)
665
721
  if (modelConfig.supportsEffort && reasoning_effort && !modelConfig.effortGA) {
666
722
  betas.push('effort-2025-11-24');
@@ -690,6 +746,10 @@ export const anthropicProvider = {
690
746
  requestPayload.system = systemPrompt;
691
747
  }
692
748
 
749
+ if (modelConfig.supportsDefaultFallback) {
750
+ requestPayload.fallbacks = 'default';
751
+ }
752
+
693
753
  // Set max tokens - API requires this field
694
754
  if (maxTokens) {
695
755
  requestPayload.max_tokens = Math.min(
@@ -823,6 +883,10 @@ export const anthropicProvider = {
823
883
  const responseTime = Date.now() - startTime;
824
884
  debugLog(`[Anthropic] Response received in ${responseTime}ms`);
825
885
 
886
+ if (response.stop_reason === 'refusal') {
887
+ throw refusalError(response.stop_details);
888
+ }
889
+
826
890
  // Extract response content
827
891
  let content = '';
828
892
 
@@ -965,6 +1029,7 @@ export const anthropicProvider = {
965
1029
  let thinkingContent = '';
966
1030
  let lastUsage = null;
967
1031
  let finishReason = null;
1032
+ let stopDetails = null;
968
1033
 
969
1034
  try {
970
1035
  // Yield start event
@@ -1040,6 +1105,7 @@ export const anthropicProvider = {
1040
1105
  // Message-level updates (usage, stop_reason)
1041
1106
  if (event.delta?.stop_reason) {
1042
1107
  finishReason = event.delta.stop_reason;
1108
+ stopDetails = event.delta.stop_details ?? null;
1043
1109
  }
1044
1110
  if (event.usage) {
1045
1111
  lastUsage = event.usage;
@@ -1083,6 +1149,10 @@ export const anthropicProvider = {
1083
1149
  }
1084
1150
  }
1085
1151
 
1152
+ if (finishReason === 'refusal') {
1153
+ throw refusalError(stopDetails);
1154
+ }
1155
+
1086
1156
  const responseTime = Date.now() - startTime;
1087
1157
  debugLog(`[Anthropic] Streaming completed in ${responseTime}ms`);
1088
1158
 
@@ -93,6 +93,25 @@ const SUPPORTED_MODELS = {
93
93
  'Claude Fable 5 via Agent SDK - requires claude login authentication',
94
94
  aliases: ['fable-5', 'fable5'],
95
95
  },
96
+ 'claude-sonnet-5-5': {
97
+ modelName: 'claude-sonnet-5-5',
98
+ friendlyName: 'Claude Sonnet 5.5 (via Agent SDK)',
99
+ contextWindow: 1000000,
100
+ maxOutputTokens: 128000,
101
+ supportsStreaming: true,
102
+ supportsImages: true,
103
+ supportsWebSearch: false,
104
+ timeout: 1800000,
105
+ description:
106
+ 'Claude Sonnet 5.5 via Agent SDK - requires claude login authentication',
107
+ aliases: [
108
+ 'sonnet',
109
+ 'claude-sonnet',
110
+ 'claude-sonnet-5.5',
111
+ 'sonnet-5-5',
112
+ 'sonnet-5.5',
113
+ ],
114
+ },
96
115
  };
97
116
 
98
117
  /**
@@ -29,14 +29,14 @@ import {
29
29
  /**
30
30
  * Models Codex can run, keyed by the slug passed to the CLI as --model. The
31
31
  * catalog key is the canonical model ID the router resolves to. The reasoning tiers are the ones each model's API accepts, verified
32
- * against the API's own rejection messages (gpt-6-astra: "Supported values
33
- * are: 'low', 'medium', 'high', 'xhigh', and 'max'"; the Sol/Luna tiers of
34
- * both generations accept 'none' as well). The SDK's ModelReasoningEffort
35
- * type is the union across models, so the backend is the authority and
36
- * requests are clamped per model.
32
+ * against the API's own rejection messages (gpt-6-astra and gpt-6.1-sol:
33
+ * "Supported values are: 'low', 'medium', 'high', 'xhigh', and 'max'"; the
34
+ * GPT-6 and GPT-5.6 Sol/Luna tiers accept 'none' as well). The SDK's
35
+ * ModelReasoningEffort type is the union across models, so the backend is the
36
+ * authority and requests are clamped per model.
37
37
  *
38
38
  * Bare tier names (sol, luna) and the bare generation (gpt-6) point at the
39
- * current generation; the GPT-5.6 tiers stay reachable by full slug.
39
+ * current release of each tier; older releases stay reachable by full slug.
40
40
  *
41
41
  * Codex also exposes 'ultra' above 'max', but that tier turns on automatic
42
42
  * sub-agent delegation — a change in how the run executes, not just how deep
@@ -44,6 +44,7 @@ import {
44
44
  * and nothing at the tool level can select it.
45
45
  */
46
46
  const ALL_EFFORTS = ['none', 'low', 'medium', 'high', 'xhigh', 'max'];
47
+ const NO_NONE_EFFORTS = ['low', 'medium', 'high', 'xhigh', 'max'];
47
48
 
48
49
  function codexModel(slug, friendlyName, { aliases, contextWindow = 272000, supportedEfforts = ALL_EFFORTS }) {
49
50
  return {
@@ -62,15 +63,19 @@ function codexModel(slug, friendlyName, { aliases, contextWindow = 272000, suppo
62
63
  }
63
64
 
64
65
  const SUPPORTED_MODELS = {
66
+ 'gpt-6.1-sol': codexModel('gpt-6.1-sol', 'GPT-6.1 Sol', {
67
+ aliases: ['sol', 'gpt-6', 'gpt6', 'gpt-6.1', 'gpt6.1', 'gpt6.1-sol', 'gpt-6-codex'],
68
+ supportedEfforts: NO_NONE_EFFORTS,
69
+ }),
65
70
  'gpt-6-sol': codexModel('gpt-6-sol', 'GPT-6 Sol', {
66
- aliases: ['sol', 'gpt-6', 'gpt6', 'gpt6-sol', 'gpt-6-codex'],
71
+ aliases: ['gpt6-sol'],
67
72
  }),
68
73
  'gpt-6-luna': codexModel('gpt-6-luna', 'GPT-6 Luna', {
69
74
  aliases: ['luna', 'gpt6-luna'],
70
75
  }),
71
76
  'gpt-6-astra': codexModel('gpt-6-astra', 'GPT-6 Astra', {
72
77
  aliases: ['astra', 'gpt6-astra'],
73
- supportedEfforts: ['low', 'medium', 'high', 'xhigh', 'max'],
78
+ supportedEfforts: NO_NONE_EFFORTS,
74
79
  }),
75
80
  'gpt-5.6-sol': codexModel('gpt-5.6-sol', 'GPT-5.6 Sol', {
76
81
  aliases: ['gpt-5.6', 'gpt5.6', 'gpt5.6-sol', 'gpt-5.6-codex'],
@@ -21,16 +21,30 @@ import { clampReasoningEffort } from '../utils/reasoningEffort.js';
21
21
  import { findCatalogEntry, findCatalogId } from '../utils/modelCatalog.js';
22
22
  import { isPackageResolvable } from '../utils/localProviderAuth.js';
23
23
 
24
- const DEFAULT_MODEL = 'gpt-6-sol';
24
+ const DEFAULT_MODEL = 'gpt-6.1-sol';
25
25
 
26
26
  // Keyed by the SDK model ID, which is also the canonical ID the router
27
27
  // resolves to. Every name here is reached only through the `copilot:`
28
28
  // namespace — Copilot never serves bare model names.
29
29
  const SUPPORTED_MODELS = {
30
30
  // OpenAI models
31
- // `gpt-6` / `gpt-5.6` point at that generation's Sol, matching Copilot's own
32
- // bare-alias behavior; `sol`/`luna` and the legacy `gpt-5` shortcut follow
33
- // the current generation. `codex` and `gpt` point at the latest GPT tier.
31
+ // `gpt-6` / `gpt-5.6` point at that generation's latest Sol, matching
32
+ // Copilot's own bare-alias behavior; `sol`/`luna` and the legacy `gpt-5`
33
+ // shortcut follow the current release of each tier. `codex` and `gpt` point
34
+ // at the latest GPT tier.
35
+ 'gpt-6.1-sol': {
36
+ modelName: 'gpt-6.1-sol',
37
+ friendlyName: 'GPT-6.1 Sol (via Copilot)',
38
+ contextWindow: 1050000,
39
+ maxOutputTokens: 32768,
40
+ supportsStreaming: true,
41
+ supportsImages: false,
42
+ supportsWebSearch: false,
43
+ supportsReasoningEffort: true,
44
+ timeout: 1800000,
45
+ description: 'OpenAI GPT-6.1 Sol via Copilot subscription',
46
+ aliases: ['gpt-6', 'gpt-6.1', 'gpt-5', 'gpt', 'codex', 'sol'],
47
+ },
34
48
  'gpt-6-sol': {
35
49
  modelName: 'gpt-6-sol',
36
50
  friendlyName: 'GPT-6 Sol (via Copilot)',
@@ -42,7 +56,7 @@ const SUPPORTED_MODELS = {
42
56
  supportsReasoningEffort: true,
43
57
  timeout: 1800000,
44
58
  description: 'OpenAI GPT-6 Sol via Copilot subscription',
45
- aliases: ['gpt-6', 'gpt-5', 'gpt', 'codex', 'sol'],
59
+ aliases: [],
46
60
  },
47
61
  'gpt-6-luna': {
48
62
  modelName: 'gpt-6-luna',
@@ -123,6 +137,18 @@ const SUPPORTED_MODELS = {
123
137
  description: 'Anthropic Claude Fable 5 via Copilot subscription',
124
138
  aliases: ['fable'],
125
139
  },
140
+ 'claude-sonnet-5.5': {
141
+ modelName: 'claude-sonnet-5.5',
142
+ friendlyName: 'Claude Sonnet 5.5 (via Copilot)',
143
+ contextWindow: 200000,
144
+ maxOutputTokens: 32768,
145
+ supportsStreaming: true,
146
+ supportsImages: false,
147
+ supportsWebSearch: false,
148
+ timeout: 1800000,
149
+ description: 'Anthropic Claude Sonnet 5.5 via Copilot subscription',
150
+ aliases: ['sonnet', 'claude-sonnet-5-5'],
151
+ },
126
152
  'claude-sonnet-5': {
127
153
  modelName: 'claude-sonnet-5',
128
154
  friendlyName: 'Claude Sonnet 5 (via Copilot)',
@@ -133,7 +159,7 @@ const SUPPORTED_MODELS = {
133
159
  supportsWebSearch: false,
134
160
  timeout: 1800000,
135
161
  description: 'Anthropic Claude Sonnet 5 via Copilot subscription',
136
- aliases: ['sonnet'],
162
+ aliases: [],
137
163
  },
138
164
  'claude-opus-5': {
139
165
  modelName: 'claude-opus-5',
@@ -168,6 +168,7 @@ export const ErrorCodes = {
168
168
  // Response errors
169
169
  NO_RESPONSE_CONTENT: 'NO_RESPONSE_CONTENT',
170
170
  NO_RESPONSE_CHOICE: 'NO_RESPONSE_CHOICE',
171
+ REFUSED: 'REFUSED',
171
172
 
172
173
  // Rate limiting and quota
173
174
  RATE_LIMIT_EXCEEDED: 'RATE_LIMIT_EXCEEDED',
@@ -11,14 +11,14 @@ import { clampReasoningEffort } from '../utils/reasoningEffort.js';
11
11
 
12
12
  // Values each family accepts for reasoning effort, per the model pages at
13
13
  // developers.openai.com/api/docs/models. The GPT-6 Sol/Luna tiers and the
14
- // GPT-5.6 family take the whole ladder; GPT-6 Astra has no 'none'; the
15
- // GPT-5.4 tier stops at 'xhigh'; the original GPT-5 minis kept 'minimal' but
16
- // never gained 'xhigh'; the o-series predates both ends of the ladder;
17
- // GPT-5.4 Pro starts at 'medium'. Models without a list are passed the
14
+ // GPT-5.6 family take the whole ladder; GPT-6 Astra and GPT-6.1 Sol have no
15
+ // 'none'; the GPT-5.4 tier stops at 'xhigh'; the original GPT-5 minis kept
16
+ // 'minimal' but never gained 'xhigh'; the o-series predates both ends of the
17
+ // ladder; GPT-5.4 Pro starts at 'medium'. Models without a list are passed the
18
18
  // requested value unchanged, except uncatalogued GPT-5 Pro snapshots, which
19
19
  // are only known to accept 'high'.
20
20
  const FULL_EFFORT_TIERS = ['none', 'low', 'medium', 'high', 'xhigh', 'max'];
21
- const GPT_6_ASTRA_EFFORT_TIERS = ['low', 'medium', 'high', 'xhigh', 'max'];
21
+ const NO_NONE_EFFORT_TIERS = ['low', 'medium', 'high', 'xhigh', 'max'];
22
22
  const GPT_54_EFFORT_TIERS = ['none', 'low', 'medium', 'high', 'xhigh'];
23
23
  const GPT_54_PRO_EFFORT_TIERS = ['medium', 'high', 'xhigh'];
24
24
  const GPT_5_EFFORT_TIERS = ['minimal', 'low', 'medium', 'high'];
@@ -27,35 +27,53 @@ const PRO_PASSTHROUGH_EFFORT_TIERS = ['high'];
27
27
 
28
28
  // Define supported models with their capabilities.
29
29
  // Bare tier names (sol, luna) and the bare generation (gpt-6, and the legacy
30
- // gpt-5 shortcut) follow the current generation; older tiers stay reachable by
31
- // their versioned names.
30
+ // gpt-5 shortcut) follow the current release of each tier; older tiers stay
31
+ // reachable by their versioned names.
32
32
  const SUPPORTED_MODELS = {
33
- 'gpt-6-sol': {
34
- modelName: 'gpt-6-sol',
35
- friendlyName: 'OpenAI (GPT-6 Sol)',
33
+ 'gpt-6.1-sol': {
34
+ modelName: 'gpt-6.1-sol',
35
+ friendlyName: 'OpenAI (GPT-6.1 Sol)',
36
36
  contextWindow: 1050000,
37
37
  maxOutputTokens: 128000,
38
38
  supportsStreaming: true,
39
39
  supportsImages: true,
40
40
  supportsWebSearch: true,
41
41
  supportsResponsesAPI: true,
42
- supportedEfforts: FULL_EFFORT_TIERS,
42
+ supportedEfforts: NO_NONE_EFFORT_TIERS,
43
43
  timeout: 10800000, // 3 hours
44
44
  description:
45
- 'Default GPT-6 model (1M context, 128K output) - Complex coding and agentic workflows at a fifth of the Astra price',
45
+ 'Default GPT-6 model (1M context, 128K output) - Near-Astra coding, computer use and professional work at a fifth of the Astra price',
46
46
  aliases: [
47
47
  'gpt-6',
48
48
  'gpt6',
49
49
  'gpt 6',
50
+ 'gpt-6.1',
51
+ 'gpt6.1',
52
+ 'gpt 6.1',
50
53
  'gpt-5',
51
54
  'gpt5',
52
55
  'gpt 5',
53
56
  'sol',
54
- 'gpt6-sol',
55
- 'gpt-6sol',
56
- 'gpt 6 sol',
57
+ 'gpt6.1-sol',
58
+ 'gpt-6.1sol',
59
+ 'gpt 6.1 sol',
57
60
  ],
58
61
  },
62
+ 'gpt-6-sol': {
63
+ modelName: 'gpt-6-sol',
64
+ friendlyName: 'OpenAI (GPT-6 Sol)',
65
+ contextWindow: 1050000,
66
+ maxOutputTokens: 128000,
67
+ supportsStreaming: true,
68
+ supportsImages: true,
69
+ supportsWebSearch: true,
70
+ supportsResponsesAPI: true,
71
+ supportedEfforts: FULL_EFFORT_TIERS,
72
+ timeout: 10800000, // 3 hours
73
+ description:
74
+ 'Previous GPT-6 Sol (1M context, 128K output) - Complex coding and agentic workflows; the only Sol that accepts none effort',
75
+ aliases: ['gpt6-sol', 'gpt-6sol', 'gpt 6 sol'],
76
+ },
59
77
  'gpt-6-luna': {
60
78
  modelName: 'gpt-6-luna',
61
79
  friendlyName: 'OpenAI (GPT-6 Luna)',
@@ -80,7 +98,7 @@ const SUPPORTED_MODELS = {
80
98
  supportsImages: true,
81
99
  supportsWebSearch: true,
82
100
  supportsResponsesAPI: true,
83
- supportedEfforts: GPT_6_ASTRA_EFFORT_TIERS,
101
+ supportedEfforts: NO_NONE_EFFORT_TIERS,
84
102
  timeout: 10800000, // 3 hours
85
103
  description:
86
104
  'Frontier GPT-6 flagship (1M context, 128K output) - Maximum intelligence for the hardest end-to-end work (EXPENSIVE: 5x Sol)',
@@ -410,7 +428,7 @@ function acceptsReasoningEffort(resolvedModel, modelConfig) {
410
428
  /**
411
429
  * Resolve the reasoning effort actually sent to the API. Catalogued models
412
430
  * clamp onto their declared tiers. Pass-through IDs are matched by family
413
- * where the tiers are known (GPT-5 Pro snapshots, GPT-6 Sol/Luna and GPT-5.6
431
+ * where the tiers are known (GPT-5 Pro snapshots, GPT-6.x and GPT-5.6
414
432
  * snapshots) and otherwise keep the requested value.
415
433
  */
416
434
  function resolveReasoningEffort(resolvedModel, modelConfig, reasoningEffort) {
@@ -420,8 +438,11 @@ function resolveReasoningEffort(resolvedModel, modelConfig, reasoningEffort) {
420
438
  if (resolvedModel.endsWith('-pro') && resolvedModel.startsWith('gpt-5')) {
421
439
  return clampReasoningEffort(reasoningEffort, PRO_PASSTHROUGH_EFFORT_TIERS);
422
440
  }
423
- if (resolvedModel.startsWith('gpt-6-astra')) {
424
- return clampReasoningEffort(reasoningEffort, GPT_6_ASTRA_EFFORT_TIERS);
441
+ if (
442
+ resolvedModel.startsWith('gpt-6-astra') ||
443
+ resolvedModel.startsWith('gpt-6.1-sol')
444
+ ) {
445
+ return clampReasoningEffort(reasoningEffort, NO_NONE_EFFORT_TIERS);
425
446
  }
426
447
  if (
427
448
  resolvedModel.startsWith('gpt-6-sol') ||
@@ -547,7 +568,7 @@ function convertMessages(messages, useResponsesAPI = false) {
547
568
  /**
548
569
  * Main OpenAI provider implementation
549
570
  */
550
- const DEFAULT_MODEL = 'gpt-6-sol';
571
+ const DEFAULT_MODEL = 'gpt-6.1-sol';
551
572
 
552
573
  export const openaiProvider = {
553
574
  defaultModel: DEFAULT_MODEL,