@rayadesu/dsh-llm-billing 0.3.14 → 0.3.16

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.i18n.yaml CHANGED
@@ -2,5 +2,5 @@
2
2
  # last confirmed-consistent state. Both languages carry equal authority; after
3
3
  # editing either side, bring the other along and re-record both hashes with:
4
4
  # git hash-object README.md README.zh.md
5
- README.md: c3ca750612bab07f27a0d7d72acbcd80257fc7d5
6
- README.zh.md: 1bc217580dfe245ae96a1c537af213dfd79ef482
5
+ README.md: 9bb742179e5a39cc3128597ef28b2ea671f5d824
6
+ README.zh.md: 5704f78fd040f44b0a1f872bcd26e60eb733fce8
package/README.md CHANGED
@@ -47,7 +47,7 @@ A forked session (DSH's "fork" of a conversation) opens its log with a verbatim
47
47
 
48
48
  ## Runtime compatibility
49
49
 
50
- Since 0.1.2-alpha.4, DSH replaced the live `Session` log surface `Session.events` with `Session.snapshotEvents()` (no args = the full current log) and `Session.ownEvents()`, and moved `SessionHeader.seedLength` to `Session.inheritedEventCount` (the persistence `inspect()` result carries the value beside `meta`; `listSnapshots()` headers keep only the boolean `isSeeded`). Every log read in the plugin goes through the structural adapters `liveSessionEvents` / `forkBoundaryOf` / `isSeededSession`, which accept both the ≤ 0.1.1-rc.2 and the 0.1.2-alpha.4+ shapes — the npm release baseline (`^0.1.6-alpha.1`) and the ahead-of-npm monorepo runtime both work without modification. On an unknown surface that has neither shape the plugin fails loudly rather than silently pricing an empty log. The ranking's lineage read is structural in the same way: a header that carries neither `origin: 'subagent'` nor a non-zero `delegationDepth` (an older log, or a session created without them) simply reads as a top-level session and keeps its own row.
50
+ Since 0.1.2-alpha.4, DSH replaced the live `Session` log surface `Session.events` with `Session.snapshotEvents()` (no args = the full current log) and `Session.ownEvents()`, and moved `SessionHeader.seedLength` to `Session.inheritedEventCount` (the persistence `inspect()` result carries the value beside `meta`; `listSnapshots()` headers keep only the boolean `isSeeded`). Every log read in the plugin goes through the structural adapters `liveSessionEvents` / `forkBoundaryOf` / `isSeededSession`, which accept both the ≤ 0.1.1-rc.2 and the 0.1.2-alpha.4+ shapes — the npm release baseline (`^0.1.7-alpha.2`) and the ahead-of-npm monorepo runtime both work without modification. On an unknown surface that has neither shape the plugin fails loudly rather than silently pricing an empty log. The ranking's lineage read is structural in the same way: a header that carries neither `origin: 'subagent'` nor a non-zero `delegationDepth` (an older log, or a session created without them) simply reads as a top-level session and keeps its own row.
51
51
 
52
52
  The persistence service itself changed surface too: 0.1.1-rc.2 exposes `inspect(id)` / `listSnapshots()`, while the handle-based seam exposes `open(id, 'read')` + `SessionHandle.read()` / `list()`. The scanner reads both families through `persistenceInspect` / `persistenceListSnapshots` (the handle is always closed, including after a failed read), so the same plugin serves the published alpha line and the refactored checkout. `SessionHandle.read()` itself has two generations: it first returned the bare event array, and since DSH `9b78f99dec` (in the 0.1.5-alpha.1 checkout) it returns `{ eventState, events }`; `handleReadEvents` unwraps both, so a cold read keeps working across the change.
53
53
 
package/README.zh.md CHANGED
@@ -47,7 +47,7 @@
47
47
 
48
48
  ## 运行时兼容性
49
49
 
50
- 0.1.2-alpha.4 起,DSH 把 live `Session` 的日志读取表面从 `Session.events` 改为 `Session.snapshotEvents()`(无参 = 当前全量日志)与 `Session.ownEvents()`,并把 `SessionHeader.seedLength` 移至 `Session.inheritedEventCount`(持久化侧 `inspect()` 的结果在 `meta` 之外携带该值,`listSnapshots()` 的 header 只剩布尔 `isSeeded`)。插件的所有日志读取都走结构适配器 `liveSessionEvents` / `forkBoundaryOf` / `isSeededSession`,同时接受 ≤ 0.1.1-rc.2 与 0.1.2-alpha.4+ 两种形状——npm 发布基线(`^0.1.6-alpha.1`)与超前于它的 monorepo 运行时代码均无需改动即可工作。遇到两种形状都没有的未知运行时表面时,插件会显式失败而不是静默按零花费计价。排行的血缘读取同样以结构方式完成:header 里既没有 `origin: 'subagent'` 也没有非零 `delegationDepth` 的会话(旧日志,或创建时就没有这两个字段的会话)直接视作顶层会话、保留自己一行。
50
+ 0.1.2-alpha.4 起,DSH 把 live `Session` 的日志读取表面从 `Session.events` 改为 `Session.snapshotEvents()`(无参 = 当前全量日志)与 `Session.ownEvents()`,并把 `SessionHeader.seedLength` 移至 `Session.inheritedEventCount`(持久化侧 `inspect()` 的结果在 `meta` 之外携带该值,`listSnapshots()` 的 header 只剩布尔 `isSeeded`)。插件的所有日志读取都走结构适配器 `liveSessionEvents` / `forkBoundaryOf` / `isSeededSession`,同时接受 ≤ 0.1.1-rc.2 与 0.1.2-alpha.4+ 两种形状——npm 发布基线(`^0.1.7-alpha.2`)与超前于它的 monorepo 运行时代码均无需改动即可工作。遇到两种形状都没有的未知运行时表面时,插件会显式失败而不是静默按零花费计价。排行的血缘读取同样以结构方式完成:header 里既没有 `origin: 'subagent'` 也没有非零 `delegationDepth` 的会话(旧日志,或创建时就没有这两个字段的会话)直接视作顶层会话、保留自己一行。
51
51
 
52
52
  持久化服务的表面同样换代:0.1.1-rc.2 提供 `inspect(id)` / `listSnapshots()`,而 handle 化 seam 提供 `open(id, 'read')` + `SessionHandle.read()` / `list()`。扫描器通过 `persistenceInspect` / `persistenceListSnapshots` 同时读取两代表面(handle 总会关闭,读取失败时也一样),因此同一套插件既能服务已发布的 alpha 线,也能服务重构后的 checkout。`SessionHandle.read()` 自身也有两代:最初返回裸事件数组,DSH `9b78f99dec`(0.1.5-alpha.1 checkout 中)起返回 `{ eventState, events }`;`handleReadEvents` 同时接受两种形状,冷读因此不受该变更影响。
53
53
 
package/lib/index.js CHANGED
@@ -410,8 +410,8 @@ const V4_PRO_SWITCHED_RATES = {
410
410
  * series (V4.1 Flash, V4 Flash, V4 Flash Vision Exp) carries the second
411
411
  * revision effective 2026-09-10 12:00 Beijing, and the V4 Pro row the V4.1
412
412
  * Flash rates from its announced route switch (2026-09-14 12:00 Beijing) —
413
- * the MiMo-V2.5 series is untouched by either adjustment. Rows sharing a model
414
- * are that model's rate history.
413
+ * the MiMo series (V2.5, and V2.6 which kept V2.5's pricing) is untouched by
414
+ * either adjustment. Rows sharing a model are that model's rate history.
415
415
  */
416
416
  const DEFAULT_MODEL_PRICING = [
417
417
  {
@@ -488,6 +488,32 @@ const DEFAULT_MODEL_PRICING = [
488
488
  cacheMissInput: 1,
489
489
  output: 2
490
490
  }
491
+ },
492
+ {
493
+ model: "mimo-v2.6-pro",
494
+ peak: {
495
+ cacheHitInput: .025,
496
+ cacheMissInput: 3,
497
+ output: 6
498
+ },
499
+ offPeak: {
500
+ cacheHitInput: .025,
501
+ cacheMissInput: 3,
502
+ output: 6
503
+ }
504
+ },
505
+ {
506
+ model: "mimo-v2.6-flash",
507
+ peak: {
508
+ cacheHitInput: .02,
509
+ cacheMissInput: 1,
510
+ output: 2
511
+ },
512
+ offPeak: {
513
+ cacheHitInput: .02,
514
+ cacheMissInput: 1,
515
+ output: 2
516
+ }
491
517
  }
492
518
  ];
493
519
  /**
@@ -2037,10 +2063,11 @@ const BASE_URL_ENV = "DEEPSEEK_BASE_URL";
2037
2063
  const PUBLIC_BASE_URL = "https://api.deepseek.com";
2038
2064
  /**
2039
2065
  * Advisory display rows mirroring the DSH `llm-deepseek` catalog (V4.1 Flash
2040
- * first, its current default route), plus the MiMo-V2.5 series. The retired
2041
- * preview id `deepseek-v4.1-flash-expires-on-0910` stays so the logs that used
2042
- * it keep a readable label; rows never restrict which models are priced — the
2043
- * pricing table does.
2066
+ * first, its current default route), plus the MiMo series (V2.5, and V2.6
2067
+ * which kept V2.5's pricing). The retired preview id
2068
+ * `deepseek-v4.1-flash-expires-on-0910` stays so the logs that used it keep a
2069
+ * readable label; rows never restrict which models are priced — the pricing
2070
+ * table does.
2044
2071
  */
2045
2072
  const DEFAULT_MODELS = [
2046
2073
  {
@@ -2070,6 +2097,14 @@ const DEFAULT_MODELS = [
2070
2097
  {
2071
2098
  id: "mimo-v2.5",
2072
2099
  name: "MiMo-V2.5"
2100
+ },
2101
+ {
2102
+ id: "mimo-v2.6-pro",
2103
+ name: "MiMo-V2.6-Pro"
2104
+ },
2105
+ {
2106
+ id: "mimo-v2.6-flash",
2107
+ name: "MiMo-V2.6-Flash"
2073
2108
  }
2074
2109
  ];
2075
2110
  const billingModel = z.object({
@@ -1,8 +1,10 @@
1
1
  /* Generated by @deepseek-ai/dsh-typert-generator from FaceModel — do not edit. */
2
2
  import { z } from 'zod'
3
3
 
4
- const _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema = z.union([z.undefined(), z.literal(false), z.literal(true)])
5
- const _rayadesu_dsh_llm_billing_billing_getBalance_result$schema = z.object({
4
+ let _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema$value
5
+ const _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema$value ??= z.union([z.undefined(), z.literal(false), z.literal(true)]))
6
+ let _rayadesu_dsh_llm_billing_billing_getBalance_result$schema$value
7
+ const _rayadesu_dsh_llm_billing_billing_getBalance_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getBalance_result$schema$value ??= z.object({
6
8
  'isAvailable': z.boolean(),
7
9
  'lines': z.array(z.object({
8
10
  'currency': z.string(),
@@ -10,10 +12,13 @@ const _rayadesu_dsh_llm_billing_billing_getBalance_result$schema = z.object({
10
12
  'granted': z.string(),
11
13
  'toppedUp': z.string(),
12
14
  })),
13
- })
14
- const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema = z.intersection(z.string(), z.unknown())
15
- const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema = z.union([z.undefined(), z.literal(false), z.literal(true)])
16
- const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema = z.object({
15
+ }))
16
+ let _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema$value
17
+ const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
18
+ let _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema$value
19
+ const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema = () => (_rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema$value ??= z.union([z.undefined(), z.literal(false), z.literal(true)]))
20
+ let _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema$value
21
+ const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema$value ??= z.object({
17
22
  'total': z.number(),
18
23
  'models': z.array(z.object({
19
24
  'model': z.string(),
@@ -30,9 +35,11 @@ const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema = z.obje
30
35
  })),
31
36
  'isSubagent': z.boolean(),
32
37
  'crossedDay': z.boolean(),
33
- })
34
- const _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema = z.intersection(z.string(), z.unknown())
35
- const _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema = z.object({
38
+ }))
39
+ let _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema$value
40
+ const _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
41
+ let _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema$value
42
+ const _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema$value ??= z.object({
36
43
  'total': z.number(),
37
44
  'models': z.array(z.object({
38
45
  'model': z.string(),
@@ -47,25 +54,31 @@ const _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema = z.object
47
54
  'cacheMissInputCost': z.number(),
48
55
  'outputCost': z.number(),
49
56
  })),
50
- })
51
- const _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema = z.intersection(z.string(), z.unknown())
52
- const _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema = z.object({
57
+ }))
58
+ let _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema$value
59
+ const _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
60
+ let _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema$value
61
+ const _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema$value ??= z.object({
53
62
  'turns': z.array(z.object({
54
63
  'messageId': z.string(),
55
64
  'total': z.number(),
56
65
  })),
57
- })
58
- const _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema = z.union([z.undefined(), z.literal(false), z.literal(true)])
59
- const _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema = z.object({
66
+ }))
67
+ let _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema$value
68
+ const _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema$value ??= z.union([z.undefined(), z.literal(false), z.literal(true)]))
69
+ let _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema$value
70
+ const _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema$value ??= z.object({
60
71
  'sessions': z.array(z.object({
61
72
  'sessionId': z.intersection(z.string(), z.unknown()),
62
73
  'title': z.union([z.literal(null), z.string()]),
63
74
  'total': z.number(),
64
75
  'ownTotal': z.number(),
65
76
  })),
66
- })
67
- const _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema = z.union([z.undefined(), z.literal(false), z.literal(true)])
68
- const _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema = z.object({
77
+ }))
78
+ let _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema$value
79
+ const _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema$value ??= z.union([z.undefined(), z.literal(false), z.literal(true)]))
80
+ let _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema$value
81
+ const _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema$value ??= z.object({
69
82
  'total': z.number(),
70
83
  'models': z.array(z.object({
71
84
  'model': z.string(),
@@ -80,12 +93,15 @@ const _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema = z.object({
80
93
  'cacheMissInputCost': z.number(),
81
94
  'outputCost': z.number(),
82
95
  })),
83
- })
84
- const _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema = z.intersection(z.string(), z.unknown())
85
- const _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema = z.string()
86
- const _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema = z.object({
96
+ }))
97
+ let _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema$value
98
+ const _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
99
+ let _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema$value
100
+ const _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema = () => (_rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema$value ??= z.string())
101
+ let _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema$value
102
+ const _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema$value ??= z.object({
87
103
  'total': z.number(),
88
- })
104
+ }))
89
105
 
90
106
  export const TYPERT = {
91
107
  package: '@rayadesu/dsh-llm-billing',
@@ -108,16 +124,14 @@ export const TYPERT = {
108
124
  codec: {
109
125
  mode: 'strict',
110
126
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getBalance:force',
111
- schema: _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema,
112
- create: () => _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema,
127
+ create: _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema,
113
128
  },
114
129
  },
115
130
  ],
116
131
  result: {
117
132
  mode: 'strict',
118
133
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekBalance',
119
- schema: _rayadesu_dsh_llm_billing_billing_getBalance_result$schema,
120
- create: () => _rayadesu_dsh_llm_billing_billing_getBalance_result$schema,
134
+ create: _rayadesu_dsh_llm_billing_billing_getBalance_result$schema,
121
135
  },
122
136
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":172,"column":3},
123
137
  },
