chiro2001/dsh-oc
DeepSeek Harness × OpenCode TUI 前端:将 dsh 的 Agent、会话和工具集成到官方 opencode 终端中。
Project Overview项目介绍
dsh-oc is a DSH-native plugin that integrates the official OpenCode TUI frontend with the DeepSeek Harness backend. The official OpenCode TUI handles all terminal rendering, keyboard interaction, and application lifecycle, while all core backend capabilities including agent management, session context, tool calling, model access, and permission control are provided by DSH. dsh-oc acts as a compatibility bridge between the two, running an HTTP/SSE server inside the DSH process that the OpenCode TUI connects to via the official opencode attach command. To install the current prerelease version, users can run dsh plugin --profile oc add chiro2001/dsh-oc and launch via dsh --profile oc.
After launching, users can enter regular tasks directly into the OpenCode TUI, just like they would with native OpenCode. Common control commands are supported out of the box, including ! to run user-authorized shell commands directly, /preset to list or switch DSH agent presets, /goal to create or view project goals, and /help to pull up a summary of available capabilities. Users can pass through most standard OpenCode launch parameters, including --continue to resume an existing session, --dir to set the starting working directory, and --mini to launch a stripped-down TUI without extra branding elements. This plugin is built for DSH users who prefer the OpenCode TUI workflow over the default DSH TUI.
All peer dependencies like @deepseek-ai/cordis are provided by the DSH host at runtime, so any warning about missing peers is expected and can be safely ignored. The current prerelease version has several known limitations: MCP, LSP, formatter, and other peripheral integrations only provide schema-valid stubs with no working implementation. Allow always permission settings are only stored in current session memory and are cleared when the application restarts. Shell commands executed via ! run with your current OS user permissions, and output is capped at 1MB per stream, so avoid including sensitive data like tokens in these commands.
dsh-oc 是专为 DeepSeek Harness(DSH)开发的原生插件,可为 DSH 提供官方 OpenCode 终端用户界面(TUI)。它依托 DSH 后端提供代理、会话、工具、模型、权限和提问能力,仅负责提供 DSH 与官方 OpenCode TUI 之间的兼容桥接,由官方 OpenCode TUI 处理终端渲染、键盘交互和生命周期管理。
安装 dsh-oc 可通过 DSH 自带的插件命令完成,需要使用名称为 oc 的专属 profile 进行隔离。安装完成后,将 profile 的 bin 目录添加到系统 PATH 环境变量,即可使用 dsh-oc 简写命令启动。开发者如果偏好 OpenCode 的终端交互体验,同时希望使用 DSH 提供的后端能力,就可以通过这个插件获得适配好的体验。
dsh-oc 的依赖如 @deepseek-ai/cordis 等都由 DSH 宿主在运行时提供,不会要求用户额外安装。当前兼容基线是 DSH >= 0.1.5-rc.2,官方 OpenCode 二进制锁定为 1.18.18,自动更新功能默认关闭。MCP、LSP 等外围能力目前仅提供占位桩,shell 模式输出有大小限制,使用时需要注意防范敏感信息泄露。
请帮我安装这个 DSH 插件。安装前先完成【兼容性检查 + 安全性检查】,检查通过再动手。
插件:dsh-oc(chiro2001/dsh-oc)
仓库:https://github.com/chiro2001/dsh-oc
本站详情页:https://www.yhbd.top/plugins/chiro2001-dsh-oc/
本站登记:类型 client · 归类 原生 DSH 插件 · 许可证未声明 · ⭐ 7 · 最近提交 2026-09-11 · 主语言 TypeScript
按下面顺序执行,每步先把结论告诉我,再进入下一步:
【1 兼容性检查】
① 我这边:DSH 版本、Node 版本、操作系统、当前 profile(web / desktop)。
② 读它的 README、package.json、插件 manifest,列出它要求的 DSH 版本 / Node 版本 / 操作系统 / 外部依赖 / 需要另外先装的运行时。
③ 逐条比对,结论只写「满足 / 不满足 / 未知」三种;不满足的给出可行替代方案。
④ 检查是否和我已装的插件冲突:命令名重复、skill / tool 重名、端口占用、重复注册的 MCP server。
【2 安全性检查】
① 仓库可信度:和上面「本站登记」是否一致;star / fork 数、创建时间、最近提交,是否归档或长期停更。
② 安装脚本:逐行看 package.json 的 preinstall / install / postinstall,以及 install.sh、setup.ps1 之类脚本。出现 curl|bash、下载后直接执行、混淆代码、访问与插件功能无关的域名,立刻停下来告诉我,不要继续装。
③ 依赖:列出新增依赖,标出无人维护、或与知名包拼写近似的可疑包(typosquatting)。
④ 权限与副作用:它会读写哪些目录、访问哪些域名、需要哪些 DSH 权限(filesystem / network / shell / clipboard 等),以及怎么卸载和回滚。
⑤ 如果它要求 sudo / 管理员权限,或权限明显超出功能所需,先停下来问我。
【3 安装】
上面两步没有「不满足」和「高危项」时才执行;用官方推荐方式安装,不要自行提权。
【4 汇报】
用表格输出:检查项 / 结论 / 依据 / 是否需要我决策。拿不准的一律写「未知」并说明要我怎么确认——不要猜,也不要替我决定。
Send this message to DSH in your current session: it verifies compatibility and security first (answering met / not met / unknown item by item) and only installs once everything checks out — it will stop and ask you if it finds a high-risk item. The box scrolls; the copy is the full prompt. CLI install commands may not be accurate across systems, so DSH is the safer route.把上面这条消息直接发给当前会话里的 DSH:它会先核对兼容性与安全性(逐条给「满足 / 不满足 / 未知」),确认没问题再安装,有高危项会停下来问你。框内可滚动,复制到的是完整提示词;安装命令不一定准确,发给 DSH 更稳。
- No license declared - all rights reserved by default; ask the author before commercial use or redistribution未声明开源许可证 —— 默认「保留所有权利」,商用或再分发前先问作者
- Only 7 stars - very few users, little community feedback星标只有 7,几乎没人在用,遇到问题缺少社区反馈
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 tui add '@deepseek-harness-tui/dsh-tui@0.10.0-beta.5'
把 chiro2001/dsh-oc 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-oc
DeepSeek Harness(dsh)的 OpenCode TUI 前端:使用官方 OpenCode 终端界面, 由 dsh 提供 Agent、会话、工具、模型、权限和提问能力。
工作方式
- 界面:官方
opencode attachTUI,只负责终端渲染、键盘交互和生命周期。 - 后端:dsh 负责 Agent、Session、工具、模型、权限和用户提问。
- 桥接:dsh-oc 在 dsh 进程内提供 OpenCode 兼容的 HTTP/SSE bridge,并启动官方 TUI。
dsh (Node) ── dsh-oc bundle ── oc-bridge (HTTP/SSE) <── opencode TUI (attach)
│
└─ DSH Agent/Session/Tools/LLM/Approval/Questions
当前兼容基线:dsh >=0.1.5-rc.2、官方 opencode 1.18.18。
main 当前指向 GitHub prerelease v0.2.0-rc.4,
不是无标记的稳定版;npm registry 暂未发布,安装和更新走 GitHub 源。
安装并启动
使用 main 发布线(当前为 prerelease)
dsh plugin --profile oc add chiro2001/dsh-oc
dsh --profile oc
这里的 profile 名称是 oc,不是 dsh-oc。更新同一来源时重复执行上面的安装命令即可。
固定版本与开发线
需要固定当前 prerelease 时使用 tag;验证集成线时显式选择 develop:
dsh plugin --profile oc add 'github:chiro2001/dsh-oc#v0.2.0-rc.4'
dsh plugin --profile oc add 'github:chiro2001/dsh-oc#develop'
固定某个 tag 或完整 commit SHA 时使用相应 GitHub spec。npm 包名是
@chiro2001/dsh-oc,但目前未发布到 npm registry。
本地开发可用 dsh plugin --profile oc add . 链接工作树;修改 TypeScript 后执行
pnpm build 即可让 profile 使用新构建。
安装后也可使用 dsh-oc 简写。将 profile 的 bin 目录加入 PATH:
export PATH="$HOME/.dsh/profiles/oc/node_modules/.bin:$PATH"
dsh-oc # 等价于 dsh --profile oc
dsh-oc --mini # 等价于 dsh --profile oc --mini
dsh-oc --version # 同时输出 dsh-oc 与 dsh 的版本
pnpm 提示缺少 @deepseek-ai/cordis 等 peer 属于预期警告;这些依赖由 dsh 宿主在
运行时提供。
5 分钟上手
启动后可以直接输入普通任务,例如“只回复 OK”。常用的控制命令如下:
| 输入 | 作用 |
|---|---|
!,再输入 shell 命令 |
在完整 OpenCode TUI 中执行用户指定的 shell 命令 |
/preset |
列出可用的 dsh agent preset |
/preset minimal |
切换到 minimal preset,不触发模型回合 |
/goal <目标> |
创建或查看 goal,状态会同步到侧栏 |
/help |
在 TUI 中显示能力摘要 |
! shell mode
在完整 TUI 输入框输入 !,再输入例如 printf DSH_OC_SHELL_OK 并回车。命令经
dsh-oc 以当前 OS 用户身份启动精确的 shell 子进程(POSIX 仅使用绝对路径的
$SHELL -c,否则回退 /bin/sh;Windows 使用 ComSpec,缺失时回退
cmd.exe)。! 本身就是用户授权边界;它不经过 dsh 的模型工具、approval 或
sandbox waterfall。TUI 显示一张 shell tool card、输出和退出结果,但不会触发模型
回复;命令完成后会以明确标注“用户手动执行”的非唤醒 context 注入下一次真实 prompt,
让模型能看到命令和输出。注入本身不会开启新的 turn,session 被清理时不会迟到注入。
stdout/stderr 各自最多保留 1 MiB;超过后继续 drain 子进程,但在卡片中追加截断标记,
不会因为输出超过阈值而 kill 命令。发送给模型的 context 有独立预算:命令最多 16 KiB、
stdout/stderr 各最多 64 KiB、完整文本最多约 144 KiB,并带明确截断标记。
命令和输出会发送给当前配置的模型,可能包含 token、密码或个人数据;使用 ! 前请
确认不会泄露敏感信息。
Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →
robiteame/dsh-session-tree-extension
shiningsprk-arch/dsh-context-viewer
ming-14/PTY-Agent
kevenxz/dsh-desktop
ccch1mneyyy/dsh-TUI
xyTom/coding-tools-mcp