@kenz1117/dsh-ui-usage-billing 1.0.1 → 1.0.3

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.en.md CHANGED
@@ -21,6 +21,8 @@
21
21
 
22
22
  ---
23
23
 
24
+ > **Qwen family pricing update (2026-08-27)**: aligned with the latest Alibaba Cloud Model Studio list prices — **Qwen3.7-Max** corrected to official list price (input ¥12 / explicit-cache hit ¥1.2 / output ¥36, previously recorded at the discounted promo rate). The current official 50%-off promotion has **no announced end date**: the rate table shows the discounted price with a red promo badge (hover for details), and resumes list-price display once an end date is filled in after the announcement. The Qwen family also gains **supplementary pricing reference rows** (Batch File standing half-price tier, Batch Chat, explicit-cache create/hit — display-only, excluded from estimation); Qwen3-Coder Plus officially does not support batch inference, so only the explicit-cache rows are listed.
25
+
24
26
  > **Peak/off-peak pricing update (from 2026-08-23 (Sun) 00:00 Beijing)**: DeepSeek models follow the new official rule — **weekdays (Mon–Fri)** keep the original peak/off-peak split (peak 09:00–12:00 / 14:00–18:00, ×2); **weekends (Sat/Sun)** are no longer split and are billed at the **off-peak price** all day. The plugin's billing engine, rate table and per-turn peak/off-peak bands all reflect this.
25
27
 
26
28
  <div align="center">
package/README.md CHANGED
@@ -21,6 +21,8 @@
21
21
 
22
22
  ---
23
23
 
24
+ > **千问(Qwen)系列价格更新(2026-08-27)**:对齐阿里云百炼最新官方刊例——**Qwen3.7-Max** 更正为官方原价(输入 ¥12 / 显式缓存命中 ¥1.2 / 输出 ¥36,此前误录活动折后价),当前官方限时 5 折且**未公布截止时间**,费率表按折后价显示并挂红色促销徽章(悬停提示活动性质),公告截止后补填日期即自动恢复原价展示;Qwen 全系补充**附加计价参考行**(Batch File 长期半价档、Batch Chat、显式缓存创建/命中,纯展示不参与估算计费);Qwen3-Coder Plus 官方明确不支持批量推理,仅列显式缓存两行。
25
+
24
26
  > **峰谷计费规则更新(自 2026-08-23(周日)00:00 起)**:DeepSeek 模型按官方新规计费——**工作日(周一至周五)** 继续执行原峰谷分段计费(高峰 09:00–12:00 / 14:00–18:00,×2);**周末(周六、周日)** 全天不再区分峰谷时段,统一按**低谷价**计费。插件计费引擎、费率表与每轮费用峰谷分带均已同步生效。
25
27
 
26
28
  <div align="center">
