DSH-Receipt: Calculating the Cost of Blind Retries Burned at the Bottom Left of DSH

Introduction

When running agents in DeepSeek Harness (DSH), tool call failures are common: paths don’t exist, searches return empty results, and the model often tries again with the same set of parameters. The first failure can be considered normal exploration; an immediate, identical retry often yields nothing but still consumes tokens. In long sessions, it is hard to estimate the cost of these “blind retries” by feel.

The community plugin dsh-receipt (Maintainer: Sevyn-Star, Category: Model Reasoning) does not perform trajectory replay, nor does it alter proxy strategies within the conversation. It places a card in the bottom-left corner of the Web interface, calculating the amount of money “burned” on the spot using local pricing, and optionally inserts a reminder when duplicate calls occur.

What is this

dsh-receipt is a Web-side plugin for DSH, currently at version 0.1.0 (MIT License). Its positioning can be summarized as: a card in the corner, with a large number showing how much money was wasted in this session.

By default, the card shows only one big number; clicking it reveals three lines: how much this step cost, how much the entire session cost, and how much was wasted on blind retries (the big number corresponds to this third line). If there are spins with identical parameters in the session, an extra section “What is being repeated here” appears, summarizing the same action into a sentence, along with the count and approximate cost. The text indicates “Estimated by local pricing,” based on public unit prices, not platform bills.

Core Features

Blind Retry Detection

The plugin does not equate “verbose” with “expensive.” A call is only marked as wasted if all three of the following conditions are met:

  1. It is the same tool.
  2. It has the same set of parameters (different key order counts as the same set).
  3. The previous attempt failed or returned empty, and you did not send a new message in between.

Typical examples: reading a non-existent file twice in a row with the same path; performing an empty search twice in a row with the same query. If you said something else in between before retrying, changed the path, or if the previous attempt actually succeeded, it is not recorded. The first failure itself is also not recorded; if the call is still running and the result hasn’t returned, it is not counted yet.

If only some calls within the same step are blind retries, the waste is prorated based on the total cost and call count of that step. Steps in progress are first reflected in the “This Step” amount, and are only decided to be included in the big number after they finish.

Cost Display & Reminders

  • The entry text in the bottom left is “Burned”; click the black card to view details.
  • When reopening a finished session, the accounts are reconciled.
  • When a second identical retry with the same parameter set occurs, a sentence may appear in the conversation: “The previous identical call failed; do not retry with the same parameters.” This sentence does not block the tool. If not needed, set remind to false in the plugin configuration.

The plugin does not provide trajectories, replays, or themes; it does not check account balances, nor does it handle free models or quota bypasses.

Pricing & Model Mapping

Unit prices are copied from DeepSeek Public Pricing (data verified as of 2026-10-15). Estimates are based on “Off-Peak” (idle) rates by default; Peak rates are approximately double the Off-Peak rates, which can be set by writing period as peak in the configuration.

Off-Peak reference (per million tokens): Flash Cache Hit $0.003, Miss $0.15, Output $0.60; Pro Cache Hit $0.022, Miss $0.66, Output $1.98. deepseek-flash, deepseek-v4-flash, DeepSeek-V4.1-Flash, and paths involving SiliconFlow like deepseek-ai/DeepSeek-V4.1-Flash are priced as Flash. Models not in the price list show “Unpriced” rather than $0.

This is a local estimate; actual charges from SiliconFlow or other gateways may differ from the card. With high cache hit rates, the big number may be very small even if the token count is large (the README uses a deepseek-ai/DeepSeek-V4.1-Flash session as an example).

Installation & Activation

Prerequisite: dsh web opens normally on your machine. Run the following command in the root directory of the plugin repository (must keep -- -w, otherwise the pnpm workspace for the Web profile will refuse installation):

dsh plugin --profile web add "link:$(pwd)" -- -w

Then restart the Web:

dsh web

The “Burned” card should appear in the bottom left corner.

Typical Usage

  1. Install as described above and run dsh web.
  2. Chat with the agent normally; if a retry occurs with the same tool and parameters immediately following a failure or empty result, the big number will accumulate the estimated blind retry cost.
  3. Click the card to view the three lines: “This Step / Total Session / Blind Retries”; read the “What is being repeated here” summary if there are repetition patterns.
  4. Configure period: peak if you need peak time estimates; configure remind: false if you do not need in-session reminders (refer to cordis.patch.yml in the repository and DSH plugin configuration conventions for specific syntax).

Use Cases & Notes

Suitable for: Developers who debug toolchains in DSH Web for long periods, want to quickly perceive the estimated cost caused by “identical retries,” and do not want to pull logs separately for reconciliation.

Notes:

  • The plugin runs with the permissions of the current dsh process. Please review the GitHub Source Code and the MIT License before installing.
  • The DSH ecosystem advocates “Everything is a plugin”; the SkillHub Directory Page is a community collection and has no official affiliation with DeepSeek / High-Flyer.
  • Amounts are merely local calculations based on public price lists and cannot replace the real bills from inference platforms.

Conclusion

dsh-receipt consolidates duplicate, invalid tool retries into a single number in the bottom left corner, along with an optional in-session reminder, helping you see roughly how much was “burned” during the development phase. For instructions and installation details, see SkillHub: dsh-receipt and GitHub: Sevyn-Star/dsh-receipt.

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye