Skip to content

Recommend connectors from prompt URLs - #342129

Merged
Hawk Ticehurst (hawkticehurst) merged 15 commits into
mainfrom
hawkticehurst/dynamic-connector-recommendations
Oct 21, 2026
Merged

Hawk Ticehurst (hawkticehurst) merged 15 commits into
mainfrom
hawkticehurst/dynamic-connector-recommendations

Conversation

@hawkticehurst

@hawkticehurst Hawk Ticehurst (hawkticehurst) commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

Fixes #341453
Companion product metadata: microsoft/vscode-distro#1469

The new-session composer stays quiet until its prompt contains a recognized connector URL. Matching connectors then appear through the existing chat tips UI, inheriting its setting, eligibility, layout, navigation, accessibility, and session visibility behavior.

Implementation

  • Reads connector display names, task descriptions, image URLs, and recognized URL associations from trusted product metadata through the urls field.
  • Supports Linear, Notion, WorkIQ, Azure Data Explorer, Sentry, and Slack.
  • Uses the standard chat tip surface instead of a separate recommendation row.
  • Extends chat tips with an optional 16px decorative image. Connector icons use the 2px --vscode-cornerRadius-xSmall token; ordinary tips remain text-only.
  • Shows no connector tip without a matching URL or when chat tips, the customization marketplace, Copilot connectors, or connector recommendations are disabled.
  • Keeps the selected recommendation stable while its matching URL set is unchanged.
  • Exposes every match through the existing Previous Tip and Next Tip controls when prompts contain URLs for multiple connectors.
  • Ignores product names, email addresses, lookalike hosts, and connector domains embedded in another URL's path.
  • Suppresses a dismissed connector for the composer session and follows the standard tip session-dismissal behavior.
  • Opens the exact Copilot Connector detail by carrying both the stable product key and display name. Connector lookup supports opaque catalog names without falling back to an error notification.

Before and After

Dark

Dark theme comparison

Light

Light theme comparison

High Contrast Dark

High Contrast Dark comparison

High Contrast Light

High Contrast Light comparison

Multiple Matching URLs

Multiple URL matches use existing tip navigation

Narrow Layout

Narrow layout comparison

Phone with Notices

Phone layout comparison

Additional States

No Recognized URL

No connector tip without a recognized URL

Chat Tips Disabled

No connector recommendation when chat tips are disabled

Dismissed

Dismissed connector tip

Tip with Migration Notice

Connector tip with migration notice

Keyboard Focus

Keyboard focus on the connector tip link

Validation

  • npm run typecheck-client — Passed.

  • npm run build-fast -- --client-only — Passed.

  • .\scripts\test.bat --run src/vs/sessions/contrib/chat/test/browser/newChatConnectorRecommendations.test.ts --run src/vs/workbench/contrib/chat/test/browser/chatTipService.test.ts --run src/vs/workbench/contrib/chat/test/browser/widget/input/chatInputTipPresenter.test.ts --run src/vs/workbench/contrib/chat/test/browser/aiCustomization/aiCustomizationManagementEditor.test.ts — Passed, 251 tests.

  • Targeted ESLint across the 14 changed TypeScript files — Passed.

  • Targeted stylelint for chatTipContent.css — Passed; it reported three pre-existing spacing-token suggestions on unchanged toolbar margins.

  • npm run valid-layers-check — Passed.

  • git diff --check — Passed.

  • Component Explorer connector fixture error check — Passed, 34 of 34 fixtures rendered without errors.

  • Component Explorer representative stability check — Passed, 7 of 7 fixtures stable, including Dark, Light, both High Contrast themes, narrow, dismissed, and phone-with-notices.

  • Multiple-match fixture — Stable and visually verified with Previous Tip, Next Tip, and Dismiss Tip controls.

  • Reviewed Linux blocks-CI screenshot baselines for the three changed connector fixtures — Updated from CI-provided hashes.

  • Rebased onto current origin/main; focused post-rebase tests and 38 relevant component fixtures passed.

  • Post-rebase Component Fixtures workflow (Screenshots, Playwright Fixture Tests, and aggregate check) — Passed.

Copilot AI balanced review requested due to automatic review settings October 16, 2026 17:51
@github-actions

github-actions Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Screenshot Changes

Base: 924c808f Current: 98771f42

Changed (10)