@@ -135,8 +149,7 @@ export const TYPERT = {
135
149
  codec: {
136
150
  mode: 'strict',
137
151
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getDelegatedSpend:sessionId',
138
- schema: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema,
139
- create: () => _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema,
152
+ create: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema,
140
153
  },
141
154
  },
142
155
  {
@@ -147,16 +160,14 @@ export const TYPERT = {
147
160
  codec: {
148
161
  mode: 'strict',
149
162
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getDelegatedSpend:force',
150
- schema: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema,
151
- create: () => _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema,
163
+ create: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema,
152
164
  },
153
165
  },
154
166
  ],
155
167
  result: {
156
168
  mode: 'strict',
157
169
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekDelegatedSpend',
158
- schema: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema,
159
- create: () => _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema,
170
+ create: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema,
160
171
  },
161
172
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":226,"column":3},
162
173
  },
@@ -174,16 +185,14 @@ export const TYPERT = {
174
185
  codec: {
175
186
  mode: 'strict',
176
187
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getSessionSpend:sessionId',
177
- schema: _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema,
178
- create: () => _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema,
188
+ create: _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema,
179
189
  },
180
190
  },
181
191
  ],
182
192
  result: {
183
193
  mode: 'strict',
184
194
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekSessionSpend',
185
- schema: _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema,
186
- create: () => _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema,
195
+ create: _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema,
187
196
  },
