@jayyuen66/dsh-zvec-grep 0.1.14 → 0.1.16
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 +23 -0
- package/README.md +26 -25
- package/README.zh-CN.md +4 -4
- package/client.js +195 -159
- package/host.js +227 -163
- package/package.json +45 -44
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,29 @@
|
|
|
2
2
|
|
|
3
3
|
The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). The deviations below are deliberate: version headings carry no release date (publish times are recorded by the registry — `npm view <package> time`), and a release may add sections beyond the standard six, such as `Not changed, deliberately` and `Earlier`.
|
|
4
4
|
|
|
5
|
+
## 0.1.16
|
|
6
|
+
|
|
7
|
+
设置卡的下拉候选与说明浮层不再漂到浏览器最左边;shared 抬到 `^0.2.8`(含运行时几何自检)。zg 检索工具与路由行为不变。
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- **下拉候选与说明浮层被钉在视口左边缘**:`.dsu-menu` 与 `.dsu-tip` 的 `position-area: block-end span-inline-start` 选中的是「行内起始列 + 中间列」,而 `position: fixed` 下该区域的起始边是**视口左边缘**、不是触发器左边缘,再叠一条 `justify-self: start`,浮层就落在 `x=0`。改为 `block-end span-inline-end`——真实 Chromium(patchright headless,156.0.8078.4)实测:1440px 视口、触发器左边缘 860px,改前浮层左边缘 0,改后 860;触发器贴到右侧时 `flip-inline` 会改成右边缘对齐,贴到视口底部时 `flip-block` 翻到上方。
|
|
12
|
+
- **锚定没兑现时改回 JS 矩形定位**:`select.ts` 与 `field.ts` 的 `place()` 此前只要 `CSS.supports("position-area: block-end")` 为真就直接 `return`,方向性错误没有任何兜底。现在锚定后先量一次浮层矩形,用 shared 0.2.8 的 `anchorPlacementOff` 判它是否真贴在触发器上(行内起始边或结束边任一在 2px 容差内贴住,且块向落在触发器下方或上方),不通过才把 `position-area` 显式置 `none` 再写 `left` / `top`。顺序是承重的:实测同时留着 `position-area` 只写坐标时块向仍由锚定决定(浮层 `y` 落在 314 而不是 160),必须先关。回退是单向的——同一个浮层一旦走过 JS 路径,后续 `resize` 不再尝试锚定,避免两个定位源来回抢。
|
|
13
|
+
- **回归测试**:`test/card-ui.test.ts` 新增 `anchorPlacementOff` 的四种对齐形态(左边缘对齐、`flip-inline` 右对齐、`flip-block` 翻上方、两轴都不沾)与容差边界,以及三条锚定用例(浮层真贴住时不写 JS 坐标、被钉到视口左侧时改写坐标并关掉 `position-area`、回退过的浮层不再重试锚定)。
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
|
|
17
|
+
- **运行时依赖 shared 抬到 `^0.2.8`**:`pnpm-workspace.yaml` 的 catalog 由根 `sync` 投影,`pnpm-lock.yaml` 随 `sync:lock` 重解;`client.js` 按新 shared 重建,内联的 `CARD_UI_CSS` 逐字节等于已装 shared 导出的那一份。0.2.8 新增的 `anchorPlacementOff` / `ANCHOR_PLACEMENT_TOLERANCE` 只被卡片内部使用,本包对外工具与 Remote 方法名单不变。
|
|
18
|
+
|
|
19
|
+
## 0.1.15
|
|
20
|
+
|
|
21
|
+
宿主开发基线抬到 `0.2.2-rc.2`,支持窗口收到 `^0.2.2-rc.1`。zg 检索工具与路由行为不变。
|
|
22
|
+
|
|
23
|
+
### Changed
|
|
24
|
+
|
|
25
|
+
- **宿主开发基线抬到 `0.2.2-rc.2`**:`devDependencies` 整组 `@deepseek-ai/dsh-*` 抬到 `0.2.2-rc.2`,并补上 rc.2 新增的 `@deepseek-ai/dsh-error`(`dsh-llm` 的精确 peer,`autoInstallPeers: false` 下须显式声明)。
|
|
26
|
+
- **支持窗口收到 `^0.2.2-rc.1`**:`engines.dsh` 与 `@deepseek-ai/dsh*` peer 由 `^0.2.1-rc.5 || ^0.2.2-alpha.3` 改为 `^0.2.2-rc.1`(单条 0.2.2 线);`@deepseek-ai/schemastery` peer 由 `^3.18.5 || ^3.18.6-alpha.1` 收到 `^3.19.0`。devDependencies 仍精确钉版。
|
|
27
|
+
|
|
5
28
|
## 0.1.14
|
|
6
29
|
|
|
7
30
|
修复 0.1.13 引入的 web 启动隐患:卡片组件收回 `client.js` 内联,移除对 `@jayyuen66/dsh-plugin-shared/client` 的模块表外置与 `cordis.patch.yml` 里的 shared 供应行。zg 命令面与 MCP 传输层不变。
|
package/README.md
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<a href="https://github.com/JayYuen666/dsh-zvec-grep/actions/workflows/ci.yml"><img src="https://img.shields.io/github/actions/workflow/status/JayYuen666/dsh-zvec-grep/ci.yml?branch=main&style=flat-square&label=ci" alt="ci" /></a>
|
|
13
13
|
<img src="https://img.shields.io/badge/license-MIT-4c1?style=flat-square" alt="MIT" />
|
|
14
14
|
<img src="https://img.shields.io/badge/node-%3E%3D24.9-4c1?style=flat-square&logo=nodedotjs&logoColor=white" alt="node" />
|
|
15
|
-
<img src="https://img.shields.io/badge/dsh-%5E0.2.
|
|
15
|
+
<img src="https://img.shields.io/badge/dsh-%5E0.2.2--rc.1-658EFF?style=flat-square" alt="dsh" />
|
|
16
16
|
<a href="https://github.com/deepseek-ai/deepseek-harness"><img src="https://img.shields.io/badge/powered_by_dsh-4D6BFE?style=flat-square&logo=deepseek&logoColor=white" alt="powered by dsh" /></a>
|
|
17
17
|
</p>
|
|
18
18
|
|
|
@@ -33,32 +33,33 @@
|
|
|
33
33
|
|
|
34
34
|
## <img src="https://api.iconify.design/lucide/file-text.svg?color=%23658EFF&height=22" height="22" width="22" align="absmiddle" alt="" /> Contents
|
|
35
35
|
|
|
36
|
-
- [
|
|
37
|
-
- [
|
|
38
|
-
|
|
39
|
-
- [
|
|
40
|
-
- [
|
|
41
|
-
- [
|
|
42
|
-
- [
|
|
43
|
-
|
|
44
|
-
- [
|
|
45
|
-
- [
|
|
36
|
+
- [ Contents](#-contents)
|
|
37
|
+
- [ What it does](#-what-it-does)
|
|
38
|
+
- [ Install](#-install)
|
|
39
|
+
- [ Shared version floor](#-shared-version-floor)
|
|
40
|
+
- [ Verify it is live](#-verify-it-is-live)
|
|
41
|
+
- [ What it does not provide](#-what-it-does-not-provide)
|
|
42
|
+
- [ Enabling it in dsh](#-enabling-it-in-dsh)
|
|
43
|
+
- [ Tools exposed to the model](#-tools-exposed-to-the-model)
|
|
44
|
+
- [zg\_search](#zg_search)
|
|
45
|
+
- [zg\_index](#zg_index)
|
|
46
|
+
- [zg\_status](#zg_status)
|
|
46
47
|
- [The rg switch](#the-rg-switch)
|
|
47
48
|
- [Root rules](#root-rules)
|
|
48
|
-
- [The search-first gate](
|
|
49
|
-
- [Settings](
|
|
49
|
+
- [ The search-first gate](#-the-search-first-gate)
|
|
50
|
+
- [ Settings](#-settings)
|
|
50
51
|
- [Remote embedding](#remote-embedding)
|
|
51
52
|
- [Asking before an explicit root](#asking-before-an-explicit-root)
|
|
52
|
-
- [Support surface](
|
|
53
|
-
- [External dependency](
|
|
54
|
-
- [Daemon (server mode)](
|
|
55
|
-
- [Public interface](
|
|
56
|
-
- [The background job surface](
|
|
57
|
-
- [Data and privacy](
|
|
58
|
-
- [Known boundaries](
|
|
59
|
-
- [FAQ](
|
|
60
|
-
- [Development](
|
|
61
|
-
- [License](
|
|
53
|
+
- [ Support surface](#-support-surface)
|
|
54
|
+
- [ External dependency](#-external-dependency)
|
|
55
|
+
- [ Daemon (server mode)](#-daemon-server-mode)
|
|
56
|
+
- [ Public interface](#-public-interface)
|
|
57
|
+
- [ The background job surface](#-the-background-job-surface)
|
|
58
|
+
- [ Data and privacy](#-data-and-privacy)
|
|
59
|
+
- [ Known boundaries](#-known-boundaries)
|
|
60
|
+
- [ FAQ](#-faq)
|
|
61
|
+
- [ Development](#-development)
|
|
62
|
+
- [ License](#-license)
|
|
62
63
|
|
|
63
64
|
## <img src="https://api.iconify.design/lucide/shield.svg?color=%23658EFF&height=22" height="22" width="22" align="absmiddle" alt="" /> What it does
|
|
64
65
|
|
|
@@ -77,8 +78,8 @@ dsh plugin --profile web add @jayyuen66/dsh-zvec-grep
|
|
|
77
78
|
Remove with `dsh plugin --profile web remove @jayyuen66/dsh-zvec-grep`. The package is on the public npm registry; no credentials, no scoped-registry line.
|
|
78
79
|
|
|
79
80
|
- **Node.js `>= 24.9`** (ESM-only; that floor is what makes `require()` of an ESM entry work, hence `engines.node`).
|
|
80
|
-
- **Host `dsh` on the `0.2.
|
|
81
|
-
- **No `@deepseek-ai/*` under `dependencies`, by contract** (`test/publish-manifest.test.ts`). Profiles install with `nodeLinker: hoisted` and `autoInstallPeers: false`, so a host package there becomes a real second copy; `@deepseek-ai/dsh-tools` keys its scheduler with a plain `Symbol`, so **every native tool call throws** in that profile while build, typecheck and coverage stay green. The `@deepseek-ai/dsh*` peers carry the same support-window range (`^0.2.
|
|
81
|
+
- **Host `dsh` on the `0.2.2-rc.1` line or later.** The host reads `engines.dsh` (`^0.2.2-rc.1`) and it **decides alone** - with that field present, compatibility is judged before `peerDependencies` is ever consulted, prereleases included. Any `0.2.x` at or above `0.2.2-rc.1` passes the host gate; strict npm peer resolution starts at `0.2.2-rc.1`. `0.3.0` and later need the risk grant `dsh plugin --profile <p> allow-version <pkg>@<ver> --dsh-version <exact> --accept-risk`. The support window rolls: at publish time this package is checked against every released host version inside the window - the judgement is the host's `--dump-config` layer line for this package, while the settings card and its namespace calls are verified once in full on the release's development baseline - and re-verified once the window moves, so the version number in this bullet is not a standing promise.
|
|
82
|
+
- **No `@deepseek-ai/*` under `dependencies`, by contract** (`test/publish-manifest.test.ts`). Profiles install with `nodeLinker: hoisted` and `autoInstallPeers: false`, so a host package there becomes a real second copy; `@deepseek-ai/dsh-tools` keys its scheduler with a plain `Symbol`, so **every native tool call throws** in that profile while build, typecheck and coverage stay green. The `@deepseek-ai/dsh*` peers carry the same support-window range (`^0.2.2-rc.1`), while the exact pins in `devDependencies` are the compile-time discipline against a second host type surface - not a claim the host consults.
|
|
82
83
|
- **Value imports are required peers.** `@deepseek-ai/schemastery` is the host fork (only its `resolve` wraps `.volatile()` fields); `@deepseek-ai/dsh-typert-protocol` provides `TypertRemoteService`, a class to `extends`; `@deepseek-ai/dsh-scope` provides `scopeOf` for the step-admission lookup; shared's `lib/text` value-imports `@deepseek-ai/dsh-output-retention`. Each sits in `peerDependencies` plus the same exact pin in `devDependencies` - missing one is `ERR_MODULE_NOT_FOUND` at load, not a graceful downgrade. `dependencies` holds `@jayyuen66/dsh-plugin-shared` and `zod` (the latter versioned through the umbrella catalog, used by the settings card's strict codecs).
|
|
83
84
|
- **What ships**: `host.js`, `client.js`, `cordis.patch.yml`, `icon.svg`, both READMEs, `CHANGELOG.md`, `THIRD_PARTY_NOTICES.md`, `locale/zh.json` + `locale/en.json`, and `docs/` (both DETAIL files). Artifacts are rebuilt by `prepack`, never committed.
|
|
84
85
|
|
package/README.zh-CN.md
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<a href="https://github.com/JayYuen666/dsh-zvec-grep/actions/workflows/ci.yml"><img src="https://img.shields.io/github/actions/workflow/status/JayYuen666/dsh-zvec-grep/ci.yml?branch=main&style=flat-square&label=ci" alt="ci" /></a>
|
|
13
13
|
<img src="https://img.shields.io/badge/license-MIT-4c1?style=flat-square" alt="MIT" />
|
|
14
14
|
<img src="https://img.shields.io/badge/node-%3E%3D24.9-4c1?style=flat-square&logo=nodedotjs&logoColor=white" alt="node" />
|
|
15
|
-
<img src="https://img.shields.io/badge/dsh-%5E0.2.
|
|
15
|
+
<img src="https://img.shields.io/badge/dsh-%5E0.2.2--rc.1-658EFF?style=flat-square" alt="dsh" />
|
|
16
16
|
<a href="https://github.com/deepseek-ai/deepseek-harness"><img src="https://img.shields.io/badge/powered_by_dsh-4D6BFE?style=flat-square&logo=deepseek&logoColor=white" alt="powered by dsh" /></a>
|
|
17
17
|
</p>
|
|
18
18
|
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
- [zg\_status](#zg_status)
|
|
47
47
|
- [rg 开关](#rg-开关)
|
|
48
48
|
- [root 判据](#root-判据)
|
|
49
|
-
- [ search-first
|
|
49
|
+
- [ search-first 门禁](#-search-first-门禁)
|
|
50
50
|
- [ 设置项](#-设置项)
|
|
51
51
|
- [远程 embedding](#远程-embedding)
|
|
52
52
|
- [显式 root 前的确认](#显式-root-前的确认)
|
|
@@ -78,8 +78,8 @@ dsh plugin --profile web add @jayyuen66/dsh-zvec-grep
|
|
|
78
78
|
卸载用 `dsh plugin --profile web remove @jayyuen66/dsh-zvec-grep`。包在公共 npm registry 上,不需要凭据,也不需要 scoped-registry 配置行。
|
|
79
79
|
|
|
80
80
|
- **Node.js `>= 24.9`**(纯 ESM;正是这个下限让 `require()` 一枚 ESM 入口成为可能,`engines.node` 因此声明)。
|
|
81
|
-
- **宿主 `dsh` 在 `0.2.
|
|
82
|
-
- **按约定,`dependencies` 下不放任何 `@deepseek-ai/*`**(`test/publish-manifest.test.ts` 钉住)。profile 以 `nodeLinker: hoisted` 与 `autoInstallPeers: false` 安装,宿主包在那里会落成真实的第二份副本;`@deepseek-ai/dsh-tools` 用普通 `Symbol` 给调度器做键,那个 profile 里**每一次原生工具调用都抛错**,而构建、类型检查与覆盖率照绿。`@deepseek-ai/dsh*` 的 peer 写同一条支持窗口范围(`^0.2.
|
|
81
|
+
- **宿主 `dsh` 在 `0.2.2-rc.1` 或更新的 `0.2.2` 这条线上。** 宿主读 `engines.dsh`(`^0.2.2-rc.1`)且**单独决定**——该字段在场时兼容性先于 `peerDependencies` 判定,prerelease 参与比较。`0.2.x` 里不低于 `0.2.2-rc.1` 的都通过宿主装载门;npm 的严格 peer 解析从 `0.2.2-rc.1` 起算。`0.3.0` 及以上需要风险授权 `dsh plugin --profile <p> allow-version <pkg>@<ver> --dsh-version <确切版本> --accept-risk`。支持窗口是滚动的:本包在发布时把窗口内的每个已发布宿主版本逐版取证(判据是宿主 `--dump-config` 里本包的层行;设置卡与它的命名空间调用另在发布基线上全量取证一次),窗口滚动后重新取证,不把这一句里的版本号当长期承诺。
|
|
82
|
+
- **按约定,`dependencies` 下不放任何 `@deepseek-ai/*`**(`test/publish-manifest.test.ts` 钉住)。profile 以 `nodeLinker: hoisted` 与 `autoInstallPeers: false` 安装,宿主包在那里会落成真实的第二份副本;`@deepseek-ai/dsh-tools` 用普通 `Symbol` 给调度器做键,那个 profile 里**每一次原生工具调用都抛错**,而构建、类型检查与覆盖率照绿。`@deepseek-ai/dsh*` 的 peer 写同一条支持窗口范围(`^0.2.2-rc.1`),`devDependencies` 里的精确钉版才是防「第二份宿主类型」的编译期纪律——那不是宿主会去读的声明。
|
|
83
83
|
- **值导入都是必需 peer。** `@deepseek-ai/schemastery` 是宿主 fork(只有它的 `resolve` 认 `.volatile()` 字段);`@deepseek-ai/dsh-typert-protocol` 提供 `TypertRemoteService` 这个要 `extends` 的类;`@deepseek-ai/dsh-scope` 提供步骤准入判定用的 `scopeOf`;shared 的 `lib/text` 自己值导入 `@deepseek-ai/dsh-output-retention`。四者都落 peer 加同版精确钉的 devDependencies——缺一枚就是装载期 `ERR_MODULE_NOT_FOUND`,不是优雅降级。`dependencies` 里是 `@jayyuen66/dsh-plugin-shared` 与 `zod`(后者版本走伞根 catalog,供设置卡的 strict codec 校验)。
|
|
84
84
|
- **随包发什么**:`host.js`、`client.js`、`cordis.patch.yml`、`icon.svg`、两份 README、`CHANGELOG.md`、`THIRD_PARTY_NOTICES.md`、`locale/zh.json` + `locale/en.json`、`docs/`(两份 DETAIL)。产物由 `prepack` 现产,不入库。
|
|
85
85
|
|