* Add per-skill telemetry when skills are loaded into agent context
Add a new 'skillLoadedIntoContext' telemetry event that fires for each
skill loaded into agent context. This captures:
- Skill name
- Skill storage source (local, user, extension, plugin, internal)
- SHA-1 hash of the SKILL.md file content (integrity verification)
The event fires in computeAutomaticInstructions.ts where skills are
filtered and loaded into the chat system prompt, providing per-request
skill usage visibility.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Replace skillVersion/skillAuthor with extensionVersion in skill provenance telemetry
* Add skill telemetry tests for skillLoadedIntoContext events
* Send extensionVersion and pluginVersion as plain text instead of hashed
* Address PR review feedback: use ResourceMap for URI keys, remove skillContentHash, simplify plugin lookup
* Add try/catch for fire-and-forget telemetry, add extension/plugin provenance test
* Clearing out an unused import.
* update, avoid new IAgentSkillProvenance type
* use cheap hash
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Martin Aeschlimann <martinae@microsoft.com>
Remove the ChatAgentVoteDownReason enum and all voteDownReason
references from the model, view model, service, telemetry, and
UI layers. Fix snapshot test ordering to maintain backward compat
for the voteDownReason field position.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
`LocalAgentsSessionsController` is firing updates on every single response change. This PR tries to reduce this by doing a object equality check before firing the update. In a follow up I'll also see if we can debounce listening to so many request updates
* agentPlugins: normalize to user data dir storage
Previously we stored plugins in a very internal way that was inaccessible
by other tooling. This sets up a `agent-plugins` folder beside `extensions`
and creates an `installed.json` which is easy to integrate with.
* comments
* fix compile
---------
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
* feat: add chat.registerCustomizationProvider extension API
Introduces a new proposed extension API (chatCustomizationProvider) that
enables extensions to register as customization providers for the AI
Customization UI. This replaces core-based harness filtering with
extension-driven discovery.
Key changes:
- New proposed API: vscode.proposed.chatCustomizationProvider.d.ts
- ChatCustomizationProvider, ChatCustomizationItem, ChatCustomizationType
- chat.registerCustomizationProvider(id, metadata, provider)
- ExtHost/MainThread RPC bridge for provider registration
- ICustomizationHarnessService extended with registerExternalHarness()
for dynamic harness registration from extensions
- IHarnessDescriptor.itemProvider for extension-driven item discovery
- AICustomizationListWidget falls through to provider when active
harness has an itemProvider
- Unit tests for dynamic harness registration and lifecycle
The static CLI/Claude harness descriptors remain as fallback until
extensions adopt the new API.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: address code review issues
- Register chatCustomizationProvider in extensionsApiProposals.ts
- Fix duplicate 'descriptor' variable in fetchItemsForSection
- Add missing IExternalCustomizationItemProvider import
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: make management editor reactive to dynamic harness registration
- Track availableHarnesses in autorun (not just activeHarness)
- Add ensureHarnessDropdown() to lazily create/remove the dropdown
when harnesses are dynamically registered/unregistered
- Store sidebarContent and harnessDropdownContainer refs for
dynamic dropdown management
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* refactor: address API review feedback for ChatCustomizationProvider
- Replace ChatCustomizationType enum with TaskGroup-style class pattern
(static instances with string-backed ids, extensible via constructor)
- Rename provideCustomizations → provideChatCustomizations to match
VS Code provider naming conventions
- Add comprehensive JSDoc explaining customization lifecycle and
caching semantics (cached until onDidChange fires)
- Simplify type converter to use class id directly
- Bump proposal version to 2
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: quality improvements for ChatCustomizationProvider plumbing
- Skip storage-based grouping for provider-backed items in the
customization list widget. External providers manage their own
items, so Workspace/User/Extension categories don't apply —
render a flat sorted list instead.
- Use AICustomizationManagementSection constants instead of
hardcoded string literals in hiddenSections mapping.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* refactor: make storage optional on IAICustomizationListItem
External provider items don't have a storage origin — the provider
manages discovery, so Workspace/User/Extension categories don't
apply. Make the storage field optional:
- Provider items omit storage entirely (no fake PromptsStorage.local)
- Context key overlay only sets storage key when present
- Management editor falls back gracefully for provider items
- Debug panel accepts optional storage
- Built-in path (promptsService) is unchanged — items always have storage
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* feat: include external provider data in customization debug report
When the active harness has an external provider, the debug report
now shows the provider's raw items grouped by type, with name, URI,
and description for each item, plus a count of items matching the
current section. The promptsService stages are skipped since they
don't apply to provider-backed harnesses.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* refactor: rename ChatCustomization → ChatSessionCustomization per API review
Renames all types, methods, events, DTOs, and the proposal file to use
the ChatSession prefix as requested in API review feedback.
- ChatCustomizationType → ChatSessionCustomizationType
- ChatCustomizationItem → ChatSessionCustomizationItem
- ChatCustomizationProvider → ChatSessionCustomizationProvider
- provideChatCustomizations → provideChatSessionCustomizations
- onDidChangeChatCustomizations → onDidChangeChatSessionCustomizations
- registerCustomizationProvider → registerChatSessionCustomizationProvider
- Proposal: chatCustomizationProvider → chatSessionCustomizationProvider
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: resolve rebase conflicts and remove old ChatSessionCustomizations API
Remove the old group-based ChatSessionCustomizations API from the merged
PR #304532, which is superseded by our new ChatSessionCustomizationProvider
API. The old API used groups, storageLocation, and commands on the
chatSessionsService path; the new API uses a flat item model on the
customizationHarnessService path.
Removed:
- IChatSessionCustomizationItem/Group DTOs from extHost.protocol.ts
- registerChatSessionCustomizationsProvider from extHostChatSessions.ts,
mainThreadChatSessions.ts, extHost.api.impl.ts, chatSessionsProvider.d.ts
- ChatSessionCustomizations converter namespace from extHostTypeConverters.ts
- mapProviderItemToListItem and old group command fields from list widget
Fixed:
- registerContributedHarness → registerExternalHarness in fixtures and
mainThreadChatSessions.ts
- Missing AGENT_MD_FILENAME import in customizationHarnessService.ts
- Constructor arg mismatch in browser customizationHarnessService.ts
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: remove version number from new chatSessionCustomizationProvider proposal
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: rename id → chatSessionType in registerChatSessionCustomizationProvider
Aligns the parameter name with the chatSessions API convention.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* feat: add AICustomizationManagementCreateMenuId for extension create actions
Extensions can now contribute create/add button actions to the
customizations management editor via contributes.menus targeting
'AICustomizationManagementCreate'. Use the aiCustomizationManagementSection
context key to scope commands to specific sections (agents, skills, etc.).
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: register chat/customizations/create as extension menu contribution point
Extensions contribute to 'chat/customizations/create' in package.json
contributes.menus, gated by chatSessionCustomizationProvider proposal.
Uses MenuId.for() to avoid cross-layer import.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* feat: scope create menu to active harness, replace built-in actions
Add aiCustomizationManagementHarness context key set to the active
harness ID. Extensions scope create menu contributions using
'when: aiCustomizationManagementHarness == myHarness'.
When a harness has menu-contributed create actions, they fully replace
the built-in create buttons for that section.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: address code review feedback
- Provider items without storage are now read-only (not editable/deletable)
- Wrap provideChatSessionCustomizations in try/catch to handle extension errors
- Use menuItem.run() instead of commandService.executeCommand for menu actions
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: gate customization provider registration on kill-switch setting
Registration is now blocked when chat.customizations.providerApi.enabled
is false (default), preventing providers from affecting the UI.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add 7 new tests covering multi-client scenarios:
- sessionAdded/sessionRemoved notifications broadcast to all clients
- Cross-client message dispatch (client B sends on client A's session)
- Full tool progress updates delivered to both subscribers
- Action scoping: unsubscribed client gets no actions but still gets notifications
- Late subscriber gets current state via snapshot
- Cross-client permission flow (client B confirms tool started by client A)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* feat: add full reference name support for language model tools and related API updates
* Updates
* Updates
* Updates
* Updates
* Bump version number
* Updates
* Udpates
---------
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
* sessions: convert built-in prompts to skills and add UI Integration badge
- Move all 6 built-in prompts from vs/sessions/prompts/ to
vs/sessions/skills/{name}/SKILL.md with proper frontmatter
- Remove the built-in prompt discovery system (discoverBuiltinPrompts,
getBuiltinPromptFiles, BUILTIN_PROMPTS_URI) from AgenticPromptsService
- Simplify listPromptFiles/listPromptFilesForStorage to only handle
skills as the built-in type
- Add getSkillUIIntegrations() to IAICustomizationWorkspaceService
interface, returning a map of skill names with UI surface connections
- Sessions implementation maps act-on-feedback (Submit Feedback button)
and generate-run-commands (Run button) to tooltips
- Show 'UI Integration' badge in the customizations editor for skills
that drive UI surfaces, including user overrides of those skills
- Update AI_CUSTOMIZATIONS.md to reflect the simplified architecture
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* address review feedback: stable folder-name lookup, safe builtin fallback, shared empty map
- Use basename(dirname(skill.uri)) instead of skill.name for UI
integration lookup so badge persists even if frontmatter name changes
- Return [] for BUILTIN_STORAGE on non-skill types instead of
delegating to super (which would throw)
- Use a shared static empty map in the core VS Code implementation to
avoid repeated allocations
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* add built-in skills with UI integration badges for sessions
* add missing UI Integration mappings for all toolbar-connected skills
Add create-pr, create-draft-pr, update-pr, merge-changes, and commit
to the skill UI integrations map. These are all triggered by buttons
in the Changes toolbar.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Reconnect to in-progress remote agent host chat sessions
When opening a remote agent host session that has an active (in-progress)
turn, the chat UI now reconnects to it and streams ongoing progress
instead of only showing completed turns as history.
Key changes:
- activeTurnToProgress() converts accumulated active turn state into
IChatProgress[] for initial replay
- provideChatSessionContent detects activeTurn on session state, includes
it in history, and wires up live streaming via progressObs
- _reconnectToActiveTurn(): streams incremental text/reasoning/tool
call/permission updates, handles turn completion, dispatches
turnCancelled on interrupt, resolves pending permissions interactively
- Fixes live object identity (reuses ChatToolInvocation instances from
initial progress), snapshot-to-listener race (immediate reconciliation),
and proper cancellation dispatch
(Written by Copilot)
* Address Copilot review: fix empty initialProgress guard and handle completed tool calls between snapshots
(Written by Copilot)
* Fix test failures: add partId to delta action, add _meta.toolKind for terminal tool
---------
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Raymond Zhao <7199958+rzhao271@users.noreply.github.com>
* Enhance AI Customization Management Editor with confirmation handling and dirty state tracking
* Improve dialog handling by waiting for keyboard events to propagate before opening confirmation
* Refactor AI Customization Management Editor to replace confirmation handling with save handling
* Add escape key handling to close dialog only if previously pressed
* Address review: guard save() against auto-save, reset editor dirty baseline
- Only run the pick-target save flow on explicit saves (not auto-save
from focus/window changes)
- Reset _editorContentChanged after successful save so the embedded
editor stays clean until the next edit (updateEditorActionButton
propagates this to input.setDirty via updateInputDirtyState)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>