copilot-custom-endpoint 3.3.3 → 3.4.1
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 +4 -3
- package/docs/models/qwen.md +94 -57
- package/docs/pricing.md +12 -4
- package/package.json +2 -2
- package/proxy/qwen-proxy.mjs +5 -3
package/README.md
CHANGED
|
@@ -121,7 +121,7 @@ It approximates the cost of one point on the AA Intelligence Index under the com
|
|
|
121
121
|
|
|
122
122
|
For example, GLM 5.3 Flash is `(0.5 × $0.15) + (0.1 × $0.50) = $0.125`, shown as `~$0.13`. Cached-input discounts are not included. Actual costs vary with context length, output length, caching, pricing tiers, promotions, and provider billing. DeepSeek estimates use peak rates; official off-peak rates are half.
|
|
123
123
|
|
|
124
|
-
The current AA values come from OpenRouter's September
|
|
124
|
+
The current AA values come from OpenRouter's September 30 model metadata and ranking card; **every pricing cell comes from first-party provider pricing or GitHub Copilot's official billing table, never OpenRouter.** The OpenRouter ranking card places unversioned Qwen3.8 Max at **53.4 (#3)**, while the exact 0902 API metadata row is **45.4**. Qwen Cloud PAYG pricing remains **$2 / $0.25 implicit cache / $6** for Qwen3.8 Max; its separate Token Plan is not the PAYG rate table. This refresh records Gemini 3.8 Flash, Grok 4.7, GPT-6 Sol, GPT-6.1 Sol, GPT-6 Luna, Claude Opus 5.5, and Claude Sonnet 5.5 as **Copilot-native** models, using current AA v4.3.2 composites. GPT-6.1 Sol (released September 29) enters at **51.8**, and MiMo V2.6 Flash now has a composite (**37.9**) and moves to the top of the table.
|
|
125
125
|
|
|
126
126
|
| Model | Provider | Cost per intelligence | Intelligence Score | Est. session | Vision | Context window |
|
|
127
127
|
| ---------------------------- | --------- | --------------------- | ------------------ | ------------ | ------ | -------------- |
|
|
@@ -140,6 +140,7 @@ The current AA values come from OpenRouter's September 29 model metadata and ran
|
|
|
140
140
|
| **Qwen 3.8 Max (0902)** | DashScope | **~$0.0352** | **45.4** | ~$1.60 | ✅ | 1M |
|
|
141
141
|
| **Claude Sonnet 5.5** | Anthropic | **~$0.0357** | **56.0** | ~$2.00 | ✅ | 1M |
|
|
142
142
|
| **Grok 4.6** | xAI | **~$0.0361** | **44.3** | ~$1.60 | ✅ | 500K |
|
|
143
|
+
| **GPT-6.1 Sol** | OpenAI | **~$0.0386** | **51.8** | ~$2.00 | ✅ | 1M |
|
|
143
144
|
| **GPT-6 Sol** | OpenAI | **~$0.0421** | **47.5** | ~$2.00 | ✅ | 1M |
|
|
144
145
|
| **GPT-5.6 Terra** | OpenAI | **~$0.0523** | **42.1** | ~$2.20 | ✅ | 1M |
|
|
145
146
|
| **Claude Sonnet 5** | Anthropic | **~$0.0524** | **38.2** | ~$2.00 | ✅ | 1M |
|
|
@@ -153,7 +154,7 @@ The current AA values come from OpenRouter's September 29 model metadata and ran
|
|
|
153
154
|
| **Claude Fable 5** | Anthropic | **~$0.2016** | **49.6** | ~$10.00 | ✅ | 1M |
|
|
154
155
|
|
|
155
156
|
> `MiMo V2.6 Pro UltraSpeed` uses the MiMo V2.6 Pro benchmark score because it is the same-quality latency tier; no independent composite is published. `MiniMax M3 Priority` is intentionally omitted from this snapshot because it is the same model with a priority service tier; the full pricing table documents its separate tier cost. `MiMo V2.6 Flash`'s composite (37.9) is OpenRouter's Artificial Analysis v4.3.2 value; Xiaomi's published launch benchmarks for it are recorded in [docs/benchmarks.md](docs/benchmarks.md).
|
|
156
|
-
> GPT-6 Sol and Luna use standard rates up to 272K input tokens; requests above that threshold have higher input/cache and output rates. GitHub Copilot also bills cache writes separately. Plan access differs: Sol
|
|
157
|
+
> GPT-6 Sol, GPT-6.1 Sol, and Luna use standard rates up to 272K input tokens; requests above that threshold have higher input/cache and output rates. GitHub Copilot also bills cache writes separately. Plan access differs: GPT-6 Sol and GPT-6.1 Sol require Pro+ or higher, Luna and Claude Sonnet 5.5 are available from Pro, and Claude Opus 5.5 requires Pro+ or higher.
|
|
157
158
|
|
|
158
159
|
> Detailed pricing, benchmark provenance, and model-specific notes live in [docs/pricing.md](docs/pricing.md) and [docs/benchmarks.md](docs/benchmarks.md). This page stays focused on setup and model selection. For a copy-paste config containing **all providers at once**, see [docs/example-config.md](docs/example-config.md).
|
|
159
160
|
|
|
@@ -214,7 +215,7 @@ GitHub ships a first-party MCP server (and it's even bundled into Copilot), so a
|
|
|
214
215
|
2. If the provider needs request rewriting, add a proxy under `proxy/`.
|
|
215
216
|
3. Submit a PR.
|
|
216
217
|
|
|
217
|
-
The current AA values come from OpenRouter's September
|
|
218
|
+
The current AA values come from OpenRouter's September 30 model metadata and ranking card; **every pricing cell comes from first-party provider pricing or GitHub Copilot's official billing table, never OpenRouter.** The OpenRouter ranking card places unversioned Qwen3.8 Max at **53.4 (#3)**, while the exact 0902 API metadata row is **45.4**. Qwen Cloud PAYG pricing remains **$2 / $0.25 implicit cache / $6** for Qwen3.8 Max; its separate Token Plan is not the PAYG rate table. This refresh records Gemini 3.8 Flash, Grok 4.7, GPT-6 Sol, GPT-6.1 Sol, GPT-6 Luna, Claude Opus 5.5, and Claude Sonnet 5.5 as **Copilot-native** models, using current AA v4.3.2 composites. GPT-6.1 Sol (released September 29) enters at **51.8**, and MiMo V2.6 Flash now has a composite (**37.9**).
|
|
218
219
|
|
|
219
220
|
- **Chat only.** Inline completions, semantic search, and next-edit suggestions still need a GitHub-hosted model.
|
|
220
221
|
- Each proxy is tuned for a specific provider family. Don't point the Kimi proxy at an arbitrary OpenAI-compatible endpoint.
|
package/docs/models/qwen.md
CHANGED
|
@@ -1,22 +1,23 @@
|
|
|
1
1
|
# Qwen (DashScope) — VS Code Custom Endpoint Setup Guide
|
|
2
2
|
|
|
3
|
-
> **TL;DR:** `qwen3.8-max` (vision) works both direct and via the local proxy. OpenRouter's live rankings card shows unversioned Qwen3.8 Max at **#
|
|
3
|
+
> **TL;DR:** `qwen3.8-max` (vision) works both direct and via the local proxy. OpenRouter's live rankings card shows unversioned Qwen3.8 Max at **#3 with 53.4**, while the exact `qwen/qwen3.8-max-0902` API metadata row is **45.4**; the public API no longer exposes the unversioned ID. The proxy forwards the upstream `model` value unchanged, so use the exact model ID supported by the endpoint you choose. The proxy gives you dynamic thinking suppression: reasoning stays ON in plain chat but turns OFF automatically when tools are invoked. The direct path is simpler if you don't need reasoning in chat. Use the **OpenAI-compatible** endpoint on your **workspace-dedicated** domain ([details](#which-endpoint-to-use)).
|
|
4
4
|
|
|
5
5
|
## At a Glance
|
|
6
6
|
|
|
7
|
-
| Field | Value
|
|
8
|
-
| ---------------------- |
|
|
9
|
-
| Mode | **Proxy** (local on `:3458`) **or** **Direct** (static `enable_thinking: false`)
|
|
10
|
-
| Billing | **Pay-as-You-Go only** — 1M-token free quota for new users
|
|
11
|
-
| Vision | ✅ Yes (`qwen3.8-max`)
|
|
12
|
-
| Tool calling | ✅ Yes
|
|
13
|
-
| Context | 1M
|
|
14
|
-
| Max output | 131K
|
|
15
|
-
|
|
|
16
|
-
|
|
|
17
|
-
|
|
|
18
|
-
|
|
|
19
|
-
| `requestBody` (
|
|
7
|
+
| Field | Value |
|
|
8
|
+
| ---------------------- | -------------------------------------------------------------------------------------------------- |
|
|
9
|
+
| Mode | **Proxy** (local on `:3458`) **or** **Direct** (static `enable_thinking: false`) |
|
|
10
|
+
| Billing | **Pay-as-You-Go only** — 1M-token free quota for new users |
|
|
11
|
+
| Vision | ✅ Yes (`qwen3.8-max`) |
|
|
12
|
+
| Tool calling | ✅ Yes |
|
|
13
|
+
| Context | 1M |
|
|
14
|
+
| Max output | 131K |
|
|
15
|
+
| Protocol | **OpenAI-compatible** (`/compatible-mode/v1`) — not native DashScope (`/api/v1`) |
|
|
16
|
+
| Endpoint | `https://<your-workspace-id>.ap-southeast-1.maas.aliyuncs.com/compatible-mode/v1/chat/completions` |
|
|
17
|
+
| Proxy endpoint | `http://127.0.0.1:3458/v1/chat/completions` |
|
|
18
|
+
| Auth | `Authorization: Bearer $DASHSCOPE_API_KEY` |
|
|
19
|
+
| `requestBody` (direct) | `enable_thinking: false` |
|
|
20
|
+
| `requestBody` (proxy) | _none — proxy injects based on tool activity_ |
|
|
20
21
|
|
|
21
22
|
### Models
|
|
22
23
|
|
|
@@ -28,32 +29,47 @@
|
|
|
28
29
|
|
|
29
30
|
### OpenRouter snapshot records
|
|
30
31
|
|
|
31
|
-
These are separate OpenRouter catalog entries, not
|
|
32
|
+
These are separate OpenRouter catalog entries, not alternative labels for one model:
|
|
32
33
|
|
|
33
|
-
| OpenRouter slug
|
|
34
|
-
|
|
|
35
|
-
| `qwen/qwen3.8-max`
|
|
36
|
-
| `qwen/qwen3.8-max-0902`
|
|
34
|
+
| OpenRouter slug | Snapshot | AA Intelligence Index | Notes |
|
|
35
|
+
| ------------------------ | -------- | --------------------- | ----------------------------------------------------------------------------- |
|
|
36
|
+
| `qwen/qwen3.8-max` | 0803 | **53.4 (#3)** | Current ranking-card result; exact unversioned API entry is no longer exposed |
|
|
37
|
+
| `qwen/qwen3.8-max-0902` | 0902 | **45.4** | September snapshot; current exact-ID API metadata |
|
|
38
|
+
| `qwen/qwen3.8-max-prime` | 0923 | — | Higher-throughput variant at 2× the 0902 rates; no AA composite yet |
|
|
37
39
|
|
|
38
40
|
The DashScope custom-endpoint snippets below use the provider model ID `qwen3.8-max`. Do not replace it with the OpenRouter `qwen/qwen3.8-max-0902` slug unless you also change the upstream URL to OpenRouter and have verified that path independently.
|
|
39
41
|
|
|
42
|
+
OpenRouter's `qwen/qwen3.8-max-prime` SKU (0923) is a higher-throughput variant billed at 2× the 0902 list rates (**$4 / $0.50 cache read / $12** per 1M tokens). No AA composite is published for it yet, and it is not part of the validated DashScope setup.
|
|
43
|
+
|
|
40
44
|
### Optional OpenRouter snapshot proxy
|
|
41
45
|
|
|
42
|
-
The proxy forwards the `model` field without mapping it, so it can also be pointed at OpenRouter for
|
|
46
|
+
The proxy forwards the `model` field without mapping it, so it can also be pointed at OpenRouter for these catalog entries. This is an **optional, unvalidated OpenRouter path**; it is separate from the validated DashScope setup above and requires an OpenRouter API key.
|
|
43
47
|
|
|
44
|
-
1.
|
|
48
|
+
1. Point the proxy at OpenRouter — pick **one** of these launch methods:
|
|
49
|
+
- **From the repo (`.env`):** add this to the repo-root `.env` file, then start the proxy with `npm run proxy:qwen`:
|
|
45
50
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
51
|
+
```dotenv
|
|
52
|
+
QWEN_UPSTREAM_URL=https://openrouter.ai/api/v1/chat/completions
|
|
53
|
+
```
|
|
49
54
|
|
|
50
|
-
|
|
55
|
+
> `npm run proxy:qwen` always runs with cwd = repo root, so the proxy's `import 'dotenv/config'` picks up this `.env` automatically.
|
|
51
56
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
57
|
+
- **Via npx:** `npx copilot-custom-endpoint qwen` forks the same proxy, but loads `.env` from **whatever directory you run it in**. If that directory has no `.env` with `QWEN_UPSTREAM_URL`, the proxy silently falls back to the legacy DashScope upstream and OpenRouter slugs like `qwen/qwen3.8-max` will fail against it. Either run it from a directory containing a suitable `.env`, or set the variable in the shell first (see next option). Note that `npx` runs the **published** package version, not your local working tree.
|
|
58
|
+
|
|
59
|
+
- **Inline env var (Git Bash / bash):** shell variables take precedence over `.env` (dotenv does not override variables already in `process.env`), so this works from any directory without editing `.env`:
|
|
55
60
|
|
|
56
|
-
|
|
61
|
+
```bash
|
|
62
|
+
QWEN_UPSTREAM_URL=https://openrouter.ai/api/v1/chat/completions npx copilot-custom-endpoint qwen
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
PowerShell equivalent:
|
|
66
|
+
|
|
67
|
+
```powershell
|
|
68
|
+
$env:QWEN_UPSTREAM_URL = 'https://openrouter.ai/api/v1/chat/completions'
|
|
69
|
+
npx copilot-custom-endpoint qwen
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
2. Add a separate provider group using the OpenRouter key and these model entries:
|
|
57
73
|
|
|
58
74
|
```json
|
|
59
75
|
{
|
|
@@ -81,6 +97,16 @@ The proxy forwards the `model` field without mapping it, so it can also be point
|
|
|
81
97
|
"streaming": true,
|
|
82
98
|
"maxInputTokens": 991000,
|
|
83
99
|
"maxOutputTokens": 131072
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"id": "qwen/qwen3.8-max-prime",
|
|
103
|
+
"name": "Qwen 3.8 Max Prime (0923)",
|
|
104
|
+
"url": "http://127.0.0.1:3458/v1/chat/completions",
|
|
105
|
+
"toolCalling": true,
|
|
106
|
+
"vision": true,
|
|
107
|
+
"streaming": true,
|
|
108
|
+
"maxInputTokens": 991000,
|
|
109
|
+
"maxOutputTokens": 131072
|
|
84
110
|
}
|
|
85
111
|
]
|
|
86
112
|
}
|
|
@@ -92,30 +118,38 @@ Set the API key through **Chat: Manage Language Models**, then verify the proxy
|
|
|
92
118
|
|
|
93
119
|
### With Proxy (recommended)
|
|
94
120
|
|
|
95
|
-
1. **
|
|
96
|
-
2. **
|
|
97
|
-
3. **
|
|
98
|
-
4. **
|
|
99
|
-
5. **
|
|
121
|
+
1. **Set the upstream:** add `QWEN_UPSTREAM_URL=https://<your-workspace-id>.ap-southeast-1.maas.aliyuncs.com/compatible-mode/v1/chat/completions` to the git-ignored repo-root `.env` ([why this endpoint](#which-endpoint-to-use)). Without it the proxy falls back to the legacy shared DashScope domain.
|
|
122
|
+
2. **Start the proxy:** `npm run proxy:qwen` (or `npx copilot-custom-endpoint qwen`).
|
|
123
|
+
3. **Use the proxy-path JSON snippet** below.
|
|
124
|
+
4. **Set your DashScope API key** via Command Palette → **Chat: Manage Language Models**.
|
|
125
|
+
5. **Configure the Utility Small Model** — Open Settings → search **"Chat: Utility Small Model"** → pick your fastest model (e.g., DeepSeek V4 Flash or MiMo V2.6 Flash). [Why?](../../README.md#4-configure-the-utility-small-model)
|
|
126
|
+
6. **Restart VS Code.** Reasoning will be visible in plain chat and suppressed on tool turns.
|
|
100
127
|
|
|
101
128
|
### Direct (no proxy)
|
|
102
129
|
|
|
103
|
-
1. **Use the direct-path JSON snippet** below.
|
|
130
|
+
1. **Use the direct-path JSON snippet** below and replace `<your-workspace-id>` in `url` with your workspace ID.
|
|
104
131
|
2. **Set your `DASHSCOPE_API_KEY`** via Command Palette → **Chat: Manage Language Models**.
|
|
105
132
|
3. **Configure the Utility Small Model** — Open Settings → search **"Chat: Utility Small Model"** → pick your fastest model (e.g., DeepSeek V4 Flash or MiMo V2.6 Flash). [Why?](../../README.md#4-configure-the-utility-small-model)
|
|
106
133
|
4. **Restart VS Code** and pick "Qwen 3.8 Max".
|
|
107
134
|
|
|
108
135
|
## Setup
|
|
109
136
|
|
|
110
|
-
###
|
|
137
|
+
### Which endpoint to use
|
|
138
|
+
|
|
139
|
+
Model Studio's **API Quick Access** dialog (shown once, right after you create a key) lists an **API Host**, an **OpenAI Compatible Endpoint**, and a **DashScope** URL. Two choices matter:
|
|
140
|
+
|
|
141
|
+
- **Protocol — OpenAI-compatible (`/compatible-mode/v1`).** VS Code's `chat-completions` custom endpoint and `proxy/qwen-proxy.mjs` speak the OpenAI Chat Completions schema. The **DashScope** card (`/api/v1`) is the native DashScope protocol (`input.messages` requests, `output.choices` responses, `{code, message, request_id}` errors) and does not work here.
|
|
142
|
+
- **Domain — workspace-dedicated (`<workspace-id>.<region>.maas.aliyuncs.com`).** Alibaba recommends it for production: higher concurrency, network isolation, and a 3600 s request timeout (600 s on the legacy DashScope domains, which Alibaba says stop supporting new features after September 30, 2026). The legacy domains still work, so existing setups keep running.
|
|
143
|
+
|
|
144
|
+
The chat URL is `https://` + domain + `/compatible-mode/v1/chat/completions`. Copy the domain from the API Quick Access dialog (or the **API Host** column on Workspace Management); the **OpenAI Compatible Endpoint** value plus `/chat/completions` gives the same URL.
|
|
111
145
|
|
|
112
|
-
|
|
146
|
+
| Region | Workspace-dedicated domain (recommended) | Legacy DashScope domain |
|
|
147
|
+
| ------------- | ------------------------------------------------------ | ----------------------------- |
|
|
148
|
+
| Singapore | `<your-workspace-id>.ap-southeast-1.maas.aliyuncs.com` | `dashscope-intl.aliyuncs.com` |
|
|
149
|
+
| China | `<your-workspace-id>.cn-beijing.maas.aliyuncs.com` | `dashscope.aliyuncs.com` |
|
|
150
|
+
| US (Virginia) | `<your-workspace-id>.us-east-1.maas.aliyuncs.com` | `dashscope-us.aliyuncs.com` |
|
|
113
151
|
|
|
114
|
-
|
|
115
|
-
| ------------- | ------------------------------------------------------------------------- |
|
|
116
|
-
| Singapore | `https://dashscope-intl.aliyuncs.com/compatible-mode/v1/chat/completions` |
|
|
117
|
-
| China | `https://dashscope.aliyuncs.com/compatible-mode/v1/chat/completions` |
|
|
118
|
-
| US (Virginia) | `https://dashscope-us.aliyuncs.com/compatible-mode/v1/chat/completions` |
|
|
152
|
+
API keys are bound to their region (and, on a workspace-dedicated domain, to their workspace); a mismatch returns `401 invalid_api_key`. Source: [Alibaba Cloud Model Studio — Regions and endpoints](https://www.alibabacloud.com/help/en/model-studio/regions).
|
|
119
153
|
|
|
120
154
|
### 1. VS Code configuration
|
|
121
155
|
|
|
@@ -137,7 +171,7 @@ DashScope is region-specific — your API key only works on the endpoint it was
|
|
|
137
171
|
{
|
|
138
172
|
"id": "qwen3.8-max",
|
|
139
173
|
"name": "Qwen 3.8 Max (vision)",
|
|
140
|
-
"url": "https
|
|
174
|
+
"url": "https://<your-workspace-id>.ap-southeast-1.maas.aliyuncs.com/compatible-mode/v1/chat/completions",
|
|
141
175
|
"toolCalling": true,
|
|
142
176
|
"vision": true,
|
|
143
177
|
"streaming": true,
|
|
@@ -200,6 +234,8 @@ DashScope is **Pay-as-You-Go only** — but new Model Studio users get **1M inpu
|
|
|
200
234
|
4. Paste your DashScope API key.
|
|
201
235
|
|
|
202
236
|
> VS Code replaces `"apiKey": ""` with a `${input:chat.lm.secret.<id>}` reference. Keys are region-specific.
|
|
237
|
+
>
|
|
238
|
+
> New keys start with `sk-ws-` and are shown only once, in the **API Quick Access** dialog — copy the key before closing it. Older `sk-` keys keep working.
|
|
203
239
|
|
|
204
240
|
## Local Proxy
|
|
205
241
|
|
|
@@ -217,12 +253,12 @@ The `proxy/qwen-proxy.mjs` adds dynamic thinking suppression on top of the direc
|
|
|
217
253
|
|
|
218
254
|
Set in `.env` at the repo root (the proxy `import 'dotenv/config'` automatically).
|
|
219
255
|
|
|
220
|
-
| Variable | Default
|
|
221
|
-
| ---------------------------------------- |
|
|
222
|
-
| `QWEN_PROXY_PORT` | `3458`
|
|
223
|
-
| `QWEN_UPSTREAM_URL` | `https://dashscope-intl.aliyuncs.com/compatible-mode/v1/chat/completions` | Upstream
|
|
224
|
-
| `QWEN_PROXY_LOG` | `debug_log/qwen-proxy.ndjson`
|
|
225
|
-
| `QWEN_PROXY_DISABLE_THINKING_WITH_TOOLS` | `1`
|
|
256
|
+
| Variable | Default | Purpose |
|
|
257
|
+
| ---------------------------------------- | ---------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- |
|
|
258
|
+
| `QWEN_PROXY_PORT` | `3458` | Local listen port |
|
|
259
|
+
| `QWEN_UPSTREAM_URL` | `https://dashscope-intl.aliyuncs.com/compatible-mode/v1/chat/completions` (legacy) | Upstream OpenAI-compatible endpoint — set to your workspace-dedicated URL (recommended) |
|
|
260
|
+
| `QWEN_PROXY_LOG` | `debug_log/qwen-proxy.ndjson` | Redacted NDJSON log path |
|
|
261
|
+
| `QWEN_PROXY_DISABLE_THINKING_WITH_TOOLS` | `1` | Set to `0` to skip tool-aware thinking suppression |
|
|
226
262
|
|
|
227
263
|
### What the proxy does
|
|
228
264
|
|
|
@@ -250,14 +286,15 @@ The proxy detects active tool use by examining the conversation state (a `"tool"
|
|
|
250
286
|
|
|
251
287
|
## Troubleshooting
|
|
252
288
|
|
|
253
|
-
| Symptom | Likely cause
|
|
254
|
-
| ----------------------------------------------- |
|
|
255
|
-
| "Connection refused" (proxy mode) | Proxy not running
|
|
256
|
-
| Tool loops fail with `reasoning_content` errors | Direct path missing `enable_thinking: false`
|
|
257
|
-
| Tool loops still fail with proxy | Proxy not rewriting
|
|
258
|
-
| Vision fails with external image URL | DashScope couldn't reach the URL
|
|
259
|
-
| 401 Unauthorized | API key region mismatch
|
|
260
|
-
|
|
|
289
|
+
| Symptom | Likely cause | Fix |
|
|
290
|
+
| ----------------------------------------------- | ---------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
|
|
291
|
+
| "Connection refused" (proxy mode) | Proxy not running | `npm run proxy:qwen` |
|
|
292
|
+
| Tool loops fail with `reasoning_content` errors | Direct path missing `enable_thinking: false` | Add `enable_thinking: false` to `requestBody` |
|
|
293
|
+
| Tool loops still fail with proxy | Proxy not rewriting | Check `debug_log/qwen-proxy.ndjson` — verify `hasTools: true` requests have `rewrittenEnableThinking: false` |
|
|
294
|
+
| Vision fails with external image URL | DashScope couldn't reach the URL | Use a base64 data URI instead |
|
|
295
|
+
| 401 Unauthorized | API key region or workspace mismatch | Match your key to the endpoint's region (and workspace, on a workspace-dedicated domain) |
|
|
296
|
+
| 404 Not Found | URL uses the native DashScope path (`/api/v1`) or omits the path | Use `/compatible-mode/v1/chat/completions` |
|
|
297
|
+
| Want to switch back to direct | Proxy mode active | Revert `url` to DashScope endpoint and restore `requestBody.enable_thinking: false` |
|
|
261
298
|
|
|
262
299
|
## Pricing
|
|
263
300
|
|
package/docs/pricing.md
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
# Pricing
|
|
2
2
|
|
|
3
|
-
> **Latest refresh (
|
|
3
|
+
> **Latest refresh (October 7, 2026):** targeted re-check of the two Qwen entries against OpenRouter's model metadata and ranking card. The rankings card now places unversioned Qwen3.8 Max at **#3** (53.4, tied on score with Claude Fable 5.1), the `qwen/qwen3.8-max-0902` metadata row still reports **45.4**, and OpenRouter lists a newer higher-throughput `qwen/qwen3.8-max-prime` SKU (0923) at **$4 / $0.50 cache read / $12** per 1M — it has no AA composite yet, so it carries no Cost per intelligence row (see [docs/models/qwen.md](models/qwen.md)). No table values changed.
|
|
4
|
+
>
|
|
5
|
+
> **Earlier refresh (September 30, 2026):** GPT-6.1 Sol (released September 29 at OpenAI DevDay; GA in GitHub Copilot the same day for Pro+, Max, Business, and Enterprise) is added at **$2 / $0.10 cache hit / $10** per 1M tokens — identical input/output to GPT-6 Sol, with cache hits at half the rate ($0.10 vs $0.20) — and an Artificial Analysis v4.3.2 composite of **51.8**, so at **~$0.0386** per intelligence point it sorts between Grok 4.6 and GPT-6 Sol. OpenAI cancelled the planned **GPT-6.1 Astra** over safety concerns, so no such row exists. Every other composite and first-party rate was re-checked against live OpenRouter metadata and provider pages with no changes.
|
|
6
|
+
>
|
|
7
|
+
> **Earlier refresh (September 29, 2026):** Claude Sonnet 5.5 (released September 28, GA in GitHub Copilot from Pro) is added at **$2 / $0.20 cache hit / $10** per 1M tokens, unchanged from Sonnet 5, with an Artificial Analysis v4.3.2 composite of **56.0**. MiMo V2.6 Flash now has a composite (**37.9**), so it is scored and sorted instead of listed last; at ~$0.0026 it is the lowest cost per intelligence in the table. All other first-party rates were re-verified with no changes.
|
|
4
8
|
>
|
|
5
9
|
> **Earlier refresh (September 23, 2026):** OpenRouter's current metadata uses Artificial Analysis v4.3.2 composites. The September 22 Copilot releases add Claude Opus 5.5 (**57.6**), GPT-6 Sol (**47.5**), and GPT-6 Luna (**37.3**) to the roster. The API list rates are **$4 / $0.20 cache hit / $20** for Opus 5.5, **$2 / $0.20 / $10** for Sol, and **$0.10 / $0.01 / $0.50** for Luna. MiMo V2.6 Pro is **46.3**, Grok 4.7 is **46.4**, and current values for existing rows are refreshed below. Gemini 3.8 Flash is also available as a GitHub Copilot native model. Xiaomi released the V2.6 Pro, Flash, and Pro UltraSpeed models on September 22; the September 23 roster cleanup removes two retired legacy models. xAI released Grok 4.7 on September 21 at the same short-context rates as Grok 4.6: **$2 / $0.50 cache hit / $6**. The table preserves Qwen's 0803 ranking-card value (**53.4**) and 0902 metadata value (**45.4**) as separate records. The current table is authoritative for present comparisons.
|
|
6
10
|
|
|
@@ -42,6 +46,7 @@ All models are listed together below, sorted by Cost per intelligence ascending
|
|
|
42
46
|
| **Qwen 3.8 Max (0902)** | DashScope | **~$0.0352** | **45.4** | $2.00 | $0.25 | $6.00 | ~$1.60 | 1M |
|
|
43
47
|
| **Claude Sonnet 5.5** | Anthropic | **~$0.0357** | **56.0** | $2.00 | $0.20 | $10.00 | ~$2.00 | 1M |
|
|
44
48
|
| **Grok 4.6** | xAI | **~$0.0361** | **44.3** | $2.00 | $0.50 | $6.00 | ~$1.60 | 500K |
|
|
49
|
+
| **GPT-6.1 Sol** | OpenAI | **~$0.0386** | **51.8** | $2.00 | $0.10 | $10.00 | ~$2.00 | 1M |
|
|
45
50
|
| **GPT-6 Sol** | OpenAI | **~$0.0421** | **47.5** | $2.00 | $0.20 | $10.00 | ~$2.00 | 1M |
|
|
46
51
|
| **GPT-5.6 Terra** | OpenAI | **~$0.0523** | **42.1** | $2.00 | $0.20 | $12.00 | ~$2.20 | 1M |
|
|
47
52
|
| **Claude Sonnet 5** | Anthropic | **~$0.0524** | **38.2** | $2.00 | $0.20 | $10.00 | ~$2.00 | 1M |
|
|
@@ -61,7 +66,7 @@ Cost per intelligence = estimated session cost ÷ Intelligence Index score. Sess
|
|
|
61
66
|
> - **DeepSeek** input pricing shown is the **peak cache miss** price. Peak cache hits are $0.006/M for V4.1 Flash and $0.044/M for Pro; off-peak rates are half. See the [DeepSeek pricing page](https://api-docs.deepseek.com/quick_start/pricing) for the full schedule.
|
|
62
67
|
> - **MiMo** input pricing shown is the **cache miss** price. Cache hits are essentially free for V2.6 Pro ($0.0036/M, ~120× cheaper), V2.6 Flash ($0.0028/M, ~50× cheaper), and V2.6 Pro UltraSpeed ($0.036/M, ~120× cheaper). A Xiaomi price cut took effect on 2026-05-27.
|
|
63
68
|
> - **Anthropic (Claude)** cache reads and cache writes are billed separately. Claude Opus 5.5 cache reads are $0.20/M; cache writes are $5/M for 5 minutes or $8/M for 1 hour. Fast mode costs $8/M input and $40/M output. Opus 5.5, Opus 5, Sonnet 5 / 5.5, and Fable 5 / 5.1 use a newer tokenizer that produces approximately 30% more tokens for the same text. Claude Sonnet 5.5 keeps Sonnet 5's $2 / $0.20 / $10 rates (cache writes $2.50/M for 5 minutes and $4/M for 1 hour; batch $1 / $5), and Anthropic made those rates permanent: the Sonnet 5 increase to $3 / $15 scheduled for September 1 was cancelled. Artificial Analysis measured Sonnet 5.5 at 138.7 tokens/s but very verbose (410M output tokens to run the Intelligence Index vs an 88M median), so real sessions can cost more than this table's modeled token counts; Anthropic reports up to 30% fewer tokens per task than Sonnet 5.
|
|
64
|
-
> - **OpenAI** models support cached input at 0.1× base input rate. GPT-6 Sol and Luna also bill cache writes separately at 1.25× input. The GPT-6 rows show standard rates through 272K input; for requests >272K, input and cache-read rates double and output is 1.5×.
|
|
69
|
+
> - **OpenAI** models support cached input at 0.1× base input rate — except **GPT-6.1 Sol**, whose cache hits are 0.05× ($0.10/M, half of GPT-6 Sol's $0.20/M). GPT-6 Sol, GPT-6.1 Sol, and Luna also bill cache writes separately at 1.25× input. The GPT-6 and GPT-6.1 rows show standard rates through 272K input; for requests >272K, input and cache-read rates double and output is 1.5×.
|
|
65
70
|
> - **Qwen** models use **tiered pricing** — determined by total input tokens per request. Prices above are for non-thinking mode.
|
|
66
71
|
> - **Kimi** official tables list **Cache Hit before Cache Miss** (opposite order to our table; Kimi K3 also bills cache writes separately at $3.00/M for a 5-minute TTL and $6.00/M for 1 hour). The rows below transpose them so "Input" = cache miss and "Cached input" = cache hit.
|
|
67
72
|
> - **DashScope** offers a **free quota** of 1M input + 1M output tokens per model, valid for 90 days.
|
|
@@ -73,7 +78,7 @@ Cost per intelligence = estimated session cost ÷ Intelligence Index score. Sess
|
|
|
73
78
|
|
|
74
79
|
> **How long does 7,000 credits last?** A Pro+ subscriber running 50-turn sessions can estimate monthly capacity by multiplying each modeled session cost by 100 to convert it to AI credits, then mixing models as needed.
|
|
75
80
|
|
|
76
|
-
> Prices last verified: September
|
|
81
|
+
> Prices last verified: September 30, 2026. Always check the official pages for the latest rates:
|
|
77
82
|
>
|
|
78
83
|
> - [GitHub Copilot models & pricing](https://docs.github.com/en/copilot/reference/copilot-billing/models-and-pricing)
|
|
79
84
|
> - [OpenAI pricing](https://openai.com/api/pricing/)
|
|
@@ -82,15 +87,18 @@ Cost per intelligence = estimated session cost ÷ Intelligence Index score. Sess
|
|
|
82
87
|
> - [OpenAI GPT-6 Sol and Luna announcement](https://openai.com/index/introducing-gpt-6-sol-and-luna/)
|
|
83
88
|
> - [OpenAI GPT-6 Sol API details](https://developers.openai.com/api/docs/models/gpt-6-sol)
|
|
84
89
|
> - [OpenAI GPT-6 Luna API details](https://developers.openai.com/api/docs/models/gpt-6-luna)
|
|
90
|
+
> - [OpenAI GPT-6.1 Sol announcement](https://openai.com/index/introducing-gpt-6-1-sol/)
|
|
91
|
+
> - [OpenAI GPT-6.1 Sol API details](https://developers.openai.com/api/docs/models/gpt-6.1-sol)
|
|
85
92
|
> - [Anthropic (Claude) pricing](https://platform.claude.com/docs/en/about-claude/pricing)
|
|
86
93
|
> - [Anthropic Claude Opus 5.5 announcement](https://www.anthropic.com/claude-opus-5-5)
|
|
87
94
|
> - [Anthropic Opus 5.5 API docs](https://platform.claude.com/docs/en/models/opus-5-5/overview)
|
|
88
95
|
> - [Anthropic Claude Sonnet 5.5 announcement](https://www.anthropic.com/claude-sonnet-5-5)
|
|
89
96
|
> - [GitHub Copilot Claude Sonnet 5.5 release](https://github.blog/changelog/2026-09-28-claude-sonnet-5-5-in-github-copilot)
|
|
90
97
|
> - [GitHub Copilot GPT-6 Sol and Luna release](https://github.blog/changelog/2026-09-22-openais-gpt-6-sol-and-gpt-6-luna-now-available)
|
|
98
|
+
> - [GitHub Copilot GPT-6.1 Sol release](https://github.blog/changelog/2026-09-29-gpt-6-1-sol-in-github-copilot)
|
|
91
99
|
> - [GitHub Copilot Claude Opus 5.5 release](https://github.blog/changelog/2026-09-22-claude-opus-5-5-is-now-available-in-github-copilot)
|
|
92
100
|
> - [GitHub Copilot supported models](https://docs.github.com/en/copilot/reference/ai-models/supported-models)
|
|
93
|
-
> - [Artificial Analysis GPT-6 Sol](https://artificialanalysis.ai/models/gpt-6-sol), [GPT-6 Luna](https://artificialanalysis.ai/models/gpt-6-luna), [Claude Opus 5.5](https://artificialanalysis.ai/models/claude-opus-5-5), [Claude Sonnet 5.5](https://artificialanalysis.ai/models/claude-sonnet-5-5), and [MiMo-V2.6-Flash](https://artificialanalysis.ai/models/mimo-v2-6-flash)
|
|
101
|
+
> - [Artificial Analysis GPT-6 Sol](https://artificialanalysis.ai/models/gpt-6-sol), [GPT-6 Luna](https://artificialanalysis.ai/models/gpt-6-luna), [GPT-6.1 Sol](https://artificialanalysis.ai/models/gpt-6-1-sol), [Claude Opus 5.5](https://artificialanalysis.ai/models/claude-opus-5-5), [Claude Sonnet 5.5](https://artificialanalysis.ai/models/claude-sonnet-5-5), and [MiMo-V2.6-Flash](https://artificialanalysis.ai/models/mimo-v2-6-flash)
|
|
94
102
|
> - [Google Gemini pricing](https://ai.google.dev/pricing)
|
|
95
103
|
> - [DashScope pricing](https://www.alibabacloud.com/help/en/model-studio/billing-for-model-studio)
|
|
96
104
|
> - [DeepSeek pricing](https://api-docs.deepseek.com/quick_start/pricing)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "copilot-custom-endpoint",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.4.1",
|
|
4
4
|
"description": "Local proxies for VS Code Copilot custom endpoints — Kimi K2, Qwen 3.x & MiMo V2.6",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -57,4 +57,4 @@
|
|
|
57
57
|
"dependencies": {
|
|
58
58
|
"dotenv": "^17.4.2"
|
|
59
59
|
}
|
|
60
|
-
}
|
|
60
|
+
}
|
package/proxy/qwen-proxy.mjs
CHANGED
|
@@ -41,9 +41,11 @@ ID qwen3.8-max and OpenRouter ID qwen/qwen3.8-max-0902.
|
|
|
41
41
|
|
|
42
42
|
Environment variables:
|
|
43
43
|
QWEN_PROXY_PORT Local listen port. Default: 3458 (falls back to PORT)
|
|
44
|
-
QWEN_UPSTREAM_URL Upstream chat-completions URL (
|
|
45
|
-
|
|
46
|
-
|
|
44
|
+
QWEN_UPSTREAM_URL Upstream chat-completions URL (OpenAI-compatible path).
|
|
45
|
+
Recommended: your workspace-dedicated endpoint, e.g.
|
|
46
|
+
https://<workspace-id>.ap-southeast-1.maas.aliyuncs.com/compatible-mode/v1/chat/completions
|
|
47
|
+
OpenRouter can be selected for snapshot IDs.
|
|
48
|
+
Default (legacy shared domain): https://dashscope-intl.aliyuncs.com/compatible-mode/v1/chat/completions
|
|
47
49
|
QWEN_PROXY_DISABLE_THINKING_WITH_TOOLS
|
|
48
50
|
Inject enable_thinking: false when tools are present.
|
|
49
51
|
Default: 1
|