🔍 问题
本地模型上下文溢出:compact-retry 插件
功能 · 源自讨论 #8375 · 更新于 2026-09-30 23:41
本地模型上下文溢出:compact-retry 插件
dsh-token-meter 固定按约 4 字符/token 估算,CJK 与大工具 schema 被低估,本地 OpenAI 兼容服务返回 exceed_context_size
安装社区插件 dsh-plugin-local-prompt-bridge(pnpm add github:tianyiming1/dsh-plugin-local-prompt-bridge 并加入 profile bundles),把溢出改写为 CONTEXT_WINDOW_EXCEEDED 触发 compact-retry,并主动用 /tokenize 预估压力
跑 llama.cpp 等本地模型时装上该插件,避免硬撞上下文上限