Skip to content

LM-5: fixture-level AC1 compaction, AC3, AC4 and AC5 (#380) - #475

Open
BunsDev wants to merge 3 commits into
mainfrom
lm5-fixtures
Open

BunsDev wants to merge 3 commits into
mainfrom
lm5-fixtures

Conversation

@BunsDev

@BunsDev BunsDev commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

Part of #380 (LM-5). Fixture- and wire-level evidence for AC1 (compaction), AC3, AC4 and AC5, plus four small repairs. main/index.ts still constructs no LocalExecution, so product behaviour is unchanged. This PR is code and waits for Val: don't enqueue it.

Review follow-ups resolved

Both findings confirmed at b6d18767f44fc068b9383190cb169a288aa8b123 were repaired through #480, merged into this branch as signed commit 7cc57139d7598df25b685d8070f81e2e8f2d18c8. The merge tree exactly matches the reviewed repair head.

  • AC3 now races the first server arrival against early turn completion and propagates test cancellation, reporting the result and reaching cleanup. An already-aborted first-turn negative control hung before the repair, then failed promptly with the interrupted result afterward; the normal wire fixture passed.
  • AC1 and AC4 network claims now describe only the recording fixture's observations. Other destinations were not monitored.

The repair passed build and full unit validation (2,281 passes, 35 skips), with independent review finding no blockers. Hosted validation passed at 7cc57139d7598df25b685d8070f81e2e8f2d18c8: all checks succeeded, including macOS job 124887542663 with 481 desktop E2E passes, 4 skips and 7 site passes. These are CI and fixture results, not live local-runtime or human acceptance. The explicit Val approval gate above remains in force.

Repairs (each regression failed before its fix)

  • Truthful local 500. codex-cli 0.166.0 words any HTTP 500 as "We're currently experiencing high demand…" (codexErrorInfo: internalServerError). LocalExecution now reports the local server's internal error instead, and says nothing was retried or switched.
  • stream_max_retries admitted only at 0. Admission checked only request_max_retries. With retries on, Codex re-sends the whole request after a dropped stream, a 500 or a 503.
  • Compaction keys governed. compact_prompt, model_auto_compact_token_limit_scope, model_post_turn_compact_threshold_percent and model_async_compact_threshold_percent can no longer come from another layer.
  • Local target only from this Mac's window. updateThread stripped local keys only for by === "paired-desktop". It now keeps them only for by === "desktop".

Wire evidence (installed codex-cli 0.166.0, scripted loopback server, no model)

  • AC1: auto-compaction runs inline to the configured /v1/responses for the selected model, with the bearer token. The recording fixture saw no other endpoint; other destinations were not monitored.
  • AC3: a turn queued behind another profile of the same server and then stopped sends that server zero requests.
  • AC4: overflow (HTTP and stream), OOM 500, 503, a dropped stream, a killed child and Stop each end failed or interrupted, with exactly two requests observed at the recording fixture and one tool run.
  • [P1][LM-3] Run Codex against isolated local connection profiles #379 wire receipt on 0.166.0: matches 0.164.0 (same tools; a 307 is followed with the body and without the token).

Review record: docs/reviews/2026-11-01-lm5-fixtures.md, with receipts in docs/reviews/2026-11-01-lm5-fixtures/.

Verification

  • pnpm build && pnpm test exit 0 (desktop: 2,098 pass, 29 skip, 0 fail).
  • Focused suites: local-run-policy 16/16, local-model-execution 15/15, runner-local-models 15/15.
  • MODEX_LM3_WIRE=1 node --test --test-force-exit dist/test/local-codex-native.test.js: 9 + AC1 compaction + AC3 pass; AC1 live skipped.
  • Negative controls are listed in the review record.

Not done here (Val)

  • AC2 offline canary;
  • AC4 on a real runtime;
  • AC1 live;
  • managed-Mac policy check;
  • product admission.

🤖 Generated with Claude Code

BunsDev and others added 2 commits November 1, 2026 07:26
Wire tests on codex-cli 0.166.0 against a scripted loopback Responses
server (MODEX_LM3_WIRE):
- AC1: native auto-compaction goes inline to the configured server for
  the selected model, and nowhere else.
- AC3: a turn queued behind another profile of the same server and then
  stopped sends that server nothing.
- AC4: overflow (HTTP and stream), OOM 500, 503, dropped stream, killed
  child and Stop each end failed or interrupted, with no retry, no model
  switch and no second tool run.

Repairs, each red first:
- A local HTTP 500 is reported as the local server's error, not Codex's
  cloud "high demand" text.
- Admission requires the effective stream_max_retries to be 0.
- compact_prompt and the compaction threshold keys are governed.
- Only this Mac's window (by: "desktop") may set, change or clear a
  local target; the filter was a deny-list for "paired-desktop".

Also: AC3 two-profile fixture, AC5 retry and draft-settings cases, the
stale LM-5 slice 1 status line, the review record and status entry.
main/index.ts still constructs no LocalExecution.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
modex Ready Ready Preview Nov 1, 2026 3:10pm UTC

Request Review

@github-code-quality

github-code-quality Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

Code coverage overview

Languages: TypeScript

TypeScript / code-coverage-agent

main 9ecccc9 lm5-fixtures 7cc5713 +/-
66% 66% 0%

ℹ️ Calculations represent line coverage. Results may change as calculations are updated.


Updated November 01, 2026 15:57 UTC

* Correct merged PR dates to October 31 UTC (#470)

* docs: point the CF-7 review kit at its restored location (#280) (#473)

The cf7-closeout worktree was pruned after #443 merged, so the receipt's
launch commands pointed at nothing. The saved homes are restored into the
cf7-review-kit worktree from the task-evidence copy, and both saved Task
Notes reopen read-only on a build of 0a8c513. Records the two things a
reviewer will see: the notes predate #450, and the homes name the old
repository path. No human row changes.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>

This branch was successfully deployed

1 active deployment
Preview — 7cc57139 Deployed Nov 1, 2026 by vercel[bot]
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.

2 participants