Repository navigation
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. What this changesThis PR generates compact tool presentation metadata and removes rich tool and capability catalogs from Control UI boot imports. Example: Cold-load Chat with an exec tool row.
Review scores
ProductKind: Performance · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this maintainer-directed optimization removes unnecessary boot data while preserving existing presentation behavior; no actionable code defect was found. Priority: P3 Before mergeNone. FindingsNone. Tests
Agent review detailsHow this fits togetherThe build-time tool catalog generator supplies bundled metadata to Control UI resolvers, which turn tool names into labels and icons while detailed renderers retain the full catalog. flowchart TD
A[Canonical tool metadata] --> B[Existing catalog generator]
B --> C[Compact presentation snapshot]
B --> D[Full tool catalog]
C --> E[Boot label and icon resolvers]
D --> F[Detailed tool renderer]
E --> G[Control UI]
F --> G
Technical reviewBest possible solution: Retain the compact projection in the existing generator and land only after the recorded performance acceptance criteria are satisfied. Do we have a high-confidence way to reproduce the issue? Current-main compact resolvers directly import the full generated catalog, establishing the unnecessary dependency in source; no runtime reproduction was performed during this read-only review. Is this the best way to solve the issue? This is a small, coherent solution: derive presentation-only data from the canonical generator, preserve detailed consumers, and erase capability-table runtime imports without changing their values. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against a9ff0f760527. Provenance checked
TestingProof path: unit tests only. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource -3, Generated +300, Other +27. Total +324 across 8 files. Added test files: 0. View PR surface stats
Review metrics
LabelsLabel changes:
Label justifications:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 23, 2026, 9:18 AM ET / 13:18 UTC. |
What Problem This Solves
Chat imported the complete tool display catalog to paint tool names and icons, including action details that those first-render consumers never read. Generate compact presentation and detail projections from the existing canonical catalog, and keep detail-only data on its existing lazy path. Replace two broad capability-catalog imports with type-checked literals for the one capability each caller needs.
User Impact
User impact: Chat and New Session download less JavaScript while retaining the same tool names, icons, and detail behavior.
Why This Change Was Made
The native/shared catalog is unchanged. The detail projection preserves field order, fallback behavior, and explicit empty arrays that suppress fallback; it omits unused action labels and undefined detail entries. No new state owner, dependency, loading boundary, or cache is added.
Byte proof
Matched builds compare exact
a7f5566707d367af3f246391a9e87b1477700eafwith revised candidate4942d8594fd7daa4946e80edf0fbacab78d0d59f(tree4a53d4bb2c3c250e9139b4585182fc21fa1b65bc), using Node 24.22.1, identical fixed metadata, and all 29 canonical plugin payloads. Gzip values are shipped sidecar bytes.All CSS bytes and requests are unchanged; strict performance checks report no violations or warnings. Startup raw JS is unchanged; its Brotli sidecars grow 189 B. The campaign's gzip surface budgets hold. Chat/New Brotli shrink 1,786/1,300 B.
The previously observed tool-rich load also needs detailed metadata. Remapping all 33 additional observed assets, closing their static imports, and including the current static graph gives this built-payload accounting, not fresh browser timing:
The 2,240 B static saving is not the runtime-union saving. Additional content grows 1,844 B gzip, offset by the static cut. This refinement removes the earlier head's observed net payload growth by omitting metadata unused by the detail resolver.
Chat's cap ratchets to 1,361,269 B, preserving proportional headroom with
floor(baseCap × candidateBytes / baseBytes). New Session keeps its stricter existing 802,467 B cap. Startup's cap and baseline are unchanged.Evidence
pnpm tool-display:checkpnpm tsgo:uipnpm deadcode:knipexamples/inline-incident/control-ui.ts, also present in retained exact-base evidence4942d8594fd7daa4946e80edf0fbacab78d0d59fAfter the build, formatting wrapped one type annotation without changing its tokens; cap comments/constants were tightened. No runtime source changed after the measured build.
Timing acceptance
Run ten strictly alternating cold-cache base/candidate pairs through the real bundled Gateway and retain all 20 samples. Both Chat transcript-visible and enabled-composer medians must be ≤1.05× baseline, with neither p95 worse. Static byte savings do not establish this timing result. A failed cell keeps this candidate unready. The coordinator’s standing rule explicitly permits one further ten-pair batch, evaluated cumulatively as described below.
The preceding
fa1ac3c5f8b9340b4d3cbdbeaf7c35e95e5f037ahead failed its ten-pair timing contract: composer p95 1,381.20→1,461.20 ms (+5.79%). Its actual load also grew 747 B gzip because it retained the full rich catalog alongside the compact projection. That old head will not land. The revised projection’s initial timing is below; the old negative evidence remains recorded here.Revised-head initial timing (failed)
Run 40013423439 measured exact
4942d859againsta7f55667: ten strict ABAB cold-cache pairs, fixed 240-message fixture, new bundled Gateway/browser process per sample, gzip, no tracing. All 20 observations and 1,080 raw/gzip transport receipts were independently verified; no warnings. Host: four CPUs (affinity 0–3), Node 24.22.1 Linux x64, 16,555,134,976 B RAM.Observed application JavaScript is 1,364,231 → 1,363,835 B gzip, 54 → 54 requests. Seven synthetic plugin scripts add the same 1,953 uncompressed bytes on each side. This confirms the small complete-load saving, not a timing win.
The coordinator’s original authorization says: “Going forward, a timing cell is clean if its median regression is ≤5% and p95 isn't worse, or if a rerun of ten more pairs puts it inside that band.” Exactly one additional ten-pair batch was run under that standing rule. The final decision below uses all 40 samples together, with no exclusions. There will be no third batch.
Final decision — closed, timing gate failed
The authorized additional ten-pair batch completed in run 40015295249. Both batches retain their original records and identical source, workload, and asset-manifest identities. The author independently verified all 40 observations and all 2,160 raw/gzip transport receipts; no warnings or exclusions.
The small complete-load saving (396 B gzip) does not override this result. The measurements do not establish the cause of the tail movement, but they do not satisfy the agreed landing rule. This candidate is closed without merging; its source and original negative evidence remain available. No third timing batch or budget ratchet is applied.
Size
Ten files: 4,195 → 5,551 lines (+1,356). Most growth is generated JSON (presentation and detail projections) produced by the existing generator; the canonical registry remains the sole source. The handwritten changes restrict each consumer to fields it actually reads.
Screenshots
Current-head before/after captures were inspected in full and contain only the synthetic fixture.