Canson666/dsh-finish-reason-patch
Canson666★ 0JavaScript最后同步: 2026-08-20
将gpt之类的项目在dsh中出现without finish reason的情况解决,可以正常使用gpt模型
README 摘要
dsh-finish-reason-patch DSH plugin: stop agent turns from being aborted when an OpenAI-compatible provider (GPT-family models, gateways, proxies) ends a streaming response with full output but without a terminal finish reason . The bug it fixes DSH routes OpenAI-compatible providers through @earendil-works/pi-ai . When the wire stream ends without ever seeing choices[].finish reason , pi-ai raises Stream ended without finish reason ( openai-completions.js:438 ). By that point every content block is already closed and delivered — the response is complete, only the terminal marker is missing. pi-ai surfaces that as an error event, the dsh-llm-pi-ai adapter maps it to a terminal finish {kind:'error', code:'TRANSPORT'} chunk, and the agent loop ( dsh-agent-loop ) throws — aborting a perfectly good model turn. Other agents (e.g. Codex) tolerate the same wire behavior by treating end-of-stream as the end of the response. The fix The plugin hooks the llm/stream waterfall — every model call (agent turns, session-title requests, prepared calls, subagents) flows through it via LlmRuntime.streamWithRegistration . When the terminal finish is exactly that error, it is rewritten to a normal stop…
在 GitHub 查看完整 README →分类
DeepSeek Harness: Everything is a Plugin.
★ 182,325
amruthpillai/reactive-resumeA one-of-a-kind resume builder that keeps your privacy in mind. Completely secure, customizable, portable, open-source and free forever. Try it out today!
★ 41,477
anywhere-labs/deepseek-harness-desktop为 DeepSeek Harness (DSH) 插件生态打造的现代化桌面端解决方案。万物皆「插件」,桌面本身也是「插件」。
★ 17,784