Repository navigation
新增 MiniMax Code 与 ZCode 外部 CLI 适配器,兼容 DSH 0.2.0-rc.2 - #6
Merged
jingyi0605 merged 1 commit intoOct 1, 2026
Merged
Conversation
- MiniMax Code:mcode acp 常驻进程驱动(ACP 标准协议),进程跨回合复用消除
每轮冷启动;正文以 agent_message_chunk 逐字流式;支持 session/load 会话
恢复、session/cancel 中断与权限请求自动应答。显式选择非默认思考档位时改走
mcode exec --effort 单发精确下发(提示词经 stdin,避免 Windows shell 拆散
argv 与泄露用户内容)。
- ZCode:zcode app-server 的 ZCode Protocol({id,method,params} 裸信封,
JsonRpcProcess 新增 zcode 线格式与服务端请求应答)。自动发现桌面端自带
zcode.cjs 运行时(resources/glm/zcode.cjs + provider 配置环境变量)。
- 模型档位动态读取 CLI 自身声明:MiniMax 解析官方 config.yaml 的
effortOptions/defaultEffort,与官方 App 完全同源。
- 修复 JsonRpcProcess zcode 通知监听生命周期问题:回合事件监听器挂在请求级
会在响应返回时被移除,导致终态通知丢失、回合挂起;改为会话级监听。
- 兼容 DSH 0.2.0-rc.2:能力矩阵与版本清单扩展(版本门禁此前会静默排除
第三方 bundle),rc.1/rc.2 双版本无头启动与目录 RPC 验证通过。
yrt083
pushed a commit
to yrt083/Codingns4DSH
that referenced
this pull request
Oct 1, 2026
记录本次移植的完整背景与决策:PR jingyi0605#6 与 PR jingyi0605#7 都基于旧版 main,与当前 0.2.0-beta.2 / DSH 0.2.0-rc.2 主线冲突,且携带过时版本文件、生成物、权限语义缺口与进程生命周期风险,因此不做整分支合并,改为按可审查的粒度重新适配当前契约。 requirements 明确移植范围与明确不做的事项,design 给出驱动、Provider、工具三层的适配方式与主线契约对应关系,tasks 记录逐项落地结果与验证证据。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概述
新增两个外部编码 CLI 适配器,并将 DSH 兼容范围扩展到 0.2.0-rc.2(能力矩阵与版本清单同步更新,rc.1 / rc.2 双版本无头启动与
cli/catalogRPC 验证通过)。MiniMax Code(mcode)
实现:
mcode acp常驻进程(ACP 标准协议),按会话复用进程消除每轮十余秒冷启动;正文以agent_message_chunk逐字流式;会话恢复session/load、中断session/cancel、权限请求自动应答。显式选择非默认思考档位时改走mcode exec --effort单发精确下发;提示词经 stdin 下发,避免 Windows shell 拆散 argv。思考档位动态读取官方~/.minimax/config.yaml(effortOptions/defaultEffort),与官方 App 同源。ZCode
实现:
zcode app-server的 ZCode Protocol({id, method, params}裸信封);JsonRpcProcess新增 zcode 线格式与服务端请求应答。自动发现桌面端自带运行时(resources/glm/zcode.cjs+ZCODE_*环境变量),可回退 PATH 独立 CLI。失败时透传turn.terminal的真实 errorCode/errorMessage;常驻进程死亡时丢弃句柄并在下一轮自动重建,不再出现空事件流。使用方式
两个适配器安装插件后即出现在 DSH 会话输入框右侧的 Agent 选择器中,选择后直接对话。各自的准备条件:
MiniMax Code
npm install -g @minimax-ai/code@latest(或官方安装脚本)mcode login(MiniMax 账号 OAuth;也支持mcode provider add自带 API Key)ZCode
resources/glm/zcode.cjs),无需额外安装;独立 CLI 亦可zcode login(Z.AI 账号 OAuth)。注意独立 CLI 的登录态与桌面端账号体系相互独立,需登录一次CONFIGURATION_ERROR)验证
cli/catalog返回全部适配器