sessions/chat/newWidget/newChatWidget/ConnectorRecommendations/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsNarrow/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsOneDismissed/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsTwoDismissed/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsBackground/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsWithNotices/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsShortAfterLayoutToggle/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsFocused/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsPhone/Light
Before After
before after
sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsPhoneWithNotices/Light
Before After
before after

Added (4)

sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsNoUrl/Light

current

sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsDisabled/Light

current

sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsTipsDisabled/Light

current

sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsMultiple/Light

current

Removed (2)

sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsBefore/Light

baseline

sessions/chat/newWidget/newChatWidget/ConnectorRecommendationsFallbackIcons/Light

baseline

roblourens
roblourens previously approved these changes Oct 16, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

URL tokenization produces false recommendations from punctuated paths and exhibits quadratic runtime that can stall typing.

2 open findings
What changed in this PR

Makes connector recommendations contextual to URLs in the Agents window’s new-chat prompt.

Changes:

  • Adds shared hostname matching for eight connector families.
  • Updates card visibility, dismissal focus, and screen-reader announcements.
  • Expands tests and fixtures for URL-triggered recommendations.
File Description
src/​vs/​workbench/​contrib/​chat/​common/​connectorRecommendations.ts Adds URL-to-connector matching.
src/​vs/​sessions/​contrib/​chat/​test/​browser/​sessionsChatAccessibilityHelp.test.ts Updates help-text expectations.
src/​vs/​sessions/​contrib/​chat/​test/​browser/​newChatWidget.fixture.ts Covers contextual recommendation layouts.
src/​vs/​sessions/​contrib/​chat/​test/​browser/​newChatConnectorRecommendations.test.ts Tests matching and visibility.
src/​vs/​sessions/​contrib/​chat/​browser/​sessionsChatAccessibilityHelp.ts Documents URL-triggered cards.
src/​vs/​sessions/​contrib/​chat/​browser/​newChatWidget.ts Connects recommendations to prompt changes.
src/​vs/​sessions/​contrib/​chat/​browser/​newChatInput.ts Exposes input-value change notifications.
src/​vs/​sessions/​contrib/​chat/​browser/​newChatConnectorRecommendations.ts Filters cards and announces new matches.

🧠 Review effort: Balanced


💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

roblourens
roblourens previously approved these changes Oct 16, 2026
roblourens
roblourens previously approved these changes Oct 16, 2026
Detect known connector domains locally in the new-session composer and show only matching available recommendation cards. Preserve accessible announcements, dismissal behavior, and responsive fixture coverage.\n\nFixes #341453\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Preserve static recommendations until they are dismissed, temporarily prioritize URL-matched cards, and track dynamic dismissals independently per connector.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Consume complete URL tokens, avoid nested path false positives, and skip prompt reads while recommendations are disabled. Update the intentional primary Light fixture baseline.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Make screenshot fixtures wait for URL-triggered cards to settle so Linux CI captures complete recommendation and notice stacks.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Restrict URL-driven recommendations to Linear, Notion, Work IQ, Azure Data Explorer, and Sentry while retaining unsupported URLs as negative regression coverage.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Let distro metadata define URL domains and whether each connector appears statically, while preserving existing entries as static by default.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Prevent blocking screenshots from capturing intermediate prompt states before URL-driven recommendation and notice stacks settle.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Adopt the single stable task-led recommendation, muted description-only styling, compact native close action, and connector-specific tooltip from #342181 while preserving URL overrides and separate dismissal state.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Remove static recommendation selection and metadata so the compact recommendation surface appears only when the composer contains a configured connector URL.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Use the concise product field name urls and cover Slack workspace URLs in the connector recommendation regression matrix.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Render URL-matched connectors through the existing tips surface, including optional product icons and navigation across multiple matches. Fix connector marketplace deep links by resolving both stable keys and display names.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Provide the tip-change event required by ChatInputTipPresenter so unrelated inline-chat fixtures continue rendering after contextual tip support.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Accept the reviewed Linux component fixture baselines for connector recommendations rendered through the standard chat tips UI.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep the asynchronous multi-URL recommendation fixture transparent until its final navigable tip state is ready.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Align the focused accessibility help test with the connector-specific wording used by the rebased implementation.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@hawkticehurst
Hawk Ticehurst (hawkticehurst) force-pushed the hawkticehurst/dynamic-connector-recommendations branch from f22bc3d to 84a3f3f Compare October 20, 2026 21:10
@hawkticehurst
Hawk Ticehurst (hawkticehurst) marked this pull request as ready for review October 20, 2026 21:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Chat composer: Dynamically recommend connectors from prompt context

4 participants