Skip to content

feat(client): web search sources show as one Sources row you can expand - #2

Closed
akash9676 wants to merge 1 commit into
mainfrom
feat/web-search-sources-row
Closed

akash9676 wants to merge 1 commit into
mainfrom
feat/web-search-sources-row

Conversation

@akash9676

@akash9676 akash9676 commented Nov 19, 2026 •

Copy link
Copy Markdown
Owner

Problem

When an agent searches the web, the pages it found are buried. They sit three clicks deep (tool group → search row → output), behind query labels, and the reply itself shows no usable sources. Upstream #30979 reports the garbled inline citations. pingdotgg/t3code#36338 hides those markers but explicitly leaves out readable, clickable sources.

Change

A tool group that searched the web now gets one Sources · N row under it. It stays visible while the group is collapsed. Clicking it expands a list of the pages the searches returned (title and site), and each one opens in the browser. Clicking it again collapses the list.

There's no server or contract change, because web_search turn items already carry results to the client. A shared workEntriesWebSources() in client-runtime keeps http(s) URLs, drops #fragment duplicates and falls back to the hostname when a title is missing. Web/desktop and mobile each add a row built like the existing viewed-images row, and its open state lives in the same expanded-groups state as tool groups, so it survives virtualized scrolling.

Providers that send no result URLs (Codex today sends only queries) get no row, and their existing search rows are unchanged.

Scope

A small feature. Upstream accepts features only from the team or vouched contributors, so this PR lives on the fork and the idea is proposed upstream in pingdotgg/t3code#38958.

Verification

  • vp test run packages/client-runtime/src/work-log/presentation.test.ts: 21 passed, including a new case covering dedupe across searches, fragment collapse, non-http and malformed URLs, missing titles, and non-search entries in the group.
  • vp test run apps/web/src/components/chat/MessagesTimeline.logic.test.ts apps/mobile/src/lib/threadActivity.test.ts: 178 passed (existing timeline behavior unchanged).
  • Typecheck passes for packages/client-runtime, apps/web and apps/mobile. Pre-commit format, lint and knip pass.
  • Not yet done: before/after screenshots in a real web and mobile client. vp run check:changed could not run on this Windows machine (spawn ENAMETOOLONG), and mobile i18n:check fails here before generating (a Windows spawnSync issue in the script). The new key 98e8f91616613574 matches what gt generate produced for both apps.

Created with Claude Opus 5.5 in Claude Code, running in T3 Code.

Tool groups that searched the web now get a "Sources · N" row under them,
built like the viewed-images row. It stays visible while the group is
collapsed and expands to a deduped list of the pages the search returned,
opening each in the browser. Web, desktop and mobile share the derivation
in client-runtime; providers that send no result URLs get no row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added vouch:trusted Author is trusted by repo permissions or the VOUCHED list. size:L labels Nov 19, 2026
@akash9676

Copy link
Copy Markdown
Owner Author

Superseded by pingdotgg#38959.

@akash9676 akash9676 closed this Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L vouch:trusted Author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant