@codingame/monaco-vscode-chat-service-override 28.4.1 → 29.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 (339) hide show
  1. package/index.js +18 -12
  2. package/package.json +5 -5
  3. package/vscode/src/vs/platform/agentHost/common/agentService.d.ts +300 -0
  4. package/vscode/src/vs/platform/agentHost/common/agentService.js +31 -0
  5. package/vscode/src/vs/platform/agentHost/common/agentService.service.d.ts +84 -0
  6. package/vscode/src/vs/platform/agentHost/common/state/protocol/action-origin.generated.d.ts +16 -0
  7. package/vscode/src/vs/platform/agentHost/common/state/protocol/actions.d.ts +488 -0
  8. package/vscode/src/vs/platform/agentHost/common/state/protocol/commands.d.ts +424 -0
  9. package/vscode/src/vs/platform/agentHost/common/state/protocol/errors.d.ts +50 -0
  10. package/vscode/src/vs/platform/agentHost/common/state/protocol/messages.d.ts +202 -0
  11. package/vscode/src/vs/platform/agentHost/common/state/protocol/notifications.d.ts +114 -0
  12. package/vscode/src/vs/platform/agentHost/common/state/protocol/state.d.ts +723 -0
  13. package/vscode/src/vs/platform/agentHost/common/state/sessionActions.d.ts +33 -0
  14. package/vscode/src/vs/platform/agentHost/common/state/sessionProtocol.d.ts +40 -0
  15. package/vscode/src/vs/platform/agentHost/common/state/sessionState.d.ts +22 -0
  16. package/vscode/src/vs/platform/browserElements/common/browserElements.d.ts +13 -0
  17. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityService.js +2 -2
  18. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatResponseAccessibleView.d.ts +2 -2
  19. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatResponseAccessibleView.js +29 -15
  20. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityActions.js +8 -8
  21. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.js +59 -59
  22. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.js +1 -1
  23. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCodeblockActions.js +12 -12
  24. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContextActions.js +8 -8
  25. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.js +3 -3
  26. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.js +4 -4
  27. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatFileTreeActions.js +2 -2
  28. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatForkActions.js +76 -10
  29. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatImportExport.js +3 -3
  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 +11 -11
  33. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatOpenAgentDebugPanelAction.d.ts +1 -1
  34. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatOpenAgentDebugPanelAction.js +162 -4
  35. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPluginActions.js +167 -4
  36. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPromptNavigationActions.js +2 -2
  37. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQueueActions.d.ts +1 -1
  38. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQueueActions.js +52 -20
  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.js +11 -11
  41. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +13 -13
  42. package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.js +19 -19
  43. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginActions.d.ts +82 -0
  44. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginActions.js +195 -0
  45. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginEditor/agentPluginEditor.d.ts +5 -1
  46. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginEditor/agentPluginEditor.js +97 -88
  47. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginEditor/agentPluginEditorInput.js +3 -3
  48. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginEditor/agentPluginItems.d.ts +4 -1
  49. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginRepositoryService.d.ts +5 -3
  50. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginRepositoryService.js +78 -35
  51. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginsView.d.ts +7 -1
  52. package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginsView.js +174 -170
  53. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js +7 -4
  54. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.d.ts +12 -0
  55. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.js +118 -52
  56. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.js +7 -7
  57. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.js +1 -1
  58. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.d.ts +5 -1
  59. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsService.js +13 -2
  60. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjection.js +1 -1
  61. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionActions.d.ts +0 -3
  62. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionActions.js +5 -10
  63. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionService.js +1 -1
  64. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionsExperiments.contribution.js +9 -10
  65. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentTitleBarStatusWidget.d.ts +23 -25
  66. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentTitleBarStatusWidget.js +341 -196
  67. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/media/agenttitlebarstatuswidget.css +79 -7
  68. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccess.js +17 -17
  69. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccessActions.js +4 -4
  70. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsController.d.ts +5 -4
  71. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/localAgentSessionsController.js +22 -10
  72. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationDebugPanel.d.ts +1 -1
  73. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationDebugPanel.js +2 -2
  74. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationIcons.d.ts +4 -0
  75. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationIcons.js +15 -14
  76. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidget.d.ts +85 -5
  77. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidget.js +668 -214
  78. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidgetUtils.d.ts +10 -0
  79. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidgetUtils.js +18 -0
  80. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.contribution.js +306 -39
  81. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditor.d.ts +84 -4
  82. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditor.js +651 -81
  83. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditorInput.d.ts +2 -1
  84. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditorInput.js +6 -2
  85. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWorkspaceService.d.ts +31 -1
  86. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWorkspaceService.js +9 -20
  87. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationCreatorService.d.ts +11 -1
  88. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationCreatorService.js +7 -142
  89. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationGroupHeaderRenderer.d.ts +43 -0
  90. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationGroupHeaderRenderer.js +63 -0
  91. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationHarnessService.d.ts +11 -0
  92. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationHarnessService.js +44 -0
  93. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/mcpListWidget.d.ts +25 -1
  94. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/mcpListWidget.js +297 -123
  95. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/media/aiCustomizationManagement.css +153 -31
  96. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/pluginListWidget.d.ts +17 -1
  97. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/pluginListWidget.js +111 -171
  98. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentResolveService.d.ts +1 -3
  99. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentResolveService.js +5 -30
  100. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/simpleBrowserEditorOverlay.js +19 -19
  101. package/vscode/src/vs/workbench/contrib/chat/browser/chat.contribution.js +277 -186
  102. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatCustomizationDiscoveryRenderer.d.ts +4 -2
  103. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatCustomizationDiscoveryRenderer.js +31 -23
  104. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCollapsible.d.ts +3 -7
  105. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugCollapsible.js +4 -16
  106. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugDetailPanel.d.ts +18 -2
  107. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugDetailPanel.js +112 -17
  108. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditor.d.ts +3 -3
  109. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditor.js +16 -27
  110. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditorInput.js +2 -2
  111. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventDetailRenderer.d.ts +1 -1
  112. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventDetailRenderer.js +41 -19
  113. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventList.d.ts +7 -1
  114. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventList.js +35 -23
  115. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFilters.d.ts +1 -8
  116. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFilters.js +8 -51
  117. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowChartView.d.ts +1 -0
  118. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowChartView.js +13 -8
  119. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowGraph.d.ts +1 -1
  120. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowGraph.js +29 -36
  121. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowLayout.js +14 -7
  122. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHomeView.d.ts +5 -1
  123. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHomeView.js +79 -26
  124. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHookContentRenderer.d.ts +19 -0
  125. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHookContentRenderer.js +125 -0
  126. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugLogsView.d.ts +11 -4
  127. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugLogsView.js +113 -82
  128. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugMessageContentRenderer.d.ts +18 -7
  129. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugMessageContentRenderer.js +54 -15
  130. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugModelTurnContentRenderer.d.ts +8 -3
  131. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugModelTurnContentRenderer.js +103 -28
  132. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugOverviewView.d.ts +2 -0
  133. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugOverviewView.js +48 -37
  134. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugToolCallContentRenderer.d.ts +28 -2
  135. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugToolCallContentRenderer.js +62 -20
  136. package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/media/chatDebug.css +21 -37
  137. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.js +1 -1
  138. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingDeletedFileEntry.js +2 -1
  139. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationModelManager.js +3 -3
  140. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.js +4 -3
  141. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.d.ts +1 -1
  142. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.js +1 -1
  143. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.d.ts +1 -0
  144. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.js +17 -4
  145. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.js +5 -5
  146. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.d.ts +4 -1
  147. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.js +43 -5
  148. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.js +1 -1
  149. package/vscode/src/vs/workbench/contrib/chat/browser/chatImageCarouselService.d.ts +59 -0
  150. package/vscode/src/vs/workbench/contrib/chat/browser/chatImageCarouselService.js +194 -0
  151. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.js +9 -10
  152. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.js +13 -13
  153. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.d.ts +2 -1
  154. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.js +8 -4
  155. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.js +2 -2
  156. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.d.ts +11 -0
  157. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.js +81 -50
  158. package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatUsageWidget.js +11 -11
  159. package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.js +4 -4
  160. package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.js +32 -32
  161. package/vscode/src/vs/workbench/contrib/chat/browser/chatRepoInfo.js +2 -2
  162. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.js +1 -1
  163. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.js +22 -15
  164. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.js +10 -10
  165. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupGrowthSession.d.ts +2 -2
  166. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupGrowthSession.js +9 -7
  167. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.js +29 -26
  168. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.d.ts +0 -2
  169. package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.js +19 -27
  170. package/vscode/src/vs/workbench/contrib/chat/browser/chatSlashCommands.d.ts +2 -4
  171. package/vscode/src/vs/workbench/contrib/chat/browser/chatSlashCommands.js +105 -172
  172. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.d.ts +1 -0
  173. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.js +80 -65
  174. package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.js +12 -12
  175. package/vscode/src/vs/workbench/contrib/chat/browser/chatTipCatalog.js +56 -27
  176. package/vscode/src/vs/workbench/contrib/chat/browser/chatTipService.js +1 -1
  177. package/vscode/src/vs/workbench/contrib/chat/browser/chatWindowNotifier.js +4 -4
  178. package/vscode/src/vs/workbench/contrib/chat/browser/claudePluginRecommendations.d.ts +16 -0
  179. package/vscode/src/vs/workbench/contrib/chat/browser/claudePluginRecommendations.js +70 -0
  180. package/vscode/src/vs/workbench/contrib/chat/browser/defaultModelContribution.js +4 -4
  181. package/vscode/src/vs/workbench/contrib/chat/browser/enablementActions.d.ts +20 -0
  182. package/vscode/src/vs/workbench/contrib/chat/browser/enablementActions.js +40 -0
  183. package/vscode/src/vs/workbench/contrib/chat/browser/enablementStatusWidget.d.ts +31 -0
  184. package/vscode/src/vs/workbench/contrib/chat/browser/enablementStatusWidget.js +53 -0
  185. package/vscode/src/vs/workbench/contrib/chat/browser/languageModelsConfigurationService.js +33 -2
  186. package/vscode/src/vs/workbench/contrib/chat/browser/pluginInstallService.d.ts +21 -2
  187. package/vscode/src/vs/workbench/contrib/chat/browser/pluginInstallService.js +362 -18
  188. package/vscode/src/vs/workbench/contrib/chat/browser/pluginSources.d.ts +15 -4
  189. package/vscode/src/vs/workbench/contrib/chat/browser/pluginSources.js +90 -43
  190. package/vscode/src/vs/workbench/contrib/chat/browser/pluginUrlHandler.d.ts +35 -0
  191. package/vscode/src/vs/workbench/contrib/chat/browser/pluginUrlHandler.js +146 -0
  192. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/chatModeActions.js +6 -6
  193. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookActions.js +26 -26
  194. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookUtils.js +3 -3
  195. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionOverlay.js +2 -2
  196. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolsCodeLensProvider.js +2 -2
  197. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptUrlHandler.js +10 -9
  198. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.js +7 -7
  199. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.js +3 -3
  200. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/skillActions.js +3 -3
  201. package/vscode/src/vs/workbench/contrib/chat/browser/promptsDebugContribution.d.ts +1 -1
  202. package/vscode/src/vs/workbench/contrib/chat/browser/promptsDebugContribution.js +33 -5
  203. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsConfirmationService.d.ts +3 -0
  204. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsConfirmationService.js +200 -55
  205. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsService.d.ts +7 -0
  206. package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsService.js +90 -45
  207. package/vscode/src/vs/workbench/contrib/chat/browser/tools/renameTool.d.ts +4 -2
  208. package/vscode/src/vs/workbench/contrib/chat/browser/tools/renameTool.js +21 -10
  209. package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +22 -16
  210. package/vscode/src/vs/workbench/contrib/chat/browser/tools/usagesTool.d.ts +4 -2
  211. package/vscode/src/vs/workbench/contrib/chat/browser/tools/usagesTool.js +28 -13
  212. package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcomeHandler.js +5 -5
  213. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatQueuePickerActionItem.js +9 -9
  214. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatStatusWidget.js +6 -6
  215. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.js +20 -16
  216. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorContrib.js +68 -5
  217. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorHover.js +1 -1
  218. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/chatQuick.js +1 -1
  219. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/editor/chatEditor.js +1 -1
  220. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.d.ts +1 -0
  221. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.js +57 -20
  222. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewTitleControl.js +2 -2
  223. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugServiceImpl.d.ts +21 -5
  224. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugServiceImpl.js +171 -57
  225. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.d.ts +7 -5
  226. package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.js +206 -35
  227. package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionOperationLog.js +4 -3
  228. package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionStore.js +7 -7
  229. package/vscode/src/vs/workbench/contrib/chat/common/participants/chatSlashCommands.d.ts +7 -1
  230. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginService.d.ts +11 -3
  231. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginServiceImpl.d.ts +44 -22
  232. package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginServiceImpl.js +450 -301
  233. package/vscode/src/vs/workbench/contrib/chat/common/plugins/marketplaceReference.d.ts +23 -0
  234. package/vscode/src/vs/workbench/contrib/chat/common/plugins/marketplaceReference.js +165 -0
  235. package/vscode/src/vs/workbench/contrib/chat/common/plugins/pluginMarketplaceService.d.ts +34 -20
  236. package/vscode/src/vs/workbench/contrib/chat/common/plugins/pluginMarketplaceService.js +209 -144
  237. package/vscode/src/vs/workbench/contrib/chat/common/plugins/workspacePluginSettingsService.d.ts +20 -0
  238. package/vscode/src/vs/workbench/contrib/chat/common/plugins/workspacePluginSettingsService.js +205 -0
  239. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/chatPromptFilesContribution.js +17 -17
  240. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/internalCustomizations/internalCustomizations.d.ts +33 -0
  241. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/internalCustomizations/internalCustomizations.js +47 -0
  242. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/internalCustomizations/internalSkill.d.ts +30 -0
  243. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.js +5 -5
  244. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.js +5 -5
  245. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.js +12 -12
  246. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.d.ts +1 -1
  247. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.js +191 -159
  248. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.d.ts +6 -7
  249. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.js +210 -233
  250. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.d.ts +19 -26
  251. package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.js +183 -193
  252. package/vscode/src/vs/workbench/contrib/chat/common/tools/chatArtifactsService.d.ts +24 -0
  253. package/vscode/src/vs/workbench/contrib/chat/common/tools/chatArtifactsService.js +75 -0
  254. package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.js +1 -1
  255. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChat.contribution.js +8 -5
  256. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.d.ts +8 -0
  257. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +97 -35
  258. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatDefaultModel.js +2 -2
  259. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatHistoryService.d.ts +16 -0
  260. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatHistoryService.js +67 -0
  261. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.d.ts +2 -2
  262. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.js +62 -23
  263. package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.js +14 -14
  264. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.js +1 -1
  265. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.js +10 -10
  266. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebook.chat.contribution.js +5 -5
  267. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatContext.js +1 -1
  268. package/vscode/src/vs/workbench/contrib/remoteCodingAgents/browser/remoteCodingAgents.contribution.js +8 -8
  269. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibilityHelp.js +16 -16
  270. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatActions.js +20 -20
  271. package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +2 -2
  272. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.d.ts +3 -1
  273. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.js +23 -9
  274. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.d.ts +1 -1
  275. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.js +2 -2
  276. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/noneExecuteStrategy.d.ts +3 -1
  277. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/noneExecuteStrategy.js +50 -9
  278. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.d.ts +3 -1
  279. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.js +21 -7
  280. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/strategyHelpers.d.ts +20 -1
  281. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/strategyHelpers.js +124 -1
  282. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/outputHelpers.js +20 -5
  283. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.d.ts +5 -0
  284. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +10 -7
  285. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.d.ts +2 -1
  286. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.js +46 -31
  287. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.d.ts +18 -1
  288. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.js +74 -37
  289. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/awaitTerminalTool.js +3 -3
  290. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.js +1 -1
  291. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAnalyzer.d.ts +1 -0
  292. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +24 -14
  293. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +2 -2
  294. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineSandboxAnalyzer.js +1 -1
  295. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/sandboxedCommandLinePresenter.d.ts +3 -2
  296. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/sandboxedCommandLinePresenter.js +1 -1
  297. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineRewriter.d.ts +2 -0
  298. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineSandboxRewriter.js +5 -1
  299. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.js +3 -3
  300. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.js +3 -3
  301. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.js +3 -3
  302. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/killTerminalTool.js +3 -3
  303. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.d.ts +1 -2
  304. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +66 -64
  305. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/outputAnalyzer.d.ts +1 -0
  306. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.d.ts +1 -0
  307. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.js +5 -2
  308. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +32 -2
  309. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +390 -114
  310. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sandboxOutputAnalyzer.d.ts +14 -0
  311. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sandboxOutputAnalyzer.js +21 -11
  312. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.js +70 -51
  313. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.js +61 -51
  314. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.js +94 -76
  315. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.js +1 -1
  316. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.d.ts +19 -1
  317. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.js +112 -21
  318. package/vscode/src/vs/sessions/contrib/agentFeedback/browser/agentFeedbackService.d.ts +0 -53
  319. package/vscode/src/vs/sessions/contrib/agentFeedback/browser/agentFeedbackService.js +0 -219
  320. package/vscode/src/vs/sessions/contrib/chat/browser/aiCustomizationWorkspaceService.d.ts +0 -89
  321. package/vscode/src/vs/sessions/contrib/chat/browser/aiCustomizationWorkspaceService.js +0 -251
  322. package/vscode/src/vs/sessions/contrib/chat/browser/newSession.d.ts +0 -123
  323. package/vscode/src/vs/sessions/contrib/chat/browser/newSession.js +0 -278
  324. package/vscode/src/vs/sessions/contrib/chat/browser/sessionsConfigurationService.d.ts +0 -76
  325. package/vscode/src/vs/sessions/contrib/chat/browser/sessionsConfigurationService.js +0 -299
  326. package/vscode/src/vs/sessions/contrib/fileTreeView/browser/githubFileSystemProvider.d.ts +0 -67
  327. package/vscode/src/vs/sessions/contrib/fileTreeView/browser/githubFileSystemProvider.js +0 -263
  328. package/vscode/src/vs/sessions/contrib/sessions/browser/sessionsManagementService.d.ts +0 -85
  329. package/vscode/src/vs/sessions/contrib/sessions/browser/sessionsManagementService.js +0 -397
  330. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.d.ts +0 -56
  331. package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.js +0 -26
  332. package/vscode/src/vs/workbench/contrib/chat/browser/sessionResourceMatching.d.ts +0 -5
  333. package/vscode/src/vs/workbench/contrib/chat/browser/sessionResourceMatching.js +0 -30
  334. package/vscode/src/vs/workbench/contrib/chat/common/aiCustomizationWorkspaceService.d.ts +0 -40
  335. package/vscode/src/vs/workbench/contrib/chat/common/aiCustomizationWorkspaceService.js +0 -28
  336. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugService.d.ts +0 -190
  337. package/vscode/src/vs/workbench/contrib/chat/common/chatDebugService.js +0 -11
  338. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.d.ts +0 -16
  339. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.js +0 -20
