AI Agent Hub
Back to plugins
dsh-chat-cost preview

dsh-chat-cost

Memory Updated 2026.09.15

Run the following command in DeepSeek Harness:

dsh plugin install igormel81/dsh-chat-cost

Paste the following prompt into your AI chat to install this plugin:

Run dsh plugin install igormel81/dsh-chat-cost in your terminal to install the dsh-chat-cost plugin (full source at https://github.com/igormel81/dsh-chat-cost), then restart the host process to see live per-chat cost readouts in the Web UI.

About this plugin

When juggling sessions across DeepSeek, OpenAI, Anthropic, Google, and other providers in the dsh Web UI, the biggest blind spot is cost. Which subagent burned the budget? Did a session that crossed the peak window get billed at double rate? Without a plugin, the only way to find out is to dig through logs.

dsh-chat-cost puts the answers right in the interface: a hover tooltip on every chat splits spend into the chat itself, its subagents, and the full session tree; each finished answer carries its own per-turn cost badge in the transcript; the composer readout refreshes in sync. Pricing is drawn from a bundled snapshot of seven providers covering 139 models, with DeepSeek peak and off-peak tiers and the published cache-read and cache-write rates for every provider applied exactly as stated. Models without a published price show a dash, never a fabricated number. All spend is logged as append-only JSONL records in the .dsh-cost/ folder inside the project, and interval pricing ensures a chat spanning a peak boundary is billed at the tariff in effect for each segment, not retroactively re-priced.

Six budget tools round out the toolkit: look up per-token and cache rates, pull historical P50/P90 spreads, price a list of work units, pack them under a money cap, mark plan units for clean attribution, and compare routing strategies on quality and cost. No network calls, no telemetry, no accounts. Built for developers running multi-provider LLM workloads in dsh who want to see, at a glance, exactly what each turn costs and how much budget remains.

Screenshots

Use Cases

  • Track per-chat, subagent, and session-tree token spend live in the dsh Web UI
  • Record session cost against the tariff in effect during each interval, avoiding retroactive re-pricing
  • Pack work units under a budget cap and attribute spend to named plan units
  • Compare routing strategies on quality and cost to pick the best model fit

Best For

  • Developers running multi-provider LLM workloads (DeepSeek, OpenAI, Anthropic, Google, etc.) in dsh
  • Teams that need per-turn spend visibility, budget control, and traceable cost records
  • Users who prefer local-only cost logging with zero telemetry and no external service dependency