ljsysfurryACE/dsh-agentframe-plugins--packages-compaction-agentframe0

@agentframe/dsh-compaction

替代LLM摘要的语义与物理KV压缩后端

AI 分析

适合需要大幅降低Token消耗、实现免模型调用上下文压缩的用户。

套件
@agentframe/dsh-compaction
版本
0.1.0
授權
MIT
最近更新
2026年9月12日

安裝

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:ljsysfurryACE/dsh-agentframe-plugins#d598f5d09da0c8a474982a3a36176820186202ad&path:packages/compaction-agentframe

使用

在 profile 的 cordis.patch.yml 中把 compaction-basic 替换为:

- id: compaction-agentframe
  name: '@deepseek-ai/dsh-compaction-agentframe'
  config:
    semantic: true
    retainRatio: 0.2
    physical: true

配置

字段默认说明
semantictrue语义压缩(保留高信息行)
retainRatio0.2压缩后保留比例
physicaltrue物理压缩记账(bytes/token)
bytesPerToken7776INT4 压缩后每 token 字节
autotrue自动压缩