CaoNing3212/dsh-plugin-deepseek-balance
DeepSeek 余额显示
Project Overview项目介绍
This is a plugin for DeepSeek Harness. It displays your DeepSeek official API account balance before the session stats bar on the web UI, and supports click-to-refresh. It only works when using the official DeepSeek API with a configured API key, and hides automatically otherwise.
这是DeepSeek Harness的一款小插件,可在Web界面会话统计行前方显示DeepSeek官方账户余额,点击即可刷新。仅当配置DeepSeek官方API密钥并使用官方接口时显示,非官方接口、未配置密钥时会自动隐藏。
请帮我了解并安装插件:【dsh-plugin-deepseek-balance】【https://github.com/CaoNing3212/dsh-plugin-deepseek-balance】
Send this message to DSH in your current session. CLI install commands may not be accurate across systems — DSH will figure it out for you.把上面这条消息直接发给当前会话里的 DSH,让它帮你了解并安装。安装命令不一定准确,发给 DSH 更稳。
Or use CLI install (for developers)或使用命令行安装(适合开发者)
CLI Install命令行安装
dsh plugin --profile web add github:CaoNing3212/dsh-plugin-deepseek-balance
把 CaoNing3212/dsh-plugin-deepseek-balance 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-plugin-deepseek-balance
在 Web 界面输入框下方的会话统计行(**「2 轮 · 110 步 | LLM …」**那行)前面显示 DeepSeek 官方账户余额的小插件,例如:余额:¥69.94。点击可刷新。
只在使用 DeepSeek 官方接口(https://api.deepseek.com)且已配置 API key 时显示;代理/网关、未配 key、查询失败时自动隐藏。
- 主机半(
lib/index.js):挂载GET /dsh-balance,通过平台凭据服务读取DEEPSEEK_API_KEY(设置 → 模型 页面写入的那个),调用官方/user/balance。完全自包含,不依赖任何平台补丁。 - 客户端半(
lib/client.js):向conversation.composer.dock插槽注册order: -1的条目,排在自带的stats(order 0)前面。
安装(任意电脑)
方式 A —— 用 dsh 插件命令(需要 pnpm):
dsh plugin --profile web add <本插件文件夹的绝对路径>
# 重启 dsh web,浏览器刷新页面
方式 B —— 手动(无需 pnpm):
- 把整个
dsh-plugin-deepseek-balance文件夹复制到%USERPROFILE%\.dsh\profiles\node_modules\下 - 编辑
%USERPROFILE%\.dsh\profiles\web\package.json:dependencies加入"dsh-plugin-deepseek-balance": "1.0.0"dsh.profile.bundles数组追加"dsh-plugin-deepseek-balance"
- 重启
dsh web,浏览器刷新页面
卸载
方式 A:dsh plugin --profile web remove dsh-plugin-deepseek-balance
方式 B:手动删除上面登记的依赖、bundles 条目和 node_modules 里的文件夹,然后重启。
要求
- DSH web 0.1.0-rc.6(其他版本理论兼容,插槽名
conversation.composer.dock需存在) - 已配置 DeepSeek 官方 API key(设置 → 模型,或环境变量
DEEPSEEK_API_KEY)
MeteorNOX/DeepSeek-Balance-Whale-Widget
Han-1413141/dsh-cost-meter
zh667/TokenLedger
wssfk12138/dsh-damage-pulse
Ychris12138/dsh-usage-stats
Aisland-SJL/dsh-usage
yxxbc/dsh-balance-plugin
slywalker2006/dsh-passwords