188
197
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":183,"column":3},
189
198
  },
@@ -201,16 +210,14 @@ export const TYPERT = {
201
210
  codec: {
202
211
  mode: 'strict',
203
212
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getSessionTurnSpends:sessionId',
204
- schema: _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema,
205
- create: () => _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema,
213
+ create: _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema,
206
214
  },
207
215
  },
208
216
  ],
209
217
  result: {
210
218
  mode: 'strict',
211
219
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekSessionTurnSpends',
212
- schema: _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema,
213
- create: () => _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema,
220
+ create: _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema,
214
221
  },
215
222
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":251,"column":3},
216
223
  },
@@ -229,16 +236,14 @@ export const TYPERT = {
229
236
  codec: {
230
237
  mode: 'strict',
231
238
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getTodaySessionsSpend:force',
232
- schema: _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema,
233
- create: () => _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema,
239
+ create: _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema,
234
240
  },
235
241
  },
236
242
  ],
237
243
  result: {
238
244
  mode: 'strict',
239
245
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekTodaySessionsSpend',
240
- schema: _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema,
241
- create: () => _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema,
246
+ create: _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema,
242
247
  },
243
248
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":211,"column":3},
244
249
  },
@@ -257,16 +262,14 @@ export const TYPERT = {
257
262
  codec: {
258
263
  mode: 'strict',
259
264
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getTodaySpend:force',
260
- schema: _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema,
261
- create: () => _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema,
265
+ create: _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema,
262
266
  },
263
267
  },
