Skip to content

Support Controller API sessions in Agents App#311608

Merged
TylerLeonhardt merged 4 commits intomainfrom
tyler/civic-capybara
Apr 21, 2026
Merged

Support Controller API sessions in Agents App#311608
TylerLeonhardt merged 4 commits intomainfrom
tyler/civic-capybara

Conversation

@TylerLeonhardt
Copy link
Copy Markdown
Member

  1. use the new api to create a session
  2. make sure those Claude sessions are setting the correct metadata that Agents need
  3. document this hidden special contract that we've depended on

Co-authored-by: Copilot copilot@github.com

1. use the new api to create a session
2. make sure those Claude sessions are setting the correct metadata that Agents need
3. document this hidden special contract that we've depended on

Co-authored-by: Copilot <copilot@github.com>
Copilot AI review requested due to automatic review settings April 21, 2026 05:56
@TylerLeonhardt TylerLeonhardt self-assigned this Apr 21, 2026
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

Adds first-class support in the Agents sessions UI for Claude sessions created via the ChatSessionItemController API, ensuring sessions are created with real URIs up front and are grouped under the correct workspace label using ChatSessionItem.metadata.

Changes:

  • Route Claude “first message” sending through IChatSessionsService.createNewChatSessionItem to avoid the untitled→commit→swap flow.
  • Populate ChatSessionItem.metadata.workingDirectoryPath for new Claude sessions (and propagate metadata on fork) so Agents grouping doesn’t fall back to “Unknown”.
  • Document the implicit metadata contract relied on by Agents session grouping.
Show a summary per file
File Description
src/vs/sessions/contrib/copilotChatSessions/browser/copilotChatSessionsProvider.ts Adds a Claude-specific controller-based first-chat send path that creates real session URIs up front.
src/vs/sessions/SESSIONS_PROVIDER.md Documents the ChatSessionItem.metadata contract and key priority used for workspace/repo grouping.
extensions/copilot/src/extension/chatSessions/vscode-node/claudeChatSessionContentProvider.ts Sets Claude session item metadata (working directory) on new sessions and copies metadata on fork.

Copilot's findings

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

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 21, 2026

Screenshot Changes

Base: eeafd9cd Current: e46e8425

Changed (2)

editor/inlineChatAffordance/InlineChatOverlay/Light
Before After
before after
editor/inlineCompletions/other/JumpToHint/Dark
Before After
before after

@TylerLeonhardt TylerLeonhardt marked this pull request as ready for review April 21, 2026 17:18
@TylerLeonhardt TylerLeonhardt enabled auto-merge (squash) April 21, 2026 17:19
@TylerLeonhardt TylerLeonhardt merged commit 6b77674 into main Apr 21, 2026
26 checks passed
@TylerLeonhardt TylerLeonhardt deleted the tyler/civic-capybara branch April 21, 2026 17:30
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.

4 participants