Skip to content

perf(ui): split tool display identity from detail metadata - #188996

Closed
steipete wants to merge 3 commits into
mainfrom
solid2/w-boot-tool-metadata-current
Closed

steipete wants to merge 3 commits into
mainfrom
solid2/w-boot-tool-metadata-current

Conversation

@steipete

@steipete steipete commented Oct 31, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Tool labels and icons import the complete native display catalog, including argument-detail keys and action metadata they never read. Generate compact identity data and complementary detail data from the existing canonical config, and let each browser consumer import only its projection. The native catalog is unchanged.

This draft is unqualified and must not be merged: the retained current-base cohort fails local readiness. No performance acceptance is claimed. The attempted runtime co-location did not remove its request and is not included in this diff.

Qualification rule, recorded before the current-main cohort

Compare current main dda109cacbbefd3a6dfcc442ac97e2107b6c62c8 with candidate b8d5f4fd704ec7cb38b0bf506a7ebc5b76a885c4, using the same immutable production-renderer harness. Run 20 serial counterbalanced base/base-control/head triplets per profile (localhost and 100 ms RTT at 10,000 kbps), with fresh process and HTTP cache for every observation. Keep every observation. Report independent A/A and B/H median/p95/range, script and task CPU, long tasks, readiness, and host load. The timing band is at most 5% median regression and no worse p95 (sub-1% p95 movement is noise unless confirmed); an affected-path regression beyond 20% blocks acceptance. No filtering, A/A subtraction, extra file prewarming, or interpreting a preload as bytes not downloaded. Capture coverage and compiler diagnostics separately from ordinary timing.

Require lower Chat raw/gzip bytes, no startup growth beyond 64 B build variance, preserved lazy boundaries, and no attributable readiness/CPU regression in either profile. Exact current-main build, focused checks, fresh coverage ranking, and sanitized first-screen images will replace the pending rows before readiness/landing.

Evidence

The unchanged implementation passed UI/tooling typechecks, identity (8), display (14), and CI scope (27) tests and generated-catalog validation. Source and generated-manifest reviews had no actionable P0–P2 findings. Current head also passed the production build, UI typecheck, and production Knip.

Current-base result: rejected pending an explained fix

All 120 ordinary observations completed: 20 counterbalanced base/control/head triplets per profile. No observations were removed. Strict byte checks pass, but local readiness does not.

Metric Base → head Median / p95 change A/A median / p95 change
Startup raw / gzip JS 277,746 / 88,763 → 277,746 / 88,760 B 0 raw / −3 gzip B 3 JS + 1 CSS requests unchanged
Chat raw / gzip JS 4,068,113 / 1,273,610 → 4,045,199 / 1,266,163 B −22,914 raw / −7,447 gzip B 20 JS + 3 CSS requests unchanged
New Session raw / gzip JS 2,513,039 / 780,413 → 2,503,749 / 778,303 B −9,290 raw / −2,110 gzip B 15 JS + 3 CSS requests unchanged
Local shell interactive 227.05 → 348.55 ms +53.51% / +1.20% −3.13% / −5.94%
Local composer ready 333.55 → 368.85 ms +10.58% / −16.23% −1.54% / −22.16%
Local transcript ready 564.90 → 633.15 ms +12.08% / −3.80% −1.66% / −8.37%
Local script CPU 689.081 → 681.944 ms −1.04% / −0.23% −0.87% / −3.66%
Local task CPU 1309.883 → 1302.548 ms −0.56% / −1.10% −0.38% / −2.27%
Local boot long tasks 247.5 → 243.5 ms −1.62% / −1.13% +0.20% / −1.13%
100 ms RTT shell interactive 1345.5 → 1340.25 ms −0.39% / −0.48% +0.07% / +0.49%
100 ms RTT transcript ready 1585.15 → 1584.75 ms −0.03% / −0.76% +0.46% / +0.30%
100 ms RTT script CPU 805.635 → 807.311 ms +0.21% / +0.66% +0.66% / −1.31%
100 ms RTT task CPU 1539.159 → 1552.073 ms +0.84% / −1.13% +0.27% / −1.22%

