DeepSeek Harness plugin

DSH-Cache-Hit-Precision

A tiny dsh web plugin that shows the cache-hit rate with two decimal places in the chat stats line.

Jump to install

Source facts

Repository
luern0313/DSH-Cache-Hit-Precision
Latest update
Aug 16, 2026
Category
Tools & Capabilities
GitHub stars
1
Format
plugin
Catalog evidence
Upstream dsh.bundle evidence
Evidence path
package.json#dsh.bundle
Checked against
0.1.0-rc.8
Upstream check date
2026-08-20

This evidence comes from the upstream catalog. This site has not installed, run, or security-reviewed the plugin.

Install

Start with a prompt that asks an agent to review the GitHub repository and source. Switch to the command if you want to install it yourself.

Copy this prompt into DSH, Codex, or another agent and ask it to review the GitHub repository and source first.

Do not install or run any commands yet. Read this plugin's GitHub repository, README, and relevant source code. Then answer the questions below clearly and directly so I can decide whether it fits my needs:

1. What is this plugin, and what problem does it solve?
2. Who is it for, and what are its typical use cases?
3. How is it used after installation? Include one minimal example.
4. What known limitations or privacy, security, compatibility, or maintenance risks does it have?
5. Give a clear recommendation: recommend, conditionally recommend, or do not recommend, with reasons.

Distinguish statements documented by the repository, inferences from source code, and unknowns. If evidence is insufficient, say so explicitly. Do not guess or simply repeat the README.

GitHub: https://github.com/luern0313/DSH-Cache-Hit-Precision
Plugin: DSH-Cache-Hit-Precision
Author: luern0313

Check the source files

Read the README and other files from this plugin directory before installing.

File explorer3 files
README.mdSource · read only

DSH-Cache-Hit-Precision

DSH 插件:让状态栏下方的缓存命中率显示两位浮点数

📖 简介

它通过 dsh 的 slot 阴影机制包装原始 StatsLine,仅替换 stats.cacheHit 的本地化参数:从 tokenUsage 投影重新计算精确百分比,再以两位小数输出。

效果:

<img src="docs/example.png" width="640px" alt="效果示意图">

✨ 特性

  • 非侵入:不修改 dsh 安装目录与任何上游包
  • 原样保留统计行:轮次、步骤、耗时、TTFT、token 等显示均不变
  • 自动跟随当前语言:中文 / English

🚀 快速开始

GitHub 安装

dsh plugin --profile web add github:luern0313/DSH-Cache-Hit-Precision
# 安装后重启:
dsh web

本地安装

git clone https://github.com/luern0313/DSH-Cache-Hit-Precision.git
dsh plugin --profile web add ./DSH-Cache-Hit-Precision
# 安装后重启:
dsh web

手动安装(不使用 pnpm)

mkdir -p ~/.dsh/profiles/web/node_modules
ln -sfn /path/to/DSH-Cache-Hit-Precision ~/.dsh/profiles/web/node_modules/dsh-cache-hit-precision

然后在 ~/.dsh/profiles/web/cordis.patch.yml 末尾追加:

- insert:
    - id: cache-hit-precision
      name: dsh-cache-hit-precision

重启生效:

dsh web

🧩 工作原理

1. 找到 conversation.composer.dock 中 id 为 stats、优先级为 0 的原始统计行组件。 2. 以相同 id、更低优先级注册一个阴影组件。 3. 阴影组件渲染原组件,但拦截 stats.cacheHit:从 tokenUsage 重新计算缓存命中率,再格式化为两位小数。

📜 开源协议

MIT License