DeepSeek Harness Plugin Hub

Publish and manage complete Harness Profiles. Discover Plugins for your next setup.

Explore

PluginsPresetsDocsNews

Community

Publish a pluginContactReport an issue

Resources

Plugin Hub on GitHubDeepSeek HarnessSystem statusPrivacy notice
© 2026 DeepSeek Harness Plugin HubPowered byPaxTech

Independent and unofficial. Not affiliated with, authorized by, or endorsed by DeepSeek.

Token Usage Stats — DSH Plugin for DeepSeek Harness
DeepSeek Harness Plugin Hub
ProfilesPluginsCategoriesNewsDocsSign inManage Profiles
ProfilesPluginsCategoriesNewsDocsSign in
← Plugins

dsh-token-usage-stats

Token Usage Stats

DSH web plugin: cross-session token usage, request count, and optional cost analytics (ctx.tokenUsageStats), with a self-contained dashboard page and a sidebar footer entry.

The plugin will be installed here. Keep web if you are unsure.

npx -y @deepseek-ai/dsh plugin --profile web add github:jkStars/dsh-token-usage-stats#9d709a9e19bb3495a55f6d5c8ea56ff7a710c7e9
READMECompatibilityVersions

Compatibility and provenance

Token Usage Stats is published as dsh-token-usage-stats and currently resolves to version 0.3.13. The Hub verifies its manifest and preserves the exact installation source for reproducible installs.

DSH compatibility
*
Runtime surfaces
web
Release source
github
Registry updated
9/20/2026

Versions

0.3.13stable
9/12/2026
0.3.12stable
9/8/2026
0.3.11stable
9/8/2026
Show 9 more versionsCollapse versions
0.3.10stable
9/8/2026
0.3.9stable
9/4/2026
0.3.8stable
9/4/2026
0.3.7stable
9/3/2026
0.3.6stable
9/2/2026
0.3.5stable
9/1/2026
0.3.4stable
8/25/2026
0.3.3stable
8/22/2026
0.1.1stable
8/22/2026

Related plugins

Loading related plugins…

Latest
0.3.13
DSH
*
HMR
Process restart
Tree shaking
Safe tree shaking not declared
Unpacked size
Unavailable
Files
Unavailable
Surface
web
License
MIT
Source
github
GitHub
★ 1
Weekly downloads
1,001
Last push
9/12/2026
View source ↗Project homepage ↗
README badge

Click the badge to copy Markdown for your README.

Do you maintain this Plugin?Claim benefit · Priority security scan

Verify the GitHub repository declared in package.json to manage this listing. After you claim it, Hub will prioritize a security scan of the current version and publish the result when it passes.

Claim this Plugin →
Report an issue

Related plugins

More verified plugins in models-usage.

Usage@linxin666/dsh-usageUsage statistics plugin for the dsh web GUI: per-provider balance and coding-plan quota detection plus a live token usage ledger, with a dedicated pet bubble for the current providerWhale Widgetdsh-whale-widgetDeepSeek balance whale widget in the bottom-right corner of the DSH Web interface: balance/today’s usage/peak-off-peak pricing, customizable bubble click sequence (text/balance/today/peak-off-peak/image/random phrases and parallel weighted selection), per-line styles and fonts, floating quick editinUsage Stats@ychris12138/dsh-usage-statsToken usage heatmap, provider balances, and subscription quotas for the dsh web GUICodex Connectdsh-codex-connectChatGPT OAuth and Codex models for DeepSeek Harness.

README

dsh-token-usage-stats

简体中文 | English

DSH Web 插件:跨会话的 Token 用量、请求次数与可选成本统计(ctx.tokenUsageStats),自带独立仪表盘页面(/token-usage-stats,JSON 数据源 /api/token-usage-stats)以及侧边栏底部入口(页内模态框打开仪表盘)。

截图

侧边栏底部入口 — 点击「用量统计」打开仪表盘

使用入口

仪表盘 - 今天视图(成本堆叠、token 趋势、构成占比、按模型与 TOP 对话表)

仪表盘 - 今天

构成明细悬浮提示(悬停柱子查看分类明细)

仪表盘 - 悬浮提示

全部范围 - 按天视图

仪表盘 - 全部范围

说明:目前仅统计 DeepSeek 官方 API 的费用(token 用量、请求次数与成本基于本地 Harness 会话日志回放),不包含其它提供商/渠道的 API 费用。

安装

dsh plugin --profile web add dsh-token-usage-stats@0.3.13

插件的 cordis.patch.yml 会插入插件行;浏览器半区通过 dsh.client 清单自动加载。安装后重启宿主(或刷新 GUI)。

更新到新版本:

dsh plugin --profile web add dsh-token-usage-stats@latest

使用

从侧边栏底部入口打开仪表盘,或直接访问 http://<host>:<port>/token-usage-stats。

页面默认显示「今天」的按小时视图,可切换 今天 / 近 3 天 / 近 7 天 / 近 30 天 / 全部 范围,其中「近 7 天」、「近 30 天」和「全部」显示按天视图(「全部」在跨度较长时会自动按自然周或自然月折叠展示,确保图表清晰不拥挤)。每 10 秒自动刷新一次。仅当配置了模型定价时才显示成本金额。

配置

插入行支持 config.currency(成本显示货币)与 config.pricing(各模型每百万 token 的价格)。成本按高峰/闲时两档计价:高峰为北京时间 09:00-12:00、14:00-18:00,其余北京时段为闲时;周末(北京时间周六/周日)全天按闲时。用 peak/offpeak 两档的模型按使用时间取对应档位;只用四个平档键(uncachedInputPerMillion / cacheReadPerMillion / cacheWritePerMillion / outputPerMillion)的模型任意时段同价。默认行带 currency: CNY,以及 deepseek-flash 与 deepseek-v4-pro 的官方高峰/闲时定价(自动兼容 deepseek-v4-flash* 历史模型别名)。

在 profile 自己的 cordis.patch.yml 中覆盖示例:

- patch:
    - id: token-usage-stats
      config:
        currency: USD
        pricing:
          deepseek-flash:
            peak:
              uncachedInputPerMillion: 2.0
              cacheReadPerMillion: 0.04
              cacheWritePerMillion: 0
              outputPerMillion: 8.0
            offpeak:
              uncachedInputPerMillion: 1.0
              cacheReadPerMillion: 0.02
              cacheWritePerMillion: 0
              outputPerMillion: 4.0

开发

pnpm install   # devDependencies 通过 link: 指向本地 deepseek-harness checkout
pnpm run build # tsc -> lib/types, tsdown -> lib/index.js + lib/client.js

devDependencies 通过 link: 条目解析 @deepseek-ai/dsh-* 的类型,要求 harness checkout 位于本包上一级目录 ../deepseek-harness。运行时 peer 依赖由 dsh 宿主提供,不从 npm 安装。

发布

npm run build
npm publish    # 自动执行 prepublishOnly(npm run build)

仓库与反馈

  • npm:https://www.npmjs.com/package/dsh-token-usage-stats
  • 源码:https://github.com/jkStars/dsh-token-usage-stats

欢迎提 Issue 或 PR。