OCG Balance Inquiry

DeepSeek Harness users need to monitor both the official DeepSeek balance and OpenCode Go 5-hour/weekly/monthly usage simultaneously. Checking the console or multiple interfaces directly is inefficient. This plugin combines these two data points into a floating capsule located next to the main interface.

This is a DeepSeek Harness client plugin maintained by verneuil. It displays both the official DeepSeek balance and OpenCode Go 5h/w/m usage in a floating window. It includes a same-named settings page for adjusting refresh behavior and UI options.

Features Overview

  • One screen, two data sets: Displays the official DeepSeek balance (in ¥) and OpenCode Go 5h/w/m usage in the same floating capsule. Click the floating window to refresh (a failure on one side does not affect the other).
  • Three rings: Uses rings to display percentages (default shows “remaining”; can be switched to “used” in settings). Color coding: remaining > 20% is green, ≤ 20% is amber, and ≤ 5% is red. The base ring is the same color at 32% opacity.
  • Thin light-track feedback: During updates, a thin light travels around the capsule perimeter at a constant speed. When complete, it converges into a full “closed ring.” If it fails, red is displayed.
  • Drag snapping: On release, the floating window automatically snaps to the nearest reference line (input box card edge / window edge). When dimensions change or the window is resized, it follows the anchor line and does not drift.
  • Fixed dimensions: The floating window does not change size in any state (the feedback layer is an absolutely positioned overlay and does not participate in layout).
  • Zero dependencies: Pure native JS, no build step, and no third-party runtime dependencies.
  • Chinese/English bilingual: All UI text switches instantly according to DSH language settings (floating window, settings page, menu names, and action hints).
  • Theme adaptive: Colors use only host theme tokens (--dsw-alias-*), and light/dark themes follow automatically. Switches, buttons, input fields, and badges reuse host component styles.

Installation

The DeepSeek Harness desktop version ships with node / pnpm, so no additional installation is required.

In DSH, open the Plugin Management page → “Install Plugin” dialog, paste any of the following specs and install (the dialog calls pnpm and can install only one at a time):

# GitHub 直装(推荐)
github:verneuil/dsh-opencode-go-usage

# 固定版本
github:verneuil/dsh-opencode-go-usage#v2.10.0

Equivalent command-line syntax:

dsh plugin --profile web add github:verneuil/dsh-opencode-go-usage

Note: The Plugin Management page rejects dependencies without a bundle patch; this package ships with cordis.patch.yml. After installation, refresh according to the page prompts.

Usage

  • Click the floating window: Immediately refresh balance and usage.
  • Drag the floating window: Move its position; it automatically snaps on release.
  • Settings page path: Settings → Plugins → OCG Balance Query.
  • Adjust display mode: Switch between “used” / “remaining” display modes on the settings page.
  • Manual actions: Manually refresh, adjust the auto-refresh interval, toggle balance display, and reset location on the settings page.

Design and Compatibility

  • Slot occupancy: Only occupies the official shell.overlay slot (replaceRisk=none) and does not obscure the official UI.
  • Styling principle: Styling uses only theme tokens; no shadows, no blur, and no hard-coded color values.
  • Technology stack: Does not import any Harness client packages; all controls are custom-built. The host side is responsible for fetching and parsing, while the client only reads the configuration projection.
  • Upgrades: Upgrades require uninstalling and reinstalling; direct overwrite installation is not supported.
羽毛球分组比赛记分
小程序二维码

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

Xiaoye