DeepSeek Harness 插件

dsh-harness-mcp-server

Expose DeepSeek Harness agent capabilities as an MCP server, so an external MCP client (e.g. Hermes) can drive Harness to execute coding tasks. Hermes = brain, Harness = arms.(英文原文)

跳到安装方式

来源信息

GitHub 仓库
chushixixin/dsh-harness-mcp-server
最近更新
2026年8月15日
分类
自动化与任务
GitHub stars
9
载体类型
plugin
目录证据
上游声明已找到 dsh.bundle
证据路径
package.json#dsh.bundle
核对版本
0.1.0-rc.8
上游核对日期
2026-08-20

该证据由上游目录提供。本站没有安装、运行或安全审核这个插件。

安装

默认先复制一段 Prompt,让 Agent 读 GitHub 仓库和源码;需要自己装时再切到命令。

复制这段 Prompt,发给 DSH、Codex 或其他 Agent,让它先读 GitHub 仓库和源码。

请先不要安装或执行任何命令。阅读这个插件的 GitHub 仓库、README 和关键源码,然后用清楚、直接的方式回答以下问题,帮助我判断它是否适合我的需求:

1. 这个插件是什么,解决什么问题;
2. 适合哪些用户和典型使用场景;
3. 安装后如何使用,并给出一个最小使用示例;
4. 有哪些已知限制,以及隐私、安全、兼容性或维护风险;
5. 给出“推荐 / 有条件推荐 / 不推荐”的明确建议和理由。

请区分仓库明确说明、根据源码推断和未知信息。证据不足时请明确说明,不要猜测或照抄 README。

GitHub:https://github.com/chushixixin/dsh-harness-mcp-server
插件名:dsh-harness-mcp-server
作者:chushixixin

检查来源文件

安装前先看这个插件目录里的 README 和其他文件。

文件资源管理器3 个文件
README.md来源说明 · 只读预览

dsh-harness-mcp-server

> Expose DeepSeek Harness agent capabilities as an MCP server, letting any MCP client (e.g. Hermes) drive Harness to execute real coding tasks.

Hermes is the brain (pro), Harness is the arms (flash) — 1+1>2.

![npm version](https://www.npmjs.com/package/@chushixixin/dsh-harness-mcp-server) ![license](./LICENSE)

Why this exists

Harness ships a powerful agent runtime (tools, LLM, agents, sessions), but it is a Cordis app, not something another agent can call. This plugin turns Harness inside-out: it starts a real MCP server (StreamableHTTP) inside Harness and bridges Harness's core services — ctx.agents, ctx.agentPresets, ctx.tools — so an external "brain" can delegate real work to Harness's "arms".

Hermes (MCP client, brain)
   │  agent_run / task_inbox (HTTP)
   ▼
dsh-harness-mcp-server (MCP server, :8090)
   │  ctx.agents.create → mount 'standard' preset
   ▼
Harness agent (flash) — full toolset: bash, fs, todo, web…

Tools

ToolDirectionPurpose
echoVerify MCP connectivity
harness_list_toolsList Harness's registered tool names
agent_runHermes → HarnessRun a task synchronously and return a structured result
task_inboxHermes → HarnessPush a structured task (task + memory context + cwd) to an async queue
task_resultHermes ← HarnessPoll a queued task's structured result

Every task result is structured:

{
  "sessionId": "...",
  "assistantText": "final answer",
  "toolCalls": [{ "name": "bash", "args": "..." }],
  "toolResults": ["command output"],
  "changes": "what was changed",
  "verification": "how it was verified",
  "leftovers": "open issues"
}

This closes the loop between the client's persistent memory and Harness's coding: memory is fed into each task as context, and the result (changes / verification / leftovers) can be persisted back to the client's memory for the next run.

Install

Option A — from npm (recommended)

npm install @chushixixin/dsh-harness-mcp-server

Then reference the plugin from your Harness workspace (see the cordis patch below).

Option B — from source

Clone this repo inside your Harness workspace under packages/mcp/harness-mcp-server/ (the pnpm workspace matches packages/*/*, two levels deep):

cd /path/to/deepseek-harness
mkdir -p packages/mcp/harness-mcp-server
# copy this repo's files there, then:
corepack pnpm install

Register it in tsconfig.host.json references and tsconfig.base.json paths (see the Harness plugin docs), then build:

corepack pnpm exec tsc -b packages/mcp/harness-mcp-server
corepack pnpm run build:lib:host

Run

export DEEPSEEK_API_KEY=...
corepack pnpm dsh web --patch ./packages/mcp/harness-mcp-server/cordis.yml

The MCP server listens on 127.0.0.1:8090 (StreamableHTTP). Point any MCP client at http://127.0.0.1:8090/mcp.

> ⚠️ Security: by default the server binds to 127.0.0.1 only. It exposes unauthenticated remote code execution — do not bind it to 0.0.0.0 or expose it to the internet/LAN without adding authentication, TLS, and a reverse proxy first.

Hermes client config

printf 'n\nY\n' | hermes mcp add harness_plugin --url http://127.0.0.1:8090/mcp

cordis.yml (patch format)

- insert:
    - id: harness-mcp-server
      name: '@chushixixin/dsh-harness-mcp-server'
      config:
        http: true
        port: 8090
        host: 127.0.0.1        # 默认仅本机; 暴露前必须加认证
        # authToken: 'your-secret-token'     # 可选: Bearer token 认证
        # workspaceRoots: ['/workspace']      # 可选: cwd 白名单

Positioning

This is best used as a fallback tool, not a daily driver: for everyday code edits, drive your primary agent directly. Reach for this when you need context isolation (huge refactors that would blow the client's context) or parallel execution of unrelated tasks.

  • The agent session is reused per cwd (avoids re-loading project context on every call — roughly 15–20× cheaper than one-shot dsh headless).
  • Bash runs sandboxed (workspace-write): install bubblewrap on the host, or the sandbox will refuse write commands.
  • Each new MCP session gets its own McpServer + transport (an MCP McpServer connects to a single transport).

License

MIT