@@ -0,0 +1,723 @@
1
+ /** A URI string (e.g. `agenthost:/root` or `copilot:/<uuid>`). */
2
+ export type URI = string;
3
+ /**
4
+ * A string that may optionally be rendered as Markdown.
5
+ *
6
+ * - A plain `string` is rendered as-is (no Markdown processing).
7
+ * - An object with `{ markdown: string }` is rendered with Markdown formatting.
8
+ */
9
+ export type StringOrMarkdown = string | {
10
+ markdown: string;
11
+ };
12
+ /**
13
+ * Describes a protected resource's authentication requirements using
14
+ * [RFC 9728](https://datatracker.ietf.org/doc/html/rfc9728) (OAuth 2.0
15
+ * Protected Resource Metadata) semantics.
16
+ *
17
+ * Field names use snake_case to match the RFC 9728 JSON format.
18
+ *
19
+ * @category Authentication
20
+ * @see {@link https://datatracker.ietf.org/doc/html/rfc9728 | RFC 9728}
21
+ */
22
+ export interface IProtectedResourceMetadata {
23
+ /**
24
+ * REQUIRED. The protected resource's resource identifier, a URL using the
25
+ * `https` scheme with no fragment component (e.g. `"https://api.github.com"`).
26
+ */
27
+ resource: string;
28
+ /** OPTIONAL. Human-readable name of the protected resource. */
29
+ resource_name?: string;
30
+ /** OPTIONAL. JSON array of OAuth authorization server identifier URLs. */
31
+ authorization_servers?: string[];
32
+ /** OPTIONAL. URL of the protected resource's JWK Set document. */
33
+ jwks_uri?: string;
34
+ /** RECOMMENDED. JSON array of OAuth 2.0 scope values used in authorization requests. */
35
+ scopes_supported?: string[];
36
+ /** OPTIONAL. JSON array of Bearer Token presentation methods supported. */
37
+ bearer_methods_supported?: string[];
38
+ /** OPTIONAL. JSON array of JWS signing algorithms supported. */
39
+ resource_signing_alg_values_supported?: string[];
40
+ /** OPTIONAL. JSON array of JWE encryption algorithms (alg) supported. */
41
+ resource_encryption_alg_values_supported?: string[];
42
+ /** OPTIONAL. JSON array of JWE encryption algorithms (enc) supported. */
43
+ resource_encryption_enc_values_supported?: string[];
44
+ /** OPTIONAL. URL of human-readable documentation for the resource. */
45
+ resource_documentation?: string;
46
+ /** OPTIONAL. URL of the resource's data-usage policy. */
47
+ resource_policy_uri?: string;
48
+ /** OPTIONAL. URL of the resource's terms of service. */
49
+ resource_tos_uri?: string;
50
+ /**
51
+ * AHP extension. Whether authentication is required for this resource.
52
+ *
53
+ * - `true` (default) — the agent cannot be used without a valid token.
54
+ * The server SHOULD return `AuthRequired` (`-32007`) if the client
55
+ * attempts to use the agent without authenticating.
56
+ * - `false` — the agent works without authentication but MAY offer
57
+ * enhanced capabilities when a token is provided.
58
+ *
59
+ * Clients SHOULD treat an absent field the same as `true`.
60
+ */
61
+ required?: boolean;
62
+ }
63
+ /**
64
+ * Policy configuration state for a model.
65
+ *
66
+ * @category Root State
67
+ */
68
+ export declare enum PolicyState {
69
+ Enabled = "enabled",
70
+ Disabled = "disabled",
71
+ Unconfigured = "unconfigured"
72
+ }
73
+ /**
74
+ * Global state shared with every client subscribed to `agenthost:/root`.
75
+ *
76
+ * @category Root State
77
+ */
78
+ export interface IRootState {
79
+ /** Available agent backends and their models */
80
+ agents: IAgentInfo[];
81
+ /** Number of active (non-disposed) sessions on the server */
82
+ activeSessions?: number;
83
+ }
84
+ /**
85
+ * @category Root State
86
+ */
87
+ export interface IAgentInfo {
88
+ /** Agent provider ID (e.g. `'copilot'`) */
89
+ provider: string;
90
+ /** Human-readable name */
91
+ displayName: string;
92
+ /** Description string */
93
+ description: string;
94
+ /** Available models for this agent */
95
+ models: ISessionModelInfo[];
96
+ /**
97
+ * Protected resources this agent requires authentication for.
98
+ *
99
+ * Each entry describes an OAuth 2.0 protected resource using
100
+ * [RFC 9728](https://datatracker.ietf.org/doc/html/rfc9728) semantics.
101
+ * Clients should obtain tokens from the declared `authorization_servers`
102
+ * and push them via the `authenticate` command before creating sessions
103
+ * with this agent.
104
+ *
105
+ * @see {@link /specification/authentication | Authentication}
106
+ */
107
+ protectedResources?: IProtectedResourceMetadata[];
108
+ }
109
+ /**
110
+ * @category Root State
111
+ */
112
+ export interface ISessionModelInfo {
113
+ /** Model identifier */
114
+ id: string;
115
+ /** Provider this model belongs to */
116
+ provider: string;
117
+ /** Human-readable model name */
118
+ name: string;
119
+ /** Maximum context window size */
120
+ maxContextWindow?: number;
121
+ /** Whether the model supports vision */
122
+ supportsVision?: boolean;
123
+ /** Policy configuration state */
124
+ policyState?: PolicyState;
125
+ }
126
+ /**
127
+ * Session initialization state.
128
+ *
129
+ * @category Session State
130
+ */
131
+ export declare enum SessionLifecycle {
132
+ Creating = "creating",
133
+ Ready = "ready",
134
+ CreationFailed = "creationFailed"
135
+ }
136
+ /**
137
+ * Current session status.
138
+ *
139
+ * @category Session State
140
+ */
141
+ export declare enum SessionStatus {
142
+ Idle = "idle",
143
+ InProgress = "in-progress",
144
+ Error = "error"
145
+ }
146
+ /**
147
+ * Full state for a single session, loaded when a client subscribes to the session's URI.
148
+ *
149
+ * @category Session State
150
+ */
151
+ export interface ISessionState {
152
+ /** Lightweight session metadata */
153
+ summary: ISessionSummary;
154
+ /** Session initialization state */
155
+ lifecycle: SessionLifecycle;
156
+ /** Error details if creation failed */
157
+ creationError?: IErrorInfo;
158
+ /** Tools provided by the server (agent host) for this session */
159
+ serverTools?: IToolDefinition[];
160
+ /** The client currently providing tools and interactive capabilities to this session */
161
+ activeClient?: ISessionActiveClient;
162
+ /** The working directory URI for this session */
163
+ workingDirectory?: URI;
164
+ /** Completed turns */
165
+ turns: ITurn[];
166
+ /** Currently in-progress turn */
167
+ activeTurn?: IActiveTurn;
168
+ }
169
+ /**
170
+ * The client currently providing tools and interactive capabilities to a session.
171
+ *
172
+ * Only one client may be active per session at a time. The server SHOULD
173
+ * automatically unset the active client if that client disconnects.
174
+ *
175
+ * @category Session State
176
+ */
177
+ export interface ISessionActiveClient {
178
+ /** Client identifier (matches `clientId` from `initialize`) */
179
+ clientId: string;
180
+ /** Human-readable client name (e.g. `"VS Code"`) */
181
+ displayName?: string;
182
+ /** Tools this client provides to the session */
183
+ tools: IToolDefinition[];
184
+ }
185
+ /**
186
+ * @category Session State
187
+ */
188
+ export interface ISessionSummary {
189
+ /** Session URI */
190
+ resource: URI;
191
+ /** Agent provider ID */
192
+ provider: string;
193
+ /** Session title */
194
+ title: string;
195
+ /** Current session status */
196
+ status: SessionStatus;
197
+ /** Creation timestamp */
198
+ createdAt: number;
199
+ /** Last modification timestamp */
200
+ modifiedAt: number;
201
+ /** Currently selected model */
202
+ model?: string;
203
+ /** The working directory URI for this session */
204
+ workingDirectory?: URI;
205
+ }
206
+ /**
207
+ * How a turn ended.
208
+ *
209
+ * @category Turn Types
210
+ */
211
+ export declare enum TurnState {
212
+ Complete = "complete",
213
+ Cancelled = "cancelled",
214
+ Error = "error"
215
+ }
216
+ /**
217
+ * Type of a message attachment.
218
+ *
219
+ * @category Turn Types
220
+ */
221
+ export declare enum AttachmentType {
222
+ File = "file",
223
+ Directory = "directory",
224
+ Selection = "selection"
225
+ }
226
+ /**
227
+ * A completed request/response cycle.
228
+ *
229
+ * @category Turn Types
230
+ */
231
+ export interface ITurn {
232
+ /** Turn identifier */
233
+ id: string;
234
+ /** The user's input */
235
+ userMessage: IUserMessage;
236
+ /** Final response text (captured from streaming) */
237
+ responseText: string;
238
+ /** Structured response content */
239
+ responseParts: IResponsePart[];
240
+ /** Tool invocations in terminal states (completed or cancelled) */
241
+ toolCalls: (IToolCallCompletedState | IToolCallCancelledState)[];
242
+ /** Token usage info */
243
+ usage: IUsageInfo | undefined;
244
+ /** How the turn ended */
245
+ state: TurnState;
246
+ /** Error details if state is `'error'` */
247
+ error?: IErrorInfo;
248
+ }
249
+ /**
250
+ * An in-progress turn — the assistant is actively streaming.
251
+ *
252
+ * @category Turn Types
253
+ */
254
+ export interface IActiveTurn {
255
+ /** Turn identifier */
256
+ id: string;
257
+ /** The user's input */
258
+ userMessage: IUserMessage;
259
+ /** Accumulated streaming response text */
260
+ streamingText: string;
261
+ /** Structured response content so far */
262
+ responseParts: IResponsePart[];
263
+ /** Active tool invocations keyed by tool call ID */
264
+ toolCalls: Record<string, IToolCallState>;
265
+ /** Pending permission requests keyed by request ID */
266
+ pendingPermissions: Record<string, IPermissionRequest>;
267
+ /** Accumulated reasoning/thinking text */
268
+ reasoning: string;
269
+ /** Token usage info */
270
+ usage: IUsageInfo | undefined;
271
+ }
272
+ /**
273
+ * @category Turn Types
274
+ */
275
+ export interface IUserMessage {
276
+ /** Message text */
277
+ text: string;
278
+ /** File/selection attachments */
279
+ attachments?: IMessageAttachment[];
280
+ }
281
+ /**
282
+ * @category Turn Types
283
+ */
284
+ export interface IMessageAttachment {
285
+ /** Attachment type */
286
+ type: AttachmentType;
287
+ /** File/directory path */
288
+ path: string;
289
+ /** Display name */
290
+ displayName?: string;
291
+ }
292
+ /**
293
+ * Discriminant for response part types.
294
+ *
295
+ * @category Response Parts
296
+ */
297
+ export declare enum ResponsePartKind {
298
+ Markdown = "markdown",
299
+ ContentRef = "contentRef"
300
+ }
301
+ /**
302
+ * @category Response Parts
303
+ */
304
+ export interface IMarkdownResponsePart {
305
+ /** Discriminant */
306
+ kind: ResponsePartKind.Markdown;
307
+ /** Markdown content */
308
+ content: string;
309
+ }
310
+ /**
311
+ * A reference to large content stored outside the state tree.
312
+ *
313
+ * @category Response Parts
314
+ */
315
+ export interface IContentRef {
316
+ /** Discriminant */
317
+ kind: ResponsePartKind.ContentRef;
318
+ /** Content URI */
319
+ uri: string;
320
+ /** Approximate size in bytes */
321
+ sizeHint?: number;
322
+ /** Content MIME type */
323
+ contentType?: string;
324
+ }
325
+ /**
326
+ * @category Response Parts
327
+ */
328
+ export type IResponsePart = IMarkdownResponsePart | IContentRef;
329
+ /**
330
+ * Status of a tool call in the lifecycle state machine.
331
+ *
332
+ * @category Tool Call Types
333
+ */
334
+ export declare enum ToolCallStatus {
335
+ Streaming = "streaming",
336
+ PendingConfirmation = "pending-confirmation",
337
+ Running = "running",
338
+ PendingResultConfirmation = "pending-result-confirmation",
339
+ Completed = "completed",
340
+ Cancelled = "cancelled"
341
+ }
342
+ /**
343
+ * How a tool call was confirmed for execution.
344
+ *
345
+ * - `NotNeeded` — No confirmation required (auto-approved)
346
+ * - `UserAction` — User explicitly approved
347
+ * - `Setting` — Approved by a persistent user setting
348
+ *
349
+ * @category Tool Call Types
350
+ */
351
+ export declare enum ToolCallConfirmationReason {
352
+ NotNeeded = "not-needed",
353
+ UserAction = "user-action",
354
+ Setting = "setting"
355
+ }
356
+ /**
357
+ * Why a tool call was cancelled.
358
+ *
359
+ * @category Tool Call Types
360
+ */
361
+ export declare enum ToolCallCancellationReason {
362
+ Denied = "denied",
363
+ Skipped = "skipped",
364
+ ResultDenied = "result-denied"
365
+ }
366
+ /**
367
+ * Metadata common to all tool call states.
368
+ *
369
+ * @category Tool Call Types
370
+ * @remarks
371
+ * Fields like `toolName` carry agent-specific identifiers on the wire despite the
372
+ * agent-agnostic design principle. These exist for debugging and logging purposes.
373
+ * A future version may move these to a separate diagnostic channel or namespace them
374
+ * more clearly.
375
+ */
376
+ interface IToolCallBase {
377
+ /** Unique tool call identifier */
378
+ toolCallId: string;
379
+ /** Internal tool name (for debugging/logging) */
380
+ toolName: string;
381
+ /** Human-readable tool name */
382
+ displayName: string;
383
+ /**
384
+ * If this tool is provided by a client, the `clientId` of the owning client.
385
+ * Absent for server-side tools.
386
+ *
387
+ * When set, the identified client is responsible for executing the tool and
388
+ * dispatching `session/toolCallComplete` with the result.
389
+ */
390
+ toolClientId?: string;
391
+ /**
392
+ * Additional provider-specific metadata for this tool call.
393
+ *
394
+ * Clients MAY look for well-known keys here to provide enhanced UI.
395
+ * For example, a `ptyTerminal` key with `{ input: string; output: string }`
396
+ * indicates the tool operated on a terminal (both `input` and `output` may
397
+ * contain escape sequences).
398
+ */
399
+ _meta?: Record<string, unknown>;
400
+ }
401
+ /**
402
+ * Properties available once tool call parameters are fully received.
403
+ *
404
+ * @category Tool Call Types
405
+ */
406
+ interface IToolCallParameterFields {
407
+ /** Message describing what the tool will do */
408
+ invocationMessage: StringOrMarkdown;
409
+ /** Raw tool input */
410
+ toolInput?: string;
411
+ }
412
+ /**
413
+ * Tool execution result details, available after execution completes.
414
+ *
415
+ * @category Tool Call Types
416
+ */
417
+ export interface IToolCallResult {
418
+ /** Whether the tool succeeded */
419
+ success: boolean;
420
+ /** Past-tense description of what the tool did */
421
+ pastTenseMessage: StringOrMarkdown;
422
+ /**
423
+ * Unstructured result content blocks.
424
+ *
425
+ * This mirrors the `content` field of MCP `CallToolResult`.
426
+ */
427
+ content?: IToolResultContent[];
428
+ /**
429
+ * Optional structured result object.
430
+ *
431
+ * This mirrors the `structuredContent` field of MCP `CallToolResult`.
432
+ */
433
+ structuredContent?: Record<string, unknown>;
434
+ /** Error details if the tool failed */
435
+ error?: {
436
+ message: string;
437
+ code?: string;
438
+ };
439
+ }
440
+ /**
441
+ * LM is streaming the tool call parameters.
442
+ *
443
+ * @category Tool Call Types
444
+ */
445
+ export interface IToolCallStreamingState extends IToolCallBase {
446
+ status: ToolCallStatus.Streaming;
447
+ /** Partial parameters accumulated so far */
448
+ partialInput?: string;
449
+ /** Progress message shown while parameters are streaming */
450
+ invocationMessage?: StringOrMarkdown;
451
+ }
452
+ /**
453
+ * Parameters are complete, waiting for client to confirm execution.
454
+ *
455
+ * @category Tool Call Types
456
+ */
457
+ export interface IToolCallPendingConfirmationState extends IToolCallBase, IToolCallParameterFields {
458
+ status: ToolCallStatus.PendingConfirmation;
459
+ }
460
+ /**
461
+ * Tool is actively executing.
462
+ *
463
+ * @category Tool Call Types
464
+ */
465
+ export interface IToolCallRunningState extends IToolCallBase, IToolCallParameterFields {
466
+ status: ToolCallStatus.Running;
467
+ /** How the tool was confirmed for execution */
468
+ confirmed: ToolCallConfirmationReason;
469
+ }
470
+ /**
471
+ * Tool finished executing, waiting for client to approve the result.
472
+ *
473
+ * @category Tool Call Types
474
+ */
475
+ export interface IToolCallPendingResultConfirmationState extends IToolCallBase, IToolCallParameterFields, IToolCallResult {
476
+ status: ToolCallStatus.PendingResultConfirmation;
477
+ /** How the tool was confirmed for execution */
478
+ confirmed: ToolCallConfirmationReason;
479
+ }
480
+ /**
481
+ * Tool completed successfully or with an error.
482
+ *
483
+ * @category Tool Call Types
484
+ */
485
+ export interface IToolCallCompletedState extends IToolCallBase, IToolCallParameterFields, IToolCallResult {
486
+ status: ToolCallStatus.Completed;
487
+ /** How the tool was confirmed for execution */
488
+ confirmed: ToolCallConfirmationReason;
489
+ }
490
+ /**
491
+ * Tool call was cancelled before execution.
492
+ *
493
+ * @category Tool Call Types
494
+ */
495
+ export interface IToolCallCancelledState extends IToolCallBase, IToolCallParameterFields {
496
+ status: ToolCallStatus.Cancelled;
497
+ /** Why the tool was cancelled */
498
+ reason: ToolCallCancellationReason;
499
+ /** Optional message explaining the cancellation */
500
+ reasonMessage?: StringOrMarkdown;
501
+ /** What the user suggested doing instead */
502
+ userSuggestion?: IUserMessage;
503
+ }
504
+ /**
505
+ * Discriminated union of all tool call lifecycle states.
506
+ *
507
+ * See the [state model guide](/guide/state-model.html#tool-call-lifecycle)
508
+ * for the full state machine diagram.
509
+ *
510
+ * @category Tool Call Types
511
+ */
512
+ export type IToolCallState = IToolCallStreamingState | IToolCallPendingConfirmationState | IToolCallRunningState | IToolCallPendingResultConfirmationState | IToolCallCompletedState | IToolCallCancelledState;
513
+ /**
514
+ * Describes a tool available in a session, provided by either the server or the active client.
515
+ *
516
+ * This type mirrors the MCP `Tool` type from the Model Context Protocol specification
517
+ * (2025-11-25 draft) and will continue to track it.
518
+ *
519
+ * @category Tool Definition Types
520
+ */
521
+ export interface IToolDefinition {
522
+ /** Unique tool identifier */
523
+ name: string;
524
+ /** Human-readable display name */
525
+ title?: string;
526
+ /** Description of what the tool does */
527
+ description?: string;
528
+ /**
529
+ * JSON Schema defining the expected input parameters.
530
+ *
531
+ * Optional because client-provided tools may not have formal schemas.
532
+ * Mirrors MCP `Tool.inputSchema`.
533
+ */
534
+ inputSchema?: {
535
+ type: "object";
536
+ properties?: Record<string, object>;
537
+ required?: string[];
538
+ };
539
+ /**
540
+ * JSON Schema defining the structure of the tool's output.
541
+ *
542
+ * Mirrors MCP `Tool.outputSchema`.
543
+ */
544
+ outputSchema?: {
545
+ type: "object";
546
+ properties?: Record<string, object>;
547
+ required?: string[];
548
+ };
549
+ /** Behavioral hints about the tool. All properties are advisory. */
550
+ annotations?: IToolAnnotations;
551
+ /**
552
+ * Additional provider-specific metadata.
553
+ *
554
+ * Mirrors the MCP `_meta` convention.
555
+ */
556
+ _meta?: Record<string, unknown>;
557
+ }
558
+ /**
559
+ * Behavioral hints about a tool. All properties are advisory and not
560
+ * guaranteed to faithfully describe tool behavior.
561
+ *
562
+ * Mirrors MCP `ToolAnnotations` from the Model Context Protocol specification.
563
+ *
564
+ * @category Tool Definition Types
565
+ */
566
+ export interface IToolAnnotations {
567
+ /** Alternate human-readable title */
568
+ title?: string;
569
+ /** Tool does not modify its environment (default: false) */
570
+ readOnlyHint?: boolean;
571
+ /** Tool may perform destructive updates (default: true) */
572
+ destructiveHint?: boolean;
573
+ /** Repeated calls with the same arguments have no additional effect (default: false) */
574
+ idempotentHint?: boolean;
575
+ /** Tool may interact with external entities (default: true) */
576
+ openWorldHint?: boolean;
577
+ }
578
+ /**
579
+ * Discriminant for tool result content types.
580
+ *
581
+ * @category Tool Result Content
582
+ */
583
+ export declare enum ToolResultContentType {
584
+ Text = "text",
585
+ Binary = "binary",
586
+ FileEdit = "fileEdit"
587
+ }
588
+ /**
589
+ * Text content in a tool result.
590
+ *
591
+ * Mirrors MCP `TextContent`.
592
+ *
593
+ * @category Tool Result Content
594
+ */
595
+ export interface IToolResultTextContent {
596
+ type: ToolResultContentType.Text;
597
+ /** The text content */
598
+ text: string;
599
+ }
600
+ /**
601
+ * Base64-encoded binary content in a tool result.
602
+ *
603
+ * Mirrors MCP `ImageContent` but generalized to any binary content type.
604
+ *
605
+ * @category Tool Result Content
606
+ */
607
+ export interface IToolResultBinaryContent {
608
+ type: ToolResultContentType.Binary;
609
+ /** Base64-encoded data */
610
+ data: string;
611
+ /** Content type (e.g. `"image/png"`, `"application/pdf"`) */
612
+ contentType: string;
613
+ }
614
+ /**
615
+ * Describes a file modification performed by a tool.
616
+ *
617
+ * Clients can use the `beforeURI`/`afterURI` pair to render a diff view.
618
+ *
619
+ * @category Tool Result Content
620
+ */
621
+ export interface IToolResultFileEditContent {
622
+ type: ToolResultContentType.FileEdit;
623
+ /** URI of the file content before the edit */
624
+ beforeURI: URI;
625
+ /** URI of the file content after the edit */
626
+ afterURI: URI;
627
+ /** Optional diff display metadata */
628
+ diff?: {
629
+ /** Number of items added (e.g., lines for text files, cells for notebooks) */
630
+ added?: number;
631
+ /** Number of items removed (e.g., lines for text files, cells for notebooks) */
632
+ removed?: number;
633
+ };
634
+ }
635
+ /**
636
+ * Content block in a tool result.
637
+ *
638
+ * Mirrors the content blocks in MCP `CallToolResult.content`, plus
639
+ * `IContentRef` for lazy-loading large results and `IToolResultFileEditContent`
640
+ * for file edit diffs (AHP extensions).
641
+ *
642
+ * @category Tool Result Content
643
+ */
644
+ export type IToolResultContent = IToolResultTextContent | IToolResultBinaryContent | IToolResultFileEditContent | IContentRef;
645
+ /**
646
+ * Type of permission requested.
647
+ *
648
+ * @category Permission Types
649
+ */
650
+ export declare enum PermissionKind {
651
+ Shell = "shell",
652
+ Write = "write",
653
+ Mcp = "mcp",
654
+ Read = "read",
655
+ Url = "url"
656
+ }
657
+ /**
658
+ * @category Permission Types
659
+ * @remarks
660
+ * Fields like `serverName`, `toolName`, and `rawRequest` carry agent-specific
661
+ * identifiers on the wire despite the agent-agnostic design principle. These exist
662
+ * for debugging and logging purposes.
663
+ * @todo @connor4312, split this up into well-separated union types
664
+ */
665
+ export interface IPermissionRequest {
666
+ /** Unique request identifier */
667
+ requestId: string;
668
+ /** Type of permission */
669
+ permissionKind: PermissionKind;
670
+ /** Associated tool call */
671
+ toolCallId?: string;
672
+ /** File/directory path */
673
+ path?: string;
674
+ /** Full command to execute */
675
+ fullCommandText?: string;
676
+ /** What the tool intends to do */
677
+ intention?: string;
678
+ /** MCP server name */
679
+ serverName?: string;
680
+ /** Tool requesting permission */
681
+ toolName?: string;
682
+ /** Raw request data */
683
+ rawRequest?: string;
684
+ }
685
+ /**
686
+ * @category Common Types
687
+ */
688
+ export interface IUsageInfo {
689
+ /** Input tokens consumed */
690
+ inputTokens?: number;
691
+ /** Output tokens generated */
692
+ outputTokens?: number;
693
+ /** Model used */
694
+ model?: string;
695
+ /** Tokens read from cache */
696
+ cacheReadTokens?: number;
697
+ }
698
+ /**
699
+ * @category Common Types
700
+ */
701
+ export interface IErrorInfo {
702
+ /** Error type identifier */
703
+ errorType: string;
704
+ /** Human-readable error message */
705
+ message: string;
706
+ /** Stack trace */
707
+ stack?: string;
708
+ }
709
+ /**
710
+ * A point-in-time snapshot of a subscribed resource's state, returned by
711
+ * `initialize`, `reconnect`, and `subscribe`.
712
+ *
713
+ * @category Common Types
714
+ */
715
+ export interface ISnapshot {
716
+ /** The subscribed resource URI (e.g. `agenthost:/root` or `copilot:/<uuid>`) */
717
+ resource: URI;
718
+ /** The current state of the resource */
719
+ state: IRootState | ISessionState;
720
+ /** The `serverSeq` at which this snapshot was taken. Subsequent actions will have `serverSeq > fromSeq`. */
721
+ fromSeq: number;
722
+ }
723
+ export {};