codeep 3.2.2 → 3.3.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.
@@ -19,7 +19,7 @@ export const PROVIDERS = {
19
19
  },
20
20
  models: [
21
21
  { id: 'glm-5.3', name: 'GLM-5.3', description: 'Latest flagship for project-scale engineering (1M context)' },
22
- { id: 'glm-5.3-flash', name: 'GLM-5.3 Flash', description: 'Same 1M context at a twentieth of the price' },
22
+ { id: 'glm-5.3-flash', name: 'GLM-5.3 Flash', description: 'Same 1M context at roughly a ninth of the price' },
23
23
  { id: 'glm-5.2', name: 'GLM-5.2', description: 'Previous flagship for project-scale engineering (1M context)' },
24
24
  { id: 'glm-5-turbo', name: 'GLM-5 Turbo', description: 'Fast GLM-5 variant, available to all users' },
25
25
  ],
@@ -53,7 +53,7 @@ export const PROVIDERS = {
53
53
  // (`z.ai-cn*`) bills separately and is not covered by that page, so it is
54
54
  // left alone until its own listing is checked.
55
55
  { id: 'glm-5.3', name: 'GLM-5.3', description: 'Latest flagship for project-scale engineering (1M context)' },
56
- { id: 'glm-5.3-flash', name: 'GLM-5.3 Flash', description: 'Same 1M context at a twentieth of the price' },
56
+ { id: 'glm-5.3-flash', name: 'GLM-5.3 Flash', description: 'Same 1M context at roughly a ninth of the price' },
57
57
  { id: 'glm-5.2', name: 'GLM-5.2', description: 'Previous flagship for project-scale engineering (1M context)' },
58
58
  { id: 'glm-5-turbo', name: 'GLM-5 Turbo', description: 'Fast GLM-5 variant' },
59
59
  ],
@@ -80,11 +80,14 @@ export const PROVIDERS = {
80
80
  supportsNativeTools: true,
81
81
  },
82
82
  },
83
+ // GLM-5.3 is on the China gateway and the China Coding Plan (bigmodel.cn).
84
+ // Flash is listed only on China pay-per-use, so the plan does not offer it.
83
85
  models: [
84
- { id: 'glm-5.2', name: 'GLM-5.2', description: 'Latest flagship for project-scale engineering (1M context)' },
86
+ { id: 'glm-5.3', name: 'GLM-5.3', description: 'Latest flagship for project-scale engineering (1M context)' },
87
+ { id: 'glm-5.2', name: 'GLM-5.2', description: 'Previous flagship for project-scale engineering (1M context)' },
85
88
  { id: 'glm-5-turbo', name: 'GLM-5 Turbo', description: 'Fast GLM-5 variant, available to all users' },
86
89
  ],
87
- defaultModel: 'glm-5.2',
90
+ defaultModel: 'glm-5.3',
88
91
  defaultProtocol: 'openai',
89
92
  maxOutputTokens: 131_072,
90
93
  envKey: 'ZAI_CN_API_KEY',
@@ -109,10 +112,12 @@ export const PROVIDERS = {
109
112
  },
110
113
  },
111
114
  models: [
112
- { id: 'glm-5.2', name: 'GLM-5.2', description: 'Latest flagship for project-scale engineering (1M context)' },
115
+ { id: 'glm-5.3', name: 'GLM-5.3', description: 'Latest flagship for project-scale engineering (1M context)' },
116
+ { id: 'glm-5.3-flash', name: 'GLM-5.3 Flash', description: 'Same 1M context at a tenth of the price' },
117
+ { id: 'glm-5.2', name: 'GLM-5.2', description: 'Previous flagship for project-scale engineering (1M context)' },
113
118
  { id: 'glm-5-turbo', name: 'GLM-5 Turbo', description: 'Fast GLM-5 variant' },
114
119
  ],
115
- defaultModel: 'glm-5.2',
120
+ defaultModel: 'glm-5.3',
116
121
  defaultProtocol: 'openai',
117
122
  maxOutputTokens: 131_072,
118
123
  envKey: 'ZAI_CN_API_KEY',
@@ -207,11 +212,19 @@ export const PROVIDERS = {
207
212
  supportsNativeTools: true,
208
213
  },
209
214
  },
