Skip to content

test(context): apply the generated native output profile to saved preflight - #7541

Merged
loopx-agent merged 1 commit into
mainfrom
codex/release220-saved-context-20261028
Oct 28, 2026
Merged

loopx-agent merged 1 commit into
mainfrom
codex/release220-saved-context-20261028

Conversation

@loopx-agent

@loopx-agent loopx-agent commented Oct 28, 2026 •

Copy link
Copy Markdown
Collaborator

The native saved-preflight regression requested only 2,000/3,000 output tokens while the accepted context profile can return a complete 64,000-byte JSON first page. A real native baseline produces a truncation warning (about 16,000 original tokens), then the fixture tries to decode that truncated text as JSON and never reaches its lifecycle assertions.

Apply the existing generated config_overrides in the isolated App fixture, use the documented 22,000-token direct result and 24,000-token code-mode emission budgets, and validate a capture immediately when page zero already reaches EOF. All source-byte/digest, full-to-delta, session/Turn identity, no-replayed-guard and no-spend assertions remain. No product behavior, frozen qualification criterion, scenario content, page limit, timeout or authority changes.

Implemented against required-work-context.md: generated native setup includes its retained-history/output overrides, direct and code-mode budgets are separate, and a complete capture may finish inline. The fixture now follows that shipped profile instead of simulating a smaller incompatible transport.

Validation: unchanged native baseline failure and bounded sanitized output-shape evidence retained. Exact-head complete saved-context module passes all 33 cases, including all four real Codex/loopback parameters. Adjacent machine configuration has 33 passes; its initial five explicit-native skips are preserved, and all five were then run with the native binary and passed. Ruff, isolated boundary and premerge pass (5 direct checks, zero selected catalog checks, zero failures/holds). An independent read-only native environment probe confirms private HOME/CODEX_HOME and disabled usage telemetry. No paid model, operator session or operator configuration is used. PR CI is not consulted under the configured policy. Final release qualification remains separate.

UI impact: none. One existing synthetic native integration fixture is corrected; its independent complete-byte oracle and negative cases are retained.

…flight

Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>

@loopx-agent loopx-agent left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewer: model_agent | gpt-6.1-sol | OpenAI | runtime_reported | reasoning_effort=max

Approval conclusion (author-owned PR; GitHub blocks formal self-approval)

动机 / Motivation

需要验证原生已保存上下文能完整读回、恢复接续且不重复准入或扣账的维护者。 现有native fixture把支持64000字节首屏的读取限制为2000/3000输出tokens,实际JSON被截断,测试在解码前就停下。 fixture应用原生setup已返回的完整输出配置与声明的传输预算;首屏已完整时直接执行原字节oracle,四种宿主的生命周期断言均能完成。 本PR仅修正一个既有隔离fixture的调用配置,不改产品页大小、原始要求、哈希oracle、超时、权限、默认启用或模型评分。

改动思路 / Approach

缩短要求或只比较摘要会丢失原有独立语义,修改公共页上限又会扩大产品范围。本头只让合成调用者采用现有setup完整返回的输出配置,并按其明确指引设置直接工具与code-mode外层两个预算。首屏已经完整时重入原字节比较逻辑,不为制造一次额外read而访问空队列。既有生命周期、真实工具执行与完整源判断仍由原owner和独立oracle完成。

具体改动 / Changes

关键内容讲解

规范为 docs/reference/required-work-context.md,不可变 revision 5fd216a90f11d721293ceeb9a380cf8333e1c7e6。generated-native-output-profile 对应现有64000字节页、20000 retained-history及22000/24000工具预算:fixture应用 configuration["config_overrides"],两层输出均按原指引执行。complete-inline-capture 对应能放下的capture可在page zero完成:队列为空时进入原 _delivered 全字节比较;它没有信任一个EOF标记来替代完整内容。presentation-does-not-readmit 对应已保存读取不重新准入或扣账:原source/digest、full/delta、session/Turn和heartbeat/spend计数断言全部保留。

完整净diff只有 tests/control_plane/test_saved_context_project.py +11/-3。新增配置仅写入本次隔离fixture的Codex配置,实际产品profile、页上限和工具指引不变。不存在内容压缩、变小的scenario、跳过oracle、增加超时或修改benchmark评分/冻结条件;预算依据为同一native工作负载的截断证据和已接受的输出合同。

对主干的风险 / Risks

最大风险是增大输出后掩盖真实输入缺失。本头仍从真实model input重建每个字节并与原capture比较;坏digest、跨来源、缺页和重复准入继续失败。CLI纯投影测试不能替代native输入与生命周期,因此保留四种原宿主及全部负例。PASS:原native基线复现截断JSON,诊断见约16000 tokens首屏被3000 cap截断;本头完整saved-context模块33项通过,含4个真实Codex/loopback参数、零skip。相邻machine配置33项通过,初次5项因未传native binary而skip的记录保留;补跑这5个原native default-off参数全部通过。Ruff、隔离边界、diff/RFC与premerge5项直接检查零失败、0selected、0hold;CI未查询。 初次相邻suite的5个skip是调用未传native binary,记录保留,后续只补跑这5个原参数并全部通过。独立只读环境诊断确认native HOME、CODEX_HOME与usage开关保持隔离,不读写操作者配置;真实推理全部是loopback synthetic provider。

我的整体评价 / Verdict

APPROVE仅覆盖 afed4573aaa7c027a709cfbc18ccdcb03f4dccf0 的fixture修复。long_horizon为not_applicable,user_experience为preserved:没有产品默认、权限或新增人工操作。完整净diff只有 tests/control_plane/test_saved_context_project.py 的fixture调用配置与首屏EOF分支,没有页面或布局变化。未验证范围为整版发布源码资格、真实付费模型与公开制品,仍由原任务独立验收。局部同域简化复用已有配置生成器和原oracle,不引入新的框架或协议,也不把一次完整传输宣称为长程收益。

English verdict: APPROVE afed457. The original truncation is reproduced; all 33 saved-context tests and all 38 adjacent machine cases are covered, including 9 real-native parameter cases. Original byte/lifecycle oracles and required local checks pass; product and release criteria are unchanged.

@loopx-agent
loopx-agent merged commit c187e90 into main Oct 28, 2026
8 of 30 checks passed
@loopx-agent
loopx-agent deleted the codex/release220-saved-context-20261028 branch October 28, 2026 00:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant