copilot-custom-endpoint 1.6.6 → 1.6.7

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/README.md CHANGED
@@ -19,18 +19,18 @@ That's it. No code, no servers to manage (unless the model specifically needs th
19
19
 
20
20
  ## Pick a model
21
21
 
22
- | Model | Provider | Needs proxy? | Vision | Setup guide |
23
- | --------------------------- | --------- | ---------------------- | ------------ | -------------------------------------------------------------------------------------------------- |
24
- | **MiMo V2.5** | Xiaomi | Optional (recommended) | ✅ | [Setup](docs/models/mimo.md) |
25
- | **MiMo V2.5 Pro** | Xiaomi | Optional (recommended) | ❌ | [Setup](docs/models/mimo.md) |
26
- | **Kimi K2.7 Code / K2.6** | Moonshot | **Yes** | ✅ | [Setup](docs/models/kimi.md) |
27
- | **Qwen 3.7 Plus** | DashScope | Optional (recommended) | ✅ | [Setup](docs/models/qwen.md) |
28
- | **Qwen 3.7 Max** | DashScope | Optional (recommended) | ❌ | [Setup](docs/models/qwen.md) |
29
- | **MiniMax M3** | MiniMax | No | ✅ | [Setup](docs/models/minimax.md) |
30
- | **GLM 5.2** | Z.ai | No | ❌ | [Setup](docs/models/glm.md) |
31
- | **GLM 5.1** | Z.ai | No | ❌ | [Setup](docs/models/glm.md) |
32
- | **GLM 5V Turbo** | Z.ai | No | ✅ | [Setup](docs/models/glm.md) |
33
- | **DeepSeek V4 Pro / Flash** | DeepSeek | No (uses an extension) | ✅ via proxy | [Marketplace](https://marketplace.visualstudio.com/items?itemName=Vizards.deepseek-v4-for-copilot) |
22
+ | Model | Provider | Needs proxy? | Vision | Setup guide |
23
+ | --------------------------- | --------- | ---------------------- | ------------ | ----------------------------------------------------------------------------------------------------------------------------------------- |
24
+ | **MiMo V2.5** | Xiaomi | Optional (recommended) | ✅ | [Extension](https://marketplace.visualstudio.com/items?itemName=sdmapvstool.xiaomimimo-for-copilot) ★ / [Setup](docs/models/mimo.md) |
25
+ | **MiMo V2.5 Pro** | Xiaomi | Optional (recommended) | ❌ | [Extension](https://marketplace.visualstudio.com/items?itemName=sdmapvstool.xiaomimimo-for-copilot) ★ / [Setup](docs/models/mimo.md) |
26
+ | **Kimi K2.7 Code / K2.6** | Moonshot | **Yes** | ✅ | [Extension](https://marketplace.visualstudio.com/items?itemName=DenizhanDaklr.kimi-lm-provider) ★ / [Setup](docs/models/kimi.md) |
27
+ | **Qwen 3.7 Plus** | DashScope | Optional (recommended) | ✅ | [Setup](docs/models/qwen.md) |
28
+ | **Qwen 3.7 Max** | DashScope | Optional (recommended) | ❌ | [Setup](docs/models/qwen.md) |
29
+ | **MiniMax M3** | MiniMax | No | ✅ | [Extension](https://marketplace.visualstudio.com/items?itemName=klarkxy.minimax-vscode-copilot) ★ / [Setup](docs/models/minimax.md) |
30
+ | **GLM 5.2** | Z.ai | No | ❌ | [Extension](https://marketplace.visualstudio.com/items?itemName=ikaros.glm-for-vscode-copilot) ★ / [Setup](docs/models/glm.md) |
31
+ | **GLM 5.1** | Z.ai | No | ❌ | [Extension](https://marketplace.visualstudio.com/items?itemName=yijiazhen-qi.glm-for-github-copilot-chat) ★ / [Setup](docs/models/glm.md) |
32
+ | **GLM 5V Turbo** | Z.ai | No | ✅ | [Extension](https://marketplace.visualstudio.com/items?itemName=ikaros.glm-for-vscode-copilot) ★ / [Setup](docs/models/glm.md) |
33
+ | **DeepSeek V4 Pro / Flash** | DeepSeek | No (uses an extension) | ✅ via proxy | [Marketplace](https://marketplace.visualstudio.com/items?itemName=Vizards.deepseek-v4-for-copilot) |
34
34
 
35
35
  ## Setup
36
36
 
@@ -135,6 +135,7 @@ For footnotes, sources, and detailed notes (cache behavior, tiered pricing, free
135
135
  > - Highest intelligence score (44.4) among affordable models
136
136
  > - Only ~$0.27/session with vision + 1M context
137
137
  > - No local proxy required — works direct
138
+ > - **Use the [MiniMax Copilot extension](https://marketplace.visualstudio.com/items?itemName=klarkxy.minimax-vscode-copilot) for the best experience** (Token Plan subscription required; for PAYG, use the [manual setup](docs/models/minimax.md))
138
139
  >
139
140
  > **DeepSeek V4 Pro** is a strong backup — nearly identical intelligence (44.3 vs 44.4) and cost (~$0.0068 vs ~$0.0061 per intelligence point), but noticeably faster in practice.
140
141
  >
@@ -1,6 +1,6 @@
1
1
  # Full example config
2
2
 
3
- Here's a complete, real-world `chatLanguageModels.json` that combines **the `customendpoint` providers from the live `chatLanguageModels.json`**. Copy what you need, leave the rest out.
3
+ Here's a complete, real-world `chatLanguageModels.json` that combines **the `customendpoint` providers from the live `chatLanguageModels.json`**, plus the additional GLM models (`glm-5.2`, `glm-5.1`) that are validated in [docs/models/glm.md](models/glm.md) but not present in every live config. Copy what you need, leave the rest out.
4
4
 
5
5
  > **Note:** The `apiKey` fields are left as empty strings — set them via the **Chat: Manage Language Models** UI (Command Palette → right-click provider group → **Update API Key**). After you set a key via the UI, VS Code replaces the empty string with a `${input:chat.lm.secret.<id>}` secret reference.
6
6
  >
@@ -3,6 +3,14 @@
3
3
  > **TL;DR:** GLM works directly with VS Code's custom-endpoint provider — **no proxy needed**. The API is OpenAI Chat Completions compatible at `https://api.z.ai/api/paas/v4/chat/completions`, and Z.ai's default `thinking.clear_thinking: true` quietly strips `reasoning_content` from prior turns, which makes multi-turn tool loops stable even when VS Code doesn't preserve reasoning blocks.
4
4
  >
5
5
  > **Billing:** The PaaS API is **Pay-as-You-Go** (per-token). Z.ai also offers a **Coding Plan** subscription (Lite/Pro/Max, $18–$160/mo), but it uses a **different endpoint** (`/api/coding/paas/v4`) that is **locked to a curated list of coding tools** (Claude Code, Cursor, Cline, etc.) — it **cannot** be used from VS Code custom endpoints. See [Why the GLM Coding Plan is not an option](#why-the-glm-coding-plan-is-not-an-option-for-vs-code).
6
+ >
7
+ > **🆕 GLM VS Code extensions are available.** Three community extensions add reasoning visibility (collapsible thinking blocks), per-model thinking toggles, usage dashboards, and more — all impossible with custom endpoints. Two of them support **Standard API** keys. See the [full comparison](../research/glm-vscode-extension.md) for details:
8
+ >
9
+ > | Extension | Marketplace ID | Standard API | Coding Plan | Key feature |
10
+ > | ------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ | :----------: | :---------: | ----------------------------------- |
11
+ > | **GLM for Copilot** (umbrella22) | [`ikaros.glm-for-vscode-copilot`](https://marketplace.visualstudio.com/items?itemName=ikaros.glm-for-vscode-copilot) | ✅ | ✅ | Vision proxy, cost est., team mode |
12
+ > | **GLM Models for Copilot** (KiwiGaze) | [`yijiazhen-qi.glm-for-github-copilot-chat`](https://marketplace.visualstudio.com/items?itemName=yijiazhen-qi.glm-for-github-copilot-chat) | ✅ | ✅ | Quota dashboard, dual API |
13
+ > | **GLM Chat Provider** (zelosleone) | _(pending)_ | ❌ | ✅ | 14 models, per-model thinking tiers |
6
14
 
7
15
  ## At a Glance
8
16
 
@@ -60,7 +68,7 @@ Modify your configuration:
60
68
  "models": [
61
69
  {
62
70
  "id": "glm-5.2",
63
- "name": "GLM 5.2 (1M Context)",
71
+ "name": "GLM 5.2 (text)",
64
72
  "url": "https://api.z.ai/api/paas/v4/chat/completions",
65
73
  "toolCalling": true,
66
74
  "vision": false,
@@ -1,6 +1,8 @@
1
1
  # Kimi — VS Code Custom Endpoint Setup Guide
2
2
 
3
3
  > **TL;DR:** Kimi models require the local proxy. The K2 family locks `temperature: 1` and `top_p: 0.95`. K2.6 requires `thinking: { type: "disabled" }` on tool turns; **K2.7 Code is always-thinking and rejects `thinking: disabled`**, so the proxy detects `kimi-k2.7*` and skips that rewrite while keeping sampling enforcement. Direct VS Code → Moonshot integration is not viable in this environment.
4
+ >
5
+ > **🆕 Alternative: Kimi VS Code extension.** If you're on the **Kimi Coding tier** (`kimi.com/code/console`), try the [**Moonshot LM Provider**](https://marketplace.visualstudio.com/items?itemName=DenizhanDaklr.kimi-lm-provider) extension — it offers zero-proxy setup, reasoning visibility via `LanguageModelThinkingPart`, prompt caching, and a simpler install. **Not compatible with Pay-as-You-Go** keys from `platform.kimi.ai`. See the [full comparison](../research/kimi-vscode-extension.md).
4
6
 
5
7
  ## At a Glance
6
8
 
@@ -1,41 +1,74 @@
1
- # Xiaomi MiMo — VS Code Custom Endpoint Setup Guide
1
+ # Xiaomi MiMo — VS Code Copilot Chat Setup Guide
2
2
 
3
- > **TL;DR:** MiMo works direct with static `thinking: { type: "disabled" }` in `requestBody`, or via `proxy/mimo-proxy.mjs` for dynamic thinking suppression (reasoning visible in plain chat, suppressed in tool loops). Static suppression is simpler; the proxy lets you see reasoning in non-agent chats.
3
+ > **TL;DR:** The **recommended** way to use MiMo with Copilot Chat is the [Xiaomi MiMo for Copilot Chat](https://marketplace.visualstudio.com/items?itemName=sdmapvstool.xiaomimimo-for-copilot) VS Code extension — it supports thinking mode WITH tool calling, prompt caching feedback, reasoning visibility in agent mode, and token usage reporting, all with zero dependencies (no proxy server needed). Two alternative methods are documented below for users who prefer direct `chatLanguageModels.json` control: direct API with static `thinking: disabled`, or via `proxy/mimo-proxy.mjs` for dynamic thinking suppression.
4
4
  >
5
5
  > **June 2026 provider notice:** Xiaomi says the legacy ids `mimo-v2-pro` and `mimo-v2-omni` have already been auto-switched to V2.5 replacements and billed at V2.5-series pricing. Xiaomi's same notice also retires an older legacy chat alias and the `mimo-v2-tts` alias. Requests that still use retired legacy aliases are scheduled to start failing after **2026-06-30 00:00 Beijing time**. This guide now documents only the current V2.5 chat ids.
6
6
 
7
7
  ## At a Glance
8
8
 
9
- | Field | Value |
10
- | ---------------------- | -------------------------------------------------------------------------------------------------------------- |
11
- | Mode | **Direct** (proxy optional) |
12
- | Vision | ✅ Yes (`mimo-v2.5` only) |
13
- | Tool calling | ✅ Yes (with `thinking: disabled`) |
14
- | Context | 1M (V2.5 Pro / V2.5) |
15
- | Max output | 131072 (V2.5 Pro) / 32768 (V2.5) |
16
- | Required `requestBody` | Direct: `thinking: { type: "disabled" }`<br>Proxy: none (proxy handles it) |
17
- | Endpoint | Direct: `https://api.xiaomimimo.com/v1/chat/completions`<br>Proxy: `http://127.0.0.1:3459/v1/chat/completions` |
9
+ | Field | Value |
10
+ | ---------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
11
+ | **Recommended method** | **[Xiaomi MiMo for Copilot Chat](https://marketplace.visualstudio.com/items?itemName=sdmapvstool.xiaomimimo-for-copilot)** VS Code extension |
12
+ | Alternative methods | Direct API (static `thinking: disabled`) or `proxy/mimo-proxy.mjs` (dynamic suppression) |
13
+ | Vision | ✅ Yes (`mimo-v2.5` only) |
14
+ | Tool calling | ✅ Yes (with thinking disabled, OR thinking enabled via the extension's reasoning cache) |
15
+ | Context | 917K (extension) / 1M (custom endpoint) |
16
+ | Max output | 131072 (UltraSpeed / V2.5 Pro) / 32768 (V2.5) |
17
+ | Dependencies | Extension: **none**. Proxy method: Node.js + `proxy/mimo-proxy.mjs` |
18
18
 
19
19
  ### Models at a glance
20
20
 
21
- | Model | Vision | Context | Role |
22
- | --------------- | ------ | ------- | ------------------------------------------ |
23
- | `mimo-v2.5-pro` | ❌ | 1M | Flagship text-only — best for agentic work |
24
- | `mimo-v2.5` | ✅ | 1M | Omnimodal — text + image + video + audio |
21
+ | Model | Vision | Context | Role |
22
+ | -------------------------- | ------ | ------- | ---------------------------------------------------- |
23
+ | `mimo-v2.5-pro-ultraspeed` | ❌ | 917K | Fast Pro reasoning for latency-sensitive agent tasks |
24
+ | `mimo-v2.5-pro` | ❌ | 917K | Flagship text-only — best for deep reasoning |
25
+ | `mimo-v2.5` | ✅ | 917K | Omnimodal — text + image + video + audio |
25
26
 
27
+ > **Note:** `mimo-v2.5-pro-ultraspeed` is only available through the VS Code extension. The custom-endpoint methods below only cover `mimo-v2.5-pro` and `mimo-v2.5`.
28
+ >
26
29
  > Official June 2026 notice: legacy pre-V2.5 chat aliases now auto-route to V2.5 replacements and become invalid after **2026-06-30 00:00 Beijing time**. This guide intentionally omits retired alias names so new configs only show supported ids.
27
30
 
28
31
  ## Quick Start
29
32
 
30
- ### Direct (no proxy)
33
+ ### Recommended: VS Code Extension
34
+
35
+ The [Xiaomi MiMo for Copilot Chat](https://marketplace.visualstudio.com/items?itemName=sdmapvstool.xiaomimimo-for-copilot) extension is the easiest and most capable way to use MiMo with Copilot Chat:
36
+
37
+ 1. **Install** from the [VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=sdmapvstool.xiaomimimo-for-copilot).
38
+ 2. **Set your API key** — run **MiMo: Set API Key** from the Command Palette (`Ctrl+Shift+P`).
39
+ 3. **Pick a model** — open Copilot Chat, click the model picker, and choose **MiMo-V2.5-Pro-UltraSpeed**, **MiMo V2.5 Pro**, or **MiMo V2.5**.
40
+ 4. That's it — chat away.
41
+
42
+ **Why the extension over custom endpoints:**
43
+
44
+ | Capability | Extension | Custom Endpoint |
45
+ | -------------------------------- | ------------------------------------ | -------------------------------------- |
46
+ | Thinking + tool calling together | ✅ Yes (reasoning cache) | ❌ Must disable thinking on tool turns |
47
+ | Reasoning visible in agent mode | ✅ Yes (`LanguageModelThinkingPart`) | ❌ Hidden (suppressed by proxy) |
48
+ | Prompt caching feedback loop | ✅ 97–99% cache hit rates | ❌ No cache awareness |
49
+ | Token usage in context widget | ✅ Yes | ❌ No |
50
+ | `mimo-v2.5-pro-ultraspeed` model | ✅ Yes | ❌ Not available |
51
+ | Multi-region endpoint selector | ✅ Built-in dropdown | ❌ Manual JSON edits |
52
+ | Dependencies | ✅ Zero (VS Code + Node built-ins) | ❌ Requires proxy server |
53
+ | API key validation | ✅ `sk-` / `tp-` prefix check | ❌ Generic secret input |
54
+
55
+ > **Prerequisites:** VS Code 1.116+, GitHub Copilot subscription (Free tier works), and a MiMo API key from [platform.xiaomimimo.com](https://platform.xiaomimimo.com/console/api-keys). The extension is MIT-licensed. Source: [Sdcb/xiaomimimo-for-copilot](https://github.com/Sdcb/xiaomimimo-for-copilot).
56
+
57
+ The extension exposes models as a proper `LanguageModelChatProvider` (vendor `'mimo'`), so they appear directly in the Copilot Chat model picker alongside GPT-4o, Claude, and friends. Switch models mid-chat without losing history.
58
+
59
+ For a detailed comparison of extension vs. custom-endpoint features, see [docs/research/mimo-improvements.md](../research/mimo-improvements.md).
60
+
61
+ ### Alternative: Direct API (static `thinking: disabled`)
62
+
63
+ Simplest no-proxy approach — but thinking is always off, so you never see model reasoning.
31
64
 
32
- 1. **Edit `chatLanguageModels.json`** — add the MiMo block(s) from [Setup](#setup) below.
65
+ 1. **Edit `chatLanguageModels.json`** — add the MiMo block(s) from [Setup → Direct](#direct-static-thinking-disabled) below.
33
66
  2. **Set your `MIMO_API_KEY`** via Command Palette → **Chat: Manage Language Models**.
34
67
  3. **Restart VS Code** and pick "MiMo V2.5 Pro" or "MiMo V2.5".
35
68
 
36
- ### With optional proxy (dynamic thinking)
69
+ ### Alternative: With optional proxy (dynamic thinking)
37
70
 
38
- The `proxy/mimo-proxy.mjs` provides dynamic thinking suppression: reasoning stays ON in plain chat but turns OFF automatically when tools are invoked.
71
+ The `proxy/mimo-proxy.mjs` provides dynamic thinking suppression: reasoning stays ON in plain chat but turns OFF automatically when tools are invoked. A middle ground — you see reasoning in chat but not during agent mode.
39
72
 
40
73
  - `npm run proxy:mimo` (from the repo root)
41
74
  - `npx copilot-custom-endpoint mimo` (standalone, no clone needed)
@@ -46,7 +79,24 @@ When using the proxy, update your model URLs to `http://127.0.0.1:3459/v1/chat/c
46
79
 
47
80
  ## Setup
48
81
 
49
- ### 1. VS Code configuration
82
+ ### Recommended: VS Code Extension
83
+
84
+ 1. Install from the [VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=sdmapvstool.xiaomimimo-for-copilot).
85
+ 2. Run **MiMo: Set API Key** from the Command Palette.
86
+ 3. (Optional) Run **MiMo: Open Settings** to configure endpoint region, max tokens, or model ID overrides.
87
+
88
+ **Extension settings:**
89
+
90
+ | Setting | Default | Description |
91
+ | ------------------------------- | ------------------------------- | -------------------------------------------------------- |
92
+ | `mimo-copilot.baseUrl` | `https://api.xiaomimimo.com/v1` | API endpoint — select a preset or pick 'Custom Endpoint' |
93
+ | `mimo-copilot.customBaseUrl` | _(empty)_ | Custom endpoint URL when baseUrl is 'Custom Endpoint' |
94
+ | `mimo-copilot.maxTokens` | `0` | Max output tokens (`0` = API default, capped at 131072) |
95
+ | `mimo-copilot.modelIdOverrides` | `{}` | Override API model IDs for third-party proxies |
96
+
97
+ The extension stores your API key in VS Code's `SecretStorage` (OS keychain) — never in `settings.json`, never in Git history.
98
+
99
+ ### Alternative: Custom Endpoint (direct or proxy)
50
100
 
51
101
  Config file location:
52
102
 
@@ -140,7 +190,7 @@ Config file location:
140
190
  }
141
191
  ```
142
192
 
143
- ### 2. API key
193
+ ### 1. API key (custom endpoint only)
144
194
 
145
195
  1. Open the Command Palette (`Ctrl+Shift+P`).
146
196
  2. Run **Chat: Manage Language Models**.
@@ -148,8 +198,10 @@ Config file location:
148
198
  4. Paste your MiMo API key.
149
199
 
150
200
  > After setting via the UI, VS Code replaces `"apiKey": ""` with a `${input:chat.lm.secret.<id>}` reference.
201
+ >
202
+ > The extension uses its own **MiMo: Set API Key** command instead — skip this step if using the extension.
151
203
 
152
- ### 3. Token Plan (optional)
204
+ ### 2. Token Plan (optional, all methods)
153
205
 
154
206
  Token Plan subscribers use different base URLs and `tp-` prefixed keys from the pay-as-you-go `sk-` keys. The **model id** (`mimo-v2.5-pro`, `mimo-v2.5`) and **`requestBody`** (thinking, temperature, top_p) are the **same** for both billing modes — only the URL and key prefix differ.
155
207
 
@@ -163,9 +215,9 @@ Token Plan subscribers use different base URLs and `tp-` prefixed keys from the
163
215
  | OpenAI | `https://token-plan-cn.xiaomimimo.com/v1` |
164
216
  | Anthropic | `https://token-plan-cn.xiaomimimo.com/anthropic` |
165
217
 
166
- > The same `requestBody` block (thinking, temperature, top_p) is shared between both modes. If you switch from PAYG to Token Plan, update the `url` in `chatLanguageModels.json` and swap the key — the rest of the config stays as-is. Note that the Token Plan endpoint is `token-plan-cn.xiaomimimo.com` (China-hosted), which differs from the PAYG endpoint `api.xiaomimimo.com`.
218
+ > The extension has a built-in multi-region endpoint selector covering all Token Plan regions (China, Singapore, Amsterdam). With the custom endpoint method, update the `url` in `chatLanguageModels.json` and swap the key — the rest of the config stays as-is. Note that the Token Plan endpoint is `token-plan-cn.xiaomimimo.com` (China-hosted), which differs from the PAYG endpoint `api.xiaomimimo.com`.
167
219
 
168
- ### 4. Legacy id retirement schedule
220
+ ### 3. Legacy id retirement schedule (all methods)
169
221
 
170
222
  From Xiaomi's June 2026 deprecation notice:
171
223
 
@@ -216,13 +268,13 @@ When thinking is enabled, responses include a `reasoning_content` field alongsid
216
268
 
217
269
  ## Troubleshooting
218
270
 
219
- | Symptom | Likely cause | Fix |
220
- | ------------------------------------------ | -------------------------------------------------------- | ---------------------------------------------------------------------------------------------- |
221
- | HTTP 400 on the second turn of a tool loop | `reasoning_content` missing in history (thinking on) | Add `thinking: { type: "disabled" }` to `requestBody`, or use the proxy (`npm run proxy:mimo`) |
222
- | Vision request returns an error | Used `mimo-v2.5-pro` (text-only) | Use `mimo-v2.5` for vision |
223
- | Custom `tool_choice` ignored | MiMo only honors `"auto"` | Stick to `auto` |
224
- | 401 Unauthorized | Wrong key, or Token Plan URL used with pay-as-you-go key | Match key prefix (`sk-` vs `tp-`) to the endpoint |
225
- | 429 rate-limited | Concurrent sessions exceeded 100 RPM / 10M TPM | Reduce concurrent agent sessions |
271
+ | Symptom | Likely cause | Fix |
272
+ | ------------------------------------------ | -------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- |
273
+ | HTTP 400 on the second turn of a tool loop | `reasoning_content` missing in history (thinking on) | **Use the extension** (it caches reasoning per tool-call ID). Or: add `thinking: { type: "disabled" }` to `requestBody`, or use the proxy (`npm run proxy:mimo`) |
274
+ | Vision request returns an error | Used `mimo-v2.5-pro` (text-only) | Use `mimo-v2.5` for vision |
275
+ | Custom `tool_choice` ignored | MiMo only honors `"auto"` | Stick to `auto` |
276
+ | 401 Unauthorized | Wrong key, or Token Plan URL used with pay-as-you-go key | Match key prefix (`sk-` vs `tp-`) to the endpoint |
277
+ | 429 rate-limited | Concurrent sessions exceeded 100 RPM / 10M TPM | Reduce concurrent agent sessions |
226
278
 
227
279
  ## Pricing
228
280
 
@@ -249,10 +301,20 @@ This is the same class of problem as Qwen's `reasoning_content` issue, but **str
249
301
 
250
302
  **Implication for VS Code Copilot:** VS Code's agent mode is unlikely to preserve `reasoning_content` across multi-turn tool loops. Therefore:
251
303
 
252
- - **Thinking enabled + tool calling = broken** (400 errors after the first tool round-trip).
304
+ - **Thinking enabled + tool calling = broken** (400 errors after the first tool round-trip) — _unless using the [VS Code extension](https://marketplace.visualstudio.com/items?itemName=sdmapvstool.xiaomimimo-for-copilot), which caches and re-injects `reasoning_content`._
253
305
  - **Thinking disabled + tool calling = works** (no `reasoning_content` to preserve).
254
306
  - **Thinking enabled + plain chat = works** (no tool calls in history).
255
307
 
308
+ ### Extension solves the `reasoning_content` problem natively
309
+
310
+ The [Xiaomi MiMo for Copilot Chat](https://github.com/Sdcb/xiaomimimo-for-copilot) extension implements a reasoning-content cache that makes thinking mode work WITH tool calling. It:
311
+
312
+ 1. Caches `reasoning_content` keyed by `tool_call_id` as the model streams tool calls.
313
+ 2. Re-injects cached reasoning into prior assistant messages when reconstructing history for subsequent turns.
314
+ 3. Prunes stale entries at conversation start (messages ≤ 2) or via LRU eviction (max 200 entries).
315
+
316
+ This is the single biggest architectural advantage of the extension over the proxy approach. See [docs/research/mimo-improvements.md](../research/mimo-improvements.md) for a full comparison.
317
+
256
318
  ### Proxy for dynamic thinking suppression
257
319
 
258
320
  A dynamic proxy (`proxy/mimo-proxy.mjs`) is now available — same pattern as `proxy/qwen-proxy.mjs`. It suppresses thinking only when tools are present, letting plain chat show reasoning while keeping tool loops stable.
@@ -288,13 +350,13 @@ External API checks (curl):
288
350
 
289
351
  ### Known risks
290
352
 
291
- | Risk | Detail | Mitigation |
292
- | ------------------------------------- | ------------------------------------------------------------------ | -------------------------------------------------------------------------- |
293
- | `reasoning_content` 400 errors | If thinking is accidentally enabled in tool loops, API returns 400 | Set `thinking.type: "disabled"` in `requestBody` (direct) or use the proxy |
294
- | `tool_choice` only supports `"auto"` | Non-`auto` values are stripped | Should not affect VS Code, which uses `auto` |
295
- | Auth header format | Both `api-key:` and `Authorization: Bearer` work | VS Code sends `Authorization: Bearer` — works directly |
296
- | `temperature` locked in thinking mode | V2.5 Pro / V2.5 force `temperature: 1.0` when thinking is on | Not an issue when thinking is disabled |
297
- | 1M context window | VS Code may not send enough tokens to benefit | Set conservatively; adjust after testing |
353
+ | Risk | Detail | Mitigation |
354
+ | ------------------------------------- | ------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ |
355
+ | `reasoning_content` 400 errors | If thinking is accidentally enabled in tool loops, API returns 400 | **Use the extension** (solves natively). Or: set `thinking.type: "disabled"` in `requestBody` (direct), or use the proxy |
356
+ | `tool_choice` only supports `"auto"` | Non-`auto` values are stripped | Should not affect VS Code, which uses `auto` |
357
+ | Auth header format | Both `api-key:` and `Authorization: Bearer` work | VS Code sends `Authorization: Bearer` — works directly |
358
+ | `temperature` locked in thinking mode | V2.5 Pro / V2.5 force `temperature: 1.0` when thinking is on | Not an issue when thinking is disabled |
359
+ | 1M context window | VS Code may not send enough tokens to benefit | Set conservatively; adjust after testing |
298
360
 
299
361
  ## References
300
362
 
@@ -4,6 +4,10 @@
4
4
  >
5
5
  > The same `url`, `model id`, and `requestBody` work for **both** Pay-as-You-Go (account-balance billing) and Token Plan (monthly/annual subscription) — only the API key in the secret field changes. See [API key source](#3-api-key-source) below.
6
6
 
7
+ > **🆕 Try the MiniMax Copilot extension first.** If you have a **Token Plan subscription** (`sk-cp-…` key), use the [**MiniMax Copilot** VS Code extension](https://marketplace.visualstudio.com/items?itemName=klarkxy.minimax-vscode-copilot) instead — it gives you reasoning visibility, a usage dashboard, status-bar quota monitoring, one-click region switching, and M3 1M context toggling. Install → `MiniMax: Add API Key` → done. No JSON editing.
8
+ >
9
+ > **PAYG users:** the extension targets the Anthropic-compatible endpoint which requires a Token Plan subscription key. If you're on pay-as-you-go, use the manual setup below — it works with both PAYG and Token Plan keys on the OpenAI-compatible endpoint.
10
+
7
11
  ## At a Glance
8
12
 
9
13
  | Field | Value |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "copilot-custom-endpoint",
3
- "version": "1.6.6",
3
+ "version": "1.6.7",
4
4
  "description": "Local proxies for VS Code Copilot custom endpoints — Kimi K2, Qwen 3.x & MiMo V2.5",
5
5
  "license": "MIT",
6
6
  "type": "module",