TypeSafe Jev (System One decision model) as the jev_decide tool for DeepSeek Harness: noul, choice and score questions return calibrated probabilities; credentials reuse the DSH credential seam; 429/529 backoff retry built in.
Install
# from npm (prebuilt)
dsh plugin --profile web add dsh-jev-decide
# from GitHub (first run asks for allowBuilds approval — follow the hint, retry)
dsh plugin --profile web add github:nanami-0713/dsh-jev-decide
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.
把 TypeSafe Jev("System One" 决策模型)接入 DSH:注册一个 agent 工具 jev_decide,让 agent 在需要"快而准的判断"时调用 Jev,而不是让对话模型凭感觉猜。
为什么不是"再加一个对话模型"
Jev 不生成文本。它对输入 state 回答类型化问题并返回校准过的概率:
| type | 问法 | 返回 |
|---|---|---|
noul |
是/否问题 | answer = 是的概率 0..1 |
choice |
从选项里挑一个(需 options ≥2) |
answer = 选中项 + probabilities 全分布 + confidence |
score |
按有序等级打分(需 levels ≥2) |
answer = 概率加权分值 + 分布 + confidence |
适合:消息紧急度分级、意图路由、guardrail 检查、二选一决策、按 rubric 打分。不适合:写代码、写文案、任何需要生成文本的活。
工具签名
jev_decide({
state: string, // 必填,要评估的内容(纯文本)
question: string, // 必填,要做的判断
type?: 'noul' | 'choice' | 'score', // 默认 noul
options?: string[], // type=choice 时必填(≥2)
levels?: string[], // type=score 时必填(≥2,从低到高)
yes?: string, // type=noul 时可选:什么算 YES(锐化校准)
no?: string, // type=noul 时可选:什么算 NO
model?: string, // 默认 jev-latest(当前 jev-1.13.0)
}) → { model, type, answer, confidence?, probabilities?, usage }
凭证解析顺序
- 插件配置的
apiKey(cordis patch config 或数据目录 config.json) - 环境变量
TYPESAFE_API_KEY ~/.dsh/.credentials.yaml的refs.TYPESAFE_AI_API_KEY(与 DSH 凭证缝同源——本机已配置,无需重复)
配置
数据目录 $DSH_HOME/plugins/dsh-jev-decide/config.json(或 cordis patch 的 config:):
{ "model": "jev-latest", "timeoutMs": 15000, "baseUrl": "https://api.typesafe.ai/v1" }
安装 / 接线
方式一:npm(已上架,包页):
dsh plugin --profile web add dsh-jev-decide
# 或纯 npm 侧安装(npm ≥7 / pnpm auto-install-peers 会自动装 @deepseek-ai/dsh-tools peer)
npm install dsh-jev-decide
v0.1.2 起包内自带 dsh.bundle(根目录 cordis.patch.yml):dsh plugin add 会自动把插件装配进 profile,无需手写任何接线;纯 npm install 仍只装包不装配。
v0.1.1 手动接线用户升级注意:已按方式三手写 insert 的 profile,不要再对它跑
dsh plugin add——两处注册同一 id 会报duplicate loader entry id,整份 profile 无法启动;先注释/删除手动条目,再交给 bundle 自动装配。
peer 解析注意:宿主不会把捆绑的
@deepseek-ai/dsh-tools注入插件的模块解析链。经 npm/pnpm 安装时 peer 会被自动物化;若以link:/本地路径方式接入插件源码目录,需在插件目录内先跑一次npm install把 peer 物化(>=0.1.0-rc.6的 semver 预发布匹配只会选到 0.1.0-rc.x 元组,属预期——插件只消费defineTool一个纯函数,跨宿主版本已实测兼容)。
发版即自动发布:git tag vX.Y.Z && git push --tags → GitHub Actions 以 OIDC 免 token 发布(带 provenance 签名),无需任何长期 npm 凭据。
方式二:插件市场(收录 PR #5428 合并后自动出现在 awesome-dsh-plugin.com 与 DSH 内置市场)。
方式三:手动接线:
- 源码:
~/dsh/plugins/dsh-jev-decide/ ~/.dsh/profiles/web/package.json依赖:"dsh-jev-decide": "link:~/dsh/plugins/dsh-jev-decide"~/.dsh/profiles/web/cordis.patch.yml加一条 insert(内容同仓库根目录cordis.patch.yml):- insert: [- id: dsh-jev-decide, name: dsh-jev-decide]- 因无 shell 无法建 pnpm symlink,
profiles/web/node_modules/dsh-jev-decide/放的是实体副本;下次pnpm install会把它规范成 link,无副作用。 - 生效需重启 DSH(host 插件在进程启动时装配)。
生态扫描:同类项目(2026-09-19)
Jev 发布三天内 GitHub 上已出现多个 DSH 接入实现,各有侧重:
| 项目 | 特点 |
|---|---|
| noetion/dsh-jev | jev_ask 工具,一次 state 可混搭多问题;bundle + 内置 skill;配套 mock 传输测试,工程最完整 |
| kaijia323/dsh-plugin-jev | 同名 jev_decide;双传输(官方 API + Vercel AI Gateway);指数退避重试、state/问题数上限守卫、置信度阈值路由示例 |
| buberlo/dsh-jev | 决策层封装 |
| zhangxaochen/dsh-jev | 插件套件 |
本插件的差异点:
- 单文件、零构建(纯 ESM JS),copy 即用,没有 TypeScript 工具链依赖
- 凭证零配置:直接复用 DSH 凭证缝(
~/.dsh/.credentials.yaml的TYPESAFE_AI_API_KEY),不要求 env 也不在 patch 里落明文 - 内建 429/529 官方建议的短退避重试
- 只做一件事:把
jev_decide注册进工具集;多问题、双网关等进阶需求请用上面的项目
定价参考
Jev 1.13:$0.042/百万输入 token,输出免费;官方限流 250k tok/s、1200 req/min(模型页)。
开发 / 测试
npm install --no-save @deepseek-ai/dsh-tools # 装上 peer 依赖(仅为 import)
npm test # node --test,16 个用例,零依赖、不发网络请求
test/pure.test.js 覆盖纯函数契约:三种题型的请求构造(buildQuestion/buildPayload)、参数校验报错路径、响应压缩(summarize)对 noul/choice/score 三种答案形状的解析。CI(.github/workflows/test.yml)在每次 push/PR 上运行同一套测试。
Links
More in this category
DayuanJiang/next-ai-draw-io#dsh-plugin★ 36802
Draws draw.io diagrams in DeepSeek Harness through the next-ai-drawio MCP server: the link in the reply opens a live preview in the right sidebar, you can edit the diagram by hand, and each AI change is a version you can restore. Node.js 18+; npx downloads the MCP server on first use.
Tencent/WeKnora#dsh-weknora★ 36302
Four read-only tools over a WeKnora knowledge base: list knowledge bases, hybrid passage search, reassemble one document's chunks in order, and WeKnora's own cited RAG or ReAct-agent answer with a resumable session id.
superdesigndev/treg★ 7042
Tool catalog for agents: search ~2,600 external endpoints (SEO and SERP, backlinks, social, people and company enrichment, ad libraries, scraping) by the task you want done, read each one's parameters and per-call price, then call it with the credential injected server-side. Ships the skill plus an MCP row that stays disabled until TREG_TOKEN is set.
T-Auto/dsh-ops★ 5074
Provides bash, PowerShell 7, and high-performance Rust tools for DSH on Windows to reduce token usage.
sixtysevenlf/dsh-blender-plugin★ 1575
Lets a DSH agent drive a local Blender over a direct TCP channel with 15 tools: viewport frames, custom-angle renders, Python execution, headless and job offload, transaction rollback, and a planning layer of 228 ops across 34 families.
TencentCloudBase/CloudBase-AI-Toolkit#dsh-plugin★ 1155
Tencent CloudBase backend for DeepSeek Harness — scaffold and deploy full-stack apps from chat, render query results as table cards with paging, sorting and CSV export, preview a deployment on its domain, and call the CloudBase MCP toolset (`mcp__cloudbase__*`) with device-code login.
Community comments
Comments are public GitHub Discussions. Loading them connects to GitHub and Giscus; a GitHub account is required to post.