215
+ // One model. DeepSeek's own pricing page names `deepseek-flash` (V4.1 Flash)
216
+ // as the model to use and says it outperforms V4 Pro. `deepseek-v4-flash`
217
+ // is already served by it, and from 2026-09-14 12:00 Beijing time every
218
+ // `deepseek-v4-pro` request is routed to it and billed at its price until
219
+ // a V4.1 Pro exists — so a Pro entry would be a label on a different model.
220
+ // Both old ids migrate via RETIRED_MODEL_REPLACEMENTS.
221
+ //
222
+ // Note the id differs on OpenRouter, which lists the same model as
223
+ // `deepseek/deepseek-v4.1-flash`.
210
224
  models: [
211
- { id: 'deepseek-v4-pro', name: 'DeepSeek V4 Pro', description: 'Most capable DeepSeek model (1M context, thinking mode)' },
212
- { id: 'deepseek-v4-flash', name: 'DeepSeek V4 Flash', description: 'Fast and affordable DeepSeek model (1M context)' },
225
+ { id: 'deepseek-flash', name: 'DeepSeek V4.1 Flash', description: 'Current DeepSeek model — thinking on by default, vision, 1M context, 384K output' },
213
226
  ],
214
- defaultModel: 'deepseek-v4-pro',
227
+ defaultModel: 'deepseek-flash',
215
228
  defaultProtocol: 'openai',
216
229
  maxOutputTokens: 384_000, // DeepSeek V4 max output
217
230
  envKey: 'DEEPSEEK_API_KEY',