264
268
  ],
265
269
  result: {
266
270
  mode: 'strict',
267
271
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekTodaySpend',
268
- schema: _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema,
269
- create: () => _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema,
272
+ create: _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema,
270
273
  },
271
274
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":196,"column":3},
272
275
  },
@@ -284,8 +287,7 @@ export const TYPERT = {
284
287
  codec: {
285
288
  mode: 'strict',
286
289
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getTurnSpend:sessionId',
287
- schema: _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema,
288
- create: () => _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema,
290
+ create: _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema,
289
291
  },
290
292
  },
291
293
  {
@@ -295,16 +297,14 @@ export const TYPERT = {
295
297
  codec: {
296
298
  mode: 'strict',
297
299
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getTurnSpend:messageId',
298
- schema: _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema,
299
- create: () => _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema,
300
+ create: _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema,
300
301
  },
301
302
  },
302
303
  ],
303
304
  result: {
304
305
  mode: 'strict',
305
306
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekTurnSpend',
306
- schema: _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema,
307
- create: () => _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema,
307
+ create: _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema,
308
308
  },
309
309
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":239,"column":3},
310
310
  },
@@ -1,8 +1,10 @@
1
1
  /* Generated by @deepseek-ai/dsh-typert-generator from the Host FaceModel — do not edit. */
2
2
  import { z } from 'zod'
3
3
 
