dsh-ccswitch
No description
- Stars
- 0
- Language
- JavaScript
- Created
- Aug 24, 2026
- Updated
- Aug 24, 2026
Introduction
dsh-ccswitch
Import CCSwitch's skills and MCP servers into DeepSeek Harness in one plugin — without modifying DSH itself.
✨ Features
🧠 Skills
- 📂 Reads
~/.cc-switch/skills/<name>/SKILL.md(standard SKILL.md format) and registers them as actx.skillsprovider namedccswitch. - ⌨️ Typing / in the input box lists them (DSH's built-in ui-skill); picking one inserts
/nameand DSH's tool-skill injects the body into the prompt. - 🛡️ Same-name skills keep DSH's native version (rank 700 > bundled 600); CCSwitch-only skills fill in (e.g.
docx,xlsx,pdf,slides,alipay-payment-skill).
🔌 MCP
- 🗄️ Reads the MCP server list CCSwitch manages (
~/.cc-switch/cc-switch.db, tablemcp_servers) with Node's built-innode:sqlite(read-only, no native driver). - ⚙️ Mounts each enabled server as a
@deepseek-ai/dsh-mcp-clientinstance; its tools appear asmcp__<server>__<tool>and are callable like any other tool. - 🌐
http→streamable-http;stdio→stdio; unreachable endpoints auto-reconnect (failOnStartupError: false).
🤖 Models
- Automatically imports the providers/models configured in CCSwitch (
~/.cc-switch/cc-switch.db, tableproviders) into DSH'sllm-pi-ai.providersasccswitch-*routes. - Each imported route carries the CCSwitch base URL, the model list (from
ANTHROPIC_DEFAULT_*_MODEL/models/ Codexconfig), and a credential reference; the API keys are stored in DSH's credentials service (.credentials.yaml). - Wire protocol is derived per provider:
anthropic-messagesfor Claude-Code endpoints,openai-completionsfor OpenAI-style custom providers,openai-responsesfor Codex providers. Imported models declarelow…maxreasoning efforts. - Only
ccswitch--prefixed routes are ever touched — your manually configured routes (e.g.uu,ark) are preserved. Changes apply immediately; stale routes/keys are removed.
🖥️ Settings page
- One CCSwitch 导入 section with three cards (Skills / MCP / Models): master switches, paths, and per-item disable toggles. Changes apply immediately.
⚙️ Configuration
ccswitch:
skills:
enabled: true
path: ~/.cc-switch/skills
disabled: []
mcp:
enabled: true
path: ~/.cc-switch/cc-switch.db
disabled: []
models:
enabled: true
disabled: []
models.disabledlists CCSwitch provider names to skip.models.pathfalls back tomcp.path(same cc-switch.db).
🚀 Install
One-click copy: hover the code block below and click the copy button in the top-right corner.
1. Add the dependency:
dsh plugin --profile web add github:Elysiaqwq/dsh-ccswitch
2. Append the mount row to ~/.dsh/profiles/web/cordis.patch.yml:
- insert:
- id: dsh-ccswitch
name: dsh-ccswitch
3. Refresh the browser (F5) — the CCSwitch 导入 section appears in Settings.
⚠️ Do not mount it via the bundle layer (no
dsh.bundle.patch, not indsh.profile.bundles).
🧹 Uninstall
dsh plugin --profile web remove dsh-ccswitch
Then remove the - insert: … dsh-ccswitch … block from cordis.patch.yml, and optionally delete the ccswitch: section from settings.yaml.
🧪 Verify
cd dsh-ccswitch && node --no-warnings test-apply.mjs
Reads the real CCSwitch skills (77) and MCP servers (4), checks mappings, and drives apply() / reconcile against a stub ctx.
📦 Dependencies
- Node built-in
node:sqlite(v22.5+) for the DB — zero extra deps. - Runtime peers (
yaml,@deepseek-ai/dsh-settings,@deepseek-ai/schemastery) resolved through the$DSH_HOME/profiles/node_modulesfallback. @deepseek-ai/dsh-mcp-clientis resolved by name through the loader.