dsh-jev-prune
基于语义和收据机制压缩与修剪上下文 适合在长对话中面临上下文压力、需要智能精简历史记录的用户。
安装
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add dsh-jev-prune@0.1.1说明文档
阅读完整 README ↗Configuration
Start with a dry run in the profile's plugin entry:
- id: jev-prune
config:
dryRun: true
judgeOn: pressure
softLimit: "55%"
compactReceipts: true
compactOn: pressure
compactSoftLimit: "70%"
After inspecting /jev, set dryRun: false to apply reductions.
| Option | Default | Purpose |
|---|---|---|
keepMode | budget | Rank candidates; trimming budget follows context pressure. |
preserveRecent / compactPreserveRecent | 4 / 1 | Independent recent-node protection. |
headChars / tailChars | 600 / 200 | Verbatim content retained by layer 1. |
compactQuantile | 0.34 | Tail fraction on each judgment axis; use the intersection. |
compactTools | Read-only allow-list | Limits which tool pairs may be compacted. |
receiptTextChars | 400 | Bounds verbatim assistant-visible notes in receipts. |
dryRun | false | Judge and report without applying changes. |
Full configuration and pressure-gate details · Configuration example
In-session usage
| Entry point | Purpose |
|---|---|
/jev, jev_prune_status | Ledger for both layers: cached judgments, cumulative savings, takeover state, tool-name index |
jev_prune_now | Force one layer-1 trimming pass |
jev_compact_now (supports dryRun) | Force one layer-2 receipt compaction and list every gate's exclusion counts; in dryRun it also prints the full receipt text |
jev_restore | Safety valve: fetch back the original text that a checkpoint moved out (read-only) |
jev_probe_shapes | Print the real event shapes and the resolved tool names, for adapting to a different DSH version |
In normal operation both layers are driven automatically by context pressure; no manual step is needed.