@codingame/monaco-vscode-chat-service-override 26.2.2 → 27.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 (316) hide show
  1. package/index.js +31 -1
  2. package/package.json +5 -5
  3. package/vscode/src/vs/platform/browserElements/common/browserElements.d.ts +15 -0
  4. package/vscode/src/vs/sessions/contrib/agentFeedback/browser/agentFeedbackService.d.ts +53 -0
  5. package/vscode/src/vs/sessions/contrib/agentFeedback/browser/agentFeedbackService.js +219 -0
  6. package/vscode/src/vs/sessions/contrib/chat/browser/aiCustomizationWorkspaceService.d.ts +39 -0
  7. package/vscode/src/vs/sessions/contrib/chat/browser/aiCustomizationWorkspaceService.js +83 -0
  8. package/vscode/src/vs/sessions/contrib/chat/browser/newSession.d.ts +123 -0
  9. package/vscode/src/vs/sessions/contrib/chat/browser/newSession.js +274 -0
  10. package/vscode/src/vs/sessions/contrib/chat/browser/sessionsConfigurationService.d.ts +71 -0
  11. package/vscode/src/vs/sessions/contrib/chat/browser/sessionsConfigurationService.js +284 -0
  12. package/vscode/src/vs/sessions/contrib/sessions/browser/sessionsManagementService.d.ts +79 -0
  13. package/vscode/src/vs/sessions/contrib/sessions/browser/sessionsManagementService.js +378 -0
  14. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityService.d.ts +1 -2
  15. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityService.js +27 -40
  16. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatResponseAccessibleView.d.ts +9 -3
  17. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatResponseAccessibleView.js +74 -18
  18. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityActions.d.ts +1 -0
  19. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityActions.js +54 -8
  20. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.js +87 -53
  21. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.js +1 -1
  22. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCodeblockActions.js +71 -15
  23. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContextActions.js +43 -21
  24. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.js +3 -3
  25. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.js +22 -3
  26. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatFileTreeActions.js +2 -2
  27. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatForkActions.d.ts +1 -0
  28. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatForkActions.js +154 -0
  29. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatImportExport.js +6 -8
  30. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatLanguageModelActions.js +13 -13
  31. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatMoveActions.js +6 -6
  32. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatNewActions.js +53 -43
  33. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatOpenAgentDebugPanelAction.d.ts +4 -0
  34. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatOpenAgentDebugPanelAction.js +84 -0
  35. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPluginActions.d.ts +1 -0
  36. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPluginActions.js +33 -0
  37. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPromptNavigationActions.js +2 -2
  38. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQueueActions.js +15 -29
  39. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +8 -8
  40. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.d.ts +13 -0
  41. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +16 -16
  42. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +12 -12
  43. package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.js +18 -18
  44. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginRepositoryService.d.ts +33 -0
  45. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginRepositoryService.js +204 -0
  46. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginsView.d.ts +77 -0
  47. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginsView.js +541 -0
  48. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js +10 -11
  49. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.js +70 -65
  50. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.d.ts +7 -1
  51. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.js +27 -18
  52. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.d.ts +1 -0
  53. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.js +4 -2
  54. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjection.js +1 -1
  55. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionActions.js +5 -5
  56. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionService.d.ts +2 -0
  57. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionService.js +90 -51
  58. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionsExperiments.contribution.js +20 -5
  59. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentTitleBarStatusWidget.d.ts +3 -1
  60. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentTitleBarStatusWidget.js +43 -27
  61. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/media/agenttitlebarstatuswidget.css +7 -2
  62. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccess.d.ts +3 -1
  63. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccess.js +84 -22
  64. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccessActions.js +4 -4
  65. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/{localAgentSessionsProvider.d.ts → localAgentSessionsController.d.ts} +7 -4
  66. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/{localAgentSessionsProvider.js → localAgentSessionsController.js} +24 -17
  67. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationDebugPanel.d.ts +23 -0
  68. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationDebugPanel.js +171 -0
  69. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationIcons.d.ts +48 -0
  70. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationIcons.js +19 -0
  71. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidget.d.ts +181 -0
  72. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidget.js +943 -0
  73. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.contribution.d.ts +1 -0
  74. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.contribution.js +248 -0
  75. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.d.ts +57 -0
  76. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.js +27 -0
  77. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditor.d.ts +118 -0
  78. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditor.js +727 -0
  79. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditorInput.d.ts +22 -0
  80. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditorInput.js +38 -0
  81. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWorkspaceService.d.ts +1 -0
  82. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWorkspaceService.js +72 -0
  83. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationCreatorService.d.ts +45 -0
  84. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationCreatorService.js +165 -0
  85. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/mcpListWidget.d.ts +75 -0
  86. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/mcpListWidget.js +623 -0
  87. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/media/aiCustomizationManagement.css +858 -0
  88. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentResolveService.d.ts +2 -0
  89. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentResolveService.js +30 -1
  90. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgetRegistry.d.ts +32 -0
  91. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgetRegistry.js +26 -0
  92. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatVariables.js +19 -3
  93. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/simpleBrowserEditorOverlay.js +36 -26
  94. package/vscode/src/vs/workbench/contrib/chat/browser/chat.contribution.js +529 -363
  95. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatCustomizationDiscoveryRenderer.d.ts +18 -0
  96. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatCustomizationDiscoveryRenderer.js +419 -0
  97. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCollapsible.d.ts +12 -0
  98. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCollapsible.js +46 -0
  99. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugDetailPanel.d.ts +34 -0
  100. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugDetailPanel.js +198 -0
  101. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditor.d.ts +55 -0
  102. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditor.js +305 -0
  103. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditorInput.d.ts +23 -0
  104. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditorInput.js +64 -0
  105. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventDetailRenderer.d.ts +5 -0
  106. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventDetailRenderer.js +84 -0
  107. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventList.d.ts +27 -0
  108. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventList.js +110 -0
  109. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFilters.d.ts +34 -0
  110. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFilters.js +111 -0
  111. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowChartView.d.ts +71 -0
  112. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowChartView.js +611 -0
  113. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowGraph.d.ts +125 -0
  114. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowGraph.js +504 -0
  115. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowLayout.d.ts +10 -0
  116. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowLayout.js +914 -0
  117. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHomeView.d.ts +19 -0
  118. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHomeView.js +128 -0
  119. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugLogsView.d.ts +58 -0
  120. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugLogsView.js +429 -0
  121. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugMessageContentRenderer.d.ts +31 -0
  122. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugMessageContentRenderer.js +113 -0
  123. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugModelTurnContentRenderer.d.ts +14 -0
  124. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugModelTurnContentRenderer.js +126 -0
  125. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugOverviewView.d.ts +38 -0
  126. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugOverviewView.js +279 -0
  127. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugToolCallContentRenderer.d.ts +18 -0
  128. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugToolCallContentRenderer.js +122 -0
  129. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugTypes.d.ts +45 -0
  130. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugTypes.js +85 -0
  131. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/media/chatDebug.css +781 -0
  132. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.js +1 -1
  133. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationModelManager.js +5 -22
  134. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.js +2 -2
  135. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.js +1 -1
  136. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.js +1 -1
  137. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.js +3 -3
  138. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.js +3 -3
  139. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingTextModelChangeService.js +2 -1
  140. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.js +1 -1
  141. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.js +12 -12
  142. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.d.ts +1 -0
  143. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.js +16 -15
  144. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.js +4 -4
  145. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.js +2 -2
  146. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.js +63 -76
  147. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatUsageWidget.js +26 -15
  148. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/media/chatManagementEditor.css +2 -2
  149. package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.js +3 -3
  150. package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.js +30 -30
  151. package/vscode/src/vs/workbench/contrib/chat/browser/chatRepoInfo.d.ts +15 -7
  152. package/vscode/src/vs/workbench/contrib/chat/browser/chatRepoInfo.js +40 -413
  153. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.d.ts +10 -0
  154. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.js +38 -6
  155. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.d.ts +5 -1
  156. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.js +56 -46
  157. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.js +15 -11
  158. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupGrowthSession.d.ts +52 -0
  159. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupGrowthSession.js +138 -0
  160. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.d.ts +11 -1
  161. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.js +166 -41
  162. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.d.ts +6 -0
  163. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.js +37 -23
  164. package/vscode/src/vs/workbench/contrib/chat/browser/chatSlashCommands.d.ts +15 -0
  165. package/vscode/src/vs/workbench/contrib/chat/browser/chatSlashCommands.js +351 -0
  166. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.d.ts +1 -0
  167. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.js +118 -63
  168. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.js +12 -12
  169. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/media/chatStatus.css +28 -0
  170. package/vscode/src/vs/workbench/contrib/chat/browser/chatTipService.d.ts +182 -13
  171. package/vscode/src/vs/workbench/contrib/chat/browser/chatTipService.js +892 -41
  172. package/vscode/src/vs/workbench/contrib/chat/browser/chatWindowNotifier.d.ts +5 -1
  173. package/vscode/src/vs/workbench/contrib/chat/browser/chatWindowNotifier.js +55 -25
  174. package/vscode/src/vs/workbench/contrib/chat/browser/contextContrib/chatContextService.js +28 -19
  175. package/vscode/src/vs/workbench/contrib/chat/browser/createSlashCommandsUsageTracker.d.ts +14 -0
  176. package/vscode/src/vs/workbench/contrib/chat/browser/createSlashCommandsUsageTracker.js +62 -0
  177. package/vscode/src/vs/workbench/contrib/chat/browser/defaultModelContribution.d.ts +36 -0
  178. package/vscode/src/vs/workbench/contrib/chat/browser/defaultModelContribution.js +110 -0
  179. package/vscode/src/vs/workbench/contrib/chat/browser/exploreAgentDefaultModel.d.ts +10 -0
  180. package/vscode/src/vs/workbench/contrib/chat/browser/exploreAgentDefaultModel.js +39 -0
  181. package/vscode/src/vs/workbench/contrib/chat/browser/languageModelsConfigurationService.d.ts +3 -3
  182. package/vscode/src/vs/workbench/contrib/chat/browser/languageModelsConfigurationService.js +6 -6
  183. package/vscode/src/vs/workbench/contrib/chat/browser/planAgentDefaultModel.d.ts +10 -0
  184. package/vscode/src/vs/workbench/contrib/chat/browser/planAgentDefaultModel.js +39 -0
  185. package/vscode/src/vs/workbench/contrib/chat/browser/pluginInstallService.d.ts +27 -0
  186. package/vscode/src/vs/workbench/contrib/chat/browser/pluginInstallService.js +102 -0
  187. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/chatModeActions.js +6 -6
  188. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookActions.d.ts +16 -1
  189. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookActions.js +69 -47
  190. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookUtils.js +2 -41
  191. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionOverlay.js +2 -2
  192. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolsCodeLensProvider.js +7 -7
  193. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptUrlHandler.js +8 -8
  194. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.d.ts +4 -0
  195. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.js +8 -8
  196. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.js +3 -3
  197. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/skillActions.d.ts +4 -0
  198. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/skillActions.js +4 -4
  199. package/vscode/src/vs/workbench/contrib/chat/browser/promptsDebugContribution.d.ts +22 -0
  200. package/vscode/src/vs/workbench/contrib/chat/browser/promptsDebugContribution.js +76 -0
  201. package/vscode/src/vs/workbench/contrib/chat/browser/sessionResourceMatching.d.ts +5 -0
  202. package/vscode/src/vs/workbench/contrib/chat/browser/sessionResourceMatching.js +30 -0
  203. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsConfirmationService.js +43 -31
  204. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsService.js +67 -42
  205. package/vscode/src/vs/workbench/contrib/chat/browser/tools/renameTool.d.ts +31 -0
  206. package/vscode/src/vs/workbench/contrib/chat/browser/tools/renameTool.js +242 -0
  207. package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolHelpers.d.ts +34 -0
  208. package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolHelpers.js +45 -0
  209. package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +13 -13
  210. package/vscode/src/vs/workbench/contrib/chat/browser/tools/usagesTool.d.ts +33 -0
  211. package/vscode/src/vs/workbench/contrib/chat/browser/tools/usagesTool.js +311 -0
  212. package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcomeHandler.js +5 -5
  213. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidgetService.d.ts +4 -0
  214. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidgetService.js +10 -1
  215. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatQueuePickerActionItem.js +10 -10
  216. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatStatusWidget.js +8 -9
  217. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.js +64 -26
  218. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorContrib.js +4 -2
  219. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorHover.js +1 -1
  220. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/chatQuick.js +2 -2
  221. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/editor/chatEditor.d.ts +15 -4
  222. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/editor/chatEditor.js +42 -8
  223. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.d.ts +8 -1
  224. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.js +58 -31
  225. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewTitleControl.js +6 -5
  226. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatViewPane.css +8 -20
  227. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatViewTitleControl.css +15 -6
  228. package/vscode/src/vs/workbench/contrib/chat/common/aiCustomizationWorkspaceService.d.ts +39 -0
  229. package/vscode/src/vs/workbench/contrib/chat/common/aiCustomizationWorkspaceService.js +27 -0
  230. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugService.d.ts +190 -0
  231. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugService.js +11 -0
  232. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugServiceImpl.d.ts +36 -0
  233. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugServiceImpl.js +188 -0
  234. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.d.ts +18 -8
  235. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.js +192 -85
  236. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceTelemetry.d.ts +2 -1
  237. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceTelemetry.js +2 -1
  238. package/vscode/src/vs/workbench/contrib/chat/common/model/chatModelStore.d.ts +5 -6
  239. package/vscode/src/vs/workbench/contrib/chat/common/model/chatModelStore.js +16 -8
  240. package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionStore.d.ts +8 -4
  241. package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionStore.js +111 -7
  242. package/vscode/src/vs/workbench/contrib/chat/common/participants/chatSlashCommands.d.ts +2 -0
  243. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginService.d.ts +52 -0
  244. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginService.js +29 -0
  245. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginServiceImpl.d.ts +73 -0
  246. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginServiceImpl.js +622 -0
  247. package/vscode/src/vs/workbench/contrib/chat/common/plugins/pluginMarketplaceService.d.ts +64 -0
  248. package/vscode/src/vs/workbench/contrib/chat/common/plugins/pluginMarketplaceService.js +478 -0
  249. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/chatPromptFilesContribution.js +35 -16
  250. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookCompatibility.js +1 -30
  251. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookCopilotCliCompat.d.ts +0 -5
  252. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookCopilotCliCompat.js +2 -8
  253. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/PromptHeaderDefinitionProvider.js +1 -1
  254. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.js +8 -8
  255. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.js +9 -9
  256. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.js +23 -22
  257. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.d.ts +44 -14
  258. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.js +345 -113
  259. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.d.ts +14 -1
  260. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.js +34 -24
  261. package/vscode/src/vs/workbench/contrib/chat/common/tools/chatTodoListService.d.ts +3 -0
  262. package/vscode/src/vs/workbench/contrib/chat/common/tools/chatTodoListService.js +13 -0
  263. package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.js +1 -1
  264. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChat.contribution.js +11 -5
  265. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.d.ts +23 -0
  266. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +248 -24
  267. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatDefaultModel.d.ts +6 -11
  268. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatDefaultModel.js +18 -81
  269. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.js +2 -3
  270. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.js +10 -10
  271. package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.js +14 -14
  272. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.js +1 -1
  273. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.js +10 -10
  274. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebook.chat.contribution.js +6 -6
  275. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatContext.js +1 -1
  276. package/vscode/src/vs/workbench/contrib/remoteCodingAgents/browser/remoteCodingAgents.contribution.js +7 -7
  277. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/media/terminalChatWidget.css +6 -2
  278. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibilityHelp.js +16 -16
  279. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatActions.js +35 -26
  280. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.d.ts +0 -1
  281. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.js +1 -5
  282. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +3 -3
  283. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +6 -6
  284. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.d.ts +4 -1
  285. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.js +13 -11
  286. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.js +3 -3
  287. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.js +3 -1
  288. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/awaitTerminalTool.js +3 -3
  289. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.js +1 -1
  290. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +12 -12
  291. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +2 -2
  292. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.js +3 -3
  293. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.js +3 -3
  294. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.js +3 -3
  295. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/killTerminalTool.js +3 -3
  296. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.d.ts +9 -0
  297. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +280 -65
  298. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/types.d.ts +3 -1
  299. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/outputAnalyzer.d.ts +8 -0
  300. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.js +2 -10
  301. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +1 -0
  302. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +47 -19
  303. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sandboxOutputAnalyzer.d.ts +8 -0
  304. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sandboxOutputAnalyzer.js +31 -0
  305. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.js +14 -14
  306. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.js +7 -7
  307. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.js +14 -14
  308. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.js +1 -1
  309. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.d.ts +6 -1
  310. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.js +38 -16
  311. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCustomizationDiagnosticsAction.d.ts +0 -72
  312. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCustomizationDiagnosticsAction.js +0 -587
  313. package/vscode/src/vs/workbench/contrib/chat/common/model/chatProgressTypes/chatToolInvocation.d.ts +0 -71
  314. package/vscode/src/vs/workbench/contrib/chat/common/model/chatProgressTypes/chatToolInvocation.js +0 -293
  315. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/utils.d.ts +0 -2
  316. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/utils.js +0 -31
