Skip to content

speech: expose voice chat state changes to extensions#286726

Open
fabienbouchez wants to merge 3 commits intomicrosoft:mainfrom
fabienbouchez:feature/speech-voice-chat-event
Open

speech: expose voice chat state changes to extensions#286726
fabienbouchez wants to merge 3 commits intomicrosoft:mainfrom
fabienbouchez:feature/speech-voice-chat-event

Conversation

@fabienbouchez
Copy link
Copy Markdown

@fabienbouchez fabienbouchez commented Jan 9, 2026

Add onDidChangeVoiceChatInProgress event to the speech API to allow extensions to react when voice chat sessions start or stop.

This enables extensions for example to :

  • Automatically adjust system audio during voice chat
  • Show UI indicators for active voice input
  • Adapt behavior during voice interaction

The implementation listens to the voiceChatInProgress context key and propagates changes to extensions via an Event.

Add onDidChangeVoiceChatInProgress event to the speech API to allow
extensions to react when voice chat sessions start or stop.

This enables extensions to:
- Automatically adjust system audio during voice chat
- Disable interfering keyboard shortcuts
- Show UI indicators for active voice input
- Adapt behavior during voice interaction

The implementation listens to the voiceChatInProgress context key
and propagates changes to extensions via an Event<boolean>.

Fixes: #<issue_number_if_any>
Copilot AI review requested due to automatic review settings January 9, 2026 11:41
@fabienbouchez
Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

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 exposes voice chat state changes to extensions by adding an onDidChangeVoiceChatInProgress event to the speech API. This enables extensions to react when voice chat sessions start or stop, allowing them to automatically adjust system audio, disable interfering shortcuts, show UI indicators, or adapt behavior during voice interaction.

Key Changes:

  • Added onDidChangeVoiceChatInProgress event to the proposed speech API
  • Implemented event propagation from main thread to extension host via context key listener
  • Exposed the event through the extension API with proper proposal guard

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/vscode-dts/vscode.proposed.speech.d.ts Adds API definition for onDidChangeVoiceChatInProgress event
src/vs/workbench/api/common/extHostSpeech.ts Implements Emitter and event exposure in extension host
src/vs/workbench/api/common/extHost.protocol.ts Adds protocol method for voice chat state change notifications
src/vs/workbench/api/common/extHost.api.impl.ts Exposes event to extensions with proposal API guard
src/vs/workbench/api/browser/mainThreadSpeech.ts Listens to context key changes and notifies extensions

@meganrogge meganrogge assigned bpasero and unassigned meganrogge Jan 9, 2026
@bpasero bpasero added this to the Backlog milestone Feb 8, 2026
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