@liustack/modlens 3.22.2 → 3.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/README.md +1 -1
- package/README.zh-CN.md +2 -2
- package/dist/main.js +7 -3
- package/docs/harness-setup.md +2 -2
- package/docs/harness-setup.zh-CN.md +2 -2
- package/docs/troubleshooting.md +2 -2
- package/docs/troubleshooting.zh-CN.md +2 -2
- package/dsh/index.js +15 -5
- package/package.json +1 -1
- package/skills/modlens/SKILL.md +4 -4
- package/skills/modlens/references/runtime.md +1 -1
- package/skills/modlens/scripts/run.ps1 +1 -1
- package/skills/modlens/scripts/run.sh +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 3.23.0 - 2026-08-21
|
|
4
|
+
|
|
5
|
+
- **dsh: a vision model never gets a `(modlens vision)` twin, even from a catalog that forgot to say it sees ([#71](https://github.com/liustack/modlens/issues/71) surfaced the mechanism).** DeepSeek launched `deepseek-v4-flash-vision-exp` today, and the official dsh catalog declares its image modality from day one, so the stock route was never at risk. But third-party catalogs and hand-written `models` lists copy an id without its modalities, and the wrapper's name gate only knew the older spellings (`deepseek-vl`, `deepseek-ocr`, `janus`, `glm-…v`): an id whose own name says `vision` would have been wrapped as text-only, stripping its native sight. The name gate now reads the word `vision` in the bare model id. The judgment also classifies by the bare id deliberately: a gateway namespace that happens to contain the word cannot veto the text model behind it, and a leading `~` alias marker cannot hide one.
|
|
6
|
+
- **dsh: OpenRouter's GLM models get their wrapper variants ([#71](https://github.com/liustack/modlens/issues/71)).** OpenRouter spells GLM as `z-ai/glm-5.2:free`, and family matching only looked at the full id, so `startsWith('glm')` never fired: a text-only family member — exactly what the wrapper exists for — was invisible behind its vendor prefix. Family matching now also tries the bare model id behind the namespace and alias marker; a custom `families` list keeps its full-id matching untouched. Vision-named and image-declaring models stay excluded on both spellings.
|
|
7
|
+
- **The reuse vision table knows DeepSeek's first vision endpoint.** Same shape as 3.22.0's #70: harness listings that carry no modality data are judged by the builtin table, and the table predates today's launch. `deepseek-*vision*` now marks `deepseek-v4-flash-vision-exp` (and successors named the same way) image-capable, verified against the official docs, models.dev, and OpenRouter's catalog.
|
|
8
|
+
|
|
3
9
|
## 3.22.2 - 2026-08-21
|
|
4
10
|
|
|
5
11
|
- **The scope contract is written down where maintainers look.** AGENTS.md and CONTRIBUTING.md now state it in full: an image the user hands over is read once, and that read leaves text later turns can quote. The image is in the conversation because the user pasted it, dropped a path, or gave a URL — capture is a different job. Both files list what stays out and why: a camera, screenshot capture, or hotkeys; CDP or holding a browser session; computer-use; a pixel toolbox; bounding boxes or confidence scores, dropped from the schema on purpose. Docs only, no behavior change — verified byte-identical CLI output against the previous tree.
|
package/README.md
CHANGED
|
@@ -33,7 +33,7 @@ Issues are welcome any time: [open one](https://github.com/liustack/modlens/issu
|
|
|
33
33
|
|
|
34
34
|
## Highlights
|
|
35
35
|
|
|
36
|
-
**🥇 The most capable vision plugin for DeepSeek Harness (dsh):** install it instantly with one command: `npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.
|
|
36
|
+
**🥇 The most capable vision plugin for DeepSeek Harness (dsh):** install it instantly with one command: `npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.23.0`. See the [setup guide](docs/harness-setup.md) for installation and update details. If the command line is not your thing but you still want to try DSH, check out <a href="https://github.com/liustack/aimanager"><b>AIManager</b></a>, the lightest desktop wrapper for DeepSeek Harness. It gets you started with zero code or configuration and installs every dependency for you with one click.
|
|
37
37
|
|
|
38
38
|
Pasting an image works two ways. **① Just paste.** On a text-only model the pasted image lands as a private temp file and its path enters the composer — the same interaction OpenCode and Pi ship — and the `modlens_read_image` tool takes it from there. **② Pick a `(modlens vision)` entry** in the model selector (it remembers your choice, so once is enough), then paste: the thumbnail stays visible in your message, closer to the Codex app feel, and the image is converted to structured evidence at request time, answered by the same underlying route. The plugin auto-discovers every provider route carrying text-only DeepSeek or GLM models and adds a wrapped entry per route (a stock install gets **`DeepSeek-V4-Flash (modlens vision)`** and **`DeepSeek-V4-Pro (modlens vision)`**; extra routes like opencode-go or zai get their own); the two families' own vision models are excluded automatically. Which paste route applies is the host's per-model call: only a model its metadata positively confirms text-only is taken over, anything unconfirmed is left alone, so vision models keep their native paste ([details](docs/harness-setup.md)).
|
|
39
39
|
|
package/README.zh-CN.md
CHANGED
|
@@ -33,7 +33,7 @@ DeepSeek 和 GLM 的主力对话模型是纯文本的,无法进行图片识别
|
|
|
33
33
|
|
|
34
34
|
## 亮点
|
|
35
35
|
|
|
36
|
-
**🥇 全网最强的 DeepSeek Harness(dsh)外挂视觉识别插件:**一条命令即刻安装 `npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.
|
|
36
|
+
**🥇 全网最强的 DeepSeek Harness(dsh)外挂视觉识别插件:**一条命令即刻安装 `npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.23.0`。更多安装与更新细节参考 [配置手册](docs/harness-setup.zh-CN.md) 。如果用不惯命令行,也想想玩玩 DSH,推荐食用全网最轻量级的 DeepSeek Harness 桌面版封装 <a href="https://github.com/liustack/aimanager"><b> AIManager</b></a>,零代码零配置起手,一键帮你安装所有依赖环境。
|
|
37
37
|
|
|
38
38
|
DeepSeek Harness 粘贴识图有两种玩法。
|
|
39
39
|
|
|
@@ -70,7 +70,7 @@ agy # 浏览器完成
|
|
|
70
70
|
**DeepSeek Harness(dsh)用户不走 skill 流程**,本包就是原生 dsh 插件:
|
|
71
71
|
|
|
72
72
|
```sh
|
|
73
|
-
npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.
|
|
73
|
+
npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.23.0
|
|
74
74
|
```
|
|
75
75
|
|
|
76
76
|
装完即有 `modlens_read_image` 工具,选「(modlens vision)」模型变体即可直接粘贴识图。引擎配置同样在 `~/.modlens`,详见[宿主接入](docs/harness-setup.zh-CN.md)。
|
package/dist/main.js
CHANGED
|
@@ -2750,6 +2750,9 @@ const VISION_MODEL_PATTERNS = [
|
|
|
2750
2750
|
"mimo-v2-omni*",
|
|
2751
2751
|
"deepseek-vl*",
|
|
2752
2752
|
"deepseek-ocr*",
|
|
2753
|
+
// DeepSeek's V4 vision endpoint (2026-08-21); the docs name vision models
|
|
2754
|
+
// by the word, so the wildcard covers the exp tier and its successors.
|
|
2755
|
+
"deepseek-*vision*",
|
|
2753
2756
|
"janus*",
|
|
2754
2757
|
"pixtral*",
|
|
2755
2758
|
"llama-4*",
|
|
@@ -2759,7 +2762,8 @@ const VISION_MODEL_PATTERNS = [
|
|
|
2759
2762
|
"internvl*"
|
|
2760
2763
|
];
|
|
2761
2764
|
function isVisionModel(modelId) {
|
|
2762
|
-
const
|
|
2765
|
+
const unaliased = modelId.replace(/^~/, "");
|
|
2766
|
+
const bare = unaliased.includes("/") ? unaliased.slice(unaliased.lastIndexOf("/") + 1) : unaliased;
|
|
2763
2767
|
return VISION_MODEL_PATTERNS.some((pattern) => globMatch(pattern, bare));
|
|
2764
2768
|
}
|
|
2765
2769
|
const DEFAULT_TTL_MS = 6 * 60 * 60 * 1e3;
|
|
@@ -5003,7 +5007,7 @@ function parsePositiveInt(raw, flag) {
|
|
|
5003
5007
|
}
|
|
5004
5008
|
return Number.parseInt(raw, 10);
|
|
5005
5009
|
}
|
|
5006
|
-
program.name("modlens").description("Plug-in vision for text-only LLMs: image in, structured JSON evidence out").version("3.
|
|
5010
|
+
program.name("modlens").description("Plug-in vision for text-only LLMs: image in, structured JSON evidence out").version("3.23.0");
|
|
5007
5011
|
program.command("analyze", { isDefault: true }).description("Analyze an image into structured JSON evidence (default command)").requiredOption("-i, --input <path|url>", "Input image path or https URL").option("-o, --output <path>", "Write result JSON to a file").option("-m, --model <name>", "Provider model name").option("-p, --provider <name>", `Vision provider (${listProviders().join(", ")})`).option("--prompt <text>", "Extra focus for this image").option("--timeout <ms>", "Provider timeout in milliseconds", "180000").option("--provider-bin <path>", "Provider binary path (default: agy)").option("--workdir <path>", "Working directory for the provider").option(
|
|
5008
5012
|
"--extra-body <json>",
|
|
5009
5013
|
`JSON merged into the API request body, e.g. '{"thinking":{"type":"disabled"}}'`
|
|
@@ -5113,7 +5117,7 @@ program.command("doctor").description(
|
|
|
5113
5117
|
configPath: CONFIG_PATH,
|
|
5114
5118
|
// Lets doctor name an installed skill copy that is older than
|
|
5115
5119
|
// the CLI reporting on it (issue #33).
|
|
5116
|
-
version: "3.
|
|
5120
|
+
version: "3.23.0"
|
|
5117
5121
|
});
|
|
5118
5122
|
const output = options.json ? JSON.stringify(report, null, 2) : renderDoctorReport(report);
|
|
5119
5123
|
process.stdout.write(`${output}
|
package/docs/harness-setup.md
CHANGED
|
@@ -55,7 +55,7 @@ OpenCode with DeepSeek: `opencode auth login`, pick DeepSeek and paste the key (
|
|
|
55
55
|
dsh is different from the other harnesses: modlens plugs in as a native tool, not a prompt-triggered skill. The package itself is a dsh bundle, so one command installs it into a profile:
|
|
56
56
|
|
|
57
57
|
```sh
|
|
58
|
-
npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.
|
|
58
|
+
npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.23.0
|
|
59
59
|
```
|
|
60
60
|
|
|
61
61
|
This registers a `modlens_read_image` tool whose schema reaches the model on every request (no trigger heuristics), runs the modlens CLI shipped inside the same package, and returns the structured evidence as the tool's canonical JSON output. Engines, reuse grants, and guard rules stay in `~/.modlens/config.json`, shared with every other harness. dsh is in developer preview and its plugin surface may change; the plugin keeps its touch small (raw tool registration, the llm adapter surface for the vision variants, the attachment reader, and one agent pre-step hook) and degrades loudly if any of them moves.
|
|
@@ -87,7 +87,7 @@ modlens ships often, and both install shapes freeze at whatever version they
|
|
|
87
87
|
got. On dsh, re-run the install with the version named:
|
|
88
88
|
|
|
89
89
|
```sh
|
|
90
|
-
npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.
|
|
90
|
+
npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.23.0
|
|
91
91
|
```
|
|
92
92
|
|
|
93
93
|
`npm view @liustack/modlens version` prints the current one, and this page is
|
|
@@ -55,7 +55,7 @@ OpenCode 接 DeepSeek:执行 `opencode auth login`,选择 DeepSeek 并粘贴
|
|
|
55
55
|
dsh 与其他 harness 不同:modlens 以原生工具的形式接入,而不是靠提示词触发的 skill。本包自身就是一个 dsh bundle,一条命令即可装进某个 profile:
|
|
56
56
|
|
|
57
57
|
```sh
|
|
58
|
-
npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.
|
|
58
|
+
npx -y @deepseek-ai/dsh plugin --profile web add @liustack/modlens@3.23.0
|
|
59
59
|
```
|
|
60
60
|
|
|
61
61
|
这会注册一个 `modlens_read_image` 工具,它的 schema 随每次请求抵达模型(不靠触发启发式),运行同一个包里自带的 modlens CLI,并把结构化证据作为工具的标准 JSON 输出返回。引擎、复用授权和 guard 规则仍在 `~/.modlens/config.json` 里,与其他所有 harness 共享。dsh 还在开发者预览阶段,插件接口可能变化。这个插件刻意保持很小的接触面(原生工具注册、视觉变体所用的 llm 适配层、附件读取器,以及一个 agent 执行前钩子),其中任何一处变动,它都会大声报错而不是无声退化。
|
|
@@ -73,7 +73,7 @@ dsh 的网页用户面前没有终端,所以引擎设置有一张卡片,在*
|
|
|
73
73
|
modlens 发布很频繁,而两种安装形态都会冻结在装进来的那个版本上。dsh 上重跑一遍安装即可,版本号要点名:
|
|
74
74
|
|
|
75
75
|
```sh
|
|
76
|
-
npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.
|
|
76
|
+
npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.23.0
|
|
77
77
|
```
|
|
78
78
|
|
|
79
79
|
`npm view @liustack/modlens version` 可以查到当前版本号,本页的版本号则由发布流程自动写入。
|
package/docs/troubleshooting.md
CHANGED
|
@@ -163,7 +163,7 @@ simply lands on an older one. Name the exact version instead, which pnpm treats
|
|
|
163
163
|
as a deliberate request rather than a resolution:
|
|
164
164
|
|
|
165
165
|
```sh
|
|
166
|
-
npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.
|
|
166
|
+
npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.23.0
|
|
167
167
|
```
|
|
168
168
|
|
|
169
169
|
`npm view @liustack/modlens version` prints the current one. pnpm 11 installs a named
|
|
@@ -178,7 +178,7 @@ file:
|
|
|
178
178
|
|
|
179
179
|
```yaml
|
|
180
180
|
minimumReleaseAgeExclude:
|
|
181
|
-
- '@liustack/modlens@3.
|
|
181
|
+
- '@liustack/modlens@3.23.0'
|
|
182
182
|
```
|
|
183
183
|
|
|
184
184
|
Or lift the gate for a single command, which lifts it for everything that
|
|
@@ -144,7 +144,7 @@ dsh profile 装到的是旧版 modlens。`dsh.bundle` 声明从 3.9.0 起才存
|
|
|
144
144
|
`@latest` 绕不开这一层,本页早先的说法是错的。冷静期先把候选版本过滤掉,dist-tag 才在剩下的里面解析,于是它直接落到了更旧的那个上。改成写死精确版本号,pnpm 会把它当作一次明确的指定,而不是一次解析:
|
|
145
145
|
|
|
146
146
|
```sh
|
|
147
|
-
npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.
|
|
147
|
+
npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.23.0
|
|
148
148
|
```
|
|
149
149
|
|
|
150
150
|
`npm view @liustack/modlens version` 可以查到当前版本号。pnpm 11 会装上被点名的版本,11.1.3 起还会把它作为一条已批准的例外写进该 profile 的 `pnpm-workspace.yaml`,其余所有包和 modlens 以后的版本仍然留在窗口后面。
|
|
@@ -153,7 +153,7 @@ npx -y @deepseek-ai/dsh plugin --profile <name> add @liustack/modlens@3.22.2
|
|
|
153
153
|
|
|
154
154
|
```yaml
|
|
155
155
|
minimumReleaseAgeExclude:
|
|
156
|
-
- '@liustack/modlens@3.
|
|
156
|
+
- '@liustack/modlens@3.23.0'
|
|
157
157
|
```
|
|
158
158
|
|
|
159
159
|
或者只为这一条命令解除冷静期,注意它解除的是这条命令解析到的所有包,不只 modlens:
|
package/dsh/index.js
CHANGED
|
@@ -548,14 +548,24 @@ function restoreUpstreamSource(messages, wrapperId, upstream) {
|
|
|
548
548
|
|
|
549
549
|
function registerVisionProvider(ctx, config, ownProviders, evidenceCache) {
|
|
550
550
|
// Wrap only the text-only members of these families. Their own vision
|
|
551
|
-
// models (present or future: deepseek-vl/ocr/janus, glm-4.5v, glm-5v
|
|
552
|
-
// need no bridge and are excluded by name and
|
|
551
|
+
// models (present or future: deepseek-vl/ocr/janus, glm-4.5v, glm-5v-...,
|
|
552
|
+
// deepseek-v4-flash-vision-exp) need no bridge and are excluded by name and
|
|
553
|
+
// by declared modality. The name gate matters on its own: third-party
|
|
554
|
+
// catalogs copy an id without its modalities, and a vision model handed a
|
|
555
|
+
// wrapper twin loses its native sight. Family matching also strips a vendor
|
|
556
|
+
// namespace (OpenRouter's z-ai/glm-5.2:free, ~-prefixed aliases), because
|
|
557
|
+
// the text-only member is the same model wherever the id carries a prefix.
|
|
553
558
|
const families = config.families || ['deepseek', 'glm']
|
|
554
|
-
const VISION_ID = /(deepseek-(vl|ocr)|janus|glm-[\d.]*v(\b|-))/i
|
|
559
|
+
const VISION_ID = /(deepseek-(vl|ocr)|janus|glm-[\d.]*v(\b|-)|\bvision\b)/i
|
|
555
560
|
const shouldWrap = (info) => {
|
|
556
561
|
const id = String(info?.id ?? '').toLowerCase()
|
|
557
|
-
|
|
558
|
-
|
|
562
|
+
// The model's own name: alias marker and vendor namespace stripped. The
|
|
563
|
+
// vision-name gate reads only this, so a gateway namespace that happens
|
|
564
|
+
// to contain the word cannot veto the text model behind it.
|
|
565
|
+
const unaliased = id.replace(/^~/, '')
|
|
566
|
+
const bare = unaliased.slice(unaliased.lastIndexOf('/') + 1)
|
|
567
|
+
if (!families.some((family) => id.startsWith(family) || bare.startsWith(family))) return false
|
|
568
|
+
if (VISION_ID.test(bare)) return false
|
|
559
569
|
if (Array.isArray(info?.inputModalities) && info.inputModalities.includes('image')) return false
|
|
560
570
|
return true
|
|
561
571
|
}
|
package/package.json
CHANGED
package/skills/modlens/SKILL.md
CHANGED
|
@@ -20,11 +20,11 @@ powershell -ExecutionPolicy Bypass -File <skill-dir>\scripts\run.ps1 <args>
|
|
|
20
20
|
|
|
21
21
|
It resolves a working runtime (PATH `modlens`, then `npx`, then `bunx`) and forwards your arguments unchanged. Exit 78 means no runtime: relay the `nextSteps` from its stderr JSON instead of retrying.
|
|
22
22
|
|
|
23
|
-
If your harness forbids running scripts, reason through the same order by hand and run the first line that works (the pinned version is 3.
|
|
23
|
+
If your harness forbids running scripts, reason through the same order by hand and run the first line that works (the pinned version is 3.23.0):
|
|
24
24
|
|
|
25
|
-
1. A `modlens` on `PATH` whose major version is 3 and is at least 3.
|
|
26
|
-
2. Otherwise, if `npx` exists: `npx --yes --package @liustack/modlens@3.
|
|
27
|
-
3. Otherwise, if `bunx` exists: `bunx --bun @liustack/modlens@3.
|
|
25
|
+
1. A `modlens` on `PATH` whose major version is 3 and is at least 3.23.0: `modlens <args>`.
|
|
26
|
+
2. Otherwise, if `npx` exists: `npx --yes --package @liustack/modlens@3.23.0 modlens <args>`.
|
|
27
|
+
3. Otherwise, if `bunx` exists: `bunx --bun @liustack/modlens@3.23.0 <args>`.
|
|
28
28
|
4. Otherwise tell the user no JavaScript runtime was found and that installing Node 22.19+ (https://nodejs.org) or Bun (https://bun.sh) is the next step. Do not claim modlens itself failed.
|
|
29
29
|
|
|
30
30
|
`references/runtime.md` documents the pin and the diagnostic fields.
|
|
@@ -24,7 +24,7 @@ $ErrorActionPreference = 'Stop'
|
|
|
24
24
|
# package.json version, and the release script rewrites it on every bump.
|
|
25
25
|
$Package = '@liustack/modlens'
|
|
26
26
|
$Bin = 'modlens'
|
|
27
|
-
$Pinned = '3.
|
|
27
|
+
$Pinned = '3.23.0'
|
|
28
28
|
# -------------------------------------------------------------------------------
|
|
29
29
|
|
|
30
30
|
$NativeNote = 'no native artifact is published for this tool yet; phase A ships npm launch paths only'
|
|
@@ -22,7 +22,7 @@ set -eu
|
|
|
22
22
|
# package.json version, and the release script rewrites it on every bump.
|
|
23
23
|
PKG="@liustack/modlens"
|
|
24
24
|
BIN="modlens"
|
|
25
|
-
PINNED="3.
|
|
25
|
+
PINNED="3.23.0"
|
|
26
26
|
# -------------------------------------------------------------------------------
|
|
27
27
|
|
|
28
28
|
NATIVE_NOTE="no native artifact is published for this tool yet; phase A ships npm launch paths only"
|