@@ -6,6 +6,7 @@ import { ITelemetryService } from '@codingame/monaco-vscode-api/vscode/vs/platfo
6
6
  import { ChatAgentVoteDirection, ChatCopyKind } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService/chatService';
7
7
  import { isImageVariableEntry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/attachments/chatVariableEntries';
8
8
  import { ILanguageModelsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModels.service';
9
+ import { chatSessionResourceToId } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/model/chatUri';
9
10
 
10
11
  let ChatServiceTelemetry = class ChatServiceTelemetry {
11
12
  constructor(telemetryService) {
@@ -120,7 +121,7 @@ let ChatRequestTelemetry = class ChatRequestTelemetry {
120
121
  agent: detectedAgent?.id ?? this.opts.agent.id,
121
122
  agentExtensionId: detectedAgent?.extensionId.value ?? this.opts.agent.extensionId.value,
122
123
  slashCommand: this.opts.agentSlashCommandPart ? this.opts.agentSlashCommandPart.command.name : this.opts.commandPart?.slashCommand.command,
123
- chatSessionId: this.opts.sessionId,
124
+ chatSessionId: chatSessionResourceToId(this.opts.sessionResource),
124
125
  enableCommandDetection: this.opts.enableCommandDetection,
125
126
  isParticipantDetected: !!detectedAgent,
126
127
  location: this.opts.location,
@@ -1,4 +1,4 @@
1
- import { IDisposable, IReference, ReferenceCollection } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
1
+ import { Disposable, IReference } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
2
2
  import { URI } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri";
3
3
  import { ILogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service";
4
4
  import { ChatAgentLocation } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants";
@@ -8,7 +8,6 @@ export interface IStartSessionProps {
8
8
  readonly initialData?: ISerializedChatDataReference;
9
9
  readonly location: ChatAgentLocation;
10
10
  readonly sessionResource: URI;
11
- readonly sessionId?: string;
12
11
  readonly canUseTools: boolean;
13
12
  readonly transferEditingSession?: IChatEditingSession;
14
13
  readonly disableBackgroundKeepAlive?: boolean;
@@ -18,10 +17,10 @@ export interface ChatModelStoreDelegate {
18
17
  createModel: (props: IStartSessionProps) => ChatModel;
19
18
  willDisposeModel: (model: ChatModel) => Promise<void>;
20
19
  }
21
- export declare class ChatModelStore extends ReferenceCollection<ChatModel> implements IDisposable {
20
+ export declare class ChatModelStore extends Disposable {
22
21
  private readonly delegate;
23
22
  private readonly logService;
24
- private readonly _store;
23
+ private readonly _refCollection;
25
24
  private readonly _models;
26
25
  private readonly _modelsToDispose;
27
26
  private readonly _pendingDisposals;
@@ -39,8 +38,8 @@ export declare class ChatModelStore extends ReferenceCollection<ChatModel> imple
39
38
  has(uri: URI): boolean;
40
39
  acquireExisting(uri: URI): IReference<ChatModel> | undefined;
41
40
  acquireOrCreate(props: IStartSessionProps): IReference<ChatModel>;
42
- protected createReferencedObject(key: string, props?: IStartSessionProps): ChatModel;
43
- protected destroyReferencedObject(key: string, object: ChatModel): void;
41
+ private createReferencedObject;
42
+ private destroyReferencedObject;
44
43
  private doDestroyReferencedObject;
45
44
  /**
46
45
  * For test use only
@@ -1,24 +1,32 @@
1
1
 
2
2
  import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
3
3
  import { Emitter } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event';
4
- import { ReferenceCollection, DisposableStore } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
4
+ import { Disposable, ReferenceCollection } 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 { ILogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service';
7
7
  import { ObservableMap } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/map';
8
8
 
9
- let ChatModelStore = class ChatModelStore extends ReferenceCollection {
9
+ let ChatModelStore = class ChatModelStore extends Disposable {
10
10
  constructor(delegate, logService) {
11
11
  super();
12
12
  this.delegate = delegate;
13
13
  this.logService = logService;
14
- this._store = ( new DisposableStore());
15
14
  this._models = ( new ObservableMap());
16
15
  this._modelsToDispose = ( new Set());
17
16
  this._pendingDisposals = ( new Set());
18
- this._onDidDisposeModel = this._store.add(( new Emitter()));
17
+ this._onDidDisposeModel = this._register(( new Emitter()));
19
18
  this.onDidDisposeModel = this._onDidDisposeModel.event;
20
- this._onDidCreateModel = this._store.add(( new Emitter()));
19
+ this._onDidCreateModel = this._register(( new Emitter()));
21
20
  this.onDidCreateModel = this._onDidCreateModel.event;
21
+ const self = this;
22
+ this._refCollection = new (class extends ReferenceCollection {
23
+ createReferencedObject(key, props) {
24
+ return self.createReferencedObject(key, props);
25
+ }
26
+ destroyReferencedObject(key, object) {
27
+ return self.destroyReferencedObject(key, object);
28
+ }
29
+ })();
22
30
  }
23
31
  get observable() {
24
32
  return this._models.observable;
@@ -37,10 +45,10 @@ let ChatModelStore = class ChatModelStore extends ReferenceCollection {
37
45
  if (!( this._models.has(key))) {
38
46
  return undefined;
39
47
  }
40
- return this.acquire(key);
48
+ return this._refCollection.acquire(key);
41
49
  }
42
50
  acquireOrCreate(props) {
43
- return this.acquire(this.toKey(props.sessionResource), props);
51
+ return this._refCollection.acquire(this.toKey(props.sessionResource), props);
44
52
  }
45
53
  createReferencedObject(key, props) {
46
54
  this._modelsToDispose.delete(key);
@@ -90,7 +98,7 @@ let ChatModelStore = class ChatModelStore extends ReferenceCollection {
90
98
  return ( uri.toString());
91
99
  }
92
100
  dispose() {
93
- this._store.dispose();
101
+ super.dispose();
94
102
  this._models.forEach(model => model.dispose());
95
103
  }
96
104
  };
@@ -9,6 +9,7 @@ import { ITelemetryService } from "@codingame/monaco-vscode-api/vscode/vs/platfo
9
9
  import { IUserDataProfilesService } from "@codingame/monaco-vscode-api/vscode/vs/platform/userDataProfile/common/userDataProfile.service";
10
10
  import { IWorkspaceContextService } from "@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace.service";
11
11
  import { ILifecycleService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/lifecycle/common/lifecycle.service";
12
+ import { IWorkspaceEditingService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/workspaces/common/workspaceEditing.service";
12
13
  import { IChatSessionStats, IChatSessionTiming, ResponseModelState } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService/chatService";
13
14
  import { ChatAgentLocation } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants";
14
15
  import { ChatModel, ISerializableChatData, ISerializableChatsData, ISerializedChatDataReference } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/model/chatModel";
@@ -22,13 +23,16 @@ export declare class ChatSessionStore extends Disposable {
22
23
  private readonly lifecycleService;
23
24
  private readonly userDataProfilesService;
24
25
  private readonly configurationService;
25
- private readonly storageRoot;
26
+ private readonly workspaceEditingService;
27
+ private storageRoot;
26
28
  private readonly previousEmptyWindowStorageRoot;
27
29
  private readonly transferredSessionStorageRoot;
28
30
  private readonly storeQueue;
29
31
  private storeTask;
30
32
  private shuttingDown;
31
- constructor(fileService: IFileService, environmentService: IEnvironmentService, logService: ILogService, workspaceContextService: IWorkspaceContextService, telemetryService: ITelemetryService, storageService: IStorageService, lifecycleService: ILifecycleService, userDataProfilesService: IUserDataProfilesService, configurationService: IConfigurationService);
33
+ constructor(fileService: IFileService, environmentService: IEnvironmentService, logService: ILogService, workspaceContextService: IWorkspaceContextService, telemetryService: ITelemetryService, storageService: IStorageService, lifecycleService: ILifecycleService, userDataProfilesService: IUserDataProfilesService, configurationService: IConfigurationService, workspaceEditingService: IWorkspaceEditingService);
34
+ private handleWorkspaceTransition;
35
+ private migrateSessionsToNewWorkspace;
32
36
  storeSessions(sessions: ChatModel[]): Promise<void>;
33
37
  storeSessionsMetadataOnly(sessions: ChatModel[]): Promise<void>;
34
38
  storeTransferSession(transferData: IChatTransfer, session: ChatModel): Promise<void>;
@@ -68,11 +72,11 @@ export interface IChatSessionEntryMetadata {
68
72
  sessionId: string;
69
73
  title: string;
70
74
  lastMessageDate: number;
71
- timing?: IChatSessionTiming;
75
+ timing: IChatSessionTiming;
72
76
  initialLocation?: ChatAgentLocation;
73
77
  hasPendingEdits?: boolean;
74
78
  stats?: IChatSessionStats;
75
- lastResponseState?: ResponseModelState;
79
+ lastResponseState: ResponseModelState;
76
80
  /**
77
81
  * This only exists because the migrated data from the storage service had empty sessions persisted, and it's impossible to know which ones are
78
82
  * currently in use. Now, `clearSession` deletes empty sessions, so old ones shouldn't take up space in the store anymore, but we still need to
@@ -18,8 +18,10 @@ import { StorageScope, StorageTarget } from '@codingame/monaco-vscode-api/vscode
18
18
  import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service';
19
19
  import { ITelemetryService } from '@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service';
20
20
  import { IUserDataProfilesService } from '@codingame/monaco-vscode-api/vscode/vs/platform/userDataProfile/common/userDataProfile.service';
21
+ import { isEmptyWorkspaceIdentifier } from '@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace';
21
22
  import { IWorkspaceContextService } from '@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace.service';
22
23
  import { ILifecycleService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/lifecycle/common/lifecycle.service';
24
+ import { IWorkspaceEditingService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/workspaces/common/workspaceEditing.service';
23
25
  import { awaitStatsForSession } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chat';
24
26
  import { ResponseModelState } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService/chatService';
25
27
  import { ModifiedFileEntryState } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/editing/chatEditingService';
@@ -44,7 +46,8 @@ let ChatSessionStore = class ChatSessionStore extends Disposable {
44
46
  storageService,
45
47
  lifecycleService,
46
48
  userDataProfilesService,
47
- configurationService
49
+ configurationService,
50
+ workspaceEditingService
48
51
  ) {
49
52
  super();
50
53
  this.fileService = fileService;
@@ -56,6 +59,7 @@ let ChatSessionStore = class ChatSessionStore extends Disposable {
56
59
  this.lifecycleService = lifecycleService;
57
60
  this.userDataProfilesService = userDataProfilesService;
58
61
  this.configurationService = configurationService;
62
+ this.workspaceEditingService = workspaceEditingService;
59
63
  this.storeQueue = ( new Sequencer());
60
64
  this.shuttingDown = false;
61
65
  const workspace = this.workspaceContextService.getWorkspace();
@@ -74,6 +78,12 @@ let ChatSessionStore = class ChatSessionStore extends Disposable {
74
78
  this.userDataProfilesService.defaultProfile.globalStorageHome,
75
79
  "transferredChatSessions"
76
80
  );
81
+ this._register(this.workspaceEditingService.onDidEnterWorkspace(event => {
82
+ const transitionPromise = this.storeQueue.queue(
83
+ () => this.handleWorkspaceTransition(event.oldWorkspace, event.newWorkspace)
84
+ );
85
+ event.join(transitionPromise);
86
+ }));
77
87
  this._register(this.lifecycleService.onWillShutdown(e => {
78
88
  this.shuttingDown = true;
79
89
  if (!this.storeTask) {
@@ -81,10 +91,96 @@ let ChatSessionStore = class ChatSessionStore extends Disposable {
81
91
  }
82
92
  e.join(this.storeTask, {
83
93
  id: "join.chatSessionStore",
84
- label: ( localize(6352, "Saving chat history"))
94
+ label: ( localize(6904, "Saving chat history"))
85
95
  });
86
96
  }));
87
97
  }
98
+ async handleWorkspaceTransition(oldWorkspace, newWorkspace) {
99
+ const wasEmptyWindow = isEmptyWorkspaceIdentifier(oldWorkspace);
100
+ const isNewWorkspaceEmpty = isEmptyWorkspaceIdentifier(newWorkspace);
101
+ const oldWorkspaceId = oldWorkspace.id;
102
+ const newWorkspaceId = newWorkspace.id;
103
+ this.logService.info(
104
+ `ChatSessionStore: Workspace transition from ${oldWorkspaceId} to ${newWorkspaceId}`
105
+ );
106
+ const oldStorageRoot = wasEmptyWindow ? joinPath(
107
+ this.userDataProfilesService.defaultProfile.globalStorageHome,
108
+ "emptyWindowChatSessions"
109
+ ) : joinPath(
110
+ this.environmentService.workspaceStorageHome,
111
+ oldWorkspaceId,
112
+ "chatSessions"
113
+ );
114
+ const newStorageRoot = isNewWorkspaceEmpty ? joinPath(
115
+ this.userDataProfilesService.defaultProfile.globalStorageHome,
116
+ "emptyWindowChatSessions"
117
+ ) : joinPath(
118
+ this.environmentService.workspaceStorageHome,
119
+ newWorkspaceId,
120
+ "chatSessions"
121
+ );
122
+ if (( oldStorageRoot.toString()) === ( newStorageRoot.toString())) {
123
+ this.storageRoot = newStorageRoot;
124
+ return;
125
+ }
126
+ this.storageRoot = newStorageRoot;
127
+ await this.migrateSessionsToNewWorkspace(oldStorageRoot, wasEmptyWindow, isNewWorkspaceEmpty);
128
+ }
129
+ async migrateSessionsToNewWorkspace(oldStorageRoot, wasEmptyWindow, isNewWorkspaceEmpty) {
130
+ try {
131
+ const oldStorageExists = await this.fileService.exists(oldStorageRoot);
132
+ if (!oldStorageExists) {
133
+ this.logService.info(
134
+ `ChatSessionStore: Old storage location does not exist, skipping migration`
135
+ );
136
+ return;
137
+ }
138
+ const oldDirectory = await this.fileService.resolve(oldStorageRoot);
139
+ if (!oldDirectory.children) {
140
+ this.logService.info(
141
+ `ChatSessionStore: No children in old storage location, skipping migration`
142
+ );
143
+ return;
144
+ }
145
+ this.logService.info(
146
+ `ChatSessionStore: Found ${oldDirectory.children.length} files in old storage location`
147
+ );
148
+ let migratedCount = 0;
149
+ for (const child of oldDirectory.children) {
150
+ if (!child.isDirectory && (child.name.endsWith(".json") || child.name.endsWith(".jsonl"))) {
151
+ const oldFilePath = child.resource;
152
+ const newFilePath = joinPath(this.storageRoot, child.name);
153
+ try {
154
+ await this.fileService.copy(oldFilePath, newFilePath, false);
155
+ migratedCount++;
156
+ } catch (e) {
157
+ if (toFileOperationResult(e) === FileOperationResult.FILE_MOVE_CONFLICT) {
158
+ this.logService.trace(
159
+ `ChatSessionStore: Session file ${child.name} already exists at target, skipping`
160
+ );
161
+ } else {
162
+ this.reportError("sessionMigration", `Error migrating chat session file ${child.name}`, e);
163
+ }
164
+ }
165
+ }
166
+ }
167
+ this.logService.info(
168
+ `ChatSessionStore: Copied ${migratedCount} chat session files from ${wasEmptyWindow ? "empty window" : ( oldStorageRoot.toString())} to ${isNewWorkspaceEmpty ? "empty window" : ( this.storageRoot.toString())} (originals preserved at old location)`
169
+ );
170
+ this.indexCache = undefined;
171
+ try {
172
+ await this.flushIndex();
173
+ } catch (e) {
174
+ this.reportError(
175
+ "migrateWorkspace",
176
+ "Error flushing chat session index after workspace migration",
177
+ e
178
+ );
179
+ }
180
+ } catch (e) {
181
+ this.reportError("migrateWorkspace", "Error migrating chat sessions to new workspace", e);
182
+ }
183
+ }
88
184
  async storeSessions(sessions) {
89
185
  if (this.shuttingDown) {
90
186
  return;
@@ -257,7 +353,8 @@ let ChatSessionStore = class ChatSessionStore extends Disposable {
257
353
  } else {
258
354
  await this.fileService.writeFile(storageLocation.flat, VSBuffer.fromString(JSON.stringify(session)));
259
355
  }
260
- index.entries[session.sessionId] = await getSessionMetadata(session);
356
+ const newMetadata = await getSessionMetadata(session);
357
+ index.entries[session.sessionId] = newMetadata;
261
358
  } catch (e) {
262
359
  this.reportError("sessionWrite", "Error writing chat session", e);
263
360
  }
@@ -389,15 +486,22 @@ let ChatSessionStore = class ChatSessionStore extends Disposable {
389
486
  entries: {}
390
487
  };
391
488
  }
392
- return this.indexCache;
393
489
  } catch (e) {
394
490
  this.reportError("invalidIndexJSON", `Index corrupt: ${data}`, e);
395
491
  this.indexCache = {
396
492
  version: 1,
397
493
  entries: {}
398
494
  };
399
- return this.indexCache;
400
495
  }
496
+ for (const entry of ( Object.values(this.indexCache.entries))) {
497
+ entry.timing ??= {
498
+ created: entry.lastMessageDate,
499
+ lastRequestStarted: undefined,
500
+ lastRequestEnded: entry.lastMessageDate
501
+ };
502
+ entry.lastResponseState ??= entry.lastResponseState === ResponseModelState.Pending || entry.lastResponseState === ResponseModelState.NeedsInput ? ResponseModelState.Complete : entry.lastResponseState || ResponseModelState.Complete;
503
+ }
504
+ return this.indexCache;
401
505
  }
402
506
  async getIndex() {
403
507
  return this.storeQueue.queue(async () => {
@@ -534,7 +638,7 @@ let ChatSessionStore = class ChatSessionStore extends Disposable {
534
638
  return this.storageRoot;
535
639
  }
536
640
  };
537
- ChatSessionStore = ChatSessionStore_1 = ( __decorate([( __param(0, IFileService)), ( __param(1, IEnvironmentService)), ( __param(2, ILogService)), ( __param(3, IWorkspaceContextService)), ( __param(4, ITelemetryService)), ( __param(5, IStorageService)), ( __param(6, ILifecycleService)), ( __param(7, IUserDataProfilesService)), ( __param(8, IConfigurationService))], ChatSessionStore));
641
+ ChatSessionStore = ChatSessionStore_1 = ( __decorate([( __param(0, IFileService)), ( __param(1, IEnvironmentService)), ( __param(2, ILogService)), ( __param(3, IWorkspaceContextService)), ( __param(4, ITelemetryService)), ( __param(5, IStorageService)), ( __param(6, ILifecycleService)), ( __param(7, IUserDataProfilesService)), ( __param(8, IConfigurationService)), ( __param(9, IWorkspaceEditingService))], ChatSessionStore));
538
642
  function isChatSessionEntryMetadata(obj) {
539
643
  return (!!obj && typeof obj === "object" && typeof obj.sessionId === "string" && typeof obj.title === "string" && typeof obj.lastMessageDate === "number");
540
644
  }
@@ -575,7 +679,7 @@ async function getSessionMetadata(session) {
575
679
  }
576
680
  return {
577
681
  sessionId: session.sessionId,
578
- title: title || ( localize(6353, "New Chat")),
682
+ title: title || ( localize(6905, "New Chat")),
579
683
  lastMessageDate,
580
684
  timing,
581
685
  initialLocation: session.initialLocation,
@@ -7,6 +7,7 @@ import { IChatFollowup, IChatProgress, IChatResponseProgressFileTreeData } from
7
7
  import { IExtensionService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions.service";
8
8
  import { ChatAgentLocation, ChatModeKind } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants";
9
9
  import { URI } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri";
10
+ import { Target } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/service/promptsService";
10
11
  import { IChatSlashCommandService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/participants/chatSlashCommands.service";
11
12
  export interface IChatSlashData {
12
13
  command: string;
@@ -27,6 +28,7 @@ export interface IChatSlashData {
27
28
  silent?: boolean;
28
29
  locations: ChatAgentLocation[];
29
30
  modes?: ChatModeKind[];
31
+ target?: Target;
30
32
  }
31
33
  export interface IChatSlashFragment {
32
34
  content: string | {
@@ -0,0 +1,52 @@
1
+ import { IDisposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
2
+ import { IObservable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/observable";
3
+ import { URI } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri";
4
+ import { SyncDescriptor0 } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/descriptors";
5
+ import { IMcpServerConfiguration } from "@codingame/monaco-vscode-api/vscode/vs/platform/mcp/common/mcpPlatformTypes";
6
+ import { HookType, IHookCommand } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/hookSchema";
7
+ import { IMarketplacePlugin } from "./pluginMarketplaceService.js";
8
+ export interface IAgentPluginHook {
9
+ readonly type: HookType;
10
+ readonly hooks: readonly IHookCommand[];
11
+ readonly originalId: string;
12
+ }
13
+ export interface IAgentPluginCommand {
14
+ readonly uri: URI;
15
+ readonly name: string;
16
+ }
17
+ export interface IAgentPluginSkill {
18
+ readonly uri: URI;
19
+ readonly name: string;
20
+ }
21
+ export interface IAgentPluginAgent {
22
+ readonly uri: URI;
23
+ readonly name: string;
24
+ }
25
+ export interface IAgentPluginMcpServerDefinition {
26
+ readonly name: string;
27
+ readonly configuration: IMcpServerConfiguration;
28
+ }
29
+ export interface IAgentPlugin {
30
+ readonly uri: URI;
31
+ readonly enabled: IObservable<boolean>;
32
+ setEnabled(enabled: boolean): void;
33
+ readonly hooks: IObservable<readonly IAgentPluginHook[]>;
34
+ readonly commands: IObservable<readonly IAgentPluginCommand[]>;
35
+ readonly skills: IObservable<readonly IAgentPluginSkill[]>;
36
+ readonly agents: IObservable<readonly IAgentPluginAgent[]>;
37
+ readonly mcpServerDefinitions: IObservable<readonly IAgentPluginMcpServerDefinition[]>;
38
+ /** Set when the plugin was installed from a marketplace repository. */
39
+ readonly fromMarketplace?: IMarketplacePlugin;
40
+ }
41
+ export interface IAgentPluginDiscovery extends IDisposable {
42
+ readonly plugins: IObservable<readonly IAgentPlugin[]>;
43
+ start(): void;
44
+ }
45
+ export declare function getCanonicalPluginCommandId(plugin: IAgentPlugin, commandName: string): string;
46
+ declare class AgentPluginDiscoveryRegistry {
47
+ private readonly _discovery;
48
+ register(descriptor: SyncDescriptor0<IAgentPluginDiscovery>): void;
49
+ getAll(): readonly SyncDescriptor0<IAgentPluginDiscovery>[];
50
+ }
51
+ export declare const agentPluginDiscoveryRegistry: AgentPluginDiscoveryRegistry;
52
+ export {};
@@ -0,0 +1,29 @@
1
+
2
+ import { basename } from '@codingame/monaco-vscode-api/vscode/vs/base/common/resources';
3
+
4
+ function getCanonicalPluginCommandId(plugin, commandName) {
5
+ const pluginSegment = basename(plugin.uri);
6
+ const prefix = normalizePluginToken(pluginSegment);
7
+ const normalizedCommand = normalizePluginToken(commandName);
8
+ if (normalizedCommand.startsWith(`${prefix}:`)) {
9
+ return normalizedCommand;
10
+ }
11
+ return `${prefix}:${normalizedCommand}`;
12
+ }
13
+ function normalizePluginToken(value) {
14
+ return value.trim().toLowerCase().replace(/\s+/g, "-").replace(/[^a-z0-9_.:-]/g, "-").replace(/-+/g, "-").replace(/^[-:.]+|[-:.]+$/g, "");
15
+ }
16
+ class AgentPluginDiscoveryRegistry {
17
+ constructor() {
18
+ this._discovery = [];
19
+ }
20
+ register(descriptor) {
21
+ this._discovery.push(descriptor);
22
+ }
23
+ getAll() {
24
+ return this._discovery;
25
+ }
26
+ }
27
+ const agentPluginDiscoveryRegistry = ( new AgentPluginDiscoveryRegistry());
28
+
29
+ export { agentPluginDiscoveryRegistry, getCanonicalPluginCommandId };
@@ -0,0 +1,73 @@
1
+ import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
2
+ import { IObservable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/observable";
3
+ import { URI } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri";
4
+ import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service";
5
+ import { IFileService } from "@codingame/monaco-vscode-api/vscode/vs/platform/files/common/files.service";
6
+ import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
7
+ import { ILogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service";
8
+ import { IWorkspaceContextService } from "@codingame/monaco-vscode-api/vscode/vs/platform/workspace/common/workspace.service";
9
+ import { IPathService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/path/common/pathService.service";
10
+ import { IAgentPlugin, IAgentPluginDiscovery } from "./agentPluginService.js";
11
+ import { IAgentPluginService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/plugins/agentPluginService.service";
12
+ import { IPluginMarketplaceService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/plugins/pluginMarketplaceService.service";
13
+ /**
14
+ * Replaces `${CLAUDE_PLUGIN_ROOT}` in a shell command string with the
15
+ * given fsPath. If the path contains characters that would break shell
16
+ * parsing (e.g. spaces), occurrences are wrapped in double-quotes.
17
+ *
18
+ * The token may be followed by additional path segments like
19
+ * `${CLAUDE_PLUGIN_ROOT}/scripts/run.sh`; the entire resulting path
20
+ * (including suffix) is quoted as one unit.
21
+ *
22
+ */
23
+ export declare function shellQuotePluginRootInCommand(command: string, fsPath: string, token?: string): string;
24
+ export declare class AgentPluginService extends Disposable implements IAgentPluginService {
25
+ readonly _serviceBrand: undefined;
26
+ readonly allPlugins: IObservable<readonly IAgentPlugin[]>;
27
+ readonly plugins: IObservable<readonly IAgentPlugin[]>;
28
+ constructor(instantiationService: IInstantiationService, configurationService: IConfigurationService);
29
+ setPluginEnabled(pluginUri: URI, enabled: boolean): void;
30
+ private _dedupeAndSort;
31
+ }
32
+ export declare class ConfiguredAgentPluginDiscovery extends Disposable implements IAgentPluginDiscovery {
33
+ private readonly _configurationService;
34
+ private readonly _fileService;
35
+ private readonly _pluginMarketplaceService;
36
+ private readonly _workspaceContextService;
37
+ private readonly _pathService;
38
+ private readonly _logService;
39
+ private readonly _instantiationService;
40
+ private readonly _pluginPathsConfig;
41
+ private readonly _pluginEntries;
42
+ private readonly _plugins;
43
+ readonly plugins: IObservable<readonly IAgentPlugin[]>;
44
+ private _discoverVersion;
45
+ constructor(_configurationService: IConfigurationService, _fileService: IFileService, _pluginMarketplaceService: IPluginMarketplaceService, _workspaceContextService: IWorkspaceContextService, _pathService: IPathService, _logService: ILogService, _instantiationService: IInstantiationService);
46
+ start(): void;
47
+ private _refreshPlugins;
48
+ private _discoverPlugins;
49
+ /**
50
+ * Resolves a plugin path to one or more resource URIs. Absolute paths are
51
+ * used directly; relative paths are resolved against each workspace folder.
52
+ */
53
+ private _resolvePluginPath;
54
+ /**
55
+ * Updates the enabled state of a plugin path in the configuration,
56
+ * writing to the most specific config target where the key is defined.
57
+ */
58
+ private _updatePluginPathEnabled;
59
+ private _detectPluginFormatAdapter;
60
+ private _pathExists;
61
+ private _toPlugin;
62
+ private _readMcpDefinitions;
63
+ private _readInlinePluginJsonMcpDefinitions;
64
+ private _parseMcpServerDefinitionMap;
65
+ private _normalizeMcpServerConfiguration;
66
+ private _readHooks;
67
+ private _readJsonFile;
68
+ private _readSkills;
69
+ private _readAgents;
70
+ private _readCommands;
71
+ private _disposePluginEntriesExcept;
72
+ dispose(): void;
73
+ }