插件目录 / Developer / dsh-turn-meta
dsh-turn-meta
未验证 randerous
功能简介
dsh-turn-meta — DSH 插件(工具)
未验证 — 尚未实测
dsh-turn-meta — DSH 插件(工具) 尚未验证——请自行安装测试。
「未验证」表示我们的自动化 CI 尚未安装过该插件。功能描述与版本兼容性均为作者声明。这不是安全审计,也不代表对第三方代码的背书。
README
dsh-turn-meta
English | 中文
Opt-in per-step turn metadata for DeepSeek Harness. Each entering agent step appends one compact, source-attributed header naming the session, the current turn and step, how many real user messages and tool results belong to the open turn, and how many turns preceded it.
[turn-meta] session=<id> turn=<turn> step=<step> user_msgs=<a> tool_results=<b> prior_turns=<p>
The package doubles as a minimal first-plugin template: it exercises the same seams every Harness plugin uses with the smallest surface that still shows them — a named-export function plugin (name / inject / Config / apply), schemastery-validated config, one ctx.on('agent/pre-step', …) hook with { prepend: true }, and a ./invariant companion that owns the durable message shape.
Install into a profile
The plugin is opt-in. Add it to a cordis.patch.yml overlay (or pass as --patch):
- insert:
- id: turn-meta
name: '@deepseek-ai/dsh-turn-meta'
config:
enabled: true
minStep: 1
Or, for a self-contained checkout, symlink the dependencies from your installed dsh profile and run the smoke:
node tests/smoke.mjs
smoke.mjs drives the real TypeScript source (Node ≥ 23 type stripping) against an installed dsh distribution; it needs @deepseek-ai/{cordis,dsh-agent,dsh-llm,dsh-session,schemastery} resolvable from the package's node_modules.
Verification status
- Runtime smoke against an installed dsh distribution: 6/6 assertions pass (injection, exact header text, disabled config, invalid-config load failure, disposal, proposed-message counting).
- Monorepo CI gates (vitest full suite, coverage, typecheck, doc-sync) require the deepseek-harness workspace install; they are expected to pass but have not been run here. The package also lives at
packages/context/turn-metain the harness repo for when external contributions open up.
License
MIT
安装
装一次目录插件,之后本站所有插件都能让 DeepSeek Harness 自动找、自动装:
dsh plugin add dshbase-catalog 然后对 agent 说「帮我装 dsh-turn-meta」,它会在目录里找到并自动安装。文档:dshbase-catalog · 已验证场景包。
该插件是 GitHub 源码(未发 npm)——直接从仓库装:
Web profile:
dsh plugin --profile web add github:randerous/dsh-turn-meta Headless(CLI)profile:
dsh plugin --profile headless add github:randerous/dsh-turn-meta 实测报告
尚未 L3 验证——若已跑过,见下方失败备注。
备注:验证: install-fail (0.1.0-rc.6) 浏览全部待验证失败 →
使用场景
扩展 agent 的编码能力面——给它一个新工具、工作流或集成,让它接手以前做不了的开发任务。
适合谁
想让 dsh 在真实代码库上像队友一样干活的开发者——能改、能跑、能验证,而不只是回答问题。
二次开发建议
工具/命令面就是缝:暴露更多 SDK 能力、加更聪明的上下文接线,或收紧改代码与验证之间的循环。