@theia/ai-ide 1.65.0-next.6 → 1.65.1
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/ai-configuration/agent-configuration-widget.d.ts +13 -3
- package/lib/browser/ai-configuration/agent-configuration-widget.d.ts.map +1 -1
- package/lib/browser/ai-configuration/agent-configuration-widget.js +72 -38
- package/lib/browser/ai-configuration/agent-configuration-widget.js.map +1 -1
- package/lib/browser/ai-configuration/prompt-fragments-configuration-widget.d.ts.map +1 -1
- package/lib/browser/ai-configuration/prompt-fragments-configuration-widget.js +3 -6
- package/lib/browser/ai-configuration/prompt-fragments-configuration-widget.js.map +1 -1
- package/lib/browser/ai-configuration/tools-configuration-widget.d.ts +4 -2
- package/lib/browser/ai-configuration/tools-configuration-widget.d.ts.map +1 -1
- package/lib/browser/ai-configuration/tools-configuration-widget.js +6 -4
- package/lib/browser/ai-configuration/tools-configuration-widget.js.map +1 -1
- package/lib/browser/ai-ide-activation-service.d.ts +2 -2
- package/lib/browser/ai-ide-activation-service.d.ts.map +1 -1
- package/lib/browser/ai-ide-activation-service.js +2 -3
- package/lib/browser/ai-ide-activation-service.js.map +1 -1
- package/lib/browser/app-tester-chat-agent.d.ts +1 -1
- package/lib/browser/app-tester-chat-agent.d.ts.map +1 -1
- package/lib/browser/app-tester-chat-agent.js +4 -4
- package/lib/browser/app-tester-chat-agent.js.map +1 -1
- package/lib/browser/app-tester-prompt-template.d.ts.map +1 -1
- package/lib/browser/app-tester-prompt-template.js +5 -1
- package/lib/browser/app-tester-prompt-template.js.map +1 -1
- package/lib/browser/architect-agent.d.ts +0 -1
- package/lib/browser/architect-agent.d.ts.map +1 -1
- package/lib/browser/architect-agent.js +0 -2
- package/lib/browser/architect-agent.js.map +1 -1
- package/lib/browser/coder-agent.d.ts +0 -1
- package/lib/browser/coder-agent.d.ts.map +1 -1
- package/lib/browser/coder-agent.js +0 -3
- package/lib/browser/coder-agent.js.map +1 -1
- package/lib/browser/file-changeset-functions.d.ts.map +1 -1
- package/lib/browser/file-changeset-functions.js +2 -1
- package/lib/browser/file-changeset-functions.js.map +1 -1
- package/lib/browser/frontend-module.d.ts.map +1 -1
- package/lib/browser/frontend-module.js +7 -6
- package/lib/browser/frontend-module.js.map +1 -1
- package/lib/browser/task-context-file-storage-service.d.ts +3 -3
- package/lib/browser/task-context-file-storage-service.d.ts.map +1 -1
- package/lib/browser/task-context-file-storage-service.js +5 -5
- package/lib/browser/task-context-file-storage-service.js.map +1 -1
- package/lib/browser/template-preference-contribution.d.ts +2 -1
- package/lib/browser/template-preference-contribution.d.ts.map +1 -1
- package/lib/browser/template-preference-contribution.js +5 -6
- package/lib/browser/template-preference-contribution.js.map +1 -1
- package/lib/browser/workspace-functions.d.ts +12 -2
- package/lib/browser/workspace-functions.d.ts.map +1 -1
- package/lib/browser/workspace-functions.js +181 -19
- package/lib/browser/workspace-functions.js.map +1 -1
- package/lib/browser/workspace-functions.spec.js +1 -1
- package/lib/browser/workspace-functions.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 +2 -2
- package/lib/browser/workspace-search-provider.js.map +1 -1
- package/lib/browser/workspace-search-provider.spec.js +1 -2
- package/lib/browser/workspace-search-provider.spec.js.map +1 -1
- package/lib/{browser/ai-configuration → common}/ai-configuration-preferences.d.ts +1 -1
- package/lib/common/ai-configuration-preferences.d.ts.map +1 -0
- package/lib/{browser/ai-configuration → common}/ai-configuration-preferences.js +0 -1
- package/lib/common/ai-configuration-preferences.js.map +1 -0
- package/lib/{browser → common}/ai-ide-preferences.d.ts +1 -1
- package/lib/common/ai-ide-preferences.d.ts.map +1 -0
- package/lib/{browser → common}/ai-ide-preferences.js +3 -4
- package/lib/common/ai-ide-preferences.js.map +1 -0
- package/lib/common/architect-prompt-template.d.ts.map +1 -1
- package/lib/common/architect-prompt-template.js +5 -2
- package/lib/common/architect-prompt-template.js.map +1 -1
- package/lib/common/coder-replace-prompt-template.d.ts.map +1 -1
- package/lib/common/coder-replace-prompt-template.js +11 -7
- package/lib/common/coder-replace-prompt-template.js.map +1 -1
- package/lib/common/orchestrator-chat-agent.d.ts +0 -1
- package/lib/common/orchestrator-chat-agent.d.ts.map +1 -1
- package/lib/common/orchestrator-chat-agent.js +0 -1
- package/lib/common/orchestrator-chat-agent.js.map +1 -1
- package/lib/common/workspace-functions.d.ts +1 -0
- package/lib/common/workspace-functions.d.ts.map +1 -1
- package/lib/common/workspace-functions.js +2 -1
- package/lib/common/workspace-functions.js.map +1 -1
- package/lib/{browser → common}/workspace-preferences.d.ts +1 -1
- package/lib/common/workspace-preferences.d.ts.map +1 -0
- package/lib/{browser → common}/workspace-preferences.js +0 -1
- package/lib/common/workspace-preferences.js.map +1 -0
- package/lib/node/backend-module.d.ts.map +1 -1
- package/lib/node/backend-module.js +6 -0
- package/lib/node/backend-module.js.map +1 -1
- package/package.json +19 -19
- package/src/browser/ai-configuration/agent-configuration-widget.tsx +86 -44
- package/src/browser/ai-configuration/prompt-fragments-configuration-widget.tsx +3 -5
- package/src/browser/ai-configuration/tools-configuration-widget.tsx +4 -2
- package/src/browser/ai-ide-activation-service.ts +4 -4
- package/src/browser/app-tester-chat-agent.ts +2 -2
- package/src/browser/app-tester-prompt-template.ts +5 -1
- package/src/browser/architect-agent.ts +0 -2
- package/src/browser/coder-agent.ts +0 -3
- package/src/browser/file-changeset-functions.ts +2 -1
- package/src/browser/frontend-module.ts +13 -6
- package/src/browser/task-context-file-storage-service.ts +6 -6
- package/src/browser/template-preference-contribution.ts +3 -3
- package/src/browser/workspace-functions.spec.ts +2 -2
- package/src/browser/workspace-functions.ts +201 -19
- package/src/browser/workspace-search-provider.spec.ts +1 -2
- package/src/browser/workspace-search-provider.ts +2 -2
- package/src/{browser/ai-configuration → common}/ai-configuration-preferences.ts +1 -2
- package/src/{browser → common}/ai-ide-preferences.ts +3 -5
- package/src/common/architect-prompt-template.ts +7 -4
- package/src/common/coder-replace-prompt-template.ts +12 -8
- package/src/common/orchestrator-chat-agent.ts +0 -1
- package/src/common/workspace-functions.ts +1 -0
- package/src/{browser → common}/workspace-preferences.ts +1 -3
- package/src/node/backend-module.ts +8 -1
- package/lib/browser/ai-configuration/ai-configuration-preferences.d.ts.map +0 -1
- package/lib/browser/ai-configuration/ai-configuration-preferences.js.map +0 -1
- package/lib/browser/ai-ide-preferences.d.ts.map +0 -1
- package/lib/browser/ai-ide-preferences.js.map +0 -1
- package/lib/browser/workspace-preferences.d.ts.map +0 -1
- package/lib/browser/workspace-preferences.js.map +0 -1
|
@@ -56,9 +56,9 @@ After each tool call:
|
|
|
56
56
|
Never guess or hallucinate file content or structure. Use tools for all workspace interactions:
|
|
57
57
|
|
|
58
58
|
### Workspace Exploration
|
|
59
|
-
- ~{${workspace_functions_1.GET_WORKSPACE_DIRECTORY_STRUCTURE_FUNCTION_ID}} — view overall structure
|
|
60
59
|
- ~{${workspace_functions_1.GET_WORKSPACE_FILE_LIST_FUNCTION_ID}} — list contents of a specific directory
|
|
61
60
|
- ~{${workspace_functions_1.FILE_CONTENT_FUNCTION_ID}} — retrieve the content of a file
|
|
61
|
+
- ~{${workspace_functions_1.FIND_FILES_BY_PATTERN_FUNCTION_ID}} — find files matching glob patterns (e.g., '**/*.ts' for all TypeScript files)
|
|
62
62
|
- ~{${workspace_functions_1.SEARCH_IN_WORKSPACE_FUNCTION_ID}}} — locate references or patterns (only search if you are missing information, always prefer examples that are explicitly provided, never \
|
|
63
63
|
search for files you already know the path for)
|
|
64
64
|
- ~{${context_functions_1.UPDATE_CONTEXT_FILES_FUNCTION_ID}} — bookmark important files for context
|
|
@@ -151,12 +151,14 @@ which will be reviewed and accepted by the user.
|
|
|
151
151
|
|
|
152
152
|
## Context Retrieval
|
|
153
153
|
Use the following functions to interact with the workspace files if you require context:
|
|
154
|
-
- **~{${workspace_functions_1.GET_WORKSPACE_DIRECTORY_STRUCTURE_FUNCTION_ID}}**
|
|
155
154
|
- **~{${workspace_functions_1.GET_WORKSPACE_FILE_LIST_FUNCTION_ID}}**
|
|
156
155
|
- **~{${workspace_functions_1.FILE_CONTENT_FUNCTION_ID}}**
|
|
157
|
-
- **~{${workspace_functions_1.
|
|
158
|
-
|
|
156
|
+
- **~{${workspace_functions_1.FIND_FILES_BY_PATTERN_FUNCTION_ID}}** (find files by glob patterns like '**/*.ts')
|
|
157
|
+
- **~{${workspace_functions_1.SEARCH_IN_WORKSPACE_FUNCTION_ID}}**
|
|
159
158
|
|
|
159
|
+
If you cannot find good search terms, navigate the directory structure.
|
|
160
|
+
**Confirm Paths**: Always verify paths by listing directories or files as you navigate. Avoid assumptions based on user input alone.
|
|
161
|
+
**Navigate Step-by-Step**: Move into subdirectories only as needed, confirming each directory level.
|
|
160
162
|
Remember file locations that are relevant for completing your tasks using **~{${context_functions_1.UPDATE_CONTEXT_FILES_FUNCTION_ID}}**
|
|
161
163
|
Only add files that are really relevant to look at later.
|
|
162
164
|
|
|
@@ -221,12 +223,14 @@ which will be reviewed and accepted by the user.
|
|
|
221
223
|
|
|
222
224
|
## Context Retrieval
|
|
223
225
|
Use the following functions to interact with the workspace files if you require context:
|
|
224
|
-
- **~{${workspace_functions_1.GET_WORKSPACE_DIRECTORY_STRUCTURE_FUNCTION_ID}}**
|
|
225
226
|
- **~{${workspace_functions_1.GET_WORKSPACE_FILE_LIST_FUNCTION_ID}}**
|
|
226
227
|
- **~{${workspace_functions_1.FILE_CONTENT_FUNCTION_ID}}**
|
|
227
|
-
- **~{${workspace_functions_1.
|
|
228
|
-
|
|
228
|
+
- **~{${workspace_functions_1.FIND_FILES_BY_PATTERN_FUNCTION_ID}}** (find files by glob patterns like '**/*.ts')
|
|
229
|
+
- **~{${workspace_functions_1.SEARCH_IN_WORKSPACE_FUNCTION_ID}}**
|
|
229
230
|
|
|
231
|
+
If you cannot find good search terms, navigate the directory structure.
|
|
232
|
+
**Confirm Paths**: Always verify paths by listing directories or files as you navigate. Avoid assumptions based on user input alone.
|
|
233
|
+
**Navigate Step-by-Step**: Move into subdirectories only as needed, confirming each directory level.
|
|
230
234
|
Remember file locations that are relevant for completing your tasks using **~{${context_functions_1.UPDATE_CONTEXT_FILES_FUNCTION_ID}}**
|
|
231
235
|
Only add files that are really relevant to look at later.
|
|
232
236
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coder-replace-prompt-template.js","sourceRoot":"","sources":["../../src/common/coder-replace-prompt-template.ts"],"names":[],"mappings":";AAAA,qDAAqD;AACrD,gFAAgF;AAChF,oDAAoD;AACpD,EAAE;AACF,+CAA+C;AAC/C,mEAAmE;AACnE,sCAAsC;AACtC,EAAE;AACF,+BAA+B;AAC/B,gFAAgF;;;AAGhF,4CAAgE;AAChE,+DAQ+B;AAC/B,2DAAkG;AAClG,2DAAuE;AACvE,+EAOuC;AAE1B,QAAA,sBAAsB,GAAG,cAAc,CAAC;AAExC,QAAA,6BAA6B,GAAG,0BAA0B,CAAC;AAC3D,QAAA,sBAAsB,GAAG,mBAAmB,CAAC;AAC7C,QAAA,4BAA4B,GAAG,yBAAyB,CAAC;AAEtE,SAAgB,+BAA+B;IAC3C,OAAO;QACH,EAAE,EAAE,oCAA4B;QAChC,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAiCZ,
|
|
1
|
+
{"version":3,"file":"coder-replace-prompt-template.js","sourceRoot":"","sources":["../../src/common/coder-replace-prompt-template.ts"],"names":[],"mappings":";AAAA,qDAAqD;AACrD,gFAAgF;AAChF,oDAAoD;AACpD,EAAE;AACF,+CAA+C;AAC/C,mEAAmE;AACnE,sCAAsC;AACtC,EAAE;AACF,+BAA+B;AAC/B,gFAAgF;;;AAGhF,4CAAgE;AAChE,+DAQ+B;AAC/B,2DAAkG;AAClG,2DAAuE;AACvE,+EAOuC;AAE1B,QAAA,sBAAsB,GAAG,cAAc,CAAC;AAExC,QAAA,6BAA6B,GAAG,0BAA0B,CAAC;AAC3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;;;gFAKyC,oDAAgC;;;;;;;;;oCAS5E,qDAAuB;;QAEnD,0DAA4B;QAC5B,qDAAuB;WACpB,0DAA4B,8BAA8B,qDAAuB;QACpF,mDAAqB;;;;;;;;iFAQoD,8CAAwB;IACrG,6CAAyB;;;;IAIzB,wCAA8B;;;;IAI9B,oDAAgC;;;;;;;CAOnC;QACO,GAAG,CAAC,EAAE,SAAS,EAAE,8BAAsB,EAAE,CAAC;KAC7C,CAAC;AACN,CAAC;AA5DD,4EA4DC"}
|
|
@@ -9,7 +9,6 @@ export declare class OrchestratorChatAgent extends AbstractStreamParsingChatAgen
|
|
|
9
9
|
name: string;
|
|
10
10
|
languageModelRequirements: LanguageModelRequirement[];
|
|
11
11
|
protected defaultLanguageModelPurpose: string;
|
|
12
|
-
variables: string[];
|
|
13
12
|
prompts: import("@theia/ai-core").PromptVariantSet[];
|
|
14
13
|
description: string;
|
|
15
14
|
iconClass: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"orchestrator-chat-agent.d.ts","sourceRoot":"","sources":["../../src/common/orchestrator-chat-agent.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAoC,aAAa,EAAE,oBAAoB,EAAE,wBAAwB,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AAExJ,OAAO,EAAE,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAChF,OAAO,EAAE,eAAe,EAAE,MAAM,qDAAqD,CAAC;AACtF,OAAO,EAAE,8BAA8B,EAAE,MAAM,uCAAuC,CAAC;AACvF,OAAO,EAAE,uBAAuB,EAAwC,MAAM,sCAAsC,CAAC;AAIrH,eAAO,MAAM,uBAAuB,iBAAiB,CAAC;AAGtD,qBACa,qBAAsB,SAAQ,8BAA8B;IACrE,EAAE,EAAE,MAAM,CAA2B;IACrC,IAAI,SAA2B;IAC/B,yBAAyB,EAAE,wBAAwB,EAAE,CAGlD;IACH,SAAS,CAAC,2BAA2B,EAAE,MAAM,CAAqB;IAEzD,
|
|
1
|
+
{"version":3,"file":"orchestrator-chat-agent.d.ts","sourceRoot":"","sources":["../../src/common/orchestrator-chat-agent.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAoC,aAAa,EAAE,oBAAoB,EAAE,wBAAwB,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AAExJ,OAAO,EAAE,gBAAgB,EAAE,MAAM,8CAA8C,CAAC;AAChF,OAAO,EAAE,eAAe,EAAE,MAAM,qDAAqD,CAAC;AACtF,OAAO,EAAE,8BAA8B,EAAE,MAAM,uCAAuC,CAAC;AACvF,OAAO,EAAE,uBAAuB,EAAwC,MAAM,sCAAsC,CAAC;AAIrH,eAAO,MAAM,uBAAuB,iBAAiB,CAAC;AAGtD,qBACa,qBAAsB,SAAQ,8BAA8B;IACrE,EAAE,EAAE,MAAM,CAA2B;IACrC,IAAI,SAA2B;IAC/B,yBAAyB,EAAE,wBAAwB,EAAE,CAGlD;IACH,SAAS,CAAC,2BAA2B,EAAE,MAAM,CAAqB;IAEzD,OAAO,8CAA0B;IACjC,WAAW,SAE+F;IAC1G,SAAS,EAAE,MAAM,CAAoC;IAE9D,UAAmB,cAAc,EAAE,MAAM,CAA2B;IAEpE,OAAO,CAAC,mBAAmB,CAAe;IAG1C,SAAS,CAAC,gBAAgB,EAAE,gBAAgB,CAAC;IAE9B,MAAM,CAAC,OAAO,EAAE,uBAAuB,GAAG,OAAO,CAAC,IAAI,CAAC;cAS7C,cAAc,CACnC,OAAO,EAAE,uBAAuB,EAChC,QAAQ,EAAE,oBAAoB,EAAE,EAChC,YAAY,EAAE,eAAe,EAAE,EAC/B,aAAa,EAAE,aAAa,GAC7B,OAAO,CAAC,qBAAqB,CAAC;cAqBR,qBAAqB,CAAC,QAAQ,EAAE,qBAAqB,EAAE,OAAO,EAAE,uBAAuB,GAAG,OAAO,CAAC,IAAI,CAAC;CAwDnI"}
|
|
@@ -36,7 +36,6 @@ let OrchestratorChatAgent = class OrchestratorChatAgent extends chat_agents_1.Ab
|
|
|
36
36
|
identifier: 'default/universal',
|
|
37
37
|
}];
|
|
38
38
|
this.defaultLanguageModelPurpose = 'agent-selection';
|
|
39
|
-
this.variables = ['chatAgents'];
|
|
40
39
|
this.prompts = [orchestrator_prompt_template_1.orchestratorTemplate];
|
|
41
40
|
this.description = core_1.nls.localize('theia/ai/chat/orchestrator/description', 'This agent analyzes the user request against the description of all available chat agents and selects the best fitting agent to answer the request \
|
|
42
41
|
(by using AI).The user\'s request will be directly delegated to the selected agent without further confirmation.');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"orchestrator-chat-agent.js","sourceRoot":"","sources":["../../src/common/orchestrator-chat-agent.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,4CAAwJ;AACxJ,4DAAkE;AAClE,qFAAgF;AAEhF,uEAAuF;AACvF,qEAAqH;AACrH,sCAAgD;AAChD,iFAAsE;AAEzD,QAAA,uBAAuB,GAAG,cAAc,CAAC;AACtD,MAAM,wBAAwB,GAAG,0BAA0B,CAAC;AAGrD,IAAM,qBAAqB,GAA3B,MAAM,qBAAsB,SAAQ,4CAA8B;IAAlE;;QACH,OAAE,GAAW,+BAAuB,CAAC;QACrC,SAAI,GAAG,+BAAuB,CAAC;QAC/B,8BAAyB,GAA+B,CAAC;gBACrD,OAAO,EAAE,iBAAiB;gBAC1B,UAAU,EAAE,mBAAmB;aAClC,CAAC,CAAC;QACO,gCAA2B,GAAW,iBAAiB,CAAC;QAEzD,
|
|
1
|
+
{"version":3,"file":"orchestrator-chat-agent.js","sourceRoot":"","sources":["../../src/common/orchestrator-chat-agent.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,y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QACrC,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAC,UAAU,CAAC,IAAI,iDAAoC,CACzE,oCAAoC,gBAAgB;;;;aAInD,CACJ,CAAC,CAAC;QACH,OAAO,CAAC,QAAQ,CAAC,eAAe,CAAC,gBAAgB,CAAC,CAAC;QACnD,OAAO,CAAC,QAAQ,CAAC,gBAAgB,CAAC,OAAO,CAAC,eAAe,CAAC,EAAE,CACxD,OAAO,CAAC,QAAQ,CAAC,qBAAqB,CAAC,EAAE,GAAG,eAAe,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC,CACtF,CAAC;QACF,MAAM,KAAK,GAAG,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,gBAAgB,CAAC,CAAC;QAC/D,IAAI,CAAC,KAAK,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CAAC,cAAc,gBAAgB,aAAa,CAAC,CAAC;QACjE,CAAC;QAED,wCAAwC;QACxC,MAAM,eAAe,GAAG,mBAAmB,IAAI,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,iBAA4C,CAAC,CAAC,CAAC,OAAO,CAAC;QACxH,MAAM,KAAK,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC;IACxC,CAAC;CACJ,CAAA;AAjHY,sDAAqB;AAoBpB;IADT,IAAA,kBAAM,EAAC,qCAAgB,CAAC;;+DACoB;gCApBpC,qBAAqB;IADjC,IAAA,sBAAU,GAAE;GACA,qBAAqB,CAiHjC"}
|
|
@@ -3,6 +3,7 @@ export declare const GET_WORKSPACE_FILE_LIST_FUNCTION_ID = "getWorkspaceFileList
|
|
|
3
3
|
export declare const GET_WORKSPACE_DIRECTORY_STRUCTURE_FUNCTION_ID = "getWorkspaceDirectoryStructure";
|
|
4
4
|
export declare const GET_FILE_DIAGNOSTICS_ID = "getFileDiagnostics";
|
|
5
5
|
export declare const SEARCH_IN_WORKSPACE_FUNCTION_ID = "searchInWorkspace";
|
|
6
|
+
export declare const FIND_FILES_BY_PATTERN_FUNCTION_ID = "findFilesByPattern";
|
|
6
7
|
export declare const LIST_TASKS_FUNCTION_ID = "listTasks";
|
|
7
8
|
export declare const RUN_TASK_FUNCTION_ID = "runTask";
|
|
8
9
|
export declare const LIST_LAUNCH_CONFIGURATIONS_FUNCTION_ID = "listLaunchConfigurations";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workspace-functions.d.ts","sourceRoot":"","sources":["../../src/common/workspace-functions.ts"],"names":[],"mappings":"AAeA,eAAO,MAAM,wBAAwB,mBAAmB,CAAC;AACzD,eAAO,MAAM,mCAAmC,yBAAyB,CAAC;AAC1E,eAAO,MAAM,6CAA6C,mCAAmC,CAAC;AAC9F,eAAO,MAAM,uBAAuB,uBAAuB,CAAC;AAC5D,eAAO,MAAM,+BAA+B,sBAAsB,CAAC;AACnE,eAAO,MAAM,sBAAsB,cAAc,CAAC;AAClD,eAAO,MAAM,oBAAoB,YAAY,CAAC;AAC9C,eAAO,MAAM,sCAAsC,6BAA6B,CAAC;AACjF,eAAO,MAAM,oCAAoC,2BAA2B,CAAC;AAC7E,eAAO,MAAM,qCAAqC,4BAA4B,CAAC"}
|
|
1
|
+
{"version":3,"file":"workspace-functions.d.ts","sourceRoot":"","sources":["../../src/common/workspace-functions.ts"],"names":[],"mappings":"AAeA,eAAO,MAAM,wBAAwB,mBAAmB,CAAC;AACzD,eAAO,MAAM,mCAAmC,yBAAyB,CAAC;AAC1E,eAAO,MAAM,6CAA6C,mCAAmC,CAAC;AAC9F,eAAO,MAAM,uBAAuB,uBAAuB,CAAC;AAC5D,eAAO,MAAM,+BAA+B,sBAAsB,CAAC;AACnE,eAAO,MAAM,iCAAiC,uBAAuB,CAAC;AACtE,eAAO,MAAM,sBAAsB,cAAc,CAAC;AAClD,eAAO,MAAM,oBAAoB,YAAY,CAAC;AAC9C,eAAO,MAAM,sCAAsC,6BAA6B,CAAC;AACjF,eAAO,MAAM,oCAAoC,2BAA2B,CAAC;AAC7E,eAAO,MAAM,qCAAqC,4BAA4B,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.STOP_LAUNCH_CONFIGURATION_FUNCTION_ID = exports.RUN_LAUNCH_CONFIGURATION_FUNCTION_ID = exports.LIST_LAUNCH_CONFIGURATIONS_FUNCTION_ID = exports.RUN_TASK_FUNCTION_ID = exports.LIST_TASKS_FUNCTION_ID = exports.SEARCH_IN_WORKSPACE_FUNCTION_ID = exports.GET_FILE_DIAGNOSTICS_ID = exports.GET_WORKSPACE_DIRECTORY_STRUCTURE_FUNCTION_ID = exports.GET_WORKSPACE_FILE_LIST_FUNCTION_ID = exports.FILE_CONTENT_FUNCTION_ID = void 0;
|
|
3
|
+
exports.STOP_LAUNCH_CONFIGURATION_FUNCTION_ID = exports.RUN_LAUNCH_CONFIGURATION_FUNCTION_ID = exports.LIST_LAUNCH_CONFIGURATIONS_FUNCTION_ID = exports.RUN_TASK_FUNCTION_ID = exports.LIST_TASKS_FUNCTION_ID = exports.FIND_FILES_BY_PATTERN_FUNCTION_ID = exports.SEARCH_IN_WORKSPACE_FUNCTION_ID = exports.GET_FILE_DIAGNOSTICS_ID = exports.GET_WORKSPACE_DIRECTORY_STRUCTURE_FUNCTION_ID = exports.GET_WORKSPACE_FILE_LIST_FUNCTION_ID = exports.FILE_CONTENT_FUNCTION_ID = void 0;
|
|
4
4
|
// *****************************************************************************
|
|
5
5
|
// Copyright (C) 2024 EclipseSource GmbH.
|
|
6
6
|
//
|
|
@@ -21,6 +21,7 @@ exports.GET_WORKSPACE_FILE_LIST_FUNCTION_ID = 'getWorkspaceFileList';
|
|
|
21
21
|
exports.GET_WORKSPACE_DIRECTORY_STRUCTURE_FUNCTION_ID = 'getWorkspaceDirectoryStructure';
|
|
22
22
|
exports.GET_FILE_DIAGNOSTICS_ID = 'getFileDiagnostics';
|
|
23
23
|
exports.SEARCH_IN_WORKSPACE_FUNCTION_ID = 'searchInWorkspace';
|
|
24
|
+
exports.FIND_FILES_BY_PATTERN_FUNCTION_ID = 'findFilesByPattern';
|
|
24
25
|
exports.LIST_TASKS_FUNCTION_ID = 'listTasks';
|
|
25
26
|
exports.RUN_TASK_FUNCTION_ID = 'runTask';
|
|
26
27
|
exports.LIST_LAUNCH_CONFIGURATIONS_FUNCTION_ID = 'listLaunchConfigurations';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workspace-functions.js","sourceRoot":"","sources":["../../src/common/workspace-functions.ts"],"names":[],"mappings":";;;AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;AACnE,QAAA,wBAAwB,GAAG,gBAAgB,CAAC;AAC5C,QAAA,mCAAmC,GAAG,sBAAsB,CAAC;AAC7D,QAAA,6CAA6C,GAAG,gCAAgC,CAAC;AACjF,QAAA,uBAAuB,GAAG,oBAAoB,CAAC;AAC/C,QAAA,+BAA+B,GAAG,mBAAmB,CAAC;AACtD,QAAA,sBAAsB,GAAG,WAAW,CAAC;AACrC,QAAA,oBAAoB,GAAG,SAAS,CAAC;AACjC,QAAA,sCAAsC,GAAG,0BAA0B,CAAC;AACpE,QAAA,oCAAoC,GAAG,wBAAwB,CAAC;AAChE,QAAA,qCAAqC,GAAG,yBAAyB,CAAC"}
|
|
1
|
+
{"version":3,"file":"workspace-functions.js","sourceRoot":"","sources":["../../src/common/workspace-functions.ts"],"names":[],"mappings":";;;AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;AACnE,QAAA,wBAAwB,GAAG,gBAAgB,CAAC;AAC5C,QAAA,mCAAmC,GAAG,sBAAsB,CAAC;AAC7D,QAAA,6CAA6C,GAAG,gCAAgC,CAAC;AACjF,QAAA,uBAAuB,GAAG,oBAAoB,CAAC;AAC/C,QAAA,+BAA+B,GAAG,mBAAmB,CAAC;AACtD,QAAA,iCAAiC,GAAG,oBAAoB,CAAC;AACzD,QAAA,sBAAsB,GAAG,WAAW,CAAC;AACrC,QAAA,oBAAoB,GAAG,SAAS,CAAC;AACjC,QAAA,sCAAsC,GAAG,0BAA0B,CAAC;AACpE,QAAA,oCAAoC,GAAG,wBAAwB,CAAC;AAChE,QAAA,qCAAqC,GAAG,yBAAyB,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PreferenceSchema } from '@theia/core
|
|
1
|
+
import { PreferenceSchema } from '@theia/core';
|
|
2
2
|
export declare const CONSIDER_GITIGNORE_PREF = "ai-features.workspaceFunctions.considerGitIgnore";
|
|
3
3
|
export declare const USER_EXCLUDE_PATTERN_PREF = "ai-features.workspaceFunctions.userExcludes";
|
|
4
4
|
export declare const SEARCH_IN_WORKSPACE_MAX_RESULTS_PREF = "ai-features.workspaceFunctions.searchMaxResults";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"workspace-preferences.d.ts","sourceRoot":"","sources":["../../src/common/workspace-preferences.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAO,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAEpD,eAAO,MAAM,uBAAuB,qDAAqD,CAAC;AAC1F,eAAO,MAAM,yBAAyB,gDAAgD,CAAC;AACvF,eAAO,MAAM,oCAAoC,oDAAoD,CAAC;AACtG,eAAO,MAAM,0CAA0C,6DAA6D,CAAC;AACrH,eAAO,MAAM,0CAA0C,mDAAmD,CAAC;AAC3G,eAAO,MAAM,oCAAoC,uDAAuD,CAAC;AACzG,eAAO,MAAM,mCAAmC,4DAA4D,CAAC;AAK7G,eAAO,MAAM,0BAA0B,EAAE,gBAkExC,CAAC"}
|
|
@@ -27,7 +27,6 @@ exports.TASK_CONTEXT_STORAGE_DIRECTORY_PREF = 'ai-features.promptTemplates.taskC
|
|
|
27
27
|
const CONFLICT_RESOLUTION_DESCRIPTION = 'When templates with the same ID (filename) exist in multiple locations, conflicts are resolved by priority: specific template files \
|
|
28
28
|
(highest) > workspace directories > global directories (lowest).';
|
|
29
29
|
exports.WorkspacePreferencesSchema = {
|
|
30
|
-
type: 'object',
|
|
31
30
|
properties: {
|
|
32
31
|
[exports.CONSIDER_GITIGNORE_PREF]: {
|
|
33
32
|
type: 'boolean',
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"workspace-preferences.js","sourceRoot":"","sources":["../../src/common/workspace-preferences.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;AAEhF,sCAAoD;AAEvC,QAAA,uBAAuB,GAAG,kDAAkD,CAAC;AAC7E,QAAA,yBAAyB,GAAG,6CAA6C,CAAC;AAC1E,QAAA,oCAAoC,GAAG,iDAAiD,CAAC;AACzF,QAAA,0CAA0C,GAAG,0DAA0D,CAAC;AACxG,QAAA,0CAA0C,GAAG,gDAAgD,CAAC;AAC9F,QAAA,oCAAoC,GAAG,oDAAoD,CAAC;AAC5F,QAAA,mCAAmC,GAAG,yDAAyD,CAAC;AAE7G,MAAM,+BAA+B,GAAG;iEACyB,CAAC;AAErD,QAAA,0BAA0B,GAAqB;IACxD,UAAU,EAAE;QACR,CAAC,+BAAuB,CAAC,EAAE;YACvB,IAAI,EAAE,SAAS;YACf,KAAK,EAAE,UAAG,CA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J,KAAK,EAAE;gBACH,IAAI,EAAE,QAAQ;aACjB;SACJ;QACD,CAAC,4CAAoC,CAAC,EAAE;YACpC,IAAI,EAAE,OAAO;YACb,KAAK,EAAE,UAAG,CAAC,QAAQ,CAAC,sCAAsC,EAAE,0CAA0C,CAAC;YACvG,WAAW,EAAE,UAAG,CAAC,QAAQ,CAAC,4CAA4C,EAClE,oGAAoG;gBACpG,+BAA+B,CAAC;YACpC,OAAO,EAAE,EAAE;YACX,KAAK,EAAE;gBACH,IAAI,EAAE,QAAQ;aACjB;SACJ;QACD,CAAC,2CAAmC,CAAC,EAAE;YACnC,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,UAAG,CAAC,QAAQ,CAAC,uDAAuD,EAC7E,qGAAqG;gBACrG,+FAA+F,CAClG;YACD,OAAO,EAAE,wBAAwB;SACpC;KACJ;CACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"backend-module.d.ts","sourceRoot":"","sources":["../../src/node/backend-module.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;;
|
|
1
|
+
{"version":3,"file":"backend-module.d.ts","sourceRoot":"","sources":["../../src/node/backend-module.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;;AAoB/D,wBAOG"}
|
|
@@ -20,6 +20,9 @@ const inversify_1 = require("@theia/core/shared/inversify");
|
|
|
20
20
|
const browser_automation_protocol_1 = require("../common/browser-automation-protocol");
|
|
21
21
|
const browser_automation_impl_1 = require("./app-tester-agent/browser-automation-impl");
|
|
22
22
|
const connection_container_module_1 = require("@theia/core/lib/node/messaging/connection-container-module");
|
|
23
|
+
const workspace_preferences_1 = require("../common/workspace-preferences");
|
|
24
|
+
const ai_configuration_preferences_1 = require("../common/ai-configuration-preferences");
|
|
25
|
+
const ai_ide_preferences_1 = require("../common/ai-ide-preferences");
|
|
23
26
|
const browserAutomationModule = connection_container_module_1.ConnectionContainerModule.create(({ bind, bindBackendService, bindFrontendService }) => {
|
|
24
27
|
bind(browser_automation_protocol_1.BrowserAutomation).to(browser_automation_impl_1.BrowserAutomationImpl).inSingletonScope();
|
|
25
28
|
bind(core_1.ConnectionHandler).toDynamicValue(ctx => new core_1.RpcConnectionHandler(browser_automation_protocol_1.browserAutomationPath, client => {
|
|
@@ -30,6 +33,9 @@ const browserAutomationModule = connection_container_module_1.ConnectionContaine
|
|
|
30
33
|
})).inSingletonScope();
|
|
31
34
|
});
|
|
32
35
|
exports.default = new inversify_1.ContainerModule(bind => {
|
|
36
|
+
bind(core_1.PreferenceContribution).toConstantValue({ schema: ai_ide_preferences_1.aiIdePreferenceSchema });
|
|
37
|
+
bind(core_1.PreferenceContribution).toConstantValue({ schema: workspace_preferences_1.WorkspacePreferencesSchema });
|
|
38
|
+
bind(core_1.PreferenceContribution).toConstantValue({ schema: ai_configuration_preferences_1.AiConfigurationPreferences });
|
|
33
39
|
bind(connection_container_module_1.ConnectionContainerModule).toConstantValue(browserAutomationModule);
|
|
34
40
|
});
|
|
35
41
|
//# sourceMappingURL=backend-module.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"backend-module.js","sourceRoot":"","sources":["../../src/node/backend-module.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;AAEhF,
|
|
1
|
+
{"version":3,"file":"backend-module.js","sourceRoot":"","sources":["../../src/node/backend-module.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8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,CAAC,eAAe,CAAC,uBAAuB,CAAC,CAAC;AAE7E,CAAC,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theia/ai-ide",
|
|
3
|
-
"version": "1.65.
|
|
3
|
+
"version": "1.65.1",
|
|
4
4
|
"description": "AI IDE Agents Extension",
|
|
5
5
|
"license": "EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -15,32 +15,32 @@
|
|
|
15
15
|
"theia-extension"
|
|
16
16
|
],
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@theia/ai-chat": "1.65.
|
|
19
|
-
"@theia/ai-chat-ui": "1.65.
|
|
20
|
-
"@theia/ai-core": "1.65.
|
|
21
|
-
"@theia/ai-mcp": "1.65.
|
|
22
|
-
"@theia/core": "1.65.
|
|
23
|
-
"@theia/debug": "1.65.
|
|
24
|
-
"@theia/filesystem": "1.65.
|
|
25
|
-
"@theia/markers": "1.65.
|
|
26
|
-
"@theia/monaco": "1.65.
|
|
27
|
-
"@theia/navigator": "1.65.
|
|
28
|
-
"@theia/search-in-workspace": "1.65.
|
|
29
|
-
"@theia/task": "1.65.
|
|
30
|
-
"@theia/terminal": "1.65.
|
|
31
|
-
"@theia/workspace": "1.65.
|
|
18
|
+
"@theia/ai-chat": "1.65.1",
|
|
19
|
+
"@theia/ai-chat-ui": "1.65.1",
|
|
20
|
+
"@theia/ai-core": "1.65.1",
|
|
21
|
+
"@theia/ai-mcp": "1.65.1",
|
|
22
|
+
"@theia/core": "1.65.1",
|
|
23
|
+
"@theia/debug": "1.65.1",
|
|
24
|
+
"@theia/filesystem": "1.65.1",
|
|
25
|
+
"@theia/markers": "1.65.1",
|
|
26
|
+
"@theia/monaco": "1.65.1",
|
|
27
|
+
"@theia/navigator": "1.65.1",
|
|
28
|
+
"@theia/search-in-workspace": "1.65.1",
|
|
29
|
+
"@theia/task": "1.65.1",
|
|
30
|
+
"@theia/terminal": "1.65.1",
|
|
31
|
+
"@theia/workspace": "1.65.1",
|
|
32
32
|
"date-fns": "^4.1.0",
|
|
33
33
|
"ignore": "^6.0.0",
|
|
34
34
|
"js-yaml": "^4.1.0",
|
|
35
|
-
"minimatch": "^
|
|
35
|
+
"minimatch": "^10.0.3",
|
|
36
36
|
"puppeteer-core": "^24.10.0"
|
|
37
37
|
},
|
|
38
38
|
"publishConfig": {
|
|
39
39
|
"access": "public"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@theia/cli": "1.65.
|
|
43
|
-
"@theia/test": "1.65.
|
|
42
|
+
"@theia/cli": "1.65.1",
|
|
43
|
+
"@theia/test": "1.65.1"
|
|
44
44
|
},
|
|
45
45
|
"theiaExtensions": [
|
|
46
46
|
{
|
|
@@ -64,5 +64,5 @@
|
|
|
64
64
|
"nyc": {
|
|
65
65
|
"extends": "../../configs/nyc.json"
|
|
66
66
|
},
|
|
67
|
-
"gitHead": "
|
|
67
|
+
"gitHead": "ed70d58fe5ef87606f903ea92fcb684e83f5354f"
|
|
68
68
|
}
|
|
@@ -19,7 +19,6 @@ import {
|
|
|
19
19
|
AgentService,
|
|
20
20
|
AISettingsService,
|
|
21
21
|
AIVariableService,
|
|
22
|
-
BasePromptFragment,
|
|
23
22
|
FrontendLanguageModelRegistry,
|
|
24
23
|
LanguageModel,
|
|
25
24
|
LanguageModelRegistry,
|
|
@@ -80,6 +79,8 @@ export class AIAgentConfigurationWidget extends ReactWidget {
|
|
|
80
79
|
|
|
81
80
|
protected languageModels: LanguageModel[] | undefined;
|
|
82
81
|
protected languageModelAliases: LanguageModelAlias[] = [];
|
|
82
|
+
protected parsedPromptParts: ParsedPrompt | undefined;
|
|
83
|
+
protected isLoadingDetails = false;
|
|
83
84
|
|
|
84
85
|
@postConstruct()
|
|
85
86
|
protected init(): void {
|
|
@@ -103,11 +104,36 @@ export class AIAgentConfigurationWidget extends ReactWidget {
|
|
|
103
104
|
this.languageModels = models;
|
|
104
105
|
this.update();
|
|
105
106
|
}));
|
|
106
|
-
this.toDispose.push(this.promptService.onPromptsChange(() => this.
|
|
107
|
+
this.toDispose.push(this.promptService.onPromptsChange(() => this.updateParsedPromptParts()));
|
|
108
|
+
|
|
109
|
+
// Only call updateParsedPromptParts() as it already calls this.update() internally
|
|
110
|
+
this.toDispose.push(this.promptFragmentCustomizationService.onDidChangePromptFragmentCustomization(() => {
|
|
111
|
+
this.updateParsedPromptParts();
|
|
112
|
+
}));
|
|
113
|
+
|
|
114
|
+
// Only call updateParsedPromptParts() as it already calls this.update() internally
|
|
115
|
+
this.toDispose.push(this.aiSettingsService.onDidChange(() => {
|
|
116
|
+
this.updateParsedPromptParts();
|
|
117
|
+
}));
|
|
118
|
+
|
|
119
|
+
// Only call updateParsedPromptParts() as it already calls this.update() internally
|
|
120
|
+
this.toDispose.push(this.aiConfigurationSelectionService.onDidAgentChange(() => {
|
|
121
|
+
this.updateParsedPromptParts();
|
|
122
|
+
}));
|
|
107
123
|
|
|
108
|
-
this.aiSettingsService.onDidChange(() => this.update());
|
|
109
|
-
this.aiConfigurationSelectionService.onDidAgentChange(() => this.update());
|
|
110
124
|
this.agentService.onDidChangeAgents(() => this.update());
|
|
125
|
+
this.updateParsedPromptParts();
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
protected async updateParsedPromptParts(): Promise<void> {
|
|
129
|
+
this.isLoadingDetails = true;
|
|
130
|
+
const agent = this.aiConfigurationSelectionService.getActiveAgent();
|
|
131
|
+
if (agent) {
|
|
132
|
+
this.parsedPromptParts = await this.parsePromptFragmentsForVariableAndFunction(agent);
|
|
133
|
+
} else {
|
|
134
|
+
this.parsedPromptParts = undefined;
|
|
135
|
+
}
|
|
136
|
+
this.isLoadingDetails = false;
|
|
111
137
|
this.update();
|
|
112
138
|
}
|
|
113
139
|
|
|
@@ -138,12 +164,16 @@ export class AIAgentConfigurationWidget extends ReactWidget {
|
|
|
138
164
|
</div>;
|
|
139
165
|
}
|
|
140
166
|
|
|
141
|
-
|
|
167
|
+
protected renderAgentName(agent: Agent): React.ReactNode {
|
|
142
168
|
const tagsSuffix = agent.tags?.length ? <span>{agent.tags.map(tag => <span key={tag} className='agent-tag'>{tag}</span>)}</span> : '';
|
|
143
169
|
return <span>{agent.name} {tagsSuffix}</span>;
|
|
144
170
|
}
|
|
145
171
|
|
|
146
|
-
|
|
172
|
+
protected renderAgentDetails(): React.ReactNode {
|
|
173
|
+
if (this.isLoadingDetails) {
|
|
174
|
+
return <div>{nls.localize('theia/ai/core/agentConfiguration/loading', 'Loading...')}</div>;
|
|
175
|
+
}
|
|
176
|
+
|
|
147
177
|
const agent = this.aiConfigurationSelectionService.getActiveAgent();
|
|
148
178
|
if (!agent) {
|
|
149
179
|
return <div>{nls.localize('theia/ai/core/agentConfiguration/selectAgentMessage', 'Please select an Agent first!')}</div>;
|
|
@@ -151,9 +181,13 @@ export class AIAgentConfigurationWidget extends ReactWidget {
|
|
|
151
181
|
|
|
152
182
|
const enabled = this.agentService.isEnabled(agent.id);
|
|
153
183
|
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
184
|
+
if (!this.parsedPromptParts) {
|
|
185
|
+
this.updateParsedPromptParts();
|
|
186
|
+
return <div>{nls.localize('theia/ai/core/agentConfiguration/loading', 'Loading...')}</div>;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
const globalVariables = Array.from(new Set([...this.parsedPromptParts.globalVariables, ...agent.variables]));
|
|
190
|
+
const functions = Array.from(new Set([...this.parsedPromptParts.functions, ...agent.functions]));
|
|
157
191
|
|
|
158
192
|
return <div key={agent.id} style={{ display: 'flex', flexDirection: 'column', alignItems: 'flex-start' }}>
|
|
159
193
|
<div className='settings-section-title settings-section-category-title' style={{ paddingLeft: 0, paddingBottom: 10 }}>
|
|
@@ -211,7 +245,7 @@ export class AIAgentConfigurationWidget extends ReactWidget {
|
|
|
211
245
|
<span>Used agent-specific Variables:</span>
|
|
212
246
|
<ul className='variable-references'>
|
|
213
247
|
<AgentSpecificVariables
|
|
214
|
-
promptVariables={parsedPromptParts.agentSpecificVariables}
|
|
248
|
+
promptVariables={this.parsedPromptParts.agentSpecificVariables}
|
|
215
249
|
agent={agent}
|
|
216
250
|
/>
|
|
217
251
|
</ul>
|
|
@@ -225,40 +259,50 @@ export class AIAgentConfigurationWidget extends ReactWidget {
|
|
|
225
259
|
</div>;
|
|
226
260
|
}
|
|
227
261
|
|
|
228
|
-
|
|
229
|
-
const
|
|
230
|
-
const
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
262
|
+
protected async parsePromptFragmentsForVariableAndFunction(agent: Agent): Promise<ParsedPrompt> {
|
|
263
|
+
const result: ParsedPrompt = { functions: [], globalVariables: [], agentSpecificVariables: [] };
|
|
264
|
+
const agentSettings = await this.aiSettingsService.getAgentSettings(agent.id);
|
|
265
|
+
const selectedVariants = agentSettings?.selectedVariants ?? {};
|
|
266
|
+
|
|
267
|
+
for (const mainTemplate of agent.prompts) {
|
|
268
|
+
const promptId = selectedVariants[mainTemplate.id] ?? mainTemplate.defaultVariant.id ?? mainTemplate.id;
|
|
269
|
+
const promptToAnalyze: string | undefined = this.promptService.getRawPromptFragment(promptId)?.template;
|
|
270
|
+
|
|
271
|
+
if (!promptToAnalyze) {
|
|
272
|
+
continue;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
this.extractVariablesAndFunctions(promptToAnalyze, result, agent);
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
return result;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
protected extractVariablesAndFunctions(promptContent: string, result: ParsedPrompt, agent: Agent): void {
|
|
282
|
+
const variableMatches = matchVariablesRegEx(promptContent);
|
|
283
|
+
variableMatches.forEach(match => {
|
|
284
|
+
const variableId = match[1];
|
|
285
|
+
// skip comments
|
|
286
|
+
if (variableId.startsWith('!--')) {
|
|
287
|
+
return;
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
// Extract base variable ID without arguments
|
|
291
|
+
const baseVariableId = variableId.split(':')[0];
|
|
292
|
+
|
|
293
|
+
if (this.variableService.hasVariable(baseVariableId) &&
|
|
294
|
+
agent.agentSpecificVariables.find(v => v.name === baseVariableId) === undefined) {
|
|
295
|
+
result.globalVariables.push(variableId);
|
|
296
|
+
} else {
|
|
297
|
+
result.agentSpecificVariables.push(variableId);
|
|
235
298
|
}
|
|
236
299
|
});
|
|
237
|
-
const result: ParsedPrompt = { functions: [], globalVariables: [], agentSpecificVariables: [] };
|
|
238
|
-
promptFragments.forEach(template => {
|
|
239
|
-
const storedPrompt = this.promptService.getPromptFragment(template.id);
|
|
240
|
-
const prompt = storedPrompt?.template ?? template.template;
|
|
241
|
-
const variableMatches = matchVariablesRegEx(prompt);
|
|
242
|
-
|
|
243
|
-
variableMatches.forEach(match => {
|
|
244
|
-
const variableId = match[1];
|
|
245
|
-
// if the variable is part of the variable service and not part of the agent specific variables then it is a global variable
|
|
246
|
-
if (this.variableService.hasVariable(variableId) &&
|
|
247
|
-
agent.agentSpecificVariables.find(v => v.name === variableId) === undefined) {
|
|
248
|
-
result.globalVariables.push(variableId);
|
|
249
|
-
} else {
|
|
250
|
-
result.agentSpecificVariables.push(variableId);
|
|
251
|
-
}
|
|
252
|
-
});
|
|
253
|
-
|
|
254
|
-
const functionMatches = [...prompt.matchAll(PROMPT_FUNCTION_REGEX)];
|
|
255
|
-
functionMatches.forEach(match => {
|
|
256
|
-
const functionId = match[1];
|
|
257
|
-
result.functions.push(functionId);
|
|
258
|
-
});
|
|
259
300
|
|
|
301
|
+
const functionMatches = [...promptContent.matchAll(PROMPT_FUNCTION_REGEX)];
|
|
302
|
+
functionMatches.forEach(match => {
|
|
303
|
+
const functionId = match[1];
|
|
304
|
+
result.functions.push(functionId);
|
|
260
305
|
});
|
|
261
|
-
return result;
|
|
262
306
|
}
|
|
263
307
|
|
|
264
308
|
protected showVariableConfigurationTab(): void {
|
|
@@ -298,7 +342,7 @@ export class AIAgentConfigurationWidget extends ReactWidget {
|
|
|
298
342
|
|
|
299
343
|
protected setActiveAgent(agent: Agent): void {
|
|
300
344
|
this.aiConfigurationSelectionService.setActiveAgent(agent);
|
|
301
|
-
this.
|
|
345
|
+
this.updateParsedPromptParts();
|
|
302
346
|
}
|
|
303
347
|
|
|
304
348
|
private toggleAgentEnabled = () => {
|
|
@@ -314,8 +358,8 @@ export class AIAgentConfigurationWidget extends ReactWidget {
|
|
|
314
358
|
}
|
|
315
359
|
this.update();
|
|
316
360
|
};
|
|
317
|
-
|
|
318
361
|
}
|
|
362
|
+
|
|
319
363
|
interface AgentGlobalVariablesProps {
|
|
320
364
|
variables: string[];
|
|
321
365
|
showVariableConfigurationTab: () => void;
|
|
@@ -330,7 +374,6 @@ const AgentGlobalVariables = ({ variables: globalVariables, showVariableConfigur
|
|
|
330
374
|
<span>{variableId}</span>
|
|
331
375
|
<i className={codicon('chevron-right')}></i>
|
|
332
376
|
</div></li>)}
|
|
333
|
-
|
|
334
377
|
</>;
|
|
335
378
|
};
|
|
336
379
|
|
|
@@ -365,7 +408,6 @@ const AgentSpecificVariables = ({ promptVariables, agent }: AgentSpecificVariabl
|
|
|
365
408
|
variableId={variableId}
|
|
366
409
|
agent={agent}
|
|
367
410
|
promptVariables={promptVariables} />
|
|
368
|
-
|
|
369
411
|
)}
|
|
370
412
|
</>;
|
|
371
413
|
};
|
|
@@ -128,10 +128,7 @@ export class AIPromptFragmentsConfigurationWidget extends ReactWidget {
|
|
|
128
128
|
const existingExpandedPromptVariantIds = new Set(this.expandedPromptVariantSetIds);
|
|
129
129
|
const existingExpandedTemplates = new Set(this.expandedPromptFragmentTemplates);
|
|
130
130
|
|
|
131
|
-
|
|
132
|
-
if (existingExpandedFragmentIds.size === 0) {
|
|
133
|
-
this.expandedPromptFragmentIds = new Set(Array.from(this.promptFragmentMap.keys()));
|
|
134
|
-
} else {
|
|
131
|
+
if (existingExpandedFragmentIds.size > 0) {
|
|
135
132
|
// Keep existing expansion state but remove entries for fragments that no longer exist
|
|
136
133
|
this.expandedPromptFragmentIds = new Set(
|
|
137
134
|
Array.from(existingExpandedFragmentIds).filter(id => this.promptFragmentMap.has(id))
|
|
@@ -139,7 +136,8 @@ export class AIPromptFragmentsConfigurationWidget extends ReactWidget {
|
|
|
139
136
|
}
|
|
140
137
|
|
|
141
138
|
if (existingExpandedPromptVariantIds.size === 0) {
|
|
142
|
-
|
|
139
|
+
// Start with variant sets collapsed by default
|
|
140
|
+
this.expandedPromptVariantSetIds = new Set();
|
|
143
141
|
} else {
|
|
144
142
|
// Keep existing expansion state but remove entries for prompt variant sets that no longer exist
|
|
145
143
|
this.expandedPromptVariantSetIds = new Set(
|
|
@@ -14,11 +14,13 @@
|
|
|
14
14
|
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
15
|
// *****************************************************************************
|
|
16
16
|
|
|
17
|
-
import {
|
|
17
|
+
import { ReactWidget, ConfirmDialog } from '@theia/core/lib/browser';
|
|
18
18
|
import { inject, injectable, postConstruct } from '@theia/core/shared/inversify';
|
|
19
19
|
import * as React from '@theia/core/shared/react';
|
|
20
|
-
import { ToolConfirmationManager, ToolConfirmationMode } from '@theia/ai-chat/lib/browser/chat-tool-preferences';
|
|
21
20
|
import { ToolInvocationRegistry } from '@theia/ai-core';
|
|
21
|
+
import { PreferenceService } from '@theia/core';
|
|
22
|
+
import { ToolConfirmationManager } from '@theia/ai-chat/lib/browser/chat-tool-preference-bindings';
|
|
23
|
+
import { ToolConfirmationMode } from '@theia/ai-chat/lib/common/chat-tool-preferences';
|
|
22
24
|
|
|
23
25
|
const TOOL_OPTIONS: { value: ToolConfirmationMode, label: string, icon: string }[] = [
|
|
24
26
|
{ value: ToolConfirmationMode.DISABLED, label: 'Disabled', icon: 'close' },
|
|
@@ -14,11 +14,11 @@
|
|
|
14
14
|
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
15
|
// *****************************************************************************
|
|
16
16
|
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
17
|
-
import { FrontendApplicationContribution
|
|
18
|
-
import { Emitter, MaybePromise, Event, } from '@theia/core';
|
|
17
|
+
import { FrontendApplicationContribution } from '@theia/core/lib/browser';
|
|
18
|
+
import { Emitter, MaybePromise, Event, PreferenceService, } from '@theia/core';
|
|
19
19
|
import { ContextKeyService, ContextKey } from '@theia/core/lib/browser/context-key-service';
|
|
20
20
|
import { AIActivationService, ENABLE_AI_CONTEXT_KEY } from '@theia/ai-core/lib/browser/ai-activation-service';
|
|
21
|
-
import { PREFERENCE_NAME_ENABLE_AI } from '
|
|
21
|
+
import { PREFERENCE_NAME_ENABLE_AI } from '../common/ai-ide-preferences';
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
24
|
* Implements AI Activation Service based on preferences.
|
|
@@ -58,7 +58,7 @@ export class AIIdeActivationServiceImpl implements AIActivationService, Frontend
|
|
|
58
58
|
});
|
|
59
59
|
this.preferenceService.onPreferenceChanged(e => {
|
|
60
60
|
if (e.preferenceName === PREFERENCE_NAME_ENABLE_AI) {
|
|
61
|
-
this.updateEnableValue(e.newValue);
|
|
61
|
+
this.updateEnableValue(e.newValue as boolean);
|
|
62
62
|
}
|
|
63
63
|
});
|
|
64
64
|
}
|
|
@@ -22,8 +22,8 @@ import { LanguageModelRequirement } from '@theia/ai-core/lib/common';
|
|
|
22
22
|
import { MCPFrontendService, MCPServerDescription } from '@theia/ai-mcp/lib/common/mcp-server-manager';
|
|
23
23
|
import { nls } from '@theia/core';
|
|
24
24
|
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
25
|
-
import { MCP_SERVERS_PREF } from '@theia/ai-mcp/lib/
|
|
26
|
-
import { PreferenceScope, PreferenceService } from '@theia/core/lib/
|
|
25
|
+
import { MCP_SERVERS_PREF } from '@theia/ai-mcp/lib/common/mcp-preferences';
|
|
26
|
+
import { PreferenceScope, PreferenceService } from '@theia/core/lib/common';
|
|
27
27
|
import { appTesterTemplate, appTesterTemplateVariant, REQUIRED_MCP_SERVERS } from './app-tester-prompt-template';
|
|
28
28
|
|
|
29
29
|
export const AppTesterChatAgentId = 'AppTester';
|
|
@@ -13,6 +13,7 @@ import { BasePromptFragment } from '@theia/ai-core/lib/common';
|
|
|
13
13
|
import { CHAT_CONTEXT_DETAILS_VARIABLE_ID } from '@theia/ai-chat';
|
|
14
14
|
import { QUERY_DOM_FUNCTION_ID, LAUNCH_BROWSER_FUNCTION_ID, CLOSE_BROWSER_FUNCTION_ID, IS_BROWSER_RUNNING_FUNCTION_ID } from '../common/app-tester-chat-functions';
|
|
15
15
|
import { MCPServerDescription } from '@theia/ai-mcp/lib/common/mcp-server-manager';
|
|
16
|
+
import { LIST_LAUNCH_CONFIGURATIONS_FUNCTION_ID, RUN_LAUNCH_CONFIGURATION_FUNCTION_ID, STOP_LAUNCH_CONFIGURATION_FUNCTION_ID } from '../common/workspace-functions';
|
|
16
17
|
|
|
17
18
|
export const REQUIRED_MCP_SERVERS: MCPServerDescription[] = [
|
|
18
19
|
{
|
|
@@ -58,7 +59,10 @@ ${REQUIRED_MCP_SERVERS.map(server => `{{prompt:mcp_${server.name}_tools}}`)}
|
|
|
58
59
|
- **~{${IS_BROWSER_RUNNING_FUNCTION_ID}}**: Check if the browser is running. If a tool fails by saying that the connection failed, you can verify the connection by using this tool.
|
|
59
60
|
- **~{${CLOSE_BROWSER_FUNCTION_ID}}**: Close the browser.
|
|
60
61
|
- **~{${QUERY_DOM_FUNCTION_ID}}**: Query the DOM for specific elements and their properties. Only use when explicitly requested by the user.
|
|
61
|
-
-
|
|
62
|
+
- **~{${LIST_LAUNCH_CONFIGURATIONS_FUNCTION_ID}}**: To get a list of all available launch configurations. If there are no launch configurations, ask the user to manually start\
|
|
63
|
+
the App or configure one.
|
|
64
|
+
- **~{${RUN_LAUNCH_CONFIGURATION_FUNCTION_ID}}**: Use this to launch the App under test (in case it is not already running)
|
|
65
|
+
- **~{${STOP_LAUNCH_CONFIGURATION_FUNCTION_ID}}**: To stop Apps once the testing is done
|
|
62
66
|
|
|
63
67
|
Prefer snapshots for investigating the page.
|
|
64
68
|
|
|
@@ -17,7 +17,6 @@ import { AbstractStreamParsingChatAgent, ChatRequestModel, ChatService, ChatSess
|
|
|
17
17
|
import { LanguageModelRequirement } from '@theia/ai-core';
|
|
18
18
|
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
19
19
|
import { architectSystemVariants, architectTaskSummaryVariants } from '../common/architect-prompt-template';
|
|
20
|
-
import { FILE_CONTENT_FUNCTION_ID, GET_WORKSPACE_FILE_LIST_FUNCTION_ID } from '../common/workspace-functions';
|
|
21
20
|
import { nls } from '@theia/core';
|
|
22
21
|
import { MarkdownStringImpl } from '@theia/core/lib/common/markdown-rendering';
|
|
23
22
|
import { AI_SUMMARIZE_SESSION_AS_TASK_FOR_CODER, AI_UPDATE_TASK_CONTEXT_COMMAND } from '../common/summarize-session-commands';
|
|
@@ -39,7 +38,6 @@ export class ArchitectAgent extends AbstractStreamParsingChatAgent {
|
|
|
39
38
|
and folders and retrieve their content. It cannot modify files. It can therefore answer questions about the current project, project files and source code in the \
|
|
40
39
|
workspace, such as how to build the project, where to put source code, where to find specific code or configurations, etc.');
|
|
41
40
|
override prompts = [architectSystemVariants, architectTaskSummaryVariants];
|
|
42
|
-
override functions = [GET_WORKSPACE_FILE_LIST_FUNCTION_ID, FILE_CONTENT_FUNCTION_ID];
|
|
43
41
|
protected override systemPromptId: string | undefined = architectSystemVariants.id;
|
|
44
42
|
|
|
45
43
|
override async invoke(request: MutableChatRequestModel): Promise<void> {
|