4
- const _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema = z.union([z.undefined(), z.literal(false), z.literal(true)])
5
- const _rayadesu_dsh_llm_billing_billing_getBalance_result$schema = z.object({
4
+ let _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema$value
5
+ const _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema$value ??= z.union([z.undefined(), z.literal(false), z.literal(true)]))
6
+ let _rayadesu_dsh_llm_billing_billing_getBalance_result$schema$value
7
+ const _rayadesu_dsh_llm_billing_billing_getBalance_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getBalance_result$schema$value ??= z.object({
6
8
  'isAvailable': z.boolean(),
7
9
  'lines': z.array(z.object({
8
10
  'currency': z.string(),
@@ -10,10 +12,13 @@ const _rayadesu_dsh_llm_billing_billing_getBalance_result$schema = z.object({
10
12
  'granted': z.string(),
11
13
  'toppedUp': z.string(),
12
14
  })),
13
- })
14
- const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema = z.intersection(z.string(), z.unknown())
15
- const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema = z.union([z.undefined(), z.literal(false), z.literal(true)])
16
- const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema = z.object({
15
+ }))
16
+ let _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema$value
17
+ const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
18
+ let _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema$value
19
+ const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema = () => (_rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema$value ??= z.union([z.undefined(), z.literal(false), z.literal(true)]))
20
+ let _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema$value
21
+ const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema$value ??= z.object({
17
22
  'total': z.number(),
18
23
  'models': z.array(z.object({
19
24
  'model': z.string(),
@@ -30,9 +35,11 @@ const _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema = z.obje
30
35
  })),
31
36
  'isSubagent': z.boolean(),
32
37
  'crossedDay': z.boolean(),
33
- })
34
- const _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema = z.intersection(z.string(), z.unknown())
35
- const _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema = z.object({
38
+ }))
39
+ let _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema$value
40
+ const _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
41
+ let _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema$value
42
+ const _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema$value ??= z.object({
36
43
  'total': z.number(),
37
44
  'models': z.array(z.object({
38
45
  'model': z.string(),
@@ -47,25 +54,31 @@ const _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema = z.object
47
54
  'cacheMissInputCost': z.number(),
48
55
  'outputCost': z.number(),
49
56
  })),
50
- })
51
- const _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema = z.intersection(z.string(), z.unknown())
52
- const _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema = z.object({
57
+ }))
58
+ let _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema$value
59
+ const _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
60
+ let _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema$value
61
+ const _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema$value ??= z.object({
53
62
  'turns': z.array(z.object({
54
63
  'messageId': z.string(),
55
64
  'total': z.number(),
56
65
  })),
57
- })
58
- const _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema = z.union([z.undefined(), z.literal(false), z.literal(true)])
59
- const _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema = z.object({
66
+ }))
67
+ let _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema$value
68
+ const _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema$value ??= z.union([z.undefined(), z.literal(false), z.literal(true)]))
69
+ let _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema$value
70
+ const _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema$value ??= z.object({
60
71
  'sessions': z.array(z.object({
61
72
  'sessionId': z.intersection(z.string(), z.unknown()),
62
73
  'title': z.union([z.literal(null), z.string()]),
63
74
  'total': z.number(),
64
75
  'ownTotal': z.number(),
65
76
  })),
66
- })
67
- const _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema = z.union([z.undefined(), z.literal(false), z.literal(true)])
68
- const _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema = z.object({
77
+ }))
78
+ let _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema$value
79
+ const _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema$value ??= z.union([z.undefined(), z.literal(false), z.literal(true)]))
80
+ let _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema$value
81
+ const _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema$value ??= z.object({
69
82
  'total': z.number(),
70
83
  'models': z.array(z.object({
71
84
  'model': z.string(),
@@ -80,12 +93,15 @@ const _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema = z.object({
80
93
  'cacheMissInputCost': z.number(),
81
94
  'outputCost': z.number(),
82
95
  })),
83
- })
84
- const _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema = z.intersection(z.string(), z.unknown())
85
- const _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema = z.string()
86
- const _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema = z.object({
96
+ }))
97
+ let _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema$value
98
+ const _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema = () => (_rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema$value ??= z.intersection(z.string(), z.unknown()))
99
+ let _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema$value
100
+ const _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema = () => (_rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema$value ??= z.string())
101
+ let _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema$value
102
+ const _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema = () => (_rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema$value ??= z.object({
87
103
  'total': z.number(),
88
- })
104
+ }))
89
105
 
90
106
  export const TYPERT_REMOTE = {
91
107
  package: '@rayadesu/dsh-llm-billing',
@@ -105,16 +121,14 @@ export const TYPERT_REMOTE = {
105
121
  codec: {
106
122
  mode: 'strict',
107
123
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getBalance:force',
108
- schema: _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema,
109
- create: () => _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema,
124
+ create: _rayadesu_dsh_llm_billing_billing_getBalance_parameter_0$schema,
110
125
  },
111
126
  },
112
127
  ],
