Evidence-driven goal verification plugin for DeepSeek Harness. Locks goals via /ultragoal and verifies completion against command exit codes and generated artifacts, preventing the model from falsely reporting task completion.
Install
# from npm (prebuilt)
dsh plugin --profile web add dsh-gungnir
# from GitHub (first run asks for allowBuilds approval — follow the hint, retry)
dsh plugin --profile web add github:Jonah-Wu23/dsh-gungnir#path:/packages/dsh-plugin
Any plugin you install runs third-party code with your own permissions — it can read your files, use your credentials, and reach the network, and tool approvals don’t sandbox it. GitHub-sourced plugins also run build scripts at install time — pnpm blocks those until you allow them, so an install can stop with ERR_PNPM_GIT_DEP_PREPARE_NOT_ALLOWED or ERR_PNPM_IGNORED_BUILDS; dsh prints the exact key to add under allowBuilds in your profile’s pnpm-workspace.yaml, and the install works on the next run. Allowing a build is a trust decision: only install sources you trust, and pin a commit (github:owner/repo#sha).
README
This plugin publishes its README in Chinese only.
30 秒了解
Gungnir 是 DeepSeek Harness 的证据驱动目标校验插件。 目标经 /ultragoal 锁定为版本化契约,执行过程中的工具结果自动落入追加式证据账本;模型宣称完成时,退出码、工件与 LLM 评审三级验证器对照证据裁决,证据齐备才放行。
Gungnir 为大语言模型智能体提供面向任务结果的控制面能力:
- Lock the goal(目标锁定):建立版本化目标契约,明确预期交付物和检验标准。
- Prove the hit(证据裁决):模型输出只是待检验的声明,测试退出码与文件状态等环境证据才有裁决权。
- 静默守护与最小介入:正常执行路径保持静默,只有观测到确定性证据冲突时才注入面向任务的明确反馈。
核心特性
| 维度 | 原生智能体执行 | Gungnir 控制面 |
|---|---|---|
| 完成判定 | 依赖模型自我宣称 | 依据环境证据与退出码客观裁决 |
| 假完成拦截 | 容易放行未完成的任务 | 运行时拦截虚假完成并要求修正 |
| 正常任务开销 | 基础开销 | 保持静默,Token 额外开销仅 +7.8% |
| 控制面额外交互 | 无 | 正常路径零额外模型往返 |
架构设计
Gungnir 采用分层解耦的插件化架构,全面适配 DeepSeek Harness 生态:
┌─────────────────────────────────────────────┐
│ Gungnir Goal Contract │ 目标锁定:定义任务交付物与验证规则
├─────────────────────────────────────────────┤
│ Gungnir Evidence / Verifier / Reconciler │ 证据裁决:收集环境事实,静默验证并按需介入
├─────────────────────────────────────────────┤
│ DSH Agent Contract / Session Log / Services │ 基础平台:提供会话与工具交互能力
└─────────────────────────────────────────────┘
控制流程
- 环境监听:在智能体调用工具的过程中,被动收集命令退出码与生成文件状态。
- 契约校验:当智能体发出完成任务的声明时,系统基于已捕获的环境证据执行确定性验证。
- 精准反馈:若验证通过,系统保持静默放行;若存在未满足的检验条件,系统注入简明的客观事实反馈,引导模型完成修复。
实验评测
Gungnir 建立了标准化的评测基准,并在 54 组真实环境运行中完成了多模型对比实验。
| 评测场景 | 具体用例 | 原生执行 (E0) | Gungnir 控制面 (E2) |
|---|---|---|---|
| 虚假完成拦截 | CLI 任务重试场景 | 0% (0/2) | 100% (2/2) |
| 语义缺陷修复 | 状态重入场景 (Ledgerd) | 0% (0/2) | 100% (2/2) |
| 验证错配修复 | 消息中继场景 (RelayPump) | 50% (1/2) | 100% (2/2) |
| 标准开发任务 | 常规开发基准 (H1) | 100% (6/6) | 100% (6/6) |
| 模型类型 | 虚假完成拦截率 | 语义缺陷修复率 | 标准任务通行率 |
|---|---|---|---|
| DeepSeek 系列 | 100% | 100% | 100% |
| GPT 系列 | 100% | 100% | 100% |
| GLM 系列 | 100% | 100% | 100% |
| 评测指标 | 原生执行 | Gungnir 控制面 | 控制面开销增量 |
|---|---|---|---|
| 中位 Token 消耗 | 24,151 | 26,025 | +7.8% |
| 中位模型交互轮次 | 12.0 轮 | 12.0 轮 | 0 轮 |
| 任务执行超时率 | 3.7% | 0.0% | -3.7% |
快速上手
兼容性:插件以 dsh v0.1.2-rc.1 为基线,peerDependencies 锁定实测版本。
安装
在 DeepSeek Harness 中执行安装命令:
dsh plugin add dsh-gungnir
配置
插件装载后自动注册 /ultragoal 与 /gungnir 命令及模型侧工具。需要调整时,在配置文件中覆盖插件参数:
plugins:
- name: dsh-gungnir
config:
maxGoalRounds: 64
常用配置项:maxGoalRounds(目标轮次上限)、rubricProvider / rubricModel(LLM 评审模型)、passive(被动观察形态)。
参与项目
欢迎提交 Issue 与 Pull Request。提交修改前请在本地运行测试:
pnpm -r typecheck
pnpm -r test
许可协议
本项目采用 Apache License 2.0 开源许可协议。版权所有 © 2026 Zonghe Wu。
Links
More in this category
Clearailhc/clearai-dsh★ 1104
An agent preset for evidence-checked research: every step advances only through system-verified observations, L3+ claims go to an independent evaluator, and the session folds into a replayable ledger that grows into a browsable domain ontology. Requires DSH >=0.1.7-alpha.1.
FuRongJun-1999/dsh-memory★ 413
White-box AGI architecture exploration: metacognition (self-cognition loop), continual learning (knowledge flywheel), world model (condition space, spatiotemporal memory graph), self-improvement (bootstrap discipline), zero-LLM white-box pipeline, and auditable trust guardrails.
pk14742952-AD/dsh-host-rsi★ 33
Reflective self-evolution plugin for local Qwen3.8 27B/3.8 Flash and online APIs: a coding-loop convergence steerer curbs Qwen3.8 27B/Flash repeated-verification deep-thinking to converge faster and cut thinking time; a five-state delivery guard detects and corrects stuck turns and infinite loops; model-agnostic host logic, mostly compatible with online APIs; per-use continual self-improvement with counter-reason self-checks, critic escalation, inverted-index memory retrieval, coding-loop convergence steering, and a five-state delivery guard.
kenz1117/dsh-engram★ 22
Cross-session long-term memory under the "memory palace" metaphor: dual-scope SQLite stores (user + per-git-origin project), hybrid FTS5 + local-vector retrieval with RRF fusion and recency/proof ranking boost, automatic capture from the session log (including the final turn), provenance audit chains, consolidation distillation and decay forgetting, and a settings-page Memory Library panel with corridor topology, tour butler, and refurb list.
MichengAI/dsh-pua★ 21
Adds /pua to steer the agent to try another approach and verify results before claiming completion, with 15 company styles, persona modes, global and per-conversation settings, and an optional loop that continues until a verification command passes, the iteration limit is reached, or the user cancels.
Kanadego/dsh-heartbeat★ 15
Heartbeat loop for DeepSeek Harness: every 20 minutes (by default) the agent wakes on its own to keep a local profile of your interests and preferences, search the web for things you care about, and keep what it finds. When it has something worth sharing, it sends a short package of notes to the sessions you link it to. A set of rules in code - quiet hours, busy windows, a daily limit, a cooldown - decides whether it may speak at all, and the agent in that session decides whether to actually say anything. Windows only.
Community comments
Comments are public GitHub Discussions. Loading them connects to GitHub and Giscus; a GitHub account is required to post.