Host load ranged approximately 16–37. A concurrent source-review filesystem census overlapped 11 observations during 03:14:53–03:15:58 UTC on October 31. All are retained. Candidate delays also occur before and after that interval, so overlap is not an explanation or waiver.

The byte-identical 817-byte runtime has request-to-response-start medians of 8.55 / 7.95 / 47.20 ms for base/control/head, while transfer remains approximately 0.3 ms. Its underlying scheduling cause is unproven. Flat CPU and an unexplained HTTP wait do not waive the failed local readiness result. No replacement cohort or extra worker warmup is claimed.

Current coverage and compiler diagnostics were not run after this timing failure. The earlier exact-head coverage below remains explicitly historical. Byte reductions also include generated regrouping of existing welcome/mascot code into New Session, not just the catalog projection. No new lazy boundary was introduced.

Earlier base 4f1515d → candidate fe2ddf4 builds saved 22,914 raw / 7,409 gzip B on Chat, with startup within 2 B and unchanged request counts. That earlier timing cohort is unqualified: local shell median was +24.64%, local A/A was -10.35%, and an unchanged tiny runtime had bimodal response delays. Transcript +1.82%, RTT transcript -0.23%, and flat CPU do not erase the shell result. The current-main cohort is separate; no old observation will be removed or relabeled. Compiler diagnostics retain a brief unrelated source-analysis overlap and are descriptive only.

Handwritten production/generator LOC: 364 → 422 (+58); tests: 189 → 243 (+54); generated browser JSON: 0 → 1,289; manifest: 1,888 → 1,891 (+3). A two-line test allocation accompanies the focused tests. Generated catalogs remain checked outputs, never an editable second owner.

Earlier exact-head coverage ranking (fresh current-main ranking pending)

The following measurements are explicitly from 4f1515d → fe2ddf4, not the candidate above. Local V8 evaluated source was 4,470,711 → 4,447,782 B, executed ranges 1,989,629 → 1,979,663 B, unused ranges 2,481,082 → 2,468,119 B. V8 source coverage and actual HTTP downloads have separate denominators. The frequency column describes source triggers, not population telemetry.

Source-reviewed top 30 unused-at-boot bytes

Head fe2ddf4dc6e14b0005d6c8c9d629fafdf58f6c9e. All 240 rows across localhost/RTT base/head are source-reviewed; 0 unresolved identities. Full tables and checks are in top30-index-reviewed.json and the four *-top30-reviewed.md files.

These are generated raw-byte partitions. Module and exclusive-function views overlap. Frequency describes the source trigger, not population telemetry. V8 execution coverage is not a completed-network or parse/compile ledger.

Names corrected after reading generated bodies: the registerMcpEnglish and defineSolidBridge locations are whole-module initializers; Fa initializes optional inline rail CSS. ipaddr.js is reachable synchronously through transcript media normalization as well as reader/preview views.

Top 30 modules (ranked by localhost head)

# Source / verified function Base local / RTT unused B Head local / RTT unused B Follow-up
1 node_modules/.pnpm/[email protected]/node_modules/markdown-it/dist/markdown-it.mjs 32,726 / 32,726 32,726 / 32,726 mixed — Common message rendering; unused grammar depends on future message syntax. Some library extension/configuration modes are not used by this caller. The whole parser is not rare or freely deferrable.
2 node_modules/.pnpm/[email protected]/node_modules/dompurify/dist/purify.es.mjs 12,396 / 12,396 12,396 / 12,396 mixed — Common security boundary for rendered Markdown/JSON. Sanitization branches are input-dependent; alternate DOM-return/import modes are library capabilities, not this string-rendering caller.
3 ui/src/pages/chat/components/chat-model-picker-panel.tsx 12,156 / 12,156 12,156 / 12,156 common — Opening, searching and choosing from the model picker. Closed-menu boot does not construct panel rows; catalogue/access/loading states are conditional.
4 node_modules/.pnpm/@[email protected]/node_modules/@tanstack/virtual-core/dist/esm/index.js 12,123 / 12,123 12,123 / 12,123 mixed — Common transcript scroll, resize and row measurement; horizontal/multilane/platform/smooth-scroll branches depend on configuration. The shared virtualizer is not wholly optional.
5 ui/src/components/solid/settings-ui.tsx 11,322 / 11,322 11,320 / 11,320 common — Shared controls used by settings and chat configuration. Unused exports run when their forms/toggles/segmented controls are presented.
6 ui/src/lib/protocol-validators.generated/approvals.js 10,221 / 10,221 10,221 / 10,221 mixed — Approval replay validation already runs at chat subscription, including empty replay. Unused nonempty/event variants run when agent work asks approval or an outcome arrives; keep the trust boundary.
7 ui/src/pages/chat/components/chat-composer-plus-menu-body.tsx 10,003 / 10,003 10,004 / 10,004 common — Opening the composer plus menu; attachment choices plus available skills/connectors/libraries. Camera and capability mutations remain feature-conditional.
8 ui/src/pages/chat/chat-pane-side-panels.ts 9,622 / 9,622 9,622 / 9,622 mixed — Common conversation/context/subagent/session-rail toggles; mobile restoration and companion attachment/question flows are conditional. Initial layout ownership also runs at boot.
9 node_modules/.pnpm/[email protected]/node_modules/linkify-it/build/index.mjs 8,970 / 8,970 8,970 / 8,970 mixed — Common URL autolinking in future Markdown. Scheme/fuzzy-link/punctuation branches depend on text and configured options; unsupported configurations are not ordinary follow-ups.
10 ui/src/pages/chat/chat-composer-capability-host.tsx 8,861 / 9,055 8,861 / 9,055 mixed — Plus-menu capability initialization is a common follow-up; skill/library/tool-access reads and add-server mutations depend on chosen feature. Lazy dialogs remain guarded by open state.
11 ui/src/pages/chat/chat-pane-sharing.ts 8,851 / 8,851 8,851 / 8,851 mixed — Typing updates are common in shared sessions; remote typing, multiple-identity suggestions and accept/reject/share paths require those states.
12 ui/src/app/app-shell-chrome.ts 8,749 / 8,749 8,749 / 8,749 mixed — Common keyboard, navigation, palette and resize work. Debug overlay, approval opening and lazy-action recovery are conditional. The owner is needed at initial mount.
13 ui/src/pages/chat/components/chat-effort-picker-panel.tsx 8,721 / 8,721 8,722 / 8,722 common — Opening reasoning/effort/fast-mode options and selecting one, with model/access-dependent rows.
14 node_modules/.pnpm/[email protected]/node_modules/ipaddr.js/lib/ipaddr.js 8,647 / 8,647 8,647 / 8,647 mixed — Synchronous transcript normalization reaches this library through message-normalizer -> media/parse -> media/parse-output -> net-policy/ip. Remote MEDIA URLs trigger canonical/legacy/embedded IP and special-range validation; optional reader/preview callers also use it. The fixture misses content-dependent security branches, not an optional-only library. Module initialization parses the benchmark prefix even when no remote media is present.
15 ui/src/pages/chat/components/chat-composer-view.tsx 8,515 / 8,515 8,516 / 8,516 mixed — Initial composer plus common slash/skill/mention/emoji input states; goals, voice/video and recovery/disabled states are conditional. The full unused partition is not one rare feature.
16 ui/src/app/app-root.tsx 8,515 / 8,515 8,514 / 8,514 mixed — Initial application/connection/shell root; common route changes plus conditional login, focused windows, approval/question documents and error recovery.
17 ui/src/pages/chat/components/chat-header-session-menu-content.tsx 8,352 / 8,352 8,353 / 8,353 common — Opening the session header menu constructs organization, appearance, sharing and layout entries. Mutation/permission/mobile states select additional branches.
18 ui/src/components/select-picker-view.tsx 8,268 / 8,268 8,268 / 8,268 common — Opening/filtering/selecting pickers and keyboard navigation. Sheet/windowed presentation and custom row content depend on caller and viewport.
19 node_modules/.pnpm/@[email protected]_patch_hash=421b418083c0218bb54ceb3e12bd0eb74a84e86474ca26cc1f1114abbe58de48/node_modules/@solidjs/signals/dist/prod/store/store.js 8,132 / 8,188 8,188 / 8,188 mixed — Common reactive reads/writes and publication. Array/nested/clone/descriptor operations depend on state shape; runtime ownership cannot be removed just because this fixture missed branches.
20 ui/src/components/session-progress-card-solid.tsx 8,127 / 8,127 8,126 / 8,126 mixed — Progress card is already rendered at boot here. Unused composer/details/board placements and card actions/menus run as the same progress data is shown or edited elsewhere; retry/timeout/motion states are conditional.
21 ui/src/pages/chat/components/chat-header-session-menu-mobile.tsx 8,071 / 8,071 8,069 / 8,069 common — Normal narrow/mobile version of the header menu. Owner/group/icon/advanced subpages run when that submenu is selected. Desktop fixture absence is not rare usage.
22 ui/src/components/session-menu-view.tsx 8,010 / 8,010 8,008 / 8,008 common — Sidebar/header session menu row construction; appearance, owner/group, snooze and advanced choices run on those ordinary menu actions.
23 ui/src/pages/chat/chat-pane-history.ts 7,871 / 7,871 7,871 / 7,871 mixed — History observer/hydration runs at boot; scroll toward older history is common. Refresh, catalog continuation, rewind/fork and branch switching are conditional follow-ups.
24 ui/src/lib/protocol-validators.generated/activity.js 7,822 / 7,822 7,822 / 7,822 mixed — Common future streamed tool/activity updates and sidebar activity. Union variants, delegation/reaction/observer metadata and malformed-input paths depend on payload; keep validation at the boundary.
25 ui/src/components/session-organizer.ts 7,800 / 7,800 7,798 / 7,798 mixed — Common pin/archive/group and sidebar organization. Drag/drop variants, ancestry rules and failed-mutation recovery are conditional.
26 ui/src/pages/chat/chat-outbox-owner.ts 7,661 / 7,661 7,659 / 7,659 mixed — Common fresh send/draft/queue projection work. Stored recovery, failed admissions, edits and lifecycle cleanup require those states; ordinary sending also uses this owner.
27 ui/src/lib/sessions/github-publication-owner.ts 7,560 / 7,560 7,560 / 7,560 rare — Opt-in GitHub publication surface. When visible it automatically loads options/status; selecting account, publishing, confirmation and retry require that publication flow. Rare here means specialized relative to ordinary chat, not measured population frequency.
28 ui/src/pages/chat/chat-pane-lifecycle.ts 7,543 / 7,543 7,543 / 7,543 mixed — Common pane focus/activation, session changes, visibility and disposal; reconnect, browser annotation, staged attachments and resume cases are conditional.
29 ui/src/components/solid/menu.tsx 7,537 / 7,537 7,537 / 7,537 common — Common opening/navigating menus. Some non-lazy menus construct initial bodies; lazy menus gate bodies. Nested/custom/control rows depend on actual entries.
30 ui/src/pages/chat/chat-send-submit.ts 7,489 / 7,489 7,489 / 7,489 common — First/later message submission. Slash/goal/edit/attachment/offline branches are conditional, but send itself is the principal follow-up.

