@codingame/monaco-vscode-chat-service-override 23.3.0 → 24.1.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 (273) hide show
  1. package/index.js +13 -10
  2. package/package.json +5 -41
  3. package/vscode/src/vs/platform/domWidget/browser/domWidget.d.ts +52 -0
  4. package/vscode/src/vs/platform/domWidget/browser/domWidget.js +53 -0
  5. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityActions.js +10 -10
  6. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.js +61 -50
  7. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.d.ts +18 -0
  8. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.js +152 -0
  9. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCodeblockActions.d.ts +2 -2
  10. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCodeblockActions.js +14 -14
  11. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContextActions.js +37 -28
  12. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.js +9 -9
  13. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.js +2 -2
  14. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatFileTreeActions.js +4 -4
  15. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatGettingStarted.d.ts +3 -5
  16. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatGettingStarted.js +7 -11
  17. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatImportExport.js +10 -10
  18. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatLanguageModelActions.js +12 -14
  19. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatMoveActions.js +21 -18
  20. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatNewActions.js +27 -18
  21. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPromptNavigationActions.js +4 -4
  22. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.d.ts +1 -1
  23. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +11 -11
  24. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatSessionActions.d.ts +6 -27
  25. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatSessionActions.js +44 -208
  26. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +17 -17
  27. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +17 -17
  28. package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.d.ts +1 -1
  29. package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.js +23 -24
  30. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.d.ts +1 -0
  31. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js +140 -0
  32. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.d.ts +85 -0
  33. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.js +358 -0
  34. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.d.ts +55 -0
  35. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +222 -0
  36. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.d.ts +37 -0
  37. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +241 -0
  38. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.d.ts +13 -0
  39. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.js +27 -0
  40. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsView.d.ts +11 -19
  41. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsView.js +67 -230
  42. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.d.ts +65 -33
  43. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +186 -62
  44. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsProvider.d.ts +23 -0
  45. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsProvider.js +140 -0
  46. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsview.css +2 -7
  47. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsviewer.css +115 -29
  48. package/vscode/src/vs/workbench/contrib/chat/browser/chat.contribution.js +389 -166
  49. package/vscode/src/vs/workbench/contrib/chat/browser/chatAccessibilityService.d.ts +9 -6
  50. package/vscode/src/vs/workbench/contrib/chat/browser/chatAccessibilityService.js +22 -16
  51. package/vscode/src/vs/workbench/contrib/chat/browser/chatAttachmentResolveService.d.ts +1 -1
  52. package/vscode/src/vs/workbench/contrib/chat/browser/chatAttachmentResolveService.js +8 -8
  53. package/vscode/src/vs/workbench/contrib/chat/browser/chatContentParts/chatMarkdownAnchorService.d.ts +1 -1
  54. package/vscode/src/vs/workbench/contrib/chat/browser/chatContextService.d.ts +10 -3
  55. package/vscode/src/vs/workbench/contrib/chat/browser/chatContextService.js +63 -3
  56. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimeline.d.ts +7 -3
  57. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimelineImpl.d.ts +14 -5
  58. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCheckpointTimelineImpl.js +173 -32
  59. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.d.ts +1 -0
  60. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.js +66 -17
  61. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.js +32 -29
  62. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.js +12 -12
  63. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.d.ts +4 -2
  64. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.js +9 -6
  65. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.d.ts +2 -2
  66. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.js +6 -4
  67. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.d.ts +4 -4
  68. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.js +8 -18
  69. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingOperations.d.ts +1 -0
  70. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingOperations.js +12 -1
  71. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.d.ts +5 -6
  72. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.js +15 -24
  73. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.d.ts +13 -11
  74. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.js +66 -50
  75. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSessionStorage.d.ts +3 -2
  76. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSessionStorage.js +6 -5
  77. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelChangeService.d.ts +3 -1
  78. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelChangeService.js +7 -0
  79. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.d.ts +2 -2
  80. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelContentProviders.js +6 -7
  81. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingModifiedNotebookSnapshot.d.ts +3 -3
  82. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingModifiedNotebookSnapshot.js +4 -4
  83. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookCellEntry.d.ts +2 -2
  84. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookCellEntry.js +1 -1
  85. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.d.ts +1 -1
  86. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.js +15 -4
  87. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/overlayToolbarDecorator.d.ts +1 -1
  88. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/overlayToolbarDecorator.js +3 -4
  89. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/simpleBrowserEditorOverlay.js +30 -37
  90. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditor.d.ts +13 -10
  91. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditor.js +23 -32
  92. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.js +8 -9
  93. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.d.ts +1 -1
  94. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.js +20 -19
  95. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.js +4 -4
  96. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.d.ts +47 -15
  97. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.js +270 -143
  98. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.d.ts +3 -2
  99. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.js +310 -170
  100. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatUsageWidget.js +10 -10
  101. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/media/chatModelsWidget.css +12 -2
  102. package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.d.ts +1 -1
  103. package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.js +4 -4
  104. package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.js +42 -42
  105. package/vscode/src/vs/workbench/contrib/chat/browser/chatQuick.d.ts +3 -1
  106. package/vscode/src/vs/workbench/contrib/chat/browser/chatQuick.js +35 -25
  107. package/vscode/src/vs/workbench/contrib/chat/browser/chatResponseAccessibleView.d.ts +1 -1
  108. package/vscode/src/vs/workbench/contrib/chat/browser/chatResponseAccessibleView.js +4 -4
  109. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/chatSessionsView.d.ts +1 -4
  110. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/chatSessionsView.js +22 -26
  111. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsTreeRenderer.d.ts +18 -14
  112. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsTreeRenderer.js +80 -72
  113. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsViewPane.d.ts +2 -8
  114. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/view/sessionsViewPane.js +48 -77
  115. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions.contribution.d.ts +16 -17
  116. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions.contribution.js +257 -77
  117. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.d.ts +55 -0
  118. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.js +34 -0
  119. package/vscode/src/vs/workbench/contrib/chat/browser/{chatSetup.d.ts → chatSetup/chatSetupContributions.d.ts} +4 -11
  120. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.js +622 -0
  121. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.d.ts +53 -0
  122. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.js +359 -0
  123. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.d.ts +89 -0
  124. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.js +667 -0
  125. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.d.ts +37 -0
  126. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.js +260 -0
  127. package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/chatSetup.css +4 -6
  128. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatus.d.ts +4 -0
  129. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatus.js +21 -0
  130. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.d.ts +55 -0
  131. package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatus.js → chatStatus/chatStatusDashboard.js} +193 -325
  132. package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatus.d.ts → chatStatus/chatStatusEntry.d.ts} +1 -1
  133. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.js +190 -0
  134. package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatusItemService.d.ts → chatStatus/chatStatusItemService.d.ts} +1 -1
  135. package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatStatus/media}/chatStatus.css +22 -1
  136. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatusWidget.d.ts +25 -0
  137. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatusWidget.js +108 -0
  138. package/vscode/src/vs/workbench/contrib/chat/browser/chatTerminalOutputAccessibleView.d.ts +10 -0
  139. package/vscode/src/vs/workbench/contrib/chat/browser/chatTerminalOutputAccessibleView.js +34 -0
  140. package/vscode/src/vs/workbench/contrib/chat/browser/chatVariables.js +1 -1
  141. package/vscode/src/vs/workbench/contrib/chat/browser/chatViewPane.d.ts +57 -18
  142. package/vscode/src/vs/workbench/contrib/chat/browser/chatViewPane.js +478 -146
  143. package/vscode/src/vs/workbench/contrib/chat/browser/chatViewTitleControl.d.ts +43 -0
  144. package/vscode/src/vs/workbench/contrib/chat/browser/chatViewTitleControl.js +204 -0
  145. package/vscode/src/vs/workbench/contrib/chat/browser/chatWidgetService.d.ts +44 -0
  146. package/vscode/src/vs/workbench/contrib/chat/browser/chatWidgetService.js +187 -0
  147. package/vscode/src/vs/workbench/contrib/chat/browser/codeBlockContextProviderService.d.ts +1 -1
  148. package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatInputEditorContrib.js +108 -62
  149. package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatInputEditorHover.d.ts +1 -1
  150. package/vscode/src/vs/workbench/contrib/chat/browser/contrib/chatInputEditorHover.js +3 -3
  151. package/vscode/src/vs/workbench/contrib/chat/browser/languageModelToolsConfirmationService.d.ts +1 -1
  152. package/vscode/src/vs/workbench/contrib/chat/browser/languageModelToolsConfirmationService.js +37 -32
  153. package/vscode/src/vs/workbench/contrib/chat/browser/languageModelToolsService.d.ts +37 -20
  154. package/vscode/src/vs/workbench/contrib/chat/browser/languageModelToolsService.js +232 -97
  155. package/vscode/src/vs/workbench/contrib/chat/browser/media/chatStatusWidget.css +57 -0
  156. package/vscode/src/vs/workbench/contrib/chat/browser/media/chatViewPane.css +142 -0
  157. package/vscode/src/vs/workbench/contrib/chat/browser/media/chatViewTitleControl.css +39 -0
  158. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/chatModeActions.js +51 -35
  159. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionContribution.js +1 -1
  160. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionOverlay.js +5 -4
  161. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptFileActions.js +2 -2
  162. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolsCodeLensProvider.js +5 -5
  163. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptUrlHandler.js +12 -12
  164. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.js +19 -21
  165. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.d.ts +1 -1
  166. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.js +8 -8
  167. package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +16 -16
  168. package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcomeHandler.js +6 -6
  169. package/vscode/src/vs/workbench/contrib/chat/common/chatCodeMapperService.d.ts +1 -1
  170. package/vscode/src/vs/workbench/contrib/chat/common/chatModelStore.d.ts +49 -0
  171. package/vscode/src/vs/workbench/contrib/chat/common/chatModelStore.js +100 -0
  172. package/vscode/src/vs/workbench/contrib/chat/common/chatProgressTypes/chatToolInvocation.d.ts +1 -0
  173. package/vscode/src/vs/workbench/contrib/chat/common/chatProgressTypes/chatToolInvocation.js +2 -1
  174. package/vscode/src/vs/workbench/contrib/chat/common/chatResponseResourceFileSystemProvider.js +3 -4
  175. package/vscode/src/vs/workbench/contrib/chat/common/chatServiceImpl.d.ts +41 -15
  176. package/vscode/src/vs/workbench/contrib/chat/common/chatServiceImpl.js +208 -162
  177. package/vscode/src/vs/workbench/contrib/chat/common/chatServiceTelemetry.d.ts +3 -3
  178. package/vscode/src/vs/workbench/contrib/chat/common/chatSessionStore.d.ts +15 -7
  179. package/vscode/src/vs/workbench/contrib/chat/common/chatSessionStore.js +61 -7
  180. package/vscode/src/vs/workbench/contrib/chat/common/chatSlashCommands.d.ts +3 -2
  181. package/vscode/src/vs/workbench/contrib/chat/common/chatSlashCommands.js +2 -2
  182. package/vscode/src/vs/workbench/contrib/chat/common/chatTodoListService.js +1 -1
  183. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/chatPromptFilesContribution.js +10 -10
  184. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/PromptHeaderDefinitionProvider.js +2 -2
  185. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptBodyAutocompletion.js +3 -3
  186. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.d.ts +5 -1
  187. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.js +60 -43
  188. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptDocumentSemanticTokensProvider.js +1 -1
  189. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.js +27 -4
  190. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.js +37 -47
  191. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.d.ts +5 -3
  192. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.js +120 -87
  193. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/promptFileContributions.js +1 -1
  194. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.d.ts +49 -42
  195. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.js +293 -187
  196. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.d.ts +17 -5
  197. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.js +43 -9
  198. package/vscode/src/vs/workbench/contrib/chat/common/tools/languageModelToolsContribution.d.ts +2 -0
  199. package/vscode/src/vs/workbench/contrib/chat/common/tools/languageModelToolsContribution.js +48 -29
  200. package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.d.ts +1 -1
  201. package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.js +2 -2
  202. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChat.contribution.js +8 -13
  203. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAccessibilityHelp.js +1 -1
  204. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAccessibleView.js +2 -2
  205. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.d.ts +3 -3
  206. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +36 -41
  207. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatNotebook.js +3 -3
  208. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookModifiedCellDecorator.d.ts +2 -2
  209. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookModifiedCellDecorator.js +2 -2
  210. package/vscode/src/vs/workbench/contrib/remoteCodingAgents/browser/remoteCodingAgents.contribution.js +7 -7
  211. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminal.chat.contribution.js +1 -1
  212. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibilityHelp.js +18 -18
  213. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibleView.js +1 -1
  214. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatActions.js +142 -38
  215. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatController.d.ts +1 -1
  216. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatController.js +3 -7
  217. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatEnabler.js +1 -1
  218. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.d.ts +19 -2
  219. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.js +78 -6
  220. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.d.ts +7 -11
  221. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +26 -44
  222. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/commandLineAutoApprover.js +3 -3
  223. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.d.ts +1 -1
  224. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.js +9 -0
  225. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.d.ts +0 -1
  226. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.js +23 -17
  227. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.d.ts +1 -1
  228. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/outputHelpers.js +4 -2
  229. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.d.ts +2 -0
  230. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +26 -5
  231. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.d.ts +3 -1
  232. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.js +32 -4
  233. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.js +15 -29
  234. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.js +10 -7
  235. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAnalyzer.d.ts +12 -0
  236. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.d.ts +3 -1
  237. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +38 -19
  238. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.d.ts +1 -0
  239. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +32 -7
  240. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.js +5 -4
  241. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.js +4 -3
  242. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.js +4 -3
  243. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.d.ts +1 -0
  244. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +128 -62
  245. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/types.d.ts +2 -2
  246. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.js +12 -2
  247. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +5 -2
  248. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +68 -22
  249. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.js +20 -22
  250. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.js +13 -12
  251. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.js +20 -19
  252. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.d.ts +1 -1
  253. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.js +1 -1
  254. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/terminalCommandArtifactCollector.d.ts +12 -0
  255. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/terminalCommandArtifactCollector.js +72 -0
  256. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/treeSitterCommandParser.d.ts +1 -2
  257. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/treeSitterCommandParser.js +5 -17
  258. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionViewModel.d.ts +0 -53
  259. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionViewModel.js +0 -154
  260. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.d.ts +0 -7
  261. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.js +0 -13
  262. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionTracker.d.ts +0 -25
  263. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionTracker.js +0 -135
  264. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/localChatSessionsProvider.d.ts +0 -35
  265. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/localChatSessionsProvider.js +0 -216
  266. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup.js +0 -1617
  267. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatCurrentLine.d.ts +0 -44
  268. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatCurrentLine.js +0 -313
  269. /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/apple-dark.svg +0 -0
  270. /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/apple-light.svg +0 -0
  271. /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/github.svg +0 -0
  272. /package/vscode/src/vs/workbench/contrib/chat/browser/{media → chatSetup/media}/google.svg +0 -0
  273. /package/vscode/src/vs/workbench/contrib/chat/browser/{chatStatusItemService.js → chatStatus/chatStatusItemService.js} +0 -0
