@codingame/monaco-vscode-chat-service-override 34.1.3 → 35.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (427) hide show
  1. package/index.js +38 -0
  2. package/package.json +5 -5
  3. package/vscode/src/vs/platform/agentHost/browser/agentHost.config.contribution.d.ts +1 -0
  4. package/vscode/src/vs/platform/agentHost/browser/agentHost.config.contribution.js +40 -0
  5. package/vscode/src/vs/platform/agentHost/browser/agentHostConnectionsService.d.ts +27 -0
  6. package/vscode/src/vs/platform/agentHost/browser/agentHostConnectionsService.js +91 -0
  7. package/vscode/src/vs/platform/agentHost/browser/remoteAgentHostProtocolClient.d.ts +20 -4
  8. package/vscode/src/vs/platform/agentHost/browser/remoteAgentHostProtocolClient.js +148 -15
  9. package/vscode/src/vs/platform/agentHost/browser/remoteAgentHostServiceImpl.d.ts +1 -0
  10. package/vscode/src/vs/platform/agentHost/browser/remoteAgentHostServiceImpl.js +9 -1
  11. package/vscode/src/vs/platform/agentHost/common/agentHost.config.contribution.js +57 -3
  12. package/vscode/src/vs/platform/agentHost/common/agentHostFileSystemProvider.d.ts +10 -14
  13. package/vscode/src/vs/platform/agentHost/common/agentHostFileSystemProvider.js +29 -8
  14. package/vscode/src/vs/platform/agentHost/common/agentHostSchema.d.ts +109 -2
  15. package/vscode/src/vs/platform/agentHost/common/agentHostSchema.js +207 -21
  16. package/vscode/src/vs/platform/agentHost/common/agentHostStarter.config.contribution.js +362 -37
  17. package/vscode/src/vs/platform/agentHost/common/agentService.d.ts +698 -91
  18. package/vscode/src/vs/platform/agentHost/common/agentService.js +46 -3
  19. package/vscode/src/vs/platform/agentHost/common/customAgents.js +1 -0
  20. package/vscode/src/vs/platform/agentHost/common/resourceReadLogging.d.ts +1 -0
  21. package/vscode/src/vs/platform/agentHost/common/resourceReadLogging.js +26 -0
  22. package/vscode/src/vs/platform/agentHost/common/sandboxConfigSchema.d.ts +5 -5
  23. package/vscode/src/vs/platform/agentHost/common/sandboxConfigSchema.js +17 -17
  24. package/vscode/src/vs/platform/agentHost/common/state/agentSubscription.d.ts +96 -12
  25. package/vscode/src/vs/platform/agentHost/common/state/agentSubscription.js +226 -19
  26. package/vscode/src/vs/platform/agentHost/common/state/protocol/channels-annotations/reducer.d.ts +18 -0
  27. package/vscode/src/vs/platform/agentHost/common/state/protocol/channels-annotations/reducer.js +89 -0
  28. package/vscode/src/vs/platform/agentHost/common/state/protocol/channels-changeset/reducer.js +10 -0
  29. package/vscode/src/vs/platform/agentHost/common/state/protocol/channels-chat/reducer.d.ts +6 -0
  30. package/vscode/src/vs/platform/agentHost/common/state/protocol/channels-chat/reducer.js +400 -0
  31. package/vscode/src/vs/platform/agentHost/common/state/protocol/channels-session/reducer.js +129 -446
  32. package/vscode/src/vs/platform/agentHost/common/state/protocol/common/reducer-helpers.d.ts +2 -2
  33. package/vscode/src/vs/platform/agentHost/common/state/protocol/version/registry.d.ts +1 -1
  34. package/vscode/src/vs/platform/agentHost/common/state/protocol/version/registry.js +1 -1
  35. package/vscode/src/vs/platform/agentHost/common/state/sessionActions.d.ts +35 -25
  36. package/vscode/src/vs/platform/agentHost/common/state/sessionActions.js +7 -1
  37. package/vscode/src/vs/{workbench/contrib → platform}/browserView/common/browserChatToolReferenceNames.d.ts +4 -0
  38. package/vscode/src/vs/platform/networkFilter/common/networkFilterService.js +1 -1
  39. package/vscode/src/vs/platform/sandbox/browser/sandboxHelperService.js +1 -0
  40. package/vscode/src/vs/platform/sandbox/common/terminalSandboxCommandRules.d.ts +0 -6
  41. package/vscode/src/vs/platform/sandbox/common/terminalSandboxCommandRules.js +5 -18
  42. package/vscode/src/vs/platform/sandbox/common/terminalSandboxEngine.d.ts +52 -3
  43. package/vscode/src/vs/platform/sandbox/common/terminalSandboxEngine.js +212 -34
  44. package/vscode/src/vs/platform/sandbox/common/terminalSandboxReadAllowList.js +3 -4
  45. package/vscode/src/vs/platform/sandbox/common/terminalSandboxRuntimeConfigurationPerOperation.js +11 -10
  46. package/vscode/src/vs/platform/sandbox/common/terminalSandboxService.d.ts +13 -6
  47. package/vscode/src/vs/platform/sandbox/common/terminalSandboxService.js +6 -1
  48. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoice.contribution.d.ts +2 -0
  49. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoice.contribution.js +399 -0
  50. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoiceSessionsPicker.d.ts +20 -0
  51. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoiceSessionsPicker.js +85 -0
  52. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoiceWidget.d.ts +177 -0
  53. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoiceWidget.js +898 -0
  54. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoiceWidgetBinding.d.ts +24 -0
  55. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoiceWidgetBinding.js +204 -0
  56. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoiceWindowService.d.ts +61 -0
  57. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/agentsVoiceWindowService.js +338 -0
  58. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/confirmationComponent.d.ts +10 -0
  59. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/confirmationComponent.js +57 -0
  60. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/feedbackDialog.d.ts +33 -0
  61. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/feedbackDialog.js +98 -0
  62. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/headerComponent.d.ts +30 -0
  63. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/headerComponent.js +149 -0
  64. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/onboardingComponent.d.ts +12 -0
  65. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/onboardingComponent.js +116 -0
  66. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/sessionListComponent.d.ts +32 -0
  67. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/sessionListComponent.js +226 -0
  68. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/statusRowsComponent.d.ts +18 -0
  69. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/statusRowsComponent.js +138 -0
  70. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/tokens.d.ts +26 -0
  71. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/tokens.js +25 -0
  72. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/transcriptComponent.d.ts +13 -0
  73. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/transcriptComponent.js +108 -0
  74. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/voiceBarComponent.d.ts +13 -0
  75. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/components/voiceBarComponent.js +63 -0
  76. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/transcriptsView/voiceTranscripts.contribution.d.ts +1 -0
  77. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/transcriptsView/voiceTranscripts.contribution.js +178 -0
  78. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/transcriptsView/voiceTranscriptsView.d.ts +47 -0
  79. package/vscode/src/vs/workbench/contrib/agentsVoice/browser/transcriptsView/voiceTranscriptsView.js +322 -0
  80. package/vscode/src/vs/workbench/contrib/agentsVoice/common/agentsVoice.d.ts +15 -0
  81. package/vscode/src/vs/workbench/contrib/agentsVoice/common/agentsVoice.js +15 -0
  82. package/vscode/src/vs/workbench/contrib/agentsVoice/common/agentsVoiceColors.d.ts +2 -0
  83. package/vscode/src/vs/workbench/contrib/agentsVoice/common/agentsVoiceColors.js +26 -0
  84. package/vscode/src/vs/workbench/contrib/agentsVoice/common/voiceTranscriptStore.d.ts +132 -0
  85. package/vscode/src/vs/workbench/contrib/agentsVoice/common/voiceTranscriptStore.js +237 -0
  86. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityService.js +2 -2
  87. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatResponseAccessibleView.d.ts +2 -2
  88. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatResponseAccessibleView.js +32 -16
  89. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityActions.js +8 -8
  90. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.d.ts +1 -1
  91. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.js +71 -60
  92. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.js +1 -1
  93. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatClear.js +6 -1
  94. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCodeblockActions.js +15 -15
  95. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContextActions.js +8 -8
  96. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.js +7 -7
  97. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.js +19 -24
  98. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatFileTreeActions.js +2 -2
  99. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatForkActions.d.ts +9 -0
  100. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatForkActions.js +14 -5
  101. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatImportExport.js +3 -3
  102. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatLanguageModelActions.js +13 -13
  103. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatMoveActions.js +6 -6
  104. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatNewActions.js +14 -14
  105. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatOpenAgentDebugPanelAction.js +13 -13
  106. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPluginActions.js +66 -52
  107. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPromptNavigationActions.js +2 -2
  108. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQueueActions.js +15 -36
  109. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +8 -8
  110. package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.js +19 -19
  111. package/vscode/src/vs/workbench/contrib/chat/browser/actions/createPluginAction.js +20 -20
  112. package/vscode/src/vs/workbench/contrib/chat/browser/actions/exportAgentHostDebugLogsAction.d.ts +1 -1
  113. package/vscode/src/vs/workbench/contrib/chat/browser/actions/exportAgentHostDebugLogsAction.js +128 -13
  114. package/vscode/src/vs/workbench/contrib/chat/browser/actions/openCopilotCliStateFileAction.js +6 -6
  115. package/vscode/src/vs/workbench/contrib/chat/browser/actions/reviewEdits.js +1 -1
  116. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginActions.js +10 -10
  117. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginEditor/agentPluginEditor.js +2 -2
  118. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginEditor/agentPluginEditorInput.js +2 -2
  119. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginRepositoryService.d.ts +1 -0
  120. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginRepositoryService.js +58 -9
  121. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginsView.js +13 -13
  122. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostActiveClientService.d.ts +15 -3
  123. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostActiveClientService.js +64 -17
  124. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostCustomizationService.d.ts +45 -1
  125. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostCustomizationService.js +15 -0
  126. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostLocalCustomizations.d.ts +25 -5
  127. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostLocalCustomizations.js +143 -20
  128. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostModeSynchronizer.js +7 -31
  129. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostNewSessionFolderService.d.ts +23 -0
  130. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostNewSessionFolderService.js +52 -0
  131. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostPermissionUiContribution.js +5 -5
  132. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostToolSetEnablementService.d.ts +47 -0
  133. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostToolSetEnablementService.js +163 -0
  134. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostUntitledProvisionalSessionService.d.ts +26 -3
  135. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostUntitledProvisionalSessionService.js +106 -8
  136. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/syncedCustomizationBundler.d.ts +16 -3
  137. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/syncedCustomizationBundler.js +44 -14
  138. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js +3 -3
  139. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.js +70 -59
  140. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.js +5 -5
  141. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.js +1 -1
  142. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjection.js +1 -1
  143. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionActions.js +4 -4
  144. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionService.js +1 -1
  145. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionsExperiments.contribution.js +4 -4
  146. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentTitleBarStatusWidget.js +22 -22
  147. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccess.js +17 -17
  148. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccessActions.js +4 -4
  149. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentDisabledInputTipContribution.d.ts +27 -0
  150. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentDisabledInputTipContribution.js +152 -0
  151. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsController.js +11 -5
  152. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationDebugPanel.d.ts +1 -1
  153. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationDebugPanel.js +9 -36
  154. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationIcons.d.ts +8 -0
  155. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationIcons.js +17 -15
  156. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationItemSource.d.ts +143 -0
  157. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationItemSource.js +30 -0
  158. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationItemsModel.d.ts +6 -3
  159. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationItemsModel.js +3 -1
  160. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidget.d.ts +1 -3
  161. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidget.js +107 -126
  162. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.contribution.js +46 -46
  163. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditor.d.ts +19 -22
  164. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditor.js +244 -190
  165. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditorInput.d.ts +2 -0
  166. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditorInput.js +13 -1
  167. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWelcomePage.d.ts +3 -1
  168. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWelcomePage.js +7 -2
  169. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWelcomePagePromptLaunchers.d.ts +5 -1
  170. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWelcomePagePromptLaunchers.js +47 -28
  171. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWorkspaceService.d.ts +2 -5
  172. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWorkspaceService.js +4 -8
  173. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/automationsListWidget.d.ts +87 -0
  174. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/automationsListWidget.js +772 -0
  175. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationCreatorService.d.ts +24 -8
  176. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationCreatorService.js +3 -8
  177. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationHarnessService.js +1 -7
  178. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/embeddedAgentPluginDetail.js +2 -2
  179. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/embeddedExtensionToolsDetail.d.ts +42 -0
  180. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/embeddedExtensionToolsDetail.js +130 -0
  181. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/embeddedMcpServerDetail.js +3 -3
  182. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/galleryItemRenderer.d.ts +46 -0
  183. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/galleryItemRenderer.js +94 -0
  184. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/mcpListWidget.d.ts +9 -1
  185. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/mcpListWidget.js +421 -201
  186. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/media/aiCustomizationManagement.css +1426 -97
  187. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/media/aiCustomizationWelcomePromptLaunchers.css +1 -1
  188. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/pluginListWidget.d.ts +1 -0
  189. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/pluginListWidget.js +107 -127
  190. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/promptsServiceCustomizationItemProvider.d.ts +29 -0
  191. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/promptsServiceCustomizationItemProvider.js +331 -0
  192. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/toolsListWidget.d.ts +120 -0
  193. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/toolsListWidget.js +898 -0
  194. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentResolveService.js +1 -1
  195. package/vscode/src/vs/workbench/contrib/chat/browser/chat.shared.contribution.js +581 -336
  196. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/agentHostChatDebugProvider.d.ts +123 -0
  197. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/agentHostChatDebugProvider.js +567 -0
  198. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatCustomizationDiscoveryRenderer.js +32 -32
  199. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCacheDiff.js +168 -84
  200. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCacheExplorerView.d.ts +183 -2
  201. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCacheExplorerView.js +897 -251
  202. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCacheInsights.d.ts +213 -0
  203. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCacheInsights.js +720 -0
  204. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugDetailPanel.js +6 -6
  205. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditorInput.js +2 -2
  206. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventDetailRenderer.js +20 -20
  207. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventList.js +7 -7
  208. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFilters.js +4 -4
  209. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowChartView.js +7 -7
  210. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowGraph.js +22 -22
  211. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHomeView.js +13 -13
  212. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHookContentRenderer.js +17 -17
  213. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugLogsView.js +24 -24
  214. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugMessageContentRenderer.js +8 -8
  215. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugModelTurnContentRenderer.js +23 -23
  216. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugOverviewView.js +33 -33
  217. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugToolCallContentRenderer.js +11 -11
  218. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/media/chatDebug.css +354 -1
  219. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimelineImpl.js +9 -2
  220. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.js +1 -1
  221. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingDeletedFileEntry.js +1 -1
  222. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.js +14 -14
  223. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.js +7 -7
  224. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationModelManager.js +3 -3
  225. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationWidget.js +12 -12
  226. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.js +11 -4
  227. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.js +1 -1
  228. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.js +1 -1
  229. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.js +4 -4
  230. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.js +3 -3
  231. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelChangeService.js +1 -1
  232. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.js +1 -1
  233. package/vscode/src/vs/workbench/contrib/chat/browser/chatImageCarouselService.d.ts +9 -3
  234. package/vscode/src/vs/workbench/contrib/chat/browser/chatImageCarouselService.js +55 -8
  235. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.js +8 -8
  236. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.js +2 -2
  237. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.d.ts +18 -1
  238. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.js +192 -87
  239. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/media/chatModelsWidget.css +37 -3
  240. package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.js +4 -4
  241. package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.js +30 -30
  242. package/vscode/src/vs/workbench/contrib/chat/browser/chatQuotaNotification.d.ts +40 -1
  243. package/vscode/src/vs/workbench/contrib/chat/browser/chatQuotaNotification.js +230 -41
  244. package/vscode/src/vs/workbench/contrib/chat/browser/chatRepoInfo.js +2 -2
  245. package/vscode/src/vs/workbench/contrib/chat/browser/chatResponseFileChangesService.d.ts +30 -0
  246. package/vscode/src/vs/workbench/contrib/chat/browser/chatResponseFileChangesService.js +29 -0
  247. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.js +23 -25
  248. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.js +10 -10
  249. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupGrowthSession.js +6 -6
  250. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.js +35 -32
  251. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.d.ts +26 -2
  252. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.js +56 -32
  253. package/vscode/src/vs/workbench/contrib/chat/browser/chatSlashCommands.js +19 -19
  254. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.d.ts +0 -1
  255. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.js +109 -68
  256. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.d.ts +38 -5
  257. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.js +175 -50
  258. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/media/chatStatus.css +4 -0
  259. package/vscode/src/vs/workbench/contrib/chat/browser/chatTipCatalog.js +19 -19
  260. package/vscode/src/vs/workbench/contrib/chat/browser/chatTipService.js +2 -2
  261. package/vscode/src/vs/workbench/contrib/chat/browser/chatWindowNotifier.js +4 -4
  262. package/vscode/src/vs/workbench/contrib/chat/browser/claudePluginRecommendations.js +2 -2
  263. package/vscode/src/vs/workbench/contrib/chat/browser/contextContrib/chatContext.contribution.js +5 -5
  264. package/vscode/src/vs/workbench/contrib/chat/browser/defaultModelContribution.js +5 -5
  265. package/vscode/src/vs/workbench/contrib/chat/browser/enablementActions.js +4 -4
  266. package/vscode/src/vs/workbench/contrib/chat/browser/enablementStatusWidget.js +2 -2
  267. package/vscode/src/vs/workbench/contrib/chat/browser/languageModelsConfigurationService.js +1 -1
  268. package/vscode/src/vs/workbench/contrib/chat/browser/planReviewFeedback/planReviewFeedbackEditorActions.js +4 -4
  269. package/vscode/src/vs/workbench/contrib/chat/browser/planReviewFeedback/planReviewFeedbackEditorContribution.js +5 -5
  270. package/vscode/src/vs/workbench/contrib/chat/browser/pluginAutoUpdate.d.ts +4 -5
  271. package/vscode/src/vs/workbench/contrib/chat/browser/pluginAutoUpdate.js +1 -1
  272. package/vscode/src/vs/workbench/contrib/chat/browser/pluginGitCommandService.js +3 -3
  273. package/vscode/src/vs/workbench/contrib/chat/browser/pluginInstallService.d.ts +32 -3
  274. package/vscode/src/vs/workbench/contrib/chat/browser/pluginInstallService.js +183 -84
  275. package/vscode/src/vs/workbench/contrib/chat/browser/pluginSources.js +15 -15
  276. package/vscode/src/vs/workbench/contrib/chat/browser/pluginUrlHandler.d.ts +3 -1
  277. package/vscode/src/vs/workbench/contrib/chat/browser/pluginUrlHandler.js +20 -9
  278. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/chatModeActions.js +6 -6
  279. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookActions.js +27 -27
  280. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookUtils.js +3 -3
  281. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionOverlay.js +2 -2
  282. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolSetsCodeLensProvider.d.ts +1 -0
  283. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolSetsCodeLensProvider.js +109 -0
  284. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolsCodeLensProvider.js +2 -2
  285. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptUrlHandler.js +8 -8
  286. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.js +7 -7
  287. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.js +3 -3
  288. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/skillActions.js +3 -3
  289. package/vscode/src/vs/workbench/contrib/chat/browser/promptsDebugContribution.js +20 -20
  290. package/vscode/src/vs/workbench/contrib/chat/browser/tools/clientToolSetsContribution.d.ts +17 -0
  291. package/vscode/src/vs/workbench/contrib/chat/browser/tools/clientToolSetsContribution.js +117 -0
  292. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsConfirmationService.js +39 -39
  293. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsService.d.ts +40 -4
  294. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsService.js +169 -34
  295. package/vscode/src/vs/workbench/contrib/chat/browser/tools/renameTool.js +7 -7
  296. package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolHelpers.d.ts +5 -1
  297. package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolHelpers.js +2 -2
  298. package/vscode/src/vs/workbench/contrib/chat/browser/tools/usagesTool.js +8 -8
  299. package/vscode/src/vs/workbench/contrib/chat/browser/utilityModelContribution.js +2 -2
  300. package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcomeHandler.js +5 -5
  301. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/micCaptureService.d.ts +125 -0
  302. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/micCaptureService.js +399 -0
  303. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/ttsPlaybackService.d.ts +34 -0
  304. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/ttsPlaybackService.js +198 -0
  305. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/voiceClientService.d.ts +85 -0
  306. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/voiceClientService.js +504 -0
  307. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/voiceSessionController.d.ts +321 -0
  308. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/voiceSessionController.js +2117 -0
  309. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/voiceToolDispatchService.d.ts +57 -0
  310. package/vscode/src/vs/workbench/contrib/chat/browser/voiceClient/voiceToolDispatchService.js +367 -0
  311. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatQueuePickerActionItem.js +16 -12
  312. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/agentHostInputCompletions.d.ts +2 -0
  313. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/agentHostInputCompletions.js +68 -18
  314. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.js +11 -10
  315. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorContrib.js +2 -2
  316. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorHover.js +1 -1
  317. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/chatQuick.js +1 -1
  318. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/editor/chatEditor.d.ts +7 -0
  319. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/editor/chatEditor.js +13 -2
  320. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.d.ts +23 -5
  321. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.js +320 -40
  322. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewTitleControl.js +2 -2
  323. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatViewPane.css +80 -4
  324. package/vscode/src/vs/workbench/contrib/chat/common/automations/automation.d.ts +78 -0
  325. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationDialogService.d.ts +13 -0
  326. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationDialogService.service.d.ts +11 -0
  327. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationDialogService.service.js +6 -0
  328. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationRunner.service.d.ts +16 -0
  329. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationRunner.service.js +6 -0
  330. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationService.d.ts +46 -0
  331. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationService.service.d.ts +36 -0
  332. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationService.service.js +6 -0
  333. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationsEnabled.d.ts +12 -0
  334. package/vscode/src/vs/workbench/contrib/chat/common/automations/automationsEnabled.js +6 -0
  335. package/vscode/src/vs/workbench/contrib/chat/common/automations/schedule.d.ts +9 -0
  336. package/vscode/src/vs/workbench/contrib/chat/common/automations/schedule.js +6 -0
  337. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugServiceImpl.d.ts +2 -0
  338. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugServiceImpl.js +7 -1
  339. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.d.ts +28 -0
  340. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.js +226 -88
  341. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceTelemetry.d.ts +6 -0
  342. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceTelemetry.js +8 -3
  343. package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionOperationLog.js +13 -2
  344. package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionStore.js +12 -8
  345. package/vscode/src/vs/workbench/contrib/chat/common/model/objectMutationLog.d.ts +5 -0
  346. package/vscode/src/vs/workbench/contrib/chat/common/model/objectMutationLog.js +5 -2
  347. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginEnablement.d.ts +15 -0
  348. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginEnablement.js +177 -0
  349. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginServiceImpl.d.ts +2 -18
  350. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginServiceImpl.js +78 -136
  351. package/vscode/src/vs/workbench/contrib/chat/common/plugins/marketplaceReference.d.ts +1 -16
  352. package/vscode/src/vs/workbench/contrib/chat/common/plugins/marketplaceReference.js +1 -17
  353. package/vscode/src/vs/workbench/contrib/chat/common/plugins/pluginMarketplaceService.d.ts +2 -0
  354. package/vscode/src/vs/workbench/contrib/chat/common/plugins/pluginMarketplaceService.js +16 -5
  355. package/vscode/src/vs/workbench/contrib/chat/common/plugins/strictKnownMarketplaces.d.ts +31 -0
  356. package/vscode/src/vs/workbench/contrib/chat/common/plugins/strictKnownMarketplaces.js +122 -0
  357. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/chatPromptFilesContribution.js +24 -18
  358. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.d.ts +3 -0
  359. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.js +113 -10
  360. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.js +5 -5
  361. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.js +12 -12
  362. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.d.ts +10 -0
  363. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.js +227 -152
  364. package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.js +1 -1
  365. package/vscode/src/vs/workbench/contrib/chat/common/voicePlaybackService.d.ts +26 -0
  366. package/vscode/src/vs/workbench/contrib/chat/common/voicePlaybackService.js +98 -0
  367. package/vscode/src/vs/workbench/contrib/chat/common/workingDirectory.d.ts +5 -0
  368. package/vscode/src/vs/workbench/contrib/chat/common/workingDirectory.js +7 -6
  369. package/vscode/src/vs/workbench/contrib/imageCarousel/browser/imageCarousel.contribution.js +11 -12
  370. package/vscode/src/vs/workbench/contrib/imageCarousel/browser/imageCarouselEditor.js +10 -10
  371. package/vscode/src/vs/workbench/contrib/imageCarousel/browser/imageCarouselEditorInput.d.ts +2 -0
  372. package/vscode/src/vs/workbench/contrib/imageCarousel/browser/imageCarouselEditorInput.js +7 -0
  373. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +15 -15
  374. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatDefaultModel.js +2 -2
  375. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.js +4 -4
  376. package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.js +14 -14
  377. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.js +1 -1
  378. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.js +10 -10
  379. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebook.chat.contribution.js +5 -5
  380. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatContext.js +1 -1
  381. package/vscode/src/vs/workbench/contrib/remoteCodingAgents/browser/remoteCodingAgents.contribution.js +7 -7
  382. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibilityHelp.js +16 -16
  383. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatActions.js +32 -20
  384. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +1 -1
  385. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/agentHostSandboxForwarder.d.ts +23 -5
  386. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/agentHostSandboxForwarder.js +37 -30
  387. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.js +7 -0
  388. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/noneExecuteStrategy.js +7 -0
  389. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.js +7 -0
  390. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/largeOutputFileWriter.d.ts +33 -0
  391. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/largeOutputFileWriter.js +71 -0
  392. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/outputHelpers.d.ts +19 -0
  393. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/outputHelpers.js +29 -9
  394. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +7 -20
  395. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.js +4 -4
  396. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.js +2 -1
  397. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.js +1 -1
  398. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +12 -12
  399. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +10 -8
  400. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.js +3 -3
  401. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.js +4 -4
  402. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.js +3 -3
  403. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/killTerminalTool.js +3 -3
  404. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +3 -3
  405. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.js +26 -2
  406. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +32 -3
  407. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +416 -252
  408. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sandboxOutputAnalyzer.d.ts +1 -1
  409. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sandboxOutputAnalyzer.js +3 -2
  410. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sendToTerminalTool.js +10 -10
  411. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.js +14 -14
  412. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.js +7 -7
  413. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.js +14 -14
  414. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.js +1 -1
  415. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/sandboxSettingsReader.d.ts +2 -3
  416. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/sandboxSettingsReader.js +5 -5
  417. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.d.ts +6 -2
  418. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.js +25 -8
  419. package/vscode/src/vs/workbench/services/agentHost/browser/editorRemoteAgentHostServiceClient.d.ts +8 -3
  420. package/vscode/src/vs/workbench/services/agentHost/browser/editorRemoteAgentHostServiceClient.js +15 -0
  421. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.d.ts +0 -20
  422. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.js +0 -77
  423. package/vscode/src/vs/workbench/contrib/chat/browser/copilotCliEventsUri.d.ts +0 -52
  424. package/vscode/src/vs/workbench/contrib/chat/browser/copilotCliEventsUri.js +0 -82
  425. package/vscode/src/vs/workbench/contrib/chat/common/chatSelectedModel.d.ts +0 -38
  426. package/vscode/src/vs/workbench/contrib/chat/common/chatSelectedModel.js +0 -47
  427. /package/vscode/src/vs/{workbench/contrib → platform}/browserView/common/browserChatToolReferenceNames.js +0 -0
