dsh-balance-widget 0.3.1 → 0.3.2
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 +2 -2
- package/README.md +3 -3
- package/package.json +1 -1
package/README.en.md
CHANGED
|
@@ -31,7 +31,7 @@ A balance & cost widget for the [DeepSeek Harness](https://github.com/deepseek-a
|
|
|
31
31
|
- **Last prompt cost (estimate)** — Parses the current session file and prices the last turn's token usage, answering "how much did that last prompt cost".
|
|
32
32
|
- **Today total cost (estimate)** — Walks every session under `~/.dsh/sessions/` and sums today's (calendar day) token usage × price.
|
|
33
33
|
- **Token usage** — Also shows the session's input (incl. cache hits) / output tokens.
|
|
34
|
-
- **One-click top-up** — a "
|
|
34
|
+
- **One-click top-up** — a "Top up" link in the popover footer jumps to the official DeepSeek top-up page (platform.deepseek.com/top_up) in a new tab.
|
|
35
35
|
- **On-demand refresh** — No polling, no background requests; endpoints are only hit when you click the icon. Costs zero tokens to use.
|
|
36
36
|
|
|
37
37
|
## Why this plugin
|
|
@@ -123,7 +123,7 @@ If you mainly use DeepSeek-V4-Pro, point the pricing model at it for a more accu
|
|
|
123
123
|
modelId: deepseek-v4-pro
|
|
124
124
|
```
|
|
125
125
|
|
|
126
|
-
|
|
126
|
+
**Note**: `cordis.patch.yml` may already contain lines for other plugins — append new lines without touching existing ones.
|
|
127
127
|
|
|
128
128
|
## Pricing
|
|
129
129
|
|
package/README.md
CHANGED
|
@@ -31,7 +31,7 @@ DeepSeek Harness (DSH) Web GUI 的余额与成本小部件:在会话头部右
|
|
|
31
31
|
- **最近一次提问成本(估算)** — 从当前会话文件解析最后一个 turn 的 token 用量 × 单价,回答"刚才那条提问花了多少"。
|
|
32
32
|
- **今天总成本(估算)** — 遍历 `~/.dsh/sessions/` 下所有会话,累加今天(自然日)的 token 用量 × 单价。
|
|
33
33
|
- **Token 用量** — 同时展示本会话输入(含缓存命中)/ 输出 token 数。
|
|
34
|
-
- **一键充值** —
|
|
34
|
+
- **一键充值** — 弹层底部「去充值」链接直达 DeepSeek 官方充值页(platform.deepseek.com/top_up),新窗口打开。
|
|
35
35
|
- **按需刷新** — 无轮询、无后台请求;只有点击图标时才发起查询,不消耗任何 token。
|
|
36
36
|
|
|
37
37
|
## 架构
|
|
@@ -78,7 +78,7 @@ DSH 的插件配置统一放在这个文件里:
|
|
|
78
78
|
~/.dsh/profiles/web/cordis.patch.yml
|
|
79
79
|
```
|
|
80
80
|
|
|
81
|
-
|
|
81
|
+
**说明**:`~` 是你的用户主目录(macOS 是 `/Users/你的用户名`)。
|
|
82
82
|
|
|
83
83
|
### 全部配置项
|
|
84
84
|
|
|
@@ -121,7 +121,7 @@ DSH 的插件配置统一放在这个文件里:
|
|
|
121
121
|
modelId: deepseek-v4-pro
|
|
122
122
|
```
|
|
123
123
|
|
|
124
|
-
|
|
124
|
+
**提示**:`cordis.patch.yml` 可能有其他插件的配置行,追加时注意**不要改动已有的行**,只加新内容。
|
|
125
125
|
|
|
126
126
|
## 定价说明
|
|
127
127
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-balance-widget",
|
|
3
3
|
"description": "Balance & cost widget for the dsh web GUI: a corner icon in the conversation session header that shows the DeepSeek account balance and the current session's estimated spend on click. Host half proxies the official /user/balance API over ctx.webServer (loopback-only); client half renders the icon and popover. Zero external dependencies — works on Node 24.",
|
|
4
|
-
"version": "0.3.
|
|
4
|
+
"version": "0.3.2",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"files": [
|