You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A tool-heavy Desktop Session can become permanently stranded after automatic history compaction returns a provider-completed but structurally invalid summary.
Observed on main@3a9824a7e with a custom openai-responses-compatible connection and gpt-5.6-sol:
the selected model had no declared contextWindow, so Runtime used the bounded fallback capacity (32,000 history budget + 16,384 reserve);
the active Turn accumulated large GitHub issue and pull-request tool results;
active tool-result pruning ran and reported 74 pruned results / 352,159 estimated tokens saved;
history compaction then ran eight times in the same Turn;
all eight model calls completed, but every compaction decision failed open with malformed_summary_missing_section;
the final Turn outcome was context_budget_exhausted;
a short follow-up message immediately ran another history_compact call, which completed with finishReason: stop after 113,942 ms (37,498 input tokens, 1,895 output tokens), but the Turn still ended as context_budget_exhausted with detail summarizer_failed.
The summary validator is behaving correctly: an incomplete summary must not replace durable history. The liveness defect is that the same Session has no bounded repair or escape path. Repeating or regenerating can issue the same doomed compaction again, while Desktop presents only the generic "Task run failed" toast.
The Session history remained intact and Runtime Host stayed ready; there was no process exit. GitHub access itself was not the failure.
How to reproduce
Configure a custom Responses-compatible relay model without declaring its context window, so the default bounded fallback applies.
Start a Desktop Session that accumulates enough text-heavy tool results to exceed that capacity. Fetching several full GitHub issue / PR bodies in one Turn reproduces the observed shape.
Make the history summarizer return non-empty text with finishReason: stop that omits one or more required checkpoint sections.
Observe that the summary is correctly rejected as malformed_summary_missing_section and no checkpoint is written.
Continue until the outgoing request remains over capacity.
Observe context_budget_exhausted.
Send a short follow-up message or regenerate.
Observe another completed history_compact request followed by the same terminal failure, with no actionable recovery guidance.
This should also be covered deterministically with an injected summarizer; it does not require a live provider test.
Bound repair attempts for a given compaction input/failure fingerprint. Do not repeatedly spend model calls on an identical malformed-summary outcome.
After the bounded attempt is exhausted, preserve a stable diagnostic reason such as malformed_summary_missing_section through the terminal projection.
Present actionable recovery: configure the model's real context window, switch model/connection, or start a fresh task/branch.
A changed model, connection, context-window declaration, or source-history fingerprint may retry; an unchanged failure should not loop blindly.
Add regression coverage for an over-capacity, tool-heavy history whose summarizer completes normally but omits required sections.
The exact repair mechanism (one stricter retry, structured-output summary, alternate summarizer, or another bounded strategy) can be decided in implementation. Weakening or bypassing summary validation is not an acceptable fix.
Environment
Maka commit: 3a9824a7e
Maka version: 0.2.0 development build
Surface: Desktop + Runtime Host
OS: macOS 26.6 / Darwin 25.6.0 arm64
Electron: 43.4.1
Node.js: 24.18.1
Provider type: custom openai-responses-compatible
Model: gpt-5.6-sol
Runtime Host: remained ready; no local process exit captured
changing the actual context limit exposed by a custom relay;
weakening checkpoint validation;
an unrelated Electron MaxListenersExceededWarning observed earlier in the same app process.
AI assistance disclosure: Codex inspected the local durable Runtime records and source, drafted this report from the reporter-provided diagnostic, and posted it at the reporter's request.
English
What happened
A tool-heavy Desktop Session can become permanently stranded after automatic history compaction returns a provider-completed but structurally invalid summary.
Observed on
main@3a9824a7ewith a customopenai-responses-compatibleconnection andgpt-5.6-sol:contextWindow, so Runtime used the bounded fallback capacity (32,000history budget +16,384reserve);malformed_summary_missing_section;context_budget_exhausted;history_compactcall, which completed withfinishReason: stopafter 113,942 ms (37,498input tokens,1,895output tokens), but the Turn still ended ascontext_budget_exhaustedwith detailsummarizer_failed.The summary validator is behaving correctly: an incomplete summary must not replace durable history. The liveness defect is that the same Session has no bounded repair or escape path. Repeating or regenerating can issue the same doomed compaction again, while Desktop presents only the generic "Task run failed" toast.
The Session history remained intact and Runtime Host stayed ready; there was no process exit. GitHub access itself was not the failure.
How to reproduce
finishReason: stopthat omits one or more required checkpoint sections.malformed_summary_missing_sectionand no checkpoint is written.context_budget_exhausted.history_compactrequest followed by the same terminal failure, with no actionable recovery guidance.This should also be covered deterministically with an injected summarizer; it does not require a live provider test.
Expected behavior
malformed_summary_missing_sectionthrough the terminal projection.The exact repair mechanism (one stricter retry, structured-output summary, alternate summarizer, or another bounded strategy) can be decided in implementation. Weakening or bypassing summary validation is not an acceptable fix.
Environment
3a9824a7e0.2.0development build43.4.124.18.1openai-responses-compatiblegpt-5.6-solready; no local process exit capturedLogs, screenshots, or additional context
First failed Turn diagnostics:
Immediate follow-up Turn:
Related:
malformed_summary_missing_sectioncompletions as an out-of-scope compaction defect in a separate image-budget incident.Out of scope:
MaxListenersExceededWarningobserved earlier in the same app process.AI assistance disclosure: Codex inspected the local durable Runtime records and source, drafted this report from the reporter-provided diagnostic, and posted it at the reporter's request.
简体中文
发生了什么
当自动历史压缩返回一个 provider 已正常完成、但结构不合法的摘要时,一个工具结果很多的 Desktop Session 会被永久卡住。
在
main@3a9824a7e上观察到该问题,使用的是自定义openai-responses-compatible连接和gpt-5.6-sol:contextWindow,因此 Runtime 使用了有界回退容量(32,000history budget +16,384reserve);malformed_summary_missing_section失败开放;context_budget_exhausted;history_compact。该调用在 113,942 ms 后以finishReason: stop正常完成(37,498input tokens、1,895output tokens),但该 Turn 仍以context_budget_exhausted结束,详情为summarizer_failed。摘要校验器的行为是正确的:不完整摘要不能替换持久历史。活性缺陷在于,同一个 Session 没有有界的修复或退出路径。重复发送或重新生成可能再次发起同一个注定失败的压缩,而 Desktop 只显示泛化的“任务运行失败”toast。
Session 历史仍然完整,Runtime Host 也始终保持 ready,没有进程退出。GitHub 访问本身不是失败原因。
如何复现
finishReason: stop,但缺少一个或多个 checkpoint 必需章节。malformed_summary_missing_section,且没有写入 checkpoint。context_budget_exhausted。history_compact请求,以及随后相同的终止失败;界面没有提供可操作的恢复建议。该问题也应通过注入摘要器进行确定性测试,不需要依赖真实 provider 测试。
预期行为
malformed_summary_missing_section。具体修复机制(一次更严格的重试、结构化输出摘要、备用摘要模型或其他有界策略)可以在实现阶段决定。削弱或绕过摘要校验不是可接受的修复。
环境
3a9824a7e0.2.0development build43.4.124.18.1openai-responses-compatiblegpt-5.6-solready;没有捕获到本地进程退出日志、截图或其他上下文
第一次失败 Turn 的诊断:
紧接着的后续 Turn:
相关 issue:
malformed_summary_missing_sectioncompletion 记录为超出其范围的压缩缺陷。非目标:
MaxListenersExceededWarning。AI 协助披露:Codex 检查了本地持久化的 Runtime 记录和源码,基于报告者提供的诊断起草本报告,并按报告者要求发布。