DSH-plugin-Billing-Capsule: A Session Cost Billing Pill for the DeepSeek Harness Composer Dock
cklyzzq/dsh-plugin-billing-capsule
Adds a billing capsule to the DSH composer dock that shows the current session's estimated cost at official DeepSeek prices, with token buckets and per-turn breakdown on click.
DSH-plugin-Billing-Capsule is a DSH plugin that places the running cost of the current conversation right in the Web GUI composer dock, converted to CNY at official rates with two decimal places. It removes the need to log into the platform dashboard to reconcile spending, so you can judge cost magnitude while chatting. Expanding the pill reveals cache-hit input, cache-miss input, and output token buckets with unit prices and subtotals, plus per-turn cost splits, the pricing model, and the price source. Prices sync from the official page via the host side, and models outside the list can be priced manually with peak and idle rates.
How to Install
dsh plugin --profile web add dsh-billing-capsule- Category
- UI & Experience
- Platform
- DSH Plugin
- Author
- cklyzzq
- Distribution
- Plugin
dsh-plugin-billing-capsule Key Features
dsh-plugin-billing-capsule Repo Summary
What Does It Do?
Billing Capsule is a DSH plugin for DeepSeek Harness that adds a billing pill to the Web GUI composer dock, showing the running cost of the current conversation in CNY based on DeepSeek's official price list. It removes the need to reconcile spending in the platform dashboard, letting you judge cost magnitude while you chat. Expanding the pill reveals four token buckets, the pricing model, the price source, and a per-turn breakdown, without modifying any built-in plugin.
Core Features
- Composer dock pill: adds a fourth item next to session stats, token usage, and context, displaying cumulative session cost with two decimal places.
- Per-turn breakdown: expands to show cache-hit input, cache-miss input, and output token buckets with unit prices and subtotals, plus per-turn usage.
- Peak and idle pricing: applies the official time-of-day rates and supports configured dates billed at idle rates.
- Automatic price sync: the host side fetches the official price page on activation and at a configurable interval, serving it through a local read-only route that the client polls to override the built-in baseline.
- Manual price overrides: lets you set input and output prices for models missing from the price list, with the highest priority.
- Estimate labeling: marks amounts with
≈when history is partially loaded or model routing is missing, estimating from whole-session totals so pagination never undercounts.
How to Use This Plugin?
After enabling it in DSH and refreshing the page, the billing pill appears on the right side of the composer dock and updates as the conversation grows. Click it to inspect the four token buckets, the active pricing model and price source, and the per-turn cost split. When official prices change, wait for the host side to refetch at its configured interval or trigger the local refresh route; if a site redesign breaks parsing, follow the README's price-update steps. To price a model outside the list, fill in its peak and idle rates in the model override config. Maintained by CKLYZZQ under the MIT license, the plugin has a zero-dependency client and can be installed across machines.
How to Troubleshoot This Plugin?
If the pill does not appear, the target profile likely lacks the conversation UI and per-turn data capabilities, or session totals are unavailable; add the required composition per the README. An amount prefixed with ≈ means history is partially loaded or turns lack model routing, which is expected estimation from whole-session totals. A "price unknown" notice means the model is absent from the price list; add a model price override as described officially. Fetch or parse failures do not block usage, and the popover shows which source is active; when the official page changes, follow the README's price-update steps.
This page is an independent rewrite of the plugin's official README — for authoritative documentation and the latest changes, refer to the source: cklyzzq/dsh-plugin-billing-capsule. The plugin is third-party code that runs on your machine once installed; inclusion does not imply endorsement — please review the source before installing.