@@ -1,7 +1,7 @@
1
1
 
2
2
  import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
3
3
  import { MarkdownString } from '@codingame/monaco-vscode-api/vscode/vs/base/common/htmlContent';
4
- import { Disposable, MutableDisposable, toDisposable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
4
+ import { Disposable, MutableDisposable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
5
5
  import '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/index';
6
6
  import { themeColorFromId } from '@codingame/monaco-vscode-api/vscode/vs/base/common/themables';
7
7
  import { URI } from '@codingame/monaco-vscode-api/vscode/vs/base/common/uri';
@@ -23,14 +23,18 @@ import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/quic
23
23
  import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/searchColors';
24
24
  import { IThemeService } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/themeService.service';
25
25
  import { IChatAgentService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatAgents.service';
26
- import { chatSlashCommandBackground, chatSlashCommandForeground } from '@codingame/monaco-vscode-a793b3ee-7ba9-5176-a019-30ec806fdd95-common/vscode/vs/workbench/contrib/chat/common/chatColors';
27
- import { ChatRequestTextPart, ChatRequestSlashPromptPart, ChatRequestAgentPart, ChatRequestAgentSubcommandPart, ChatRequestSlashCommandPart, ChatRequestToolPart, ChatRequestToolSetPart, ChatRequestDynamicVariablePart, chatAgentLeader, chatSubcommandLeader } from '@codingame/monaco-vscode-aac7027b-326c-513a-95a9-e4eedd151b38-common/vscode/vs/workbench/contrib/chat/common/chatParserTypes';
28
- import { ChatRequestParser } from '@codingame/monaco-vscode-bc6f260d-ec63-5c95-9446-1ca7d0872719-common/vscode/vs/workbench/contrib/chat/common/chatRequestParser';
26
+ import { chatSlashCommandBackground, chatSlashCommandForeground } from '@codingame/monaco-vscode-katex-common/vscode/vs/workbench/contrib/chat/common/chatColors';
27
+ import { ChatRequestTextPart, ChatRequestSlashPromptPart, ChatRequestAgentPart, ChatRequestAgentSubcommandPart, ChatRequestSlashCommandPart, ChatRequestToolPart, ChatRequestToolSetPart, ChatRequestDynamicVariablePart, chatAgentLeader, chatSubcommandLeader } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatParserTypes';
28
+ import { ChatRequestParser } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatRequestParser';
29
29
  import { IPromptsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/service/promptsService.service';
30
- import { ChatWidget } from '@codingame/monaco-vscode-a793b3ee-7ba9-5176-a019-30ec806fdd95-common/vscode/vs/workbench/contrib/chat/browser/chatWidget';
31
- import { dynamicVariableDecorationType } from '@codingame/monaco-vscode-9d2c06d1-1f89-51a5-9964-aa01fe50c198-common/vscode/vs/workbench/contrib/chat/browser/contrib/chatDynamicVariables';
30
+ import { ChatWidget } from '@codingame/monaco-vscode-katex-common/vscode/vs/workbench/contrib/chat/browser/chatWidget';
31
+ import { dynamicVariableDecorationType } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/contrib/chatDynamicVariables';
32
+ import { NativeEditContextRegistry } from '@codingame/monaco-vscode-api/vscode/vs/editor/browser/controller/editContext/native/nativeEditContextRegistry';
33
+ import { TextAreaEditContextRegistry } from '@codingame/monaco-vscode-api/vscode/vs/editor/browser/controller/editContext/textArea/textAreaEditContextRegistry';
34
+ import { ThrottledDelayer } from '@codingame/monaco-vscode-api/vscode/vs/base/common/async';
32
35
  import { autorun } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/reactions/autorun';
33
36
 
37
+ var InputEditorDecorations_1;
34
38
  const decorationDescription = 'chat';
35
39
  const placeholderDecorationType = 'chat-session-detail';
36
40
  const slashCommandTextDecorationType = 'chat-session-text';
@@ -41,7 +45,25 @@ function agentAndCommandToKey(agent, subcommand) {
41
45
  function isWhitespaceOrPromptPart(p) {
42
46
  return (p instanceof ChatRequestTextPart && !p.text.trim().length) || (p instanceof ChatRequestSlashPromptPart);
43
47
  }
48
+ function exactlyOneSpaceAfterPart(parsedRequest, part) {
49
+ const partIdx = parsedRequest.indexOf(part);
50
+ if (parsedRequest.length > partIdx + 2) {
51
+ return false;
52
+ }
53
+ const nextPart = parsedRequest[partIdx + 1];
54
+ return nextPart && nextPart instanceof ChatRequestTextPart && nextPart.text === ' ';
55
+ }
56
+ function getRangeForPlaceholder(part) {
57
+ return {
58
+ startLineNumber: part.editorRange.startLineNumber,
59
+ endLineNumber: part.editorRange.endLineNumber,
60
+ startColumn: part.editorRange.endColumn + 1,
61
+ endColumn: 1000
62
+ };
63
+ }
44
64
  let InputEditorDecorations = class InputEditorDecorations extends Disposable {
65
+ static { InputEditorDecorations_1 = this; }
66
+ static { this.UPDATE_DELAY = 200; }
45
67
  constructor(widget, codeEditorService, themeService, chatAgentService, labelService, promptsService) {
46
68
  super();
47
69
  this.widget = widget;
@@ -53,58 +75,54 @@ let InputEditorDecorations = class InputEditorDecorations extends Disposable {
53
75
  this.id = 'inputEditorDecorations';
54
76
  this.previouslyUsedAgents = ( new Set());
55
77
  this.viewModelDisposables = this._register(( new MutableDisposable()));
56
- this.codeEditorService.registerDecorationType(decorationDescription, placeholderDecorationType, {});
78
+ this.updateThrottle = this._register(( new ThrottledDelayer(InputEditorDecorations_1.UPDATE_DELAY)));
57
79
  this.registeredDecorationTypes();
58
- this.updateInputEditorDecorations();
59
- this._register(this.widget.inputEditor.onDidChangeModelContent(() => this.updateInputEditorDecorations()));
60
- this._register(this.widget.onDidChangeParsedInput(() => this.updateInputEditorDecorations()));
80
+ this.triggerInputEditorDecorationsUpdate();
81
+ this._register(this.widget.inputEditor.onDidChangeModelContent(() => this.triggerInputEditorDecorationsUpdate()));
82
+ this._register(this.widget.onDidChangeParsedInput(() => this.triggerInputEditorDecorationsUpdate()));
61
83
  this._register(this.widget.onDidChangeViewModel(() => {
62
84
  this.registerViewModelListeners();
63
85
  this.previouslyUsedAgents.clear();
64
- this.updateInputEditorDecorations();
86
+ this.triggerInputEditorDecorationsUpdate();
65
87
  }));
66
88
  this._register(this.widget.onDidSubmitAgent((e) => {
67
89
  this.previouslyUsedAgents.add(agentAndCommandToKey(e.agent, e.slashCommand?.name));
68
90
  }));
69
- this._register(this.chatAgentService.onDidChangeAgents(() => this.updateInputEditorDecorations()));
70
- this._register(this.promptsService.onDidChangeParsedPromptFilesCache(() => this.updateInputEditorDecorations()));
91
+ this._register(this.chatAgentService.onDidChangeAgents(() => this.triggerInputEditorDecorationsUpdate()));
92
+ this._register(this.promptsService.onDidChangeSlashCommands(() => this.triggerInputEditorDecorationsUpdate()));
71
93
  this._register(autorun(reader => {
72
94
  const currentMode = this.widget.input.currentModeObs.read(reader);
73
95
  if (currentMode) {
74
96
  currentMode.description.read(reader);
75
97
  }
76
- this.updateInputEditorDecorations();
98
+ this.triggerInputEditorDecorationsUpdate();
77
99
  }));
78
100
  this.registerViewModelListeners();
79
101
  }
80
102
  registerViewModelListeners() {
81
103
  this.viewModelDisposables.value = this.widget.viewModel?.onDidChange(e => {
82
104
  if (e?.kind === 'changePlaceholder' || e?.kind === 'initialize') {
83
- this.updateInputEditorDecorations();
105
+ this.triggerInputEditorDecorationsUpdate();
84
106
  }
85
107
  });
86
108
  }
87
109
  registeredDecorationTypes() {
88
- this.codeEditorService.registerDecorationType(decorationDescription, slashCommandTextDecorationType, {
110
+ this._register(this.codeEditorService.registerDecorationType(decorationDescription, placeholderDecorationType, {}));
111
+ this._register(this.codeEditorService.registerDecorationType(decorationDescription, slashCommandTextDecorationType, {
89
112
  color: themeColorFromId(chatSlashCommandForeground),
90
113
  backgroundColor: themeColorFromId(chatSlashCommandBackground),
91
114
  borderRadius: '3px'
92
- });
93
- this.codeEditorService.registerDecorationType(decorationDescription, variableTextDecorationType, {
115
+ }));
116
+ this._register(this.codeEditorService.registerDecorationType(decorationDescription, variableTextDecorationType, {
94
117
  color: themeColorFromId(chatSlashCommandForeground),
95
118
  backgroundColor: themeColorFromId(chatSlashCommandBackground),
96
119
  borderRadius: '3px'
97
- });
98
- this.codeEditorService.registerDecorationType(decorationDescription, dynamicVariableDecorationType, {
120
+ }));
121
+ this._register(this.codeEditorService.registerDecorationType(decorationDescription, dynamicVariableDecorationType, {
99
122
  color: themeColorFromId(chatSlashCommandForeground),
100
123
  backgroundColor: themeColorFromId(chatSlashCommandBackground),
101
124
  borderRadius: '3px',
102
125
  rangeBehavior: TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges
103
- });
104
- this._register(toDisposable(() => {
105
- this.codeEditorService.removeDecorationType(variableTextDecorationType);
106
- this.codeEditorService.removeDecorationType(dynamicVariableDecorationType);
107
- this.codeEditorService.removeDecorationType(slashCommandTextDecorationType);
108
126
  }));
109
127
  }
110
128
  getPlaceholderColor() {
@@ -112,15 +130,21 @@ let InputEditorDecorations = class InputEditorDecorations extends Disposable {
112
130
  const transparentForeground = theme.getColor(inputPlaceholderForeground);
113
131
  return transparentForeground?.toString();
114
132
  }
115
- async updateInputEditorDecorations() {
133
+ triggerInputEditorDecorationsUpdate() {
134
+ this.updateInputPlaceholderDecoration();
135
+ this.updateThrottle.trigger(token => this.updateAsyncInputEditorDecorations(token));
136
+ }
137
+ updateInputPlaceholderDecoration() {
116
138
  const inputValue = this.widget.inputEditor.getValue();
117
139
  const viewModel = this.widget.viewModel;
118
140
  if (!viewModel) {
141
+ this.updateAriaPlaceholder(undefined);
119
142
  return;
120
143
  }
121
144
  if (!inputValue) {
122
145
  const mode = this.widget.input.currentModeObs.get();
123
146
  const placeholder = mode.argumentHint?.get() ?? mode.description.get() ?? '';
147
+ const displayPlaceholder = viewModel.inputPlaceholder || placeholder;
124
148
  const decoration = [
125
149
  {
126
150
  range: {
@@ -131,40 +155,26 @@ let InputEditorDecorations = class InputEditorDecorations extends Disposable {
131
155
  },
132
156
  renderOptions: {
133
157
  after: {
134
- contentText: viewModel.inputPlaceholder || placeholder,
158
+ contentText: displayPlaceholder,
135
159
  color: this.getPlaceholderColor()
136
160
  }
137
161
  }
138
162
  }
139
163
  ];
164
+ this.updateAriaPlaceholder(displayPlaceholder || undefined);
140
165
  this.widget.inputEditor.setDecorationsByType(decorationDescription, placeholderDecorationType, decoration);
141
166
  return;
142
167
  }
168
+ this.updateAriaPlaceholder(undefined);
143
169
  const parsedRequest = this.widget.parsedInput.parts;
144
170
  let placeholderDecoration;
145
171
  const agentPart = parsedRequest.find((p) => p instanceof ChatRequestAgentPart);
146
172
  const agentSubcommandPart = parsedRequest.find((p) => p instanceof ChatRequestAgentSubcommandPart);
147
- const slashCommandPart = parsedRequest.find((p) => p instanceof ChatRequestSlashCommandPart);
148
- const slashPromptPart = parsedRequest.find((p) => p instanceof ChatRequestSlashPromptPart);
149
- const exactlyOneSpaceAfterPart = (part) => {
150
- const partIdx = parsedRequest.indexOf(part);
151
- if (parsedRequest.length > partIdx + 2) {
152
- return false;
153
- }
154
- const nextPart = parsedRequest[partIdx + 1];
155
- return nextPart && nextPart instanceof ChatRequestTextPart && nextPart.text === ' ';
156
- };
157
- const getRangeForPlaceholder = (part) => ({
158
- startLineNumber: part.editorRange.startLineNumber,
159
- endLineNumber: part.editorRange.endLineNumber,
160
- startColumn: part.editorRange.endColumn + 1,
161
- endColumn: 1000
162
- });
163
173
  const onlyAgentAndWhitespace = agentPart && parsedRequest.every(p => p instanceof ChatRequestTextPart && !p.text.trim().length || p instanceof ChatRequestAgentPart);
164
174
  if (onlyAgentAndWhitespace) {
165
175
  const isFollowupSlashCommand = ( this.previouslyUsedAgents.has(agentAndCommandToKey(agentPart.agent, undefined)));
166
176
  const shouldRenderFollowupPlaceholder = isFollowupSlashCommand && agentPart.agent.metadata.followupPlaceholder;
167
- if (agentPart.agent.description && exactlyOneSpaceAfterPart(agentPart)) {
177
+ if (agentPart.agent.description && exactlyOneSpaceAfterPart(parsedRequest, agentPart)) {
168
178
  placeholderDecoration = [{
169
179
  range: getRangeForPlaceholder(agentPart),
170
180
  renderOptions: {
@@ -180,7 +190,7 @@ let InputEditorDecorations = class InputEditorDecorations extends Disposable {
180
190
  if (onlyAgentAndAgentCommandAndWhitespace) {
181
191
  const isFollowupSlashCommand = ( this.previouslyUsedAgents.has(agentAndCommandToKey(agentPart.agent, agentSubcommandPart.command.name)));
182
192
  const shouldRenderFollowupPlaceholder = isFollowupSlashCommand && agentSubcommandPart.command.followupPlaceholder;
183
- if (agentSubcommandPart?.command.description && exactlyOneSpaceAfterPart(agentSubcommandPart)) {
193
+ if (agentSubcommandPart?.command.description && exactlyOneSpaceAfterPart(parsedRequest, agentSubcommandPart)) {
184
194
  placeholderDecoration = [{
185
195
  range: getRangeForPlaceholder(agentSubcommandPart),
186
196
  renderOptions: {
@@ -194,7 +204,7 @@ let InputEditorDecorations = class InputEditorDecorations extends Disposable {
194
204
  }
195
205
  const onlyAgentCommandAndWhitespace = agentSubcommandPart && parsedRequest.every(p => p instanceof ChatRequestTextPart && !p.text.trim().length || p instanceof ChatRequestAgentSubcommandPart);
196
206
  if (onlyAgentCommandAndWhitespace) {
197
- if (agentSubcommandPart?.command.description && exactlyOneSpaceAfterPart(agentSubcommandPart)) {
207
+ if (agentSubcommandPart?.command.description && exactlyOneSpaceAfterPart(parsedRequest, agentSubcommandPart)) {
198
208
  placeholderDecoration = [{
199
209
  range: getRangeForPlaceholder(agentSubcommandPart),
200
210
  renderOptions: {
@@ -206,23 +216,35 @@ let InputEditorDecorations = class InputEditorDecorations extends Disposable {
206
216
  }];
207
217
  }
208
218
  }
209
- const onlyPromptCommandAndWhitespace = slashPromptPart && parsedRequest.every(isWhitespaceOrPromptPart);
210
- if (onlyPromptCommandAndWhitespace && exactlyOneSpaceAfterPart(slashPromptPart)) {
211
- const promptFile = this.promptsService.resolvePromptSlashCommandFromCache(slashPromptPart.slashPromptCommand.command);
212
- const description = promptFile?.header?.argumentHint ?? promptFile?.header?.description;
213
- if (description) {
214
- placeholderDecoration = [{
215
- range: getRangeForPlaceholder(slashPromptPart),
216
- renderOptions: {
217
- after: {
218
- contentText: description,
219
- color: this.getPlaceholderColor(),
219
+ this.widget.inputEditor.setDecorationsByType(decorationDescription, placeholderDecorationType, placeholderDecoration ?? []);
220
+ }
221
+ async updateAsyncInputEditorDecorations(token) {
222
+ const parsedRequest = this.widget.parsedInput.parts;
223
+ const agentPart = parsedRequest.find((p) => p instanceof ChatRequestAgentPart);
224
+ const agentSubcommandPart = parsedRequest.find((p) => p instanceof ChatRequestAgentSubcommandPart);
225
+ const slashCommandPart = parsedRequest.find((p) => p instanceof ChatRequestSlashCommandPart);
226
+ const slashPromptPart = parsedRequest.find((p) => p instanceof ChatRequestSlashPromptPart);
227
+ const promptSlashCommand = slashPromptPart ? await this.promptsService.resolvePromptSlashCommand(slashPromptPart.name, token) : undefined;
228
+ if (token.isCancellationRequested) {
229
+ return;
230
+ }
231
+ if (slashPromptPart && promptSlashCommand) {
232
+ const onlyPromptCommandAndWhitespace = slashPromptPart && parsedRequest.every(isWhitespaceOrPromptPart);
233
+ if (onlyPromptCommandAndWhitespace && exactlyOneSpaceAfterPart(parsedRequest, slashPromptPart) && promptSlashCommand) {
234
+ const description = promptSlashCommand.argumentHint ?? promptSlashCommand.description;
235
+ if (description) {
236
+ this.widget.inputEditor.setDecorationsByType(decorationDescription, placeholderDecorationType, [{
237
+ range: getRangeForPlaceholder(slashPromptPart),
238
+ renderOptions: {
239
+ after: {
240
+ contentText: description,
241
+ color: this.getPlaceholderColor(),
242
+ }
220
243
  }
221
- }
222
- }];
244
+ }]);
245
+ }
223
246
  }
224
247
  }
225
- this.widget.inputEditor.setDecorationsByType(decorationDescription, placeholderDecorationType, placeholderDecoration ?? []);
226
248
  const textDecorations = [];
227
249
  if (agentPart) {
228
250
  textDecorations.push({ range: agentPart.editorRange });
@@ -233,7 +255,7 @@ let InputEditorDecorations = class InputEditorDecorations extends Disposable {
233
255
  if (slashCommandPart) {
234
256
  textDecorations.push({ range: slashCommandPart.editorRange });
235
257
  }
236
- if (slashPromptPart) {
258
+ if (slashPromptPart && promptSlashCommand) {
237
259
  textDecorations.push({ range: slashPromptPart.editorRange });
238
260
  }
239
261
  this.widget.inputEditor.setDecorationsByType(decorationDescription, slashCommandTextDecorationType, textDecorations);
@@ -251,8 +273,32 @@ let InputEditorDecorations = class InputEditorDecorations extends Disposable {
251
273
  }
252
274
  this.widget.inputEditor.setDecorationsByType(decorationDescription, variableTextDecorationType, varDecorations);
253
275
  }
276
+ updateAriaPlaceholder(value) {
277
+ const nativeEditContext = NativeEditContextRegistry.get(this.widget.inputEditor.getId());
278
+ if (nativeEditContext) {
279
+ const domNode = nativeEditContext.domNode.domNode;
280
+ if (value && value.trim().length) {
281
+ domNode.setAttribute('aria-placeholder', value);
282
+ }
283
+ else {
284
+ domNode.removeAttribute('aria-placeholder');
285
+ }
286
+ }
287
+ else {
288
+ const textAreaEditContext = TextAreaEditContextRegistry.get(this.widget.inputEditor.getId());
289
+ if (textAreaEditContext) {
290
+ const textArea = textAreaEditContext.textArea.domNode;
291
+ if (value && value.trim().length) {
292
+ textArea.setAttribute('aria-placeholder', value);
293
+ }
294
+ else {
295
+ textArea.removeAttribute('aria-placeholder');
296
+ }
297
+ }
298
+ }
299
+ }
254
300
  };
255
- InputEditorDecorations = ( __decorate([
301
+ InputEditorDecorations = InputEditorDecorations_1 = ( __decorate([
256
302
  ( __param(1, ICodeEditorService)),
257
303
  ( __param(2, IThemeService)),
258
304
  ( __param(3, IChatAgentService)),
@@ -5,7 +5,7 @@ import { HoverAnchor, IEditorHoverParticipant, IEditorHoverRenderContext, IHover
5
5
  import { ICommandService } from "@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service";
6
6
  import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
7
7
  import { IChatWidgetService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service";
8
- import { IChatAgentData } from "@codingame/monaco-vscode-aac7027b-326c-513a-95a9-e4eedd151b38-common/vscode/vs/workbench/contrib/chat/common/chatAgents";
8
+ import { IChatAgentData } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatAgents";
9
9
  export declare class ChatAgentHoverParticipant implements IEditorHoverParticipant<ChatAgentHoverPart> {
10
10
  private readonly editor;
11
11
  private readonly instantiationService;
@@ -6,9 +6,9 @@ import { RenderedHoverParts, HoverAnchorType, HoverParticipantRegistry } from '@
6
6
  import { ICommandService } from '@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service';
7
7
  import { IInstantiationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
8
8
  import { IChatWidgetService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service';
9
- import { ChatAgentHover, getChatAgentHoverOptions } from '@codingame/monaco-vscode-a793b3ee-7ba9-5176-a019-30ec806fdd95-common/vscode/vs/workbench/contrib/chat/browser/chatAgentHover';
9
+ import { ChatAgentHover, getChatAgentHoverOptions } from '@codingame/monaco-vscode-katex-common/vscode/vs/workbench/contrib/chat/browser/chatAgentHover';
10
10
  import { ChatEditorHoverWrapper } from './editorHoverWrapper.js';
11
- import { extractAgentAndCommand } from '@codingame/monaco-vscode-aac7027b-326c-513a-95a9-e4eedd151b38-common/vscode/vs/workbench/contrib/chat/common/chatParserTypes';
11
+ import { extractAgentAndCommand } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatParserTypes';
12
12
  import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
13
13
 
14
14
  let ChatAgentHoverParticipant = class ChatAgentHoverParticipant {
@@ -58,7 +58,7 @@ let ChatAgentHoverParticipant = class ChatAgentHoverParticipant {
58
58
  return ( new RenderedHoverParts([renderedHoverPart]));
59
59
  }
60
60
  getAccessibleContent(hoverPart) {
61
- return localize(5588, 'There is a chat agent hover part here.');
61
+ return localize(5694, 'There is a chat agent hover part here.');
62
62
  }
63
63
  };
64
64
  ChatAgentHoverParticipant = ( __decorate([
@@ -20,7 +20,7 @@ export declare class LanguageModelToolsConfirmationService extends Disposable im
20
20
  getPreConfirmActions(ref: ILanguageModelToolConfirmationRef): ILanguageModelToolConfirmationActions[];
21
21
  getPostConfirmActions(ref: ILanguageModelToolConfirmationRef): ILanguageModelToolConfirmationActions[];
22
22
  registerConfirmationContribution(toolName: string, contribution: ILanguageModelToolConfirmationContribution): IDisposable;
23
- manageConfirmationPreferences(tools: Readonly<IToolData>[], options?: {
23
+ manageConfirmationPreferences(tools: readonly IToolData[], options?: {
24
24
  defaultScope?: "workspace" | "profile" | "session";
25
25
  }): void;
26
26
  resetToolAutoConfirmation(): void;
@@ -24,8 +24,8 @@ import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/quic
24
24
  import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/searchColors';
25
25
  import { ToolConfirmKind } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService';
26
26
 
27
- const RUN_WITHOUT_APPROVAL = ( localize(5591, "without approval"));
28
- const CONTINUE_WITHOUT_REVIEWING_RESULTS = ( localize(5592, "without reviewing result"));
27
+ const RUN_WITHOUT_APPROVAL = ( localize(5697, "without approval"));
28
+ const CONTINUE_WITHOUT_REVIEWING_RESULTS = ( localize(5698, "without reviewing result"));
29
29
  class GenericConfirmStore extends Disposable {
30
30
  constructor(_storageKey, _instantiationService) {
31
31
  super();
@@ -222,23 +222,23 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
222
222
  return actions;
223
223
  }
224
224
  actions.push({
225
- label: ( localize(5593, 'Allow in this Session')),
226
- detail: ( localize(5594, 'Allow this tool to run in this session without confirmation.')),
225
+ label: ( localize(5699, 'Allow in this Session')),
226
+ detail: ( localize(5700, 'Allow this tool to run in this session without confirmation.')),
227
227
  divider: !!actions.length,
228
228
  select: async () => {
229
229
  this._preExecutionToolConfirmStore.setAutoConfirmation(ref.toolId, 'session');
230
230
  return true;
231
231
  }
232
232
  }, {
233
- label: ( localize(5595, 'Allow in this Workspace')),
234
- detail: ( localize(5596, 'Allow this tool to run in this workspace without confirmation.')),
233
+ label: ( localize(5701, 'Allow in this Workspace')),
234
+ detail: ( localize(5702, 'Allow this tool to run in this workspace without confirmation.')),
235
235
  select: async () => {
236
236
  this._preExecutionToolConfirmStore.setAutoConfirmation(ref.toolId, 'workspace');
237
237
  return true;
238
238
  }
239
239
  }, {
240
- label: ( localize(5597, 'Always Allow')),
241
- detail: ( localize(5598, 'Always allow this tool to run without confirmation.')),
240
+ label: ( localize(5703, 'Always Allow')),
241
+ detail: ( localize(5704, 'Always allow this tool to run without confirmation.')),
242
242
  select: async () => {
243
243
  this._preExecutionToolConfirmStore.setAutoConfirmation(ref.toolId, 'profile');
244
244
  return true;
@@ -247,9 +247,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
247
247
  if (ref.source.type === 'mcp') {
248
248
  const { serverLabel, definitionId } = ref.source;
249
249
  actions.push({
250
- label: ( localize(5599, 'Allow Tools from {0} in this Session', serverLabel)),
250
+ label: ( localize(5705, 'Allow Tools from {0} in this Session', serverLabel)),
251
251
  detail: ( localize(
252
- 5600,
252
+ 5706,
253
253
  'Allow all tools from this server to run in this session without confirmation.'
254
254
  )),
255
255
  divider: true,
@@ -258,9 +258,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
258
258
  return true;
259
259
  }
260
260
  }, {
261
- label: ( localize(5601, 'Allow Tools from {0} in this Workspace', serverLabel)),
261
+ label: ( localize(5707, 'Allow Tools from {0} in this Workspace', serverLabel)),
262
262
  detail: ( localize(
263
- 5602,
263
+ 5708,
264
264
  'Allow all tools from this server to run in this workspace without confirmation.'
265
265
  )),
266
266
  select: async () => {
@@ -268,9 +268,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
268
268
  return true;
269
269
  }
270
270
  }, {
271
- label: ( localize(5603, 'Always Allow Tools from {0}', serverLabel)),
271
+ label: ( localize(5709, 'Always Allow Tools from {0}', serverLabel)),
272
272
  detail: ( localize(
273
- 5604,
273
+ 5710,
274
274
  'Always allow all tools from this server to run without confirmation.'
275
275
  )),
276
276
  select: async () => {
@@ -291,9 +291,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
291
291
  return actions;
292
292
  }
293
293
  actions.push({
294
- label: ( localize(5605, 'Allow Without Review in this Session')),
294
+ label: ( localize(5711, 'Allow Without Review in this Session')),
295
295
  detail: ( localize(
296
- 5606,
296
+ 5712,
297
297
  'Allow results from this tool to be sent without confirmation in this session.'
298
298
  )),
299
299
  divider: !!actions.length,
@@ -302,9 +302,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
302
302
  return true;
303
303
  }
304
304
  }, {
305
- label: ( localize(5607, 'Allow Without Review in this Workspace')),
305
+ label: ( localize(5713, 'Allow Without Review in this Workspace')),
306
306
  detail: ( localize(
307
- 5608,
307
+ 5714,
308
308
  'Allow results from this tool to be sent without confirmation in this workspace.'
309
309
  )),
310
310
  select: async () => {
@@ -312,9 +312,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
312
312
  return true;
313
313
  }
314
314
  }, {
315
- label: ( localize(5609, 'Always Allow Without Review')),
315
+ label: ( localize(5715, 'Always Allow Without Review')),
316
316
  detail: ( localize(
317
- 5610,
317
+ 5716,
318
318
  'Always allow results from this tool to be sent without confirmation.'
319
319
  )),
320
320
  select: async () => {
@@ -325,9 +325,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
325
325
  if (ref.source.type === 'mcp') {
326
326
  const { serverLabel, definitionId } = ref.source;
327
327
  actions.push({
328
- label: ( localize(5611, 'Allow Tools from {0} Without Review in this Session', serverLabel)),
328
+ label: ( localize(5717, 'Allow Tools from {0} Without Review in this Session', serverLabel)),
329
329
  detail: ( localize(
330
- 5612,
330
+ 5718,
331
331
  'Allow results from all tools from this server to be sent without confirmation in this session.'
332
332
  )),
333
333
  divider: true,
@@ -336,9 +336,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
336
336
  return true;
337
337
  }
338
338
  }, {
339
- label: ( localize(5613, 'Allow Tools from {0} Without Review in this Workspace', serverLabel)),
339
+ label: ( localize(5719, 'Allow Tools from {0} Without Review in this Workspace', serverLabel)),
340
340
  detail: ( localize(
341
- 5614,
341
+ 5720,
342
342
  'Allow results from all tools from this server to be sent without confirmation in this workspace.'
343
343
  )),
344
344
  select: async () => {
@@ -346,9 +346,9 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
346
346
  return true;
347
347
  }
348
348
  }, {
349
- label: ( localize(5615, 'Always Allow Tools from {0} Without Review', serverLabel)),
349
+ label: ( localize(5721, 'Always Allow Tools from {0} Without Review', serverLabel)),
350
350
  detail: ( localize(
351
- 5616,
351
+ 5722,
352
352
  'Always allow results from all tools from this server to be sent without confirmation.'
353
353
  )),
354
354
  select: async () => {
@@ -482,7 +482,7 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
482
482
  type: 'server-post',
483
483
  serverId,
484
484
  iconClass: ThemeIcon.asClassName(Codicon.play),
485
- label: ( localize(5617, "Continue without reviewing any tool results")),
485
+ label: ( localize(5723, "Continue without reviewing any tool results")),
486
486
  checked: serverPostConfirmed
487
487
  });
488
488
  }
@@ -491,7 +491,7 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
491
491
  type: 'server-pre',
492
492
  serverId,
493
493
  iconClass: ThemeIcon.asClassName(Codicon.play),
494
- label: ( localize(5618, "Run any tool without approval")),
494
+ label: ( localize(5724, "Run any tool without approval")),
495
495
  checked: serverPreConfirmed
496
496
  });
497
497
  }
@@ -595,7 +595,7 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
595
595
  quickTree.sortByLabel = false;
596
596
  if (currentScope !== 'session') {
597
597
  const scopeToggle = disposables.add(( new Toggle({
598
- title: ( localize(5619, "Configure for this workspace only")),
598
+ title: ( localize(5725, "Configure for this workspace only")),
599
599
  icon: Codicon.folder,
600
600
  isChecked: currentScope === 'workspace',
601
601
  inputActiveOptionBorder: asCssVariable(inputActiveOptionBorder),
@@ -611,12 +611,12 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
611
611
  }
612
612
  const updatePlaceholder = () => {
613
613
  if (currentScope === 'session') {
614
- quickTree.placeholder = ( localize(5620, "Configure session tool approvals"));
614
+ quickTree.placeholder = ( localize(5726, "Configure session tool approvals"));
615
615
  }
616
616
  else {
617
617
  quickTree.placeholder = currentScope === 'workspace'
618
- ? ( localize(5621, "Configure workspace tool approvals"))
619
- : ( localize(5622, "Configure global tool approvals"));
618
+ ? ( localize(5727, "Configure workspace tool approvals"))
619
+ : ( localize(5728, "Configure global tool approvals"));
620
620
  }
621
621
  };
622
622
  updatePlaceholder();
@@ -663,6 +663,11 @@ let LanguageModelToolsConfirmationService = class LanguageModelToolsConfirmation
663
663
  }
664
664
  }));
665
665
  disposables.add(quickTree.onDidAccept(() => {
666
+ for (const item of quickTree.activeItems) {
667
+ if (item.type === 'manage') {
668
+ item.onDidOpen?.();
669
+ }
670
+ }
666
671
  quickTree.hide();
667
672
  }));
668
673
  disposables.add(quickTree.onDidHide(() => {