dsh-context-management
Agent 与会话 活跃维护

dsh-context-management

PlxloYzb/dsh-context-management

窗口化上下文压缩与历史检索,原生集成压缩流程。滑动窗口动态控制记忆范围,支持压缩内容逆向恢复,确保长对话中关键信息不丢失,保持对话连贯性与上下文利用效率。

1
Stars 标星
0
Forks 分支
1
Watchers 关注
0
Open Issues
JavaScript
主要语言
MIT
开源协议
2.2 MB
仓库大小
2 个月前
最后推送
一键安装扩展 / 插件指令
dsh plugin --profile web add github:PlxloYzb/dsh-context-management
git clone https://github.com/PlxloYzb/dsh-context-management.git
git clone git@github.com:PlxloYzb/dsh-context-management.git
README.md main

dsh-context-management

English · 简体中文

DSH 上下文管理插件,自动接管目标 profile 中各 preset 的原生 Basic 压缩,支持上下文换窗、可逆压缩和历史检索。长旅程在压力线附近优雅降级(换窗 → 就地回退 → 有限超出),并提供自适应保真:摘要足够时直答,需要精确值或逐字原文时模型自主下探无损归档。适配 DSH 0.1.7 预发布系列(本地 0.1.7-rc.1、桌面 0.1.7-rc.2),需要 Node.js ≥ 22.12。没有原生压缩的 preset(如 minimal)保持原样。

安装

CLI profile:

dsh plugin --profile web add dsh-context-management

桌面端应用(DeepSeek Harness.app)的 desktop profile 由应用独占管理,CLI 会拒绝写入;请在应用内 设置 → 插件 安装同一个包。

刚发布的版本装不上? pnpm 11 默认带供应链「最小发布时长」门(应用日志里写作 supply-chain policies):裸包名会解析 latest,但跳过刚发布不久的那个版本,退而选择足够旧的版本——于是可能装到很久以前的旧版,并因 peer 不匹配被宿主拒绝。解决办法是显式带版本号(精确版本不受该门限制):

dsh plugin --profile web add dsh-context-management@0.9.12

桌面端在 设置 → 插件 的包名栏填 dsh-context-management@0.9.12。或者等新版本超过该时长后,裸包名即可正常解析。

卸载

dsh plugin --profile web remove dsh-context-management

桌面端同样在 设置 → 插件 中卸载。

总览:功能、优越性与历史 · 设计思路 · 测试数据 · 可选后台摘要与实验 · 150k 迭代日志 · 长程实验:结论与未决清单 · 版本发布 · npm · MIT / 来源声明