113
128
  result: {
114
129
  mode: 'strict',
115
130
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekBalance',
116
- schema: _rayadesu_dsh_llm_billing_billing_getBalance_result$schema,
117
- create: () => _rayadesu_dsh_llm_billing_billing_getBalance_result$schema,
131
+ create: _rayadesu_dsh_llm_billing_billing_getBalance_result$schema,
118
132
  },
119
133
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":172,"column":3},
120
134
  },
@@ -132,8 +146,7 @@ export const TYPERT_REMOTE = {
132
146
  codec: {
133
147
  mode: 'strict',
134
148
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getDelegatedSpend:sessionId',
135
- schema: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema,
136
- create: () => _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema,
149
+ create: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_0$schema,
137
150
  },
138
151
  },
139
152
  {
@@ -144,16 +157,14 @@ export const TYPERT_REMOTE = {
144
157
  codec: {
145
158
  mode: 'strict',
146
159
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getDelegatedSpend:force',
147
- schema: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema,
148
- create: () => _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema,
160
+ create: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_parameter_1$schema,
149
161
  },
150
162
  },
151
163
  ],
152
164
  result: {
153
165
  mode: 'strict',
154
166
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekDelegatedSpend',
155
- schema: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema,
156
- create: () => _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema,
167
+ create: _rayadesu_dsh_llm_billing_billing_getDelegatedSpend_result$schema,
157
168
  },
158
169
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":226,"column":3},
159
170
  },
@@ -171,16 +182,14 @@ export const TYPERT_REMOTE = {
171
182
  codec: {
172
183
  mode: 'strict',
173
184
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getSessionSpend:sessionId',
174
- schema: _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema,
175
- create: () => _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema,
185
+ create: _rayadesu_dsh_llm_billing_billing_getSessionSpend_parameter_0$schema,
176
186
  },
177
187
  },
178
188
  ],
179
189
  result: {
180
190
  mode: 'strict',
181
191
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekSessionSpend',
182
- schema: _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema,
183
- create: () => _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema,
192
+ create: _rayadesu_dsh_llm_billing_billing_getSessionSpend_result$schema,
184
193
  },
185
194
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":183,"column":3},
186
195
  },
@@ -198,16 +207,14 @@ export const TYPERT_REMOTE = {
198
207
  codec: {
199
208
  mode: 'strict',
200
209
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getSessionTurnSpends:sessionId',
201
- schema: _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema,
202
- create: () => _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema,
210
+ create: _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_parameter_0$schema,
203
211
  },
204
212
  },
205
213
  ],
206
214
  result: {
207
215
  mode: 'strict',
208
216
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekSessionTurnSpends',
209
- schema: _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema,
210
- create: () => _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema,
217
+ create: _rayadesu_dsh_llm_billing_billing_getSessionTurnSpends_result$schema,
211
218
  },
212
219
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":251,"column":3},
213
220
  },
@@ -226,16 +233,14 @@ export const TYPERT_REMOTE = {
226
233
  codec: {
227
234
  mode: 'strict',
228
235
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getTodaySessionsSpend:force',
229
- schema: _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema,
230
- create: () => _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema,
236
+ create: _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_parameter_0$schema,
231
237
  },
232
238
  },
233
239
  ],
234
240
  result: {
235
241
  mode: 'strict',
236
242
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekTodaySessionsSpend',
237
- schema: _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema,
238
- create: () => _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema,
243
+ create: _rayadesu_dsh_llm_billing_billing_getTodaySessionsSpend_result$schema,
239
244
  },
240
245
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":211,"column":3},
241
246
  },
@@ -254,16 +259,14 @@ export const TYPERT_REMOTE = {
254
259
  codec: {
255
260
  mode: 'strict',
256
261
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getTodaySpend:force',
257
- schema: _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema,
258
- create: () => _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema,
262
+ create: _rayadesu_dsh_llm_billing_billing_getTodaySpend_parameter_0$schema,
259
263
  },
260
264
  },
261
265
  ],
262
266
  result: {
263
267
  mode: 'strict',
264
268
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekTodaySpend',
265
- schema: _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema,
266
- create: () => _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema,
269
+ create: _rayadesu_dsh_llm_billing_billing_getTodaySpend_result$schema,
267
270
  },
268
271
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":196,"column":3},
269
272
  },
@@ -281,8 +284,7 @@ export const TYPERT_REMOTE = {
281
284
  codec: {
282
285
  mode: 'strict',
283
286
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getTurnSpend:sessionId',
284
- schema: _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema,
285
- create: () => _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema,
287
+ create: _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_0$schema,
286
288
  },
287
289
  },
288
290
  {
@@ -292,16 +294,14 @@ export const TYPERT_REMOTE = {
292
294
  codec: {
293
295
  mode: 'strict',
294
296
  typeSymbol: '@rayadesu/dsh-llm-billing#billing/getTurnSpend:messageId',
295
- schema: _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema,
296
- create: () => _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema,
297
+ create: _rayadesu_dsh_llm_billing_billing_getTurnSpend_parameter_1$schema,
297
298
  },
298
299
  },
299
300
  ],
