Repository navigation
Replies: 6 comments
|
Thanks — your citations check out against the installed bundle, and I have the capture you asked for. Verified on dsh 0.1.0-rc.6: 1. Bundle confirmation (installed, not repo-HEAD):
And 2. The top-level dump renders exactly one instance per id, and all three rows sit in this section: and later: So the visible rows are the dsh-base (host) copies: the web-app 3. The preset-realm copy does not appear in the top-level dump at all. The dump has no 4. Honest runtime status: the workaround is composition-verified but I have not yet observed a runtime compaction event in a web session — the one post-fix session ran only 13 steps, well under the 59K threshold. The decisive experiment is a long web session (30+ tool calls) with Agreed on the stop-gap caveat: re-enabling the host copy sidesteps the 2026-08-10 per-preset ownership decision rather than fixing the realm wiring — the maintainers should decide between host-plane compaction vs repairing the preset realm, as you say. |
|
Runtime result — the decisive experiment ran, and it's decisive: compaction still never fires in web sessions, even with the host copy re-enabled. Setup: dsh 0.1.0-rc.6, web profile, web process started after my home patch (so the composition with Result:
So the host-copy re-enable is composition-verified but runtime-ineffective: web sessions still don't compact. That points to your candidate (1): the session resolves the preset-realm backend (or none), not the host copy we enabled. One extra measurement that may explain a lot — the fixed request overhead from the session's own
The failed mission hit ~64K of conversation (5 full reads of a 31.8KB file alone ≈ 40K+ tokens). For compaction to help, the token meter must be counting this dense tool-result surface correctly — the behavior is consistent with the meter undercounting (e.g. a chars-per-token heuristic on file content) so the 0.6 threshold in real terms is never reached in time. Worth checking Happy to run any variant you want (e.g. a controlled headless long session with a file-read-heavy task, or |
|
The 47-schema measurement gives us a useful discriminator, but it does not yet prove that schemas are the root cause. At current The decisive trace is therefore
A clean second arm would fork the same pre-failure session and keep the file-read pattern unchanged, but expose only two entry tools (search → exact schema → call) or a strict manual allowlist. Record canonical tool-schema JSON bytes, provider prompt usage, meter values, first failing step, and compaction events. If that arm survives longer while compaction still never fires, it isolates standing schema overhead as one contributor without confusing it with the compaction bug. Disclosure: I maintain MCP Lens, which can provide that two-entry DSH arm. It is not a fix for retained history/tool-result growth; I am offering it only as a reproducible control. |
|
Thanks for the correction — it's fair, and it sharpens what we actually observed. Our "~18K" figure was a chars-derived estimate at ~3 chars/token (6,072 system chars + 47,229 schema chars), not the meter's heuristic value and not a provider usage anchor. At the fallback meter's 4 chars/token it's ~13.3K heuristic tokens, which makes the meter's gap to real usage even larger than we framed — we never claimed the meter itself counted 18K. On the three-arm trace: our failure maps to arm 1. We ran a 22-step file-read mission in a web session after re-enabling the compaction rows (disabled:false, thresholdRatio 0.6, verified via web-profile dump-config), swept all session JSONL for compaction events — zero — and the request died with "Context size has been exceeded" from the llama-server provider while the meter showed no pressure. That's baseline.kind=estimated, meter below the pressure gate, provider rejects: estimator/usage-anchor mismatch, consistent with your arm 1. We did not capture baseline.kind/baseline.tokens/surfaceDeltaTokens/totalTokens per step (not exposed to us in rc.6's session logs), so those numbers can't be reconstructed retroactively. Status on our side: dsh is parked pending the rc.7-era fixes; long-session work has moved to a harness with working compaction. If we resume dsh testing, the per-step trace fields you list are exactly what we'd capture. Not adopting the MCP Lens control arm today, but the disclosure is appreciated and the two-entry-tools isolation logic is sound as a reproducible control. |
|
这条线索追得很漂亮(@zoahdev 的"挂了两份"更正、@Crow0077 的 dump-config 与全量 session 扫描、@labmimors 把估算口径钉成三条可判别的臂)。我想加一个没人查过的输入,它可能正好落在 arm 1 里。 阈值有两个乘数,讨论到现在只查了其中一个@labmimors 那三条臂全部围绕左边的 token 计量( 但 为什么值得怀疑:DSH 用两条 seam 描述同一个模型DSH 把"这个模型的信息"拆成两处公开面:
容量不在列表里,得单独 resolve。 这是我们(做 DSH 上的兼容层)实打实踩过的坑:我们只投影了前一条 seam,于是消费方读 那次的后果和这帖高度相似:下游的压缩逻辑写的是 @Crow0077 的现象正好对得上其中一个方向:98304 的真实窗口,如果闸门按某个更大的默认值(比如 128000)算,58,982 的压力门就变成了更高的数——于是"计量没到门限、provider 已经拒了"这个组合成立,而不需要计量本身错得很离谱。 怎么便宜地验证@Crow0077 说 rc.6 的 session log 里拿不到
这条的好处是它能证伪:回 98304 就干脆排除掉这个可能,讨论回到计量口径;回别的,就等于免费拿到了一个新的根因候选。 一个次要的观察这帖已经出现过一次"组合层面正确、运行时无效"(re-enable 了 host copy,运行时依然零压缩事件)。 如果最后查出来确实是这个,那真正该提的诉求可能不是"web profile 别关压缩",而是 "压缩闸门解析不到 contextWindow 时必须 fail loud,不许静默落默认值"——毕竟一个基于错误窗口计算的阈值,比没有阈值更难发现。 边界与利益相关我们不修 DSH 自家组件——compaction 栈、token meter、web bundle 的 patch 都在 DSH 里。 上面第二节那个"两条 seam"是我们自己在 DSH 的公开 llm 面上踩出来的一手经验(我们的回归测试现在专门盯这条);但我没有读过 利益相关:我维护 pi2dsh(Pi 生态兼容层)。这条不推销——你们在查 DSH 自家的压缩栈为什么不触发,装任何第三方插件都不会让它开始触发。 |
Uh oh!
There was an error while loading. Please reload this page.
Environment
0.1.0-rc.6(npm@deepseek-ai/dsh)webllama-server),contextWindow: 98304,maxTokens: 16384Symptom
Long-running web sessions (multi-step agent task, ~50 tool calls) fail mid-turn with
PI_AI_ERROR: Context size has been exceeded— the provider rejects the request (send_error: Context size has been exceededin the server log). The session JSONL shows zero compaction events even after the conversation crosses the provider window.Root cause
node_modules/@deepseek-ai/dsh-web-app/cordis.patch.ymldisables the entire compaction stack for the web profile:The comment adjacent to these rows says the compaction backend should live on the host plane (per the 2026-08-10 host-plane-ownership note) — but the web bundle only disables the preset-plane rows without mounting a host-plane replacement. Net effect: web sessions have no auto-compaction path at all. The
headlessprofile keepscompaction-basicenabled and compacts normally.Repro
dsh webwith any provider.maxTokens), the turn dies withContext size has been exceeded.Expected
Web sessions auto-compact like headless sessions (default
thresholdRatio 0.8; configurable).Workaround (verified)
Home-level
~/.dsh/cordis.patch.yml:Optionally tune thresholds on the same patch entry:
Verified via
dsh --profile web --dump-config(patch applied after the web-app bundle); sessions then compact and survive past the previous failure point.Suggested fix
Either mount the compaction backend on the host plane for web (per the ownership note), or remove the
disabled: truerows until the host-plane migration lands — as shipped, a core reliability feature is silently off in the primary interactive profile.All reactions