GongYuanCaiJi/dsh-copilot-sdk

桥接 GitHub Copilot 订阅至 DeepSeek 工具链(源自 github/copilot-sdk 的移植)

Project Overview项目介绍

dsh-copilot-sdk is a native DeepSeek Harness plugin that ports the upstream @github/copilot-sdk to DSH, allowing users to access all models available in their existing GitHub Copilot subscription directly from DSH's model selector. The core SDK library is copied verbatim from the upstream version 1.0.11, with only a thin DSH-specific bridge layer added to integrate the provider into DSH. To install the plugin, which is not yet published to npm, you can run the dsh plugin add command pointing to this GitHub repository or a local checkout of the code. If you use pnpm, you may need to update your pnpm-workspace.yaml to allow the build script and native dependency before it will install correctly.

This plugin is designed for developers who already have an active GitHub Copilot subscription and want to use the models from that subscription within their DeepSeek Harness workflow. After installation completes, you just need to restart DSH, and the copilot provider and all available models will automatically appear in your session model selector. You can run three DSH-side commands to manage the plugin: /copilot status checks the connection and number of available models, /copilot models lists all models, and /copilot stop shuts down the Copilot CLI runtime. Authentication defaults to your existing logged-in Copilot CLI user, so you do not need to set any extra credentials unless you want to use a custom token or BYOK setup.

dsh-copilot-sdk is released under the open-source MIT license, matching the license of the upstream @github/copilot-sdk project. A key security feature of the DSH bridge layer is that it rejects all tool execution requests from Copilot, so Copilot's shell commands, file editing tools, and other capabilities will never run on your local machine. Usage is billed according to your existing Copilot subscription, with each prompt counting toward your Copilot usage allowance, though BYOK (Bring Your Own Key) is supported for users without an active subscription. The upstream telemetry code is kept intact but disabled by default in this plugin, so no data is sent to third parties unless you explicitly enable it.

dsh-copilot-sdk是专门为DeepSeek Harness开发的原生插件,是上游@github/copilot-sdk的1.0.11版本移植,核心作用是将用户已订阅的GitHub Copilot模型池接入DSH,让Copilot订阅中的GPT、Claude、DeepSeek等模型直接出现在DSH的模型选择列表中。插件的SDK库完全与上游逐字一致,仅新增了适配DSH的桥接层代码,SHA-256校验可在THIRD_PARTY_NOTICES.md查看。

该插件适合已有GitHub Copilot订阅,想要在DSH中直接使用Copilot订阅模型的开发者使用。安装完成后重启DSH即可使用,插件会在首次调用模型或执行/copilot status命令时按需拉起Copilot CLI运行时,不需要额外配置,认证默认使用已登录的Copilot CLI账号。用户也可以通过环境变量配置自定义GitHub令牌,或是使用BYOK方式自带第三方API密钥。

该插件采用MIT许可证,依赖与上游保持一致,pnpm默认会拦截git安装的构建脚本和koffi FFI原生依赖,安装遇到报错时,需要按照提示将对应密钥添加到pnpm-workspace.yaml的allowBuilds配置项后重试。桥接层默认拒绝所有Copilot工具执行请求,仅允许聊天回答,不会在本地执行任何工具操作,默认也不开启遥测上报。

Pre-install check安装前体检Compatibility · Security兼容性 · 安全性 1 warning1 项注意
  • Only 5 stars - very few users, little community feedback星标只有 5,几乎没人在用,遇到问题缺少社区反馈
DSH walks through these 9 checksDSH 会逐条核对这 9 项

Compatibility兼容性

  • DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
  • External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
  • Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册

Security安全性

  • Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
  • Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
  • curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
  • Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
  • Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
  • Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式

Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。

Or use CLI install (for developers)或使用命令行安装(适合开发者)

CLI Install命令行安装

dsh plugin --profile web add github:GongYuanCaiJi/dsh-copilot-sdk

把 GongYuanCaiJi/dsh-copilot-sdk 加入你的 DSH 配置(web profile)即可启用。

READMEREADME

dsh-copilot-sdk

简体中文 | English

License: MIT upstream: @github/copilot-sdk

把 GitHub Copilot 订阅接进 DeepSeek Harness:一个 copilot LLM provider,直接使用你订阅里的模型(GPT、Claude、DeepSeek……),SDK 库与测试套件 100% 逐字移植自上游。

本插件是 @github/copilot-sdk(MIT,github/copilot-sdk)的 dsh 移植(port),版本钉在 1.0.11(commit 18002a81)。SDK 库本体与上游逐字一致(见 THIRD_PARTY_NOTICES.md 的 SHA-256 校验);.pi/ 下的桥接层是本移植自己的代码。喜欢的话,也请给上游一个 star ⭐

功能

  • Copilot 订阅即模型池:注册 copilot provider,订阅里可用的模型(gpt-5、claude-sonnet-4.5、deepseek-r1 等)直接出现在 dsh 的模型列表里
  • 复刻 Copilot CLI 引擎:SDK 自带 Copilot CLI runtime,无需单独安装 CLI;认证走你已有的 GitHub 登录 / token / BYOK
  • 纯聊天桥接:桥接层拒绝一切工具执行请求——Copilot 的 shell、文件编辑等工具绝不会在你的机器上代跑
  • 流式输出:assistant 文本与 reasoning(思维链)增量实时转发
  • /copilot 命令:status 查看连接与模型数、models 列出可用模型、stop 停掉 CLI runtime
  • 100% 逐字移植:SDK 库、docs、samples、测试套件(含离线 replay 的 e2e)全部原样保留,npm test 全绿

效果

dsh 会话中
   └─ 模型选择器里出现 copilot / gpt-5、copilot / claude-sonnet-4.5 …
        └─ /copilot status
             Copilot bridge: connected.
             Provider: copilot
             Models available: 8
             Requires a GitHub Copilot subscription (or BYOK …)
  • 每次模型调用对应一个一次性 Copilot 会话:订阅计费走 Copilot 的计费模型(每次 prompt 计入用量)
  • 无 Copilot 订阅时也可以用 BYOK(Bring Your Own Key),见下方 FAQ

安装

尚未发布到 npm —— 从 GitHub 或本地目录安装:

# GitHub 源(安装时 prepare 会执行 build)
dsh plugin --profile <你的-profile> add github:GongYuanCaiJi/dsh-copilot-sdk

# 本地路径(先在该目录 npm install)
dsh plugin --profile <你的-profile> add /path/to/dsh-copilot-sdk

pnpm 默认阻止 git 安装的构建脚本(prepare)。如果 add 报 allowBuilds 错误, 把 pnpm 打印的精确 key 加进 profile 的 pnpm-workspace.yaml 的 allowBuilds 再重试; 本插件的原生依赖(koffi FFI)可能被连带拦截,同样放行后重跑。

Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →

← 上一个 Prev dsh-web-novel-research 下一个 Next dsh-custom-mode →