Top 30 functions (ranked by localhost head)

# Source / verified function Base local / RTT unused B Head local / RTT unused B Follow-up
1 ChatModelPickerPanel / ui/src/pages/chat/components/chat-model-picker-panel.tsx:123:1 11,202 / 11,202 11,202 / 11,202 common — ChatModelPickerPanel: construct model picker only when opened; search/catalogue/access variants are conditional.
2 ChatHeaderSessionMenuContent / ui/src/pages/chat/components/chat-header-session-menu-content.tsx:65:1 8,352 / 8,352 8,353 / 8,353 common — ChatHeaderSessionMenuContent: opening the session header menu.
3 useSessionMenuEntries / ui/src/components/session-menu-view.tsx:64:1 7,807 / 7,807 7,804 / 7,804 common — useSessionMenuEntries: shared sidebar/header menu construction.
4 handleSendChat / ui/src/pages/chat/chat-send-submit.ts:97:1 7,407 / 7,407 7,407 / 7,407 common — handleSendChat: first/later submit, with admitted optional paths.
5 ChatEffortPickerPanel / ui/src/pages/chat/components/chat-effort-picker-panel.tsx:129:1 6,902 / 6,902 6,904 / 6,904 common — ChatEffortPickerPanel: open and select effort/thinking options.
6 createMobileHeaderSessionMenu / ui/src/pages/chat/components/chat-header-session-menu-mobile.tsx:114:1 6,592 / 6,592 6,591 / 6,591 common — createMobileHeaderSessionMenu: normal narrow-screen submenu alternatives.
7 AppearancePicker / ui/src/components/session-icon-picker-solid.tsx:52:1 5,771 / 5,771 5,773 / 5,773 common — AppearancePicker: session-menu appearance/icon/color selection, conditional on entering that submenu.
8 sendPreparedChatQueueItem / ui/src/pages/chat/chat-send-delivery.runtime.ts:58:1 5,713 / 5,713 5,712 / 5,712 common — sendPreparedChatQueueItem: first send and queued delivery. Admission precedes dynamic import; streaming runtime download is started alongside it.
9 useChatSessionSharingMenu / ui/src/pages/chat/components/chat-session-sharing-menu.tsx:31:1 5,628 / 5,628 5,630 / 5,630 common — useChatSessionSharingMenu: session-header sharing menu, only when session sharing controls are available.
10 isBoardSnapshot / check_0 / ui/src/lib/protocol-validators.generated/board.js:50:16 5,458 / 5,458 5,458 / 5,458 rare — Generated check_0 inside isBoardSnapshot: restore a cached board/widget snapshot. A cache/board-state path, not normal plain-chat submission; validation must remain before adopting untrusted saved data.
11 createMessageImagePresentation / ui/src/pages/chat/components/chat-message-images-solid.tsx:59:1 5,285 / 5,285 5,281 / 5,281 common — createMessageImagePresentation: show image attachments in future or older messages; blob/server handoff, load failures and gallery actions are conditional.
12 session-panel-rail.css inline initializer / deferred-ui-support-DaOiLmTX.js:50997 4,946 / 4,946 4,946 / 4,946 rare — Generated initializer Fa contains session-panel-rail.css?inline string plus setup. Runs for desktop/portals/link-reader panel modules, not generic mobile logic; ordinary chat uses the separate stylesheet. Specialized panel feature, no population frequency claim.
13 ChatComposerPlusMenuBody / ui/src/pages/chat/components/chat-composer-plus-menu-body.tsx:385:1 4,692 / 4,692 4,693 / 4,693 common — ChatComposerPlusMenuBody: plus-menu open and selected feature pages.
14 agent-select module initializer (mapped as defineSolidBridge) / ui/src/components/agent-select.tsx:30:1 4,352 / 4,352 4,351 / 4,351 common — Generated lazy module initializer for agent-select templates and bridge definition, including its renderer; not a call to defineSolidBridge itself or just the anonymous renderer. Loading the agent selector is a common follow-up; option/avatar/menu behavior is conditional on its state.
15 useSessionMenuDetails / ui/src/components/session-menu-details-solid.tsx:18:1 4,192 / 4,192 4,193 / 4,193 common — useSessionMenuDetails: construct advanced/session-detail menu sections; selected search/communication states are conditional.
16 canApplySessionListSnapshot / ui/src/lib/sessions/session-list-query.ts:37:1 4,037 / 4,037 4,037 / 4,037 common — canApplySessionListSnapshot: a subsequent session-change event is checked against current roster membership; used automatically while chatting, not an opt-in menu.
17 runHeaderSessionOperation / ui/src/pages/chat/chat-pane-session-operations.ts:54:1 3,855 / 3,855 3,855 / 3,855 common — runHeaderSessionOperation: explicit header rename/pin/archive/etc. mutation, dynamically imported after action capture.
18 buildChatItems / ui/src/pages/chat/chat-thread-build.ts:131:1 3,783 / 3,783 3,782 / 3,782 mixed — buildChatItems runs at boot; unused branches cover future streamed tools/reasoning/queued rows, searches, canvas and permissions. Cannot defer the whole builder.
19 drainStoredChatOutbox / ui/src/pages/chat/chat-outbox-drain.ts:140:1 3,657 / 3,657 3,657 / 3,657 common — drainStoredChatOutbox: fresh admission as well as persisted FIFO/reconnect recovery. It is not only crash recovery.
20 loadChatRoute / ui/src/pages/chat/route-loader.ts:253:1 3,652 / 3,652 3,652 / 3,652 mixed — loadChatRoute runs on cold route. Remaining branches resolve other ordinary session links/navigation and conditional catalog, preference, ambiguity/unavailable paths.
21 createHumanMentionEngine / ui/src/pages/chat/components/chat-composer-mention-menu-engine.ts:48:1 3,496 / 3,496 3,496 / 3,496 common — createHumanMentionEngine: selected-person mention lookup after @ input; created by the existing idle-import adoption path, not ordinary plain text.
22 normalizeStoredQueueItem / ui/src/lib/chat/outbox-store-codec.ts:112:1 3,494 / 3,494 3,494 / 3,494 common — normalizeStoredQueueItem: ordinary queue serialization as well as persisted queue reads; attachment/goal/recovery variants depend on submitted data.
23 MicrophoneMenu / ui/src/pages/chat/components/chat-composer-microphone-menu.tsx:9:1 3,387 / 3,387 3,387 / 3,387 rare — MicrophoneMenu: optional microphone/device selection when using audio; platform/device alternatives are conditional. Already lazy with idle warming.
24 renderEntries / ui/src/components/solid/menu.tsx:430:26 3,358 / 3,358 3,358 / 3,358 common — renderEntries: row rendering for an opened/gated menu, including groups, custom content and controls.
25 WorkingStatus / ui/src/pages/chat/components/chat-working-indicator.tsx:48:1 3,260 / 3,260 3,260 / 3,260 common — WorkingStatus: next active agent run/status display; approvals, retry and subagent waits select conditional branches.
26 createModalPolicy / ui/src/components/modal-dialog.tsx:136:1 3,261 / 3,261 3,259 / 3,259 common — createModalPolicy: opening a modal needs shared focus, inertness, dismissal and focus-return behavior. Individual dialogs are conditional; the policy is not camera-only.
27 camera modal JSX children getter / ui/src/pages/chat/components/chat-camera-capture.tsx:306:5 3,188 / 3,188 3,188 / 3,188 rare — Generated JSX getter for the camera modal when stage is not closed; camera capture/review/error is explicit optional device interaction.
28 coalesceTurn / ui/src/pages/chat/chat-tool-activity-coalesce.ts:218:1 3,144 / 3,144 3,144 / 3,144 common — coalesceTurn already runs its empty projection path. Remaining work merges actual streamed/persisted tool call/result projections during normal agent activity.
29 PluginViewContent / ui/src/plugins/control-ui-view.solid.tsx:61:1 3,141 / 3,141 3,141 / 3,141 rare — PluginViewContent: explicit plugin-contributed surface/view; shell/sidebar/chat expose generic slots but no plugin view means no renderer call. Specialized plugin feature relative to plain chat.
30 PersonReferenceContent / ui/src/components/solid/person-reference.tsx:25:1 3,129 / 3,129 (outside top 30) 3,129 / 3,129 (outside top 30) common — PersonReferenceContent: an explicitly selected person reference appearing in a message, then hover/click profile card. Plain-name text does not trigger it.

