deepseek-harness
deepseek-ai
DeepSeek Harness: Everything is a Plugin.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:Rannist/balance-dsh
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
DSH 插件:在 Web UI 中直接显示 DeepSeek 账户余额和当前会话 token/金额消耗。
余额 + 金额(带货币单位)+ 时段标签(高峰红 / 空闲绿)。金额按余额状态变色:充足绿色、偏低(<10)琥珀黄、为 0 显示红色"去充值"。/balance 命令:命令行查询余额明细和当前会话消耗。assistant/message Token usage。前提:已安装 DSH Desktop,且知道自己的 profile 目录(通常是 C:\Users\<你的用户名>\.dsh\profiles\desktop\)。
cd C:\Users\<你的用户名>\.dsh\profiles\desktop
pnpm add balance-dsh
cd C:\Users\<你的用户名>\.dsh\profiles\desktop
pnpm add "file:C:\path\to\balance-dsh-1.0.0.tgz"
cd C:\Users\<你的用户名>\.dsh\profiles\desktop
dsh plugin --profile desktop add github:Rannist/balance-dsh
用 npm 安装后,插件自带
dsh.bundle.patch(cordis.patch.yml),安装即自动注册,无需手动改 profile 的 cordis.patch.yml。只有用旧版 tarball/手动方式时才需要手动注册:
# profile 目录的 cordis.patch.yml(只有手动安装时才需要)
- insert:
- id: balance
name: balance-dsh
DEEPSEEK_API_KEY,或config.apiKey 中设置,或DEEPSEEK_API_KEY服务端界面改动需重启 DSH Desktop 后生效。
在插件注册项(或 cordis.patch.yml)中覆盖:
- id: balance
name: balance-dsh
config:
apiKey: sk-xxxx # 可选;缺省用 DEEPSEEK_API_KEY 环境变量/凭据
peakWindows: # 可选;默认周一至周五,如下
- {start: 9, end: 12}
- {start: 14, end: 18}
peakWeekdays: [1, 2, 3, 4, 5] # 可选;1=周一 … 5=周五,0/6=周末
price: # 可选;逐项覆盖对应模型价格(元/百万 tokens)
inputCnyPerMillion: 1.5
cacheReadCnyPerMillion: 0.05
cacheWriteCnyPerMillion: 0
outputCnyPerMillion: 4.5
注意:插件已自动按高峰/空闲时段计费(高峰价 = 目录价 × 2),不要再设置
config.peak: true,否则会重复翻倍。
cd C:\Users\<你的用户名>\.dsh\profiles\desktop
pnpm remove balance-dsh
如需删除手动注册行(若你手动加过),从 profile 的 cordis.patch.yml 移除对应的 balance 条目。
api.deepseek.com 的 /user/balance 端点发起一次余额查询。request/header、assistant/message 的 token usage)计算,不向 DeepSeek 之外的服务发送数据。| 模型 | 输入(缓存未命中) | 输入(缓存命中) | 输出 |
|---|---|---|---|
| deepseek-v4-flash | 1.5 | 0.05 | 4.5 |
| deepseek-v4-pro | 4.5 | 0.15 | 13.5 |
| deepseek-chat(旧) | 2 | 0.5 | 3 |
| deepseek-reasoner(旧) | 4 | 1 | 16 |
未识别模型按 deepseek-v4-flash 兜底;DeepSeek 调价后需同步更新 lib/index.js 的 MODEL_PRICING 与 lib/client.js 的 DEFAULT_PRICING。
MIT
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: 无有效分类标签。