DeepSeek Harness 插件

dsh-thinkmeter

DSH client plugin: replace the streaming Think reasoning preview with a live token-count display.(英文原文)

跳到安装方式

来源信息

GitHub 仓库
dmz2922990/dsh-thinkmeter
最近更新
2026年8月21日
分类
用量与账单
GitHub stars
0
载体类型
plugin
目录证据
上游声明已找到 dsh.bundle
证据路径
package.json#dsh.bundle
核对版本
0.1.0-rc.8
上游核对日期
2026-08-20

该证据由上游目录提供。本站没有安装、运行或安全审核这个插件。

安装

默认先复制一段 Prompt,让 Agent 读 GitHub 仓库和源码;需要自己装时再切到命令。

复制这段 Prompt,发给 DSH、Codex 或其他 Agent,让它先读 GitHub 仓库和源码。

请先不要安装或执行任何命令。阅读这个插件的 GitHub 仓库、README 和关键源码,然后用清楚、直接的方式回答以下问题,帮助我判断它是否适合我的需求:

1. 这个插件是什么,解决什么问题;
2. 适合哪些用户和典型使用场景;
3. 安装后如何使用,并给出一个最小使用示例;
4. 有哪些已知限制,以及隐私、安全、兼容性或维护风险;
5. 给出“推荐 / 有条件推荐 / 不推荐”的明确建议和理由。

请区分仓库明确说明、根据源码推断和未知信息。证据不足时请明确说明,不要猜测或照抄 README。

GitHub:https://github.com/dmz2922990/dsh-thinkmeter
插件名:dsh-thinkmeter
作者:dmz2922990

检查来源文件

安装前先看这个插件目录里的 README 和其他文件。

文件资源管理器3 个文件
README.md来源说明 · 只读预览

dsh-thinkmeter (ThinkMeter)

A DeepSeek Harness (DSH) client plugin that replaces the streaming Think reasoning preview in the chat view with a live token-count display.

What it does

While the model is thinking, the shipped UI streams the latest line of the reasoning text in the "Think" disclosure row. This plugin replaces that summary with a token counter:

StateDisplay
RunningThinking ≈ 1,234 tokens (with sweep animation)
SettledThink · 1,234 tokens
  • Settled counts use the exact usage.reasoningTokens reported by the model when available; otherwise a heuristic estimate (CJK chars × 0.6 + other chars ÷ 4).
  • Click the row to expand/collapse the full reasoning text.
  • Keyboard accessible (Enter / Space toggles).

How it works

The package is a proper DSH profile bundle:

  • cordis.patch.yml — bundle patch inserting the thinkmeter plugin row (dsh.bundle.patch in package.json), so dsh plugin add reconciles it into the profile's layer list automatically.
  • index.js — empty host half (pure UI plugin).
  • client.js — browser bundle in the window.__ModuleLoader__.load format (exports["./client"], declared via dsh.client.platform: web).

The Think row itself is embedded inside the shipped assistant-step chat-node renderer, with no dedicated extension slot. The browser half registers the same keyed entry (conversation.chat.node, key assistant-step) in the Cordis slot system, shadowing the shipped renderer with a lightweight one. When the plugin is removed, the shipped renderer is restored automatically.

> Known trade-off: while this plugin is active, plain assistant text blocks render as pre-wrapped plain text instead of full Markdown, because the dynamic/lightweight renderer cannot reuse the shipped Markdown components.

Install

Command (recommended)

Install directly from GitHub into your profile:

dsh plugin --profile web add https://github.com/dmz2922990/dsh-thinkmeter.git

Replace web with the profile you use (e.g. tui, headless). The command forwards to pnpm add inside the profile directory, so any pnpm-supported specifier works (git URL, tag, local path).

Upgrade / remove:

dsh plugin --profile web up dsh-thinkmeter
dsh plugin --profile web rm dsh-thinkmeter

> If your machine has no GitHub credentials configured for git-over-HTTPS, use the SSH form: git+ssh://git@github.com/dmz2922990/dsh-thinkmeter.git.

Static composition

Clone the repo next to your DSH config, then add a row to your cordis.yml composition:

plugins:
  - name: dsh-thinkmeter
    path: ../dsh-thinkmeter

Or once the package is published to a registry:

plugins:
  - name: dsh-thinkmeter

Development

Plain JavaScript, no build step:

src/index.js   # the Cordis client plugin (default export)

The same logic can also be pasted as a dynamic Cordis plugin (cordis_define client code) inside a running DSH session.

License

MIT