RTT-only top-30 function

RTT rank 2: capability-host module initializer at ui/src/pages/chat/chat-composer-capability-host.tsx:48:1, 8,651 unused raw B. Generated lazy module initializer Ir, not registerMcpEnglish itself: defines capability host/class and dialog loaders before common plus-menu capability use. Connector/library mutations remain conditional. The previous mapped display name registerMcpEnglish does not describe the full span.

Every generated function is checked against the actual UTF-16 span and its sealed hash; mapped source content is checked against the pinned Git source and emitted sourcemap. Unmapped Fa is checked as a CSS-string initializer. Numeric values and ranking order are unchanged.

@steipete steipete added the ci:full Keep ordinary native-locale CI selection on the next PR run. label Oct 31, 2026
@clawsweeper

clawsweeper Bot commented Oct 31, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui scripts Repository scripts size: XL labels Oct 31, 2026
@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. merge-risk: 🚨 other 🚨 Merging this PR has meaningful risk outside the owned taxonomy. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Oct 31, 2026
@clawsweeper

clawsweeper Bot commented Oct 31, 2026

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge.

What this changes

This PR generates separate tool identity and detail catalogs so Control UI labels and icons import less metadata.

Example: Cold-load Chat and display a web_search tool label.

  • Before: The label resolver imports the complete native catalog, including argument-detail metadata.
  • After: The resolver imports compact identity data and still displays Web Search with the search icon.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The implementation is focused and source-consistent, but retained performance evidence leaves acceptance unresolved.
