@linxin666/dsh-usage 0.3.22 → 0.3.23

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.
@@ -21,8 +21,8 @@ export interface VoucherData {
21
21
  from: string;
22
22
  to: string;
23
23
  }
24
- /** Anti-inflation exchange rate: 1000 tokens mint one whale yuan. */
25
- export declare const TOKENS_PER_WHALE_YUAN = 1000;
24
+ /** Anti-inflation exchange rate: 1,000,000 tokens mint one whale yuan. */
25
+ export declare const TOKENS_PER_WHALE_YUAN = 1000000;
26
26
  /** The note's face value in whale yuan; the smallest denomination is 1. */
27
27
  export declare function faceValue(tokens: number): number;
28
28
  /** Local calendar day (`YYYY-MM-DD`) for an epoch ms timestamp. */
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@linxin666/dsh-usage",
3
3
  "description": "Usage statistics plugin for the dsh web GUI: per-provider balance and coding-plan quota detection plus a live token usage ledger, with a dedicated pet bubble for the current provider",
4
- "version": "0.3.22",
4
+ "version": "0.3.23",
5
5
  "type": "module",
6
6
  "engines": {
7
7
  "node": "^22.19.0 || >=24.0.0"
@@ -66,7 +66,7 @@
66
66
  "@deepseek-ai/dsh-llm": "^0.1.5-rc.1",
67
67
  "@deepseek-ai/dsh-session": "^0.1.5-rc.1",
68
68
  "@deepseek-ai/dsh-settings": "^0.1.5-rc.1",
69
- "@linxin666/dsh-pet": "0.3.22",
69
+ "@linxin666/dsh-pet": "0.3.23",
70
70
  "@testing-library/dom": "^10.4.1",
71
71
  "@testing-library/react": "^16.3.2",
72
72
  "@types/node": "^22.20.0",
@@ -401,7 +401,7 @@ function totalOf(totals: UsageTokenTotals): number {
401
401
 
402
402
  /**
403
403
  * The Token 银行 card: the DeepSeek official family's retained-ledger usage
404
- * minted onto the whale-yuan note at 1000 tokens per whale yuan. The window
404
+ * minted onto the whale-yuan note at 1,000,000 tokens per whale yuan. The window
405
405
  * prefers the host's whole-ledger aggregate and falls back to the 30-day
406
406
  * trend when an older host serves no `all`; the spend line prefers the
407
407
  * official balance watch and falls back to the fold-time estimate; the
@@ -53,7 +53,7 @@ export const zh = {
53
53
  'usage.config.bubbleMode.change': '仅变化时',
54
54
  'usage.config.bubbleMode.off': '关闭',
55
55
  'usage.bank.title': '鲸元券',
56
- 'usage.bank.hint': '官方 API 每消耗 1000 tokens 铸造 1 鲸元;保存或分享这张票券。',
56
+ 'usage.bank.hint': '官方 API 每消耗 100 万 tokens 铸造 1 鲸元;保存或分享这张票券。',
57
57
  'usage.bank.noUsage': '暂无 DeepSeek 官方用量数据(统计自插件启用起)',
58
58
  'usage.bank.minted': '累计铸造 {minted} 鲸元({tokens} tokens)',
59
59
  'usage.bank.spend.observed': '官方余额实测花费 ¥{cost}(自 {since} 起)',
@@ -110,7 +110,7 @@ export const en: Record<UsageKey, string> = {
110
110
  'usage.config.bubbleMode.change': 'On change',
111
111
  'usage.config.bubbleMode.off': 'Off',
112
112
  'usage.bank.title': 'Whale-yuan voucher',
113
- 'usage.bank.hint': 'Every 1,000 tokens spent on the official API mint one whale yuan; save or share the note.',
113
+ 'usage.bank.hint': 'Every 1,000,000 tokens spent on the official API mint one whale yuan; save or share the note.',
114
114
  'usage.bank.noUsage': 'No official DeepSeek usage yet (counting starts when the plugin is enabled)',
115
115
  'usage.bank.minted': 'Minted {minted} whale yuan ({tokens} tokens)',
116
116
  'usage.bank.spend.observed': 'Spent ¥{cost} observed on the official balance (watching since {since})',
@@ -27,8 +27,8 @@ export interface VoucherData {
27
27
  to: string
28
28
  }
29
29
 
30
- /** Anti-inflation exchange rate: 1000 tokens mint one whale yuan. */
31
- export const TOKENS_PER_WHALE_YUAN = 1000
30
+ /** Anti-inflation exchange rate: 1,000,000 tokens mint one whale yuan. */
31
+ export const TOKENS_PER_WHALE_YUAN = 1_000_000
32
32
 
33
33
  /** The note's face value in whale yuan; the smallest denomination is 1. */
34
34
  export function faceValue(tokens: number): number {