In the development workflow of DeepSeek Harness (DSH), real-time monitoring of context window usage and tracking session costs are common requirements. The dsh-context-dashboard sidebar plugin provides a lightweight solution for this by integrating key metrics into the workflow interface.

What Is It

This is a dashboard plugin that resides at the bottom of the DSH sidebar. It uses a collapsible panel to display the current session’s context usage, spending statistics, and account balance. The plugin is maintained by lcohvne-tomorin and is licensed under the MIT License.

It automatically switches the display logic between pay-as-you-go and Token pack billing modes based on the currently configured LLM channel, and it supports dynamically enumerating channels and models.

Core Features

  • Real-time context ring: Displays the percentage and specific values of context usage in the collapsed state (e.g., 128K/1M); click it to expand into the full panel.
  • Dual-mode support: Supports both pay-as-you-go (paygo) and Token pack billing modes; the panel automatically switches its displayed content according to the current channel.
  • Dynamic enumeration: The channel and model lists are dynamically retrieved through the DSH model selector, and new models can be entered directly.
  • Price catalog integration: Includes the official DeepSeek model price catalog, with peak/idle logic; other models are displayed as estimates.
  • Local history storage: Uses local storage to record rolling, weekly, and monthly usage history.
  • Custom overrides: Supports customizing unit prices via the “Unit Price Override Table” in settings.
  • Bilingual UI: The UI automatically follows the theme and supports switching between Chinese and English.

Installation and Enablement

To install this plugin, you need to use the full commit hash version.

pnpm dsh plugin --profile <profile> add github:lcohvne-tomorin/dsh-context-dashboard#4fdf5f4109132fe10496dc8785c15d7e31786c5e

Usage

  • Expand the panel: Click the “pill”-shaped area at the bottom of the sidebar (containing the ring indicator and numbers) to expand the full dashboard panel.
  • Mode switching: The panel automatically switches between pay-as-you-go and Token pack views based on the currently selected LLM channel.
  • Refresh balance: A refresh button in the top-right corner of the panel lets you force a recheck of the account balance.
  • Mock testing: Set the environment variable DSH_CD_BALANCE_MOCK=1 to drive mock balance data for testing.
  • Custom pricing: In the “Unit Price Override Table” on the settings page, you can enter custom unit prices for new models.

Notes

  • Network requests: The plugin sends balance query requests only to whitelisted channels (such as api.deepseek.com, dashscope.aliyuncs.com) and does not perform real-time price fetching.
  • File access: The plugin writes to the $DSH_HOME/storages/dsh-context-dashboard/ directory (including configuration, history, and collapse-state files).
  • Credential security: The plugin reads credentials only to generate the Authorization header; it does not persist them to disk, log them, or display them in the UI.
  • UI injection: The plugin displays its UI by injecting the sidebar.footer.action and settings.section slots; they are automatically removed on uninstall.
  • Data privacy: All usage history is stored locally and is not reported to any third party.
  • Dependency requirements: Node.js version 22 or higher is required.

Summary

dsh-context-dashboard is a plugin focused on local data statistics and UI presentation. It is well suited to DSH users who need to keep track of context consumption and cost in real time during development. Its core value is that it lets you access session status and balance information without navigating to another page, while maintaining a high level of data privacy.