Proof confidence 🦐 gold shrimp (3/6) This maintainer-authored PR is outside the ordinary contributor proof gate; its complete body supplies production-renderer measurements, while older coverage is explicitly historical and no accepted shipped-entry-point result is claimed.
Patch quality 🦐 gold shrimp (3/6) No actionable review findings were identified.

Product

Kind: Performance · Worth it: Yes · Fix scope: Complete
User problem: Chat and New Session download tool argument metadata when their initial labels and icons only need identity data.
Reason: The maintainer-authored direction removes unnecessary transfer through the existing owner without changing product behavior; landing remains conditional on performance acceptance.

Merge readiness

⛔ Blocked before merge - 1 item remains

Keep this maintainer-directed draft open: the catalog split is coherent, but the author explicitly withholds performance acceptance and merge readiness.

Priority: P3
Reviewed head: b8d5f4fd704ec7cb38b0bf506a7ebc5b76a885c4

Before merge

  • Resolve merge risk - Before merge, the PR owner must explain and resolve the retained local readiness regression against the recorded acceptance rule; reduced bytes and flat CPU do not establish acceptable startup behavior.

Findings

None.

Tests

  • Missing end-to-end proof: No qualifying shipped-Gateway cold-load result is supplied for this candidate; the reported renderer-harness cohort is explicitly rejected by its acceptance rule.
