fix(runtime): preserve Codex transcript turn boundaries#271
Conversation
|
PR Title: fix(runtime): preserve Codex transcript turn bound... Commit: 本次PR修复了Codex交互式会话中多轮对话时transcript缺少turn boundary的问题。主要变更:将BufferedTextWriter持久化为类字段,新增turnCount计数器,并在第二轮及以后的runHumanMessage调用时执行beginTurn(),在上一轮输出末尾追加换行符以实现回合分隔。测试新增了transcript字段的断言验证。经审查,变更逻辑自洽,没有发现引入安全、正确性或回归风险的问题。 |
|
PR Title: fix(runtime): preserve Codex transcript turn bound... Commit: 本次 PR 仅修改了 该测试通过 测试覆盖了前序 fix commit 中修复的 Codex 交互式消息 turn boundary 丢失问题。测试逻辑与 整体评估:变更范围单一、意图明确,测试代码结构清晰,未发现正确性、安全性或可维护性方面的可执行问题。 |
Summary
Preserve boundaries between consecutive Codex interactive turns in the runtime transcript.
The interactive session now keeps its buffered text writer and inserts a newline before a subsequent turn when the previous output did not end with one. This
prevents output from adjacent turns from being concatenated while avoiding redundant separators when a newline is already present.
Testing
npm testnpm run typecheckgit diff --check origin/main..HEADChecklist
with no configuration or interface changes.