DeepSeek Harness (DSH) adopts a plugin-based architecture. dsh-token-pulse is one of its local Token monitoring tools. It reads local session logs and generates a GitHub-style calendar heatmap, addressing the need to track Token consumption without cloud dashboards.
Installation and Enablement¶
- Ensure that Node.js ≥ 23.8 is installed locally (the plugin relies on the built-in
node:zlibfor zstd decoding). - Ensure that the DSH Web profile is running (
dsh webhas been started). - Run the installation command:
dsh plugin --profile web add dsh-token-pulse
- After installation is complete, restart the DSH Web service. You can then find the Token Pulse section on the settings page.
Core Features¶
- View Switching: Supports four views: week, month, quarter, and year.
- Week View: Each day is expanded into 24 hourly bar charts to observe peak time periods.
- Month View: Calendar cells display the date and daily usage.
- Quarter/Year View: Uses GitHub-style calendar cells. The quarter view is enlarged for easier observation, and the annual view uses a dual-row layout.
- Statistics Display:
- The top area displays statistical data for today, this week, this month, and the cumulative total.
- Supports Top 5 statistical data by model or provider.
- Data and Refresh:
- Local Persistence: Historical data is saved to disk, so deleting sessions does not lose records.
- Auto Refresh: Supports automatic refresh at intervals of 5 / 10 / 30 / 60 minutes, and manual refresh is also available.
- Language and Settings: Supports switching between Chinese and English interfaces.
Usage and Configuration¶
- Data Source: The plugin only reads local session logs. Please ensure that log files containing the
usagefield exist in the$DSH_HOME/sessionsdirectory; otherwise, the data may be displayed as 0. - Reset History: If you need to clear all historical statistics, go to the
...menu in the upper-right corner of the settings page and select “Reset History”.
Notes¶
- Time Zone: The plugin uses the Beijing time zone by default, and the week starts on Monday.
- Network and Billing: It makes zero network requests and zero billing API calls, operating only as a read-only tool.
Ecosystem Background¶
The DSH philosophy is “everything is a plugin.” This plugin is a community-maintained project under the MIT license, maintained by Hou-DL.