Introduction

DSH’s extension method leans towards “everything is a plugin”: Web interface functionality can be accessed via plugins, rather than writing every requirement into the main program. For scenarios using dsh for agentic development, a specific question arises: different providers and models have different token unit prices, and peak hours may be set; after a session runs, how can one directly see the input, output, and total cost for this session in the Web interface, rather than just seeing the token count?

dsh-token-pricing is a community-maintained third-party plugin used to configure token prices by provider/model in the dsh Web interface, and provide cost readings, a cost floating window, and cross-project cost statistics. It does not add tools, prompt segments, or setting values to model requests; documentation claims zero Token impact.

What is this

dsh-token-pricing is a third-party (unofficial) plugin for the dsh Web interface, maintained by the community, independent of the official release by deepseek-ai. It primarily solves three things:

  1. Configure US dollar prices by provider/model, including input misses, cache hits, and output.
  2. View session costs in the bottom data bar of the session and the cost floating window.
  3. Summarize by project and by model in a cross-project cost statistics panel.

The package name is dsh-token-pricing, the repository address is https://github.com/LightClear/dsh-token-pricing, and the license is MIT.

Core Features

  • Configure US dollar prices by provider/model: input misses, cache hits, and output.
  • Supports an arbitrary number of peak hours, using the peak price tier during those hours.
  • The bottom data bar of the session displays input, output, and total cost.
  • Provides a collapsible, draggable cost floating window, with two views: “Per Turn” and “Per Model”.
  • Provides a cross-project cost statistics panel, aggregating by project and by model.
  • Session detail pages support step-by-step breakdowns, time window filtering, and CSV export.
  • After modifying a price entry, historical session costs are recalculated based on the new price.
  • Does not add tools, prompt segments, or setting values to model requests; documentation claims zero Token impact.

Installation and Enablement

The following explains the process in the order of “confirm environment, install plugin, then start to verify.”

Prerequisites

Requires Node ≥ 22, pnpm, and a working dsh installation. The official CLI can be installed as:

npm i -g @deepseek-ai/dsh

You can also start from source:

pnpm dsh

Install to web profile

First, execute the package installation command:

dsh plugin --profile web add dsh-token-pricing

Documentation also provides a git source installation method:

dsh plugin --profile web add github:LightClear/dsh-token-pricing

Start and verify

After the above steps, start or restart the dsh Web:

dsh web

After starting, open Settings → Model Pricing to configure prices. The documentation describes successful behavior as: a cost ball appearing in the bottom right corner, and the conversation’s bottom data bar displaying cost readings.

Update and Uninstall

If update or uninstall is needed:

dsh plugin --profile web update dsh-token-pricing
dsh plugin --profile web remove dsh-token-pricing

Typical Usage

  1. Open Settings → Model Pricing, configure input misses, input hits, and output rates for a specific model.
  2. If peak pricing is needed, add multiple peak hours; use the peak price tier within the hours.
  3. Check the input, output, and total cost for the current session in the bottom data bar of the session.
  4. Expand the cost floating window and switch between “Per Turn” and “Per Model”.
  5. Open the cross-project cost statistics panel, use time windows (All/Today/7 Days/30 Days), include the archive toggle, and export CSV.

Note: Usage of models that are not configured with pricing rules or pricing routes will not be counted in cost readings, or will prompt “Pricing not set” in the view.

Applicable Scenarios and Notes

Suitable for developers viewing token costs for multiple models and multiple projects in the dsh Web interface. It does not add tools, prompt segments, or setting values to model requests; documentation claims zero Token impact.

Notes before use:

  • It is a third-party unofficial plugin maintained by the community, independent of the official release by deepseek-ai.
  • The plugin runs with the permissions of the current dsh process; check the GitHub repository source code and the MIT license in package.json before installing.
  • Documentation states this package only declares two self-use runtime dependencies (schemastery, zod), and installation will not pull in any internal packages.
  • If a plugin line with ID token-pricing already exists in the profile, installing will cause a conflict; one must be removed.
  • Usage of models not configured with pricing rules or pricing routes may not be counted in cost readings, or may prompt “Pricing not set” in the view.

Conclusion

The value of dsh-token-pricing is to turn the token usage in dsh Web sessions into cost readings viewable by model, by turn, and by project, and to recalculate historical session costs after modifying price entries. The documentation verified this time does not provide a referenceable community directory page URL; the GitHub repository is:

https://github.com/LightClear/dsh-token-pricing