300
301
  result: {
301
302
  mode: 'strict',
302
303
  typeSymbol: '@rayadesu/dsh-llm-billing/types#DeepSeekTurnSpend',
303
- schema: _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema,
304
- create: () => _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema,
304
+ create: _rayadesu_dsh_llm_billing_billing_getTurnSpend_result$schema,
305
305
  },
306
306
  sourceLocation: {"file":"packages/llm-billing/src/balance.ts","line":239,"column":3},
307
307
  },
@@ -106,8 +106,8 @@ export declare const V4_PRO_ROUTE_SWITCH_AT: number;
106
106
  * series (V4.1 Flash, V4 Flash, V4 Flash Vision Exp) carries the second
107
107
  * revision effective 2026-09-10 12:00 Beijing, and the V4 Pro row the V4.1
108
108
  * Flash rates from its announced route switch (2026-09-14 12:00 Beijing) —
109
- * the MiMo-V2.5 series is untouched by either adjustment. Rows sharing a model
110
- * are that model's rate history.
109
+ * the MiMo series (V2.5, and V2.6 which kept V2.5's pricing) is untouched by
110
+ * either adjustment. Rows sharing a model are that model's rate history.
111
111
  */
112
112
  export declare const DEFAULT_MODEL_PRICING: readonly BillingConfigModel[];
113
113
  /** Resolved billing configuration: a pricing table plus peak-hour windows. */
@@ -65,8 +65,8 @@ const V4_PRO_SWITCHED_RATES = {
65
65
  * series (V4.1 Flash, V4 Flash, V4 Flash Vision Exp) carries the second
66
66
  * revision effective 2026-09-10 12:00 Beijing, and the V4 Pro row the V4.1
67
67
  * Flash rates from its announced route switch (2026-09-14 12:00 Beijing) —
68
- * the MiMo-V2.5 series is untouched by either adjustment. Rows sharing a model
69
- * are that model's rate history.
68
+ * the MiMo series (V2.5, and V2.6 which kept V2.5's pricing) is untouched by
69
+ * either adjustment. Rows sharing a model are that model's rate history.
70
70
  */
71
71
  export const DEFAULT_MODEL_PRICING = [
72
72
  // deepseek-flash is the V4.1 Flash route, DSH's default catalog entry; image
@@ -92,7 +92,10 @@ export const DEFAULT_MODEL_PRICING = [
92
92
  // images are converted to tokens at the same per-token price.
93
93
  { model: 'deepseek-v4-flash-vision-exp', ...FLASH_BASE_RATES },
94
94
  { model: 'deepseek-v4-flash-vision-exp', ...FLASH_REPRICED_RATES },
95
- // MiMo-V2.5 series (Xiaomi): flat rate, no peak/off-peak distinction.
95
+ // MiMo series (Xiaomi): flat rate, no peak/off-peak distinction. V2.6 keeps
96
+ // V2.5's published API pricing (2026-09-22 launch, "API pricing unchanged
97
+ // from V2.5"); cache writes bill at the miss rate, though Xiaomi's launch
98
+ // window makes them free provider-side for a limited time.
96
99
  {
97
100
  model: 'mimo-v2.5-pro',
98
101
  peak: { cacheHitInput: 0.025, cacheMissInput: 3.0, output: 6.0 },
@@ -103,6 +106,16 @@ export const DEFAULT_MODEL_PRICING = [
103
106
  peak: { cacheHitInput: 0.02, cacheMissInput: 1.0, output: 2.0 },
104
107
  offPeak: { cacheHitInput: 0.02, cacheMissInput: 1.0, output: 2.0 },
105
108
  },
109
+ {
110
+ model: 'mimo-v2.6-pro',
111
+ peak: { cacheHitInput: 0.025, cacheMissInput: 3.0, output: 6.0 },
112
+ offPeak: { cacheHitInput: 0.025, cacheMissInput: 3.0, output: 6.0 },
113
+ },
114
+ {
115
+ model: 'mimo-v2.6-flash',
116
+ peak: { cacheHitInput: 0.02, cacheMissInput: 1.0, output: 2.0 },
117
+ offPeak: { cacheHitInput: 0.02, cacheMissInput: 1.0, output: 2.0 },
118
+ },
106
119
  ];
107
120
  /**
108
121
  * Resolve optional configuration to a pricing table, defaulting omitted or
@@ -39,10 +39,11 @@ const BASE_URL_ENV = 'DEEPSEEK_BASE_URL';
39
39
  export const PUBLIC_BASE_URL = 'https://api.deepseek.com';
40
40
  /**
41
41
  * Advisory display rows mirroring the DSH `llm-deepseek` catalog (V4.1 Flash
42
- * first, its current default route), plus the MiMo-V2.5 series. The retired
43
- * preview id `deepseek-v4.1-flash-expires-on-0910` stays so the logs that used
44
- * it keep a readable label; rows never restrict which models are priced — the
45
- * pricing table does.
42
+ * first, its current default route), plus the MiMo series (V2.5, and V2.6
43
+ * which kept V2.5's pricing). The retired preview id
44
+ * `deepseek-v4.1-flash-expires-on-0910` stays so the logs that used it keep a
45
+ * readable label; rows never restrict which models are priced — the pricing
46
+ * table does.
46
47
  */
47
48
  const DEFAULT_MODELS = [
48
49
  { id: 'deepseek-flash', name: 'DeepSeek-V41-Flash' },
@@ -52,6 +53,8 @@ const DEFAULT_MODELS = [
52
53
  { id: 'deepseek-v4-flash-vision-exp', name: 'DeepSeek-V4-Flash-Vision-Exp' },
53
54
  { id: 'mimo-v2.5-pro', name: 'MiMo-V2.5-Pro' },
54
55
  { id: 'mimo-v2.5', name: 'MiMo-V2.5' },
56
+ { id: 'mimo-v2.6-pro', name: 'MiMo-V2.6-Pro' },
57
+ { id: 'mimo-v2.6-flash', name: 'MiMo-V2.6-Flash' },
55
58
  ];
56
59
  const billingModel = z.object({
57
60
  id: z.string().required(),
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@rayadesu/dsh-llm-billing",
3
3
  "description": "Standalone DeepSeek account-balance and session-spend provider exposed through the billing Remote",
4
- "version": "0.3.14",
4
+ "version": "0.3.16",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -56,29 +56,29 @@
56
56
  },
57
57
  "license": "MIT",
58
58
  "peerDependencies": {
59
- "@deepseek-ai/dsh-credentials": "^0.1.6-alpha.1",
60
- "@deepseek-ai/dsh-launch-environment": "^0.1.6-alpha.1",
61
- "@deepseek-ai/dsh-invariants": "^0.1.6-alpha.1",
62
- "@deepseek-ai/dsh-llm": "^0.1.6-alpha.1",
63
- "@deepseek-ai/dsh-session": "^0.1.6-alpha.1",
64
- "@deepseek-ai/dsh-session-persistence": "^0.1.6-alpha.1",
65
- "@deepseek-ai/dsh-session-projection": "^0.1.6-alpha.1",
66
- "@deepseek-ai/dsh-typert-protocol": "^0.1.6-alpha.1",
67
- "@deepseek-ai/cordis": "^4.0.2"
59
+ "@deepseek-ai/dsh-credentials": "^0.1.7-alpha.2",
60
+ "@deepseek-ai/dsh-launch-environment": "^0.1.7-alpha.2",
61
+ "@deepseek-ai/dsh-invariants": "^0.1.7-alpha.2",
62
+ "@deepseek-ai/dsh-llm": "^0.1.7-alpha.2",
63
+ "@deepseek-ai/dsh-session": "^0.1.7-alpha.2",
64
+ "@deepseek-ai/dsh-session-persistence": "^0.1.7-alpha.2",
65
+ "@deepseek-ai/dsh-session-projection": "^0.1.7-alpha.2",
66
+ "@deepseek-ai/dsh-typert-protocol": "^0.1.7-alpha.2",
67
+ "@deepseek-ai/cordis": "^4.0.4"
68
68
  },
69
69
  "dependencies": {
70
- "@deepseek-ai/schemastery": "^3.18.2",
70
+ "@deepseek-ai/schemastery": "^3.18.4",
71
71
  "zod": "^4.4.3"
72
72
  },
73
73
  "devDependencies": {
74
- "@deepseek-ai/dsh-credentials": "^0.1.6-alpha.1",
75
- "@deepseek-ai/dsh-launch-environment": "^0.1.6-alpha.1",
76
- "@deepseek-ai/dsh-invariants": "^0.1.6-alpha.1",
77
- "@deepseek-ai/dsh-llm": "^0.1.6-alpha.1",
78
- "@deepseek-ai/dsh-session": "^0.1.6-alpha.1",
79
- "@deepseek-ai/dsh-session-persistence": "^0.1.6-alpha.1",
80
- "@deepseek-ai/dsh-session-projection": "^0.1.6-alpha.1",
81
- "@deepseek-ai/dsh-typert-protocol": "^0.1.6-alpha.1",
82
- "@deepseek-ai/cordis": "^4.0.2"
74
+ "@deepseek-ai/dsh-credentials": "^0.1.7-alpha.2",
75
+ "@deepseek-ai/dsh-launch-environment": "^0.1.7-alpha.2",
76
+ "@deepseek-ai/dsh-invariants": "^0.1.7-alpha.2",
77
+ "@deepseek-ai/dsh-llm": "^0.1.7-alpha.2",
78
+ "@deepseek-ai/dsh-session": "^0.1.7-alpha.2",
79
+ "@deepseek-ai/dsh-session-persistence": "^0.1.7-alpha.2",
80
+ "@deepseek-ai/dsh-session-projection": "^0.1.7-alpha.2",
81
+ "@deepseek-ai/dsh-typert-protocol": "^0.1.7-alpha.2",
82
+ "@deepseek-ai/cordis": "^4.0.4"
83
83
  }
84
84
  }