Agent review details

How this fits together

The build-time generator projects canonical tool metadata into bundled resources; browser resolvers consume tool names and arguments to produce labels, icons, and detail summaries.

flowchart TD
  A[Canonical tool configuration] --> B[Existing catalog generator]
  B --> C[Unchanged native catalog]
  B --> D[Browser identity catalog]
  B --> E[Browser detail catalog]
  D --> F[Labels and icons]
  E --> G[Detailed tool summaries]
  F --> H[Control UI]
  G --> H
Loading

Technical review

Best possible solution:

Keep the projections in the existing generator and retain the draft until the optimization meets its recorded performance acceptance rule.

Do we have a high-confidence way to reproduce the issue?

Current main directly imports the complete catalog for labels and icons, establishing unnecessary metadata reachability in source; this read-only review performed no runtime reproduction.

Is this the best way to solve the issue?

The smallest complete approach is the existing generator producing complementary projections while preserving labels, icons, empty-array semantics, and the shared detail resolver; the inspected diff follows that approach.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against ece4ca85af0e.

Merge-risk options

Maintainer options:

  1. Resolve the readiness result (recommended)
    The PR owner investigates the delayed response-start path and establishes that the resulting candidate satisfies the existing acceptance rule while retaining the negative observations.
  2. Retire the optimization if it cannot qualify
    The maintainer closes the draft if the transfer saving cannot be achieved within the agreed readiness limits.

