QIANLING-0831/dsh-memory-plus--packages-dsh-compaction-locator ↗★ 2
dsh-compaction-locator
Near-lossless compaction for the DeepSeek Harness — extends BasicCompactionEngine so each <compacted-summary> ends with an Exact Sources locator block (spill files, touched file paths, seq range), making compacted details recoverable via memory_search / read.
安装
此插件尚未提供可验证的 bundle,或兼容性检查未通过。请先阅读仓库说明。 阅读完整 README ↗
说明文档
阅读完整 README ↗cordis.patch.yml — 用本插件替代 @deepseek-ai/dsh-compaction-basic(配置完全兼容)
plugins:
- name: dsh-compaction-locator config: thresholdRatio: 0.8 retainRatio: 0.16
## 行为细节
- 定位符按 shadowed 区间的**全跨度事件**提取:spill 路径(从 tool/result 文本 `stored at:
` 解析)+ 触碰文件(从区间内 tool/call 的 `path`/`file_path` 参数);
- 纯对话区间(无文件/spill)不产出定位符块,摘要保持原样;
- 除 `summarize()` 外不改任何行为:压力判定、retain 策略、shrink 校验、KV 复用的重放前缀全部继承基类。
## 测试
```sh
node --test test/compaction-locator.test.js