Introduction¶
DeepSeek Harness (DSH) adopts a plugin-based architecture, allowing developers to extend host functionality through plugins. For developers using Ollama Cloud, monitoring the remaining quota of a Cloud account (including the per-5-hour session quota and the weekly quota) usually requires manually opening a web page to check it. The dsh-ollama-usage plugin visualizes this process and integrates it into the DSH interface.
Core Features¶
The plugin provides the following capabilities:
- Session Usage: Displays the usage progress for each 5-hour session.
- Weekly Usage: Displays the quota usage for the current week.
- Sidebar Dual Bars: Permanently displays session usage and weekly usage at the bottom of the sidebar in a minimal dual-bar format, including percentage numbers.
- Full Plugin Detail Page Panel: Renders a complete usage panel on the plugin detail page, including history and countdown.
- Persistence: The API Key and usage snapshots are stored locally, supporting recovery across conversations or after restart.
- Auto Refresh: The host automatically queries usage, and invalid Keys are automatically cleared.
- Login Guidance: Guides users to create an API Key on ollama.com/settings and run detection.
Installation and Enablement¶
Install the plugin via CLI:
dsh plugin --profile web add dsh-ollama-usage
dsh --profile web
After installation, the plugin is automatically injected into the host.
Usage Steps¶
- Open the DSH plugin list and find
dsh-ollama-usage. - In the plugin panel, if not logged in, click the guidance link to jump to ollama.com/settings to create an API Key.
- Return to the plugin panel and click “Detect”, or use the terminal
ollama signinand then click “Re-detect local credentials”. - After successful detection, expand the bottom of the sidebar to see the dual bars displaying usage.
- If you no longer need the locally stored Key, you can click “Clear Stored Key” in the panel.
Data and Privacy¶
- Data Source: The plugin only sends query requests with a Bearer Token to
https://ollama.com/api/usage. - Local Storage: The API Key is stored in plaintext in the local directory
$DSH_HOME/storages/ollama-usage/usage.json, with file permissions set to 600. - Cleanup: Users can clear the stored Key at any time.
Compatibility¶
- Supports DSH >= 0.1.5-rc.1.
- For older versions of DSH (0.1.0-rc.5 ~ rc.8), use npm version 0.1.5.
Ecosystem Background¶
DSH aims to build a plugin ecosystem, and all plugins are community projects. This plugin is listed in the SkillHub directory, with its source code hosted on GitHub.