DeepSeek Harness Sidebar: Command Code Usage Panel

Introduction

When using DeepSeek Harness to invoke Command Code (GOAT Program), a common pain point is: how much quota remains in the current window, whether the current consumption rate will last until the next reset, and how the actual cost breaks down per model. If you only rely on the official pages, this information is scattered across multiple tabs and is difficult to track in one place.

Command Code Quota (dsh-comcode-quota) is a DSH client plugin that brings the core monitoring capabilities of the desktop cc-quota-monitor into a DeepSeek Harness sidebar panel. It supports remaining quota, consumption rate, reset countdown, and depletion prediction across three time windows (5-hour / weekly / monthly), and provides per-model usage breakdowns with pricing references.

Plugin Identity & Maintainer

  • Plugin name: dsh-comcode-quota
  • Maintainer: Chygyo
  • Category: Client
  • Current version: 1.0.10 (package.json)
  • License: MIT

Core Features

  • Three time windows: 5-hour, weekly, and monthly, each showing remaining/total, used percentage, reset countdown, burn rate, depletion prediction, maximum rate to sustain until reset, and daily budget.
  • Overview panel: Displays account info and last refresh time at the top, current cycle totals (tokens, request count, CLOUD minutes), a large-font remaining quota display, and cards for the three windows above.
  • Usage by Model: Reads the official /internal/usage/by-model endpoint to show per-model request counts, token usage, and this month’s quota consumption percentage. Supports filtering and sorting.
  • Pricing: Parses input/output/cache-read/cache-write prices for 75 models from the pricing page. Click column headers to sort, and display “requests remaining” (official window count, with an ≈ estimate when unavailable) based on the selected window (5-hour / weekly / monthly).
  • Settings: Configure credential source, API base URL, server fetch interval, timeout, history retention (including sample clearing), and thresholds.
  • Diagnostics: Version, Node.js version, credential source, data directory, sample count, last fetch latency, errors, and raw logs.
  • Credentials priority: 1. Manually saved in Settings; 2. DSH credential store (COMMANDCODE_API_KEY / CMD_GOAT_API_KEY / COMMAND_CODE_API_KEY); 3. Environment variables; 4. ~/.commandcode/auth.json (written by the CLI).
  • Usage by Model depends on a browser session: It reads Keychain-backed session cookies from a local browser profile, used solely for reading /internal/usage/by-model and never sent elsewhere.

Installation & Activation

The recommended approach is a one-click tarball installation (no cloning, no dependencies, no build required).

  1. Open DeepSeek Harness and navigate to Plugins → Add plugin.
  2. Paste the following URL:
https://github.com/Chygyo/dsh-comcode-quota/releases/download/v1.0.0/dsh-comcode-quota.tgz
  1. Once the plugin is enabled, a Quota row will appear in the sidebar below the Skill explorer.

This plugin requires DSH ≥ 0.2.2-rc.3. If the installation reports that engines.dsh is not satisfied, your current Harness version is below the requirement (older versions lack the sidebar.panellist slot, so the panel cannot be displayed).

Developers may alternatively clone the repository and pass the directory to plugin_manager’s target, or place it directly into ~/.dsh/bundles/dsh-comcode-quota and install from that directory.

Data & API

  • Data directory: ~/.dsh/dsh-comcode-quota/, containing settings.json, history.json, and app.log. Deleting this directory resets all state.
  • Host routes (all with loopback guard; cross-origin/proxy requests return 403):
GET  /api/dsh-comcode-quota/state
POST /api/dsh-comcode-quota/refresh
GET  /api/dsh-comcode-quota/settings
POST /api/dsh-comcode-quota/settings   # whitelisted + range-checked; {reset:true} restores defaults
GET  /api/dsh-comcode-quota/history    # ?since=<ms>
POST /api/dsh-comcode-quota/history-clear
GET  /api/dsh-comcode-quota/pricing    # ?in=&write=&cache=&out= overrides request config; ?window=fiveHour|weekly|monthly selects window
GET  /api/dsh-comcode-quota/by-model   # browser session auth
POST /api/dsh-comcode-quota/by-model/refresh
POST /api/dsh-comcode-quota/by-model/probe
POST /api/dsh-comcode-quota/credentials/probe   # re-reads all 4 credential sources
GET  /api/dsh-comcode-quota/diagnostics

Typical Usage

After enabling the plugin, in the sidebar Quota panel:

  • Switch between the five tabs — Overview, Usage by Model, Pricing, Settings, and Diagnostics — to view information from different dimensions.
  • In Settings, select the credential source and adjust the fetch interval and timeout.
  • In the Pricing tab, select a window (5-hour / weekly / monthly), and click column headers to sort and view per-model pricing and remaining requests.

Use Cases & Notes

  • Ideal for users who frequently use Command Code (GOAT Program) and want to integrate quota monitoring into their DSH workflow.
  • The plugin runs with the privileges of the current DSH process. It is recommended to review the repository source code and license (MIT) before installation.
  • The Usage by Model feature, which requires a browser session, requires you to be logged in to commandcode.ai in Edge/Chrome/Brave/Arc/Vivaldi. The plugin reads Keychain-backed cookies from your local browser profile.

Summary

dsh-comcode-quota migrates Command Code quota monitoring from a desktop application into a DeepSeek Harness sidebar panel, providing window-level remaining quota, burn rate and depletion prediction, per-model usage and pricing references across five tabs — with no additional installations or dependencies. For more details and source code, visit:

  • Plugin directory page: https://www.skillhub.cn/plugins/Chygyo/dsh-comcode-quota
  • GitHub repository: https://github.com/Chygyo/dsh-comcode-quota
羽毛球分组比赛记分
小程序二维码

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

Xiaoye