№ 0471GitHub
Muse Spark fix for DeepSeek Harness
A config and write-up that makes muse-spark-1.2-contributor via OpenCode Go work in DeepSeek Harness, fixing empty first-turn output and multi-turn thinking replay errors.
# Muse Spark via OpenCode Go in DeepSeek Harness (DSH)
> 让 `muse-spark-1.2-contributor`(OpenCode Zen Go 网关)在 DeepSeek Harness(`deepseek-harness` / `pi-ai`)里正确工作:首轮出内容 + 多轮 thinking 回传不报错。
>
> Make `muse-spark-1.2-contributor` (the OpenCode Zen Go gateway model) work correctly in DeepSeek Harness (`deepseek-harness` / `pi-ai`): first-turn output plus lossless multi-turn thinking replay.
> **免责声明 / Disclaimer**:本仓库是个人技术分享,**非** DeepSeek / opencode 官方项目,与 `deepseek-ai`、`sst/opencode`、`opencode.ai` 均无关联。文中涉及的协议与代码分析基于公开接口,仅用于学习与自用。
> This is a personal tech-sharing repo. It is **not** an official DeepSeek or opencode project and is unrelated to `deepseek-ai`, `sst/opencode`, or `opencode.ai`. Protocol/code analysis herein is based on public interfaces, for learning and personal use only.
| 项目 | 值 |
| --- | --- |
| 模型 | `muse-spark-1.2-contributor` (Muse Spark 1.2 Contributor) |
| 网关 | OpenCode Zen Go — `https://opencode.ai/zen/go/v1` |
| 协议(正确) | **OpenAI Responses API** (`openai-responses`) |
| 宿主 | DeepSeek Harness (`deepseek-harness`), LLM 适配层 `@deepseek-ai/dsh-llm-pi-ai` → `@earendil-works/pi-ai` |
| 状态 | ✅ 已验证:多轮 + thinking 回传 + 工具调用 + **图片输入** 正常 |
---
## 一、问题现象 / Symptoms
在 `~/.dsh/settings.yaml` 里用 `muse-spark-1.2-contributor`,无论怎么配都会遇到下列错误之一:
| 配置的协议 | 现象 |
| --- | --- |
| `openai-completions` | `Stream ended without finish_reason`(流被网关截断,`message.content` 恒为空) |
| `anthropic-messages` | `model returned a completed response with no content`(非流式空回复) |
| `openai-responses` + 错误的 assistant 补丁 | `input[5] did not match any supported type`(发了 responses 不认识的输入项) |
| `openai-responses`(原始)多轮 | `reasoning_content in the thinking mode must be passed back to the API` |
而 **在 opencode 官方客户端里,Muse 完全正常**。
---
## 二、为什么 opencode 能用 / Why it works in opencode
opencode 的模型目录来自 `https://models.opencode.ai/api.json`(本地缓存在 `~/.cache/opencode/models.json`)。其中:
```jsonc
// provider "opencode-go"
{
"id": "opencode-go",
"npm": "@ai-sdk/openai-compatible",
"api": "https://opencode.ai/zen/go/v1"
}
// model "muse-spark-1.2-contributor"
{
"provider": { "npm": "@ai-sdk/openai" }, // ← 关键:模型级覆盖为 OpenAI Responses SDK
"reasoning_options": [
{ "type": "effort", "values": ["minimal", "low", "medium", "high", "xhigh"] }
],
"limit": { "context": 1048576, "output": 131072 }
}
```
**Muse 只认 OpenAI Responses 协议**(模型级 `@ai-sdk/openai`),不是 Chat Completions、也不是


ChatForm
Tgmlabs