返回目录
其他 插件

dsh-client-ui-monitor

Auran-Lu/dsh-client-ui-monitor

用于监控当前会话额度消耗、预估费用及当前API余额/Used to monitor the current session's quota consumption, estimated costs, and current API balance.

Stars
3
Forks
0
Issues
0
更新
4 天前

PROJECT TOPICS

项目标签

INSTALL REFERENCE

安装参考

未验证
dsh plugin --profile web add github:Auran-Lu/dsh-client-ui-monitor

该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。

PROJECT README

README

image
image

@auranlu/dsh-client-ui-monitor

A DeepSeek Harness Web plugin that pins a usage dashboard to the bottom-left of the sidebar.

简体中文

It shows, live for the current session:

  • Token usage — input (with cache read/write), output.
  • Estimated cost — computed from DeepSeek's published pricing, displayed in CNY or USD.
  • API balance — your DeepSeek account balance, queried via GET https://api.deepseek.com/user/balance.

Features: Chinese/English toggle, currency selector (CNY/USD), manual balance refresh, auto-refresh every 30s.

Prerequisites

  • DeepSeek Harness web profile.
  • A DeepSeek API key configured in Settings → Models (stored as the DEEPSEEK_API_KEY credential).

Install

Method 1 — GitHub

dsh plugin --profile web add github:Auran-Lu/dsh-client-ui-monitor

After installing, register the plugin and restart:

Edit ~/.dsh/profiles/web/cordis.patch.yml and add this entry to its top-level array:

- insert:
    - id: ui-monitor
      name: '@auranlu/dsh-client-ui-monitor'

Then restart the server (dsh web) and expand the left sidebar.

Method 2 — one-sentence install (paste to an LLM agent)

Copy the whole block below to a coding agent that has shell access to the machine:

Install the DeepSeek Harness client plugin from github.com/Auran-Lu/dsh-client-ui-monitor: run dsh plugin --profile web add github:Auran-Lu/dsh-client-ui-monitor, then append this entry to the top-level array of ~/.dsh/profiles/web/cordis.patch.yml:

- insert:
    - id: ui-monitor
      name: '@auranlu/dsh-client-ui-monitor'

Finally restart the dsh web server and confirm the dashboard appears at the bottom of the left sidebar.

Configuration

Edit lib/client.js before installing / publishing:

Constant Default Meaning
PRICING.inputPerM 0.27 USD per 1M prompt tokens (cache miss)
PRICING.cacheReadPerM 0.07 USD per 1M prompt tokens (cache hit)
PRICING.cacheWritePerM 0.07 USD per 1M prompt tokens (cache write)
PRICING.outputPerM 1.10 USD per 1M completion tokens
USD_TO_CNY 7.2 USD → CNY exchange rate

How it works

  • Client half (lib/client.js) registers a component into the sidebar.footer.action slot and reads the current session's tokenUsage projection.
  • Host half (lib/index.js) registers GET /api/deepseek-balance, proxying DeepSeek's balance API with the stored key.

License

MIT

CLASSIFICATION EVIDENCE

分类依据

项目类型插件
功能分类其他
规则置信度

系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: 无有效分类标签。