DSH Recall Search
DSH Recall Search 在 DSH Host 上建立当前 Profile 的会话索引,支持按官方 Workspace、消息角色与时间筛选。标题、正文和附件显示名独立匹配。预览和引用由当前会话快照核验。
阶段二 Host 的验证环境为 Node 24 和 DSH 0.2.3-alpha.2。请求和响应见 Host–Client 冻结契约 v1。
安装和使用
预览版支持 DSH 0.2.3-alpha.2。Desktop 中打开「插件」,选择安装第三方插件,输入 github:jidekaixin2dian/dsh-recall-search,安装后点「立即启用」。
Web 使用 Node.js 24 和同版本的 DSH。安装后重启 Web。
dsh plugin --profile web add github:jidekaixin2dian/dsh-recall-search
点侧栏底部的 Recall,或在 Windows 按 Ctrl+Alt+Shift+F 打开搜索。可选智能、精确或模糊模式,并按工作区、角色和时间筛选。点命中可查看原文及上下文,也可将原文或选段引用到当前草稿。
在「索引与隐私」里可以查看覆盖率、增量同步、重建、暂停或清空索引。
Install and use
The preview supports DSH 0.2.3-alpha.2. In Desktop, open Plugins, choose Install a third-party plugin, enter github:jidekaixin2dian/dsh-recall-search, and select Enable now after installing. On Web, use the command above with Node.js 24 and restart DSH Web after installation.
Open Recall from the bottom of the sidebar or press Ctrl+Alt+Shift+F on Windows. Search session titles, messages, and attachment names. Filter by workspace, role, or time, open a hit in context, and quote a message or a selection into your current draft. Use Index & Privacy to check coverage and manage the local index.
本地验证
npm run lint
npm run typecheck
npm run build
npm test
npm run build 校验 Host 入口、Client 语法、patch、locale、依赖锁和 npm 实际打包清单。npm test 使用合成会话和独立 SQLite,覆盖检索、请求权限、生命周期及引用复核。
索引和会话
- 派生索引保存在
<DSH_HOME>/cache/dsh-recall-search/<profile-key>/index.sqlite。来源始终通过 DSH 官方会话服务读取。 - 使用原生 SQLite 持久化后端时,等待原生迁移的旧 JSONL 会话会计入部分覆盖。
- Host 启动后对账,并合并会话变更事件。手动全量构建在影子库完成后切换。清空会暂停索引。重启后继续保持暂停,直到用户显式构建。
- 搜索以会话分页。每组先展示最多两条命中,其余由展开端点加载。UI 可分别展示索引覆盖率和候选截断提示。
隔离联调
在一次命令内完成启动、验证和停止,可运行 pwsh -File scripts/restart.ps1 -Verify。加 -Native 时使用已安装的 DSH WebServer 和 Connection RPC,数据仍由合成会话提供。
需要分开运行时,使用 pwsh -File scripts/restart.ps1 启动,随后运行 node scripts/e2e.mjs 和 node scripts/inspect-index.mjs,最后用 pwsh -File scripts/restart.ps1 -Stop 停止。实例、临时凭据和检查数据均由脚本在仓库的 work/ 中管理。正常停止会移除临时凭据。
node scripts/e2e.mjs --benchmark 以 100、1,000、10,000 条合成会话测量 Host 查询 P95,并输出覆盖率和发生候选截断的次数。每种模式、每档规模各计 32 次请求。
No comments yet. Be the first to write one.