icyaaaww/dsh-soul
icyaaaww/dsh-soul在本地记录重复的任务纠正与工具错误,通过显式启动的演化将经验编译为八类运行组件的改动,经过基线与候选成对验证、影子试用和回滚,并提供预算与审计账本。需要 Node.js 24+ 及兼容的 DSH 0.2.1-rc.2 起的 0.2.x 宿主。
把 DSH 变成一个 MCP server:让另一个 agent 实时看见它的思维、工具调用和文件改动,共享意图,持地板锁期间拒绝 DSH 的 write/edit/git 工具,插入中途提醒,并委托审查。
English | 中文
Exposes DSH as an MCP server, so any MCP client can watch what the agent is doing and steer it mid-flight.
Two agents on one workspace normally means two agents overwriting each other. This bridge gives them a shared protocol instead: what the other side is thinking, what it's touching, who owns the floor, and a way to interrupt.
Capability · Mechanism See the agent think · LLM stream deltas → notifications/dsh/thinking (200 ms throttle) See what it touches · tool calls → notifications/dsh/tool; write/edit targets → notifications/dsh/file Share intent · dsh_set_intent / dsh_get_intent, auto-injected into DSH's system prompt every turn One writer at a time · dsh_lock_acquire / dsh_lock_release floor lock — while held, DSH's write/edit/git are physically denied Interrupt the current turn · dsh_inject_alert → injected through agent/pre-step into the running step Delegate a review · dsh_review_request → inbox on disk (inbox/.json), result written back to inbox/done/
dsh_get_status · dsh_get_intent · dsh_set_intent · dsh_lock_acquire · dsh_lock_release · dsh_lock_status · dsh_inject_alert · dsh_review_request
notifications/dsh/status · thinking · tool · file · intent · lock · alert-queued · review
dsh plugin --profile web add dsh-as-mcp-serverThen add the bridge to your MCP client — any client speaking Streamable HTTP works (WorkBuddy, Claude Desktop with an MCP-HTTP adapter, Cursor, Cline, …):
{
"mcpServers": {
"dsh-bridge": {
"type": "streamableHttp",
"url": "http://127.0.0.1:51630/mcp",
"timeout": 60000
}
}
}Restart DSH. The log should show [dsh-as-mcp-server] MCP server 就绪: http://127.0.0.1:51630/mcp.
# terminal A — start a demo server on 51999
node dsh/mcp.js 51999
# terminal B — handshake, all 8 tools, floor lock, SSE stream
node dsh/mcp-test.js http://127.0.0.1:51999/mcpExpected: 13 checks pass, ending with 全部通过 ✅.
There is also a unit-level regression suite that runs with no server:
node dsh/bridge-regression.test.mjs # 13 pass / 0 fail~/.dsh-mcp-bridge/config.json (all optional):
{
"port": 51630,
"host": "127.0.0.1",
"token": "",
"lockTtlMs": 300000,
"denyTools": ["write", "edit", "git"],
"alertInjection": true,
"inboxRoot": ""
}inboxRoot defaults to ~/.dsh-mcp-bridge/inbox.
127.0.0.1; a token is supported but empty by default. Do not expose the port.write/edit/git are denied at tools/pre-execute. The remote client is trusted to honour the lock by convention — this is a coordination primitive, not a security boundary between mutually hostile parties.agent/pre-step. If the current step cannot be injected, the alert stays queued and lands on the next step.sessionId.MIT