@@ -40,17 +40,20 @@ import { ChatContextKeys } from '@codingame/monaco-vscode-api/vscode/vs/workbenc
40
40
  import { toToolSetVariableEntry, toToolVariableEntry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/attachments/chatVariableEntries';
41
41
  import { ToolConfirmKind, IChatToolInvocation } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService/chatService';
42
42
  import { IChatService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService/chatService.service';
43
- import { ChatConfiguration, isAutoApproveLevel } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants';
43
+ import { ChatConfiguration, isAutoApproveLevel, isAutopilotLevel } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants';
44
44
  import { localChatSessionType } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatSessionsService';
45
45
  import { ChatToolInvocation } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/model/chatProgressTypes/chatToolInvocation';
46
46
  import { chatSessionResourceToId, getChatSessionType } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/model/chatUri';
47
47
  import { HookType } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/hookTypes';
48
48
  import { CopilotChatSettingId, CopilotToolId } from '../../common/tools/copilotToolIds.js';
49
49
  import { ILanguageModelToolsConfirmationService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsConfirmationService.service';
50
- import { ToolDataSource, VSCodeToolReference, SpecedToolAliases, toolMatchesModel, isToolSet, createToolSchemaUri, ToolInvocationPresentation, stringifyPromptTsxPart, ToolSetForModel, ToolSet } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService';
50
+ import { TerminalToolId } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/terminalToolIds';
51
+ import { ToolDataSource, VSCodeToolReference, SpecedToolAliases, toolMatchesModel, isToolSet, createToolSchemaUri, ToolInvocationPresentation, stringifyPromptTsxPart, ToolSetForModel, ToolAndToolSetEnablementMap, ToolSet } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService';
51
52
  import { IToolResultCompressor } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/toolResultCompressor.service';
52
53
  import { getToolConfirmationAlert } from '@codingame/monaco-vscode-katex-common/vscode/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityProvider';
53
54
  import { IChatWidgetService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service';
55
+ import { ToolRiskLevel } from '@codingame/monaco-vscode-katex-common/vscode/vs/workbench/contrib/chat/browser/tools/chatToolRiskAssessmentService';
56
+ import { IChatToolRiskAssessmentService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/tools/chatToolRiskAssessmentService.service';
54
57
  import { ObservableSet } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/set';
55
58
  import { derived, derivedOpts } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/derived';
56
59
  import { observableFromEventOpts } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/observableFromEvent';
@@ -64,12 +67,14 @@ var AutoApproveStorageKeys;
64
67
  AutoApproveStorageKeys["GlobalAutoApproveOptIn"] = "chat.tools.global.autoApprove.optIn";
65
68
  })(AutoApproveStorageKeys || (AutoApproveStorageKeys = {}));
66
69
  const SkipAutoApproveConfirmationKey = "vscode.chat.tools.global.autoApprove.testMode";
70
+ const autoApproveAllReason = "auto-approve-all";
67
71
  const toolIdsThatCannotBeAutoApproved = ( new Set([
68
72
  "vscode_get_confirmation_with_options",
69
73
  "vscode_get_modified_files_confirmation"
70
74
  ]));
75
+ const fetchWebPageToolIds = ( new Set(["copilot_fetchWebPage", "vscode_fetchWebPage_internal"]));
71
76
  const globalAutoApproveDescription = ( localize2(
72
- 7188,
77
+ 7704,
73
78
  "Global auto approve also known as \"YOLO mode\" disables manual approval completely for _all tools in all workspaces_, allowing the agent to act fully autonomously. This is extremely dangerous and is *never* recommended, even containerized environments like [Codespaces](https://github.com/features/codespaces) and [Dev Containers](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) have user keys forwarded into the container that could be compromised.\n\n**This feature disables [critical security protections](https://code.visualstudio.com/docs/copilot/security) and makes it much easier for an attacker to compromise the machine.**\n\nNote: This setting only controls tool approval and does not prevent the agent from asking questions. To automatically answer agent questions, use the [`chat.autoReply`](command:workbench.action.openSettings?%5B%22chat.autoReply%22%5D) setting."
74
79
  ));
75
80
  let LanguageModelToolsService = class LanguageModelToolsService extends Disposable {
@@ -91,7 +96,8 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
91
96
  _confirmationService,
92
97
  _commandService,
93
98
  _chatWidgetService,
94
- _toolResultCompressor
99
+ _toolResultCompressor,
100
+ _riskAssessmentService
95
101
  ) {
96
102
  super();
97
103
  this._instantiationService = _instantiationService;
@@ -109,6 +115,7 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
109
115
  this._commandService = _commandService;
110
116
  this._chatWidgetService = _chatWidgetService;
111
117
  this._toolResultCompressor = _toolResultCompressor;
118
+ this._riskAssessmentService = _riskAssessmentService;
112
119
  this._onDidChangeTools = this._register(( new Emitter()));
113
120
  this.onDidChangeTools = this._onDidChangeTools.event;
114
121
  this._onDidPrepareToolCallBecomeUnresponsive = this._register(( new Emitter()));
@@ -174,25 +181,29 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
174
181
  this.vscodeToolSet = this._register(
175
182
  this.createToolSet(ToolDataSource.Internal, "vscode", VSCodeToolReference.vscode, {
176
183
  icon: ThemeIcon.fromId(Codicon.vscode.id),
177
- description: ( localize(7189, "Use VS Code features"))
184
+ description: ( localize(7705, "Use VS Code features")),
185
+ deprecated: true
178
186
  })
179
187
  );
180
188
  this.executeToolSet = this._register(
181
189
  this.createToolSet(ToolDataSource.Internal, "execute", SpecedToolAliases.execute, {
182
190
  icon: ThemeIcon.fromId(Codicon.terminal.id),
183
- description: ( localize(7190, "Execute code and applications on your machine"))
191
+ description: ( localize(7706, "Execute code and applications on your machine")),
192
+ deprecated: true
184
193
  })
185
194
  );
186
195
  this.readToolSet = this._register(
187
196
  this.createToolSet(ToolDataSource.Internal, "read", SpecedToolAliases.read, {
188
197
  icon: ThemeIcon.fromId(Codicon.book.id),
189
- description: ( localize(7191, "Read files in your workspace"))
198
+ description: ( localize(7707, "Read files in your workspace")),
199
+ deprecated: true
190
200
  })
191
201
  );
192
202
  this.agentToolSet = this._register(
193
203
  this.createToolSet(ToolDataSource.Internal, "agent", SpecedToolAliases.agent, {
194
204
  icon: ThemeIcon.fromId(Codicon.agent.id),
195
- description: ( localize(7192, "Delegate tasks to other agents"))
205
+ description: ( localize(7708, "Delegate tasks to other agents")),
206
+ deprecated: true
196
207
  })
197
208
  );
198
209
  }
@@ -355,8 +366,8 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
355
366
  return undefined;
356
367
  }
357
368
  _handlePreToolUseDenial(dto, hookResult, toolData, pendingInvocation, request) {
358
- const hookReason = hookResult.permissionDecisionReason ?? ( localize(7193, "Hook denied tool execution"));
359
- const reason = ( localize(7194, "Denied by {0} hook: {1}", HookType.PreToolUse, hookReason));
369
+ const hookReason = hookResult.permissionDecisionReason ?? ( localize(7709, "Hook denied tool execution"));
370
+ const reason = ( localize(7710, "Denied by {0} hook: {1}", HookType.PreToolUse, hookReason));
360
371
  this._logService.debug(
361
372
  `[LanguageModelToolsService#invokeTool] Tool ${dto.toolId} denied by preToolUse hook: ${hookReason}`
362
373
  );
@@ -528,7 +539,7 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
528
539
  preparedInvocation = await this.prepareToolInvocationWithHookResult(tool, dto, preToolUseHookResult, token);
529
540
  prepareTimeWatch.stop();
530
541
  const {
531
- autoConfirmed,
542
+ autoConfirmed: resolvedAutoConfirmed,
532
543
  preparedInvocation: updatedPreparedInvocation
533
544
  } = await this.resolveAutoConfirmFromHook(
534
545
  preToolUseHookResult,
@@ -538,6 +549,10 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
538
549
  dto.context?.sessionResource
539
550
  );
540
551
  preparedInvocation = updatedPreparedInvocation;
552
+ const {
553
+ autoConfirmed,
554
+ skipExplanation: riskSkipExplanation
555
+ } = await this._maybeApplyAutopilotRiskGate(tool, dto, preparedInvocation, resolvedAutoConfirmed, token);
541
556
  if (hadPendingInvocation && toolInvocation) {
542
557
  toolInvocation.transitionFromStreaming(preparedInvocation, dto.parameters, autoConfirmed);
543
558
  } else {
@@ -554,6 +569,27 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
554
569
  this._chatService.appendProgress(request, toolInvocation);
555
570
  }
556
571
  dto.toolSpecificData = toolInvocation?.toolSpecificData;
572
+ if (riskSkipExplanation) {
573
+ this._logToolApprovalTelemetry(tool, dto, {
574
+ type: ToolConfirmKind.Skipped
575
+ });
576
+ this._chatService.appendProgress(request, {
577
+ kind: "info",
578
+ content: ( new MarkdownString(( localize(
579
+ 7711,
580
+ "Autopilot skipped \"{0}\" because it was assessed as high-risk: {1}",
581
+ tool.data.displayName,
582
+ riskSkipExplanation
583
+ ))))
584
+ });
585
+ toolResult = {
586
+ content: [{
587
+ kind: "text",
588
+ value: `Autopilot skipped this tool call because it was automatically assessed as high-risk: ${riskSkipExplanation} The action was not performed. Do not retry it as-is — choose a safer approach or leave it for the user to run manually.`
589
+ }]
590
+ };
591
+ return toolResult;
592
+ }
557
593
  if (preparedInvocation?.confirmationMessages?.title) {
558
594
  if (!IChatToolInvocation.executionConfirmedOrDenied(toolInvocation) && !autoConfirmed) {
559
595
  this.playAccessibilitySignal([toolInvocation], dto.context?.sessionResource);
@@ -694,7 +730,7 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
694
730
  async prepareToolInvocationWithHookResult(tool, dto, hookResult, token) {
695
731
  let forceConfirmationReason;
696
732
  if (hookResult?.permissionDecision === "ask") {
697
- const hookMessage = ( localize(7195, "{0} required confirmation", HookType.PreToolUse));
733
+ const hookMessage = ( localize(7712, "{0} required confirmation", HookType.PreToolUse));
698
734
  forceConfirmationReason = hookResult.permissionDecisionReason ? `${hookMessage}: ${hookResult.permissionDecisionReason}` : hookMessage;
699
735
  }
700
736
  return this.prepareToolInvocation(tool, dto, forceConfirmationReason, token);
@@ -708,7 +744,7 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
708
744
  [ToolConfirmKind.UserAction]: "userAction",
709
745
  [ToolConfirmKind.Skipped]: "skipped"
710
746
  };
711
- const allowedConfirmationNotNeededReasons = ( new Set(["auto-approve-all", "inlineChat"]));
747
+ const allowedConfirmationNotNeededReasons = ( new Set([autoApproveAllReason, "inlineChat"]));
712
748
  let confirmationNotNeededReason;
713
749
  if (reason.type === ToolConfirmKind.ConfirmationNotNeeded && reason.reason) {
714
750
  const raw = typeof reason.reason === "string" ? reason.reason : reason.reason.value;
@@ -738,7 +774,7 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
738
774
  return {
739
775
  autoConfirmed: {
740
776
  type: ToolConfirmKind.ConfirmationNotNeeded,
741
- reason: ( localize(7196, "Allowed by hook"))
777
+ reason: ( localize(7713, "Allowed by hook"))
742
778
  },
743
779
  preparedInvocation
744
780
  };
@@ -754,14 +790,14 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
754
790
  const fullReferenceName = getToolFullReferenceName(tool.data);
755
791
  const hookReason = hookResult.permissionDecisionReason;
756
792
  const hookNote = hookReason ? ( localize(
757
- 7197,
793
+ 7714,
758
794
  "{0} hook required confirmation: {1}",
759
795
  HookType.PreToolUse,
760
796
  hookReason
761
- )) : ( localize(7198, "{0} hook required confirmation", HookType.PreToolUse));
797
+ )) : ( localize(7715, "{0} hook required confirmation", HookType.PreToolUse));
762
798
  preparedInvocation.confirmationMessages = {
763
799
  ...preparedInvocation.confirmationMessages,
764
- title: ( localize(7199, "Use the '{0}' tool?", fullReferenceName)),
800
+ title: ( localize(7716, "Use the '{0}' tool?", fullReferenceName)),
765
801
  message: ( new MarkdownString(`_${hookNote}_`)),
766
802
  allowAutoConfirm: false
767
803
  };
@@ -772,11 +808,11 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
772
808
  } else {
773
809
  const hookReason = hookResult.permissionDecisionReason;
774
810
  const hookNote = hookReason ? ( localize(
775
- 7200,
811
+ 7717,
776
812
  "{0} hook required confirmation: {1}",
777
813
  HookType.PreToolUse,
778
814
  hookReason
779
- )) : ( localize(7201, "{0} hook required confirmation", HookType.PreToolUse));
815
+ )) : ( localize(7718, "{0} hook required confirmation", HookType.PreToolUse));
780
816
  const existing = preparedInvocation.confirmationMessages;
781
817
  if (preparedInvocation.toolSpecificData?.kind === "terminal") {
782
818
  const existingDisclaimerText = existing.disclaimer ? (typeof existing.disclaimer === "string" ? existing.disclaimer : existing.disclaimer.value) : undefined;
@@ -823,6 +859,72 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
823
859
  preparedInvocation
824
860
  };
825
861
  }
862
+ async _maybeApplyAutopilotRiskGate(tool, dto, preparedInvocation, autoConfirmed, token) {
863
+ const isTerminalTool = tool.data.id === TerminalToolId.RunInTerminal;
864
+ const isFetchTool = ( fetchWebPageToolIds.has(tool.data.id));
865
+ const isAlwaysClassifyTool = isTerminalTool || isFetchTool;
866
+ const isBlanketSessionApprove = autoConfirmed?.type === ToolConfirmKind.ConfirmationNotNeeded && autoConfirmed.reason === autoApproveAllReason;
867
+ const isSelfApprovedAlwaysClassify = isAlwaysClassifyTool && autoConfirmed === undefined && !preparedInvocation?.confirmationMessages?.title;
868
+ if (!isBlanketSessionApprove && !isSelfApprovedAlwaysClassify) {
869
+ return {
870
+ autoConfirmed
871
+ };
872
+ }
873
+ if (!isAlwaysClassifyTool && !preparedInvocation?.confirmationMessages?.title) {
874
+ return {
875
+ autoConfirmed
876
+ };
877
+ }
878
+ if (this._configurationService.getValue(ChatConfiguration.AutopilotAdvancedEnabled) !== true) {
879
+ return {
880
+ autoConfirmed
881
+ };
882
+ }
883
+ const sessionResource = dto.context?.sessionResource;
884
+ if (!sessionResource || getChatSessionType(sessionResource) !== localChatSessionType) {
885
+ return {
886
+ autoConfirmed
887
+ };
888
+ }
889
+ if (!this._isSessionInAutopilotLevel(sessionResource)) {
890
+ return {
891
+ autoConfirmed
892
+ };
893
+ }
894
+ try {
895
+ const assessment = await this._riskAssessmentService.assess(tool.data, dto.parameters, token, undefined, {
896
+ ignoreEnablement: true
897
+ });
898
+ if (token.isCancellationRequested) {
899
+ return {
900
+ autoConfirmed
901
+ };
902
+ }
903
+ if (assessment?.risk === ToolRiskLevel.Red) {
904
+ const fallbackExplanation = ( localize(
905
+ 7719,
906
+ "The action was assessed as potentially destructive or irreversible."
907
+ ));
908
+ const explanation = assessment.explanation.trim() || fallbackExplanation;
909
+ this._logService.info(
910
+ `[LanguageModelToolsService#invokeTool] Autopilot skipping high-risk tool ${tool.data.id}: ${explanation}`
911
+ );
912
+ return {
913
+ autoConfirmed: {
914
+ type: ToolConfirmKind.Skipped
915
+ },
916
+ skipExplanation: explanation
917
+ };
918
+ }
919
+ } catch (err) {
920
+ this._logService.warn(
921
+ `[LanguageModelToolsService#invokeTool] Autopilot risk assessment failed for tool ${tool.data.id}, allowing: ${toErrorMessage(err)}`
922
+ );
923
+ }
924
+ return {
925
+ autoConfirmed
926
+ };
927
+ }
826
928
  async prepareToolInvocation(tool, dto, forceConfirmationReason, token) {
827
929
  let prepared;
828
930
  if (tool.impl.prepareToolInvocation) {
@@ -853,17 +955,17 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
853
955
  const fullReferenceName = getToolFullReferenceName(tool.data);
854
956
  prepared.confirmationMessages = {
855
957
  ...prepared.confirmationMessages,
856
- title: ( localize(7202, "Confirm tool execution")),
857
- message: ( localize(7203, "Run the '{0}' tool?", fullReferenceName)),
958
+ title: ( localize(7720, "Confirm tool execution")),
959
+ message: ( localize(7721, "Run the '{0}' tool?", fullReferenceName)),
858
960
  disclaimer: ( toolIdsThatCannotBeAutoApproved.has(tool.data.id)) ? undefined : ( new MarkdownString(( localize(
859
- 7204,
961
+ 7722,
860
962
  "Auto approval for '{0}' is restricted via {1}.",
861
963
  getToolFullReferenceName(tool.data),
862
964
  createMarkdownCommandLink({
863
965
  text: "`" + ChatConfiguration.EligibleForAutoApproval + "`",
864
966
  id: "workbench.action.openSettings",
865
967
  arguments: [ChatConfiguration.EligibleForAutoApproval],
866
- tooltip: ( localize(7205, "Open settings to configure auto-approval"))
968
+ tooltip: ( localize(7723, "Open settings to configure auto-approval"))
867
969
  }, false)
868
970
  )), {
869
971
  isTrusted: true
@@ -873,14 +975,14 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
873
975
  }
874
976
  if (!isEligibleForAutoApproval && prepared?.confirmationMessages?.title) {
875
977
  prepared.confirmationMessages.disclaimer = ( toolIdsThatCannotBeAutoApproved.has(tool.data.id)) ? undefined : ( new MarkdownString(( localize(
876
- 7204,
978
+ 7722,
877
979
  "Auto approval for '{0}' is restricted via {1}.",
878
980
  getToolFullReferenceName(tool.data),
879
981
  createMarkdownCommandLink({
880
982
  text: "`" + ChatConfiguration.EligibleForAutoApproval + "`",
881
983
  id: "workbench.action.openSettings",
882
984
  arguments: [ChatConfiguration.EligibleForAutoApproval],
883
- tooltip: ( localize(7205, "Open settings to configure auto-approval"))
985
+ tooltip: ( localize(7723, "Open settings to configure auto-approval"))
884
986
  }, false)
885
987
  )), {
886
988
  isTrusted: true
@@ -1068,6 +1170,18 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
1068
1170
  const request = model?.getRequests().at(-1);
1069
1171
  return isAutoApproveLevel(request?.modeInfo?.permissionLevel) || this._isSessionLiveAutoApproveLevel(chatSessionResource);
1070
1172
  }
1173
+ _isSessionLiveAutopilotLevel(chatSessionResource) {
1174
+ const widget = this._chatWidgetService.getWidgetBySessionResource(chatSessionResource) ?? this._chatWidgetService.lastFocusedWidget;
1175
+ return !!widget && isAutopilotLevel(widget.input.currentModeInfo.permissionLevel);
1176
+ }
1177
+ _isSessionInAutopilotLevel(chatSessionResource) {
1178
+ if (!chatSessionResource) {
1179
+ return false;
1180
+ }
1181
+ const model = this._chatService.getSession(chatSessionResource);
1182
+ const request = model?.getRequests().at(-1);
1183
+ return isAutopilotLevel(request?.modeInfo?.permissionLevel) || this._isSessionLiveAutopilotLevel(chatSessionResource);
1184
+ }
1071
1185
  getEligibleForAutoApprovalSpecialCase(toolData) {
1072
1186
  if (toolData.id === "vscode_fetchWebPage_internal") {
1073
1187
  return "fetch";
@@ -1121,7 +1235,7 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
1121
1235
  if (!(( toolIdsThatCannotBeAutoApproved.has(tool.data.id)) && getChatSessionType(chatSessionResource) !== localChatSessionType)) {
1122
1236
  return {
1123
1237
  type: ToolConfirmKind.ConfirmationNotNeeded,
1124
- reason: "auto-approve-all"
1238
+ reason: autoApproveAllReason
1125
1239
  };
1126
1240
  }
1127
1241
  }
@@ -1172,7 +1286,7 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
1172
1286
  if (!(( toolIdsThatCannotBeAutoApproved.has(toolId)) && getChatSessionType(chatSessionResource) !== localChatSessionType)) {
1173
1287
  return {
1174
1288
  type: ToolConfirmKind.ConfirmationNotNeeded,
1175
- reason: "auto-approve-all"
1289
+ reason: autoApproveAllReason
1176
1290
  };
1177
1291
  }
1178
1292
  }
@@ -1232,12 +1346,12 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
1232
1346
  }));
1233
1347
  const promptResult = await this._dialogService.prompt({
1234
1348
  type: Severity.Warning,
1235
- message: ( localize(7206, "Enable global auto approve?")),
1349
+ message: ( localize(7724, "Enable global auto approve?")),
1236
1350
  buttons: [{
1237
- label: ( localize(7207, "Enable")),
1351
+ label: ( localize(7725, "Enable")),
1238
1352
  run: () => true
1239
1353
  }, {
1240
- label: ( localize(7208, "Disable")),
1354
+ label: ( localize(7726, "Disable")),
1241
1355
  run: () => false
1242
1356
  }],
1243
1357
  custom: {
@@ -1398,21 +1512,32 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
1398
1512
  result.set(toolSet, enabled);
1399
1513
  }
1400
1514
  }
1401
- return result;
1515
+ return ToolAndToolSetEnablementMap.fromMap(result);
1402
1516
  }
1403
1517
  toFullReferenceNames(map) {
1404
1518
  const result = [];
1405
1519
  const toolsCoveredByEnabledToolSet = ( new Set());
1520
+ const enabledToolSetIds = ( new Set());
1521
+ const enabledToolIds = ( new Set());
1522
+ for (const [tool, enabled] of map) {
1523
+ if (enabled) {
1524
+ if (isToolSet(tool)) {
1525
+ enabledToolSetIds.add(tool.id);
1526
+ } else {
1527
+ enabledToolIds.add(tool.id);
1528
+ }
1529
+ }
1530
+ }
1406
1531
  for (const [tool, fullReferenceName] of this.toolsWithFullReferenceName.get()) {
1407
1532
  if (isToolSet(tool)) {
1408
- if (map.get(tool)) {
1533
+ if (( enabledToolSetIds.has(tool.id))) {
1409
1534
  result.push(fullReferenceName);
1410
1535
  for (const memberTool of tool.getTools()) {
1411
1536
  toolsCoveredByEnabledToolSet.add(memberTool);
1412
1537
  }
1413
1538
  }
1414
1539
  } else {
1415
- if (map.get(tool) && !( toolsCoveredByEnabledToolSet.has(tool))) {
1540
+ if (( enabledToolIds.has(tool.id)) && !( toolsCoveredByEnabledToolSet.has(tool))) {
1416
1541
  result.push(fullReferenceName);
1417
1542
  }
1418
1543
  }
@@ -1484,7 +1609,10 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
1484
1609
  options?.icon ?? Codicon.tools,
1485
1610
  source,
1486
1611
  options?.description,
1612
+ options?.detail,
1487
1613
  options?.legacyFullNames,
1614
+ options?.deprecated,
1615
+ options?.hiddenInToolsPicker,
1488
1616
  this._contextKeyService
1489
1617
  );
1490
1618
  this._toolSets.add(result);
@@ -1567,8 +1695,15 @@ let LanguageModelToolsService = class LanguageModelToolsService extends Disposab
1567
1695
  }
1568
1696
  return getToolFullReferenceName(tool, toolSet);
1569
1697
  }
1698
+ getFullReferenceNameMap() {
1699
+ const result = ( new Map());
1700
+ for (const [item, toolFullReferenceName] of this.toolsWithFullReferenceName.get()) {
1701
+ result.set(item, toolFullReferenceName);
1702
+ }
1703
+ return result;
1704
+ }
1570
1705
  };
1571
- LanguageModelToolsService = LanguageModelToolsService_1 = ( __decorate([( __param(0, IInstantiationService)), ( __param(1, IExtensionService)), ( __param(2, IContextKeyService)), ( __param(3, IChatService)), ( __param(4, IDialogService)), ( __param(5, ITelemetryService)), ( __param(6, ILogService)), ( __param(7, IConfigurationService)), ( __param(8, IAccessibilityService)), ( __param(9, IAccessibilitySignalService)), ( __param(10, IStorageService)), ( __param(11, ILanguageModelToolsConfirmationService)), ( __param(12, ICommandService)), ( __param(13, IChatWidgetService)), ( __param(14, IToolResultCompressor))], LanguageModelToolsService));
1706
+ LanguageModelToolsService = LanguageModelToolsService_1 = ( __decorate([( __param(0, IInstantiationService)), ( __param(1, IExtensionService)), ( __param(2, IContextKeyService)), ( __param(3, IChatService)), ( __param(4, IDialogService)), ( __param(5, ITelemetryService)), ( __param(6, ILogService)), ( __param(7, IConfigurationService)), ( __param(8, IAccessibilityService)), ( __param(9, IAccessibilitySignalService)), ( __param(10, IStorageService)), ( __param(11, ILanguageModelToolsConfirmationService)), ( __param(12, ICommandService)), ( __param(13, IChatWidgetService)), ( __param(14, IToolResultCompressor)), ( __param(15, IChatToolRiskAssessmentService))], LanguageModelToolsService));
1572
1707
  function getToolFullReferenceName(tool, toolSet) {
1573
1708
  const toolName = tool.toolReferenceName ?? tool.displayName;
1574
1709
  if (toolSet) {
@@ -18,7 +18,7 @@ import { IChatService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/c
18
18
  import { ToolDataSource } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService';
19
19
  import { ILanguageModelToolsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService.service';
20
20
  import { createToolSimpleTextResult } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/builtinTools/toolHelpers';
21
- import { resolveToolUri, errorResult, findLineNumber, findSymbolColumn } from './toolHelpers.js';
21
+ import { resolveSymbolToolFileUri, errorResult, findLineNumber, findSymbolColumn } from './toolHelpers.js';
22
22
 
23
23
  const RenameToolId = "vscode_renameSymbol";
24
24
  const BaseModelDescription = `Rename a code symbol across the workspace using the language server's rename functionality. This performs a precise, semantics-aware rename that updates all references.
@@ -52,7 +52,7 @@ let RenameTool = class RenameTool extends Disposable {
52
52
  this._bulkEditService = _bulkEditService;
53
53
  }
54
54
  getToolData() {
55
- return this._buildToolData(StaticModelDescription, ( localize(7209, "Rename a symbol across the workspace")));
55
+ return this._buildToolData(StaticModelDescription, ( localize(7727, "Rename a symbol across the workspace")));
56
56
  }
57
57
  _buildToolData(modelDescription, userDescription) {
58
58
  return {
@@ -60,7 +60,7 @@ let RenameTool = class RenameTool extends Disposable {
60
60
  toolReferenceName: "rename",
61
61
  canBeReferencedInPrompt: false,
62
62
  icon: ThemeIcon.fromId(Codicon.rename.id),
63
- displayName: ( localize(7210, "Rename Symbol")),
63
+ displayName: ( localize(7728, "Rename Symbol")),
64
64
  userDescription,
65
65
  modelDescription,
66
66
  source: ToolDataSource.Internal,
@@ -95,12 +95,12 @@ let RenameTool = class RenameTool extends Disposable {
95
95
  async prepareToolInvocation(context, _token) {
96
96
  const input = context.parameters;
97
97
  return {
98
- invocationMessage: ( localize(7211, "Renaming `{0}` to `{1}`", input.symbol, input.newName))
98
+ invocationMessage: ( localize(7729, "Renaming `{0}` to `{1}`", input.symbol, input.newName))
99
99
  };
100
100
  }
101
101
  async invoke(invocation, _countTokens, _progress, token) {
102
102
  const input = invocation.parameters;
103
- const uri = resolveToolUri(input, this._workspaceContextService, invocation.context?.workingDirectory);
103
+ const uri = resolveSymbolToolFileUri(input, this._workspaceContextService, invocation.context?.workingDirectory);
104
104
  if (!uri) {
105
105
  return errorResult(
106
106
  "Provide either \"uri\" (a full URI) or \"filePath\" (a workspace-relative path) to identify the file."
@@ -183,13 +183,13 @@ let RenameTool = class RenameTool extends Disposable {
183
183
  }
184
184
  _successResult(input, fileCount, editCount) {
185
185
  const text = editCount === 1 ? ( localize(
186
- 7212,
186
+ 7730,
187
187
  "Renamed `{0}` to `{1}` - 1 edit in {2} file.",
188
188
  input.symbol,
189
189
  input.newName,
190
190
  fileCount
191
191
  )) : ( localize(
192
- 7213,
192
+ 7731,
193
193
  "Renamed `{0}` to `{1}` - {2} edits across {3} files.",
194
194
  input.symbol,
195
195
  input.newName,
@@ -16,8 +16,12 @@ export interface ISymbolToolInput {
16
16
  * Resolves a URI from tool input. Accepts either a full URI string or a
17
17
  * workspace-relative file path. When a {@link workingDirectory} is provided
18
18
  * (agents window), relative paths are resolved against it first.
19
+ *
20
+ * Relative paths that escape the resolution base directory via parent-directory
21
+ * segments (e.g. `../outside.ts`) are rejected and `undefined` is returned, so a
22
+ * `filePath` cannot traverse out of the working directory boundary.
19
23
  */
20
- export declare function resolveToolUri(input: ISymbolToolInput, workspaceContextService: IWorkspaceContextService, workingDirectory?: URI): URI | undefined;
24
+ export declare function resolveSymbolToolFileUri(input: ISymbolToolInput, workspaceContextService: IWorkspaceContextService, workingDirectory?: URI): URI | undefined;
21
25
  /**
22
26
  * Gets the chat permission level that should apply to a tool invocation.
23
27
  *
@@ -6,7 +6,7 @@ import { ChatPermissionLevel, isAutoApproveLevel } from '@codingame/monaco-vscod
6
6
  import { createToolSimpleTextResult } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/builtinTools/toolHelpers';
7
7
  import { WorkingDirectory } from '../../common/workingDirectory.js';
8
8
 
9
- function resolveToolUri(input, workspaceContextService, workingDirectory) {
9
+ function resolveSymbolToolFileUri(input, workspaceContextService, workingDirectory) {
10
10
  if (input.uri) {
11
11
  return ( URI.parse(input.uri));
12
12
  }
@@ -60,4 +60,4 @@ function errorResult(message) {
60
60
  return result;
61
61
  }
62
62
 
63
- export { errorResult, findLineNumber, findSymbolColumn, getChatPermissionLevelForToolInvocation, getSandboxPrecheckInputsForToolInvocation, resolveToolUri };
63
+ export { errorResult, findLineNumber, findSymbolColumn, getChatPermissionLevelForToolInvocation, getSandboxPrecheckInputsForToolInvocation, resolveSymbolToolFileUri };
@@ -21,7 +21,7 @@ import { ISearchService } from '@codingame/monaco-vscode-api/vscode/vs/workbench
21
21
  import { ToolDataSource } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService';
22
22
  import { ILanguageModelToolsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService.service';
23
23
  import { createToolSimpleTextResult } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/builtinTools/toolHelpers';
24
- import { resolveToolUri, errorResult, findLineNumber, findSymbolColumn } from './toolHelpers.js';
24
+ import { resolveSymbolToolFileUri, errorResult, findLineNumber, findSymbolColumn } from './toolHelpers.js';
25
25
 
26
26
  const UsagesToolId = "vscode_listCodeUsages";
27
27
  const BaseModelDescription = `Find all usages (references, definitions, and implementations) of a code symbol across the workspace. This tool locates where a symbol is referenced, defined, or implemented.
@@ -54,7 +54,7 @@ let UsagesTool = class UsagesTool extends Disposable {
54
54
  this._workspaceContextService = _workspaceContextService;
55
55
  }
56
56
  getToolData() {
57
- return this._buildToolData(StaticModelDescription, ( localize(7227, "Find references, definitions, and implementations of a symbol")));
57
+ return this._buildToolData(StaticModelDescription, ( localize(7749, "Find references, definitions, and implementations of a symbol")));
58
58
  }
59
59
  _buildToolData(modelDescription, userDescription) {
60
60
  return {
@@ -62,7 +62,7 @@ let UsagesTool = class UsagesTool extends Disposable {
62
62
  toolReferenceName: "usages",
63
63
  canBeReferencedInPrompt: false,
64
64
  icon: ThemeIcon.fromId(Codicon.references.id),
65
- displayName: ( localize(7228, "List Code Usages")),
65
+ displayName: ( localize(7750, "List Code Usages")),
66
66
  userDescription,
67
67
  modelDescription,
68
68
  source: ToolDataSource.Internal,
@@ -93,12 +93,12 @@ let UsagesTool = class UsagesTool extends Disposable {
93
93
  async prepareToolInvocation(context, _token) {
94
94
  const input = context.parameters;
95
95
  return {
96
- invocationMessage: ( localize(7229, "Analyzing usages of `{0}`", input.symbol))
96
+ invocationMessage: ( localize(7751, "Analyzing usages of `{0}`", input.symbol))
97
97
  };
98
98
  }
99
99
  async invoke(invocation, _countTokens, _progress, token) {
100
100
  const input = invocation.parameters;
101
- const uri = resolveToolUri(input, this._workspaceContextService, invocation.context?.workingDirectory);
101
+ const uri = resolveSymbolToolFileUri(input, this._workspaceContextService, invocation.context?.workingDirectory);
102
102
  if (!uri) {
103
103
  return errorResult(
104
104
  "Provide either \"uri\" (a full URI) or \"filePath\" (a workspace-relative path) to identify the file."
@@ -146,7 +146,7 @@ let UsagesTool = class UsagesTool extends Disposable {
146
146
  )]);
147
147
  if (references.length === 0) {
148
148
  const result = createToolSimpleTextResult(`No usages found for \`${input.symbol}\`.`);
149
- result.toolResultMessage = ( new MarkdownString(( localize(7230, "Analyzed usages of `{0}`, no results", input.symbol))));
149
+ result.toolResultMessage = ( new MarkdownString(( localize(7752, "Analyzed usages of `{0}`, no results", input.symbol))));
150
150
  return result;
151
151
  }
152
152
  const previews = await this._getLinePreviews(input.symbol, references, token);
@@ -167,8 +167,8 @@ let UsagesTool = class UsagesTool extends Disposable {
167
167
  }
168
168
  const text = lines.join("\n");
169
169
  const result = createToolSimpleTextResult(text);
170
- result.toolResultMessage = references.length === 1 ? ( new MarkdownString(( localize(7231, "Analyzed usages of `{0}`, 1 result", input.symbol)))) : ( new MarkdownString(( localize(
171
- 7232,
170
+ result.toolResultMessage = references.length === 1 ? ( new MarkdownString(( localize(7753, "Analyzed usages of `{0}`, 1 result", input.symbol)))) : ( new MarkdownString(( localize(
171
+ 7754,
172
172
  "Analyzed usages of `{0}`, {1} results",
173
173
  input.symbol,
174
174
  references.length
@@ -8,8 +8,8 @@ import { COPILOT_VENDOR_ID } from '@codingame/monaco-vscode-api/vscode/vs/workbe
8
8
  import { ILanguageModelsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModels.service';
9
9
  import { createDefaultModelArrays, DefaultModelContribution } from './defaultModelContribution.js';
10
10
 
11
- const defaultEntryLabel = ( localize(7233, "Default"));
12
- const defaultEntryDescription = ( localize(7234, "Use the built-in default utility model"));
11
+ const defaultEntryLabel = ( localize(7755, "Default"));
12
+ const defaultEntryDescription = ( localize(7756, "Use the default behavior for utility models"));
13
13
  const utilityArrays = createDefaultModelArrays(defaultEntryLabel, defaultEntryDescription);
14
14
  const utilitySmallArrays = createDefaultModelArrays(defaultEntryLabel, defaultEntryDescription);
15
15
  let UtilityModelContribution = class UtilityModelContribution extends DefaultModelContribution {
@@ -17,29 +17,29 @@ const chatViewsWelcomeJsonSchema = {
17
17
  properties: {
18
18
  icon: {
19
19
  type: "string",
20
- description: ( localize(7235, "The icon for the welcome message."))
20
+ description: ( localize(7757, "The icon for the welcome message."))
21
21
  },
22
22
  title: {
23
23
  type: "string",
24
- description: ( localize(7236, "The title of the welcome message."))
24
+ description: ( localize(7758, "The title of the welcome message."))
25
25
  },
26
26
  content: {
27
27
  type: "string",
28
28
  description: ( localize(
29
- 7237,
29
+ 7759,
30
30
  "The content of the welcome message. The first command link will be rendered as a button."
31
31
  ))
32
32
  },
33
33
  when: {
34
34
  type: "string",
35
- description: ( localize(7238, "Condition when the welcome message is shown."))
35
+ description: ( localize(7760, "Condition when the welcome message is shown."))
36
36
  }
37
37
  }
38
38
  };
39
39
  const chatViewsWelcomeExtensionPoint = ExtensionsRegistry.registerExtensionPoint({
40
40
  extensionPoint: "chatViewsWelcome",
41
41
  jsonSchema: {
42
- description: ( localize(7239, "Contributes a welcome message to a chat view")),
42
+ description: ( localize(7761, "Contributes a welcome message to a chat view")),
43
43
  type: "array",
44
44
  items: chatViewsWelcomeJsonSchema
45
45
  }