Skip to main content
R

wiser

regrevia/wiser

Turns one flow you actually ran into a narrow skill: judgeable criteria with numbers and counter-examples, enumerable assets, an executable detector that returns an exit code, and blind evals with control arms. Five gates decide whether it is publishable, a second ruler counts violations so two runs can be compared on the same scale, and freeze snapshots a version so published thresholds and counter-examples cannot change silently. Pure local CLI: no network, no credentials.

Install

dsh plugin --profile web add github:regrevia/wiser

README

wiser

把一条真实做过的流程沉淀成窄 skill,并用五道闸判定它够不够格发布。

一个 skill 只装一条流程。判据必须带数字、带反例、能机器判;只有形容词的写法过不了闸。

用

node ~/.dsh/skills/wiser/scripts/wiser.mjs audit <skill 目录>              # 五道闸
node ~/.dsh/skills/wiser/scripts/wiser.mjs new <目录> <名字>              # 起骨架
node ~/.dsh/skills/wiser/scripts/wiser.mjs add "<流程>" --trigger "用户原话" --dir <目录> --write
node ~/.dsh/skills/wiser/scripts/measure.mjs <skill 目录>                  # 违背条数
node ~/.dsh/skills/wiser/scripts/wiser.mjs freeze <skill 目录> --note "…"  # 冻结成新版本

audit 的 exit code:0 五道全过可发布 · 1 差一两件 · 2 个人笔记 · 3 路径下没有 SKILL.md。 measure:0 零违背,1 逐条列出。两边都给 --json。

五道闸

闸门槛
narrow-one-flow一条流程,正文二级标题 ≤9 节,description 无大词
judgeable-criteria≥8 条带数字的判据,或 ≥5 条且 ≥正文非标题行 20%
assets-enumerable≥1 个可枚举资产
detector-executable≥1 个脚本 + 可直接复制的命令行
eval-blind≥3 条带对照字段的 eval

证据

evidence/report.md 里有双跑盲评记录(同一道题,带 skill 违背 0 次、盲评 9 分;不带 10 次、盲评 2 分)与一次真实返工。判据与反例冻结在 versions/v1/,发布后改阈值必须冻结新版本。

同一把尺在本机 33 个 skill 上跑出 0 / 1 / 2 / 3 / 5 / 6 / 7 / 11 / 44 九档违背数,跨度见报告,不是二元开关。

先看这里:这个工作区里说过 ≥2 次的是什么

node scripts/import.mjs --workspace <目录>            # 或 --list-workspaces 看都有哪些工作区
node scripts/import.mjs --session <会话 id> --from claude
node scripts/import.mjs --stores                      # 同一件事被装进了几个 agent(软链接不重复计)

读本机已有的会话记录,不联网、不调模型:DSH(.jsonl.zstd,只解首行拿 cwd)、Claude Code、Codex 三家合起来按工作区归类,把用户说过 ≥2 次的话挑出来。实测 583 个工作区 / 2713 条会话,2.3 秒。接第四个 agent 只写 list() 与 turns() 两个方法。

和别的 skill 工具比

同行(Anthropic skill-creator、obra superpowers、NVIDIA SkillEvaluator、aws-samples/skill-eval)要开 key、起容器或跑 subagent 才能判。wiser 不联网、不要 key,audit 0.04 秒跑完,判据是可指认的行号而不是综合分。代价是它不判「这条 skill 真的帮到 agent 了吗」——那一步留给人跑盲评。详见 evidence/report.md 末节。

安装到 DSH

# 当插件装(注册成会话里可调用的 wiser 技能,模型和人写 /wiser 都能起)
dsh plugin add dsh-skill-wiser

# 或只要文件、要能直接改判据
git clone https://github.com/regrevia/wiser.git ~/.dsh/skills/wiser

插件那条路走 package.json 里的 dsh.bundle → cordis.patch.yml,注册一个 skill provider,把本包根目录的 SKILL.md 交给宿主;node scripts/wiser.mjs ... 与 references/*.md 都相对包根目录解析。技能正文按需从磁盘读,升级后要重载或重启才看到新版本。

Related plugins