Preface

When running agents with DeepSeek Harness (DSH), model configuration is unavoidable. If you have been using cc-switch to manage Claude Code / Codex relay provider configurations, these ready-made providers cannot be used directly in DSH. The conventional approach is to re-enter the API addresses and keys in DSH and manually set up the routing.

dsh-cc-switch aims to solve exactly this: it syncs the managed provider configurations from cc-switch into DSH model routing with one click, without requiring any models to be pre-configured on DSH. In other words, a brand new DSH instance with zero models can start using your existing providers via this tool. DSH’s philosophy is “everything is a plugin,” and model integration can also be left to plugins to handle.

Below is an introduction to the plugin’s features, principles, and usage.

What is it?

dsh-cc-switch is a community plugin maintained by LKRCharon, open-sourced under the MIT license. It reads the local cc-switch SQLite database and maps the Claude Code / Codex relay provider configurations within it to DSH’s llm-pi-ai model routing.

Note: This is an unofficial plugin and has no affiliation with cc-switch or DeepSeek.

How it Works

The implementation of the plugin has three key points.

  1. Opens the local cc-switch SQLite database in read-only mode and never modifies cc-switch itself.
  2. Maps providers to llm-pi-ai routing via the DSH settings seam. Changes take effect on the next request without needing a restart.
  3. API keys are stored as references via the DSH credential seam (CCS_*_KEY), and the key values do not appear in settings, tool outputs, or model context.

Routing Mapping Rules

cc-switch Provider DSH Route
codex provider openai-responses / openai-completions
claude provider anthropic-messages
Official OAuth provider Skipped (pi-ai cannot do OAuth)
gemini / claude-desktop Temporarily skipped (roadmap)

Installation and Enablement

First execute the installation command, then restart DSH:

dsh plugin --profile web add dsh-cc-switch

The plugin defaults to syncOnStart: true, performing an automatic sync when DSH starts. Providers in cc-switch will immediately appear in the model selector.

If your DSH has never been started, you can also sync directly in the terminal without installing anything:

npx dsh-cc-switch            # Sync immediately
npx dsh-cc-switch --dry-run  # Preview only

Four Synchronization Methods

Sync can be triggered from four entry points; choose as needed:

  1. Terminal CLI: Run npx dsh-cc-switch to sync immediately, or add --dry-run for a preview only. No installation required; usable even before the first DSH launch.
  2. Startup Auto-Sync: syncOnStart is enabled by default, automatically executing a sync when DSH starts.
  3. Human Command: Enter /ccswitch in the composer to sync, or /ccswitch dry for a preview. Requires DSH to be running.
  4. Proxy Tool: Have the agent call the ccswitch_sync tool to complete the sync. Requires an available model and DSH to be running.

Configuration

Configuration can be overridden line-by-line in the profile’s cordis.patch.yml. For example, to disable startup auto-sync:

- id: cc-switch
  config:
    syncOnStart: false

All configurable items and default values are as follows:

Config Item Default Value Description
dbPath ~/.cc-switch/cc-switch.db cc-switch database location
prefix ccs- Route ID prefix
apps ['codex', 'claude'] Application types to sync
syncOnStart true Execute a sync when the plugin loads

Use Cases and Notes

Suitable for two scenarios:

  • Already using cc-switch to manage Claude Code / Codex relays and want to bring these configurations directly into DSH.
  • A brand new DSH instance with no model configurations, wanting to start with existing providers.

Pre-use notes:

  • This is an unofficial community plugin running with the permissions of the current DSH process and will read the local cc-switch database. Before installing, it is recommended to review the source code and license; the repository address is at the end of the article.
  • The plugin has been tested against the cc-switch DB schema from August 2026 and DSH v0.1 developer preview. Since both sides are iterating quickly, version locking is recommended. Current version 0.1.0, requires Node >= 22.13, and depends on @deepseek-ai/dsh-tools ^0.0.1-rc.1 and yaml ^2.6.0.
  • Providers deleted in cc-switch will not be automatically removed from DSH settings for now. You need to manually delete the residual ccs-* routes in Settings → Models.
  • Official OAuth providers will be skipped; gemini mapping, the “Import from cc-switch” button on the Models settings page, and DB change listening are planned features.

Summary

After the steps above, the providers managed in cc-switch can directly become DSH model routes: no need to re-enter keys, and no requirement that models already exist on the instance. For those using both cc-switch and DSH, this is a ready-made integration path.

  • Plugin Directory Page: https://www.skillhub.cn/plugins/LKRCharon/dsh-cc-switch
  • GitHub Repository: https://github.com/LKRCharon/dsh-cc-switch

(Note: The directory page comes from an independently operated community plugin directory and has no official affiliation with DeepSeek or Hypothesis.)