@theia/ai-ide 1.66.0-next.67 → 1.66.0-next.80
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/frontend-module.d.ts.map +1 -1
- package/lib/browser/frontend-module.js +9 -0
- package/lib/browser/frontend-module.js.map +1 -1
- package/lib/browser/github-repo-variable-contribution.d.ts +8 -10
- package/lib/browser/github-repo-variable-contribution.d.ts.map +1 -1
- package/lib/browser/github-repo-variable-contribution.js +22 -41
- package/lib/browser/github-repo-variable-contribution.js.map +1 -1
- package/lib/browser/project-info-agent.d.ts +13 -0
- package/lib/browser/project-info-agent.d.ts.map +1 -0
- package/lib/browser/project-info-agent.js +45 -0
- package/lib/browser/project-info-agent.js.map +1 -0
- package/lib/browser/workspace-functions.js +1 -1
- package/lib/common/github-repo-protocol.d.ts +15 -0
- package/lib/common/github-repo-protocol.d.ts.map +1 -0
- package/lib/common/github-repo-protocol.js +21 -0
- package/lib/common/github-repo-protocol.js.map +1 -0
- package/lib/common/project-info-prompt-template.d.ts +6 -0
- package/lib/common/project-info-prompt-template.d.ts.map +1 -0
- package/lib/common/project-info-prompt-template.js +145 -0
- package/lib/common/project-info-prompt-template.js.map +1 -0
- package/lib/node/backend-module.d.ts.map +1 -1
- package/lib/node/backend-module.js +4 -0
- package/lib/node/backend-module.js.map +1 -1
- package/lib/node/github-repo-service-impl.d.ts +7 -0
- package/lib/node/github-repo-service-impl.d.ts.map +1 -0
- package/lib/node/github-repo-service-impl.js +86 -0
- package/lib/node/github-repo-service-impl.js.map +1 -0
- package/package.json +23 -23
- package/src/browser/frontend-module.ts +10 -0
- package/src/browser/github-repo-variable-contribution.ts +23 -50
- package/src/browser/project-info-agent.ts +42 -0
- package/src/browser/workspace-functions.ts +1 -1
- package/src/common/github-repo-protocol.ts +32 -0
- package/src/common/project-info-prompt-template.ts +163 -0
- package/src/node/backend-module.ts +7 -0
- package/src/node/github-repo-service-impl.ts +98 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"frontend-module.d.ts","sourceRoot":"","sources":["../../src/browser/frontend-module.ts"],"names":[],"mappings":"AAgBA,OAAO,mCAAmC,CAAC;AAE3C,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;;
|
|
1
|
+
{"version":3,"file":"frontend-module.d.ts","sourceRoot":"","sources":["../../src/browser/frontend-module.ts"],"names":[],"mappings":"AAgBA,OAAO,mCAAmC,CAAC;AAE3C,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;;AAgF/D,wBA2KG"}
|
|
@@ -55,6 +55,7 @@ const task_context_service_1 = require("@theia/ai-chat/lib/browser/task-context-
|
|
|
55
55
|
const core_1 = require("@theia/core");
|
|
56
56
|
const prompt_fragments_configuration_widget_1 = require("./ai-configuration/prompt-fragments-configuration-widget");
|
|
57
57
|
const browser_automation_protocol_1 = require("../common/browser-automation-protocol");
|
|
58
|
+
const github_repo_protocol_1 = require("../common/github-repo-protocol");
|
|
58
59
|
const app_tester_chat_functions_1 = require("./app-tester-chat-functions");
|
|
59
60
|
const model_aliases_configuration_widget_1 = require("./ai-configuration/model-aliases-configuration-widget");
|
|
60
61
|
const ai_ide_preferences_1 = require("../common/ai-ide-preferences");
|
|
@@ -62,6 +63,7 @@ const browser_2 = require("@theia/ai-core/lib/browser");
|
|
|
62
63
|
const ai_ide_activation_service_1 = require("./ai-ide-activation-service");
|
|
63
64
|
const ai_configuration_preferences_1 = require("../common/ai-configuration-preferences");
|
|
64
65
|
const task_context_agent_1 = require("./task-context-agent");
|
|
66
|
+
const project_info_agent_1 = require("./project-info-agent");
|
|
65
67
|
exports.default = new inversify_1.ContainerModule((bind, _unbind, _isBound, rebind) => {
|
|
66
68
|
bind(core_1.PreferenceContribution).toConstantValue({ schema: ai_ide_preferences_1.aiIdePreferenceSchema });
|
|
67
69
|
bind(core_1.PreferenceContribution).toConstantValue({ schema: workspace_preferences_1.WorkspacePreferencesSchema });
|
|
@@ -76,6 +78,9 @@ exports.default = new inversify_1.ContainerModule((bind, _unbind, _isBound, rebi
|
|
|
76
78
|
bind(common_1.ChatAgent).toService(coder_agent_1.CoderAgent);
|
|
77
79
|
bind(task_context_agent_1.TaskContextAgent).toSelf().inSingletonScope();
|
|
78
80
|
bind(common_2.Agent).toService(task_context_agent_1.TaskContextAgent);
|
|
81
|
+
bind(project_info_agent_1.ProjectInfoAgent).toSelf().inSingletonScope();
|
|
82
|
+
bind(common_2.Agent).toService(project_info_agent_1.ProjectInfoAgent);
|
|
83
|
+
bind(common_1.ChatAgent).toService(project_info_agent_1.ProjectInfoAgent);
|
|
79
84
|
bind(orchestrator_chat_agent_1.OrchestratorChatAgent).toSelf().inSingletonScope();
|
|
80
85
|
bind(common_2.Agent).toService(orchestrator_chat_agent_1.OrchestratorChatAgent);
|
|
81
86
|
bind(common_1.ChatAgent).toService(orchestrator_chat_agent_1.OrchestratorChatAgent);
|
|
@@ -187,6 +192,10 @@ exports.default = new inversify_1.ContainerModule((bind, _unbind, _isBound, rebi
|
|
|
187
192
|
.inSingletonScope();
|
|
188
193
|
bind(task_background_summary_variable_1.TaskContextSummaryVariableContribution).toSelf().inSingletonScope();
|
|
189
194
|
bind(common_2.AIVariableContribution).toService(task_background_summary_variable_1.TaskContextSummaryVariableContribution);
|
|
195
|
+
bind(github_repo_protocol_1.GitHubRepoService).toDynamicValue(ctx => {
|
|
196
|
+
const provider = ctx.container.get(browser_1.RemoteConnectionProvider);
|
|
197
|
+
return provider.createProxy(github_repo_protocol_1.githubRepoServicePath);
|
|
198
|
+
}).inSingletonScope();
|
|
190
199
|
bind(github_repo_variable_contribution_1.GitHubRepoVariableContribution).toSelf().inSingletonScope();
|
|
191
200
|
bind(common_2.AIVariableContribution).toService(github_repo_variable_contribution_1.GitHubRepoVariableContribution);
|
|
192
201
|
bind(task_context_file_storage_service_1.TaskContextFileStorageService).toSelf().inSingletonScope();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"frontend-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,iEAA6B,CAAC,CAAC;IAE3E,IAAI,CAAC,0BAAmB,CAAC,CAAC,EAAE,CAAC,4EAAmC,CAAC,CAAC;IAClE,IAAI,CAAC,4EAAoC,CAAC,CAAC,MAAM,EAAE,CAAC;IACpD,IAAI,CAAC,uBAAa,CAAC;SACd,cAAc,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QACpB,EAAE,EAAE,4EAAoC,CAAC,EAAE;QAC3C,YAAY,EAAE,GAAG,EAAE,CAAC,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,4EAAoC,CAAC;KAC9E,CAAC,CAAC;SACF,gBAAgB,EAAE,CAAC;AAC5B,CAAC,CAAC,CAAC"}
|
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
import { MaybePromise } from '@theia/core';
|
|
2
2
|
import { AIVariableContribution, AIVariableResolver, AIVariableService, AIVariableResolutionRequest, AIVariableContext, ResolvedAIVariable, AIVariable } from '@theia/ai-core/lib/common';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
3
|
+
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
4
|
+
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
5
|
+
import { GitHubRepoService } from '../common/github-repo-protocol';
|
|
6
6
|
export declare const GITHUB_REPO_NAME_VARIABLE: AIVariable;
|
|
7
7
|
export declare class GitHubRepoVariableContribution implements AIVariableContribution, AIVariableResolver {
|
|
8
|
-
protected readonly
|
|
9
|
-
protected readonly
|
|
10
|
-
protected readonly
|
|
8
|
+
protected readonly workspaceService: WorkspaceService;
|
|
9
|
+
protected readonly fileService: FileService;
|
|
10
|
+
protected readonly gitHubRepoService: GitHubRepoService;
|
|
11
11
|
registerVariables(service: AIVariableService): void;
|
|
12
|
-
canResolve(request: AIVariableResolutionRequest,
|
|
13
|
-
resolve(request: AIVariableResolutionRequest,
|
|
14
|
-
private isGitHubRemote;
|
|
15
|
-
private extractRepoNameFromGitHubUrl;
|
|
12
|
+
canResolve(request: AIVariableResolutionRequest, _context: AIVariableContext): MaybePromise<number>;
|
|
13
|
+
resolve(request: AIVariableResolutionRequest, _context: AIVariableContext): Promise<ResolvedAIVariable | undefined>;
|
|
16
14
|
}
|
|
17
15
|
//# sourceMappingURL=github-repo-variable-contribution.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"github-repo-variable-contribution.d.ts","sourceRoot":"","sources":["../../src/browser/github-repo-variable-contribution.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,YAAY,EAAO,MAAM,aAAa,CAAC;AAChD,OAAO,EACH,sBAAsB,EACtB,kBAAkB,EAClB,iBAAiB,EACjB,2BAA2B,EAC3B,iBAAiB,EACjB,kBAAkB,EAClB,UAAU,EACb,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"github-repo-variable-contribution.d.ts","sourceRoot":"","sources":["../../src/browser/github-repo-variable-contribution.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,YAAY,EAAO,MAAM,aAAa,CAAC;AAChD,OAAO,EACH,sBAAsB,EACtB,kBAAkB,EAClB,iBAAiB,EACjB,2BAA2B,EAC3B,iBAAiB,EACjB,kBAAkB,EAClB,UAAU,EACb,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AAEzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAEnE,eAAO,MAAM,yBAAyB,EAAE,UAIvC,CAAC;AAEF,qBACa,8BAA+B,YAAW,sBAAsB,EAAE,kBAAkB;IAG7F,SAAS,CAAC,QAAQ,CAAC,gBAAgB,EAAE,gBAAgB,CAAC;IAGtD,SAAS,CAAC,QAAQ,CAAC,WAAW,EAAE,WAAW,CAAC;IAG5C,SAAS,CAAC,QAAQ,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;IAExD,iBAAiB,CAAC,OAAO,EAAE,iBAAiB,GAAG,IAAI;IAInD,UAAU,CAAC,OAAO,EAAE,2BAA2B,EAAE,QAAQ,EAAE,iBAAiB,GAAG,YAAY,CAAC,MAAM,CAAC;IAQ7F,OAAO,CAAC,OAAO,EAAE,2BAA2B,EAAE,QAAQ,EAAE,iBAAiB,GAAG,OAAO,CAAC,kBAAkB,GAAG,SAAS,CAAC;CA8B5H"}
|
|
@@ -19,9 +19,9 @@ exports.GitHubRepoVariableContribution = exports.GITHUB_REPO_NAME_VARIABLE = voi
|
|
|
19
19
|
const tslib_1 = require("tslib");
|
|
20
20
|
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
21
|
const core_1 = require("@theia/core");
|
|
22
|
-
const
|
|
23
|
-
const
|
|
24
|
-
const
|
|
22
|
+
const browser_1 = require("@theia/workspace/lib/browser");
|
|
23
|
+
const file_service_1 = require("@theia/filesystem/lib/browser/file-service");
|
|
24
|
+
const github_repo_protocol_1 = require("../common/github-repo-protocol");
|
|
25
25
|
exports.GITHUB_REPO_NAME_VARIABLE = {
|
|
26
26
|
id: 'github-repo-name-provider',
|
|
27
27
|
name: 'githubRepoName',
|
|
@@ -31,35 +31,30 @@ let GitHubRepoVariableContribution = class GitHubRepoVariableContribution {
|
|
|
31
31
|
registerVariables(service) {
|
|
32
32
|
service.registerResolver(exports.GITHUB_REPO_NAME_VARIABLE, this);
|
|
33
33
|
}
|
|
34
|
-
canResolve(request,
|
|
34
|
+
canResolve(request, _context) {
|
|
35
35
|
if (request.variable.name !== exports.GITHUB_REPO_NAME_VARIABLE.name) {
|
|
36
36
|
return 0;
|
|
37
37
|
}
|
|
38
|
-
const selectedRepo = this.repositoryProvider.selectedRepository;
|
|
39
|
-
if (!selectedRepo) {
|
|
40
|
-
return 0;
|
|
41
|
-
}
|
|
42
38
|
return 1;
|
|
43
39
|
}
|
|
44
|
-
async resolve(request,
|
|
40
|
+
async resolve(request, _context) {
|
|
45
41
|
if (request.variable.name !== exports.GITHUB_REPO_NAME_VARIABLE.name) {
|
|
46
42
|
return undefined;
|
|
47
43
|
}
|
|
48
|
-
const repository = this.repositoryProvider.selectedRepository;
|
|
49
|
-
if (!repository) {
|
|
50
|
-
return { variable: request.variable, value: 'No GitHub repository is currently selected or detected.' };
|
|
51
|
-
}
|
|
52
44
|
try {
|
|
53
|
-
const
|
|
54
|
-
|
|
55
|
-
const githubRemote = remotes.find(remote => remote.name === 'origin' && this.isGitHubRemote(remote.fetch)) || remotes.find(remote => this.isGitHubRemote(remote.fetch));
|
|
56
|
-
if (!githubRemote) {
|
|
45
|
+
const workspaceRoots = await this.workspaceService.roots;
|
|
46
|
+
if (workspaceRoots.length === 0) {
|
|
57
47
|
return { variable: request.variable, value: 'No GitHub repository is currently selected or detected.' };
|
|
58
48
|
}
|
|
59
|
-
|
|
60
|
-
|
|
49
|
+
// Get the filesystem path from the workspace root URI
|
|
50
|
+
const workspaceRoot = workspaceRoots[0].resource;
|
|
51
|
+
const workspacePath = workspaceRoot.path.fsPath();
|
|
52
|
+
// Use the backend service to get GitHub repository information
|
|
53
|
+
const repoInfo = await this.gitHubRepoService.getGitHubRepoInfo(workspacePath);
|
|
54
|
+
if (!repoInfo) {
|
|
61
55
|
return { variable: request.variable, value: 'No GitHub repository is currently selected or detected.' };
|
|
62
56
|
}
|
|
57
|
+
const repoName = `${repoInfo.owner}/${repoInfo.repo}`;
|
|
63
58
|
return { variable: request.variable, value: `You are currently working with the GitHub repository: **${repoName}**` };
|
|
64
59
|
}
|
|
65
60
|
catch (error) {
|
|
@@ -67,34 +62,20 @@ let GitHubRepoVariableContribution = class GitHubRepoVariableContribution {
|
|
|
67
62
|
return { variable: request.variable, value: 'No GitHub repository is currently selected or detected.' };
|
|
68
63
|
}
|
|
69
64
|
}
|
|
70
|
-
isGitHubRemote(remoteUrl) {
|
|
71
|
-
return remoteUrl.includes('github.com');
|
|
72
|
-
}
|
|
73
|
-
extractRepoNameFromGitHubUrl(url) {
|
|
74
|
-
const httpsMatch = url.match(/https:\/\/github\.com\/([^\/]+\/[^\/]+?)(?:\.git)?$/);
|
|
75
|
-
if (httpsMatch) {
|
|
76
|
-
return httpsMatch[1];
|
|
77
|
-
}
|
|
78
|
-
const sshMatch = url.match(/git@github\.com:([^\/]+\/[^\/]+?)(?:\.git)?$/);
|
|
79
|
-
if (sshMatch) {
|
|
80
|
-
return sshMatch[1];
|
|
81
|
-
}
|
|
82
|
-
return undefined;
|
|
83
|
-
}
|
|
84
65
|
};
|
|
85
66
|
exports.GitHubRepoVariableContribution = GitHubRepoVariableContribution;
|
|
86
67
|
tslib_1.__decorate([
|
|
87
|
-
(0, inversify_1.inject)(
|
|
88
|
-
tslib_1.__metadata("design:type",
|
|
89
|
-
], GitHubRepoVariableContribution.prototype, "
|
|
68
|
+
(0, inversify_1.inject)(browser_1.WorkspaceService),
|
|
69
|
+
tslib_1.__metadata("design:type", browser_1.WorkspaceService)
|
|
70
|
+
], GitHubRepoVariableContribution.prototype, "workspaceService", void 0);
|
|
90
71
|
tslib_1.__decorate([
|
|
91
|
-
(0, inversify_1.inject)(
|
|
92
|
-
tslib_1.__metadata("design:type",
|
|
93
|
-
], GitHubRepoVariableContribution.prototype, "
|
|
72
|
+
(0, inversify_1.inject)(file_service_1.FileService),
|
|
73
|
+
tslib_1.__metadata("design:type", file_service_1.FileService)
|
|
74
|
+
], GitHubRepoVariableContribution.prototype, "fileService", void 0);
|
|
94
75
|
tslib_1.__decorate([
|
|
95
|
-
(0, inversify_1.inject)(
|
|
76
|
+
(0, inversify_1.inject)(github_repo_protocol_1.GitHubRepoService),
|
|
96
77
|
tslib_1.__metadata("design:type", Object)
|
|
97
|
-
], GitHubRepoVariableContribution.prototype, "
|
|
78
|
+
], GitHubRepoVariableContribution.prototype, "gitHubRepoService", void 0);
|
|
98
79
|
exports.GitHubRepoVariableContribution = GitHubRepoVariableContribution = tslib_1.__decorate([
|
|
99
80
|
(0, inversify_1.injectable)()
|
|
100
81
|
], GitHubRepoVariableContribution);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"github-repo-variable-contribution.js","sourceRoot":"","sources":["../../src/browser/github-repo-variable-contribution.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,4DAAkE;AAClE,sCAAgD;AAUhD,
|
|
1
|
+
{"version":3,"file":"github-repo-variable-contribution.js","sourceRoot":"","sources":["../../src/browser/github-repo-variable-contribution.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,4DAAkE;AAClE,sCAAgD;AAUhD,0DAAgE;AAChE,6EAAyE;AAEzE,yEAAmE;AAEtD,QAAA,yBAAyB,GAAe;IACjD,EAAE,EAAE,2BAA2B;IAC/B,IAAI,EAAE,gBAAgB;IACtB,WAAW,EAAE,UAAG,CAAC,QAAQ,CAAC,yCAAyC,EAAE,yEAAyE,CAAC;CAClJ,CAAC;AAGK,IAAM,8BAA8B,GAApC,MAAM,8BAA8B;IAWvC,iBAAiB,CAAC,OAA0B;QACxC,OAAO,CAAC,gBAAgB,CAAC,iCAAyB,EAAE,IAAI,CAAC,CAAC;IAC9D,CAAC;IAED,UAAU,CAAC,OAAoC,EAAE,QAA2B;QACxE,IAAI,OAAO,CAAC,QAAQ,CAAC,IAAI,KAAK,iCAAyB,CAAC,IAAI,EAAE,CAAC;YAC3D,OAAO,CAAC,CAAC;QACb,CAA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,CAAC;IACL,CAAC;CACJ,CAAA;AArDY,wEAA8B;AAGpB;IADlB,IAAA,kBAAM,EAAC,0BAAgB,CAAC;sCACY,0BAAgB;wEAAC;AAGnC;IADlB,IAAA,kBAAM,EAAC,0BAAW,CAAC;sCACY,0BAAW;mEAAC;AAGzB;IADlB,IAAA,kBAAM,EAAC,wCAAiB,CAAC;;yEAC8B;yCAT/C,8BAA8B;IAD1C,IAAA,sBAAU,GAAE;GACA,8BAA8B,CAqD1C"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { AbstractStreamParsingChatAgent } from '@theia/ai-chat';
|
|
2
|
+
import { LanguageModelRequirement } from '@theia/ai-core';
|
|
3
|
+
export declare class ProjectInfoAgent extends AbstractStreamParsingChatAgent {
|
|
4
|
+
name: string;
|
|
5
|
+
id: string;
|
|
6
|
+
languageModelRequirements: LanguageModelRequirement[];
|
|
7
|
+
protected defaultLanguageModelPurpose: string;
|
|
8
|
+
description: string;
|
|
9
|
+
tags: string[];
|
|
10
|
+
prompts: import("@theia/ai-core").PromptVariantSet[];
|
|
11
|
+
protected systemPromptId: string | undefined;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=project-info-agent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-info-agent.d.ts","sourceRoot":"","sources":["../../src/browser/project-info-agent.ts"],"names":[],"mappings":"AAeA,OAAO,EAAE,8BAA8B,EAAE,MAAM,gBAAgB,CAAC;AAChE,OAAO,EAAE,wBAAwB,EAAE,MAAM,gBAAgB,CAAC;AAK1D,qBACa,gBAAiB,SAAQ,8BAA8B;IAEhE,IAAI,SAAiB;IACrB,EAAE,SAAiB;IACnB,yBAAyB,EAAE,wBAAwB,EAAE,CAGlD;IACH,SAAS,CAAC,2BAA2B,EAAE,MAAM,CAAU;IAE9C,WAAW,SAEwJ;IAEnK,IAAI,EAAE,MAAM,EAAE,CAA2B;IAEzC,OAAO,8CAA4D;IAC5E,UAAmB,cAAc,EAAE,MAAM,GAAG,SAAS,CAAgC;CAExF"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProjectInfoAgent = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
// *****************************************************************************
|
|
6
|
+
// Copyright (C) 2024 EclipseSource GmbH.
|
|
7
|
+
//
|
|
8
|
+
// This program and the accompanying materials are made available under the
|
|
9
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
10
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
11
|
+
//
|
|
12
|
+
// This Source Code may also be made available under the following Secondary
|
|
13
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
14
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
15
|
+
// with the GNU Classpath Exception which is available at
|
|
16
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
17
|
+
//
|
|
18
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
19
|
+
// *****************************************************************************
|
|
20
|
+
const ai_chat_1 = require("@theia/ai-chat");
|
|
21
|
+
const inversify_1 = require("@theia/core/shared/inversify");
|
|
22
|
+
const project_info_prompt_template_1 = require("../common/project-info-prompt-template");
|
|
23
|
+
const core_1 = require("@theia/core");
|
|
24
|
+
let ProjectInfoAgent = class ProjectInfoAgent extends ai_chat_1.AbstractStreamParsingChatAgent {
|
|
25
|
+
constructor() {
|
|
26
|
+
super(...arguments);
|
|
27
|
+
this.name = 'ProjectInfo';
|
|
28
|
+
this.id = 'ProjectInfo';
|
|
29
|
+
this.languageModelRequirements = [{
|
|
30
|
+
purpose: 'chat',
|
|
31
|
+
identifier: 'default/code',
|
|
32
|
+
}];
|
|
33
|
+
this.defaultLanguageModelPurpose = 'chat';
|
|
34
|
+
this.description = core_1.nls.localize('theia/ai/workspace/projectInfoAgent/description', 'An AI assistant for managing project information templates. This agent helps create, update, and review the .prompts/project-info.prompttemplate file which provides ' +
|
|
35
|
+
'context about your project to other AI agents. It can analyze your workspace to suggest project information or update existing templates based on your requirements.');
|
|
36
|
+
this.tags = [...this.tags, 'Alpha'];
|
|
37
|
+
this.prompts = [project_info_prompt_template_1.projectInfoSystemVariants, project_info_prompt_template_1.projectInfoTemplateVariants];
|
|
38
|
+
this.systemPromptId = project_info_prompt_template_1.projectInfoSystemVariants.id;
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
exports.ProjectInfoAgent = ProjectInfoAgent;
|
|
42
|
+
exports.ProjectInfoAgent = ProjectInfoAgent = tslib_1.__decorate([
|
|
43
|
+
(0, inversify_1.injectable)()
|
|
44
|
+
], ProjectInfoAgent);
|
|
45
|
+
//# sourceMappingURL=project-info-agent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-info-agent.js","sourceRoot":"","sources":["../../src/browser/project-info-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;AAChF,4CAAgE;AAEhE,4DAA0D;AAC1D,yFAAgH;AAChH,sCAAkC;AAG3B,IAAM,gBAAgB,GAAtB,MAAM,gBAAiB,SAAQ,wCAA8B;IAA7D;;QAEH,SAAI,GAAG,aAAa,CAAC;QACrB,OAAE,GAAG,aAAa,CAAC;QACnB,8BAAyB,GAA+B,CAAC;gBACrD,OAAO,EAAE,MAAM;gBACf,UAAU,EAAE,cAAc;aAC7B,CAAC,CAAC;QACO,gCAA2B,GAAW,MAAM,CAAC;QAE9C,gBAAW,GAAG,UAAG,CAAC,QAAQ,CAAC,iDAAiD,EACjF,uKAAuK;YACvK,sKAAsK,CAAC,CAAC;QAEnK,SAAI,GAAa,CAAC,GAAG,IAAI,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;QAEzC,YAAO,GAAG,CAAC,wDAAyB,EAAE,0DAA2B,CAAC,CAAC;QACzD,mBAAc,GAAuB,wDAAyB,CAAC,EAAE,CAAC;IAEzF,CAAC;CAAA,CAAA;AAnBY,4CAAgB;2BAAhB,gBAAgB;IAD5B,IAAA,sBAAU,GAAE;GACA,gBAAgB,CAmB5B"}
|
|
@@ -115,7 +115,7 @@ let GetWorkspaceDirectoryStructure = GetWorkspaceDirectoryStructure_1 = class Ge
|
|
|
115
115
|
'This structure excludes specific directories, such as node_modules and hidden files, ensuring paths are within workspace boundaries.',
|
|
116
116
|
parameters: {
|
|
117
117
|
type: 'object',
|
|
118
|
-
properties: {}
|
|
118
|
+
properties: {},
|
|
119
119
|
},
|
|
120
120
|
handler: (_, ctx) => {
|
|
121
121
|
const cancellationToken = ctx.response.cancellationToken;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const GitHubRepoService: unique symbol;
|
|
2
|
+
export declare const githubRepoServicePath = "/services/github-repo";
|
|
3
|
+
export interface GitHubRepoInfo {
|
|
4
|
+
owner: string;
|
|
5
|
+
repo: string;
|
|
6
|
+
}
|
|
7
|
+
export interface GitHubRepoService {
|
|
8
|
+
/**
|
|
9
|
+
* Gets the GitHub repository information for the given workspace path.
|
|
10
|
+
* @param workspacePath The absolute path to the workspace directory
|
|
11
|
+
* @returns GitHub repository info (owner/repo) or undefined if not a GitHub repository
|
|
12
|
+
*/
|
|
13
|
+
getGitHubRepoInfo(workspacePath: string): Promise<GitHubRepoInfo | undefined>;
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=github-repo-protocol.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"github-repo-protocol.d.ts","sourceRoot":"","sources":["../../src/common/github-repo-protocol.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,iBAAiB,eAA8B,CAAC;AAC7D,eAAO,MAAM,qBAAqB,0BAA0B,CAAC;AAE7D,MAAM,WAAW,cAAc;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,iBAAiB;IAC9B;;;;OAIG;IACH,iBAAiB,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,GAAG,SAAS,CAAC,CAAC;CACjF"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *****************************************************************************
|
|
3
|
+
// Copyright (C) 2025 EclipseSource GmbH.
|
|
4
|
+
//
|
|
5
|
+
// This program and the accompanying materials are made available under the
|
|
6
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
//
|
|
9
|
+
// This Source Code may also be made available under the following Secondary
|
|
10
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
// with the GNU Classpath Exception which is available at
|
|
13
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
//
|
|
15
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
+
// *****************************************************************************
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.githubRepoServicePath = exports.GitHubRepoService = void 0;
|
|
19
|
+
exports.GitHubRepoService = Symbol('GitHubRepoService');
|
|
20
|
+
exports.githubRepoServicePath = '/services/github-repo';
|
|
21
|
+
//# sourceMappingURL=github-repo-protocol.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"github-repo-protocol.js","sourceRoot":"","sources":["../../src/common/github-repo-protocol.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;;;AAEnE,QAAA,iBAAiB,GAAG,MAAM,CAAC,mBAAmB,CAAC,CAAC;AAChD,QAAA,qBAAqB,GAAG,uBAAuB,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { PromptVariantSet } from '@theia/ai-core/lib/common';
|
|
2
|
+
export declare const PROJECT_INFO_SYSTEM_PROMPT_TEMPLATE_ID = "project-info-system";
|
|
3
|
+
export declare const PROJECT_INFO_TEMPLATE_PROMPT_ID = "project-info-template";
|
|
4
|
+
export declare const projectInfoTemplateVariants: PromptVariantSet;
|
|
5
|
+
export declare const projectInfoSystemVariants: PromptVariantSet;
|
|
6
|
+
//# sourceMappingURL=project-info-prompt-template.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-info-prompt-template.d.ts","sourceRoot":"","sources":["../../src/common/project-info-prompt-template.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAc7D,eAAO,MAAM,sCAAsC,wBAAwB,CAAC;AAC5E,eAAO,MAAM,+BAA+B,0BAA0B,CAAC;AAEvE,eAAO,MAAM,2BAA2B,kBAgCvC,CAAC;AAEF,eAAO,MAAM,yBAAyB,kBAqGrC,CAAC"}
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.projectInfoSystemVariants = exports.projectInfoTemplateVariants = exports.PROJECT_INFO_TEMPLATE_PROMPT_ID = exports.PROJECT_INFO_SYSTEM_PROMPT_TEMPLATE_ID = void 0;
|
|
4
|
+
const workspace_functions_1 = require("./workspace-functions");
|
|
5
|
+
const context_variables_1 = require("./context-variables");
|
|
6
|
+
const context_functions_1 = require("./context-functions");
|
|
7
|
+
const file_changeset_function_ids_1 = require("./file-changeset-function-ids");
|
|
8
|
+
exports.PROJECT_INFO_SYSTEM_PROMPT_TEMPLATE_ID = 'project-info-system';
|
|
9
|
+
exports.PROJECT_INFO_TEMPLATE_PROMPT_ID = 'project-info-template';
|
|
10
|
+
exports.projectInfoTemplateVariants = {
|
|
11
|
+
id: exports.PROJECT_INFO_TEMPLATE_PROMPT_ID,
|
|
12
|
+
defaultVariant: {
|
|
13
|
+
id: 'project-info-template-default',
|
|
14
|
+
template: `## Project Info Template Structure
|
|
15
|
+
|
|
16
|
+
### Architecture Overview
|
|
17
|
+
[Brief description of what the project does, Key architectural decisions, patterns, and structure.]
|
|
18
|
+
|
|
19
|
+
### Key Technologies
|
|
20
|
+
[List of main technologies, frameworks, libraries]
|
|
21
|
+
|
|
22
|
+
### Essential Development Patterns
|
|
23
|
+
Examples for key patterns (refer via relative file paths)
|
|
24
|
+
|
|
25
|
+
### File Structure
|
|
26
|
+
[Important directories/packages and their contents]
|
|
27
|
+
|
|
28
|
+
### Build & Development
|
|
29
|
+
[How to build and run the project.]
|
|
30
|
+
|
|
31
|
+
### Testing
|
|
32
|
+
[What kind of tests exist, test organization and test patterns. Examples for different types of tests (as relative file paths)]
|
|
33
|
+
|
|
34
|
+
### Coding Guidelines
|
|
35
|
+
[Coding standards, conventions, practices. Examples for key practices (as relative file paths), rules for imports, indentation]
|
|
36
|
+
|
|
37
|
+
### Additional Notes
|
|
38
|
+
[Any other important information for agents to understand the project and write code for it. Important files with more information (as relative file paths)]
|
|
39
|
+
\`\`\`
|
|
40
|
+
`
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
exports.projectInfoSystemVariants = {
|
|
44
|
+
id: exports.PROJECT_INFO_SYSTEM_PROMPT_TEMPLATE_ID,
|
|
45
|
+
defaultVariant: {
|
|
46
|
+
id: 'project-info-system-default',
|
|
47
|
+
template: `{{!-- This prompt is licensed under the MIT License (https://opensource.org/license/mit).
|
|
48
|
+
Made improvements or adaptations to this prompt template? We'd love for you to share it with the community! Contribute back here:
|
|
49
|
+
https://github.com/eclipse-theia/theia/discussions/new?category=prompt-template-contribution --}}
|
|
50
|
+
# Instructions
|
|
51
|
+
|
|
52
|
+
You are the ProjectInfo agent, an AI assistant specialized in managing project information files. Your role is to help users create, update,
|
|
53
|
+
and maintain the \`.prompts/project-info.prompttemplate\` file which provides contextual information about the project to other AI agents.
|
|
54
|
+
|
|
55
|
+
## Project Info Guidelines
|
|
56
|
+
The project info is an artifact that will be handed over to agents to understand the current workspace, project and codebase.
|
|
57
|
+
Do not include obvious instructions, generic information, generic development practices or things that can be very easily discovered.
|
|
58
|
+
Focus on non-obvious and project-specific facts as well as specific guidelines and patterns.
|
|
59
|
+
Try to keep the project info minimal and avoid duplicates.
|
|
60
|
+
|
|
61
|
+
## Your Capabilities
|
|
62
|
+
|
|
63
|
+
### Initially Create Project Info
|
|
64
|
+
For initial project info creation, start by determining the user's preferred working mode:
|
|
65
|
+
|
|
66
|
+
**Step 1: Define mode of working**
|
|
67
|
+
Ask the user about the preferred working mode:
|
|
68
|
+
|
|
69
|
+
1. "Auto-exploration - Agent explores and creates an initial suggestion",
|
|
70
|
+
2. "Manual - User provides all necessary input with your guidance"
|
|
71
|
+
|
|
72
|
+
IMPORTANT: Remember the chosen mode and stick to it until the user requests otherwise!
|
|
73
|
+
|
|
74
|
+
- In automatic mode, create an initial version of the project info yourself by exploring the workspace
|
|
75
|
+
- In manual mode, guide the user section by section and ask for additional information.
|
|
76
|
+
Whenever you ask a question to the user, offer the option that you answer the question for them.
|
|
77
|
+
|
|
78
|
+
**Step 2: Final tasks**
|
|
79
|
+
After completing all sections or if you feel the user is done, offer the user to do an automatic refinement:
|
|
80
|
+
"Would you like me to review and finalize the project information?",
|
|
81
|
+
- In this final refinement, particularly focus on relevance and potential duplications and the "Project Info Guidelines"
|
|
82
|
+
- Then, ask for final user review. Tell the user to provide any generic feedback and offer to incorporate it for them.
|
|
83
|
+
- Finally remind them to accept the final version in the change set
|
|
84
|
+
|
|
85
|
+
### Complete Project Info
|
|
86
|
+
- If a project info is incomplete, offer the user to complete it
|
|
87
|
+
|
|
88
|
+
### Update Project Info
|
|
89
|
+
- Modify existing project info based on user requirements
|
|
90
|
+
- Do not use a specific workflow for this
|
|
91
|
+
|
|
92
|
+
## Workspace Analysis Guidelines
|
|
93
|
+
|
|
94
|
+
**Auto-Discovery File Patterns**
|
|
95
|
+
When auto-discovering project information or exploring the workspace structure, ALWAYS prioritize examining these file patterns that commonly contain agent instructions
|
|
96
|
+
and project documentation:
|
|
97
|
+
- .github/copilot-instructions.md
|
|
98
|
+
- AGENT.md
|
|
99
|
+
- AGENTS.md
|
|
100
|
+
- CLAUDE.md
|
|
101
|
+
- .cursorrules
|
|
102
|
+
- .windsurfrules
|
|
103
|
+
- .clinerules
|
|
104
|
+
- .cursor
|
|
105
|
+
- rules/**
|
|
106
|
+
- .windsurf/rules/**
|
|
107
|
+
- .clinerules/**
|
|
108
|
+
- README.md
|
|
109
|
+
- .md files in the root level if they contain documentation
|
|
110
|
+
|
|
111
|
+
Use the **~{${workspace_functions_1.FIND_FILES_BY_PATTERN_FUNCTION_ID}}** function with these patterns to discover relevant configuration and documentation files.
|
|
112
|
+
|
|
113
|
+
## Context Retrieval
|
|
114
|
+
Use the following functions to interact with the workspace files when needed:
|
|
115
|
+
- **~{${workspace_functions_1.GET_WORKSPACE_FILE_LIST_FUNCTION_ID}}**: List files and directories
|
|
116
|
+
- **~{${workspace_functions_1.FILE_CONTENT_FUNCTION_ID}}**: Get content of specific files
|
|
117
|
+
- **~{${workspace_functions_1.FIND_FILES_BY_PATTERN_FUNCTION_ID}}**: Find files by glob patterns like '**/*.json'
|
|
118
|
+
- **~{${workspace_functions_1.SEARCH_IN_WORKSPACE_FUNCTION_ID}}**: Search file contents
|
|
119
|
+
|
|
120
|
+
Navigate step-by-step and confirm paths. Use **~{${context_functions_1.UPDATE_CONTEXT_FILES_FUNCTION_ID}}** to remember important files for later reference.
|
|
121
|
+
|
|
122
|
+
## File Modification - SUGGEST ONLY
|
|
123
|
+
Use these functions liberally to suggest file changes. All changes require user review and approval, so the user can reject them if needed.
|
|
124
|
+
|
|
125
|
+
- **~{${file_changeset_function_ids_1.SUGGEST_FILE_CONTENT_ID}}**: Propose complete file content (for creating new templates or complete rewrites)
|
|
126
|
+
- **~{${file_changeset_function_ids_1.SUGGEST_FILE_REPLACEMENTS_ID}}**: Propose targeted replacements of specific text sections
|
|
127
|
+
- **~{${file_changeset_function_ids_1.GET_PROPOSED_CHANGES_ID}}**: View current proposed changes before making additional ones
|
|
128
|
+
- **~{${file_changeset_function_ids_1.CLEAR_FILE_CHANGES_ID}}**: Clear all pending changes for a file to start fresh
|
|
129
|
+
|
|
130
|
+
{{prompt:${exports.PROJECT_INFO_TEMPLATE_PROMPT_ID}}}
|
|
131
|
+
|
|
132
|
+
## Additional Context
|
|
133
|
+
{{${context_variables_1.CONTEXT_FILES_VARIABLE_ID}}}
|
|
134
|
+
|
|
135
|
+
## Workflow Guidelines
|
|
136
|
+
|
|
137
|
+
When creating project info for the first time:
|
|
138
|
+
1. **Always start by asking about the user's preferred mode** (auto-exploration or manual) and stick to it
|
|
139
|
+
2. **After initial suggestions or provided content**: Always ask for refinement and additional information
|
|
140
|
+
|
|
141
|
+
Remember: Proactively help users maintain accurate project information for better AI assistance.
|
|
142
|
+
`
|
|
143
|
+
}
|
|
144
|
+
};
|
|
145
|
+
//# sourceMappingURL=project-info-prompt-template.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-info-prompt-template.js","sourceRoot":"","sources":["../../src/common/project-info-prompt-template.ts"],"names":[],"mappings":";;;AAWA,+DAG+B;AAC/B,2DAAgE;AAChE,2DAAuE;AACvE,+EAKuC;AAE1B,QAAA,sCAAsC,GAAG,qBAAqB,CAAC;AAC/D,QAAA,+BAA+B,GAAG,uBAAuB,CAAC;AAE1D,QAAA,2BAA2B,GAAqB;IACzD,EAAE,EAAE,uCAA+B;IACnC,cAAc,EAAE;QACZ,EAAE,EAAE,+BAA+B;QACnC,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;CA0BjB;KACI;CACJ,CAAC;AAEW,QAAA,yBAAyB,GAAqB;IACvD,EAAE,EAAE,8CAAsC;IAC1C,cAAc,EAAE;QACZ,EAAE,EAAE,6BAA6B;QACjC,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAgEJ,uDAAiC;;;;QAIvC,yDAAmC;QACnC,8CAAwB;QACxB,uDAAiC;QACjC,qDAA+B;;mDAEY,oDAAgC;;;;;QAK3E,qDAAuB;QACvB,0DAA4B;QAC5B,qDAAuB;QACvB,mDAAqB;;WAElB,uCAA+B;;;IAGtC,6CAAyB;;;;;;;;;CAS5B;KACI;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;;AAsB/D,wBAYG"}
|
|
@@ -23,6 +23,8 @@ const connection_container_module_1 = require("@theia/core/lib/node/messaging/co
|
|
|
23
23
|
const workspace_preferences_1 = require("../common/workspace-preferences");
|
|
24
24
|
const ai_configuration_preferences_1 = require("../common/ai-configuration-preferences");
|
|
25
25
|
const ai_ide_preferences_1 = require("../common/ai-ide-preferences");
|
|
26
|
+
const github_repo_protocol_1 = require("../common/github-repo-protocol");
|
|
27
|
+
const github_repo_service_impl_1 = require("./github-repo-service-impl");
|
|
26
28
|
const browserAutomationModule = connection_container_module_1.ConnectionContainerModule.create(({ bind, bindBackendService, bindFrontendService }) => {
|
|
27
29
|
bind(browser_automation_protocol_1.BrowserAutomation).to(browser_automation_impl_1.BrowserAutomationImpl).inSingletonScope();
|
|
28
30
|
bind(core_1.ConnectionHandler).toDynamicValue(ctx => new core_1.RpcConnectionHandler(browser_automation_protocol_1.browserAutomationPath, client => {
|
|
@@ -37,5 +39,7 @@ exports.default = new inversify_1.ContainerModule(bind => {
|
|
|
37
39
|
bind(core_1.PreferenceContribution).toConstantValue({ schema: workspace_preferences_1.WorkspacePreferencesSchema });
|
|
38
40
|
bind(core_1.PreferenceContribution).toConstantValue({ schema: ai_configuration_preferences_1.AiConfigurationPreferences });
|
|
39
41
|
bind(connection_container_module_1.ConnectionContainerModule).toConstantValue(browserAutomationModule);
|
|
42
|
+
bind(github_repo_protocol_1.GitHubRepoService).to(github_repo_service_impl_1.GitHubRepoServiceImpl).inSingletonScope();
|
|
43
|
+
bind(core_1.ConnectionHandler).toDynamicValue(ctx => new core_1.RpcConnectionHandler(github_repo_protocol_1.githubRepoServicePath, () => ctx.container.get(github_repo_protocol_1.GitHubRepoService))).inSingletonScope();
|
|
40
44
|
});
|
|
41
45
|
//# 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,sCAA8F;AAC9F,4DAA+D;AAC/D,uFAA+H;AAC/H,wFAAmF;AACnF,4GAAuG;AACvG,2EAA6E;AAC7E,yFAAoF;AACpF,qEAAqE;
|
|
1
|
+
{"version":3,"file":"backend-module.js","sourceRoot":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AC,CAAC,eAAe,CAAC,EAAE,MAAM,EAAE,kDAA0B,EAAE,CAAC,CAAC;IACrF,IAAI,CAAC,6BAAsB,CAAC,CAAC,eAAe,CAAC,EAAE,MAAM,EAAE,yDAA0B,EAAE,CAAC,CAAC;IAErF,IAAI,CAAC,uDAAyB,CAAC,CAAC,eAAe,CAAC,uBAAuB,CAAC,CAAC;IAEzE,IAAI,CAAC,wCAAiB,CAAC,CAAC,EAAE,CAAC,gDAAqB,CAAC,CAAC,gBAAgB,EAAE,CAAC;IACrE,IAAI,CAAC,wBAAiB,CAAC,CAAC,cAAc,CAAC,GAAG,CAAC,EAAE,CACzC,IAAI,2BAAoB,CAAC,4CAAqB,EAAE,GAAG,EAAE,CAAC,GAAG,CAAC,SAAS,CAAC,GAAG,CAAoB,wCAAiB,CAAC,CAAC,CACjH,CAAC,gBAAgB,EAAE,CAAC;AAEzB,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { GitHubRepoService, GitHubRepoInfo } from '../common/github-repo-protocol';
|
|
2
|
+
export declare class GitHubRepoServiceImpl implements GitHubRepoService {
|
|
3
|
+
getGitHubRepoInfo(workspacePath: string): Promise<GitHubRepoInfo | undefined>;
|
|
4
|
+
private isGitHubRemote;
|
|
5
|
+
private extractRepoInfoFromGitHubUrl;
|
|
6
|
+
}
|
|
7
|
+
//# sourceMappingURL=github-repo-service-impl.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"github-repo-service-impl.d.ts","sourceRoot":"","sources":["../../src/node/github-repo-service-impl.ts"],"names":[],"mappings":"AAkBA,OAAO,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAEnF,qBACa,qBAAsB,YAAW,iBAAiB;IAErD,iBAAiB,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,GAAG,SAAS,CAAC;IAwCnF,OAAO,CAAC,cAAc;IAItB,OAAO,CAAC,4BAA4B;CA8BvC"}
|