glangzh/dsh-advisor
给 DeepSeek Harness 的 Agent 增加一位"顾问":日常任务使用较弱模型(默认模型),遇到真正困难的决策时,Agent 会自动向一个更强的模型咨询。
项目介绍Project Overview
dsh-advisor 是 DeepSeek Harness 的顾问插件:日常任务仍用默认模型,遇到复杂架构、模糊需求、安全敏感改动或拿不准的方案时,Agent 自动调用更强模型(默认 deepseek-v4-pro)获取判断,调用记录留痕且子代理不会递归升级。适用于需要在关键决策点寻求更高质量判断、又不想常规任务增加成本的场景。注意:需已配置 deepseek-official 服务与 DEEPSEEK_API_KEY,预设与全局两种安装方式不可同时使用,否则 advisor 工具冲突。
dsh-advisor is a DeepSeek Harness plugin that adds an advisor: routine tasks run on the default model, but when the Agent faces hard decisions—complex architecture, ambiguous requirements, security-sensitive changes, or uncertain plans—it automatically consults a stronger model (default deepseek-v4-pro), logs the call, and prevents recursive escalation by sub-agents. Use it when you want higher-quality judgment only at key decision points without paying pro costs for everyday work. Caveat: requires a configured deepseek-official service and DEEPSEEK_API_KEY; do not install both the preset and global versions or the advisor tool will conflict.
请帮我了解并安装插件:【dsh-advisor】【https://github.com/glangzh/dsh-advisor】
把上面这条消息直接发给当前会话里的 DSH,让它帮你了解并安装。安装命令不一定准确,发给 DSH 更稳。Send this message to DSH in your current session. CLI install commands may not be accurate across systems — DSH will figure it out for you.
或使用命令行安装(适合开发者)Or use CLI install (for developers)
命令行安装CLI Install
dsh plugin --profile web add github:glangzh/dsh-advisor
把 glangzh/dsh-advisor 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-advisor — DeepSeek Harness 顾问能力
给 DeepSeek Harness 的 Agent 增加一位"顾问":日常任务照常用你的模型完成,遇到
真正困难的决策(复杂架构选择、模糊需求、安全敏感改动、拿不准的方案)时,Agent
会自动向一个更强的模型(默认 deepseek-v4-pro)咨询判断,再继续干活。
- 只在关键时刻用更强的模型——常规工作不额外花钱,升级时才产生 pro 消耗。
- 决策留痕——顾问调用记录在会话中,随时可回看。
- 不会层层升级——子代理不会重复触发顾问,避免递归开销。
灵感来自 Anthropic《The advisor strategy》。
安装
先决条件:DSH 已配置 deepseek-official 模型服务(DEEPSEEK_API_KEY 可用)。
两种安装方式任选其一(不要同时安装,否则 advisor 工具会冲突)。
Agent 预设安装(推荐)— 仅 Advisor 会话可用
顾问能力只在选择了 顾问模式 的会话里生效,其他会话不受影响。
git clone git@github.com:glangzh/dsh-advisor.git
cp -r dsh-advisor/preset ~/.dsh/.agent-presets/advisor
然后在 Web 界面 Agent 预设选择器(或 settings.yaml 的 agent-presets.default: advisor)
中选择 顾问模式,开一个新会话即可使用。
全局安装 — 所有会话可用
一条命令装完,之后所有会话都能使用顾问能力:
dsh plugin --profile web add github:glangzh/dsh-advisor
装好后开新会话即可。
使用
安装后无需额外操作——Agent 的系统提示中已内置升级准则,遇到下面几类情况会自动
调用 advisor 工具咨询:
- 影响多个文件/组件的架构决策;
- 有多种合理解释的模糊需求;
- 认证、授权、数据校验等安全敏感代码;
- 复杂问题中你自己不确定的方案。
如果你希望明确要求它咨询顾问,直接说即可,例如:
我们要给这个模块加 OAuth2,但代码里已有 3 种 session 方案。先请顾问评估哪种最合理,再动手。
配置
可在安装配置中调整以下项(默认值已够用,通常无需改动):
| 字段 | 默认值 | 说明 |
|---|---|---|
advisorModel |
deepseek-v4-pro |
顾问使用的模型 |
maxTokens |
4096 |
顾问每次回复的输出上限 |
timeoutMs |
180000 |
顾问调用超时时间 |
- Agent 预设安装:修改
~/.dsh/.agent-presets/advisor/agent.cordis.yml中 advisor 行的config:。 - 全局安装:修改 profile 的
cordis.patch.yml中 advisor 行的config:。
卸载
# Agent 预设安装
rm -rf ~/.dsh/.agent-presets/advisor
# 全局安装
dsh plugin --profile web remove dsh-advisor-plugin
常见问题
Q:两种安装方式有什么区别? A:Agent 预设安装只影响选择了 Advisor Agent 预设的会话;全局安装让所有会话都能用顾问。 推荐 Agent 预设安装,把顾问能力限定在需要的场景。
Q:顾问调用会花很多钱吗? A:只有升级时才用更强的模型,且每次回复有输出上限(默认 4096 tokens)。常规工作仍由 你的默认模型完成。
Q:子代理会不会再次调用顾问? A:不会。子代理被禁止调用顾问工具,不会产生层层升级。
Q:换默认模型会影响顾问吗?
A:顾问固定使用 advisorModel 配置的模型(默认 deepseek-v4-pro),与执行者模型无关。
nexu-io/open-design
freestylefly/awesome-gpt-image-2
anywhere-labs/dsh-desktop
walkinglabs/learn-harness-engineering
awesome-dsh-plugin/awesome-dsh-plugin
MemTensor/MemOS