Jaylor-Wang/dsh-tool-headroom ↗★ 1

dsh-tool-headroom

Smart output compression, log denoising, syntax-preserving JSON compaction, and CCR (Content-Cache-Retrieval) cache plugin for DeepSeek Harness 适合需要压缩大体积JSON/日志输出以节省上下文Token的用户。

Package
dsh-tool-headroom
Compatibility
Unverified
Cordis peer range
^4.0.2
Version
0.1.0
License
MIT
Last updated
Oct 2, 2026

Install

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Jaylor-Wang/dsh-tool-headroom

🚀 Installation & Configuration

1. Install Plugin

In your DSH profile directory:

pnpm add dsh-tool-headroom

2. Enable Plugin (cordis.patch.yml)

Add the plugin to your cordis.patch.yml or custom agent preset:

- insert:
    - id: headroom
      name: 'dsh-tool-headroom'

3. Configuration Options

Customizable via DSH Settings UI or profile YAML:

OptionTypeDefaultDescription
enabledbooleantrueEnable or disable output compression globally
thresholdBytesnumber3072 (3KB)Minimum output size to trigger compression
maxTargetBytesnumber12288 (12KB)Target maximum size for compressed output
jsonCompressionbooleantrueEnable JSON SmartCrusher
logDenoisingbooleantrueEnable log deduplication and progress bar folding
stripAnsibooleantrueStrip terminal ANSI escape codes
collapseRepetitionsbooleantrueCollapse sequential duplicate lines
preserveErrorContextnumber8Number of context lines to preserve around errors
cacheRawOutputbooleantrueCache full uncompressed output to disk (CCR)
cacheDirstring""Custom cache path (defaults to OS temp directory)
excludedToolsstring[]["read", "read_image"]Tool names excluded from compression

3. Configuration Options

Customizable via DSH Settings UI or profile YAML:

OptionTypeDefaultDescription
enabledbooleantrueEnable or disable output compression globally
thresholdBytesnumber3072 (3KB)Minimum output size to trigger compression
maxTargetBytesnumber12288 (12KB)Target maximum size for compressed output
jsonCompressionbooleantrueEnable JSON SmartCrusher
logDenoisingbooleantrueEnable log deduplication and progress bar folding
stripAnsibooleantrueStrip terminal ANSI escape codes
collapseRepetitionsbooleantrueCollapse sequential duplicate lines
preserveErrorContextnumber8Number of context lines to preserve around errors
cacheRawOutputbooleantrueCache full uncompressed output to disk (CCR)
cacheDirstring""Custom cache path (defaults to OS temp directory)
excludedToolsstring[]["read", "read_image"]Tool names excluded from compression