Provenance checked

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

  • Pinned introduced change: The introduced diff extends the existing generator, replaces browser catalog imports, updates generated boot grouping, and routes generated snapshots through existing guards; no separate editable metadata owner is introduced. (scripts/tool-display.ts:127, b8d5f4fd704e)
  • Current main retains the unnecessary import: Fetched main still imports the full native catalog in compact identity, icon, and detail resolvers; the central optimization is not implemented there. (ui/src/lib/chat/tool-display-identity.ts:1, ece4ca85af0e)
  • Retained current-head measurements: The complete PR body reports Chat gzip bytes decreasing from 1,273,610 to 1,266,163 with unchanged requests, but local shell readiness median increases 53.51%, composer readiness 10.58%, and transcript readiness 12.08%. The author rejects acceptance, retains every observation, and identifies an unexplained response-start delay rather than an established patch cause. (b8d5f4fd704e)
  • Earlier attempt did not land: perf(ui): keep rich tool metadata out of boot #181636 implements the same canonical presentation/detail projection approach and was closed without merging after cumulative timing failed both p95 gates; its results do not qualify this candidate. (scripts/tool-display.ts:143, ece4ca85af0e)
  • Display contract and provenance: The shared resolver consumes action detail keys but not action labels; the projection preserves explicit empty arrays and fallback precedence. The existing lightweight identity boundary comes from perf(ui): defer detailed tool rendering from chat boot #181052, and semantic icon ownership from improve: native tool rows show Tool Search calls and every client shares tool icons #165095 remains intact. (src/agents/tool-display-common.ts, b8d5f4fd704e)
  • Failed check attribution: The failed PR context and evidence check reports missing authored body sections, although the current body contains them; it identifies no diff-caused runtime or test failure. Skipped downstream checks provide no broad validation. (b8d5f4fd704e)

Likely related people:

  • Peter Steinberger: Raw commit 2c5b726 adds ui/src/lib/chat/tool-display-identity.ts:12 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 2c5b726de0e9; files: ui/src/lib/chat/tool-display-identity.ts)

PR surface

Source +4, Tests +54, Generated +1289, Other +59. Total +1406 across 12 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 4 29 25 +4
Tests 3 54 0 +54
Docs 0 0 0 0
Config 0 0 0 0
Generated 2 1289 0 +1289
Other 3 87 28 +59
Total 12 1459 53 +1406

Review metrics

Metric Value Why it matters
Handwritten production versus tests Production and generator +58 lines; tests +54 lines. Growth supplies checked projections and distinct parity, sparse-detail, and CI-routing coverage rather than a new runtime owner.

Labels

Label changes:

  • add P3: This is a bounded boot-transfer optimization without an established urgent user-facing failure.
  • add merge-risk: 🚨 other: The retained measurements show slower local readiness beyond the agreed performance limits, with attribution unresolved.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🦐 gold shrimp.

Label justifications:

  • P3: This is a bounded boot-transfer optimization without an established urgent user-facing failure.
  • merge-risk: 🚨 other: The retained measurements show slower local readiness beyond the agreed performance limits, with attribution unresolved.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🦐 gold shrimp.

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Explain and resolve the delayed runtime response-start path before qualifying the optimization under the existing acceptance rule.

Rating scale

6/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.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed October 30, 2026, 11:42 PM ET / October 31, 2026, 03:42 UTC.

@steipete

Copy link
Copy Markdown
Contributor Author

Remote-readiness handoff from round 3: #189141's cold ledger measures the current baseline at 250 ms RTT / 3 Mbps. All 23 declared assets start in one discovery wave; they transfer 1,207,282 B, with 810,374 B in the shared + Chat bundles. Initial history arrives before those bundles finish. Syntax highlighting and Mermaid are already lazy in this plain-text fixture.

The ledger separates required first paint from conditional tool presenters, closed controls, header subviews, catalogs and media. This remote PR leaves those boot owners with your existing work and changes only reconnect recovery. Hashed asset caching is already immutable; no cache-header fix is needed here.

@steipete

Copy link
Copy Markdown
Contributor Author

Closing this unqualified metadata-only experiment. Its byte split did not establish the required cold-readiness improvement, so it is not a landing candidate. The cold-path byte/RTT handoff recorded here remains useful evidence and is preserved.

The lane continues on current main with #189444's corrected coverage baseline and a separate conditional-rendering/early-prefetch experiment. Any future metadata change will need its own current-head readiness qualification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui ci:full Keep ordinary native-locale CI selection on the next PR run. merge-risk: 🚨 other 🚨 Merging this PR has meaningful risk outside the owned taxonomy. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. scripts Repository scripts size: XL

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant