Skip to content

Conversation

@roblourens
Copy link
Member

No description provided.

Copilot AI review requested due to automatic review settings January 3, 2026 02:11
@roblourens roblourens enabled auto-merge (squash) January 3, 2026 02:11
@roblourens roblourens self-assigned this Jan 3, 2026
@vs-code-engineering vs-code-engineering bot added this to the December / January 2026 milestone Jan 3, 2026
Copy link
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 adds a new "Inspect Chat Model" developer action that allows developers to view the internal state of chat models in a markdown viewer, showing both the latest response and the full model data as JSON. It also improves the chat widget service to properly track the last focused widget on initialization and cleanup.

Key Changes

  • Added a new developer action InspectChatModelAction that opens the chat model's JSON representation in an untitled markdown editor
  • Enhanced ChatWidgetService to set the last focused widget on registration when no widget is currently focused, and to clear it when the focused widget is disposed

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.ts Adds new InspectChatModelAction that retrieves chat model data and displays it in markdown format with the latest response shown first
src/vs/workbench/contrib/chat/browser/widget/chatWidgetService.ts Ensures lastFocusedWidget is set when the first widget is registered and cleared when the focused widget is disposed

Comment on lines +105 to +112
await editorService.openEditor({
resource: undefined,
contents: output,
languageId: 'markdown',
options: {
pinned: true
}
});
Copy link

Copilot AI Jan 3, 2026

Choose a reason for hiding this comment

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

Consider using the satisfies IUntitledTextResourceEditorInput keyword for type safety, similar to the pattern used in chatCodeblockActions.ts. This ensures the object literal is properly typed and catches any type errors at compile time.

Copilot uses AI. Check for mistakes.
@roblourens roblourens merged commit b627a9c into main Jan 3, 2026
33 of 34 checks passed
@roblourens roblourens deleted the roblou/ideal-fox branch January 3, 2026 05:20
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.

3 participants