@@ -142,31 +144,39 @@ cost(CNY)= (missInput × p_input + cacheHit × p_cacheHit + output × p_outp
142
144
 
143
145
  统计中的 `input` 为总输入(cacheHit + cacheMiss),估算按命中 / 未命中分拆计价,避免重复计费。支持双档计费的模型按 `DEFAULT_PEAK_SHARE`(默认 0.5)混合高峰与低谷档;周末(北京时间周六 / 周日)全天按低谷价计费。
144
146
 
145
- ### 支持模型(2026-08-21 主流阵容,OpenAI 兼容系列)
146
-
147
- | 厂商 | 模型 |
148
- | -------- | --------------------------------------------------------------------------------------- |
149
- | DeepSeek | V4 Flash、V4 Flash Vision (Exp)、V4 Pro(按时段峰谷计费:工作日高峰 09:00-12:00 / 14:00-18:00 北京 = 低谷 2 倍;周末全天低谷) |
150
- | 智谱 AI | GLM-5.3、GLM-5.2、GLM-5.1、GLM-5-Turbo、GLM-4.7、GLM-4.6、GLM-4.5-Air、GLM-5V-Turbo |
151
- | 阿里通义 | Qwen3.8 MaxQwen3.7-Max、Qwen3.5-Plus、Qwen3.5-Flash |
152
- | 字节豆包 | Doubao Seed-2.0 ProSeed-2.0 Mini、Seed-1.6 |
153
- | 月之暗面 | Kimi K3K2.7 Code、K2.7 Code HighSpeed、K2.6 |
154
- | 小米 | MiMo V2.5(走 token plan 订阅通道时豁免计费)¹ |
155
- | MiniMax | MiniMax-M3MiniMax-M2.7、MiniMax-M2.7-highspeed |
156
- | 百度 | ERNIE-5.1 |
157
- | 腾讯 | 混元 T1、混元 Hy3 |
158
- | 零一万物 | Yi-Lightning |
159
- | 阶跃星辰 | Step 3.7 Flash |
160
- | 科大讯飞 | Spark 4.0 Ultra(套餐制)¹ |
161
- | 商汤 | SenseNova 6.5(公测中)¹ |
162
- | 百川智能 | Baichuan M3-Plus |
163
- | OpenAI | GPT-5.6 Sol / Terra / Luna |
164
- | Google | Gemini 3.1 Pro、3.6 Flash(Standard / Flex 双档,Flex = -50%) |
165
- | xAI | Grok 4.6、Grok 4.3 |
166
- | Meta | Llama 4 Maverick、Scout |
167
- | 其他 | 未收录模型的统一回退定价 |
168
-
169
- > ¹ 讯飞、商汤、小米未公布按量单价,表内为估算价;这些模型走订阅通道(coding / token plan / opencode)时费用记 0,正式定价公布后自动校准。订阅通道与 pi-ai 内置提供方对齐(kimi-coding、zai-coding-cn、opencode、opencode-go、qwen/xiaomi 的 token-plan 各区域变体),可按 `subscriptionProviders` 配置覆盖。
147
+ ### 支持模型(2026-08 主流阵容,OpenAI 兼容系列,共 73 款)
148
+
149
+ 完整目录见费率 Tab 及源码 `src/client/pricing.ts` 的 `MODEL_CATALOG`,此处每厂商仅列代表型号。
150
+
151
+ | 厂商 | 代表模型 |
152
+ | -------- | -------------------------------------------- |
153
+ | DeepSeek | V4 FlashV4 Pro(等 3 款;峰谷计费:工作日高峰 ×2、周末全天低谷) |
154
+ | 智谱 AI | GLM-5.3GLM-5.2(等 10 款) |
155
+ | 阿里通义 | Qwen3.8 MaxQwen3-Coder 480B(等 7 款) |
156
+ | 字节豆包 | Doubao Seed-2.1 Pro、Doubao-Seed-Evolving(等 8 款) |
157
+ | 月之暗面 | Kimi K3Kimi K2.7 Code(等 9 款) |
158
+ | 小米 | MiMo V2.5(等 2 款)¹ |
159
+ | MiniMax | MiniMax-M3、MiniMax-M2.7(等 3 款) |
160
+ | 百度文心 | ERNIE-5.1、ERNIE-4.5 300B(等 2 款) |
161
+ | 腾讯混元 | 混元 T1、混元 Hy3(等 2 款) |
162
+ | Anthropic | Claude Opus 4.6、Claude Sonnet 4.6(等 5 款) |
163
+ | Mistral AI | Mistral Large 3、Mistral Small 4(等 3 款) |
164
+ | Cohere | Command A、Command R(等 2 款) |
165
+ | OpenAI | GPT-5.6 Sol / Terra / Luna(等 3 款) |
166
+ | Google | Gemini 3.1 Pro、Gemini 3.6 Flash(等 2 款) |
167
+ | xAI | Grok 4.6(等 2 款) |
168
+ | Meta | Llama 4 Maverick(等 2 款) |
169
+ | 美团 | LongCat 2.0(估算价) |
170
+ | 面壁智能 | MiniCPM-V 4.5(估算价) |
171
+ | 小红书 | Dots3-Note Preview(估算价) |
172
+ | 零一万物 | Yi-Lightning |
173
+ | 阶跃星辰 | Step 3.7 Flash |
174
+ | 科大讯飞 | Spark 4.0 Ultra(套餐制)¹ |
175
+ | 商汤 | SenseNova 6.5(公测中)¹ |
176
+ | 百川智能 | Baichuan M3-Plus |
177
+ | 其他 | 未收录模型的统一回退定价(费用记 0) |
178
+
179
+ > ¹ 讯飞、商汤、小米及美团 / 面壁智能 / 小红书等未公布官方按量单价的模型,表内为估算价(`estimated`);这些模型走订阅通道(coding / token plan / opencode)时费用记 0。订阅通道与 pi-ai 内置提供方对齐(kimi-coding、zai-coding-cn、opencode、opencode-go、qwen / xiaomi 的 token-plan 各区域变体),可按 `subscriptionProviders` 配置覆盖。
170
180
 
171
181
  新增模型:在 `MODEL_CATALOG` 追加条目,并在 `src/client/pricing.ts` 的 `MODEL_KEY_ALIASES` 中映射真实模型 id(聚合层与客户端渲染共用同一张表)。
172
182