AllShadowAnan/dsh-context-compressor ↗★ 0

dsh-context-compressor

User-set absolute context ceiling for DeepSeek Harness: when a session's estimated context reaches the configured token limit, the harness automatically compacts the conversation. Ships a dedicated settings page (host half + browser half). 适合需要严格控制Token消耗、防止长对话超出模型窗口限制的用户。

Package
dsh-context-compressor
Compatibility
Unverified
Version
1.0.1
License
MIT
Last updated
Oct 6, 2026

Other repositories with this package name

Install

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:AllShadowAnan/dsh-context-compressor

配置

同样这四个字段也可以从组合层预置——插件的 cordis.patch.yml,或 profile 的补丁:

- insert:
    - id: context-compressor
      name: dsh-context-compressor
      config:
        enabled: true
        contextLimit: 120000
        retainTokens: 20000
        maxRounds: 3

id 是设置页所编辑的设置命名空间,不是包名。如果你要改名,请保持三处一致(lib/index.js 的 SETTINGS_NS、lib/client.js 的 SETTINGS_NS、以及补丁行的 id)。