@codingame/monaco-vscode-chat-service-override 30.0.0 → 31.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.
- package/index.js +21 -3
- package/package.json +5 -5
- package/vscode/src/vs/platform/agentHost/browser/remoteAgentHostProtocolClient.d.ts +125 -0
- package/vscode/src/vs/platform/agentHost/browser/remoteAgentHostProtocolClient.js +393 -0
- package/vscode/src/vs/platform/agentHost/browser/remoteAgentHostServiceImpl.d.ts +65 -0
- package/vscode/src/vs/platform/agentHost/browser/remoteAgentHostServiceImpl.js +453 -0
- package/vscode/src/vs/platform/agentHost/browser/webSocketClientTransport.d.ts +28 -0
- package/vscode/src/vs/platform/agentHost/browser/webSocketClientTransport.js +81 -0
- package/vscode/src/vs/platform/agentHost/common/agentHostFileSystemProvider.d.ts +75 -0
- package/vscode/src/vs/platform/agentHost/common/agentHostFileSystemProvider.js +180 -0
- package/vscode/src/vs/platform/agentHost/common/agentService.d.ts +202 -51
- package/vscode/src/vs/platform/agentHost/common/state/agentSubscription.d.ts +182 -0
- package/vscode/src/vs/platform/agentHost/common/state/agentSubscription.js +282 -0
- package/vscode/src/vs/platform/agentHost/common/state/protocol/commands.d.ts +303 -32
- package/vscode/src/vs/platform/agentHost/common/state/protocol/commands.js +14 -0
- package/vscode/src/vs/platform/agentHost/common/state/protocol/errors.d.ts +1 -1
- package/vscode/src/vs/platform/agentHost/common/state/protocol/errors.js +9 -0
- package/vscode/src/vs/platform/agentHost/common/state/protocol/reducers.d.ts +30 -0
- package/vscode/src/vs/platform/agentHost/common/state/protocol/reducers.js +662 -0
- package/vscode/src/vs/platform/agentHost/common/state/sessionActions.d.ts +12 -5
- package/vscode/src/vs/platform/agentHost/common/state/sessionActions.js +9 -0
- package/vscode/src/vs/platform/agentHost/common/state/sessionCapabilities.d.ts +17 -0
- package/vscode/src/vs/platform/agentHost/common/state/sessionCapabilities.js +5 -0
- package/vscode/src/vs/platform/agentHost/common/state/sessionProtocol.d.ts +5 -5
- package/vscode/src/vs/platform/agentHost/common/state/sessionProtocol.js +14 -0
- package/vscode/src/vs/platform/agentHost/common/state/sessionTransport.d.ts +42 -0
- package/vscode/src/vs/platform/agentHost/common/state/sessionTransport.js +7 -0
- package/vscode/src/vs/platform/agentPlugins/common/pluginParsers.d.ts +118 -0
- package/vscode/src/vs/platform/agentPlugins/common/pluginParsers.js +551 -0
- package/vscode/src/vs/platform/networkFilter/common/networkFilterService.d.ts +22 -0
- package/vscode/src/vs/platform/networkFilter/common/networkFilterService.js +83 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityService.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatResponseAccessibleView.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityActions.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAccessibilityHelp.js +59 -59
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatAgentRecommendationActions.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCodeblockActions.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContextActions.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContextActions.js +17 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.d.ts +8 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.js +113 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.js +81 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatFileTreeActions.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatForkActions.js +47 -26
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatImportExport.js +15 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatLanguageModelActions.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatMoveActions.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatNewActions.js +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatOpenAgentDebugPanelAction.js +13 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPluginActions.js +15 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPromptNavigationActions.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQueueActions.d.ts +5 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQueueActions.js +58 -23
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.js +18 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/createPluginAction.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/createPluginAction.js +24 -22
- package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginActions.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginEditor/agentPluginEditor.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginEditor/agentPluginEditorInput.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginRepositoryService.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginRepositoryService.js +29 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/agentPluginsView.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostSessionWorkingDirectoryResolver.d.ts +9 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostSessionWorkingDirectoryResolver.js +23 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.js +65 -55
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjection.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionService.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionsExperiments.contribution.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentTitleBarStatusWidget.js +28 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccess.js +17 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccessActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationDebugPanel.d.ts +10 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationDebugPanel.js +80 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationIcons.d.ts +20 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationIcons.js +30 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationItemSource.d.ts +131 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationItemSource.js +363 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidget.d.ts +31 -76
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidget.js +374 -764
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidgetUtils.d.ts +8 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationListWidgetUtils.js +11 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagement.contribution.js +222 -44
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditor.d.ts +20 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditor.js +269 -123
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationManagementEditorInput.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWelcomePage.d.ts +40 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWelcomePage.js +40 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWelcomePagePromptLaunchers.d.ts +26 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWelcomePagePromptLaunchers.js +249 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWorkspaceService.d.ts +3 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/aiCustomizationWorkspaceService.js +3 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationHarnessService.d.ts +4 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/customizationHarnessService.js +5 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/mcpListWidget.d.ts +14 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/mcpListWidget.js +113 -58
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/media/aiCustomizationManagement.css +202 -68
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/media/aiCustomizationWelcomePromptLaunchers.css +246 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/pluginListWidget.d.ts +15 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/pluginListWidget.js +162 -50
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/promptsServiceCustomizationItemProvider.d.ts +24 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/aiCustomization/promptsServiceCustomizationItemProvider.js +306 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentResolveService.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chat.contribution.js +581 -257
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatCustomizationDiscoveryRenderer.d.ts +15 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatCustomizationDiscoveryRenderer.js +245 -26
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugDetailPanel.js +25 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditor.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditor.js +3 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEditorInput.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventDetailRenderer.js +19 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugEventList.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFilters.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowChartView.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowGraph.js +103 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugFlowLayout.js +3 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHomeView.d.ts +11 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHomeView.js +80 -29
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugHookContentRenderer.js +17 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugLogsView.d.ts +20 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugLogsView.js +128 -65
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugMessageContentRenderer.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugModelTurnContentRenderer.js +23 -23
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugOverviewView.js +28 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/chatDebugToolCallContentRenderer.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/chatDebug/media/chatDebug.css +18 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationModelManager.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.js +11 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.js +6 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatImageCarouselService.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.js +10 -27
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.d.ts +4 -41
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.js +4 -310
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.d.ts +0 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.js +3 -30
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.js +61 -53
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/media/chatManagementEditor.css +0 -110
- package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.js +31 -31
- package/vscode/src/vs/workbench/contrib/chat/browser/chatRepoInfo.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.js +46 -34
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.d.ts +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.js +17 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupGrowthSession.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.js +96 -82
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.js +21 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSlashCommands.js +18 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatus.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.d.ts +15 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.js +315 -263
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.js +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/media/chatStatus.css +196 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/chatTipCatalog.js +56 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/chatTipEligibilityTracker.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatTipService.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatWindowNotifier.js +8 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/claudePluginRecommendations.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/defaultModelContribution.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/enablementActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/enablementStatusWidget.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/languageModelsConfigurationService.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/pluginGitCommandService.d.ts +18 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/pluginGitCommandService.js +31 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/pluginInstallService.js +26 -25
- package/vscode/src/vs/workbench/contrib/chat/browser/pluginSources.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/pluginSources.js +48 -57
- package/vscode/src/vs/workbench/contrib/chat/browser/pluginUrlHandler.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/chatModeActions.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookActions.js +26 -26
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookUtils.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookUtils.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionOverlay.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolsCodeLensProvider.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptUrlHandler.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/skillActions.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/promptsDebugContribution.d.ts +11 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/promptsDebugContribution.js +226 -36
- package/vscode/src/vs/workbench/contrib/chat/browser/telemetry/chatModelCountTelemetry.d.ts +23 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/telemetry/chatModelCountTelemetry.js +82 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsConfirmationService.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsConfirmationService.js +108 -56
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsService.js +24 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/renameTool.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/usagesTool.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcomeHandler.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatQueuePickerActionItem.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatStatusWidget.d.ts +3 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatStatusWidget.js +9 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.js +21 -80
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorContrib.js +26 -59
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorHover.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/chatQuick.js +4 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/editor/chatEditor.js +9 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.js +46 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewTitleControl.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/chatDebugEvents.d.ts +40 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatDebugEvents.js +60 -0
- package/vscode/src/vs/workbench/contrib/chat/common/chatDebugServiceImpl.d.ts +32 -5
- package/vscode/src/vs/workbench/contrib/chat/common/chatDebugServiceImpl.js +152 -26
- package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.d.ts +5 -9
- package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.js +265 -261
- package/vscode/src/vs/workbench/contrib/chat/common/model/chatModelStore.d.ts +28 -2
- package/vscode/src/vs/workbench/contrib/chat/common/model/chatModelStore.js +75 -7
- package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionOperationLog.js +9 -1
- package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionStore.js +6 -5
- package/vscode/src/vs/workbench/contrib/chat/common/model/objectMutationLog.d.ts +18 -0
- package/vscode/src/vs/workbench/contrib/chat/common/model/objectMutationLog.js +32 -4
- package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginService.d.ts +10 -25
- package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginServiceImpl.d.ts +7 -52
- package/vscode/src/vs/workbench/contrib/chat/common/plugins/agentPluginServiceImpl.js +58 -466
- package/vscode/src/vs/workbench/contrib/chat/common/plugins/workspacePluginSettingsService.js +3 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/chatPromptFilesContribution.js +36 -18
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.d.ts +0 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.js +168 -182
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.d.ts +49 -29
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.js +491 -462
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.d.ts +16 -6
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.js +18 -12
- package/vscode/src/vs/workbench/contrib/chat/common/tools/chatArtifactsService.d.ts +24 -4
- package/vscode/src/vs/workbench/contrib/chat/common/tools/chatArtifactsService.js +145 -68
- package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.js +1 -1
- package/vscode/src/vs/workbench/contrib/editTelemetry/browser/telemetry/aiEditTelemetry/aiEditTelemetryServiceImpl.js +2 -2
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChat.contribution.js +4 -4
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +25 -25
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatDefaultModel.js +2 -2
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatHistoryService.d.ts +2 -4
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatHistoryService.js +19 -17
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatNotebook.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatNotebook.js +3 -3
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.d.ts +5 -17
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.js +77 -157
- package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.js +14 -14
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.js +10 -10
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebook.chat.contribution.js +5 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatContext.js +1 -1
- package/vscode/src/vs/workbench/contrib/remoteCodingAgents/browser/remoteCodingAgents.contribution.js +7 -7
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibilityHelp.js +17 -17
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibleView.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatActions.js +21 -21
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatEnabler.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.d.ts +4 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatService.js +29 -7
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +2 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/taskHelpers.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.js +12 -14
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.js +4 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.d.ts +5 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.js +49 -12
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.js +4 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/killTerminalTool.js +9 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.js +13 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sendToTerminalTool.d.ts +53 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sendToTerminalTool.js +319 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.js +15 -15
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.js +8 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.js +15 -15
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.js +2 -2
- package/vscode/src/vs/workbench/services/agentHost/common/agentHostFileSystemService.d.ts +21 -0
- package/vscode/src/vs/workbench/services/agentHost/common/agentHostFileSystemService.js +35 -0
- package/vscode/src/vs/platform/agentHost/common/agentService.service.d.ts +0 -94
- package/vscode/src/vs/platform/agentHost/common/state/protocol/action-origin.generated.d.ts +0 -16
- package/vscode/src/vs/platform/agentHost/common/state/protocol/actions.d.ts +0 -578
- package/vscode/src/vs/platform/agentHost/common/state/protocol/messages.d.ts +0 -206
- package/vscode/src/vs/platform/agentHost/common/state/protocol/notifications.d.ts +0 -114
- package/vscode/src/vs/platform/agentHost/common/state/protocol/state.d.ts +0 -860
- package/vscode/src/vs/platform/agentHost/common/state/sessionState.d.ts +0 -27
- package/vscode/src/vs/platform/browserElements/common/browserElements.d.ts +0 -58
- package/vscode/src/vs/platform/browserElements/common/browserElements.js +0 -16
- package/vscode/src/vs/platform/sandbox/common/sandboxHelperIpc.d.ts +0 -18
- package/vscode/src/vs/platform/sandbox/common/sandboxHelperIpc.js +0 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/media/simpleBrowserOverlay.css +0 -85
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/simpleBrowserEditorOverlay.d.ts +0 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/simpleBrowserEditorOverlay.js +0 -443
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatUsageWidget.d.ts +0 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatUsageWidget.js +0 -132
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/media/chatUsageWidget.css +0 -69
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.d.ts +0 -65
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetup.js +0 -66
- package/vscode/src/vs/workbench/contrib/chat/common/chatArtifactExtraction.d.ts +0 -8
- package/vscode/src/vs/workbench/contrib/chat/common/chatArtifactExtraction.js +0 -158
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/alternativeRecommendation.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/alternativeRecommendation.js +0 -41
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/commandParsers/commandFileWriteParser.d.ts +0 -24
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/commandParsers/sedFileWriteParser.d.ts +0 -26
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/commandParsers/sedFileWriteParser.js +0 -142
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.d.ts +0 -45
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.js +0 -164
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.d.ts +0 -50
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.js +0 -163
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/noneExecuteStrategy.d.ts +0 -27
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/noneExecuteStrategy.js +0 -142
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.d.ts +0 -29
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.js +0 -137
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/strategyHelpers.d.ts +0 -40
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/strategyHelpers.js +0 -174
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/outputHelpers.d.ts +0 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/outputHelpers.js +0 -39
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.d.ts +0 -32
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +0 -249
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalToolTelemetry.d.ts +0 -41
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalToolTelemetry.js +0 -92
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.d.ts +0 -40
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.js +0 -209
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/awaitTerminalTool.d.ts +0 -12
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/awaitTerminalTool.js +0 -106
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/commandLineAutoApprover.d.ts +0 -31
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/commandLineAutoApprover.js +0 -392
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.d.ts +0 -45
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.js +0 -243
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAnalyzer.d.ts +0 -52
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAnalyzer.js +0 -10
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.d.ts +0 -20
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +0 -310
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.d.ts +0 -19
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +0 -168
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineSandboxAnalyzer.d.ts +0 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineSandboxAnalyzer.js +0 -25
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/commandLinePresenter.d.ts +0 -41
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/nodeCommandLinePresenter.d.ts +0 -19
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/nodeCommandLinePresenter.js +0 -37
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/pythonCommandLinePresenter.d.ts +0 -19
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/pythonCommandLinePresenter.js +0 -37
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/rubyCommandLinePresenter.d.ts +0 -19
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/rubyCommandLinePresenter.js +0 -44
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/sandboxedCommandLinePresenter.d.ts +0 -13
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLinePresenter/sandboxedCommandLinePresenter.js +0 -21
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineCdPrefixRewriter.d.ts +0 -5
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineCdPrefixRewriter.js +0 -27
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLinePreventHistoryRewriter.d.ts +0 -14
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLinePreventHistoryRewriter.js +0 -29
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLinePwshChainOperatorRewriter.d.ts +0 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLinePwshChainOperatorRewriter.js +0 -33
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineRewriter.d.ts +0 -20
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineSandboxRewriter.d.ts +0 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineSandboxRewriter.js +0 -28
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.d.ts +0 -118
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +0 -1019
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/types.d.ts +0 -49
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/types.js +0 -23
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/outputAnalyzer.d.ts +0 -9
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +0 -150
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +0 -1619
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sandboxOutputAnalyzer.d.ts +0 -22
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/sandboxOutputAnalyzer.js +0 -41
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/terminalCommandArtifactCollector.d.ts +0 -17
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/terminalCommandArtifactCollector.js +0 -118
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/toolIds.d.ts +0 -12
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/toolIds.js +0 -17
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/treeSitterCommandParser.d.ts +0 -25
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/treeSitterCommandParser.js +0 -130
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.d.ts +0 -122
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.js +0 -482
|
@@ -5,10 +5,10 @@ import { Iterable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/ite
|
|
|
5
5
|
import { Range } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/core/range';
|
|
6
6
|
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
7
7
|
import { IConfigurationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service';
|
|
8
|
-
import { MarkerSeverity } from '@codingame/monaco-vscode-api/vscode/vs/platform/markers/common/markers';
|
|
8
|
+
import { MarkerSeverity, MarkerTag } from '@codingame/monaco-vscode-api/vscode/vs/platform/markers/common/markers';
|
|
9
9
|
import { ChatMode } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatModes';
|
|
10
10
|
import { IChatModeService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatModes.service';
|
|
11
|
-
import { ChatModeKind
|
|
11
|
+
import { ChatModeKind } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants';
|
|
12
12
|
import { ILanguageModelChatMetadata } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModels';
|
|
13
13
|
import { ILanguageModelsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModels.service';
|
|
14
14
|
import { SpecedToolAliases } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService';
|
|
@@ -61,13 +61,13 @@ let PromptValidator = class PromptValidator {
|
|
|
61
61
|
const location = this.promptsService.getAgentFileURIFromModeFile(promptAST.uri);
|
|
62
62
|
if (location && (await this.fileService.canCreateFile(location))) {
|
|
63
63
|
report(toMarker(( localize(
|
|
64
|
-
|
|
64
|
+
7602,
|
|
65
65
|
"Chat modes have been renamed to agents. Please move this file to {0}",
|
|
66
66
|
(location.toString())
|
|
67
67
|
)), ( new Range(1, 1, 1, 4)), MarkerSeverity.Warning));
|
|
68
68
|
} else {
|
|
69
69
|
report(toMarker(( localize(
|
|
70
|
-
|
|
70
|
+
7603,
|
|
71
71
|
"Chat modes have been renamed to agents. Please move the file to {0}",
|
|
72
72
|
AGENTS_SOURCE_FOLDER
|
|
73
73
|
)), ( new Range(1, 1, 1, 4)), MarkerSeverity.Warning));
|
|
@@ -80,12 +80,12 @@ let PromptValidator = class PromptValidator {
|
|
|
80
80
|
}
|
|
81
81
|
const nameAttribute = promptAST.header?.attributes.find(attr => attr.key === PromptHeaderAttributes.name);
|
|
82
82
|
if (!nameAttribute) {
|
|
83
|
-
report(toMarker(( localize(
|
|
83
|
+
report(toMarker(( localize(7604, "Skill must provide a name.")), ( new Range(1, 1, 1, 4)), MarkerSeverity.Error));
|
|
84
84
|
return;
|
|
85
85
|
}
|
|
86
86
|
const descriptionAttribute = promptAST.header?.attributes.find(attr => attr.key === PromptHeaderAttributes.description);
|
|
87
87
|
if (!descriptionAttribute) {
|
|
88
|
-
report(toMarker(( localize(
|
|
88
|
+
report(toMarker(( localize(7605, "Skill must provide a description.")), ( new Range(1, 1, 1, 4)), MarkerSeverity.Error));
|
|
89
89
|
return;
|
|
90
90
|
}
|
|
91
91
|
if (nameAttribute.value.type === "scalar") {
|
|
@@ -93,7 +93,7 @@ let PromptValidator = class PromptValidator {
|
|
|
93
93
|
if (skillName.length > 0) {
|
|
94
94
|
if (!VALID_SKILL_NAME_REGEX.test(skillName)) {
|
|
95
95
|
report(toMarker(( localize(
|
|
96
|
-
|
|
96
|
+
7606,
|
|
97
97
|
"Skill name may only contain lowercase letters, numbers, and hyphens."
|
|
98
98
|
)), nameAttribute.value.range, MarkerSeverity.Error));
|
|
99
99
|
}
|
|
@@ -103,7 +103,7 @@ let PromptValidator = class PromptValidator {
|
|
|
103
103
|
const folderName = pathParts[skillIndex - 1];
|
|
104
104
|
if (folderName && skillName !== folderName) {
|
|
105
105
|
report(toMarker(( localize(
|
|
106
|
-
|
|
106
|
+
7607,
|
|
107
107
|
"The skill name '{0}' should match the folder name '{1}'.",
|
|
108
108
|
skillName,
|
|
109
109
|
folderName
|
|
@@ -122,7 +122,7 @@ let PromptValidator = class PromptValidator {
|
|
|
122
122
|
for (const ref of body.fileReferences) {
|
|
123
123
|
const resolved = body.resolveFilePath(ref.content);
|
|
124
124
|
if (!resolved) {
|
|
125
|
-
report(toMarker(( localize(
|
|
125
|
+
report(toMarker(( localize(7608, "Invalid file reference '{0}'.", ref.content)), ref.range, MarkerSeverity.Warning));
|
|
126
126
|
continue;
|
|
127
127
|
}
|
|
128
128
|
if (promptAST.uri.scheme === resolved.scheme) {
|
|
@@ -134,7 +134,7 @@ let PromptValidator = class PromptValidator {
|
|
|
134
134
|
}
|
|
135
135
|
} catch {}
|
|
136
136
|
const loc = this.labelService.getUriLabel(resolved);
|
|
137
|
-
report(toMarker(( localize(
|
|
137
|
+
report(toMarker(( localize(7609, "File '{0}' not found at '{1}'.", ref.content, loc)), ref.range, MarkerSeverity.Warning));
|
|
138
138
|
})());
|
|
139
139
|
}
|
|
140
140
|
}
|
|
@@ -151,7 +151,7 @@ let PromptValidator = class PromptValidator {
|
|
|
151
151
|
if (currentNames.size === 1) {
|
|
152
152
|
const newName = Array.from(currentNames)[0];
|
|
153
153
|
report(toMarker(( localize(
|
|
154
|
-
|
|
154
|
+
7610,
|
|
155
155
|
"Tool or toolset '{0}' has been renamed, use '{1}' instead.",
|
|
156
156
|
variable.name,
|
|
157
157
|
newName
|
|
@@ -159,7 +159,7 @@ let PromptValidator = class PromptValidator {
|
|
|
159
159
|
} else {
|
|
160
160
|
const newNames = Array.from(currentNames).sort((a, b) => a.localeCompare(b)).join(", ");
|
|
161
161
|
report(toMarker(( localize(
|
|
162
|
-
|
|
162
|
+
7611,
|
|
163
163
|
"Tool or toolset '{0}' has been renamed, use the following tools instead: {1}",
|
|
164
164
|
variable.name,
|
|
165
165
|
newNames
|
|
@@ -167,13 +167,13 @@ let PromptValidator = class PromptValidator {
|
|
|
167
167
|
}
|
|
168
168
|
}
|
|
169
169
|
} else {
|
|
170
|
-
report(toMarker(( localize(
|
|
170
|
+
report(toMarker(( localize(7612, "Unknown tool or toolset '{0}'.", variable.name)), variable.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
171
171
|
}
|
|
172
172
|
} else if (headerToolsMap) {
|
|
173
173
|
const tool = this.languageModelToolsService.getToolByFullReferenceName(variable.name);
|
|
174
174
|
if (tool && headerToolsMap.get(tool) === false) {
|
|
175
175
|
report(toMarker(( localize(
|
|
176
|
-
|
|
176
|
+
7613,
|
|
177
177
|
"Tool or toolset '{0}' also needs to be enabled in the header.",
|
|
178
178
|
variable.name
|
|
179
179
|
)), variable.range, MarkerSeverity.Warning));
|
|
@@ -256,62 +256,62 @@ let PromptValidator = class PromptValidator {
|
|
|
256
256
|
switch (promptType) {
|
|
257
257
|
case PromptsType.prompt:
|
|
258
258
|
report(toMarker(( localize(
|
|
259
|
-
|
|
259
|
+
7614,
|
|
260
260
|
"Attribute '{0}' is not supported in prompt files. Supported: {1}.",
|
|
261
261
|
attribute.key,
|
|
262
262
|
supportedNames.value
|
|
263
|
-
)), attribute.range, MarkerSeverity.
|
|
263
|
+
)), attribute.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
264
264
|
break;
|
|
265
265
|
case PromptsType.agent:
|
|
266
266
|
if (target === Target.GitHubCopilot) {
|
|
267
267
|
report(toMarker(( localize(
|
|
268
|
-
|
|
268
|
+
7615,
|
|
269
269
|
"Attribute '{0}' is not supported in custom GitHub Copilot agent files. Supported: {1}.",
|
|
270
270
|
attribute.key,
|
|
271
271
|
supportedNames.value
|
|
272
|
-
)), attribute.range, MarkerSeverity.
|
|
272
|
+
)), attribute.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
273
273
|
} else if (target === Target.Claude)
|
|
274
274
|
; else {
|
|
275
275
|
if (( validGithubCopilotAttributeNames.value.has(attribute.key))) {
|
|
276
276
|
report(toMarker(( localize(
|
|
277
|
-
|
|
277
|
+
7616,
|
|
278
278
|
"Attribute '{0}' is ignored when running locally in VS Code.",
|
|
279
279
|
attribute.key
|
|
280
|
-
)), attribute.range, MarkerSeverity.
|
|
280
|
+
)), attribute.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
281
281
|
} else {
|
|
282
282
|
report(toMarker(( localize(
|
|
283
|
-
|
|
283
|
+
7617,
|
|
284
284
|
"Attribute '{0}' is not supported in VS Code agent files. Supported: {1}.",
|
|
285
285
|
attribute.key,
|
|
286
286
|
supportedNames.value
|
|
287
|
-
)), attribute.range, MarkerSeverity.
|
|
287
|
+
)), attribute.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
288
288
|
}
|
|
289
289
|
}
|
|
290
290
|
break;
|
|
291
291
|
case PromptsType.instructions:
|
|
292
292
|
if (target === Target.Claude) {
|
|
293
293
|
report(toMarker(( localize(
|
|
294
|
-
|
|
295
|
-
"Attribute '{0}' is not supported in rules files. Supported: {1}.",
|
|
294
|
+
7618,
|
|
295
|
+
"Attribute '{0}' is not supported in rules files by VS Code agents. Supported: {1}.",
|
|
296
296
|
attribute.key,
|
|
297
297
|
supportedNames.value
|
|
298
|
-
)), attribute.range, MarkerSeverity.
|
|
298
|
+
)), attribute.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
299
299
|
} else {
|
|
300
300
|
report(toMarker(( localize(
|
|
301
|
-
|
|
301
|
+
7619,
|
|
302
302
|
"Attribute '{0}' is not supported in instructions files. Supported: {1}.",
|
|
303
303
|
attribute.key,
|
|
304
304
|
supportedNames.value
|
|
305
|
-
)), attribute.range, MarkerSeverity.
|
|
305
|
+
)), attribute.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
306
306
|
}
|
|
307
307
|
break;
|
|
308
308
|
case PromptsType.skill:
|
|
309
309
|
report(toMarker(( localize(
|
|
310
|
-
|
|
311
|
-
"Attribute '{0}' is not supported
|
|
310
|
+
7620,
|
|
311
|
+
"Attribute '{0}' is not supported by VS Code agents. Supported: {1}.",
|
|
312
312
|
attribute.key,
|
|
313
313
|
supportedNames.value
|
|
314
|
-
)), attribute.range, MarkerSeverity.
|
|
314
|
+
)), attribute.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
315
315
|
break;
|
|
316
316
|
}
|
|
317
317
|
}
|
|
@@ -323,11 +323,11 @@ let PromptValidator = class PromptValidator {
|
|
|
323
323
|
return;
|
|
324
324
|
}
|
|
325
325
|
if (nameAttribute.value.type !== "scalar") {
|
|
326
|
-
report(toMarker(( localize(
|
|
326
|
+
report(toMarker(( localize(7621, "The 'name' attribute must be a string.")), nameAttribute.range, MarkerSeverity.Error));
|
|
327
327
|
return;
|
|
328
328
|
}
|
|
329
329
|
if (nameAttribute.value.value.trim().length === 0) {
|
|
330
|
-
report(toMarker(( localize(
|
|
330
|
+
report(toMarker(( localize(7622, "The 'name' attribute must not be empty.")), nameAttribute.value.range, MarkerSeverity.Error));
|
|
331
331
|
return;
|
|
332
332
|
}
|
|
333
333
|
}
|
|
@@ -337,11 +337,11 @@ let PromptValidator = class PromptValidator {
|
|
|
337
337
|
return;
|
|
338
338
|
}
|
|
339
339
|
if (descriptionAttribute.value.type !== "scalar") {
|
|
340
|
-
report(toMarker(( localize(
|
|
340
|
+
report(toMarker(( localize(7623, "The 'description' attribute must be a string.")), descriptionAttribute.range, MarkerSeverity.Error));
|
|
341
341
|
return;
|
|
342
342
|
}
|
|
343
343
|
if (descriptionAttribute.value.value.trim().length === 0) {
|
|
344
|
-
report(toMarker(( localize(
|
|
344
|
+
report(toMarker(( localize(7624, "The 'description' attribute should not be empty.")), descriptionAttribute.value.range, MarkerSeverity.Error));
|
|
345
345
|
return;
|
|
346
346
|
}
|
|
347
347
|
}
|
|
@@ -351,11 +351,11 @@ let PromptValidator = class PromptValidator {
|
|
|
351
351
|
return;
|
|
352
352
|
}
|
|
353
353
|
if (argumentHintAttribute.value.type !== "scalar") {
|
|
354
|
-
report(toMarker(( localize(
|
|
354
|
+
report(toMarker(( localize(7625, "The 'argument-hint' attribute must be a string.")), argumentHintAttribute.range, MarkerSeverity.Error));
|
|
355
355
|
return;
|
|
356
356
|
}
|
|
357
357
|
if (argumentHintAttribute.value.value.trim().length === 0) {
|
|
358
|
-
report(toMarker(( localize(
|
|
358
|
+
report(toMarker(( localize(7626, "The 'argument-hint' attribute should not be empty.")), argumentHintAttribute.value.range, MarkerSeverity.Warning));
|
|
359
359
|
return;
|
|
360
360
|
}
|
|
361
361
|
}
|
|
@@ -365,30 +365,30 @@ let PromptValidator = class PromptValidator {
|
|
|
365
365
|
return;
|
|
366
366
|
}
|
|
367
367
|
if (attribute.value.type !== "scalar" && attribute.value.type !== "sequence") {
|
|
368
|
-
report(toMarker(( localize(
|
|
368
|
+
report(toMarker(( localize(7627, "The 'model' attribute must be a string or an array of strings.")), attribute.value.range, MarkerSeverity.Error));
|
|
369
369
|
return;
|
|
370
370
|
}
|
|
371
371
|
const modelNames = [];
|
|
372
372
|
if (attribute.value.type === "scalar") {
|
|
373
373
|
const modelName = attribute.value.value.trim();
|
|
374
374
|
if (modelName.length === 0) {
|
|
375
|
-
report(toMarker(( localize(
|
|
375
|
+
report(toMarker(( localize(7628, "The 'model' attribute must be a non-empty string.")), attribute.value.range, MarkerSeverity.Error));
|
|
376
376
|
return;
|
|
377
377
|
}
|
|
378
378
|
modelNames.push([modelName, attribute.value.range]);
|
|
379
379
|
} else if (attribute.value.type === "sequence") {
|
|
380
380
|
if (attribute.value.items.length === 0) {
|
|
381
|
-
report(toMarker(( localize(
|
|
381
|
+
report(toMarker(( localize(7629, "The 'model' array must not be empty.")), attribute.value.range, MarkerSeverity.Error));
|
|
382
382
|
return;
|
|
383
383
|
}
|
|
384
384
|
for (const item of attribute.value.items) {
|
|
385
385
|
if (item.type !== "scalar") {
|
|
386
|
-
report(toMarker(( localize(
|
|
386
|
+
report(toMarker(( localize(7630, "The 'model' array must contain only strings.")), item.range, MarkerSeverity.Error));
|
|
387
387
|
return;
|
|
388
388
|
}
|
|
389
389
|
const modelName = item.value.trim();
|
|
390
390
|
if (modelName.length === 0) {
|
|
391
|
-
report(toMarker(( localize(
|
|
391
|
+
report(toMarker(( localize(7631, "Model names in the array must be non-empty strings.")), item.range, MarkerSeverity.Error));
|
|
392
392
|
return;
|
|
393
393
|
}
|
|
394
394
|
modelNames.push([modelName, item.range]);
|
|
@@ -401,9 +401,9 @@ let PromptValidator = class PromptValidator {
|
|
|
401
401
|
for (const [modelName, range] of modelNames) {
|
|
402
402
|
const modelMetadata = this.findModelByName(modelName);
|
|
403
403
|
if (!modelMetadata) {
|
|
404
|
-
report(toMarker(( localize(
|
|
404
|
+
report(toMarker(( localize(7632, "Unknown model '{0}' will be ignored.", modelName)), range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
405
405
|
} else if (agentKind === ChatModeKind.Agent && !ILanguageModelChatMetadata.suitableForAgentMode(modelMetadata)) {
|
|
406
|
-
report(toMarker(( localize(
|
|
406
|
+
report(toMarker(( localize(7633, "Model '{0}' is not suited for agent mode.", modelName)), range, MarkerSeverity.Warning));
|
|
407
407
|
}
|
|
408
408
|
}
|
|
409
409
|
}
|
|
@@ -417,13 +417,13 @@ let PromptValidator = class PromptValidator {
|
|
|
417
417
|
continue;
|
|
418
418
|
}
|
|
419
419
|
if (attribute.value.type !== "scalar") {
|
|
420
|
-
report(toMarker(( localize(
|
|
420
|
+
report(toMarker(( localize(7634, "The '{0}' attribute must be a string.", claudeAttributeName)), attribute.value.range, MarkerSeverity.Error));
|
|
421
421
|
continue;
|
|
422
422
|
} else {
|
|
423
423
|
const modelName = attribute.value.value.trim();
|
|
424
424
|
if (enumValues.every(model => model.name !== modelName)) {
|
|
425
425
|
const validValues = ( enumValues.map(model => model.name)).join(", ");
|
|
426
|
-
report(toMarker(( localize(
|
|
426
|
+
report(toMarker(( localize(7635, "Unknown value '{0}', valid: {1}.", modelName, validValues)), attribute.value.range, MarkerSeverity.Warning));
|
|
427
427
|
}
|
|
428
428
|
}
|
|
429
429
|
}
|
|
@@ -442,14 +442,14 @@ let PromptValidator = class PromptValidator {
|
|
|
442
442
|
if (modeAttribute) {
|
|
443
443
|
if (agentAttribute) {
|
|
444
444
|
report(toMarker(( localize(
|
|
445
|
-
|
|
445
|
+
7636,
|
|
446
446
|
"The 'mode' attribute has been deprecated. The 'agent' attribute is used instead."
|
|
447
|
-
)), modeAttribute.range, MarkerSeverity.Warning));
|
|
447
|
+
)), modeAttribute.range, MarkerSeverity.Warning, [MarkerTag.Deprecated]));
|
|
448
448
|
} else {
|
|
449
449
|
report(toMarker(( localize(
|
|
450
|
-
|
|
450
|
+
7637,
|
|
451
451
|
"The 'mode' attribute has been deprecated. Please rename it to 'agent'."
|
|
452
|
-
)), modeAttribute.range, MarkerSeverity.
|
|
452
|
+
)), modeAttribute.range, MarkerSeverity.Warning, [MarkerTag.Deprecated]));
|
|
453
453
|
}
|
|
454
454
|
}
|
|
455
455
|
const attribute = attributes.find(attr => attr.key === PromptHeaderAttributes.agent) ?? modeAttribute;
|
|
@@ -457,12 +457,12 @@ let PromptValidator = class PromptValidator {
|
|
|
457
457
|
return undefined;
|
|
458
458
|
}
|
|
459
459
|
if (attribute.value.type !== "scalar") {
|
|
460
|
-
report(toMarker(( localize(
|
|
460
|
+
report(toMarker(( localize(7638, "The '{0}' attribute must be a string.", attribute.key)), attribute.value.range, MarkerSeverity.Error));
|
|
461
461
|
return undefined;
|
|
462
462
|
}
|
|
463
463
|
const agentValue = attribute.value.value;
|
|
464
464
|
if (agentValue.trim().length === 0) {
|
|
465
|
-
report(toMarker(( localize(
|
|
465
|
+
report(toMarker(( localize(7639, "The '{0}' attribute must be a non-empty string.", attribute.key)), attribute.value.range, MarkerSeverity.Error));
|
|
466
466
|
return undefined;
|
|
467
467
|
}
|
|
468
468
|
return this.validateAgentValue(attribute.value, report);
|
|
@@ -477,7 +477,7 @@ let PromptValidator = class PromptValidator {
|
|
|
477
477
|
availableAgents.push(agent.name.get());
|
|
478
478
|
}
|
|
479
479
|
const errorMessage = ( localize(
|
|
480
|
-
|
|
480
|
+
7640,
|
|
481
481
|
"Unknown agent '{0}'. Available agents: {1}.",
|
|
482
482
|
value.value,
|
|
483
483
|
availableAgents.join(", ")
|
|
@@ -492,7 +492,7 @@ let PromptValidator = class PromptValidator {
|
|
|
492
492
|
}
|
|
493
493
|
if (agentKind !== ChatModeKind.Agent) {
|
|
494
494
|
report(toMarker(( localize(
|
|
495
|
-
|
|
495
|
+
7641,
|
|
496
496
|
"The 'tools' attribute is only supported when using agents. Attribute will be ignored."
|
|
497
497
|
)), attribute.range, MarkerSeverity.Warning));
|
|
498
498
|
}
|
|
@@ -502,7 +502,7 @@ let PromptValidator = class PromptValidator {
|
|
|
502
502
|
}
|
|
503
503
|
if (value.type !== "sequence") {
|
|
504
504
|
report(toMarker(( localize(
|
|
505
|
-
|
|
505
|
+
7642,
|
|
506
506
|
"The 'tools' attribute must be an array or a comma separated string."
|
|
507
507
|
)), attribute.value.range, MarkerSeverity.Error));
|
|
508
508
|
return;
|
|
@@ -518,7 +518,7 @@ let PromptValidator = class PromptValidator {
|
|
|
518
518
|
const deprecatedNames = this.languageModelToolsService.getDeprecatedFullReferenceNames();
|
|
519
519
|
for (const item of valueItem.items) {
|
|
520
520
|
if (item.type !== "scalar") {
|
|
521
|
-
report(toMarker(( localize(
|
|
521
|
+
report(toMarker(( localize(7643, "Each tool name in the 'tools' attribute must be a string.")), item.range, MarkerSeverity.Error));
|
|
522
522
|
} else if (item.value) {
|
|
523
523
|
if (!( available.has(item.value))) {
|
|
524
524
|
const currentNames = deprecatedNames.get(item.value);
|
|
@@ -526,22 +526,22 @@ let PromptValidator = class PromptValidator {
|
|
|
526
526
|
if (currentNames?.size === 1) {
|
|
527
527
|
const newName = Array.from(currentNames)[0];
|
|
528
528
|
report(toMarker(( localize(
|
|
529
|
-
|
|
529
|
+
7644,
|
|
530
530
|
"Tool or toolset '{0}' has been renamed, use '{1}' instead.",
|
|
531
531
|
item.value,
|
|
532
532
|
newName
|
|
533
|
-
)), item.range, MarkerSeverity.Info));
|
|
533
|
+
)), item.range, MarkerSeverity.Info, [MarkerTag.Deprecated]));
|
|
534
534
|
} else {
|
|
535
535
|
const newNames = Array.from(currentNames).sort((a, b) => a.localeCompare(b)).join(", ");
|
|
536
536
|
report(toMarker(( localize(
|
|
537
|
-
|
|
537
|
+
7645,
|
|
538
538
|
"Tool or toolset '{0}' has been renamed, use the following tools instead: {1}",
|
|
539
539
|
item.value,
|
|
540
540
|
newNames
|
|
541
|
-
)), item.range, MarkerSeverity.Info));
|
|
541
|
+
)), item.range, MarkerSeverity.Info, [MarkerTag.Deprecated]));
|
|
542
542
|
}
|
|
543
543
|
} else {
|
|
544
|
-
report(toMarker(( localize(
|
|
544
|
+
report(toMarker(( localize(7646, "Unknown tool '{0}' will be ignored.", item.value)), item.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
545
545
|
}
|
|
546
546
|
}
|
|
547
547
|
}
|
|
@@ -554,25 +554,25 @@ let PromptValidator = class PromptValidator {
|
|
|
554
554
|
return;
|
|
555
555
|
}
|
|
556
556
|
if (attribute.value.type !== "scalar") {
|
|
557
|
-
report(toMarker(( localize(
|
|
557
|
+
report(toMarker(( localize(7647, "The 'applyTo' attribute must be a string.")), attribute.value.range, MarkerSeverity.Error));
|
|
558
558
|
return;
|
|
559
559
|
}
|
|
560
560
|
const pattern = attribute.value.value;
|
|
561
561
|
try {
|
|
562
562
|
const patterns = splitGlobAware(pattern, ",");
|
|
563
563
|
if (patterns.length === 0) {
|
|
564
|
-
report(toMarker(( localize(
|
|
564
|
+
report(toMarker(( localize(7648, "The 'applyTo' attribute must be a valid glob pattern.")), attribute.value.range, MarkerSeverity.Error));
|
|
565
565
|
return;
|
|
566
566
|
}
|
|
567
567
|
for (const pattern of patterns) {
|
|
568
568
|
const globPattern = parse(pattern);
|
|
569
569
|
if (isEmptyPattern(globPattern)) {
|
|
570
|
-
report(toMarker(( localize(
|
|
570
|
+
report(toMarker(( localize(7648, "The 'applyTo' attribute must be a valid glob pattern.")), attribute.value.range, MarkerSeverity.Error));
|
|
571
571
|
return;
|
|
572
572
|
}
|
|
573
573
|
}
|
|
574
574
|
} catch (_error) {
|
|
575
|
-
report(toMarker(( localize(
|
|
575
|
+
report(toMarker(( localize(7648, "The 'applyTo' attribute must be a valid glob pattern.")), attribute.value.range, MarkerSeverity.Error));
|
|
576
576
|
}
|
|
577
577
|
}
|
|
578
578
|
validatePaths(attributes, report) {
|
|
@@ -581,26 +581,26 @@ let PromptValidator = class PromptValidator {
|
|
|
581
581
|
return;
|
|
582
582
|
}
|
|
583
583
|
if (attribute.value.type !== "sequence") {
|
|
584
|
-
report(toMarker(( localize(
|
|
584
|
+
report(toMarker(( localize(7649, "The 'paths' attribute must be an array of glob patterns.")), attribute.value.range, MarkerSeverity.Error));
|
|
585
585
|
return;
|
|
586
586
|
}
|
|
587
587
|
for (const item of attribute.value.items) {
|
|
588
588
|
if (item.type !== "scalar") {
|
|
589
|
-
report(toMarker(( localize(
|
|
589
|
+
report(toMarker(( localize(7650, "Each entry in the 'paths' attribute must be a string.")), item.range, MarkerSeverity.Error));
|
|
590
590
|
continue;
|
|
591
591
|
}
|
|
592
592
|
const pattern = item.value.trim();
|
|
593
593
|
if (pattern.length === 0) {
|
|
594
|
-
report(toMarker(( localize(
|
|
594
|
+
report(toMarker(( localize(7651, "Path entries must be non-empty glob patterns.")), item.range, MarkerSeverity.Error));
|
|
595
595
|
continue;
|
|
596
596
|
}
|
|
597
597
|
try {
|
|
598
598
|
const globPattern = parse(pattern);
|
|
599
599
|
if (isEmptyPattern(globPattern)) {
|
|
600
|
-
report(toMarker(( localize(
|
|
600
|
+
report(toMarker(( localize(7652, "'{0}' is not a valid glob pattern.", pattern)), item.range, MarkerSeverity.Error));
|
|
601
601
|
}
|
|
602
602
|
} catch (_error) {
|
|
603
|
-
report(toMarker(( localize(
|
|
603
|
+
report(toMarker(( localize(7652, "'{0}' is not a valid glob pattern.", pattern)), item.range, MarkerSeverity.Error));
|
|
604
604
|
}
|
|
605
605
|
}
|
|
606
606
|
}
|
|
@@ -610,7 +610,7 @@ let PromptValidator = class PromptValidator {
|
|
|
610
610
|
return;
|
|
611
611
|
}
|
|
612
612
|
if (attribute.value.type !== "sequence" && attribute.value.type !== "scalar") {
|
|
613
|
-
report(toMarker(( localize(
|
|
613
|
+
report(toMarker(( localize(7653, "The 'excludeAgent' attribute must be an string or array.")), attribute.value.range, MarkerSeverity.Error));
|
|
614
614
|
return;
|
|
615
615
|
}
|
|
616
616
|
}
|
|
@@ -621,7 +621,7 @@ let PromptValidator = class PromptValidator {
|
|
|
621
621
|
}
|
|
622
622
|
if (attribute.value.type !== "map") {
|
|
623
623
|
report(toMarker(( localize(
|
|
624
|
-
|
|
624
|
+
7654,
|
|
625
625
|
"The 'hooks' attribute must be a map of hook event types to command arrays."
|
|
626
626
|
)), attribute.value.range, MarkerSeverity.Error));
|
|
627
627
|
return;
|
|
@@ -630,7 +630,7 @@ let PromptValidator = class PromptValidator {
|
|
|
630
630
|
for (const prop of attribute.value.properties) {
|
|
631
631
|
if (!( validHookNames.has(prop.key.value))) {
|
|
632
632
|
report(toMarker(( localize(
|
|
633
|
-
|
|
633
|
+
7655,
|
|
634
634
|
"Unknown hook event type '{0}'. Supported: {1}.",
|
|
635
635
|
prop.key.value,
|
|
636
636
|
Array.from(validHookNames).join(", ")
|
|
@@ -638,7 +638,7 @@ let PromptValidator = class PromptValidator {
|
|
|
638
638
|
}
|
|
639
639
|
if (prop.value.type !== "sequence") {
|
|
640
640
|
report(toMarker(( localize(
|
|
641
|
-
|
|
641
|
+
7656,
|
|
642
642
|
"Hook event '{0}' must have an array of command objects as its value.",
|
|
643
643
|
prop.key.value
|
|
644
644
|
)), prop.value.range, MarkerSeverity.Error));
|
|
@@ -651,19 +651,19 @@ let PromptValidator = class PromptValidator {
|
|
|
651
651
|
}
|
|
652
652
|
validateHookCommand(item, target, report) {
|
|
653
653
|
if (item.type !== "map") {
|
|
654
|
-
report(toMarker(( localize(
|
|
654
|
+
report(toMarker(( localize(7657, "Each hook command must be an object.")), item.range, MarkerSeverity.Error));
|
|
655
655
|
return;
|
|
656
656
|
}
|
|
657
657
|
const hooksProperty = item.properties.find(p => p.key.value === "hooks");
|
|
658
658
|
if (hooksProperty) {
|
|
659
659
|
for (const prop of item.properties) {
|
|
660
660
|
if (prop.key.value !== "hooks" && prop.key.value !== "matcher") {
|
|
661
|
-
report(toMarker(( localize(
|
|
661
|
+
report(toMarker(( localize(7658, "Unknown property '{0}' in hook matcher.", prop.key.value)), prop.key.range, MarkerSeverity.Warning));
|
|
662
662
|
}
|
|
663
663
|
}
|
|
664
664
|
if (hooksProperty.value.type !== "sequence") {
|
|
665
665
|
report(toMarker(( localize(
|
|
666
|
-
|
|
666
|
+
7659,
|
|
667
667
|
"The 'hooks' property in a matcher must be an array of command objects."
|
|
668
668
|
)), hooksProperty.value.range, MarkerSeverity.Error));
|
|
669
669
|
return;
|
|
@@ -692,37 +692,37 @@ let PromptValidator = class PromptValidator {
|
|
|
692
692
|
for (const prop of item.properties) {
|
|
693
693
|
const key = prop.key.value;
|
|
694
694
|
if (!( validProperties.has(key))) {
|
|
695
|
-
report(toMarker(( localize(
|
|
695
|
+
report(toMarker(( localize(7660, "Unknown property '{0}' in hook command.", key)), prop.key.range, MarkerSeverity.Warning));
|
|
696
696
|
}
|
|
697
697
|
if (key === "type") {
|
|
698
698
|
hasType = true;
|
|
699
699
|
if (prop.value.type !== "scalar" || prop.value.value !== "command") {
|
|
700
|
-
report(toMarker(( localize(
|
|
700
|
+
report(toMarker(( localize(7661, "The 'type' property in a hook command must be 'command'.")), prop.value.range, MarkerSeverity.Error));
|
|
701
701
|
}
|
|
702
702
|
} else if (( validCommandFields.has(key))) {
|
|
703
703
|
hasCommandField = true;
|
|
704
704
|
if (prop.value.type !== "scalar" || prop.value.value.trim().length === 0) {
|
|
705
705
|
report(toMarker(( localize(
|
|
706
|
-
|
|
706
|
+
7662,
|
|
707
707
|
"The '{0}' property in a hook command must be a non-empty string.",
|
|
708
708
|
key
|
|
709
709
|
)), prop.value.range, MarkerSeverity.Error));
|
|
710
710
|
}
|
|
711
711
|
} else if (key === "cwd") {
|
|
712
712
|
if (prop.value.type !== "scalar") {
|
|
713
|
-
report(toMarker(( localize(
|
|
713
|
+
report(toMarker(( localize(7663, "The 'cwd' property in a hook command must be a string.")), prop.value.range, MarkerSeverity.Error));
|
|
714
714
|
}
|
|
715
715
|
} else if (key === "env") {
|
|
716
716
|
if (prop.value.type !== "map") {
|
|
717
717
|
report(toMarker(( localize(
|
|
718
|
-
|
|
718
|
+
7664,
|
|
719
719
|
"The 'env' property in a hook command must be a map of string values."
|
|
720
720
|
)), prop.value.range, MarkerSeverity.Error));
|
|
721
721
|
} else {
|
|
722
722
|
for (const envProp of prop.value.properties) {
|
|
723
723
|
if (envProp.value.type !== "scalar") {
|
|
724
724
|
report(toMarker(( localize(
|
|
725
|
-
|
|
725
|
+
7665,
|
|
726
726
|
"Environment variable '{0}' must have a string value.",
|
|
727
727
|
envProp.key.value
|
|
728
728
|
)), envProp.value.range, MarkerSeverity.Error));
|
|
@@ -731,19 +731,19 @@ let PromptValidator = class PromptValidator {
|
|
|
731
731
|
}
|
|
732
732
|
} else if (key === "timeout" || key === "timeoutSec") {
|
|
733
733
|
if (prop.value.type !== "scalar" || isNaN(Number(prop.value.value))) {
|
|
734
|
-
report(toMarker(( localize(
|
|
734
|
+
report(toMarker(( localize(7666, "The '{0}' property in a hook command must be a number.", key)), prop.value.range, MarkerSeverity.Error));
|
|
735
735
|
}
|
|
736
736
|
}
|
|
737
737
|
}
|
|
738
738
|
if (!hasType) {
|
|
739
|
-
report(toMarker(( localize(
|
|
739
|
+
report(toMarker(( localize(7667, "Hook command is missing required property 'type'.")), item.range, MarkerSeverity.Error));
|
|
740
740
|
}
|
|
741
741
|
if (!hasCommandField) {
|
|
742
742
|
if (isCopilotCli) {
|
|
743
|
-
report(toMarker(( localize(
|
|
743
|
+
report(toMarker(( localize(7668, "Hook command must specify at least one of 'bash' or 'powershell'.")), item.range, MarkerSeverity.Error));
|
|
744
744
|
} else {
|
|
745
745
|
report(toMarker(( localize(
|
|
746
|
-
|
|
746
|
+
7669,
|
|
747
747
|
"Hook command must specify at least one of 'command', 'windows', 'linux', or 'osx'."
|
|
748
748
|
)), item.range, MarkerSeverity.Error));
|
|
749
749
|
}
|
|
@@ -755,14 +755,14 @@ let PromptValidator = class PromptValidator {
|
|
|
755
755
|
return;
|
|
756
756
|
}
|
|
757
757
|
if (attribute.value.type !== "sequence") {
|
|
758
|
-
report(toMarker(( localize(
|
|
758
|
+
report(toMarker(( localize(7670, "The 'handoffs' attribute must be an array.")), attribute.value.range, MarkerSeverity.Error));
|
|
759
759
|
return;
|
|
760
760
|
}
|
|
761
761
|
const seenLabels = ( new Map());
|
|
762
762
|
for (const item of attribute.value.items) {
|
|
763
763
|
if (item.type !== "map") {
|
|
764
764
|
report(toMarker(( localize(
|
|
765
|
-
|
|
765
|
+
7671,
|
|
766
766
|
"Each handoff in the 'handoffs' attribute must be an object with 'label', 'agent', 'prompt' and optional 'send'."
|
|
767
767
|
)), item.range, MarkerSeverity.Error));
|
|
768
768
|
continue;
|
|
@@ -772,44 +772,44 @@ let PromptValidator = class PromptValidator {
|
|
|
772
772
|
switch (prop.key.value) {
|
|
773
773
|
case "label":
|
|
774
774
|
if (prop.value.type !== "scalar" || prop.value.value.trim().length === 0) {
|
|
775
|
-
report(toMarker(( localize(
|
|
775
|
+
report(toMarker(( localize(7672, "The 'label' property in a handoff must be a non-empty string.")), prop.value.range, MarkerSeverity.Error));
|
|
776
776
|
} else if (!/[a-zA-Z0-9]/.test(prop.value.value)) {
|
|
777
777
|
report(toMarker(( localize(
|
|
778
|
-
|
|
778
|
+
7673,
|
|
779
779
|
"The 'label' property in a handoff must contain at least one alphanumeric character."
|
|
780
780
|
)), prop.value.range, MarkerSeverity.Error));
|
|
781
781
|
}
|
|
782
782
|
break;
|
|
783
783
|
case "agent":
|
|
784
784
|
if (prop.value.type !== "scalar" || prop.value.value.trim().length === 0) {
|
|
785
|
-
report(toMarker(( localize(
|
|
785
|
+
report(toMarker(( localize(7674, "The 'agent' property in a handoff must be a non-empty string.")), prop.value.range, MarkerSeverity.Error));
|
|
786
786
|
} else {
|
|
787
787
|
this.validateAgentValue(prop.value, report);
|
|
788
788
|
}
|
|
789
789
|
break;
|
|
790
790
|
case "prompt":
|
|
791
791
|
if (prop.value.type !== "scalar") {
|
|
792
|
-
report(toMarker(( localize(
|
|
792
|
+
report(toMarker(( localize(7675, "The 'prompt' property in a handoff must be a string.")), prop.value.range, MarkerSeverity.Error));
|
|
793
793
|
}
|
|
794
794
|
break;
|
|
795
795
|
case "send":
|
|
796
796
|
if (!isTrueOrFalse(prop.value)) {
|
|
797
|
-
report(toMarker(( localize(
|
|
797
|
+
report(toMarker(( localize(7676, "The 'send' property in a handoff must be a boolean.")), prop.value.range, MarkerSeverity.Error));
|
|
798
798
|
}
|
|
799
799
|
break;
|
|
800
800
|
case "showContinueOn":
|
|
801
801
|
if (!isTrueOrFalse(prop.value)) {
|
|
802
|
-
report(toMarker(( localize(
|
|
802
|
+
report(toMarker(( localize(7677, "The 'showContinueOn' property in a handoff must be a boolean.")), prop.value.range, MarkerSeverity.Error));
|
|
803
803
|
}
|
|
804
804
|
break;
|
|
805
805
|
case "model":
|
|
806
806
|
if (prop.value.type !== "scalar") {
|
|
807
|
-
report(toMarker(( localize(
|
|
807
|
+
report(toMarker(( localize(7678, "The 'model' property in a handoff must be a string.")), prop.value.range, MarkerSeverity.Error));
|
|
808
808
|
}
|
|
809
809
|
break;
|
|
810
810
|
default:
|
|
811
811
|
report(toMarker(( localize(
|
|
812
|
-
|
|
812
|
+
7679,
|
|
813
813
|
"Unknown property '{0}' in handoff object. Supported properties are 'label', 'agent', 'prompt' and optional 'send', 'showContinueOn', 'model'.",
|
|
814
814
|
prop.key.value
|
|
815
815
|
)), prop.value.range, MarkerSeverity.Warning));
|
|
@@ -818,7 +818,7 @@ let PromptValidator = class PromptValidator {
|
|
|
818
818
|
}
|
|
819
819
|
if (required.size > 0) {
|
|
820
820
|
report(toMarker(( localize(
|
|
821
|
-
|
|
821
|
+
7680,
|
|
822
822
|
"Missing required properties {0} in handoff object.",
|
|
823
823
|
( Array.from(required).map(s => `'${s}'`)).join(", ")
|
|
824
824
|
)), item.range, MarkerSeverity.Error));
|
|
@@ -828,7 +828,7 @@ let PromptValidator = class PromptValidator {
|
|
|
828
828
|
const normalizedLabel = labelProp.value.value.toLowerCase();
|
|
829
829
|
if (normalizedLabel && ( seenLabels.has(normalizedLabel))) {
|
|
830
830
|
report(toMarker(( localize(
|
|
831
|
-
|
|
831
|
+
7681,
|
|
832
832
|
"Duplicate handoff label '{0}'. Each handoff must have a unique label.",
|
|
833
833
|
labelProp.value.value
|
|
834
834
|
)), labelProp.value.range, MarkerSeverity.Error));
|
|
@@ -844,7 +844,7 @@ let PromptValidator = class PromptValidator {
|
|
|
844
844
|
return;
|
|
845
845
|
}
|
|
846
846
|
report(toMarker(( localize(
|
|
847
|
-
|
|
847
|
+
7682,
|
|
848
848
|
"The 'infer' attribute is deprecated in favour of 'user-invocable' and 'disable-model-invocation'."
|
|
849
849
|
)), attribute.value.range, MarkerSeverity.Error));
|
|
850
850
|
}
|
|
@@ -854,18 +854,18 @@ let PromptValidator = class PromptValidator {
|
|
|
854
854
|
return;
|
|
855
855
|
}
|
|
856
856
|
if (attribute.value.type !== "scalar") {
|
|
857
|
-
report(toMarker(( localize(
|
|
857
|
+
report(toMarker(( localize(7683, "The 'target' attribute must be a string.")), attribute.value.range, MarkerSeverity.Error));
|
|
858
858
|
return;
|
|
859
859
|
}
|
|
860
860
|
const targetValue = attribute.value.value.trim();
|
|
861
861
|
if (targetValue.length === 0) {
|
|
862
|
-
report(toMarker(( localize(
|
|
862
|
+
report(toMarker(( localize(7684, "The 'target' attribute must be a non-empty string.")), attribute.value.range, MarkerSeverity.Error));
|
|
863
863
|
return;
|
|
864
864
|
}
|
|
865
865
|
const validTargets = ["github-copilot", "vscode"];
|
|
866
866
|
if (!validTargets.includes(targetValue)) {
|
|
867
867
|
report(toMarker(( localize(
|
|
868
|
-
|
|
868
|
+
7685,
|
|
869
869
|
"The 'target' attribute must be one of: {0}.",
|
|
870
870
|
validTargets.join(", ")
|
|
871
871
|
)), attribute.value.range, MarkerSeverity.Error));
|
|
@@ -877,7 +877,7 @@ let PromptValidator = class PromptValidator {
|
|
|
877
877
|
return;
|
|
878
878
|
}
|
|
879
879
|
if (!isTrueOrFalse(attribute.value)) {
|
|
880
|
-
report(toMarker(( localize(
|
|
880
|
+
report(toMarker(( localize(7686, "The 'user-invocable' attribute must be 'true' or 'false'.")), attribute.value.range, MarkerSeverity.Error));
|
|
881
881
|
return;
|
|
882
882
|
}
|
|
883
883
|
}
|
|
@@ -888,19 +888,11 @@ let PromptValidator = class PromptValidator {
|
|
|
888
888
|
}
|
|
889
889
|
if (!isTrueOrFalse(attribute.value)) {
|
|
890
890
|
report(toMarker(( localize(
|
|
891
|
-
|
|
891
|
+
7687,
|
|
892
892
|
"The 'disable-model-invocation' attribute must be 'true' or 'false'."
|
|
893
893
|
)), attribute.value.range, MarkerSeverity.Error));
|
|
894
894
|
return;
|
|
895
895
|
}
|
|
896
|
-
if (attribute.value.type === "scalar" && attribute.value.value === "false") {
|
|
897
|
-
if (!this.isCustomAgentInSubagentEnabled()) {
|
|
898
|
-
report(toMarker(( localize(
|
|
899
|
-
7561,
|
|
900
|
-
"For agents to be used as subagent you also need to enable the 'chat.customAgentInSubagent.enabled' setting."
|
|
901
|
-
)), attribute.value.range, MarkerSeverity.Warning));
|
|
902
|
-
}
|
|
903
|
-
}
|
|
904
896
|
}
|
|
905
897
|
async validateAgentsAttribute(attributes, header, report) {
|
|
906
898
|
const attribute = attributes.find(attr => attr.key === PromptHeaderAttributes.agents);
|
|
@@ -908,31 +900,25 @@ let PromptValidator = class PromptValidator {
|
|
|
908
900
|
return;
|
|
909
901
|
}
|
|
910
902
|
if (attribute.value.type !== "sequence") {
|
|
911
|
-
report(toMarker(( localize(
|
|
903
|
+
report(toMarker(( localize(7688, "The 'agents' attribute must be an array.")), attribute.value.range, MarkerSeverity.Error));
|
|
912
904
|
return;
|
|
913
905
|
}
|
|
914
|
-
if (!this.isCustomAgentInSubagentEnabled()) {
|
|
915
|
-
report(toMarker(( localize(
|
|
916
|
-
7563,
|
|
917
|
-
"For agents to be used as subagent you also need to enable the 'chat.customAgentInSubagent.enabled' setting."
|
|
918
|
-
)), attribute.range, MarkerSeverity.Warning));
|
|
919
|
-
}
|
|
920
906
|
const agents = await this.promptsService.getCustomAgents(CancellationToken.None);
|
|
921
907
|
const availableAgentNames = ( new Set(( agents.map(agent => agent.name))));
|
|
922
908
|
availableAgentNames.add(ChatMode.Agent.name.get());
|
|
923
909
|
const agentNames = [];
|
|
924
910
|
for (const item of attribute.value.items) {
|
|
925
911
|
if (item.type !== "scalar") {
|
|
926
|
-
report(toMarker(( localize(
|
|
912
|
+
report(toMarker(( localize(7689, "Each agent name in the 'agents' attribute must be a string.")), item.range, MarkerSeverity.Error));
|
|
927
913
|
} else if (item.value) {
|
|
928
914
|
agentNames.push(item.value);
|
|
929
915
|
if (item.value !== "*" && !( availableAgentNames.has(item.value))) {
|
|
930
916
|
report(toMarker(( localize(
|
|
931
|
-
|
|
932
|
-
"Unknown agent '{0}'. Available agents: {1}.",
|
|
917
|
+
7690,
|
|
918
|
+
"Unknown agent '{0}' will be ignored. Available agents: {1}.",
|
|
933
919
|
item.value,
|
|
934
920
|
Array.from(availableAgentNames).join(", ")
|
|
935
|
-
)), item.range, MarkerSeverity.
|
|
921
|
+
)), item.range, MarkerSeverity.Hint, [MarkerTag.Unnecessary]));
|
|
936
922
|
}
|
|
937
923
|
}
|
|
938
924
|
}
|
|
@@ -940,35 +926,32 @@ let PromptValidator = class PromptValidator {
|
|
|
940
926
|
const tools = header.tools;
|
|
941
927
|
if (tools && !tools.includes(SpecedToolAliases.agent)) {
|
|
942
928
|
report(toMarker(( localize(
|
|
943
|
-
|
|
929
|
+
7691,
|
|
944
930
|
"When 'agents' and 'tools' are specified, the 'agent' tool must be included in the 'tools' attribute."
|
|
945
931
|
)), attribute.value.range, MarkerSeverity.Warning));
|
|
946
932
|
}
|
|
947
933
|
}
|
|
948
934
|
}
|
|
949
|
-
isCustomAgentInSubagentEnabled() {
|
|
950
|
-
return !!this.configurationService.getValue(ChatConfiguration.SubagentToolCustomAgents);
|
|
951
|
-
}
|
|
952
935
|
validateGithubPermissions(attributes, report) {
|
|
953
936
|
const attribute = attributes.find(attr => attr.key === GithubPromptHeaderAttributes.github);
|
|
954
937
|
if (!attribute) {
|
|
955
938
|
return;
|
|
956
939
|
}
|
|
957
940
|
if (attribute.value.type !== "map") {
|
|
958
|
-
report(toMarker(( localize(
|
|
941
|
+
report(toMarker(( localize(7692, "The 'github' attribute must be an object.")), attribute.value.range, MarkerSeverity.Error));
|
|
959
942
|
return;
|
|
960
943
|
}
|
|
961
944
|
for (const prop of attribute.value.properties) {
|
|
962
945
|
if (prop.key.value !== "permissions") {
|
|
963
946
|
report(toMarker(( localize(
|
|
964
|
-
|
|
947
|
+
7693,
|
|
965
948
|
"Unknown property '{0}' in 'github' object. Supported: 'permissions'.",
|
|
966
949
|
prop.key.value
|
|
967
950
|
)), prop.key.range, MarkerSeverity.Warning));
|
|
968
951
|
continue;
|
|
969
952
|
}
|
|
970
953
|
if (prop.value.type !== "map") {
|
|
971
|
-
report(toMarker(( localize(
|
|
954
|
+
report(toMarker(( localize(7694, "The 'permissions' property must be an object.")), prop.value.range, MarkerSeverity.Error));
|
|
972
955
|
continue;
|
|
973
956
|
}
|
|
974
957
|
for (const permProp of prop.value.properties) {
|
|
@@ -977,7 +960,7 @@ let PromptValidator = class PromptValidator {
|
|
|
977
960
|
if (!scopeInfo) {
|
|
978
961
|
const validScopes = ( Object.keys(githubPermissionScopes)).sort().join(", ");
|
|
979
962
|
report(toMarker(( localize(
|
|
980
|
-
|
|
963
|
+
7695,
|
|
981
964
|
"Unknown permission scope '{0}'. Valid scopes: {1}.",
|
|
982
965
|
scope,
|
|
983
966
|
validScopes
|
|
@@ -985,13 +968,13 @@ let PromptValidator = class PromptValidator {
|
|
|
985
968
|
continue;
|
|
986
969
|
}
|
|
987
970
|
if (permProp.value.type !== "scalar") {
|
|
988
|
-
report(toMarker(( localize(
|
|
971
|
+
report(toMarker(( localize(7696, "The permission value for '{0}' must be a string.", scope)), permProp.value.range, MarkerSeverity.Error));
|
|
989
972
|
continue;
|
|
990
973
|
}
|
|
991
974
|
const value = permProp.value.value;
|
|
992
975
|
if (!scopeInfo.allowedValues.includes(value)) {
|
|
993
976
|
report(toMarker(( localize(
|
|
994
|
-
|
|
977
|
+
7697,
|
|
995
978
|
"Invalid permission value '{0}' for scope '{1}'. Allowed values: {2}.",
|
|
996
979
|
value,
|
|
997
980
|
scope,
|
|
@@ -1006,39 +989,39 @@ PromptValidator = ( __decorate([( __param(0, ILanguageModelsService)), ( __param
|
|
|
1006
989
|
const githubPermissionScopes = {
|
|
1007
990
|
"actions": {
|
|
1008
991
|
allowedValues: ["read", "write", "none"],
|
|
1009
|
-
description: ( localize(
|
|
992
|
+
description: ( localize(7698, "Access to GitHub Actions workflows and runs"))
|
|
1010
993
|
},
|
|
1011
994
|
"checks": {
|
|
1012
995
|
allowedValues: ["read", "none"],
|
|
1013
|
-
description: ( localize(
|
|
996
|
+
description: ( localize(7699, "Access to check runs and statuses"))
|
|
1014
997
|
},
|
|
1015
998
|
"contents": {
|
|
1016
999
|
allowedValues: ["read", "write", "none"],
|
|
1017
|
-
description: ( localize(
|
|
1000
|
+
description: ( localize(7700, "Access to repository contents (files, commits, branches)"))
|
|
1018
1001
|
},
|
|
1019
1002
|
"discussions": {
|
|
1020
1003
|
allowedValues: ["read", "write", "none"],
|
|
1021
|
-
description: ( localize(
|
|
1004
|
+
description: ( localize(7701, "Access to discussions"))
|
|
1022
1005
|
},
|
|
1023
1006
|
"issues": {
|
|
1024
1007
|
allowedValues: ["read", "write", "none"],
|
|
1025
|
-
description: ( localize(
|
|
1008
|
+
description: ( localize(7702, "Access to issues (read, create, update, comment)"))
|
|
1026
1009
|
},
|
|
1027
1010
|
"metadata": {
|
|
1028
1011
|
allowedValues: ["read"],
|
|
1029
|
-
description: ( localize(
|
|
1012
|
+
description: ( localize(7703, "Repository metadata (always read-only)"))
|
|
1030
1013
|
},
|
|
1031
1014
|
"pull-requests": {
|
|
1032
1015
|
allowedValues: ["read", "write", "none"],
|
|
1033
|
-
description: ( localize(
|
|
1016
|
+
description: ( localize(7704, "Access to pull requests (read, create, update, review)"))
|
|
1034
1017
|
},
|
|
1035
1018
|
"security-events": {
|
|
1036
1019
|
allowedValues: ["read", "none"],
|
|
1037
|
-
description: ( localize(
|
|
1020
|
+
description: ( localize(7705, "Access to security-related events"))
|
|
1038
1021
|
},
|
|
1039
1022
|
"workflows": {
|
|
1040
1023
|
allowedValues: ["write", "none"],
|
|
1041
|
-
description: ( localize(
|
|
1024
|
+
description: ( localize(7706, "Access to modify workflow files"))
|
|
1042
1025
|
}
|
|
1043
1026
|
};
|
|
1044
1027
|
function isTrueOrFalse(value) {
|
|
@@ -1125,103 +1108,103 @@ function isNonRecommendedAttribute(attributeName) {
|
|
|
1125
1108
|
}
|
|
1126
1109
|
const knownClaudeTools = [{
|
|
1127
1110
|
name: "Bash",
|
|
1128
|
-
description: ( localize(
|
|
1111
|
+
description: ( localize(7707, "Execute shell commands")),
|
|
1129
1112
|
toolEquivalent: [SpecedToolAliases.execute]
|
|
1130
1113
|
}, {
|
|
1131
1114
|
name: "Edit",
|
|
1132
|
-
description: ( localize(
|
|
1115
|
+
description: ( localize(7708, "Make targeted file edits")),
|
|
1133
1116
|
toolEquivalent: ["edit/editNotebook", "edit/editFiles"]
|
|
1134
1117
|
}, {
|
|
1135
1118
|
name: "Glob",
|
|
1136
|
-
description: ( localize(
|
|
1119
|
+
description: ( localize(7709, "Find files by pattern")),
|
|
1137
1120
|
toolEquivalent: ["search/fileSearch"]
|
|
1138
1121
|
}, {
|
|
1139
1122
|
name: "Grep",
|
|
1140
|
-
description: ( localize(
|
|
1123
|
+
description: ( localize(7710, "Search file contents with regex")),
|
|
1141
1124
|
toolEquivalent: ["search/textSearch"]
|
|
1142
1125
|
}, {
|
|
1143
1126
|
name: "Read",
|
|
1144
|
-
description: ( localize(
|
|
1127
|
+
description: ( localize(7711, "Read file contents")),
|
|
1145
1128
|
toolEquivalent: ["read/readFile", "read/getNotebookSummary"]
|
|
1146
1129
|
}, {
|
|
1147
1130
|
name: "Write",
|
|
1148
|
-
description: ( localize(
|
|
1131
|
+
description: ( localize(7712, "Create/overwrite files")),
|
|
1149
1132
|
toolEquivalent: ["edit/createDirectory", "edit/createFile", "edit/createJupyterNotebook"]
|
|
1150
1133
|
}, {
|
|
1151
1134
|
name: "WebFetch",
|
|
1152
|
-
description: ( localize(
|
|
1135
|
+
description: ( localize(7713, "Fetch URL content")),
|
|
1153
1136
|
toolEquivalent: [SpecedToolAliases.web]
|
|
1154
1137
|
}, {
|
|
1155
1138
|
name: "WebSearch",
|
|
1156
|
-
description: ( localize(
|
|
1139
|
+
description: ( localize(7714, "Perform web searches")),
|
|
1157
1140
|
toolEquivalent: [SpecedToolAliases.web]
|
|
1158
1141
|
}, {
|
|
1159
1142
|
name: "Task",
|
|
1160
|
-
description: ( localize(
|
|
1143
|
+
description: ( localize(7715, "Run subagents for complex tasks")),
|
|
1161
1144
|
toolEquivalent: [SpecedToolAliases.agent]
|
|
1162
1145
|
}, {
|
|
1163
1146
|
name: "Skill",
|
|
1164
|
-
description: ( localize(
|
|
1147
|
+
description: ( localize(7716, "Execute skills")),
|
|
1165
1148
|
toolEquivalent: []
|
|
1166
1149
|
}, {
|
|
1167
1150
|
name: "LSP",
|
|
1168
|
-
description: ( localize(
|
|
1151
|
+
description: ( localize(7717, "Code intelligence (requires plugin)")),
|
|
1169
1152
|
toolEquivalent: []
|
|
1170
1153
|
}, {
|
|
1171
1154
|
name: "NotebookEdit",
|
|
1172
|
-
description: ( localize(
|
|
1155
|
+
description: ( localize(7718, "Modify Jupyter notebooks")),
|
|
1173
1156
|
toolEquivalent: ["edit/editNotebook"]
|
|
1174
1157
|
}, {
|
|
1175
1158
|
name: "AskUserQuestion",
|
|
1176
|
-
description: ( localize(
|
|
1159
|
+
description: ( localize(7719, "Ask multiple-choice questions")),
|
|
1177
1160
|
toolEquivalent: ["vscode/askQuestions"]
|
|
1178
1161
|
}, {
|
|
1179
1162
|
name: "MCPSearch",
|
|
1180
|
-
description: ( localize(
|
|
1163
|
+
description: ( localize(7720, "Searches for MCP tools when tool search is enabled")),
|
|
1181
1164
|
toolEquivalent: []
|
|
1182
1165
|
}];
|
|
1183
1166
|
const knownClaudeModels = [{
|
|
1184
1167
|
name: "sonnet",
|
|
1185
|
-
description: ( localize(
|
|
1168
|
+
description: ( localize(7721, "Latest Claude Sonnet")),
|
|
1186
1169
|
modelEquivalent: "Claude Sonnet 4.5 (copilot)"
|
|
1187
1170
|
}, {
|
|
1188
1171
|
name: "opus",
|
|
1189
|
-
description: ( localize(
|
|
1172
|
+
description: ( localize(7722, "Latest Claude Opus")),
|
|
1190
1173
|
modelEquivalent: "Claude Opus 4.6 (copilot)"
|
|
1191
1174
|
}, {
|
|
1192
1175
|
name: "haiku",
|
|
1193
|
-
description: ( localize(
|
|
1176
|
+
description: ( localize(7723, "Latest Claude Haiku, fast for simple tasks")),
|
|
1194
1177
|
modelEquivalent: "Claude Haiku 4.5 (copilot)"
|
|
1195
1178
|
}, {
|
|
1196
1179
|
name: "inherit",
|
|
1197
|
-
description: ( localize(
|
|
1180
|
+
description: ( localize(7724, "Inherit model from parent agent or prompt")),
|
|
1198
1181
|
modelEquivalent: undefined
|
|
1199
1182
|
}];
|
|
1200
1183
|
const claudeAgentAttributes = {
|
|
1201
1184
|
"name": {
|
|
1202
1185
|
type: "scalar",
|
|
1203
|
-
description: ( localize(
|
|
1186
|
+
description: ( localize(7725, "Unique identifier using lowercase letters and hyphens (required)"))
|
|
1204
1187
|
},
|
|
1205
1188
|
"description": {
|
|
1206
1189
|
type: "scalar",
|
|
1207
|
-
description: ( localize(
|
|
1190
|
+
description: ( localize(7726, "When to delegate to this subagent (required)"))
|
|
1208
1191
|
},
|
|
1209
1192
|
"tools": {
|
|
1210
1193
|
type: "sequence",
|
|
1211
|
-
description: ( localize(
|
|
1194
|
+
description: ( localize(7727, "Array of tools the subagent can use. Inherits all tools if omitted")),
|
|
1212
1195
|
defaults: ["Read, Edit, Bash"],
|
|
1213
1196
|
items: knownClaudeTools
|
|
1214
1197
|
},
|
|
1215
1198
|
"disallowedTools": {
|
|
1216
1199
|
type: "sequence",
|
|
1217
|
-
description: ( localize(
|
|
1200
|
+
description: ( localize(7728, "Tools to deny, removed from inherited or specified list")),
|
|
1218
1201
|
defaults: ["Write, Edit, Bash"],
|
|
1219
1202
|
items: knownClaudeTools
|
|
1220
1203
|
},
|
|
1221
1204
|
"model": {
|
|
1222
1205
|
type: "scalar",
|
|
1223
1206
|
description: ( localize(
|
|
1224
|
-
|
|
1207
|
+
7729,
|
|
1225
1208
|
"Model to use: sonnet, opus, haiku, or inherit. Defaults to inherit."
|
|
1226
1209
|
)),
|
|
1227
1210
|
defaults: ["sonnet", "opus", "haiku", "inherit"],
|
|
@@ -1230,77 +1213,77 @@ const claudeAgentAttributes = {
|
|
|
1230
1213
|
"permissionMode": {
|
|
1231
1214
|
type: "scalar",
|
|
1232
1215
|
description: ( localize(
|
|
1233
|
-
|
|
1216
|
+
7730,
|
|
1234
1217
|
"Permission mode: default, acceptEdits, dontAsk, bypassPermissions, or plan."
|
|
1235
1218
|
)),
|
|
1236
1219
|
defaults: ["default", "acceptEdits", "dontAsk", "bypassPermissions", "plan"],
|
|
1237
1220
|
enums: [{
|
|
1238
1221
|
name: "default",
|
|
1239
1222
|
description: ( localize(
|
|
1240
|
-
|
|
1223
|
+
7731,
|
|
1241
1224
|
"Standard behavior: prompts for permission on first use of each tool."
|
|
1242
1225
|
))
|
|
1243
1226
|
}, {
|
|
1244
1227
|
name: "acceptEdits",
|
|
1245
|
-
description: ( localize(
|
|
1228
|
+
description: ( localize(7732, "Automatically accepts file edit permissions for the session."))
|
|
1246
1229
|
}, {
|
|
1247
1230
|
name: "plan",
|
|
1248
1231
|
description: ( localize(
|
|
1249
|
-
|
|
1232
|
+
7733,
|
|
1250
1233
|
"Plan Mode: Claude can analyze but not modify files or execute commands."
|
|
1251
1234
|
))
|
|
1252
1235
|
}, {
|
|
1253
1236
|
name: "delegate",
|
|
1254
1237
|
description: ( localize(
|
|
1255
|
-
|
|
1238
|
+
7734,
|
|
1256
1239
|
"Coordination-only mode for agent team leads. Only available when an agent team is active."
|
|
1257
1240
|
))
|
|
1258
1241
|
}, {
|
|
1259
1242
|
name: "dontAsk",
|
|
1260
1243
|
description: ( localize(
|
|
1261
|
-
|
|
1244
|
+
7735,
|
|
1262
1245
|
"Auto-denies tools unless pre-approved via /permissions or permissions.allow rules."
|
|
1263
1246
|
))
|
|
1264
1247
|
}, {
|
|
1265
1248
|
name: "bypassPermissions",
|
|
1266
1249
|
description: ( localize(
|
|
1267
|
-
|
|
1250
|
+
7736,
|
|
1268
1251
|
"Skips all permission prompts (requires safe environment like containers)."
|
|
1269
1252
|
))
|
|
1270
1253
|
}]
|
|
1271
1254
|
},
|
|
1272
1255
|
"skills": {
|
|
1273
1256
|
type: "sequence",
|
|
1274
|
-
description: ( localize(
|
|
1257
|
+
description: ( localize(7737, "Skills to load into the subagent's context at startup."))
|
|
1275
1258
|
},
|
|
1276
1259
|
"mcpServers": {
|
|
1277
1260
|
type: "sequence",
|
|
1278
|
-
description: ( localize(
|
|
1261
|
+
description: ( localize(7738, "MCP servers available to this subagent."))
|
|
1279
1262
|
},
|
|
1280
1263
|
"hooks": {
|
|
1281
1264
|
type: "object",
|
|
1282
|
-
description: ( localize(
|
|
1265
|
+
description: ( localize(7739, "Lifecycle hooks scoped to this subagent."))
|
|
1283
1266
|
},
|
|
1284
1267
|
"memory": {
|
|
1285
1268
|
type: "scalar",
|
|
1286
1269
|
description: ( localize(
|
|
1287
|
-
|
|
1270
|
+
7740,
|
|
1288
1271
|
"Persistent memory scope: user, project, or local. Enables cross-session learning."
|
|
1289
1272
|
)),
|
|
1290
1273
|
defaults: ["user", "project", "local"],
|
|
1291
1274
|
enums: [{
|
|
1292
1275
|
name: "user",
|
|
1293
|
-
description: ( localize(
|
|
1276
|
+
description: ( localize(7741, "Remember learnings across all projects."))
|
|
1294
1277
|
}, {
|
|
1295
1278
|
name: "project",
|
|
1296
1279
|
description: ( localize(
|
|
1297
|
-
|
|
1280
|
+
7742,
|
|
1298
1281
|
"The subagent's knowledge is project-specific and shareable via version control."
|
|
1299
1282
|
))
|
|
1300
1283
|
}, {
|
|
1301
1284
|
name: "local",
|
|
1302
1285
|
description: ( localize(
|
|
1303
|
-
|
|
1286
|
+
7743,
|
|
1304
1287
|
"The subagent's knowledge is project-specific but should not be checked into version control."
|
|
1305
1288
|
))
|
|
1306
1289
|
}]
|
|
@@ -1310,14 +1293,14 @@ const claudeRulesAttributes = {
|
|
|
1310
1293
|
"description": {
|
|
1311
1294
|
type: "scalar",
|
|
1312
1295
|
description: ( localize(
|
|
1313
|
-
|
|
1296
|
+
7744,
|
|
1314
1297
|
"A description of what this rule covers, used to provide context about when it applies."
|
|
1315
1298
|
))
|
|
1316
1299
|
},
|
|
1317
1300
|
"paths": {
|
|
1318
1301
|
type: "sequence",
|
|
1319
1302
|
description: ( localize(
|
|
1320
|
-
|
|
1303
|
+
7745,
|
|
1321
1304
|
"Array of glob patterns that describe for which files the rule applies. Based on these patterns, the file is automatically included in the prompt when the context contains a file that matches.\nExample: `['src/**/*.ts', 'test/**']`"
|
|
1322
1305
|
))
|
|
1323
1306
|
}
|
|
@@ -1346,10 +1329,13 @@ function getTarget(promptType, header) {
|
|
|
1346
1329
|
}
|
|
1347
1330
|
return Target.Undefined;
|
|
1348
1331
|
}
|
|
1349
|
-
function toMarker(message, range, severity = MarkerSeverity.Error) {
|
|
1332
|
+
function toMarker(message, range, severity = MarkerSeverity.Error, tags) {
|
|
1350
1333
|
return {
|
|
1351
1334
|
severity,
|
|
1352
1335
|
message,
|
|
1336
|
+
...(tags ? {
|
|
1337
|
+
tags
|
|
1338
|
+
} : {}),
|
|
1353
1339
|
...range
|
|
1354
1340
|
};
|
|
1355
1341
|
}
|