Enhance agent features and improve clientIO functionality#2631
Open
robgruen wants to merge 48 commits into
Open
Enhance agent features and improve clientIO functionality#2631robgruen wants to merge 48 commits into
robgruen wants to merge 48 commits into
Conversation
can now supply --dev on agent server start record translation and history data when dev mode is on
@config dev on so that you can do action confirmation and translation recording independently
…mic + file buttons to chat input box (TODO: verify npm registryt 401 flakiness)
Contributor
There was a problem hiding this comment.
Pull request overview
This PR expands TypeAgent’s end-to-end “client ↔ dispatcher ↔ agent-server ↔ agents ↔ autoShell” capabilities by restoring missing chat-ui features (attachments, speech, interactions, history separation, dynamic displays, feedback/delete affordances, pre-init send queue) and adding a new Windows Service control action (restart service) with matching + elevation flows and tests.
Changes:
- Added Windows service restart support (schema + desktop agent logic + new autoShell service-control implementation + handler registration + .NET tests).
- Restored/implemented missing VS Code shell clientIO/webview bridging features: attachments, Azure Speech mic, dynamic displays, server-driven interactions/choices, user feedback syncing, developer-mode delete UI, and queuing sends while the dispatcher/session initializes.
- Added developer-mode translation capture plumbing (DevTrace) and a new internal npm registry bootstrap script (
getNPMRC).
Show a summary per file
| File | Description |
|---|---|
| ts/tools/scripts/getNPMRC.mjs | New script to pull/push repo .npmrc from Key Vault and set pnpm tokenHelper auth. |
| ts/tools/scripts/getNPMRC.config.json | Vault/secret/path configuration for getNPMRC. |
| ts/pnpm-workspace.yaml | Adds more onlyBuiltDependencies entries for pnpm builds. |
| ts/packages/vscode-shell/src/webview/vscode-theme.css | VS Code shell theme overlay tweaks (agent icon styling). |
| ts/packages/vscode-shell/src/webview/main.ts | Webview wiring for attachments, speech token flow, interactions, dynamic displays, feedback, and history separator. |
| ts/packages/vscode-shell/src/webview/azureSpeechProvider.ts | Azure Speech-backed SpeechInputProvider for VS Code webview. |
| ts/packages/vscode-shell/src/bridge/messages.ts | Expands bridge message contracts (attachments, choices, interactions, feedback, speech token). |
| ts/packages/vscode-shell/src/bridge/clientIO.ts | Implements previously-no-op ClientIO methods by forwarding to webview (choices/interactions/dynamic display/feedback/dev mode). |
| ts/packages/vscode-shell/src/agentServerBridge.ts | Queues sends until session is ready; adds developer-mode hydration; bridges new messages (choice/interaction/feedback/speech token/dynamic display). |
| ts/packages/vscode-shell/package.json | Adds Speech SDK dependency for VS Code shell webview. |
| ts/packages/shell/src/renderer/src/chatPanelBridge.ts | Aligns Electron shell behavior: history separator label import, pre-init send queue, dev-mode delete hook, dev-mode seeding. |
| ts/packages/dispatcher/types/src/dispatcher.ts | Adds getDeveloperMode() to Dispatcher interface. |
| ts/packages/dispatcher/rpc/test/dispatcherRpc.spec.ts | Updates stub dispatcher for new getDeveloperMode() method. |
| ts/packages/dispatcher/rpc/src/dispatcherTypes.ts | Adds RPC surface for getDeveloperMode. |
| ts/packages/dispatcher/rpc/src/dispatcherServer.ts | Implements getDeveloperMode RPC endpoint. |
| ts/packages/dispatcher/rpc/src/dispatcherClient.ts | Adds getDeveloperMode RPC client method. |
| ts/packages/dispatcher/dispatcher/test/confirmTranslation.spec.ts | Ensures confirm prompt is gated by confirmActions (not developerMode). |
| ts/packages/dispatcher/dispatcher/test/chainedChoice.spec.ts | Regression test: choice callback returning a new pending choice must render the second card. |
| ts/packages/dispatcher/dispatcher/src/translation/interpretRequest.ts | Adds DevTrace begin + translation capture persistence. |
| ts/packages/dispatcher/dispatcher/src/translation/confirmTranslation.ts | Changes confirmation gating to confirmActions instead of developerMode. |
| ts/packages/dispatcher/dispatcher/src/dispatcher.ts | Uses emitActionResult for choice callback results (enables chained pendingChoice rendering); adds getDeveloperMode. |
| ts/packages/dispatcher/dispatcher/src/context/system/handlers/configCommandHandlers.ts | Implements @config dev on [--confirm] and @config dev off + client notifications. |
| ts/packages/dispatcher/dispatcher/src/context/devTrace.ts | New DevTrace capture implementation writing dev-captures/translate-*.json. |
| ts/packages/dispatcher/dispatcher/src/context/commandHandlerContext.ts | Adds confirmActions, devTrace, dispatcher option developerMode, and hooks prompt logging to DevTrace. |
| ts/packages/chat-ui/test/chatPanel.spec.ts | Updates tests for removal of feedback “trash/hide” hook from ChatPanel. |
| ts/packages/chat-ui/styles/chat.css | Adds styling for developer-mode per-message delete split button and menu. |
| ts/packages/chat-ui/src/webSpeechProvider.ts | New default Web Speech API provider for browser hosts when no host speech provider is injected. |
| ts/packages/chat-ui/src/index.ts | Exports formatHistorySeparatorLabel. |
| ts/packages/chat-ui/src/icons.ts | Adds chevron-down icon for split-button menu. |
| ts/packages/chat-ui/src/feedbackWidget.ts | Removes the old trash/hide affordance from feedback widget. |
| ts/packages/chat-ui/src/deleteControl.ts | New developer-mode delete split-button + menu implementation. |
| ts/packages/chat-ui/src/chatPanel.ts | Restores attach button w/ web-native picker, default speech provider, developer-mode delete affordance, and exports history separator label helper. |
| ts/packages/agentServer/server/src/speechToken.ts | Implements server-side Azure Speech token vending w/ caching. |
| ts/packages/agentServer/server/src/server.ts | Adds --dev startup option to enable developer mode by default. |
| ts/packages/agentServer/server/src/connectionHandler.ts | Exposes getSpeechToken on the agent-server RPC surface. |
| ts/packages/agentServer/server/package.json | Adds start:dev script to start server with --dev. |
| ts/packages/agentServer/protocol/src/protocol.ts | Adds SpeechToken type + getSpeechToken() RPC in protocol. |
| ts/packages/agentServer/protocol/src/index.ts | Exports SpeechToken. |
| ts/packages/agentServer/client/test/conversation-stubConnection.ts | Updates stub connection with getSpeechToken. |
| ts/packages/agentServer/client/src/index.ts | Re-exports SpeechToken type from protocol. |
| ts/packages/agentServer/client/src/agentServerClient.ts | Adds getSpeechToken() client method. |
| ts/packages/agents/github-cli/test/githubCliBuildArgs.spec.ts | Adds tests for mapping “unassigned” assignee requests to --search no:assignee. |
| ts/packages/agents/github-cli/src/github-cliSchema.ts | Documents assignee option for issue/pr list actions. |
| ts/packages/agents/github-cli/src/github-cliSchema.agr | Adds grammar for “unassigned issues …” mapping to assignee: "none". |
| ts/packages/agents/github-cli/src/github-cliActionHandler.ts | Implements unassigned assignee sentinel mapping and exports buildArgs for tests. |
| ts/packages/agents/desktop/src/desktopSchema.agr | Adds new service control grammar rules mapping to RestartService. |
| ts/packages/agents/desktop/src/actionsSchema.ts | Adds RestartService action schema + parameters (matchBy/elevate). |
| ts/packages/agents/desktop/src/actionHandler.ts | Adds choice-based confirmation + elevation flows for service restart results from autoShell. |
| ts/packages/agents/browser/src/extension/serviceWorker/dispatcherConnection.ts | Adds getSpeechToken to browser extension’s agent-server adapter. |
| ts/package.json | Adds getNPMRC and start:agent-server:dev scripts; updates onlyBuiltDependencies. |
| ts/.vscode/tasks.json | Adds task for installing the VS Code chat extension locally. |
| ts/.vscode/settings.json | Improves watcher/search excludes; sets a server start command. |
| ts/.vscode/extensions.json | Recommends the typeagent.vscode-chat extension. |
| ts/.gitignore | Ignores root /.npmrc and config.local.yaml.bak. |
| dotnet/autoShell/Services/WindowsServiceControlService.cs | Implements service enumeration/matching + restart, with elevation fallback. |
| dotnet/autoShell/Services/ServiceMatcher.cs | Pure matching logic (exact/fuzzy, description coverage) for services. |
| dotnet/autoShell/Services/IServiceControlService.cs | Defines service control abstraction and result contract. |
| dotnet/autoShell/Handlers/ServiceActionHandler.cs | Adds RestartService action handler returning confirm/elevation payloads. |
| dotnet/autoShell/autoShell.csproj | Adds ServiceController package dependency. |
| dotnet/autoShell.Tests/ServiceMatcherTests.cs | Unit tests for ServiceMatcher exact/fuzzy/description matching behavior. |
| dotnet/autoShell.Tests/ServiceActionHandlerTests.cs | Unit tests for handler behavior incl. confirm/elevation payloads. |
| dotnet/autoShell.Tests/HandlerRegistrationTests.cs | Registers new handler in test handler set. |
| dotnet/autoShell.Tests/ActionDispatcherIntegrationTests.cs | Updates dispatcher construction for new service-control dependency. |
| dotnet/autoShell/ActionDispatcher.cs | Wires WindowsServiceControlService + ServiceActionHandler into dispatcher creation. |
Review details
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 64/65 changed files
- Comments generated: 5
- Review effort level: Low
curtisman
reviewed
Jul 9, 2026
curtisman
reviewed
Jul 9, 2026
curtisman
approved these changes
Jul 9, 2026
…method call' Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Collaborator
Author
|
Any objection to me using the same approach as eslint by using suppression comments?
________________________________
From: Robert Gruen ***@***.***>
Sent: Thursday, July 9, 2026 8:18 AM
To: microsoft/TypeAgent ***@***.***>; microsoft/TypeAgent ***@***.***>
Cc: Author ***@***.***>
Subject: Re: [microsoft/TypeAgent] Enhance agent features and improve clientIO functionality (PR #2631)
Yeah, I've already encountered that. I'll need to come up with a better way to do this.
Get Outlook for Android<https://aka.ms/AAb9ysg>
________________________________
From: Curtis Man ***@***.***>
Sent: Thursday, 09 July 2026 08:07:55
To: microsoft/TypeAgent ***@***.***>
Cc: Robert Gruen ***@***.***>; Author ***@***.***>
Subject: Re: [microsoft/TypeAgent] Enhance agent features and improve clientIO functionality (PR #2631)
@curtisman commented on this pull request.
________________________________
In ts/tools/scripts/code/complexity-baseline-exception.json<#2631?email_source=notifications&email_token=AGBS6WOAFJAM3Y7GUBPBQGT5D6YMXA5CNFSNUABKM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UKJSXM2LFO4XTINRWGQZDINZUHE32M4TFMFZW63VGMF2XI2DPOKSWK5TFNZ2K64DSL5ZGK5TJMV3V6Y3MNFRWW#discussion_r3552682352>:
@@ -17,7 +17,7 @@
"exceptions": [
Not for this PR, but the content of this file is going to be so noisy with the line number.
—
Reply to this email directly, view it on GitHub<#2631?email_source=notifications&email_token=AGBS6WLZUPXU7G4JMW2F77L5D6YMXA5CNFSNUABKM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UKJSXM2LFO4XTINRWGQZDINZUHE32M4TFMFZW63VGMF2XI2DPOKSWK5TFNZ2L24DSL5ZGK5TJMV3V63TPORUWM2LDMF2GS33OONPWG3DJMNVQ#pullrequestreview-4664247497>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AGBS6WO6AM6FMA4I2I6UATD5D6YMXAVCNFSNUABFKJSXA33TNF2G64TZHM4DEOJVGUZTQOJSHNEXG43VMU5TIOBUGI2DSOJTGMZ2C5QC>.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS<https://github.com/notifications/mobile/ios/AGBS6WKHWJPSDHOOG23MZLD5D6YMXA5CNFSNUABKM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UKJSXM2LFO4XTINRWGQZDINZUHE32M4TFMFZW63VGMF2XI2DPOKSWK5TFNZ2KUZTPN52GK4S7NFXXG> and Android<https://github.com/notifications/mobile/android/AGBS6WOPTXH4D7HFBQDMK335D6YMXA5CNFSNUABKM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UKJSXM2LFO4XTINRWGQZDINZUHE32M4TFMFZW63VGMF2XI2DPOKSWK5TFNZ2K4ZTPN52GK4S7MFXGI4TPNFSA>. Download it today!
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
…, webview templateServices, and promptLogger override
Member
|
Sure |
You're not authorized to push to this branch. Visit "About protected branches" for more information.
You're not authorized to push to this branch. Visit "About protected branches" for more information.
You're not authorized to push to this branch. Visit "About protected branches" for more information.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a new
ServiceActionHandlerfor Windows service control commands, adds comprehensive unit tests for service-related features, and integrates the service control functionality into the action dispatcher and handler registration. The main changes establish the ability to handle service restart actions, including scenarios for fuzzy matching, elevation, and user confirmation, with full test coverage.Added missing functionality from previous chat-ui refactor
New Service Control Handler and Integration:
ServiceActionHandlerto handle Windows service control actions (e.g.,RestartService), including logic for fuzzy matching, elevation, and user confirmation. (dotnet/autoShell/Handlers/ServiceActionHandler.cs)ServiceActionHandlerin the action dispatcher factory and handler registration, and updated dispatcher and test constructors to include the newIServiceControlServicedependency. (dotnet/autoShell/ActionDispatcher.cs,dotnet/autoShell.Tests/HandlerRegistrationTests.cs,dotnet/autoShell.Tests/ActionDispatcherIntegrationTests.cs) [1] [2] [3] [4] [5] [6] [7]Unit Tests for Service Control:
ServiceActionHandlerTeststo validate all major behaviors of the new handler, including matching by name/description, handling fuzzy matches, elevation, error cases, and confirmation payloads. (dotnet/autoShell.Tests/ServiceActionHandlerTests.cs)ServiceMatcherTeststo thoroughly test the service matching logic for various scenarios (exact, fuzzy, description-based, and fallback cases). (dotnet/autoShell.Tests/ServiceMatcherTests.cs)