Introduction

DeepSeek Harness (DSH) adopts a plugin-based architecture. The built-in pi-ai channel provides GitHub Copilot support, but the Web interface lacks an entry point for device-code login, making it inconvenient to manage Copilot accounts and model lists through the browser. This plugin reuses the DSH built-in channel and adds device-code login/logout functionality via the Web settings page. It also provides preset routing and model-list management capabilities, allowing users to use Copilot without manually maintaining API tokens.

Core Features

  • Device-code login / logout: Authorization is completed through a browser + device-code flow. Credentials are managed by the DSH built-in credential store, and logout is supported.
  • Preset provider routing: After installation, a GitHub Copilot route automatically appears on the Models page.
  • Model catalog fallback: The model list is automatically populated on the first login. Subsequent updates only append entries and do not override customized lists.
  • Model list management: Provides a checkbox-based management interface that supports adding, retaining, or deleting model entries.
  • Multilingual support: Automatically switches between Chinese and English according to the DSH settings.

Installation and Activation

Add the plugin using the official installation command:

dsh plugin --profile web add @inventec/dsh-copilot-auth

After installation, restart DSH Web and refresh the page.

Typical Usage

  1. Open Settings → GHC Settings (shown as GHC Settings in the English interface, located after Models), then click Authorize Login.
  2. At https://github.com/login/device, enter the device code displayed on the page (which can be copied with one click) to complete authorization. SSO organization accounts must click Authorize for the organization; if skipped, the login will not take effect.
  3. Return to the settings page and see Logged in. On the first login, the model catalog is automatically populated. Go to the Models page and select the GitHub Copilot route to use it.

Important Notes

  • Route prefix: The URL prefix /copilot-auth is hardcoded and cannot be configured.
  • Catalog update strategy: The model catalog follows an append-only strategy. Merging only supplements entries not previously seen locally; upstream metadata corrections to existing IDs are not synchronized.
  • Concurrency and recovery: Concurrency protection is implemented as a mutex within a single host process. Multiple instances/processes operating on the same directory are not supported. After a timeout, stale previews and configuration intents become invalid; the preview must be rerun or the stale intent must be explicitly ended.
  • Version compatibility: Depends on a DSH release-candidate version. Tested with 0.1.7-rc.2 through 0.2.0-rc.1 / rc.2, with a peer dependency on @deepseek-ai/cordis@^4.0.2.
  • Security: The plugin runs with the permissions of the current DSH process. It is recommended to review the source code and license before installation.

Conclusion

This plugin completes the user experience of the DSH built-in Copilot channel through the Web interface. For the complete documentation and source code, see the links below.