283Gawin/dsh-heatmap
DSH Web GUI 活动热力图插件:侧边栏中展示类似 GitHub 风格的提交/令牌/支出热力图,并提供按模型估算的成本。
Project Overview项目介绍
This is a native DSH plugin that adds an activity heatmap panel to the left sidebar of the DSH Web GUI. It displays 90 days of activity data that can be toggled between three different dimensions: commit count, total token usage, and estimated cost in USD with optional CNY conversion. The panel also shows today’s total tokens, cache hit rate, and automatically calculates cost based on the specific model used for each call. The heatmap matches DSH’s built-in light and dark theme modes for a clean consistent user experience.
This plugin is built for developers who want to track their DSH usage activity and token-related spending. The heatmap uses a GitHub contribution-style grid layout, with color intensity graded based on the selected data dimension. Hovering your cursor over any day will pull up a detailed breakdown of that day’s commits, token usage, and spending. The panel docks by default at the bottom of the left sidebar below the workspace list, and it supports folding via clicking the panel title, with the folded state automatically saved locally between DSH sessions.
Installation can be done either by cloning the source repo, building it with pnpm, and linking it locally to your DSH instance, or by installing the pre-built version directly from npm. After installation, you will need to restart DSH Web for the plugin to load correctly. One important caveat is that you have to add the plugin’s namespace activity-heatmap to DSH’s whitelist of allowed settings namespaces, otherwise the plugin’s configuration card will not load properly. This change will be overwritten when you upgrade DSH, so you will need to re-apply it after each upgrade. The plugin is open source under the MIT license, and includes preloaded pricing for most major large language models.
这是一款专为 DeepSeek Harness (DSH) Web GUI 开发的原生插件,会在 DSH 左侧边栏添加常驻的活动热力图面板。它支持展示近 90 天的活动数据,可在提交次数、Token 用量、估算花费三个维度间切换,还会在热力图下方显示今日所有会话的 Token 总数、缓存命中率,并按调用模型自动计算花费。插件适配 DSH 的浅色/深色主题模式,界面适配良好。
这款插件面向需要追踪自己 DSH 使用行为和 Token 花费的开发者。日常使用中,热力图采用类似 GitHub 贡献图的网格布局,颜色深浅按所选维度分级,鼠标悬停即可查看当日各项明细数据。面板默认常驻在左侧栏底部工作区列表下方,支持点击标题折叠,折叠状态会自动持久化保存,用户可以根据自己的使用习惯灵活调整面板的显示状态。
你可以通过源码构建后本地链接安装,也可以直接从 npm 下载已发布的版本安装,安装后重启 DSH Web 即可使用。需要注意的是,当前 DSH 要求新插件的命名空间添加到白名单,否则设置页无法显示插件配置,升级 DSH 后白名单修改会被覆盖,需要重新操作。插件采用 MIT 许可开源,内置主流大模型的公开定价可直接使用。
请帮我安装这个 DSH 插件。安装前先完成【兼容性检查 + 安全性检查】,检查通过再动手。
插件:dsh-heatmap(283Gawin/dsh-heatmap)
仓库:https://github.com/283Gawin/dsh-heatmap
本站详情页:https://www.yhbd.top/plugins/283gawin-dsh-heatmap/
本站登记:类型 plugin · 归类 原生 DSH 插件 · 许可证 MIT · ⭐ 5 · 最近提交 2026-08-14 · 主语言 TypeScript
按下面顺序执行,每步先把结论告诉我,再进入下一步:
【1 兼容性检查】
① 我这边:DSH 版本、Node 版本、操作系统、当前 profile(web / desktop)。
② 读它的 README、package.json、插件 manifest,列出它要求的 DSH 版本 / Node 版本 / 操作系统 / 外部依赖 / 需要另外先装的运行时。
③ 逐条比对,结论只写「满足 / 不满足 / 未知」三种;不满足的给出可行替代方案。
④ 检查是否和我已装的插件冲突:命令名重复、skill / tool 重名、端口占用、重复注册的 MCP server。
【2 安全性检查】
① 仓库可信度:和上面「本站登记」是否一致;star / fork 数、创建时间、最近提交,是否归档或长期停更。
② 安装脚本:逐行看 package.json 的 preinstall / install / postinstall,以及 install.sh、setup.ps1 之类脚本。出现 curl|bash、下载后直接执行、混淆代码、访问与插件功能无关的域名,立刻停下来告诉我,不要继续装。
③ 依赖:列出新增依赖,标出无人维护、或与知名包拼写近似的可疑包(typosquatting)。
④ 权限与副作用:它会读写哪些目录、访问哪些域名、需要哪些 DSH 权限(filesystem / network / shell / clipboard 等),以及怎么卸载和回滚。
⑤ 如果它要求 sudo / 管理员权限,或权限明显超出功能所需,先停下来问我。
【3 安装】
上面两步没有「不满足」和「高危项」时才执行;用官方推荐方式安装,不要自行提权。
【4 汇报】
用表格输出:检查项 / 结论 / 依据 / 是否需要我决策。拿不准的一律写「未知」并说明要我怎么确认——不要猜,也不要替我决定。
Send this message to DSH in your current session: it verifies compatibility and security first (answering met / not met / unknown item by item) and only installs once everything checks out — it will stop and ask you if it finds a high-risk item. The box scrolls; the copy is the full prompt. CLI install commands may not be accurate across systems, so DSH is the safer route.把上面这条消息直接发给当前会话里的 DSH:它会先核对兼容性与安全性(逐条给「满足 / 不满足 / 未知」),确认没问题再安装,有高危项会停下来问你。框内可滚动,复制到的是完整提示词;安装命令不一定准确,发给 DSH 更稳。
- Only 5 stars - very few users, little community feedback星标只有 5,几乎没人在用,遇到问题缺少社区反馈
DSH walks through these 9 checksDSH 会逐条核对这 9 项
Compatibility兼容性
- DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
- External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
- Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册
Security安全性
- Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
- Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
- curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
- Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
- Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
- Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式
Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。
Or use CLI install (for developers)或使用命令行安装(适合开发者)
CLI Install命令行安装
dsh plugin --profile web add github:283Gawin/dsh-heatmap
把 283Gawin/dsh-heatmap 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-activity-heatmap
DSH Web GUI 左侧栏活动热力图插件:常驻显示近 90 天的活动热力图,可在 「提交次数 / Token 用量 / 估算花费」三个维度间切换;热力图下方固定一行显示 今日所有会话消耗的 Token 总数、缓存命中率,并按每次调用实际使用的模型 自动计算花费(USD,可配汇率显示 CNY)。
效果图
左侧栏热力图面板(浅色 / 深色模式):
| 浅色 | 深色 |
|---|---|
![]() |
![]() |
设置页「插件」分区中的配置卡片(浅色 / 深色模式):
| 浅色 | 深色 |
|---|---|
![]() |
![]() |
功能
- 近 90 天热力图(固定窗口):GitHub 贡献图式网格(周一至周日 × 按周 分列),颜色深浅按所选维度分级(对数刻度);鼠标悬停显示当日明细 (提交数 / Token / 花费)。
- 维度切换:提交(所有 DSH 工作区 git 仓库,不含 merge)、Token(billed 总量)、花费(按模型定价)。选择记忆在浏览器 localStorage。
- 统计块(参考 Codex 个人资料页形态):今日 Token 总量、今日缓存命中率 (cacheRead / (cacheRead + cacheWrite + miss input))、今日花费,以及 近 90 天窗口的 Token / 提交 / 花费合计与今日按模型的花费细分。
- 常驻侧栏:面板常驻左侧栏底部(工作区列表下方),自愈式挂载(React 重渲染后自动复位),可点击标题折叠,折叠状态持久化。
- 设置卡片:注册在设置页「插件」分区(settings.plugin.item),支持主题 (蓝色 / 绿色)、enabled、includeMerges、USD→CNY 汇率配置;也支持插件行 config。
- 数据来源:host 进程经官方 SDK 读取——sessionPersistence 列出全部会话 并重放其 durable 日志(assistant/message 携带的 provider usage、 request/header 与 request/context 携带的模型名),subprocess 跑 git log 统计各工作区每日提交。聚合结果 TTL 缓存 60s, 经 GET /activity-heatmap/stats 提供。
安装
git clone https://github.com/283Gawin/dsh-heatmap
cd dsh-heatmap
pnpm install && pnpm build # link 安装需要构建产物(lib/)
dsh plugin --profile web add link:$PWD
或从 npm 发布版安装:
dsh plugin --profile web add @linxin666/dsh-client-ui-activity-heatmap
重启 dsh web 后,左侧栏即出现热力图面板。
设置页暴露:DSH 宿主对配置客户端可见的 settings namespace 有一个 白名单(
dsh-host-apiproxy的WEB_SETTINGS_NAMESPACES,官方包内 hardcode)。新插件必须把它的 namespace 加进该白名单,否则设置页卡片显示 "Settings not available for this plugin."。本插件需要把"activity-heatmap"追加到该数组;升级 dsh 后该修改会被覆盖,需重新 打补丁。修改后重启 dsh web 生效。
配置
设置页「插件 → 活动热力图」卡片可配置以下字段(等价于插件行 config):
| 键 | 类型 | 默认 | 含义 |
|---|---|---|---|
| theme | string | blue | 热力图主题色:blue / green |
| enabled | boolean | true | 插件总开关 |
| includeMerges | boolean | false | 提交数是否计入 merge 提交 |
| usdCnyRate | number | 0 | USD→CNY 汇率,0 表示不显示人民币 |
| priceOverrides | 文本行 | {} | 模型定价覆盖(见下) |
Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →




edison7009/EchoBird
edonadei/caliper
Aisland-SJL/dsh-usage
Make0209/dsh-usage-stats
Witherwithwinter/DeepSeek-Balance-Whale-Widget-Bowl
HaoyueQin/dsh-usage-statistics-panel
jelly-000/dsh-balance-monitor