Skip to content

Cache chat progress content part#308942

Draft
pwang347 wants to merge 4 commits intomainfrom
pawang/chatProgressContentPart
Draft

Cache chat progress content part#308942
pwang347 wants to merge 4 commits intomainfrom
pawang/chatProgressContentPart

Conversation

@pwang347
Copy link
Copy Markdown
Member

@pwang347 pwang347 commented Apr 10, 2026

Metric (Renderer) Insiders (without fix) Code OSS (with fix)
Trace duration ~55s ~23s
Heap baseline 171 MB 112 MB
Heap peak 183 MB 117 MB
MajorGC count 55 2
MajorGC rate 1.0/s 0.09/s
MajorGC total time 19,418 ms 650 ms
MajorGC % of wall time 35% 3%
MajorGC avg duration 353 ms 325 ms
Avg freed per MajorGC ~6-8 MB ~1.8 MB
MinorGC count 10 24
Incremental marking events 33,927 1,130

Copilot AI review requested due to automatic review settings April 10, 2026 04:32
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR aims to reduce re-creation of chat tool progress UI parts by caching and updating an existing ChatProgressContentPart instance during tool streaming/progress updates in the chat widget.

Changes:

  • Cache a ChatProgressContentPart in the tool streaming subpart and update it via updateMessage(...) instead of recreating it.
  • Cache a ChatProgressContentPart in the tool progress subpart and update it via updateMessage(...) instead of recreating it.
Show a summary per file
File Description
src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolStreamingSubPart.ts Reuses a single progress content part while tool invocation is in streaming state, updating message content in place.
src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolProgressPart.ts Reuses a single progress content part for tool progress rendering, updating message content in place.

Copilot's findings

  • Files reviewed: 2/2 changed files
  • Comments generated: 2

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 10, 2026

Screenshot Changes

Base: 1028f069 Current: c70ed7a8

Changed (2)

agentSessionsViewer/WithBadge/Dark
Before After
before after
agentSessionsViewer/WithBadge/Light
Before After
before after

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