@theia/ai-ide 1.77.0-next.99 → 1.77.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/lib/browser/address-pr-review-command-contribution.js +15 -19
- package/lib/browser/address-pr-review-command-contribution.js.map +1 -1
- package/lib/browser/agent-mode-confirmation-service.js +20 -24
- package/lib/browser/agent-mode-confirmation-service.js.map +1 -1
- package/lib/browser/agents-md-agent.js +15 -19
- package/lib/browser/agents-md-agent.js.map +1 -1
- package/lib/browser/ai-allow-all-mode-chat-banner.js +32 -39
- package/lib/browser/ai-allow-all-mode-chat-banner.js.map +1 -1
- package/lib/browser/ai-allow-all-mode-chat-banner.spec.js +49 -51
- package/lib/browser/ai-allow-all-mode-chat-banner.spec.js.map +1 -1
- package/lib/browser/ai-aware-scm-commit-widget.d.ts +1 -1
- package/lib/browser/ai-aware-scm-commit-widget.d.ts.map +1 -1
- package/lib/browser/ai-aware-scm-commit-widget.js +36 -47
- package/lib/browser/ai-aware-scm-commit-widget.js.map +1 -1
- package/lib/browser/ai-configuration/agent-icon.js +5 -9
- package/lib/browser/ai-configuration/agent-icon.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-breadcrumbs-contribution.js +28 -37
- package/lib/browser/ai-configuration/ai-configuration-breadcrumbs-contribution.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-detail-widget.js +29 -39
- package/lib/browser/ai-configuration/ai-configuration-detail-widget.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-detail-widget.spec.js +22 -24
- package/lib/browser/ai-configuration/ai-configuration-detail-widget.spec.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-label-provider-contribution.js +12 -15
- package/lib/browser/ai-configuration/ai-configuration-label-provider-contribution.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-open-preference-renderer.js +20 -24
- package/lib/browser/ai-configuration/ai-configuration-open-preference-renderer.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-preference-ownership.spec.js +37 -39
- package/lib/browser/ai-configuration/ai-configuration-preference-ownership.spec.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-resource.js +3 -7
- package/lib/browser/ai-configuration/ai-configuration-resource.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-search-widget.js +20 -26
- package/lib/browser/ai-configuration/ai-configuration-search-widget.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-search.js +2 -5
- package/lib/browser/ai-configuration/ai-configuration-search.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-search.spec.js +15 -17
- package/lib/browser/ai-configuration/ai-configuration-search.spec.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-service.js +9 -12
- package/lib/browser/ai-configuration/ai-configuration-service.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-tree-model.js +7 -10
- package/lib/browser/ai-configuration/ai-configuration-tree-model.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-tree-nodes.js +14 -17
- package/lib/browser/ai-configuration/ai-configuration-tree-nodes.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-tree-nodes.spec.js +47 -49
- package/lib/browser/ai-configuration/ai-configuration-tree-nodes.spec.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-tree-widget.d.ts +1 -1
- package/lib/browser/ai-configuration/ai-configuration-tree-widget.d.ts.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-tree-widget.js +68 -79
- package/lib/browser/ai-configuration/ai-configuration-tree-widget.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-view-contribution.d.ts +2 -2
- package/lib/browser/ai-configuration/ai-configuration-view-contribution.d.ts.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-view-contribution.js +47 -54
- package/lib/browser/ai-configuration/ai-configuration-view-contribution.js.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-widget.d.ts +4 -4
- package/lib/browser/ai-configuration/ai-configuration-widget.d.ts.map +1 -1
- package/lib/browser/ai-configuration/ai-configuration-widget.js +45 -57
- package/lib/browser/ai-configuration/ai-configuration-widget.js.map +1 -1
- package/lib/browser/ai-configuration/categories/agent-capabilities-settings.d.ts +3 -0
- package/lib/browser/ai-configuration/categories/agent-capabilities-settings.d.ts.map +1 -1
- package/lib/browser/ai-configuration/categories/agent-capabilities-settings.js +34 -40
- package/lib/browser/ai-configuration/categories/agent-capabilities-settings.js.map +1 -1
- package/lib/browser/ai-configuration/categories/agent-capabilities-settings.spec.js +135 -140
- package/lib/browser/ai-configuration/categories/agent-capabilities-settings.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/agent-chips.js +8 -13
- package/lib/browser/ai-configuration/categories/agent-chips.js.map +1 -1
- package/lib/browser/ai-configuration/categories/agent-detail-model.js +7 -10
- package/lib/browser/ai-configuration/categories/agent-detail-model.js.map +1 -1
- package/lib/browser/ai-configuration/categories/agent-detail-model.spec.js +13 -15
- package/lib/browser/ai-configuration/categories/agent-detail-model.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/agent-detail-view.d.ts +1 -1
- package/lib/browser/ai-configuration/categories/agent-detail-view.d.ts.map +1 -1
- package/lib/browser/ai-configuration/categories/agent-detail-view.js +29 -34
- package/lib/browser/ai-configuration/categories/agent-detail-view.js.map +1 -1
- package/lib/browser/ai-configuration/categories/agents-configuration-category.d.ts +1 -1
- package/lib/browser/ai-configuration/categories/agents-configuration-category.d.ts.map +1 -1
- package/lib/browser/ai-configuration/categories/agents-configuration-category.js +106 -128
- package/lib/browser/ai-configuration/categories/agents-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/agents-configuration-category.spec.js +32 -34
- package/lib/browser/ai-configuration/categories/agents-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/general-configuration-category.js +91 -101
- package/lib/browser/ai-configuration/categories/general-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/general-configuration-category.spec.js +38 -40
- package/lib/browser/ai-configuration/categories/general-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/model-aliases-configuration-category.js +53 -63
- package/lib/browser/ai-configuration/categories/model-aliases-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/model-aliases-configuration-category.spec.js +25 -27
- package/lib/browser/ai-configuration/categories/model-aliases-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/models-configuration-category.js +45 -56
- package/lib/browser/ai-configuration/categories/models-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/models-configuration-category.spec.js +31 -33
- package/lib/browser/ai-configuration/categories/models-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/prompt-snippets-configuration-category.js +68 -76
- package/lib/browser/ai-configuration/categories/prompt-snippets-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/prompt-snippets-configuration-category.spec.js +55 -57
- package/lib/browser/ai-configuration/categories/prompt-snippets-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/prompts-and-skills-configuration-category.js +85 -100
- package/lib/browser/ai-configuration/categories/prompts-and-skills-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/prompts-and-skills-configuration-category.spec.js +39 -41
- package/lib/browser/ai-configuration/categories/prompts-and-skills-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/provider-model-discovery-section.js +44 -49
- package/lib/browser/ai-configuration/categories/provider-model-discovery-section.js.map +1 -1
- package/lib/browser/ai-configuration/categories/provider-model-discovery-section.spec.js +71 -74
- package/lib/browser/ai-configuration/categories/provider-model-discovery-section.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/token-usage-configuration-category.js +34 -42
- package/lib/browser/ai-configuration/categories/token-usage-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/token-usage-configuration-category.spec.js +16 -18
- package/lib/browser/ai-configuration/categories/token-usage-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/tools-configuration-category.js +101 -112
- package/lib/browser/ai-configuration/categories/tools-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/tools-configuration-category.spec.js +46 -48
- package/lib/browser/ai-configuration/categories/tools-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/categories/variables-configuration-category.js +54 -63
- package/lib/browser/ai-configuration/categories/variables-configuration-category.js.map +1 -1
- package/lib/browser/ai-configuration/categories/variables-configuration-category.spec.js +27 -29
- package/lib/browser/ai-configuration/categories/variables-configuration-category.spec.js.map +1 -1
- package/lib/browser/ai-configuration/components/agent-notification-settings.js +12 -16
- package/lib/browser/ai-configuration/components/agent-notification-settings.js.map +1 -1
- package/lib/browser/ai-configuration/language-model-renderer.js +25 -31
- package/lib/browser/ai-configuration/language-model-renderer.js.map +1 -1
- package/lib/browser/ai-configuration/language-model-renderer.spec.js +29 -32
- package/lib/browser/ai-configuration/language-model-renderer.spec.js.map +1 -1
- package/lib/browser/ai-first-perspective-contribution.js +18 -21
- package/lib/browser/ai-first-perspective-contribution.js.map +1 -1
- package/lib/browser/ai-getting-started-commands.js +3 -6
- package/lib/browser/ai-getting-started-commands.js.map +1 -1
- package/lib/browser/ai-getting-started-contribution.js +24 -30
- package/lib/browser/ai-getting-started-contribution.js.map +1 -1
- package/lib/browser/ai-getting-started-walkthrough.js +54 -58
- package/lib/browser/ai-getting-started-walkthrough.js.map +1 -1
- package/lib/browser/ai-getting-started-walkthrough.spec.js +32 -34
- package/lib/browser/ai-getting-started-walkthrough.spec.js.map +1 -1
- package/lib/browser/ai-ide-activation-service.js +25 -34
- package/lib/browser/ai-ide-activation-service.js.map +1 -1
- package/lib/browser/ai-sessions-view-contribution.d.ts +1 -1
- package/lib/browser/ai-sessions-view-contribution.d.ts.map +1 -1
- package/lib/browser/ai-sessions-view-contribution.js +28 -33
- package/lib/browser/ai-sessions-view-contribution.js.map +1 -1
- package/lib/browser/ai-sessions-widget.d.ts +3 -3
- package/lib/browser/ai-sessions-widget.d.ts.map +1 -1
- package/lib/browser/ai-sessions-widget.js +42 -55
- package/lib/browser/ai-sessions-widget.js.map +1 -1
- package/lib/browser/ai-terminal-functions.js +18 -24
- package/lib/browser/ai-terminal-functions.js.map +1 -1
- package/lib/browser/ai-walkthrough-context-keys.js +35 -45
- package/lib/browser/ai-walkthrough-context-keys.js.map +1 -1
- package/lib/browser/ai-walkthrough-context-keys.spec.js +34 -36
- package/lib/browser/ai-walkthrough-context-keys.spec.js.map +1 -1
- package/lib/browser/ai-workspace-restriction-contribution.js +11 -15
- package/lib/browser/ai-workspace-restriction-contribution.js.map +1 -1
- package/lib/browser/analyze-gh-ticket-command-contribution.js +19 -23
- package/lib/browser/analyze-gh-ticket-command-contribution.js.map +1 -1
- package/lib/browser/app-tester-chat-agent.js +45 -51
- package/lib/browser/app-tester-chat-agent.js.map +1 -1
- package/lib/browser/app-tester-chat-functions.d.ts +1 -1
- package/lib/browser/app-tester-chat-functions.d.ts.map +1 -1
- package/lib/browser/app-tester-chat-functions.js +29 -34
- package/lib/browser/app-tester-chat-functions.js.map +1 -1
- package/lib/browser/app-tester-prompt-template.js +42 -45
- package/lib/browser/app-tester-prompt-template.js.map +1 -1
- package/lib/browser/apptester-capability-contribution.js +13 -17
- package/lib/browser/apptester-capability-contribution.js.map +1 -1
- package/lib/browser/architect-agent.d.ts +2 -2
- package/lib/browser/architect-agent.d.ts.map +1 -1
- package/lib/browser/architect-agent.js +38 -44
- package/lib/browser/architect-agent.js.map +1 -1
- package/lib/browser/architect-prompt-template.js +84 -87
- package/lib/browser/architect-prompt-template.js.map +1 -1
- package/lib/browser/chat-session-item-action-contribution.js +15 -18
- package/lib/browser/chat-session-item-action-contribution.js.map +1 -1
- package/lib/browser/chat-session-item.d.ts +1 -1
- package/lib/browser/chat-session-item.d.ts.map +1 -1
- package/lib/browser/chat-session-item.js +25 -29
- package/lib/browser/chat-session-item.js.map +1 -1
- package/lib/browser/chat-session-list-components.js +9 -14
- package/lib/browser/chat-session-list-components.js.map +1 -1
- package/lib/browser/chat-session-list-service.d.ts +2 -2
- package/lib/browser/chat-session-list-service.d.ts.map +1 -1
- package/lib/browser/chat-session-list-service.js +33 -43
- package/lib/browser/chat-session-list-service.js.map +1 -1
- package/lib/browser/chat-session-list-service.spec.js +56 -58
- package/lib/browser/chat-session-list-service.spec.js.map +1 -1
- package/lib/browser/chat-session-tooltip.js +31 -35
- package/lib/browser/chat-session-tooltip.js.map +1 -1
- package/lib/browser/chat-sessions-welcome-message-provider.d.ts +3 -3
- package/lib/browser/chat-sessions-welcome-message-provider.d.ts.map +1 -1
- package/lib/browser/chat-sessions-welcome-message-provider.js +54 -70
- package/lib/browser/chat-sessions-welcome-message-provider.js.map +1 -1
- package/lib/browser/code-review-capability-contribution.js +13 -17
- package/lib/browser/code-review-capability-contribution.js.map +1 -1
- package/lib/browser/code-reviewer-agent.js +17 -21
- package/lib/browser/code-reviewer-agent.js.map +1 -1
- package/lib/browser/code-reviewer-prompt-template.js +5 -8
- package/lib/browser/code-reviewer-prompt-template.js.map +1 -1
- package/lib/browser/coder-agent.d.ts +2 -2
- package/lib/browser/coder-agent.d.ts.map +1 -1
- package/lib/browser/coder-agent.js +44 -50
- package/lib/browser/coder-agent.js.map +1 -1
- package/lib/browser/commit-message-agent.js +26 -32
- package/lib/browser/commit-message-agent.js.map +1 -1
- package/lib/browser/commit-message-agent.spec.js +25 -28
- package/lib/browser/commit-message-agent.spec.js.map +1 -1
- package/lib/browser/commit-message-command-contribution.d.ts +1 -1
- package/lib/browser/commit-message-command-contribution.d.ts.map +1 -1
- package/lib/browser/commit-message-command-contribution.js +21 -28
- package/lib/browser/commit-message-command-contribution.js.map +1 -1
- package/lib/browser/commit-message-commands.js +4 -7
- package/lib/browser/commit-message-commands.js.map +1 -1
- package/lib/browser/commit-message-prompt-template.js +9 -12
- package/lib/browser/commit-message-prompt-template.js.map +1 -1
- package/lib/browser/commit-message-runner.d.ts +2 -2
- package/lib/browser/commit-message-runner.d.ts.map +1 -1
- package/lib/browser/commit-message-runner.js +33 -41
- package/lib/browser/commit-message-runner.js.map +1 -1
- package/lib/browser/commit-message-runner.spec.js +65 -68
- package/lib/browser/commit-message-runner.spec.js.map +1 -1
- package/lib/browser/context-file-validation-service-impl.d.ts +1 -1
- package/lib/browser/context-file-validation-service-impl.d.ts.map +1 -1
- package/lib/browser/context-file-validation-service-impl.js +20 -26
- package/lib/browser/context-file-validation-service-impl.js.map +1 -1
- package/lib/browser/context-file-validation-service-impl.spec.js +77 -79
- package/lib/browser/context-file-validation-service-impl.spec.js.map +1 -1
- package/lib/browser/context-functions.js +27 -31
- package/lib/browser/context-functions.js.map +1 -1
- package/lib/browser/context-functions.spec.js +64 -66
- package/lib/browser/context-functions.spec.js.map +1 -1
- package/lib/browser/create-skill-agent.d.ts +1 -1
- package/lib/browser/create-skill-agent.d.ts.map +1 -1
- package/lib/browser/create-skill-agent.js +19 -23
- package/lib/browser/create-skill-agent.js.map +1 -1
- package/lib/browser/default-chat-agent-recommendation-service.js +16 -19
- package/lib/browser/default-chat-agent-recommendation-service.js.map +1 -1
- package/lib/browser/explore-agent.d.ts +1 -1
- package/lib/browser/explore-agent.d.ts.map +1 -1
- package/lib/browser/explore-agent.js +18 -22
- package/lib/browser/explore-agent.js.map +1 -1
- package/lib/browser/explore-prompt-template.js +5 -8
- package/lib/browser/explore-prompt-template.js.map +1 -1
- package/lib/browser/file-changeset-function.spec.js +12 -14
- package/lib/browser/file-changeset-function.spec.js.map +1 -1
- package/lib/browser/file-changeset-functions.d.ts +1 -1
- package/lib/browser/file-changeset-functions.d.ts.map +1 -1
- package/lib/browser/file-changeset-functions.js +134 -164
- package/lib/browser/file-changeset-functions.js.map +1 -1
- package/lib/browser/file-changeset-functions.spec.js +136 -138
- package/lib/browser/file-changeset-functions.spec.js.map +1 -1
- package/lib/browser/frontend-module.js +293 -295
- package/lib/browser/frontend-module.js.map +1 -1
- package/lib/browser/git-changes-tool.js +22 -26
- package/lib/browser/git-changes-tool.js.map +1 -1
- package/lib/browser/git-changes-tool.spec.js +52 -55
- package/lib/browser/git-changes-tool.spec.js.map +1 -1
- package/lib/browser/github-capability-contribution.js +14 -18
- package/lib/browser/github-capability-contribution.js.map +1 -1
- package/lib/browser/github-chat-agent.js +58 -67
- package/lib/browser/github-chat-agent.js.map +1 -1
- package/lib/browser/github-prompt-template.js +6 -9
- package/lib/browser/github-prompt-template.js.map +1 -1
- package/lib/browser/github-repo-variable-contribution.d.ts +1 -1
- package/lib/browser/github-repo-variable-contribution.d.ts.map +1 -1
- package/lib/browser/github-repo-variable-contribution.js +23 -30
- package/lib/browser/github-repo-variable-contribution.js.map +1 -1
- package/lib/browser/ide-chat-welcome-message-provider.js +59 -71
- package/lib/browser/ide-chat-welcome-message-provider.js.map +1 -1
- package/lib/browser/implement-gh-ticket-command-contribution.js +15 -19
- package/lib/browser/implement-gh-ticket-command-contribution.js.map +1 -1
- package/lib/browser/memory-capability-contribution.d.ts.map +1 -1
- package/lib/browser/memory-capability-contribution.js +21 -25
- package/lib/browser/memory-capability-contribution.js.map +1 -1
- package/lib/browser/memory-capability-contribution.spec.js +30 -32
- package/lib/browser/memory-capability-contribution.spec.js.map +1 -1
- package/lib/browser/memory-directory-variable-contribution.d.ts +1 -1
- package/lib/browser/memory-directory-variable-contribution.d.ts.map +1 -1
- package/lib/browser/memory-directory-variable-contribution.js +19 -24
- package/lib/browser/memory-directory-variable-contribution.js.map +1 -1
- package/lib/browser/memory-directory-variable-contribution.spec.js +28 -30
- package/lib/browser/memory-directory-variable-contribution.spec.js.map +1 -1
- package/lib/browser/mode-aware-chat-agent.js +9 -12
- package/lib/browser/mode-aware-chat-agent.js.map +1 -1
- package/lib/browser/multi-root-paths.spec.js +86 -88
- package/lib/browser/multi-root-paths.spec.js.map +1 -1
- package/lib/browser/open-editors-hint-contribution.js +10 -14
- package/lib/browser/open-editors-hint-contribution.js.map +1 -1
- package/lib/browser/remember-command-contribution.js +17 -21
- package/lib/browser/remember-command-contribution.js.map +1 -1
- package/lib/browser/review/pr-review-agent.js +17 -21
- package/lib/browser/review/pr-review-agent.js.map +1 -1
- package/lib/browser/review/pr-review-capability-contribution.js +41 -45
- package/lib/browser/review/pr-review-capability-contribution.js.map +1 -1
- package/lib/browser/review/pr-review-prompt-template.js +48 -51
- package/lib/browser/review/pr-review-prompt-template.js.map +1 -1
- package/lib/browser/shell-execution-capability-contribution.js +17 -21
- package/lib/browser/shell-execution-capability-contribution.js.map +1 -1
- package/lib/browser/skill-file-functions.js +27 -33
- package/lib/browser/skill-file-functions.js.map +1 -1
- package/lib/browser/skill-file-functions.spec.js +19 -21
- package/lib/browser/skill-file-functions.spec.js.map +1 -1
- package/lib/browser/summarize-session-command-contribution.d.ts +1 -1
- package/lib/browser/summarize-session-command-contribution.d.ts.map +1 -1
- package/lib/browser/summarize-session-command-contribution.js +38 -50
- package/lib/browser/summarize-session-command-contribution.js.map +1 -1
- package/lib/browser/task-background-summary-variable.js +17 -20
- package/lib/browser/task-background-summary-variable.js.map +1 -1
- package/lib/browser/task-context-file-storage-service.js +39 -51
- package/lib/browser/task-context-file-storage-service.js.map +1 -1
- package/lib/browser/task-context-file-storage-service.spec.js +41 -43
- package/lib/browser/task-context-file-storage-service.spec.js.map +1 -1
- package/lib/browser/task-context-functions.js +44 -52
- package/lib/browser/task-context-functions.js.map +1 -1
- package/lib/browser/template-preference-contribution.js +30 -37
- package/lib/browser/template-preference-contribution.js.map +1 -1
- package/lib/browser/test/tool-provider-cancellation-test-util.spec.js +8 -10
- package/lib/browser/test/tool-provider-cancellation-test-util.spec.js.map +1 -1
- package/lib/browser/todo-tool-renderer.d.ts +1 -1
- package/lib/browser/todo-tool-renderer.d.ts.map +1 -1
- package/lib/browser/todo-tool-renderer.js +42 -51
- package/lib/browser/todo-tool-renderer.js.map +1 -1
- package/lib/browser/todo-tool.js +8 -11
- package/lib/browser/todo-tool.js.map +1 -1
- package/lib/browser/todo-tool.spec.js +14 -16
- package/lib/browser/todo-tool.spec.js.map +1 -1
- package/lib/browser/user-interaction-tool-renderer.d.ts +1 -1
- package/lib/browser/user-interaction-tool-renderer.d.ts.map +1 -1
- package/lib/browser/user-interaction-tool-renderer.js +81 -95
- package/lib/browser/user-interaction-tool-renderer.js.map +1 -1
- package/lib/browser/user-interaction-tool.d.ts +2 -2
- package/lib/browser/user-interaction-tool.d.ts.map +1 -1
- package/lib/browser/user-interaction-tool.js +56 -65
- package/lib/browser/user-interaction-tool.js.map +1 -1
- package/lib/browser/user-interaction-tool.spec.js +118 -121
- package/lib/browser/user-interaction-tool.spec.js.map +1 -1
- package/lib/browser/workspace-functions.d.ts +1 -1
- package/lib/browser/workspace-functions.d.ts.map +1 -1
- package/lib/browser/workspace-functions.js +126 -155
- package/lib/browser/workspace-functions.js.map +1 -1
- package/lib/browser/workspace-functions.spec.js +607 -600
- package/lib/browser/workspace-functions.spec.js.map +1 -1
- package/lib/browser/workspace-launch-provider.d.ts +1 -1
- package/lib/browser/workspace-launch-provider.d.ts.map +1 -1
- package/lib/browser/workspace-launch-provider.js +46 -57
- package/lib/browser/workspace-launch-provider.js.map +1 -1
- package/lib/browser/workspace-launch-provider.spec.js +119 -122
- package/lib/browser/workspace-launch-provider.spec.js.map +1 -1
- package/lib/browser/workspace-search-provider.d.ts +1 -1
- package/lib/browser/workspace-search-provider.d.ts.map +1 -1
- package/lib/browser/workspace-search-provider.js +25 -32
- package/lib/browser/workspace-search-provider.js.map +1 -1
- package/lib/browser/workspace-search-provider.spec.js +35 -38
- package/lib/browser/workspace-search-provider.spec.js.map +1 -1
- package/lib/browser/workspace-task-provider.d.ts +1 -1
- package/lib/browser/workspace-task-provider.d.ts.map +1 -1
- package/lib/browser/workspace-task-provider.js +42 -51
- package/lib/browser/workspace-task-provider.js.map +1 -1
- package/lib/browser/workspace-task-provider.spec.js +102 -105
- package/lib/browser/workspace-task-provider.spec.js.map +1 -1
- package/lib/common/agent-ids.js +2 -5
- package/lib/common/agent-ids.js.map +1 -1
- package/lib/common/agents-md-prompt-template.js +38 -41
- package/lib/common/agents-md-prompt-template.js.map +1 -1
- package/lib/common/ai-configuration-preferences.js +5 -8
- package/lib/common/ai-configuration-preferences.js.map +1 -1
- package/lib/common/ai-ide-preferences.js +16 -19
- package/lib/common/ai-ide-preferences.js.map +1 -1
- package/lib/common/ai-terminal-functions.js +1 -4
- package/lib/common/ai-terminal-functions.js.map +1 -1
- package/lib/common/app-tester-chat-functions.js +4 -7
- package/lib/common/app-tester-chat-functions.js.map +1 -1
- package/lib/common/browser-automation-protocol.js +3 -6
- package/lib/common/browser-automation-protocol.js.map +1 -1
- package/lib/common/coder-replace-prompt-template.js +102 -108
- package/lib/common/coder-replace-prompt-template.js.map +1 -1
- package/lib/common/command-chat-agents.js +34 -40
- package/lib/common/command-chat-agents.js.map +1 -1
- package/lib/common/command-prompt-template.js +1 -4
- package/lib/common/command-prompt-template.js.map +1 -1
- package/lib/common/context-files-variable.js +17 -20
- package/lib/common/context-files-variable.js.map +1 -1
- package/lib/common/context-functions.js +3 -6
- package/lib/common/context-functions.js.map +1 -1
- package/lib/common/context-variables.js +2 -5
- package/lib/common/context-variables.js.map +1 -1
- package/lib/common/create-skill-prompt-template.js +22 -25
- package/lib/common/create-skill-prompt-template.js.map +1 -1
- package/lib/common/file-changeset-function-ids.js +8 -11
- package/lib/common/file-changeset-function-ids.js.map +1 -1
- package/lib/common/github-repo-protocol.js +2 -5
- package/lib/common/github-repo-protocol.js.map +1 -1
- package/lib/common/open-editors-hint-fragment-id.js +1 -4
- package/lib/common/open-editors-hint-fragment-id.js.map +1 -1
- package/lib/common/orchestrator-chat-agent.js +36 -42
- package/lib/common/orchestrator-chat-agent.js.map +1 -1
- package/lib/common/orchestrator-prompt-template.js +1 -4
- package/lib/common/orchestrator-prompt-template.js.map +1 -1
- package/lib/common/summarize-session-commands.js +2 -5
- package/lib/common/summarize-session-commands.js.map +1 -1
- package/lib/common/task-context-function-ids.js +5 -8
- package/lib/common/task-context-function-ids.js.map +1 -1
- package/lib/common/todo-tool.js +2 -6
- package/lib/common/todo-tool.js.map +1 -1
- package/lib/common/universal-chat-agent.js +17 -21
- package/lib/common/universal-chat-agent.js.map +1 -1
- package/lib/common/universal-prompt-template.js +6 -9
- package/lib/common/universal-prompt-template.js.map +1 -1
- package/lib/common/user-interaction-tool.js +11 -21
- package/lib/common/user-interaction-tool.js.map +1 -1
- package/lib/common/user-interaction-tool.spec.js +52 -54
- package/lib/common/user-interaction-tool.spec.js.map +1 -1
- package/lib/common/workspace-functions.js +13 -16
- package/lib/common/workspace-functions.js.map +1 -1
- package/lib/common/workspace-preferences.js +41 -44
- package/lib/common/workspace-preferences.js.map +1 -1
- package/lib/common/workspace-search-provider-util.js +3 -6
- package/lib/common/workspace-search-provider-util.js.map +1 -1
- package/lib/common/workspace-search-provider-util.spec.js +13 -15
- package/lib/common/workspace-search-provider-util.spec.js.map +1 -1
- package/lib/node/app-tester-agent/browser-automation-impl.d.ts +1 -1
- package/lib/node/app-tester-agent/browser-automation-impl.d.ts.map +1 -1
- package/lib/node/app-tester-agent/browser-automation-impl.js +7 -10
- package/lib/node/app-tester-agent/browser-automation-impl.js.map +1 -1
- package/lib/node/backend-module.js +21 -23
- package/lib/node/backend-module.js.map +1 -1
- package/lib/node/github-repo-service-impl.d.ts +1 -1
- package/lib/node/github-repo-service-impl.d.ts.map +1 -1
- package/lib/node/github-repo-service-impl.js +11 -15
- package/lib/node/github-repo-service-impl.js.map +1 -1
- package/lib/package.spec.d.ts +1 -0
- package/lib/package.spec.js +1 -1
- package/lib/package.spec.js.map +1 -1
- package/package.json +33 -25
- package/src/browser/address-pr-review-command-contribution.ts +1 -1
- package/src/browser/agent-mode-confirmation-service.ts +1 -1
- package/src/browser/agents-md-agent.ts +1 -1
- package/src/browser/ai-allow-all-mode-chat-banner.spec.ts +1 -1
- package/src/browser/ai-aware-scm-commit-widget.tsx +3 -3
- package/src/browser/ai-configuration/ai-configuration-breadcrumbs-contribution.ts +2 -2
- package/src/browser/ai-configuration/ai-configuration-detail-widget.spec.ts +1 -1
- package/src/browser/ai-configuration/ai-configuration-label-provider-contribution.ts +1 -1
- package/src/browser/ai-configuration/ai-configuration-open-preference-renderer.ts +1 -1
- package/src/browser/ai-configuration/ai-configuration-preference-ownership.spec.ts +6 -6
- package/src/browser/ai-configuration/ai-configuration-search.spec.ts +1 -1
- package/src/browser/ai-configuration/ai-configuration-tree-nodes.spec.ts +1 -1
- package/src/browser/ai-configuration/ai-configuration-tree-widget.tsx +3 -3
- package/src/browser/ai-configuration/ai-configuration-view-contribution.ts +2 -2
- package/src/browser/ai-configuration/ai-configuration-widget.tsx +5 -5
- package/src/browser/ai-configuration/categories/agent-capabilities-settings.spec.ts +9 -9
- package/src/browser/ai-configuration/categories/agent-capabilities-settings.tsx +5 -2
- package/src/browser/ai-configuration/categories/agent-chips.tsx +1 -1
- package/src/browser/ai-configuration/categories/agent-detail-model.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/agent-detail-view.tsx +6 -6
- package/src/browser/ai-configuration/categories/agents-configuration-category.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/agents-configuration-category.tsx +5 -5
- package/src/browser/ai-configuration/categories/general-configuration-category.spec.ts +2 -2
- package/src/browser/ai-configuration/categories/general-configuration-category.tsx +1 -1
- package/src/browser/ai-configuration/categories/model-aliases-configuration-category.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/model-aliases-configuration-category.tsx +1 -1
- package/src/browser/ai-configuration/categories/models-configuration-category.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/models-configuration-category.tsx +1 -1
- package/src/browser/ai-configuration/categories/prompt-snippets-configuration-category.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/prompt-snippets-configuration-category.tsx +1 -1
- package/src/browser/ai-configuration/categories/prompts-and-skills-configuration-category.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/prompts-and-skills-configuration-category.tsx +1 -1
- package/src/browser/ai-configuration/categories/provider-model-discovery-section.spec.tsx +1 -1
- package/src/browser/ai-configuration/categories/provider-model-discovery-section.tsx +1 -1
- package/src/browser/ai-configuration/categories/token-usage-configuration-category.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/token-usage-configuration-category.tsx +1 -1
- package/src/browser/ai-configuration/categories/tools-configuration-category.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/variables-configuration-category.spec.ts +1 -1
- package/src/browser/ai-configuration/categories/variables-configuration-category.tsx +1 -1
- package/src/browser/ai-configuration/language-model-renderer.spec.ts +1 -1
- package/src/browser/ai-first-perspective-contribution.ts +1 -1
- package/src/browser/ai-getting-started-contribution.ts +2 -2
- package/src/browser/ai-getting-started-walkthrough.spec.ts +2 -2
- package/src/browser/ai-getting-started-walkthrough.ts +3 -3
- package/src/browser/ai-ide-activation-service.ts +1 -1
- package/src/browser/ai-sessions-view-contribution.ts +1 -1
- package/src/browser/ai-sessions-widget.tsx +4 -4
- package/src/browser/ai-terminal-functions.ts +1 -1
- package/src/browser/ai-walkthrough-context-keys.spec.ts +1 -1
- package/src/browser/analyze-gh-ticket-command-contribution.ts +3 -3
- package/src/browser/app-tester-chat-agent.ts +2 -2
- package/src/browser/app-tester-chat-functions.ts +2 -2
- package/src/browser/app-tester-prompt-template.ts +2 -2
- package/src/browser/apptester-capability-contribution.ts +1 -1
- package/src/browser/architect-agent.ts +4 -4
- package/src/browser/architect-prompt-template.ts +6 -6
- package/src/browser/chat-session-item.tsx +2 -2
- package/src/browser/chat-session-list-service.spec.ts +2 -2
- package/src/browser/chat-session-list-service.ts +2 -2
- package/src/browser/chat-sessions-welcome-message-provider.tsx +5 -5
- package/src/browser/code-review-capability-contribution.ts +1 -1
- package/src/browser/code-reviewer-agent.ts +1 -1
- package/src/browser/coder-agent.ts +3 -3
- package/src/browser/commit-message-agent.spec.ts +2 -2
- package/src/browser/commit-message-agent.ts +1 -1
- package/src/browser/commit-message-command-contribution.ts +3 -3
- package/src/browser/commit-message-runner.spec.ts +3 -3
- package/src/browser/commit-message-runner.ts +2 -2
- package/src/browser/context-file-validation-service-impl.spec.ts +2 -2
- package/src/browser/context-file-validation-service-impl.ts +1 -1
- package/src/browser/context-functions.spec.ts +1 -1
- package/src/browser/context-functions.ts +1 -1
- package/src/browser/create-skill-agent.ts +2 -2
- package/src/browser/default-chat-agent-recommendation-service.ts +2 -2
- package/src/browser/explore-agent.ts +2 -2
- package/src/browser/file-changeset-function.spec.ts +1 -1
- package/src/browser/file-changeset-functions.spec.ts +3 -3
- package/src/browser/file-changeset-functions.ts +3 -3
- package/src/browser/frontend-module.ts +89 -89
- package/src/browser/git-changes-tool.spec.ts +1 -1
- package/src/browser/github-capability-contribution.ts +1 -1
- package/src/browser/github-chat-agent.ts +3 -3
- package/src/browser/github-repo-variable-contribution.ts +1 -1
- package/src/browser/ide-chat-welcome-message-provider.tsx +3 -3
- package/src/browser/implement-gh-ticket-command-contribution.ts +1 -1
- package/src/browser/memory-capability-contribution.spec.ts +4 -4
- package/src/browser/memory-capability-contribution.ts +5 -3
- package/src/browser/memory-directory-variable-contribution.spec.ts +1 -1
- package/src/browser/memory-directory-variable-contribution.ts +1 -1
- package/src/browser/multi-root-paths.spec.ts +2 -2
- package/src/browser/open-editors-hint-contribution.ts +1 -1
- package/src/browser/remember-command-contribution.ts +2 -2
- package/src/browser/review/pr-review-agent.ts +1 -1
- package/src/browser/review/pr-review-capability-contribution.ts +6 -6
- package/src/browser/review/pr-review-prompt-template.ts +4 -4
- package/src/browser/shell-execution-capability-contribution.ts +1 -1
- package/src/browser/skill-file-functions.spec.ts +1 -1
- package/src/browser/skill-file-functions.ts +1 -1
- package/src/browser/summarize-session-command-contribution.ts +2 -2
- package/src/browser/task-background-summary-variable.ts +1 -1
- package/src/browser/task-context-file-storage-service.spec.ts +1 -1
- package/src/browser/task-context-file-storage-service.ts +1 -1
- package/src/browser/task-context-functions.ts +1 -1
- package/src/browser/template-preference-contribution.ts +1 -1
- package/src/browser/todo-tool-renderer.tsx +1 -1
- package/src/browser/todo-tool.spec.ts +1 -1
- package/src/browser/todo-tool.ts +1 -1
- package/src/browser/user-interaction-tool-renderer.tsx +3 -3
- package/src/browser/user-interaction-tool.spec.ts +3 -3
- package/src/browser/user-interaction-tool.ts +2 -2
- package/src/browser/workspace-functions.spec.ts +16 -7
- package/src/browser/workspace-functions.ts +7 -6
- package/src/browser/workspace-launch-provider.spec.ts +2 -2
- package/src/browser/workspace-launch-provider.ts +2 -2
- package/src/browser/workspace-search-provider.spec.ts +2 -2
- package/src/browser/workspace-search-provider.ts +4 -4
- package/src/browser/workspace-task-provider.spec.ts +2 -2
- package/src/browser/workspace-task-provider.ts +2 -2
- package/src/common/agents-md-prompt-template.ts +4 -4
- package/src/common/coder-replace-prompt-template.ts +8 -8
- package/src/common/command-chat-agents.ts +1 -1
- package/src/common/context-files-variable.ts +1 -1
- package/src/common/create-skill-prompt-template.ts +4 -4
- package/src/common/orchestrator-chat-agent.ts +2 -2
- package/src/common/universal-chat-agent.ts +1 -1
- package/src/common/universal-prompt-template.ts +1 -1
- package/src/common/user-interaction-tool.spec.ts +1 -1
- package/src/common/workspace-search-provider-util.spec.ts +1 -1
- package/src/node/app-tester-agent/browser-automation-impl.ts +1 -1
- package/src/node/backend-module.ts +7 -7
- package/src/node/github-repo-service-impl.ts +1 -1
|
@@ -25,7 +25,7 @@ import { PreferenceScope, PreferenceService } from '@theia/core/lib/common';
|
|
|
25
25
|
import { PreferencesCommands } from '@theia/preferences/lib/browser/util/preference-types';
|
|
26
26
|
import { EditorManager } from '@theia/editor/lib/browser';
|
|
27
27
|
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
28
|
-
import { githubTemplate, REQUIRED_GITHUB_MCP_SERVERS } from './github-prompt-template';
|
|
28
|
+
import { githubTemplate, REQUIRED_GITHUB_MCP_SERVERS } from './github-prompt-template.js';
|
|
29
29
|
|
|
30
30
|
export const GitHubChatAgentId = 'GitHub';
|
|
31
31
|
|
|
@@ -166,7 +166,7 @@ export class GitHubChatAgent extends AbstractStreamParsingChatAgent {
|
|
|
166
166
|
}
|
|
167
167
|
|
|
168
168
|
protected async offerConfiguration(): Promise<void> {
|
|
169
|
-
const currentServers = this.preferenceService.get<Record<string, MCPServerDescription>>(MCP_SERVERS_PREF, {});
|
|
169
|
+
const currentServers = this.preferenceService.get<Record<string, MCPServerDescription>>(MCP_SERVERS_PREF, {fallback: {}});
|
|
170
170
|
const githubServer = REQUIRED_GITHUB_MCP_SERVERS[0];
|
|
171
171
|
|
|
172
172
|
const { name, ...serverWithoutName } = githubServer;
|
|
@@ -234,7 +234,7 @@ export class GitHubChatAgent extends AbstractStreamParsingChatAgent {
|
|
|
234
234
|
async ensureServerStarted(server: MCPServerDescription): Promise<void> {
|
|
235
235
|
try {
|
|
236
236
|
if (!(await this.mcpService.hasServer(server.name))) {
|
|
237
|
-
const currentServers = this.preferenceService.get<Record<string, MCPServerDescription>>(MCP_SERVERS_PREF, {});
|
|
237
|
+
const currentServers = this.preferenceService.get<Record<string, MCPServerDescription>>(MCP_SERVERS_PREF, {fallback: {}});
|
|
238
238
|
const { name, ...serverWithoutName } = server;
|
|
239
239
|
await this.preferenceService.set(MCP_SERVERS_PREF, { ...currentServers, [name]: serverWithoutName }, PreferenceScope.User);
|
|
240
240
|
await this.mcpService.addOrUpdateServer(server);
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
29
29
|
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
30
30
|
|
|
31
|
-
import { GitHubRepoService } from '../common/github-repo-protocol';
|
|
31
|
+
import { GitHubRepoService } from '../common/github-repo-protocol.js';
|
|
32
32
|
|
|
33
33
|
export const GITHUB_REPO_NAME_VARIABLE: AIVariable = {
|
|
34
34
|
id: 'github-repo-name-provider',
|
|
@@ -24,12 +24,12 @@ import { FrontendLanguageModelRegistry } from '@theia/ai-core/lib/common';
|
|
|
24
24
|
import { PreferenceService } from '@theia/core/lib/common';
|
|
25
25
|
import { BYPASS_MODEL_REQUIREMENT_PREF, DEFAULT_CHAT_AGENT_PREF } from '@theia/ai-chat/lib/common/ai-chat-preferences';
|
|
26
26
|
import { WalkthroughService } from '@theia/getting-started/lib/browser/walkthrough-service';
|
|
27
|
-
import { OPEN_AI_CONFIG_VIEW } from './ai-configuration/ai-configuration-view-contribution';
|
|
27
|
+
import { OPEN_AI_CONFIG_VIEW } from './ai-configuration/ai-configuration-view-contribution.js';
|
|
28
28
|
import { AIActivationService } from '@theia/ai-core/lib/browser';
|
|
29
29
|
import { FrontendApplicationConfigProvider } from '@theia/core/lib/browser/frontend-application-config-provider';
|
|
30
30
|
import { WorkspaceCommands } from '@theia/workspace/lib/browser/workspace-commands';
|
|
31
|
-
import { AI_OPEN_GETTING_STARTED_WALKTHROUGH } from './ai-getting-started-commands';
|
|
32
|
-
import { AI_GETTING_STARTED_WALKTHROUGH_ID } from './ai-getting-started-walkthrough';
|
|
31
|
+
import { AI_OPEN_GETTING_STARTED_WALKTHROUGH } from './ai-getting-started-commands.js';
|
|
32
|
+
import { AI_GETTING_STARTED_WALKTHROUGH_ID } from './ai-getting-started-walkthrough.js';
|
|
33
33
|
|
|
34
34
|
const TheiaIdeAiLogo = ({ width = 120, height = 120, className = '' }) =>
|
|
35
35
|
<svg
|
|
@@ -19,7 +19,7 @@ import { inject, injectable } from '@theia/core/shared/inversify';
|
|
|
19
19
|
import { PromptService } from '@theia/ai-core/lib/common';
|
|
20
20
|
import { nls } from '@theia/core';
|
|
21
21
|
import { AGENT_DELEGATION_FUNCTION_ID } from '@theia/ai-core';
|
|
22
|
-
import { GitHubChatAgentId } from './github-chat-agent';
|
|
22
|
+
import { GitHubChatAgentId } from './github-chat-agent.js';
|
|
23
23
|
|
|
24
24
|
@injectable()
|
|
25
25
|
export class FixGitHubTicketCommandContribution implements FrontendApplicationContribution {
|
|
@@ -22,10 +22,10 @@ import {
|
|
|
22
22
|
FIND_FILES_BY_PATTERN_FUNCTION_ID,
|
|
23
23
|
GET_WORKSPACE_FILE_LIST_FUNCTION_ID,
|
|
24
24
|
SEARCH_IN_WORKSPACE_FUNCTION_ID
|
|
25
|
-
} from '../common/workspace-functions';
|
|
26
|
-
import { WRITE_FILE_CONTENT_ID, WRITE_FILE_REPLACEMENTS_ID } from '../common/file-changeset-function-ids';
|
|
27
|
-
import { MEMORY_DIRECTORY_VARIABLE } from './memory-directory-variable-contribution';
|
|
28
|
-
import { MemoryCapabilityContribution } from './memory-capability-contribution';
|
|
25
|
+
} from '../common/workspace-functions.js';
|
|
26
|
+
import { WRITE_FILE_CONTENT_ID, WRITE_FILE_REPLACEMENTS_ID } from '../common/file-changeset-function-ids.js';
|
|
27
|
+
import { MEMORY_DIRECTORY_VARIABLE } from './memory-directory-variable-contribution.js';
|
|
28
|
+
import { MemoryCapabilityContribution } from './memory-capability-contribution.js';
|
|
29
29
|
|
|
30
30
|
const registerFragment = (): { id: string, template: string } => {
|
|
31
31
|
const fragments: Array<{ id: string, template: string }> = [];
|
|
@@ -18,9 +18,11 @@ import { FrontendApplicationContribution } from '@theia/core/lib/browser';
|
|
|
18
18
|
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
19
19
|
import { PromptService } from '@theia/ai-core';
|
|
20
20
|
import { nls } from '@theia/core';
|
|
21
|
-
import {
|
|
22
|
-
|
|
23
|
-
|
|
21
|
+
import {
|
|
22
|
+
GET_WORKSPACE_FILE_LIST_FUNCTION_ID, FILE_CONTENT_FUNCTION_ID, SEARCH_IN_WORKSPACE_FUNCTION_ID, FIND_FILES_BY_PATTERN_FUNCTION_ID
|
|
23
|
+
} from '../common/workspace-functions.js';
|
|
24
|
+
import { WRITE_FILE_REPLACEMENTS_ID, WRITE_FILE_CONTENT_ID } from '../common/file-changeset-function-ids.js';
|
|
25
|
+
import { MEMORY_DIRECTORY_VARIABLE } from './memory-directory-variable-contribution.js';
|
|
24
26
|
|
|
25
27
|
@injectable()
|
|
26
28
|
export class MemoryCapabilityContribution implements FrontendApplicationContribution {
|
|
@@ -19,7 +19,7 @@ import { URI } from '@theia/core';
|
|
|
19
19
|
import { Container } from '@theia/core/shared/inversify';
|
|
20
20
|
import { WorkspaceMetadataStorageService, WorkspaceMetadataStore } from '@theia/workspace/lib/browser/metadata-storage';
|
|
21
21
|
import { WorkspaceService } from '@theia/workspace/lib/browser/workspace-service';
|
|
22
|
-
import { MEMORY_DIRECTORY_VARIABLE, MEMORY_METADATA_STORE_KEY, MemoryDirectoryVariableContribution } from './memory-directory-variable-contribution';
|
|
22
|
+
import { MEMORY_DIRECTORY_VARIABLE, MEMORY_METADATA_STORE_KEY, MemoryDirectoryVariableContribution } from './memory-directory-variable-contribution.js';
|
|
23
23
|
|
|
24
24
|
describe('MemoryDirectoryVariableContribution', () => {
|
|
25
25
|
|
|
@@ -21,7 +21,7 @@ import { MaybePromise, URI, nls } from '@theia/core';
|
|
|
21
21
|
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
22
22
|
import { WorkspaceMetadataStorageService, WorkspaceMetadataStore } from '@theia/workspace/lib/browser/metadata-storage';
|
|
23
23
|
import { WorkspaceService } from '@theia/workspace/lib/browser/workspace-service';
|
|
24
|
-
import { AccessibleRootContribution } from './workspace-functions';
|
|
24
|
+
import { AccessibleRootContribution } from './workspace-functions.js';
|
|
25
25
|
|
|
26
26
|
/** Key under which the memory directory is requested from the workspace metadata storage. */
|
|
27
27
|
export const MEMORY_METADATA_STORE_KEY = 'memory';
|
|
@@ -35,8 +35,8 @@ import { ShellExecutionRequest, ShellExecutionServer } from '@theia/ai-terminal/
|
|
|
35
35
|
import { ShellExecutionTool } from '@theia/ai-terminal/lib/browser/shell-execution-tool';
|
|
36
36
|
import { ShellCommandPermissionService } from '@theia/ai-terminal/lib/browser/shell-command-permission-service';
|
|
37
37
|
import { Minimatch } from 'minimatch';
|
|
38
|
-
import { FindFilesByPattern, GetWorkspaceFileList, WorkspaceFunctionScope } from './workspace-functions';
|
|
39
|
-
import { WorkspaceSearchProvider } from './workspace-search-provider';
|
|
38
|
+
import { FindFilesByPattern, GetWorkspaceFileList, WorkspaceFunctionScope } from './workspace-functions.js';
|
|
39
|
+
import { WorkspaceSearchProvider } from './workspace-search-provider.js';
|
|
40
40
|
|
|
41
41
|
disableJSDOM();
|
|
42
42
|
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
import { FrontendApplicationContribution } from '@theia/core/lib/browser';
|
|
18
18
|
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
19
19
|
import { PromptService } from '@theia/ai-core/lib/common';
|
|
20
|
-
import { OPEN_EDITORS_HINT_FRAGMENT_ID } from '../common/open-editors-hint-fragment-id';
|
|
20
|
+
import { OPEN_EDITORS_HINT_FRAGMENT_ID } from '../common/open-editors-hint-fragment-id.js';
|
|
21
21
|
|
|
22
22
|
@injectable()
|
|
23
23
|
export class OpenEditorsHintContribution implements FrontendApplicationContribution {
|
|
@@ -19,8 +19,8 @@ import { inject, injectable } from '@theia/core/shared/inversify';
|
|
|
19
19
|
import { PromptService } from '@theia/ai-core/lib/common';
|
|
20
20
|
import { nls } from '@theia/core';
|
|
21
21
|
import { AGENT_DELEGATION_FUNCTION_ID, AGENTS_MD_FILE_NAME } from '@theia/ai-core';
|
|
22
|
-
import { ArchitectAgentId } from './architect-agent';
|
|
23
|
-
import { CoderAgentId } from './coder-agent';
|
|
22
|
+
import { ArchitectAgentId } from './architect-agent.js';
|
|
23
|
+
import { CoderAgentId } from './coder-agent.js';
|
|
24
24
|
|
|
25
25
|
/**
|
|
26
26
|
* Contribution that registers the `/remember` slash command for AI chat agents.
|
|
@@ -18,7 +18,7 @@ import { AbstractStreamParsingChatAgent } from '@theia/ai-chat';
|
|
|
18
18
|
import { LanguageModelRequirement } from '@theia/ai-core/lib/common';
|
|
19
19
|
import { ILogger, nls } from '@theia/core';
|
|
20
20
|
import { inject, injectable, named } from '@theia/core/shared/inversify';
|
|
21
|
-
import { PR_REVIEW_SYSTEM_PROMPT_ID, prReviewSystemPrompt } from './pr-review-prompt-template';
|
|
21
|
+
import { PR_REVIEW_SYSTEM_PROMPT_ID, prReviewSystemPrompt } from './pr-review-prompt-template.js';
|
|
22
22
|
|
|
23
23
|
export const PRReviewAgentId = 'pr-reviewer';
|
|
24
24
|
|
|
@@ -23,17 +23,17 @@ import { SHELL_EXECUTION_FUNCTION_ID } from '@theia/ai-terminal/lib/common/shell
|
|
|
23
23
|
import {
|
|
24
24
|
LIST_TASKS_FUNCTION_ID,
|
|
25
25
|
RUN_TASK_FUNCTION_ID
|
|
26
|
-
} from '../../common/workspace-functions';
|
|
27
|
-
import { USER_INTERACTION_FUNCTION_ID } from '../../common/user-interaction-tool';
|
|
28
|
-
import { GitHubChatAgentId } from '../github-chat-agent';
|
|
29
|
-
import { ExploreAgentId } from '../explore-agent';
|
|
26
|
+
} from '../../common/workspace-functions.js';
|
|
27
|
+
import { USER_INTERACTION_FUNCTION_ID } from '../../common/user-interaction-tool.js';
|
|
28
|
+
import { GitHubChatAgentId } from '../github-chat-agent.js';
|
|
29
|
+
import { ExploreAgentId } from '../explore-agent.js';
|
|
30
30
|
import {
|
|
31
31
|
PR_REVIEW_CODEBASE_EXPLORATION_CAPABILITY_ID,
|
|
32
32
|
PR_REVIEW_GITHUB_INFORMATION_CAPABILITY_ID,
|
|
33
33
|
PR_REVIEW_LOCAL_CHECKOUT_CAPABILITY_ID,
|
|
34
34
|
PR_REVIEW_LOCAL_VALIDATION_CAPABILITY_ID,
|
|
35
35
|
PR_REVIEW_PENDING_GITHUB_REVIEW_CAPABILITY_ID
|
|
36
|
-
} from './pr-review-prompt-template';
|
|
36
|
+
} from './pr-review-prompt-template.js';
|
|
37
37
|
|
|
38
38
|
@injectable()
|
|
39
39
|
export class PRReviewCapabilityContribution implements FrontendApplicationContribution {
|
|
@@ -137,7 +137,7 @@ Store these values for the review plan and cleanup:
|
|
|
137
137
|
}
|
|
138
138
|
|
|
139
139
|
protected buildLocalValidationTemplate(): string {
|
|
140
|
-
const name = nls.
|
|
140
|
+
const name = nls.localizeByDefault('Build');
|
|
141
141
|
const description = nls.localize('theia/ai/ide/prReview/capability/localValidation/description',
|
|
142
142
|
'Runs local install, build, lint, test, or comparable validation tasks for the pull request.');
|
|
143
143
|
|
|
@@ -16,20 +16,20 @@
|
|
|
16
16
|
// *****************************************************************************
|
|
17
17
|
|
|
18
18
|
import { AGENTS_MD_FILE_NAME, AGENTS_MD_PROMPT_FRAGMENT_ID, BasePromptFragment } from '@theia/ai-core/lib/common';
|
|
19
|
-
import { CONTEXT_FILES_VARIABLE_ID, TASK_CONTEXT_SUMMARY_VARIABLE_ID } from '../../common/context-variables';
|
|
19
|
+
import { CONTEXT_FILES_VARIABLE_ID, TASK_CONTEXT_SUMMARY_VARIABLE_ID } from '../../common/context-variables.js';
|
|
20
20
|
import {
|
|
21
21
|
FILE_CONTENT_FUNCTION_ID,
|
|
22
22
|
GET_FILE_DIAGNOSTICS_ID,
|
|
23
23
|
SEARCH_IN_WORKSPACE_FUNCTION_ID
|
|
24
|
-
} from '../../common/workspace-functions';
|
|
24
|
+
} from '../../common/workspace-functions.js';
|
|
25
25
|
import {
|
|
26
26
|
CREATE_TASK_CONTEXT_FUNCTION_ID,
|
|
27
27
|
GET_TASK_CONTEXT_FUNCTION_ID,
|
|
28
28
|
EDIT_TASK_CONTEXT_FUNCTION_ID,
|
|
29
29
|
LIST_TASK_CONTEXTS_FUNCTION_ID,
|
|
30
30
|
REWRITE_TASK_CONTEXT_FUNCTION_ID
|
|
31
|
-
} from '../../common/task-context-function-ids';
|
|
32
|
-
import { USER_INTERACTION_FUNCTION_ID } from '../../common/user-interaction-tool';
|
|
31
|
+
} from '../../common/task-context-function-ids.js';
|
|
32
|
+
import { USER_INTERACTION_FUNCTION_ID } from '../../common/user-interaction-tool.js';
|
|
33
33
|
|
|
34
34
|
export const PR_REVIEW_SYSTEM_PROMPT_ID = 'pr-review-system';
|
|
35
35
|
export const PR_REVIEW_GITHUB_INFORMATION_CAPABILITY_ID = 'pr-review-github-information';
|
|
@@ -18,7 +18,7 @@ import { FrontendApplicationContribution } from '@theia/core/lib/browser';
|
|
|
18
18
|
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
19
19
|
import { PromptService } from '@theia/ai-core/lib/common';
|
|
20
20
|
import { SHELL_EXECUTION_FUNCTION_ID } from '@theia/ai-terminal/lib/common/shell-execution-server';
|
|
21
|
-
import { LIST_TASKS_FUNCTION_ID, RUN_TASK_FUNCTION_ID } from '../common/workspace-functions';
|
|
21
|
+
import { LIST_TASKS_FUNCTION_ID, RUN_TASK_FUNCTION_ID } from '../common/workspace-functions.js';
|
|
22
22
|
import { nls } from '@theia/core';
|
|
23
23
|
|
|
24
24
|
@injectable()
|
|
@@ -25,7 +25,7 @@ import { expect } from 'chai';
|
|
|
25
25
|
import { Container } from '@theia/core/shared/inversify';
|
|
26
26
|
import { SkillService } from '@theia/ai-core/lib/browser/skill-service';
|
|
27
27
|
import { Skill } from '@theia/ai-core/lib/common/skill';
|
|
28
|
-
import { ListSkills } from './skill-file-functions';
|
|
28
|
+
import { ListSkills } from './skill-file-functions.js';
|
|
29
29
|
|
|
30
30
|
disableJSDOM();
|
|
31
31
|
|
|
@@ -20,7 +20,7 @@ import { URI } from '@theia/core';
|
|
|
20
20
|
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
21
21
|
import { SkillService } from '@theia/ai-core/lib/browser/skill-service';
|
|
22
22
|
import { parseSkillFile } from '@theia/ai-core/lib/common/skill';
|
|
23
|
-
import { GET_SKILL_FILE_CONTENT_FUNCTION_ID, LIST_SKILLS_FUNCTION_ID } from '../common/workspace-functions';
|
|
23
|
+
import { GET_SKILL_FILE_CONTENT_FUNCTION_ID, LIST_SKILLS_FUNCTION_ID } from '../common/workspace-functions.js';
|
|
24
24
|
|
|
25
25
|
@injectable()
|
|
26
26
|
export class ListSkills implements ToolProvider {
|
|
@@ -18,8 +18,8 @@ import { ChatAgentLocation, ChatService } from '@theia/ai-chat/lib/common';
|
|
|
18
18
|
import { CommandContribution, CommandRegistry, CommandService, ILogger } from '@theia/core';
|
|
19
19
|
import { TaskContextStorageService, TaskContextService } from '@theia/ai-chat/lib/browser/task-context-service';
|
|
20
20
|
import { injectable, inject, named } from '@theia/core/shared/inversify';
|
|
21
|
-
import { AI_EXECUTE_PLAN_WITH_CODER } from '../common/summarize-session-commands';
|
|
22
|
-
import { CoderAgent } from './coder-agent';
|
|
21
|
+
import { AI_EXECUTE_PLAN_WITH_CODER } from '../common/summarize-session-commands.js';
|
|
22
|
+
import { CoderAgent } from './coder-agent.js';
|
|
23
23
|
import { TASK_CONTEXT_VARIABLE } from '@theia/ai-chat/lib/browser/task-context-variable';
|
|
24
24
|
|
|
25
25
|
import { FILE_VARIABLE } from '@theia/ai-core/lib/browser/file-variable-contribution';
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
} from '@theia/ai-core';
|
|
29
29
|
import { ChatSessionContext } from '@theia/ai-chat';
|
|
30
30
|
import { TASK_CONTEXT_VARIABLE } from '@theia/ai-chat/lib/browser/task-context-variable';
|
|
31
|
-
import { TASK_CONTEXT_SUMMARY_VARIABLE_ID } from '../common/context-variables';
|
|
31
|
+
import { TASK_CONTEXT_SUMMARY_VARIABLE_ID } from '../common/context-variables.js';
|
|
32
32
|
|
|
33
33
|
export const TASK_CONTEXT_SUMMARY_VARIABLE: AIVariable = {
|
|
34
34
|
id: TASK_CONTEXT_SUMMARY_VARIABLE_ID,
|
|
@@ -27,7 +27,7 @@ import { AIVariableResourceResolver } from '@theia/ai-core';
|
|
|
27
27
|
import { InMemoryTaskContextStorage } from '@theia/ai-chat/lib/browser/task-context-storage-service';
|
|
28
28
|
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
29
29
|
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
30
|
-
import { TaskContextFileStorageService } from './task-context-file-storage-service';
|
|
30
|
+
import { TaskContextFileStorageService } from './task-context-file-storage-service.js';
|
|
31
31
|
disableJSDOM();
|
|
32
32
|
|
|
33
33
|
const workspaceRoot = new URI('file:///workspace');
|
|
@@ -23,7 +23,7 @@ import { OpenerService, open } from '@theia/core/lib/browser';
|
|
|
23
23
|
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
24
24
|
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
25
25
|
import { FileChange, FileChangeType } from '@theia/filesystem/lib/common/files';
|
|
26
|
-
import { TASK_CONTEXT_STORAGE_DIRECTORY_PREF } from '../common/workspace-preferences';
|
|
26
|
+
import { TASK_CONTEXT_STORAGE_DIRECTORY_PREF } from '../common/workspace-preferences.js';
|
|
27
27
|
import { BinaryBuffer } from '@theia/core/lib/common/buffer';
|
|
28
28
|
|
|
29
29
|
@injectable()
|
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
EDIT_TASK_CONTEXT_FUNCTION_ID,
|
|
28
28
|
LIST_TASK_CONTEXTS_FUNCTION_ID,
|
|
29
29
|
REWRITE_TASK_CONTEXT_FUNCTION_ID
|
|
30
|
-
} from '../common/task-context-function-ids';
|
|
30
|
+
} from '../common/task-context-function-ids.js';
|
|
31
31
|
|
|
32
32
|
@injectable()
|
|
33
33
|
export class CreateTaskContextFunction implements ToolProvider {
|
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
PROMPT_TEMPLATE_WORKSPACE_DIRECTORIES_PREF,
|
|
24
24
|
PROMPT_TEMPLATE_ADDITIONAL_EXTENSIONS_PREF,
|
|
25
25
|
PROMPT_TEMPLATE_WORKSPACE_FILES_PREF
|
|
26
|
-
} from '../common/workspace-preferences';
|
|
26
|
+
} from '../common/workspace-preferences.js';
|
|
27
27
|
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
28
28
|
import { Path, PreferenceService } from '@theia/core';
|
|
29
29
|
import { WorkspaceTrustService } from '@theia/workspace/lib/browser/workspace-trust-service';
|
|
@@ -22,7 +22,7 @@ import { ReactNode } from '@theia/core/shared/react';
|
|
|
22
22
|
import * as React from '@theia/core/shared/react';
|
|
23
23
|
import { codicon, ContextMenuRenderer, KeybindingRegistry, OpenerService } from '@theia/core/lib/browser';
|
|
24
24
|
import { nls } from '@theia/core';
|
|
25
|
-
import { TODO_WRITE_FUNCTION_ID, TodoItem, isValidTodoItem } from '../common/todo-tool';
|
|
25
|
+
import { TODO_WRITE_FUNCTION_ID, TodoItem, isValidTodoItem } from '../common/todo-tool.js';
|
|
26
26
|
import { ToolConfirmationKeybindingHints, withToolCallConfirmation } from '@theia/ai-chat-ui/lib/browser/chat-response-renderer/tool-confirmation';
|
|
27
27
|
import {
|
|
28
28
|
APPROVE_LATEST_TOOL_CONFIRMATION_COMMAND,
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
// *****************************************************************************
|
|
16
16
|
|
|
17
17
|
import { expect } from 'chai';
|
|
18
|
-
import { isValidTodoItem } from '../common/todo-tool';
|
|
18
|
+
import { isValidTodoItem } from '../common/todo-tool.js';
|
|
19
19
|
|
|
20
20
|
describe('isValidTodoItem', () => {
|
|
21
21
|
it('should accept a minimal valid item', () => {
|
package/src/browser/todo-tool.ts
CHANGED
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
|
|
17
17
|
import { injectable } from '@theia/core/shared/inversify';
|
|
18
18
|
import { ToolProvider, ToolRequest } from '@theia/ai-core/lib/common';
|
|
19
|
-
import { TODO_WRITE_FUNCTION_ID, isValidTodoItem } from '../common/todo-tool';
|
|
19
|
+
import { TODO_WRITE_FUNCTION_ID, isValidTodoItem } from '../common/todo-tool.js';
|
|
20
20
|
|
|
21
21
|
@injectable()
|
|
22
22
|
export class TodoWriteTool implements ToolProvider {
|
|
@@ -35,7 +35,7 @@ import {
|
|
|
35
35
|
import { ToolConfirmationManager } from '@theia/ai-chat/lib/browser/chat-tool-preference-bindings';
|
|
36
36
|
import { PendingToolConfirmationTracker } from '@theia/ai-chat/lib/browser/pending-tool-confirmation-tracker';
|
|
37
37
|
import { ToolInvocationRegistry } from '@theia/ai-core';
|
|
38
|
-
import { UserInteractionTool } from './user-interaction-tool';
|
|
38
|
+
import { UserInteractionTool } from './user-interaction-tool.js';
|
|
39
39
|
import {
|
|
40
40
|
USER_INTERACTION_FUNCTION_ID,
|
|
41
41
|
UserInteractionArgs,
|
|
@@ -49,7 +49,7 @@ import {
|
|
|
49
49
|
parseUserInteractionInput,
|
|
50
50
|
parseUserInteractionResult,
|
|
51
51
|
resolveContentRef,
|
|
52
|
-
} from '../common/user-interaction-tool';
|
|
52
|
+
} from '../common/user-interaction-tool.js';
|
|
53
53
|
|
|
54
54
|
interface StepState {
|
|
55
55
|
value?: string;
|
|
@@ -281,7 +281,7 @@ const UserInteractionComponent: React.FC<UserInteractionComponentProps> = ({
|
|
|
281
281
|
}
|
|
282
282
|
return (
|
|
283
283
|
<span className='user-interaction-tool status waiting' role='status' aria-live='polite'>
|
|
284
|
-
{nls.
|
|
284
|
+
{nls.localizeByDefault('Waiting for input')}
|
|
285
285
|
</span>
|
|
286
286
|
);
|
|
287
287
|
})()}
|
|
@@ -21,9 +21,9 @@ FrontendApplicationConfigProvider.set({});
|
|
|
21
21
|
import { expect } from 'chai';
|
|
22
22
|
import * as sinon from 'sinon';
|
|
23
23
|
import { Container } from '@theia/core/shared/inversify';
|
|
24
|
-
import { UserInteractionTool } from './user-interaction-tool';
|
|
25
|
-
import { UserInteractionResult } from '../common/user-interaction-tool';
|
|
26
|
-
import { WorkspaceFunctionScope } from './workspace-functions';
|
|
24
|
+
import { UserInteractionTool } from './user-interaction-tool.js';
|
|
25
|
+
import { UserInteractionResult } from '../common/user-interaction-tool.js';
|
|
26
|
+
import { WorkspaceFunctionScope } from './workspace-functions.js';
|
|
27
27
|
import { OpenerService } from '@theia/core/lib/browser';
|
|
28
28
|
import { EditorManager } from '@theia/editor/lib/browser';
|
|
29
29
|
import { ScmService } from '@theia/scm/lib/browser/scm-service';
|
|
@@ -25,7 +25,7 @@ import URI from '@theia/core/lib/common/uri';
|
|
|
25
25
|
import { inject, injectable, named } from '@theia/core/shared/inversify';
|
|
26
26
|
import { EditorManager } from '@theia/editor/lib/browser';
|
|
27
27
|
import { ScmService } from '@theia/scm/lib/browser/scm-service';
|
|
28
|
-
import { WorkspaceFunctionScope } from './workspace-functions';
|
|
28
|
+
import { WorkspaceFunctionScope } from './workspace-functions.js';
|
|
29
29
|
import {
|
|
30
30
|
ContentRef,
|
|
31
31
|
USER_INTERACTION_FUNCTION_ID,
|
|
@@ -38,7 +38,7 @@ import {
|
|
|
38
38
|
normalizeUserInteractionLink,
|
|
39
39
|
parseUserInteractionArgs,
|
|
40
40
|
resolveContentRef
|
|
41
|
-
} from '../common/user-interaction-tool';
|
|
41
|
+
} from '../common/user-interaction-tool.js';
|
|
42
42
|
import { ILogger } from '@theia/core';
|
|
43
43
|
|
|
44
44
|
interface PendingInteraction {
|
|
@@ -29,7 +29,7 @@ import {
|
|
|
29
29
|
FileDiagnosticProvider,
|
|
30
30
|
WorkspaceFunctionScope,
|
|
31
31
|
FindFilesByPattern
|
|
32
|
-
} from './workspace-functions';
|
|
32
|
+
} from './workspace-functions.js';
|
|
33
33
|
import { bindRootContributionProvider } from '@theia/core/lib/common/contribution-provider';
|
|
34
34
|
import { AiConfigurationService, ToolInvocationContext } from '@theia/ai-core';
|
|
35
35
|
import { Container } from '@theia/core/shared/inversify';
|
|
@@ -145,7 +145,7 @@ describe('Workspace Functions Cancellation Tests', () => {
|
|
|
145
145
|
} as unknown as FileService;
|
|
146
146
|
|
|
147
147
|
const mockPreferenceService = {
|
|
148
|
-
get: <T>(_path: string,
|
|
148
|
+
get: <T>(_path: string, options?: { fallback?: T }) => options?.fallback
|
|
149
149
|
};
|
|
150
150
|
|
|
151
151
|
const mockMonacoWorkspace = {
|
|
@@ -287,7 +287,7 @@ describe('FileContentFunction.getArgumentsShortLabel', () => {
|
|
|
287
287
|
} as unknown as FileService;
|
|
288
288
|
|
|
289
289
|
const mockPreferenceService = {
|
|
290
|
-
get: <T>(_path: string,
|
|
290
|
+
get: <T>(_path: string, options?: { fallback?: T }) => options?.fallback
|
|
291
291
|
};
|
|
292
292
|
|
|
293
293
|
const mockMonacoWorkspace = {
|
|
@@ -348,7 +348,7 @@ describe('FileContentFunction handler', () => {
|
|
|
348
348
|
let mockRead: () => Promise<unknown>;
|
|
349
349
|
let mockReadStream: () => Promise<unknown>;
|
|
350
350
|
let mockMonacoWorkspace: MonacoWorkspace;
|
|
351
|
-
let mockPreferenceService: { get: <T>(path: string,
|
|
351
|
+
let mockPreferenceService: { get: <T>(path: string, optionsOrFallback?: { fallback?: T } | T) => T | undefined };
|
|
352
352
|
|
|
353
353
|
const makeMockStream = (content: string) => {
|
|
354
354
|
const handlers: Record<string, Function> = {};
|
|
@@ -406,7 +406,16 @@ describe('FileContentFunction handler', () => {
|
|
|
406
406
|
} as unknown as FileService;
|
|
407
407
|
|
|
408
408
|
mockPreferenceService = {
|
|
409
|
-
get: <T>(_path: string,
|
|
409
|
+
get: <T>(_path: string, optionsOrFallback?: { fallback?: T } | T) => {
|
|
410
|
+
if (optionsOrFallback === undefined) {
|
|
411
|
+
return undefined;
|
|
412
|
+
}
|
|
413
|
+
// eslint-disable-next-line no-null/no-null
|
|
414
|
+
if (typeof optionsOrFallback === 'object' && optionsOrFallback !== null && !Array.isArray(optionsOrFallback) && 'fallback' in optionsOrFallback) {
|
|
415
|
+
return (optionsOrFallback as { fallback?: T }).fallback;
|
|
416
|
+
}
|
|
417
|
+
return optionsOrFallback as T;
|
|
418
|
+
}
|
|
410
419
|
};
|
|
411
420
|
|
|
412
421
|
mockMonacoWorkspace = {
|
|
@@ -617,7 +626,7 @@ describe('FileContentFunction handler', () => {
|
|
|
617
626
|
|
|
618
627
|
it('uses custom preference value for size limit', async () => {
|
|
619
628
|
// Set a very small limit of 1 KB
|
|
620
|
-
mockPreferenceService.get = <T>(_path: string,
|
|
629
|
+
mockPreferenceService.get = <T>(_path: string, _optionsOrFallback?: { fallback?: T } | T) => 1 as unknown as T;
|
|
621
630
|
|
|
622
631
|
const content = 'x'.repeat(2 * 1024); // 2 KB
|
|
623
632
|
mockRead = async () => ({ value: content });
|
|
@@ -776,7 +785,7 @@ describe('FindFilesByPattern.getArgumentsShortLabel', () => {
|
|
|
776
785
|
} as unknown as FileService;
|
|
777
786
|
|
|
778
787
|
const mockPreferenceService = {
|
|
779
|
-
get: <T>(_path: string,
|
|
788
|
+
get: <T>(_path: string, options?: { fallback?: T }) => options?.fallback
|
|
780
789
|
};
|
|
781
790
|
|
|
782
791
|
container.bind(ILogger).to(MockLogger);
|
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
FILE_CONTENT_FUNCTION_ID, GET_FILE_DIAGNOSTICS_ID,
|
|
28
28
|
GET_WORKSPACE_DIRECTORY_STRUCTURE_FUNCTION_ID,
|
|
29
29
|
GET_WORKSPACE_FILE_LIST_FUNCTION_ID, FIND_FILES_BY_PATTERN_FUNCTION_ID
|
|
30
|
-
} from '../common/workspace-functions';
|
|
30
|
+
} from '../common/workspace-functions.js';
|
|
31
31
|
import { extractJsonStringField } from '@theia/ai-chat-ui/lib/browser/chat-response-renderer/toolcall-utils';
|
|
32
32
|
import ignore from 'ignore';
|
|
33
33
|
import { Minimatch } from 'minimatch';
|
|
@@ -36,7 +36,7 @@ import {
|
|
|
36
36
|
CONSIDER_GITIGNORE_PREF,
|
|
37
37
|
FILE_CONTENT_MAX_SIZE_KB_PREF,
|
|
38
38
|
USER_EXCLUDE_PATTERN_PREF
|
|
39
|
-
} from '../common/workspace-preferences';
|
|
39
|
+
} from '../common/workspace-preferences.js';
|
|
40
40
|
import { MonacoWorkspace } from '@theia/monaco/lib/browser/monaco-workspace';
|
|
41
41
|
import { MonacoTextModelService } from '@theia/monaco/lib/browser/monaco-text-model-service';
|
|
42
42
|
import { ProblemManager } from '@theia/markers/lib/browser';
|
|
@@ -83,7 +83,7 @@ export class WorkspaceFunctionScope {
|
|
|
83
83
|
@inject(ContributionProvider) @named(AccessibleRootContribution) @optional()
|
|
84
84
|
protected readonly accessibleRootContributions: ContributionProvider<AccessibleRootContribution> | undefined;
|
|
85
85
|
|
|
86
|
-
private gitignoreMatchers = new Map<string, ReturnType<typeof ignore> | undefined>();
|
|
86
|
+
private gitignoreMatchers = new Map<string, ReturnType<typeof ignore.default> | undefined>();
|
|
87
87
|
private gitignoreWatchersInitialized = new Set<string>();
|
|
88
88
|
|
|
89
89
|
private _allRootUris: URI[] | undefined;
|
|
@@ -545,7 +545,7 @@ export class WorkspaceFunctionScope {
|
|
|
545
545
|
* The cache is invalidated by {@link initializeGitignoreWatcher} when the `.gitignore` is
|
|
546
546
|
* created, changed, or deleted, so individual exclusion checks need no filesystem RPC.
|
|
547
547
|
*/
|
|
548
|
-
protected async getGitignoreMatcher(workspaceRoot: URI): Promise<ReturnType<typeof ignore> | undefined> {
|
|
548
|
+
protected async getGitignoreMatcher(workspaceRoot: URI): Promise<ReturnType<typeof ignore.default> | undefined> {
|
|
549
549
|
await this.initializeGitignoreWatcher(workspaceRoot);
|
|
550
550
|
|
|
551
551
|
const rootKey = workspaceRoot.toString();
|
|
@@ -553,11 +553,12 @@ export class WorkspaceFunctionScope {
|
|
|
553
553
|
return this.gitignoreMatchers.get(rootKey);
|
|
554
554
|
}
|
|
555
555
|
|
|
556
|
-
let matcher: ReturnType<typeof ignore> | undefined;
|
|
556
|
+
let matcher: ReturnType<typeof ignore.default> | undefined;
|
|
557
557
|
try {
|
|
558
558
|
const gitignoreUri = workspaceRoot.resolve(this.GITIGNORE_FILE_NAME);
|
|
559
559
|
const gitignoreContent = await this.fileService.read(gitignoreUri);
|
|
560
|
-
|
|
560
|
+
// `ignore` is a CommonJS module that also provides itself as `default` export.
|
|
561
|
+
matcher = ignore.default().add(gitignoreContent.value);
|
|
561
562
|
} catch {
|
|
562
563
|
// No .gitignore (or it cannot be read): cache the absence so we don't retry on every check.
|
|
563
564
|
matcher = undefined;
|
|
@@ -27,14 +27,14 @@ import {
|
|
|
27
27
|
LaunchListProvider,
|
|
28
28
|
LaunchRunnerProvider,
|
|
29
29
|
LaunchStopProvider,
|
|
30
|
-
} from './workspace-launch-provider';
|
|
30
|
+
} from './workspace-launch-provider.js';
|
|
31
31
|
import { DebugConfigurationManager } from '@theia/debug/lib/browser/debug-configuration-manager';
|
|
32
32
|
import { DebugSessionManager } from '@theia/debug/lib/browser/debug-session-manager';
|
|
33
33
|
import { DebugSessionOptions } from '@theia/debug/lib/browser/debug-session-options';
|
|
34
34
|
import { DebugConfiguration } from '@theia/debug/lib/common/debug-common';
|
|
35
35
|
import { DebugCompound } from '@theia/debug/lib/common/debug-compound';
|
|
36
36
|
import { DebugSession } from '@theia/debug/lib/browser/debug-session';
|
|
37
|
-
import { WorkspaceFunctionScope } from './workspace-functions';
|
|
37
|
+
import { WorkspaceFunctionScope } from './workspace-functions.js';
|
|
38
38
|
import { AiConfigurationService } from '@theia/ai-core';
|
|
39
39
|
import { EnvVariablesServer } from '@theia/core/lib/common/env-variables';
|
|
40
40
|
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
@@ -26,8 +26,8 @@ import {
|
|
|
26
26
|
LIST_LAUNCH_CONFIGURATIONS_FUNCTION_ID,
|
|
27
27
|
RUN_LAUNCH_CONFIGURATION_FUNCTION_ID,
|
|
28
28
|
STOP_LAUNCH_CONFIGURATION_FUNCTION_ID
|
|
29
|
-
} from '../common/workspace-functions';
|
|
30
|
-
import { WorkspaceFunctionScope } from './workspace-functions';
|
|
29
|
+
} from '../common/workspace-functions.js';
|
|
30
|
+
import { WorkspaceFunctionScope } from './workspace-functions.js';
|
|
31
31
|
|
|
32
32
|
/**
|
|
33
33
|
* Sentinel value returned (and accepted) as `workspaceRoot` for launch
|
|
@@ -17,11 +17,11 @@
|
|
|
17
17
|
import { expect } from 'chai';
|
|
18
18
|
import * as sinon from 'sinon';
|
|
19
19
|
import { CancellationTokenSource, PreferenceService } from '@theia/core';
|
|
20
|
-
import { WorkspaceSearchProvider } from './workspace-search-provider';
|
|
20
|
+
import { WorkspaceSearchProvider } from './workspace-search-provider.js';
|
|
21
21
|
import { ToolInvocationContext } from '@theia/ai-core';
|
|
22
22
|
import { Container } from '@theia/core/shared/inversify';
|
|
23
23
|
import { SearchInWorkspaceService, SearchInWorkspaceCallbacks } from '@theia/search-in-workspace/lib/browser/search-in-workspace-service';
|
|
24
|
-
import { WorkspaceFunctionScope } from './workspace-functions';
|
|
24
|
+
import { WorkspaceFunctionScope } from './workspace-functions.js';
|
|
25
25
|
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
26
26
|
import { URI } from '@theia/core/lib/common/uri';
|
|
27
27
|
import { SearchInWorkspaceOptions } from '@theia/search-in-workspace/lib/common/search-in-workspace-interface';
|
|
@@ -21,10 +21,10 @@ import { inject, injectable } from '@theia/core/shared/inversify';
|
|
|
21
21
|
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
22
22
|
import { SearchInWorkspaceService, SearchInWorkspaceCallbacks } from '@theia/search-in-workspace/lib/browser/search-in-workspace-service';
|
|
23
23
|
import { SearchInWorkspaceResult, SearchInWorkspaceOptions } from '@theia/search-in-workspace/lib/common/search-in-workspace-interface';
|
|
24
|
-
import { SEARCH_IN_WORKSPACE_FUNCTION_ID } from '../common/workspace-functions';
|
|
25
|
-
import { WorkspaceFunctionScope } from './workspace-functions';
|
|
26
|
-
import { SEARCH_IN_WORKSPACE_MAX_RESULTS_PREF } from '../common/workspace-preferences';
|
|
27
|
-
import { optimizeSearchResults } from '../common/workspace-search-provider-util';
|
|
24
|
+
import { SEARCH_IN_WORKSPACE_FUNCTION_ID } from '../common/workspace-functions.js';
|
|
25
|
+
import { WorkspaceFunctionScope } from './workspace-functions.js';
|
|
26
|
+
import { SEARCH_IN_WORKSPACE_MAX_RESULTS_PREF } from '../common/workspace-preferences.js';
|
|
27
|
+
import { optimizeSearchResults } from '../common/workspace-search-provider-util.js';
|
|
28
28
|
|
|
29
29
|
@injectable()
|
|
30
30
|
export class WorkspaceSearchProvider implements ToolProvider {
|
|
@@ -17,14 +17,14 @@
|
|
|
17
17
|
import { expect } from 'chai';
|
|
18
18
|
import { CancellationTokenSource, PreferenceService, ILogger } from '@theia/core';
|
|
19
19
|
import URI from '@theia/core/lib/common/uri';
|
|
20
|
-
import { GLOBAL_SCOPE_TOKEN, TaskListProvider, TaskRunnerProvider, WORKSPACE_SCOPE_TOKEN } from './workspace-task-provider';
|
|
20
|
+
import { GLOBAL_SCOPE_TOKEN, TaskListProvider, TaskRunnerProvider, WORKSPACE_SCOPE_TOKEN } from './workspace-task-provider.js';
|
|
21
21
|
import { AiConfigurationService, ToolInvocationContext } from '@theia/ai-core';
|
|
22
22
|
import { Container } from '@theia/core/shared/inversify';
|
|
23
23
|
import { TaskService } from '@theia/task/lib/browser/task-service';
|
|
24
24
|
import { TerminalService } from '@theia/terminal/lib/browser/base/terminal-service';
|
|
25
25
|
import { TaskConfiguration, TaskInfo, TaskScope } from '@theia/task/lib/common';
|
|
26
26
|
import { TerminalWidget } from '@theia/terminal/lib/browser/base/terminal-widget';
|
|
27
|
-
import { WorkspaceFunctionScope } from './workspace-functions';
|
|
27
|
+
import { WorkspaceFunctionScope } from './workspace-functions.js';
|
|
28
28
|
import { EnvVariablesServer } from '@theia/core/lib/common/env-variables';
|
|
29
29
|
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
30
30
|
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|