genaicode 0.11.0 → 0.12.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/README.md +3 -9
- package/dist/ai-service/ai-studio.d.ts +18 -1
- package/dist/ai-service/ai-studio.js +92 -21
- package/dist/ai-service/ai-studio.js.map +1 -1
- package/dist/ai-service/anthropic.js +59 -25
- package/dist/ai-service/anthropic.js.map +1 -1
- package/dist/ai-service/common-types.d.ts +8 -3
- package/dist/ai-service/common.d.ts +5 -1
- package/dist/ai-service/common.js +9 -0
- package/dist/ai-service/common.js.map +1 -1
- package/dist/ai-service/dall-e.js +1 -0
- package/dist/ai-service/dall-e.js.map +1 -1
- package/dist/ai-service/github-models.d.ts +13 -0
- package/dist/ai-service/github-models.js +51 -0
- package/dist/ai-service/github-models.js.map +1 -0
- package/dist/ai-service/local-llm.js +2 -1
- package/dist/ai-service/local-llm.js.map +1 -1
- package/dist/ai-service/openai-responses.d.ts +9 -0
- package/dist/ai-service/openai-responses.js +286 -0
- package/dist/ai-service/openai-responses.js.map +1 -0
- package/dist/ai-service/openai.js +22 -10
- package/dist/ai-service/openai.js.map +1 -1
- package/dist/ai-service/service-configurations-types.d.ts +7 -7
- package/dist/ai-service/service-configurations.d.ts +1 -0
- package/dist/ai-service/service-configurations.js +41 -36
- package/dist/ai-service/service-configurations.js.map +1 -1
- package/dist/ai-service/vertex-ai-claude.js +2 -2
- package/dist/ai-service/vertex-ai-claude.js.map +1 -1
- package/dist/ai-service/vertex-ai.d.ts +1 -0
- package/dist/ai-service/vertex-ai.js +4 -332
- package/dist/ai-service/vertex-ai.js.map +1 -1
- package/dist/cli/cli-options.js +1 -1
- package/dist/cli/cli-options.js.map +1 -1
- package/dist/cli/validate-cli-params.js +1 -1
- package/dist/cli/validate-cli-params.js.map +1 -1
- package/dist/files/cache-file.d.ts +4 -0
- package/dist/files/cache-file.js +21 -0
- package/dist/files/cache-file.js.map +1 -1
- package/dist/files/find-files.d.ts +1 -0
- package/dist/files/find-files.js +4 -1
- package/dist/files/find-files.js.map +1 -1
- package/dist/files/source-code-utils.js +1 -1
- package/dist/files/summary-cache.d.ts +1 -1
- package/dist/files/summary-cache.js +1 -1
- package/dist/files/summary-cache.js.map +1 -1
- package/dist/main/codegen-utils.d.ts +6 -1
- package/dist/main/codegen-utils.js +21 -2
- package/dist/main/codegen-utils.js.map +1 -1
- package/dist/main/codegen.js +2 -2
- package/dist/main/codegen.js.map +1 -1
- package/dist/main/common/content-bus-types.d.ts +17 -1
- package/dist/main/common/content-bus.d.ts +3 -1
- package/dist/main/common/content-bus.js +23 -1
- package/dist/main/common/content-bus.js.map +1 -1
- package/dist/main/common/user-actions.d.ts +3 -0
- package/dist/main/common/user-actions.js +10 -0
- package/dist/main/common/user-actions.js.map +1 -1
- package/dist/main/config-lib.js +3 -2
- package/dist/main/config-lib.js.map +1 -1
- package/dist/main/config-types.d.ts +4 -0
- package/dist/main/config.js +4 -0
- package/dist/main/config.js.map +1 -1
- package/dist/main/interactive/select-ai-service.js +0 -1
- package/dist/main/interactive/select-ai-service.js.map +1 -1
- package/dist/main/interactive/user-action-handlers.js +7 -2
- package/dist/main/interactive/user-action-handlers.js.map +1 -1
- package/dist/main/knowledge/knowledge-store.d.ts +6 -0
- package/dist/main/knowledge/knowledge-store.js +128 -0
- package/dist/main/knowledge/knowledge-store.js.map +1 -0
- package/dist/main/knowledge/types.d.ts +20 -0
- package/dist/main/knowledge/types.js +2 -0
- package/dist/main/knowledge/types.js.map +1 -0
- package/dist/main/ui/backend/endpoints/interrupt-execution-endpoint.js +17 -3
- package/dist/main/ui/backend/endpoints/interrupt-execution-endpoint.js.map +1 -1
- package/dist/main/ui/common/api-types.d.ts +67 -4
- package/dist/main/ui/common/api-types.js +12 -1
- package/dist/main/ui/common/api-types.js.map +1 -1
- package/dist/main/ui/frontend/assets/index-BbIYZZub.js +2635 -0
- package/dist/main/ui/frontend/index.html +1 -1
- package/dist/main/ui/user-action-handlers.js +7 -1
- package/dist/main/ui/user-action-handlers.js.map +1 -1
- package/dist/project-profiles/types.d.ts +4 -4
- package/dist/project-profiles/types.js +4 -4
- package/dist/project-profiles/types.js.map +1 -1
- package/dist/prompt/function-calling-validate.js +2 -1
- package/dist/prompt/function-calling-validate.js.map +1 -1
- package/dist/prompt/function-calling.js +4 -0
- package/dist/prompt/function-calling.js.map +1 -1
- package/dist/prompt/function-defs/ask-question.js +4 -0
- package/dist/prompt/function-defs/ask-question.js.map +1 -1
- package/dist/prompt/function-defs/container-task-commands.d.ts +10 -0
- package/dist/prompt/function-defs/container-task-commands.js +185 -0
- package/dist/prompt/function-defs/container-task-commands.js.map +1 -0
- package/dist/prompt/function-defs/run-container-task.d.ts +11 -0
- package/dist/prompt/function-defs/run-container-task.js +41 -0
- package/dist/prompt/function-defs/run-container-task.js.map +1 -0
- package/dist/prompt/function-defs/web-search.d.ts +9 -0
- package/dist/prompt/function-defs/web-search.js +16 -0
- package/dist/prompt/function-defs/web-search.js.map +1 -0
- package/dist/prompt/limits.js +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/container-task/command-execution-loop.d.ts +7 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/command-execution-loop.js +301 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/command-execution-loop.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/check-context.d.ts +12 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/check-context.js +41 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/check-context.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/complete-task.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/complete-task.js +49 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/complete-task.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/copy-from-container.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/copy-from-container.js +190 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/copy-from-container.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/copy-to-container.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/copy-to-container.js +139 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/copy-to-container.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/edit-file.d.ts +10 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/edit-file.js +93 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/edit-file.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/fail-task.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/fail-task.js +72 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/fail-task.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/gain-knowledge.d.ts +10 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/gain-knowledge.js +125 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/gain-knowledge.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/interrupt-controller.d.ts +19 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/interrupt-controller.js +33 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/interrupt-controller.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/query-knowledge.d.ts +8 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/query-knowledge.js +85 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/query-knowledge.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/request-secret.d.ts +6 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/request-secret.js +122 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/request-secret.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/run-command.d.ts +7 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/run-command.js +146 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/run-command.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/send-message.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/send-message.js +56 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/send-message.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/set-execution-plan.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/set-execution-plan.js +56 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/set-execution-plan.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/update-execution-plan.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/update-execution-plan.js +39 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/update-execution-plan.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/view-file.d.ts +10 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/view-file.js +95 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/view-file.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/web-search.d.ts +2 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/web-search.js +96 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/web-search.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/wrap-context.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/wrap-context.js +123 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/commands/wrap-context.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-command-handlers.d.ts +34 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-command-handlers.js +332 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-command-handlers.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-commands-registry.d.ts +11 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-commands-registry.js +50 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-commands-registry.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-commands-types.d.ts +28 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-commands-types.js +2 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-commands-types.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-task-orchestrator.d.ts +2 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-task-orchestrator.js +202 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-task-orchestrator.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-task-types.d.ts +52 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-task-types.js +2 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/container-task-types.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/utils/docker-check.d.ts +4 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/utils/docker-check.js +15 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/utils/docker-check.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/utils/docker-utils.d.ts +50 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/utils/docker-utils.js +358 -0
- package/dist/prompt/steps/step-ask-question/handlers/container-task/utils/docker-utils.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/handle-compound-action.js +2 -2
- package/dist/prompt/steps/step-ask-question/handlers/handle-compound-action.js.map +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-explore-external-directories.js +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-explore-external-directories.js.map +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-genaicode-help.js +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-genaicode-help.js.map +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-generate-image.js +2 -2
- package/dist/prompt/steps/step-ask-question/handlers/handle-generate-image.js.map +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-perform-analysis.js +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-perform-analysis.js.map +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-run-container-task.d.ts +2 -0
- package/dist/prompt/steps/step-ask-question/handlers/handle-run-container-task.js +7 -0
- package/dist/prompt/steps/step-ask-question/handlers/handle-run-container-task.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/handle-send-message.js +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-send-message.js.map +1 -1
- package/dist/prompt/steps/step-ask-question/handlers/handle-web-search.d.ts +1 -0
- package/dist/prompt/steps/step-ask-question/handlers/handle-web-search.js +85 -0
- package/dist/prompt/steps/step-ask-question/handlers/handle-web-search.js.map +1 -0
- package/dist/prompt/steps/step-ask-question/step-ask-question-types.d.ts +1 -1
- package/dist/prompt/steps/step-ask-question/step-ask-question.d.ts +2 -0
- package/dist/prompt/steps/step-ask-question/step-ask-question.js +11 -1
- package/dist/prompt/steps/step-ask-question/step-ask-question.js.map +1 -1
- package/dist/prompt/steps/step-codegen-planning.js +1 -1
- package/dist/prompt/steps/step-codegen-planning.js.map +1 -1
- package/dist/prompt/steps/step-summarization.js +17 -10
- package/dist/prompt/steps/step-summarization.js.map +1 -1
- package/dist/prompt/systemprompt.js +3 -0
- package/dist/prompt/systemprompt.js.map +1 -1
- package/dist/utils/docker-utils.d.ts +37 -0
- package/dist/utils/docker-utils.js +258 -0
- package/dist/utils/docker-utils.js.map +1 -0
- package/dist/vite-genaicode/vite-genaicode-plugin.js +9 -2
- package/dist/vite-genaicode/vite-genaicode-plugin.js.map +1 -1
- package/package.json +12 -4
- package/dist/main/ui/frontend/assets/index-C1H0vVGm.js +0 -2256
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
<meta name="keywords" content="GenAIcode, AI, code generation, programming" />
|
|
8
8
|
<title>GenAIcode - AI-Powered Code Generation</title>
|
|
9
9
|
<link rel="icon" href="/assets/favicon-DvroFOpS.png" type="image/png" />
|
|
10
|
-
<script type="module" crossorigin src="/assets/index-
|
|
10
|
+
<script type="module" crossorigin src="/assets/index-BbIYZZub.js"></script>
|
|
11
11
|
<link rel="stylesheet" crossorigin href="/assets/index-5QDg_0vR.css">
|
|
12
12
|
</head>
|
|
13
13
|
<body data-security-token="__SECURITY_TOKEN__">
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { registerConfirmHandler, registerInputHandler } from '../common/user-actions.js';
|
|
1
|
+
import { registerConfirmHandler, registerInputHandler, registerSecretHandler } from '../common/user-actions.js';
|
|
2
2
|
export function registerUserActionHandlers(service) {
|
|
3
3
|
registerInputHandler((_, message) => service.askQuestion(message, undefined));
|
|
4
4
|
registerConfirmHandler(async (props) => {
|
|
@@ -10,5 +10,11 @@ export function registerUserActionHandlers(service) {
|
|
|
10
10
|
});
|
|
11
11
|
return response;
|
|
12
12
|
});
|
|
13
|
+
registerSecretHandler(async (prompt) => {
|
|
14
|
+
const res = await service.askQuestion(prompt, {
|
|
15
|
+
secret: true,
|
|
16
|
+
});
|
|
17
|
+
return res?.answer || undefined;
|
|
18
|
+
});
|
|
13
19
|
}
|
|
14
20
|
//# sourceMappingURL=user-action-handlers.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user-action-handlers.js","sourceRoot":"","sources":["../../../src/main/ui/user-action-handlers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"user-action-handlers.js","sourceRoot":"","sources":["../../../src/main/ui/user-action-handlers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAGhH,MAAM,UAAU,0BAA0B,CAAC,OAAgB;IACzD,oBAAoB,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,WAAW,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC;IAC9E,sBAAsB,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE;QACrC,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,WAAW,CAAC,KAAK,CAAC,MAAM,EAAE;YACvD,YAAY,EAAE,KAAK,CAAC,YAAY;YAChC,aAAa,EAAE,KAAK,CAAC,aAAa;YAClC,YAAY,EAAE,KAAK,CAAC,YAAY;YAChC,YAAY,EAAE,KAAK,CAAC,YAAY;SACjC,CAAC,CAAC;QACH,OAAO,QAAQ,CAAC;IAClB,CAAC,CAAC,CAAC;IACH,qBAAqB,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE;QACrC,MAAM,GAAG,GAAG,MAAM,OAAO,CAAC,WAAW,CAAC,MAAM,EAAE;YAC5C,MAAM,EAAE,IAAI;SACb,CAAC,CAAC;QACH,OAAO,GAAG,EAAE,MAAM,IAAI,SAAS,CAAC;IAClC,CAAC,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -106,10 +106,10 @@ export declare const DETECTION_WEIGHTS: {
|
|
|
106
106
|
* Default extensions for common project types
|
|
107
107
|
*/
|
|
108
108
|
export declare const DEFAULT_EXTENSIONS: {
|
|
109
|
-
readonly JS: readonly [".js", ".ts", ".jsx", ".tsx", ".mjs", ".mts", ".cjs", ".json", ".md", ".css", ".scss", ".html"];
|
|
110
|
-
readonly JAVA: readonly [".java", ".xml", ".properties", ".md"];
|
|
111
|
-
readonly PYTHON: readonly [".py", ".pyi", ".pyw", ".md"];
|
|
112
|
-
readonly GO: readonly [".go", ".mod", ".sum", ".md"];
|
|
109
|
+
readonly JS: readonly [".js", ".ts", ".jsx", ".tsx", ".mjs", ".mts", ".cjs", ".json", ".md", ".css", ".scss", ".html", ".txt"];
|
|
110
|
+
readonly JAVA: readonly [".java", ".xml", ".properties", ".md", ".txt"];
|
|
111
|
+
readonly PYTHON: readonly [".py", ".pyi", ".pyw", ".md", ".txt"];
|
|
112
|
+
readonly GO: readonly [".go", ".mod", ".sum", ".md", ".txt"];
|
|
113
113
|
};
|
|
114
114
|
/**
|
|
115
115
|
* Default ignore paths for common project types
|
|
@@ -60,10 +60,10 @@ export const DETECTION_WEIGHTS = {
|
|
|
60
60
|
* Default extensions for common project types
|
|
61
61
|
*/
|
|
62
62
|
export const DEFAULT_EXTENSIONS = {
|
|
63
|
-
JS: ['.js', '.ts', '.jsx', '.tsx', '.mjs', '.mts', '.cjs', '.json', '.md', '.css', '.scss', '.html'],
|
|
64
|
-
JAVA: ['.java', '.xml', '.properties', '.md'],
|
|
65
|
-
PYTHON: ['.py', '.pyi', '.pyw', '.md'],
|
|
66
|
-
GO: ['.go', '.mod', '.sum', '.md'],
|
|
63
|
+
JS: ['.js', '.ts', '.jsx', '.tsx', '.mjs', '.mts', '.cjs', '.json', '.md', '.css', '.scss', '.html', '.txt'],
|
|
64
|
+
JAVA: ['.java', '.xml', '.properties', '.md', '.txt'],
|
|
65
|
+
PYTHON: ['.py', '.pyi', '.pyw', '.md', '.txt'],
|
|
66
|
+
GO: ['.go', '.mod', '.sum', '.md', '.txt'],
|
|
67
67
|
};
|
|
68
68
|
/**
|
|
69
69
|
* Default ignore paths for common project types
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/project-profiles/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AA4DH;;GAEG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACnC,qCAAqC;IACrC,EAAE,EAAE;QACF,GAAG,EAAE,cAAc;QACnB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,gBAAgB;QACtB,KAAK,EAAE,CAAC,aAAa,EAAE,aAAa,EAAE,aAAa,EAAE,aAAa,CAAC;QACnE,IAAI,EAAE,gBAAgB;QACtB,IAAI,EAAE,gBAAgB;KACvB;IACD,oBAAoB;IACpB,IAAI,EAAE;QACJ,KAAK,EAAE,SAAS;QAChB,MAAM,EAAE,cAAc;QACtB,MAAM,EAAE,wBAAwB;KACjC;IACD,sBAAsB;IACtB,MAAM,EAAE;QACN,MAAM,EAAE,WAAW;QACnB,KAAK,EAAE,CAAC,QAAQ,EAAE,SAAS,CAAC;QAC5B,YAAY,EAAE,kBAAkB;QAChC,MAAM,EAAE,gBAAgB;KACzB;IACD,kBAAkB;IAClB,EAAE,EAAE;QACF,GAAG,EAAE,QAAQ;QACb,IAAI,EAAE,SAAS;KAChB;CACO,CAAC;AAEX;;GAEG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG;IAC/B,6BAA6B;IAC7B,IAAI,EAAE;QACJ,MAAM,EAAE,CAAC;QACT,SAAS,EAAE,CAAC;QACZ,WAAW,EAAE,CAAC;QACd,OAAO,EAAE,CAAC;KACX;IACD,iCAAiC;IACjC,SAAS,EAAE;QACT,KAAK,EAAE,CAAC;QACR,IAAI,EAAE,CAAC;QACP,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,CAAC;KACV;IACD,oCAAoC;IACpC,iBAAiB,EAAE,EAAE;CACb,CAAC;AAEX;;GAEG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,EAAE,EAAE,CAAC,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/project-profiles/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AA4DH;;GAEG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACnC,qCAAqC;IACr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AAK,EAAE,UAAU,CAAC,CAAC,CAAC;gBAChD,CAAC;YACH,CAAC;QACH,CAAC;QAED,OAAO,MAAM,CAAC;IAChB,CAAC;IAED,SAAS,YAAY,CAAC,KAAa,EAAE,GAAW;QAC9C,MAAM,MAAM,GAAsB,EAAE,CAAC;QACrC,MAAM,cAAc,GAAG,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC;QAC7C,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE,CAAC;YAC5B,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC,cAAc,KAAK,oBAAoB,EAAE,IAAI,EAAE,GAAG,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;QACvF,CAAC;aAAM,IAAI,CAAC,cAAc,CAAC,UAAU,CAAC,OAAO,CAAC,EAAE,CAAC;YAC/C,MAAM,CAAC,IAAI,CACT,SAAS,CAAC,cAAc,KAAK,uCAAuC,OAAO,IAAI,EAAE,IAAI,EAAE,GAAG,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CACtG,CAAC;QACJ,CAAC;QACD,OAAO,MAAM,CAAC;IAChB,CAAC;IAED,MAAM,MAAM,GAAG,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACrC,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACtB,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,EAAqB,CAAC;IACrD,CAAC;IAED,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,SAAS,cAAc,CAAC,IAAY;IAClC,OAAO;QACL,UAAU;QACV,QAAQ;QACR,aAAa;QACb,eAAe;QACf,gBAAgB;QAChB,cAAc;QACd,WAAW;QACX,qBAAqB;QACrB,iBAAiB;
|
|
1
|
+
{"version":3,"file":"function-calling-validate.js","sourceRoot":"","sources":["../../src/prompt/function-calling-validate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAA4C,MAAM,YA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AC;IACrC,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACtB,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,EAAqB,CAAC;IACrD,CAAC;IAED,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,SAAS,cAAc,CAAC,IAAY;IAClC,OAAO;QACL,UAAU;QACV,QAAQ;QACR,aAAa;QACb,eAAe;QACf,gBAAgB;QAChB,cAAc;QACd,WAAW;QACX,qBAAqB;QACrB,iBAAiB;QACjB,UAAU;KACX,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;AACnB,CAAC;AAED,SAAS,SAAS,CAAC,OAAe,EAAE,IAA+C,EAAE,YAAoB;IACvG,OAAO;QACL,MAAM,EAAE;YACN;gBACE,OAAO;aACsB;SAChC;QACD,KAAK,EAAE,KAAK;QACZ,QAAQ,EAAE,IAAI;QACd,MAAM,EAAE,EAAY;QACpB,YAAY;QACZ,aAAa,EAAE,KAAK;QACpB,UAAU,EAAE,IAAI;KACjB,CAAC;AACJ,CAAC"}
|
|
@@ -22,6 +22,8 @@ import { conversationSummaryDef } from './function-defs/conversation-summary.js'
|
|
|
22
22
|
import { readExternalFiles } from './function-defs/read-external-files.js';
|
|
23
23
|
import { exploreExternalDirectories } from './function-defs/explore-external-directories.js';
|
|
24
24
|
import { getCompoundActionDef } from './function-defs/compound-action.js';
|
|
25
|
+
import { runContainerTaskDef } from './function-defs/run-container-task.js';
|
|
26
|
+
import { webSearchDef } from './function-defs/web-search.js';
|
|
25
27
|
/**
|
|
26
28
|
* Function definitions for function calling feature
|
|
27
29
|
*/
|
|
@@ -62,6 +64,8 @@ export function getFunctionDefs() {
|
|
|
62
64
|
exploreExternalDirectories,
|
|
63
65
|
requestGitContextDef,
|
|
64
66
|
getCompoundActionDef(),
|
|
67
|
+
runContainerTaskDef,
|
|
68
|
+
webSearchDef,
|
|
65
69
|
...getOperationDefs(),
|
|
66
70
|
].map((fd) => {
|
|
67
71
|
if (!disableExplanations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,gBAAgB,EAAE;KACtB,CAAC,GAAG,CAAC,CAAC,EAAe,EAAE,EAAE;QACxB,IACE,CAAC,mBAAmB;YACpB,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC,WAAW;YACpC,CAAC,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,QAAQ,CAAC,aAAa,CAAC,EAC/C,CAAC;YACD,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC;QAChD,CAAC;aAAM,IAAI,mBAAmB,EAAE,CAAC;YAC/B,OAAO,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC,WAAW,CAAC;QAC9C,CAAC;QAED,OAAO,EAAE,CAAC;IACZ,CAAC,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -21,6 +21,7 @@ ${rcConfig.featuresEnabled?.gitContext !== false ? '- requestGitContext: Use to
|
|
|
21
21
|
- contextOptimization: Use to manage and optimize context during code generation tasks, allowing the LLM to provide guidance on what parts of the context are most relevant to keep.
|
|
22
22
|
- contextCompression: Use to compress the context by removing unnecessary tokens and optimizing the context size while maintaining essential information.
|
|
23
23
|
- searchCode: Use to search through source code files with flexible filtering. Supports searching in file contents and names, with pattern matching and case sensitivity options. Useful for finding specific code patterns or references across the codebase.
|
|
24
|
+
- webSearch: Use to get a grounded answer with URLs via web search. Provide an exhaustive prompt for the best results.
|
|
24
25
|
- confirmCodeGeneration: Use to confirm with the user before starting the main, multi-step code generation workflow for implementing features or significant code changes requiring analysis and potentially intertwined modifications across multiple files.
|
|
25
26
|
- endConversation: Use to stop the conversation.
|
|
26
27
|
- requestFilesFragments: Use to request fragments (specific parts) of files based on a given prompt. This is useful when you need only certain sections of files, not their entire content.
|
|
@@ -34,6 +35,7 @@ ${rcConfig.lintCommand ? '- lint: Use to check the code for errors and provide f
|
|
|
34
35
|
${pluginDescriptions}
|
|
35
36
|
- genaicodeHelp: Use to provide help to the user on how to use GenAIcode. The response will be grounded in the content of GenAIcode's documentation.
|
|
36
37
|
- reasoningInference: Use to perform an inference on a reasoning model. Should be used when a in-depth reasoning is needed for a specific problem.
|
|
38
|
+
${rcConfig.featuresEnabled?.containerTask ? '- runContainerTask: Use to perform a complex task inside a Docker container. Before task is started, the user will be asked for confirmation. During the task, the user will be kept informed about the progress and any issues that arise. The user can also interrupt the task, and provide input if needed. User can be asked for feedback on the task at any time.' : ''}
|
|
37
39
|
|
|
38
40
|
This value must be derived from the value of \`decisionMakingProcess\` parameter, and must be one of the above values.`;
|
|
39
41
|
}
|
|
@@ -52,11 +54,13 @@ export const actionTypeOptions = [
|
|
|
52
54
|
'contextOptimization',
|
|
53
55
|
'contextCompression',
|
|
54
56
|
'searchCode',
|
|
57
|
+
'webSearch',
|
|
55
58
|
'confirmCodeGeneration',
|
|
56
59
|
'endConversation',
|
|
57
60
|
'requestFilesFragments',
|
|
58
61
|
...(rcConfig.featuresEnabled?.appContext ? ['pullAppContext', 'pushAppContext'] : []),
|
|
59
62
|
...(rcConfig.lintCommand ? ['lint'] : []),
|
|
63
|
+
...(rcConfig.featuresEnabled?.containerTask ? ['runContainerTask'] : []),
|
|
60
64
|
...Array.from(getRegisteredActionHandlers().keys()),
|
|
61
65
|
'genaicodeHelp',
|
|
62
66
|
'reasoningInference',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ask-question.js","sourceRoot":"","sources":["../../../src/prompt/function-defs/ask-question.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,sCAAsC,EAAE,2BAA2B,EAAE,MAAM,6BAA6B,CAAC;AAElH,SAAS,wBAAwB;IAC/B,MAAM,kBAAkB,GAAG,KAAK,CAAC,IAAI,CAAC,sCAAsC,EAAE,CAAC,OAAO,EAAE,CAAC;SACtF,GAAG,CAAC,CAAC,CAAC,UAAU,EAAE,WAAW,CAAC,EAAE,EAAE,CAAC,MAAM,UAAU,KAAK,WAAW,EAAE,CAAC;SACtE,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EAAE,QAAQ;QACd,UAAU,EAAE;YACV,WAAW,EAAE;gBACX,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE,CAAC,SAAS,EAAE,aAAa,EAAE,OAAO,EAAE,UAAU,CAAC;gBACrD,WAAW,EAAE,yCAAyC;aACvD;YACD,QAAQ,EAAE;gBACR,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,sFAAsF;aACpG;YACD,UAAU,EAAE;gBACV,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,+DAA+D;aAC7E;YACD,KAAK,EAAE;gBACL,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,kEAAkE;aAChF;SACF;QACD,QAAQ,EAAE,CAAC,aAAa,CAAC;KAC1B;CACF,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { FunctionDef } from '../../ai-service/common-types.js';
|
|
2
|
+
export declare const runCommandDef: FunctionDef;
|
|
3
|
+
export declare const completeTaskDef: FunctionDef;
|
|
4
|
+
export declare const failTaskDef: FunctionDef;
|
|
5
|
+
export declare const wrapContextDef: FunctionDef;
|
|
6
|
+
export declare const setExecutionPlanDef: FunctionDef;
|
|
7
|
+
export declare const updateExecutionPlanDef: FunctionDef;
|
|
8
|
+
export declare const getCopyToContainerDef: () => FunctionDef;
|
|
9
|
+
export declare const getCopyFromContainerDef: () => FunctionDef;
|
|
10
|
+
export declare const sendMessageDef: FunctionDef;
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
import { rcConfig } from '../../main/config.js';
|
|
2
|
+
export const runCommandDef = {
|
|
3
|
+
name: 'runCommand',
|
|
4
|
+
description: `Execute a shell command in the Docker container.
|
|
5
|
+
IMPORTANT:
|
|
6
|
+
- The command will block you until it completes, so consider using a non-blocking approach if needed.
|
|
7
|
+
- For complex/long input you should prefer \`stdin\` over command-line arguments. For example instead of echo \`some long text\`, you can put the long text in the \`stdin\` field, and then use it in the command like this: \`cat | some_command\`.
|
|
8
|
+
`,
|
|
9
|
+
parameters: {
|
|
10
|
+
type: 'object',
|
|
11
|
+
properties: {
|
|
12
|
+
reasoning: {
|
|
13
|
+
type: 'string',
|
|
14
|
+
description: 'Explanation of why this command is needed for the task.',
|
|
15
|
+
},
|
|
16
|
+
command: {
|
|
17
|
+
type: 'string',
|
|
18
|
+
description: 'The shell command to execute in the container. Command must be 256 characters or less. If there is a need for a longer command, consider using a script file, and consider using `stdin` to pass the script contents.',
|
|
19
|
+
maxLength: 256,
|
|
20
|
+
},
|
|
21
|
+
stdin: {
|
|
22
|
+
type: 'string',
|
|
23
|
+
description: 'Input to provide to the command via stdin. Equivalent of `echo <stdin> | <command>`. Very good for long inputs, better than passing as command-line arguments in the command string parameter.',
|
|
24
|
+
},
|
|
25
|
+
truncMode: {
|
|
26
|
+
type: 'string',
|
|
27
|
+
description: 'Mode for truncating command output (e.g., "start", "end").',
|
|
28
|
+
enum: ['start', 'end'],
|
|
29
|
+
},
|
|
30
|
+
workingDir: {
|
|
31
|
+
type: 'string',
|
|
32
|
+
description: 'Working directory inside the container to run the command in. This MUST be an absolute path.',
|
|
33
|
+
minLength: 1,
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
required: ['reasoning', 'command', 'stdin', 'workingDir', 'truncMode'],
|
|
37
|
+
},
|
|
38
|
+
};
|
|
39
|
+
export const completeTaskDef = {
|
|
40
|
+
name: 'completeTask',
|
|
41
|
+
description: 'Mark the container task as successfully completed.',
|
|
42
|
+
parameters: {
|
|
43
|
+
type: 'object',
|
|
44
|
+
properties: {
|
|
45
|
+
summary: {
|
|
46
|
+
type: 'string',
|
|
47
|
+
description: 'A brief summary of what was accomplished.',
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
required: ['summary'],
|
|
51
|
+
},
|
|
52
|
+
};
|
|
53
|
+
export const failTaskDef = {
|
|
54
|
+
name: 'failTask',
|
|
55
|
+
description: 'Mark the container task as failed.',
|
|
56
|
+
parameters: {
|
|
57
|
+
type: 'object',
|
|
58
|
+
properties: {
|
|
59
|
+
reason: {
|
|
60
|
+
type: 'string',
|
|
61
|
+
description: 'Explanation of why the task failed.',
|
|
62
|
+
},
|
|
63
|
+
},
|
|
64
|
+
required: ['reason'],
|
|
65
|
+
},
|
|
66
|
+
};
|
|
67
|
+
export const wrapContextDef = {
|
|
68
|
+
name: 'wrapContext',
|
|
69
|
+
description: 'Replace prior conversation in the loop with a concise summary for continued processing.',
|
|
70
|
+
parameters: {
|
|
71
|
+
type: 'object',
|
|
72
|
+
properties: {
|
|
73
|
+
summary: {
|
|
74
|
+
type: 'string',
|
|
75
|
+
description: 'A summary of prior steps and important findings to keep for next actions.',
|
|
76
|
+
},
|
|
77
|
+
plan: {
|
|
78
|
+
type: 'string',
|
|
79
|
+
description: 'A concise plan outlining the plan of action for the task.',
|
|
80
|
+
},
|
|
81
|
+
progress: {
|
|
82
|
+
type: 'string',
|
|
83
|
+
description: 'What was achieved so far? What are the outcomes?',
|
|
84
|
+
},
|
|
85
|
+
importantFiles: {
|
|
86
|
+
type: 'array',
|
|
87
|
+
items: {
|
|
88
|
+
type: 'string',
|
|
89
|
+
description: `Paths to important files to keep for next actions.
|
|
90
|
+
It is critically IMPORTANT to keep track of files which are essential for the task. For example the files that were modified or created during the task so far.`,
|
|
91
|
+
},
|
|
92
|
+
},
|
|
93
|
+
nextStep: {
|
|
94
|
+
type: 'string',
|
|
95
|
+
description: 'The next step to take in the process.',
|
|
96
|
+
},
|
|
97
|
+
},
|
|
98
|
+
required: ['summary', 'plan', 'progress', 'importantFiles', 'nextStep'],
|
|
99
|
+
},
|
|
100
|
+
};
|
|
101
|
+
export const setExecutionPlanDef = {
|
|
102
|
+
name: 'setExecutionPlan',
|
|
103
|
+
description: 'Record a concise execution plan to follow in subsequent steps.',
|
|
104
|
+
parameters: {
|
|
105
|
+
type: 'object',
|
|
106
|
+
properties: {
|
|
107
|
+
plan: {
|
|
108
|
+
type: 'string',
|
|
109
|
+
description: 'Brief execution plan (high level outline).',
|
|
110
|
+
},
|
|
111
|
+
},
|
|
112
|
+
required: ['plan'],
|
|
113
|
+
},
|
|
114
|
+
};
|
|
115
|
+
export const updateExecutionPlanDef = {
|
|
116
|
+
name: 'updateExecutionPlan',
|
|
117
|
+
description: 'Update progress/status against the previously set execution plan.',
|
|
118
|
+
parameters: {
|
|
119
|
+
type: 'object',
|
|
120
|
+
properties: {
|
|
121
|
+
progress: {
|
|
122
|
+
type: 'string',
|
|
123
|
+
description: 'Progress update and next steps if applicable.',
|
|
124
|
+
},
|
|
125
|
+
},
|
|
126
|
+
required: ['progress'],
|
|
127
|
+
},
|
|
128
|
+
};
|
|
129
|
+
export const getCopyToContainerDef = () => ({
|
|
130
|
+
name: 'copyToContainer',
|
|
131
|
+
description: 'Copy a file or directory from the host to the container.',
|
|
132
|
+
parameters: {
|
|
133
|
+
type: 'object',
|
|
134
|
+
properties: {
|
|
135
|
+
hostPath: {
|
|
136
|
+
type: 'string',
|
|
137
|
+
description: `The absolute path of the file or directory on the host machine, which must be within the project root directory.
|
|
138
|
+
The file path must start from: ${rcConfig.rootDir}`,
|
|
139
|
+
},
|
|
140
|
+
containerPath: {
|
|
141
|
+
type: 'string',
|
|
142
|
+
description: 'The absolute destination path inside the container.',
|
|
143
|
+
},
|
|
144
|
+
},
|
|
145
|
+
required: ['hostPath', 'containerPath'],
|
|
146
|
+
},
|
|
147
|
+
});
|
|
148
|
+
export const getCopyFromContainerDef = () => ({
|
|
149
|
+
name: 'copyFromContainer',
|
|
150
|
+
description: 'Copy a file or directory from the container to the host.',
|
|
151
|
+
parameters: {
|
|
152
|
+
type: 'object',
|
|
153
|
+
properties: {
|
|
154
|
+
containerPath: {
|
|
155
|
+
type: 'string',
|
|
156
|
+
description: 'The absolute destination path on the host machine, which must be within the project root directory.',
|
|
157
|
+
},
|
|
158
|
+
hostPath: {
|
|
159
|
+
type: 'string',
|
|
160
|
+
description: `The absolute destination path on the host machine, which must be within the project root directory.
|
|
161
|
+
The file path must start from: ${rcConfig.rootDir}`,
|
|
162
|
+
},
|
|
163
|
+
},
|
|
164
|
+
required: ['containerPath', 'hostPath'],
|
|
165
|
+
},
|
|
166
|
+
});
|
|
167
|
+
export const sendMessageDef = {
|
|
168
|
+
name: 'sendMessage',
|
|
169
|
+
description: 'Send a message to the user. Should be used for non-interactive messages.',
|
|
170
|
+
parameters: {
|
|
171
|
+
type: 'object',
|
|
172
|
+
properties: {
|
|
173
|
+
message: {
|
|
174
|
+
type: 'string',
|
|
175
|
+
description: 'The message to send to the user.',
|
|
176
|
+
},
|
|
177
|
+
isQuestion: {
|
|
178
|
+
type: 'boolean',
|
|
179
|
+
description: 'Whether the message is a question, and user input is expected.',
|
|
180
|
+
},
|
|
181
|
+
},
|
|
182
|
+
required: ['message', 'isQuestion'],
|
|
183
|
+
},
|
|
184
|
+
};
|
|
185
|
+
//# sourceMappingURL=container-task-commands.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"container-task-commands.js","sourceRoot":"","sources":["../../../src/prompt/function-defs/container-task-commands.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD,MAAM,CAAC,MAAM,aAAa,GAAgB;IACxC,IAAI,EAAE,YAAY;IAClB,WAAW,EAAE;;;;GAIZ;IACD,UAAU,EAAE;QACV,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,SAAS,EAAE;gBACT,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,yDAAyD;aACvE;YACD,OAAO,EAAE;gBACP,IAAI,EAAE,QAAQ;gBACd,WAAW,EACT,uNAAuN;gBACzN,SAAS,EAAE,GAAG;aACf;YACD,KAAK,EAAE;gBACL,IAAI,EAAE,QAAQ;gBACd,WAAW,EACT,gMAAgM;aACnM;YACD,SAAS,EAAE;gBACT,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,4DAA4D;gBACzE,IAAI,EAAE,CAAC,OAAO,EAAE,KAAK,CAAC;aACvB;YACD,UAAU,EAAE;gBAC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AsB,GAAG,EAAE,CAAC,CAAC;IAC/D,IAAI,EAAE,mBAAmB;IACzB,WAAW,EAAE,0DAA0D;IACvE,UAAU,EAAE;QACV,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,aAAa,EAAE;gBACb,IAAI,EAAE,QAAQ;gBACd,WAAW,EACT,qGAAqG;aACxG;YACD,QAAQ,EAAE;gBACR,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE;iCACY,QAAQ,CAAC,OAAO,EAAE;aAC5C;SACF;QACD,QAAQ,EAAE,CAAC,eAAe,EAAE,UAAU,CAAC;KACxC;CACF,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,cAAc,GAAgB;IACzC,IAAI,EAAE,aAAa;IACnB,WAAW,EAAE,0EAA0E;IACvF,UAAU,EAAE;QACV,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,OAAO,EAAE;gBACP,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,kCAAkC;aAChD;YACD,UAAU,EAAE;gBACV,IAAI,EAAE,SAAS;gBACf,WAAW,EAAE,gEAAgE;aAC9E;SACF;QACD,QAAQ,EAAE,CAAC,SAAS,EAAE,YAAY,CAAC;KACpC;CACF,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { FunctionDef } from '../../ai-service/common-types.js';
|
|
2
|
+
export type AllowedDockerImage = 'ubuntu:latest' | 'ubuntu:22.04' | 'ubuntu:20.04' | 'alpine:latest' | 'alpine:3.18' | 'node:latest' | 'node:18' | 'node:20' | 'python:latest' | 'python:3.11' | 'python:3.12' | 'ghcr.io/puppeteer/puppeteer:latest';
|
|
3
|
+
export declare const runContainerTaskDef: FunctionDef;
|
|
4
|
+
/**
|
|
5
|
+
* Arguments for the runContainerTask action
|
|
6
|
+
*/
|
|
7
|
+
export type RunContainerTaskArgs = {
|
|
8
|
+
image: AllowedDockerImage;
|
|
9
|
+
taskDescription: string;
|
|
10
|
+
workingDir: string;
|
|
11
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
export const runContainerTaskDef = {
|
|
2
|
+
name: 'runContainerTask',
|
|
3
|
+
description: `Asks user for confirmation, and if confirmed executes a multi-step task safely in a sandboxed Docker container. It starts a a new container in clean state.
|
|
4
|
+
Current project files are NOT automatically available in the container, you need to copy them explicitly if needed.
|
|
5
|
+
You can run multiple commands in the container to accomplish the task. Outcomes can be copied back to the current project on the host machine.`,
|
|
6
|
+
parameters: {
|
|
7
|
+
type: 'object',
|
|
8
|
+
properties: {
|
|
9
|
+
image: {
|
|
10
|
+
type: 'string',
|
|
11
|
+
enum: [
|
|
12
|
+
'ubuntu:latest',
|
|
13
|
+
'ubuntu:22.04',
|
|
14
|
+
'ubuntu:20.04',
|
|
15
|
+
'alpine:latest',
|
|
16
|
+
'alpine:3.18',
|
|
17
|
+
'node:latest',
|
|
18
|
+
'node:18',
|
|
19
|
+
'node:20',
|
|
20
|
+
'python:latest',
|
|
21
|
+
'python:3.11',
|
|
22
|
+
'python:3.12',
|
|
23
|
+
'ghcr.io/puppeteer/puppeteer:latest',
|
|
24
|
+
],
|
|
25
|
+
description: 'The Docker image to use from the allowed list.',
|
|
26
|
+
},
|
|
27
|
+
taskDescription: {
|
|
28
|
+
type: 'string',
|
|
29
|
+
description: `A detailed, natural language description of the entire task to be performed. This guides the command execution loop.
|
|
30
|
+
It is important to provide as much context as possible to ensure successful execution.
|
|
31
|
+
When a task requires current project files to be included, you must explicitly state this in the task description.`,
|
|
32
|
+
},
|
|
33
|
+
workingDir: {
|
|
34
|
+
type: 'string',
|
|
35
|
+
description: `Path of the working directory inside the container, which will be created if it doesn't exist.`,
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
required: ['image', 'taskDescription', 'workingDir'],
|
|
39
|
+
},
|
|
40
|
+
};
|
|
41
|
+
//# sourceMappingURL=run-container-task.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run-container-task.js","sourceRoot":"","sources":["../../../src/prompt/function-defs/run-container-task.ts"],"names":[],"mappings":"AAgBA,MAAM,CAAC,MAAM,mBAAmB,GAAgB;IAC9C,IAAI,EAAE,kBAAkB;IACxB,WAAW,EAAE;;+IAEgI;IAC7I,UAAU,EAAE;QACV,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,KAAK,EAAE;gBACL,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE;oBACJ,eAAe;oBACf,cAAc;oBACd,cAAc;oBACd,eAAe;oBACf,aAAa;oBACb,aAAa;oBACb,SAAS;oBACT,SAAS;oBACT,eAAe;oBACf,aAAa;oBACb,aAAa;oBACb,oCAAoC;iBACrC;gBACD,WAAW,EAAE,gDAAgD;aAC9D;YACD,eAAe,EAAE;gBACf,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE;;mHAE8F;aAC5G;YACD,UAAU,EAAE;gBACV,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,gGAAgG;aAC9G;SACF;QACD,QAAQ,EAAE,CAAC,OAAO,EAAE,iBAAiB,EAAE,YAAY,CAAC;KACrD;CACF,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export const webSearchDef = {
|
|
2
|
+
name: 'webSearch',
|
|
3
|
+
description: `Performs a web search and returns a grounded answer with source URLs.
|
|
4
|
+
The answer is not displayed to the user. It should be used to inform following actions.`,
|
|
5
|
+
parameters: {
|
|
6
|
+
type: 'object',
|
|
7
|
+
properties: {
|
|
8
|
+
query: {
|
|
9
|
+
type: 'string',
|
|
10
|
+
description: 'An exhaustive prompt or question for the web search.',
|
|
11
|
+
},
|
|
12
|
+
},
|
|
13
|
+
required: ['query'],
|
|
14
|
+
},
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=web-search.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-search.js","sourceRoot":"","sources":["../../../src/prompt/function-defs/web-search.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,YAAY,GAAgB;IACvC,IAAI,EAAE,WAAW;IACjB,WAAW,EAAE;wFACyE;IACtF,UAAU,EAAE;QACV,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,KAAK,EAAE;gBACL,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,sDAAsD;aACpE;SACF;QACD,QAAQ,EAAE,CAAC,OAAO,CAAC;KACpB;CACF,CAAC"}
|
package/dist/prompt/limits.js
CHANGED
|
@@ -2,7 +2,7 @@ import assert from 'node:assert';
|
|
|
2
2
|
import { estimateTokenCount } from './token-estimator.js';
|
|
3
3
|
const SYSTEM_PROMPT_LIMIT = 3500;
|
|
4
4
|
const CODEGEN_PROMPT_LIMIT = 1600;
|
|
5
|
-
const SOURCE_CODE_LIMIT =
|
|
5
|
+
const SOURCE_CODE_LIMIT = 300000;
|
|
6
6
|
function verifyPromptLimit(promptType, prompt, limit) {
|
|
7
7
|
const tokenCount = estimateTokenCount(prompt);
|
|
8
8
|
console.log(`${promptType} prompt estimated token count: ${tokenCount}`);
|
package/dist/prompt/steps/step-ask-question/handlers/container-task/command-execution-loop.d.ts
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import Docker from 'dockerode';
|
|
2
|
+
import { ActionHandlerProps } from '../../step-ask-question-types.js';
|
|
3
|
+
import { RunContainerTaskArgs } from '../../../../function-defs/run-container-task.js';
|
|
4
|
+
export declare function commandExecutionLoop(args: RunContainerTaskArgs, container: Docker.Container, taskDescription: string, unsanitizedGenerateContentFn: ActionHandlerProps['generateContentFn'], options: ActionHandlerProps['options'], waitIfPaused: ActionHandlerProps['waitIfPaused']): Promise<{
|
|
5
|
+
success: boolean;
|
|
6
|
+
summary: string;
|
|
7
|
+
}>;
|