@@ -344,12 +357,17 @@ export const PROVIDERS = {
344
357
  protocols: {
345
358
  openai: { baseUrl: 'https://dashscope-intl.aliyuncs.com/compatible-mode/v1', authHeader: 'Bearer', supportsNativeTools: true },
346
359
  },
360
+ // 3.8 Max and Flash are GA on Model Studio international and cost less
361
+ // than the 3.7 Max / 3.6 Flash they sit above. China (`qwen-cn-api`) is a
362
+ // separate listing and is not changed on this evidence.
347
363
  models: [
348
- { id: 'qwen3.7-max', name: 'Qwen3.7-Max', description: 'Latest flagship for complex coding and reasoning' },
364
+ { id: 'qwen3.8-max', name: 'Qwen3.8-Max', description: 'Latest flagship for complex coding and reasoning (1M context)' },
365
+ { id: 'qwen3.8-flash', name: 'Qwen3.8-Flash', description: 'Low-latency, low-cost multimodal model (1M context)' },
366
+ { id: 'qwen3.7-max', name: 'Qwen3.7-Max', description: 'Previous flagship for complex coding and reasoning' },
349
367
  { id: 'qwen3.7-plus', name: 'Qwen3.7-Plus', description: 'Balanced quality, speed, and price (1M context)' },
350
- { id: 'qwen3.6-flash', name: 'Qwen3.6-Flash', description: 'Low-latency, low-cost multimodal model' },
368
+ { id: 'qwen3.6-flash', name: 'Qwen3.6-Flash', description: 'Previous low-latency, low-cost multimodal model' },
351
369
  ],
352
- defaultModel: 'qwen3.7-max',
370
+ defaultModel: 'qwen3.8-max',
353
371
  defaultProtocol: 'openai',
354
372
  maxOutputTokens: 65_536,
355
373
  noStreamWithTools: true,
@@ -535,12 +553,17 @@ export const PROVIDERS = {
535
553
  { id: 'anthropic/claude-fable-5', name: 'Claude Fable 5', description: 'Anthropic — superseded by 5.1' },
536
554
  { id: 'anthropic/claude-opus-5', name: 'Claude Opus 5', description: 'Anthropic — flagship Opus tier' },
537
555
  { id: 'anthropic/claude-sonnet-5', name: 'Claude Sonnet 5', description: 'Anthropic — balanced' },
556
+ { id: 'openai/gpt-6-astra', name: 'GPT-6 Astra', description: 'OpenAI — frontier' },
538
557
  { id: 'openai/gpt-5.6-sol', name: 'GPT-5.6 Sol', description: 'OpenAI — flagship' },
539
558
  { id: 'openai/gpt-5.6-luna', name: 'GPT-5.6 Luna', description: 'OpenAI — fast/efficient' },
540
- { id: 'google/gemini-3.7-flash', name: 'Gemini 3.7 Flash', description: 'Google — latest production Flash' },
541
- { id: 'deepseek/deepseek-v4-pro', name: 'DeepSeek V4 Pro', description: 'DeepSeek — flagship agentic model' },
559
+ { id: 'google/gemini-3.8-flash', name: 'Gemini 3.8 Flash', description: 'Google — latest production Flash' },
560
+ { id: 'google/gemini-3.7-flash', name: 'Gemini 3.7 Flash', description: 'Google — previous production Flash' },
561
+ { id: 'deepseek/deepseek-v4.1-flash', name: 'DeepSeek V4.1 Flash', description: 'DeepSeek — current model' },
542
562
  { id: 'moonshotai/kimi-k3', name: 'Kimi K3', description: 'Moonshot — long-horizon coding' },
543
- { id: 'qwen/qwen3.8-max', name: 'Qwen 3.8 Max', description: 'Alibaba — latest flagship' },
563
+ // Dated on purpose: OpenRouter lists only the snapshot. The undated
564
+ // `qwen/qwen3.8-max` this used to carry does not exist there, so picking
565
+ // it before the live catalogue loaded was an error.
566
+ { id: 'qwen/qwen3.8-max-0902', name: 'Qwen 3.8 Max', description: 'Alibaba — latest flagship' },
544
567
  { id: 'x-ai/grok-4.6', name: 'Grok 4.6', description: 'xAI — flagship reasoning' },
545
568
  ],
546
569
  defaultModel: 'openrouter/auto',
@@ -607,6 +630,13 @@ const RETIRED_MODEL_REPLACEMENTS = {
607
630
  google: {
608
631
  'gemini-3.1-flash-lite': 'gemini-3.5-flash-lite',
609
632
  },
633
+ // DeepSeek named V4.1 Flash the model to use: the V4 Flash ids are retired
634
+ // and served by it, and V4 Pro is routed to it from 2026-09-14.
635
+ deepseek: {
636
+ 'deepseek-v4-flash': 'deepseek-flash',
637
+ 'deepseek-v4-flash-vision-exp': 'deepseek-flash',
638
+ 'deepseek-v4-pro': 'deepseek-flash',
639
+ },
610
640
  grok: {
611
641
  'grok-code-fast-1': 'grok-build-0.1',
612
642
  'grok-4-fast-reasoning': 'grok-4.3',
@@ -848,7 +878,10 @@ export function modelSupportsReasoningEffort(providerId, model) {
848
878
  // Gemini 3.x thinking_level via the OpenAI-compat reasoning_effort mapping.
849
879
  return id.startsWith('gemini-3');
850
880
  case 'deepseek':
851
- return id.startsWith('deepseek-v4');
881
+ // `deepseek-flash` does not start with `deepseek-v4` — a prefix check
882
+ // alone would ship the current model with /thinking hidden, the same
883
+ // trap GPT-6 nearly fell into behind `gpt-5`.
884
+ return id.startsWith('deepseek-v4') || idMatches(id, 'deepseek-flash');
852
885
  case 'z.ai':
853
886
  case 'z.ai-api':
854
887
  case 'z.ai-cn':
@@ -908,7 +941,12 @@ export function reasoningParamsFor(providerId, model, tier) {
908
941
  // 'minimal' is deliberately not emitted: 3.7 Flash rejects it outright.
909
942
  return { reasoning_effort: tier === 'max' ? 'high' : tier };
910
943
  case 'deepseek':
911
- // Graded thinking depth: high (default) or max. Lower tiers collapse to high.
944
+ // V4.1 Flash distinguishes low / high / max (DeepSeek's mapping table:
945
+ // minimal+low→low, medium+high+xhigh→high, max+ultra→max). The retired V4
946
+ // ids graded only high|max. Always an effort, never a disabled block.
947
+ if (idMatches(canonicalModelId(model), 'deepseek-flash')) {
948
+ return { reasoning_effort: tier === 'low' ? 'low' : tier === 'max' ? 'max' : 'high' };
949
+ }
912
950
  return { reasoning_effort: tier === 'max' ? 'max' : 'high' };
913
951
  case 'z.ai':
914
952
  case 'z.ai-api':
@@ -959,7 +997,9 @@ export function availableReasoningTiers(providerId, model) {
959
997
  // coding, so collapsing it hid the setting most users want.
960
998
  return ['auto', 'low', 'medium', 'high'];
961
999
  case 'deepseek':
962
- return ['auto', 'high', 'max'];
1000
+ return idMatches(canonicalModelId(model), 'deepseek-flash')
1001
+ ? ['auto', 'low', 'high', 'max']
1002
+ : ['auto', 'high', 'max'];
963
1003
  case 'z.ai':
964
1004
  case 'z.ai-api':
965
1005
  case 'z.ai-cn':
@@ -30,6 +30,7 @@ const MODEL_CONTEXT_WINDOWS = {
30
30
  'claude-sonnet-5': 1_000_000,
31
31
  'claude-haiku-4-5-20251001': 200_000,
32
32
  // DeepSeek
33
+ 'deepseek-flash': 1_000_000,
33
34
  'deepseek-v4-pro': 1_000_000,
34
35
  'deepseek-v4-flash': 1_000_000,
35
36
  // Google
@@ -43,7 +44,7 @@ const MODEL_CONTEXT_WINDOWS = {
43
44
  // MiniMax
44
45
  'MiniMax-M3': 1_000_000,
45
46
  // Kimi (Moonshot) — 1M on K3, 256K across K2.x
46
- 'kimi-k3': 1_000_000,
47
+ 'kimi-k3': 1_048_576,
47
48
  'kimi-k2.7-code': 262_144,
48
49
  'kimi-k2.7-code-highspeed': 262_144,
49
50
  'kimi-k2.6': 262_144,
@@ -59,6 +60,8 @@ const MODEL_CONTEXT_WINDOWS = {
59
60
  'grok-code-fast-1': 256_000,
60
61
  'grok-4-fast-reasoning': 2_000_000,
61
62
  // Qwen (Alibaba) — current hosted generation
63
+ 'qwen3.8-max': 1_000_000,
64
+ 'qwen3.8-flash': 1_000_000,
62
65
  'qwen3.7-max': 1_000_000,
63
66
  'qwen3.8-max-preview': 1_000_000,
64
67
  'qwen3.7-plus': 1_000_000,
@@ -93,10 +96,14 @@ const MODEL_PRICING = {
93
96
  'glm-5.1': { inputPer1M: 1.40, outputPer1M: 4.40 },
94
97
  'glm-5-turbo': { inputPer1M: 1.20, outputPer1M: 4.00 },
95
98
  // OpenAI
96
- // Twice the price of 5.6 Sol. Cached reads are $1.00/M — 0.1x input, which is
99
+ // 2.5x 5.6 Sol at its current promotional rate. Cached reads are $1.00/M — 0.1x input, which is
97
100
  // what DEFAULT_CACHE_READ_RATE already applies, so no model row is needed.
98
101
  'gpt-6-astra': { inputPer1M: 10.00, outputPer1M: 50.00 },
99
- 'gpt-5.6-sol': { inputPer1M: 5.00, outputPer1M: 30.00 },
102
+ // Promotional rate "available at least through 2026-11-21" per OpenAI's
103
+ // pricing page. Carried because it is what users are billed now, and no end
104
+ // date is written ahead of time — the Sonnet 5 lesson. Long-context requests
105
+ // bill 8/30; like every row here this holds the standard short-context tier.
106
+ 'gpt-5.6-sol': { inputPer1M: 4.00, outputPer1M: 20.00 },
100
107
  'gpt-5.6-terra': { inputPer1M: 2.00, outputPer1M: 12.00 },
101
108
  'gpt-5.6-luna': { inputPer1M: 0.20, outputPer1M: 1.20 },
102
109
  'gpt-5.5': { inputPer1M: 5.00, outputPer1M: 30.00 },
@@ -116,8 +123,19 @@ const MODEL_PRICING = {
116
123
  // honest direction for a cost estimate, and rule 5 of the catalogue policy
117
124
  // allows a clearly-labelled conservative approximation but never an invented
118
125
  // number. Cache-miss input; cache hits are ~1/50th and not modelled here.
119
- 'deepseek-v4-pro': { inputPer1M: 0.435, outputPer1M: 0.87 },
120
- 'deepseek-v4-flash': { inputPer1M: 0.14, outputPer1M: 0.28 },
126
+ // DeepSeek bills peak / off-peak (off-peak is half), and this table holds one
127
+ // rate, so it carries PEAK — an over-estimate by design. The previous rows
128
+ // (0.435/0.87 and 0.14/0.28) were two to four and a half times below today's
129
+ // peak and so under-reported, which is the one direction this table must not
130
+ // err in. Cache hits cost 2% of a miss, but DeepSeek reports them as
131
+ // `prompt_cache_hit_tokens`, which this tracker does not read — so every input
132
+ // token bills at the miss rate: an over-estimate again, not a gap.
133
+ 'deepseek-flash': { inputPer1M: 0.30, outputPer1M: 1.20 },
134
+ // Retired V4 Flash is served by V4.1 Flash and billed at its price.
135
+ 'deepseek-v4-flash': { inputPer1M: 0.30, outputPer1M: 1.20 },
136
+ // Pro's own peak rate, right for every run until 2026-09-14; after that the id
137
+ // is routed to Flash, and configs holding it have been migrated away from it.
138
+ 'deepseek-v4-pro': { inputPer1M: 1.32, outputPer1M: 3.96 },
121
139
  // Google
122
140
  // Gemini 3.6/3.7/3.8 Flash carry PROMOTIONAL rates that run through 2026-12-31
123
141
  // and are scheduled to step up to 1.50/7.50 on 2027-01-01 — revisit all three
@@ -132,7 +150,10 @@ const MODEL_PRICING = {
132
150
  'gemini-3.5-flash-lite': { inputPer1M: 0.30, outputPer1M: 2.50 },
133
151
  'gemini-3-flash-preview': { inputPer1M: 0.50, outputPer1M: 3.00 },
134
152
  // MiniMax
135
- 'MiniMax-M3': { inputPer1M: 0.60, outputPer1M: 2.40 },
153
+ // "Permanent 50% off" list price for prompts up to 512K tokens; above that,
154
+ // 0.60/2.40. The old 0.60/2.40 row was the long-context tier and doubled the
155
+ // estimate for virtually every real request.
156
+ 'MiniMax-M3': { inputPer1M: 0.30, outputPer1M: 1.20 },
136
157
  // Kimi (Moonshot) — pay-per-use cache-miss rates; `kimi-for-coding` is the
137
158
  // subscription alias (flat-fee in reality, priced notionally like K2.7 Code).
138
159
  'kimi-k3': { inputPer1M: 3.00, outputPer1M: 15.00 },
@@ -160,6 +181,8 @@ const MODEL_PRICING = {
160
181
  // `qwen3.8-max-preview` is Token-Plan-only (credit-metered, promotional
161
182
  // preview rate); Alibaba publishes no pay-per-use per-token price for it.
162
183
  // Leave it unpriced rather than borrowing the GA qwen3.8-max rate.
184
+ 'qwen3.8-max': { inputPer1M: 2.00, outputPer1M: 6.00 },
185
+ 'qwen3.8-flash': { inputPer1M: 0.15, outputPer1M: 0.47 },
163
186
  'qwen3.7-max': { inputPer1M: 2.50, outputPer1M: 7.50 },
164
187
  'qwen3.7-plus': { inputPer1M: 0.40, outputPer1M: 1.60 },
165
188
  'qwen3.6-plus': { inputPer1M: 0.40, outputPer1M: 2.40 },
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const VERSION = "3.2.2";
1
+ export declare const VERSION = "3.3.0";
package/dist/version.js CHANGED
@@ -1,4 +1,4 @@
1
1
  // AUTO-GENERATED by scripts/gen-version.js — do not edit by hand.
2
2
  // Baked from package.json at build time so the bun-compiled binary reports
3
3
  // the right version (it has no package.json on disk to read at runtime).
4
- export const VERSION = '3.2.2';
4
+ export const VERSION = '3.3.0';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codeep",
3
- "version": "3.2.2",
3
+ "version": "3.3.0",
4
4
  "description": "AI-powered coding assistant built for the terminal. Multiple LLM providers, project-aware context, and a seamless development workflow.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",