repoburg 1.3.140 → 1.3.142
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/backend/.env +2 -1
- package/backend/dist/src/ai-actions/ai-action-batch.service.js +2 -4
- package/backend/dist/src/ai-actions/ai-action-batch.service.js.map +1 -1
- package/backend/dist/src/ai-actions/ai-actions.controller.d.ts +0 -1
- package/backend/dist/src/ai-actions/ai-actions.controller.js +0 -17
- package/backend/dist/src/ai-actions/ai-actions.controller.js.map +1 -1
- package/backend/dist/src/ai-actions/ai-actions.service.d.ts +1 -4
- package/backend/dist/src/ai-actions/ai-actions.service.js +2 -31
- package/backend/dist/src/ai-actions/ai-actions.service.js.map +1 -1
- package/backend/dist/src/application-state/application-state.controller.d.ts +0 -11
- package/backend/dist/src/application-state/application-state.controller.js +0 -52
- package/backend/dist/src/application-state/application-state.controller.js.map +1 -1
- package/backend/dist/src/application-state/application-state.service.d.ts +0 -5
- package/backend/dist/src/application-state/application-state.service.js +1 -29
- package/backend/dist/src/application-state/application-state.service.js.map +1 -1
- package/backend/dist/src/core-entities/session-input.entity.d.ts +0 -4
- package/backend/dist/src/core-entities/session-input.entity.js +1 -35
- package/backend/dist/src/core-entities/session-input.entity.js.map +1 -1
- package/backend/dist/src/core-entities/session.entity.js +1 -1
- package/backend/dist/src/core-entities/session.entity.js.map +1 -1
- package/backend/dist/src/core-entities/system-prompt.entity.js +2 -2
- package/backend/dist/src/core-entities/system-prompt.entity.js.map +1 -1
- package/backend/dist/src/events/websocket.events.d.ts +0 -25
- package/backend/dist/src/events/websocket.events.js +0 -6
- package/backend/dist/src/events/websocket.events.js.map +1 -1
- package/backend/dist/src/global-config/dto/update-global-config.dto.d.ts +0 -1
- package/backend/dist/src/global-config/dto/update-global-config.dto.js +0 -5
- package/backend/dist/src/global-config/dto/update-global-config.dto.js.map +1 -1
- package/backend/dist/src/global-config/global-config.service.d.ts +0 -2
- package/backend/dist/src/global-config/global-config.service.js.map +1 -1
- package/backend/dist/src/interactive-chat/chat.service.d.ts +1 -1
- package/backend/dist/src/interactive-chat/chat.service.js +1 -10
- package/backend/dist/src/interactive-chat/chat.service.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/apply-diff.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/apply-diff.handler.js +5 -7
- package/backend/dist/src/llm-orchestration/action-handlers/apply-diff.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/ask-user.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/ask-user.handler.js +6 -8
- package/backend/dist/src/llm-orchestration/action-handlers/ask-user.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/create-file.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/create-file.handler.js +5 -7
- package/backend/dist/src/llm-orchestration/action-handlers/create-file.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/delete-file.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/delete-file.handler.js +5 -7
- package/backend/dist/src/llm-orchestration/action-handlers/delete-file.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/execute-code.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/execute-code.handler.js +5 -7
- package/backend/dist/src/llm-orchestration/action-handlers/execute-code.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/final.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/final.handler.js +6 -8
- package/backend/dist/src/llm-orchestration/action-handlers/final.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/generate-title.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/generate-title.handler.js +5 -7
- package/backend/dist/src/llm-orchestration/action-handlers/generate-title.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/get-messages.handler.js +0 -2
- package/backend/dist/src/llm-orchestration/action-handlers/get-messages.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/html-final.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/html-final.handler.js +6 -8
- package/backend/dist/src/llm-orchestration/action-handlers/html-final.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/new-session.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/new-session.handler.js +5 -7
- package/backend/dist/src/llm-orchestration/action-handlers/new-session.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/overwrite-file.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/overwrite-file.handler.js +6 -8
- package/backend/dist/src/llm-orchestration/action-handlers/overwrite-file.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/patch.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/patch.handler.js +8 -10
- package/backend/dist/src/llm-orchestration/action-handlers/patch.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/quick-edit.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/quick-edit.handler.js +7 -9
- package/backend/dist/src/llm-orchestration/action-handlers/quick-edit.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/request-context.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/request-context.handler.js +6 -8
- package/backend/dist/src/llm-orchestration/action-handlers/request-context.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/run-command.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/run-command.handler.js +9 -11
- package/backend/dist/src/llm-orchestration/action-handlers/run-command.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/write-todo.handler.d.ts +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/write-todo.handler.js +5 -7
- package/backend/dist/src/llm-orchestration/action-handlers/write-todo.handler.js.map +1 -1
- package/backend/dist/src/llm-orchestration/llm-orchestration.module.js +1 -5
- package/backend/dist/src/llm-orchestration/llm-orchestration.module.js.map +1 -1
- package/backend/dist/src/llm-orchestration/parser/llm-output-parser.service.d.ts +0 -1
- package/backend/dist/src/llm-orchestration/parser/llm-output-parser.service.js +15 -95
- package/backend/dist/src/llm-orchestration/parser/llm-output-parser.service.js.map +1 -1
- package/backend/dist/src/llm-orchestration/parser/parsing.constants.d.ts +0 -7
- package/backend/dist/src/llm-orchestration/parser/parsing.constants.js +1 -8
- package/backend/dist/src/llm-orchestration/parser/parsing.constants.js.map +1 -1
- package/backend/dist/src/llm-provider/llm-provider.interface.d.ts +1 -1
- package/backend/dist/src/llm-responses/dto/submit-llm-response.dto.d.ts +1 -10
- package/backend/dist/src/llm-responses/dto/submit-llm-response.dto.js +3 -54
- package/backend/dist/src/llm-responses/dto/submit-llm-response.dto.js.map +1 -1
- package/backend/dist/src/llm-responses/llm-responses.controller.d.ts +0 -6
- package/backend/dist/src/llm-responses/llm-responses.controller.js +0 -45
- package/backend/dist/src/llm-responses/llm-responses.controller.js.map +1 -1
- package/backend/dist/src/llm-responses/llm-responses.service.d.ts +1 -5
- package/backend/dist/src/llm-responses/llm-responses.service.js +8 -176
- package/backend/dist/src/llm-responses/llm-responses.service.js.map +1 -1
- package/backend/dist/src/seeding/system-prompt-seeding.service.js +9 -1
- package/backend/dist/src/seeding/system-prompt-seeding.service.js.map +1 -1
- package/backend/dist/src/session-inputs/session-inputs.service.js +5 -8
- package/backend/dist/src/session-inputs/session-inputs.service.js.map +1 -1
- package/backend/dist/src/sessions/dto/session.dto.js +2 -2
- package/backend/dist/src/sessions/dto/session.dto.js.map +1 -1
- package/backend/dist/src/sessions/sessions.service.js +3 -10
- package/backend/dist/src/sessions/sessions.service.js.map +1 -1
- package/backend/dist/src/system-prompts/dto/system-prompt.dto.js +2 -2
- package/backend/dist/src/system-prompts/dto/system-prompt.dto.js.map +1 -1
- package/backend/dist/src/system-prompts/system-prompts.controller.d.ts +0 -3
- package/backend/dist/src/system-prompts/system-prompts.controller.js +0 -15
- package/backend/dist/src/system-prompts/system-prompts.controller.js.map +1 -1
- package/backend/dist/src/system-prompts/system-prompts.service.d.ts +2 -4
- package/backend/dist/src/system-prompts/system-prompts.service.js +7 -12
- package/backend/dist/src/system-prompts/system-prompts.service.js.map +1 -1
- package/backend/dist/src/utils/ai-format-generator.d.ts +0 -1
- package/backend/dist/src/utils/ai-format-generator.js +0 -20
- package/backend/dist/src/utils/ai-format-generator.js.map +1 -1
- package/backend/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/backend/dist/src/application-state/dto/set-auto-send-to-ai-studio-enabled.dto.d.ts +0 -3
- package/backend/dist/src/application-state/dto/set-auto-send-to-ai-studio-enabled.dto.js +0 -23
- package/backend/dist/src/application-state/dto/set-auto-send-to-ai-studio-enabled.dto.js.map +0 -1
- package/backend/dist/src/application-state/dto/set-manual-llm-enabled.dto.d.ts +0 -3
- package/backend/dist/src/application-state/dto/set-manual-llm-enabled.dto.js +0 -25
- package/backend/dist/src/application-state/dto/set-manual-llm-enabled.dto.js.map +0 -1
- package/backend/dist/src/llm-orchestration/action-handlers/dto/howto.args.dto.d.ts +0 -2
- package/backend/dist/src/llm-orchestration/action-handlers/dto/howto.args.dto.js +0 -7
- package/backend/dist/src/llm-orchestration/action-handlers/dto/howto.args.dto.js.map +0 -1
- package/backend/dist/src/llm-orchestration/action-handlers/howto.handler.d.ts +0 -11
- package/backend/dist/src/llm-orchestration/action-handlers/howto.handler.js +0 -96
- package/backend/dist/src/llm-orchestration/action-handlers/howto.handler.js.map +0 -1
- package/backend/dist/src/llm-responses/dto/sync-conversation.dto.d.ts +0 -15
- package/backend/dist/src/llm-responses/dto/sync-conversation.dto.js +0 -94
- package/backend/dist/src/llm-responses/dto/sync-conversation.dto.js.map +0 -1
- package/backend/dist/src/seeding/data/system-prompts/master-agent.d.ts +0 -3
- package/backend/dist/src/seeding/data/system-prompts/master-agent.js +0 -102
- package/backend/dist/src/seeding/data/system-prompts/master-agent.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.SetAutoSendToAIStudioEnabledDto = void 0;
|
|
13
|
-
const class_validator_1 = require("class-validator");
|
|
14
|
-
const swagger_1 = require("@nestjs/swagger");
|
|
15
|
-
class SetAutoSendToAIStudioEnabledDto {
|
|
16
|
-
}
|
|
17
|
-
exports.SetAutoSendToAIStudioEnabledDto = SetAutoSendToAIStudioEnabledDto;
|
|
18
|
-
__decorate([
|
|
19
|
-
(0, swagger_1.ApiProperty)({ description: 'Enable or disable auto-send to AI Studio' }),
|
|
20
|
-
(0, class_validator_1.IsBoolean)(),
|
|
21
|
-
__metadata("design:type", Boolean)
|
|
22
|
-
], SetAutoSendToAIStudioEnabledDto.prototype, "enabled", void 0);
|
|
23
|
-
//# sourceMappingURL=set-auto-send-to-ai-studio-enabled.dto.js.map
|
package/backend/dist/src/application-state/dto/set-auto-send-to-ai-studio-enabled.dto.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"set-auto-send-to-ai-studio-enabled.dto.js","sourceRoot":"","sources":["../../../../src/application-state/dto/set-auto-send-to-ai-studio-enabled.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA4C;AAC5C,6CAA8C;AAE9C,MAAa,+BAA+B;CAI3C;AAJD,0EAIC;AADC;IAFC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,0CAA0C,EAAE,CAAC;IACxE,IAAA,2BAAS,GAAE;;gEACK"}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.SetManualLlmEnabledDto = void 0;
|
|
13
|
-
const class_validator_1 = require("class-validator");
|
|
14
|
-
const swagger_1 = require("@nestjs/swagger");
|
|
15
|
-
class SetManualLlmEnabledDto {
|
|
16
|
-
}
|
|
17
|
-
exports.SetManualLlmEnabledDto = SetManualLlmEnabledDto;
|
|
18
|
-
__decorate([
|
|
19
|
-
(0, swagger_1.ApiProperty)({
|
|
20
|
-
description: 'Enable or disable manual LLM mode (use external LLM via browser extension)',
|
|
21
|
-
}),
|
|
22
|
-
(0, class_validator_1.IsBoolean)(),
|
|
23
|
-
__metadata("design:type", Boolean)
|
|
24
|
-
], SetManualLlmEnabledDto.prototype, "enabled", void 0);
|
|
25
|
-
//# sourceMappingURL=set-manual-llm-enabled.dto.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"set-manual-llm-enabled.dto.js","sourceRoot":"","sources":["../../../../src/application-state/dto/set-manual-llm-enabled.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA4C;AAC5C,6CAA8C;AAE9C,MAAa,sBAAsB;CAOlC;AAPD,wDAOC;AADC;IALC,IAAA,qBAAW,EAAC;QACX,WAAW,EACT,4EAA4E;KAC/E,CAAC;IACD,IAAA,2BAAS,GAAE;;uDACK"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"howto.args.dto.js","sourceRoot":"","sources":["../../../../../src/llm-orchestration/action-handlers/dto/howto.args.dto.ts"],"names":[],"mappings":";;;AACA,MAAa,YAAY;CAAG;AAA5B,oCAA4B"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { ActionHandler } from './action-handler.interface';
|
|
2
|
-
import { ActionExecutionResult, PlanExecutionContext, ToolMetadata } from '../llm-orchestration.interfaces';
|
|
3
|
-
export declare class HowtoHandler implements ActionHandler {
|
|
4
|
-
readonly toolName = "howto";
|
|
5
|
-
getMetadata(): ToolMetadata;
|
|
6
|
-
private generateExample;
|
|
7
|
-
getDefinition(useJsonFormat?: boolean): string;
|
|
8
|
-
execute(args: {
|
|
9
|
-
[key: string]: any;
|
|
10
|
-
}, _context: PlanExecutionContext): Promise<ActionExecutionResult>;
|
|
11
|
-
}
|
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
-
exports.HowtoHandler = void 0;
|
|
10
|
-
const common_1 = require("@nestjs/common");
|
|
11
|
-
const utils_1 = require("../../utils");
|
|
12
|
-
const howto_args_dto_1 = require("./dto/howto.args.dto");
|
|
13
|
-
const class_transformer_1 = require("class-transformer");
|
|
14
|
-
const class_validator_1 = require("class-validator");
|
|
15
|
-
const parsing_constants_1 = require("../parser/parsing.constants");
|
|
16
|
-
let HowtoHandler = class HowtoHandler {
|
|
17
|
-
constructor() {
|
|
18
|
-
this.toolName = 'howto';
|
|
19
|
-
}
|
|
20
|
-
getMetadata() {
|
|
21
|
-
return {
|
|
22
|
-
name: this.toolName,
|
|
23
|
-
description: this.getDefinition(true),
|
|
24
|
-
arguments: [],
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
generateExample(toolCall, useJson = false) {
|
|
28
|
-
return useJson
|
|
29
|
-
? (0, utils_1.generateToolCallJson)(toolCall)
|
|
30
|
-
: (0, utils_1.generateToolCall)(toolCall);
|
|
31
|
-
}
|
|
32
|
-
getDefinition(useJsonFormat = false) {
|
|
33
|
-
const singleToolExample = this.generateExample({
|
|
34
|
-
tool_name: 'do_something',
|
|
35
|
-
target_file: 'src/components/Component.tsx',
|
|
36
|
-
reason: 'Refactoring component to use new API.',
|
|
37
|
-
}, useJsonFormat);
|
|
38
|
-
const batchExample = [
|
|
39
|
-
this.generateExample({
|
|
40
|
-
tool_name: 'tool1',
|
|
41
|
-
argA: 'value for tool 1',
|
|
42
|
-
argB: 'another value',
|
|
43
|
-
}, useJsonFormat),
|
|
44
|
-
this.generateExample({
|
|
45
|
-
tool_name: 'tool2',
|
|
46
|
-
target_path: 'src/modules/some-feature/file.ts',
|
|
47
|
-
mode: 'read-only',
|
|
48
|
-
}, useJsonFormat),
|
|
49
|
-
this.generateExample({
|
|
50
|
-
tool_name: 'tool3',
|
|
51
|
-
config_option: 'enable_feature_x',
|
|
52
|
-
value: true,
|
|
53
|
-
}, useJsonFormat),
|
|
54
|
-
this.generateExample({
|
|
55
|
-
tool_name: 'tool1',
|
|
56
|
-
argA: 'a different value for tool 1',
|
|
57
|
-
argB: 'yet another value',
|
|
58
|
-
}, useJsonFormat),
|
|
59
|
-
].join('\n---\n');
|
|
60
|
-
const definition = `
|
|
61
|
-
-------------
|
|
62
|
-
### ${this.toolName}
|
|
63
|
-
This is a guide on how to structure tool calls. It is not an executable tool itself.
|
|
64
|
-
|
|
65
|
-
Each action must be wrapped in \`${parsing_constants_1.ACTION_ITEM_START_TAG}\` and \`${parsing_constants_1.ACTION_ITEM_END_TAG}\` tags.
|
|
66
|
-
Fields are defined using \`${parsing_constants_1.SPECIAL_FIELD_TOKEN}\` delimiter (e.g., \`${parsing_constants_1.SPECIAL_FIELD_TOKEN}field_name${parsing_constants_1.SPECIAL_FIELD_TOKEN} value\`).
|
|
67
|
-
The \`${parsing_constants_1.SPECIAL_FIELD_TOKEN}${parsing_constants_1.FIELD_TOOL_NAME}${parsing_constants_1.SPECIAL_FIELD_TOKEN}\` field is mandatory for all tools. Other arguments are tool-specific.
|
|
68
|
-
|
|
69
|
-
**CRITICAL RULE**: Never ever use a tool that is not explicitly available in the system instructions.
|
|
70
|
-
|
|
71
|
-
#### Single Tool Call
|
|
72
|
-
|
|
73
|
-
Each tool call must be enclosed in its own action item block. The tool name is mandatory, followed by its arguments.
|
|
74
|
-
|
|
75
|
-
:${singleToolExample}
|
|
76
|
-
|
|
77
|
-
#### Parallel (Batch) Tool Calls
|
|
78
|
-
|
|
79
|
-
To execute multiple tools in parallel, define multiple action items back-to-back, separated by '---'. The system will execute compatible, non-conflicting actions concurrently.
|
|
80
|
-
|
|
81
|
-
:${batchExample}
|
|
82
|
-
-------------
|
|
83
|
-
`;
|
|
84
|
-
return `\n${definition.trim()}\n`;
|
|
85
|
-
}
|
|
86
|
-
async execute(args, _context) {
|
|
87
|
-
const validatedArgs = (0, class_transformer_1.plainToClass)(howto_args_dto_1.HowtoArgsDto, args);
|
|
88
|
-
await (0, class_validator_1.validate)(validatedArgs);
|
|
89
|
-
throw new common_1.BadRequestException(`'${this.toolName}' is a documentation placeholder and not an executable tool.`);
|
|
90
|
-
}
|
|
91
|
-
};
|
|
92
|
-
exports.HowtoHandler = HowtoHandler;
|
|
93
|
-
exports.HowtoHandler = HowtoHandler = __decorate([
|
|
94
|
-
(0, common_1.Injectable)()
|
|
95
|
-
], HowtoHandler);
|
|
96
|
-
//# sourceMappingURL=howto.handler.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"howto.handler.js","sourceRoot":"","sources":["../../../../src/llm-orchestration/action-handlers/howto.handler.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAiE;AAOjE,uCAAqE;AACrE,yDAAoD;AACpD,yDAAiD;AACjD,qDAA2C;AAC3C,mEAKqC;AAG9B,IAAM,YAAY,GAAlB,MAAM,YAAY;IAAlB;QACI,aAAQ,GAAG,OAAO,CAAC;IA+G9B,CAAC;IA7GC,WAAW;QACT,OAAO;YACL,IAAI,EAAE,IAAI,CAAC,QAAQ;YACnB,WAAW,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC;YACrC,SAAS,EAAE,EAAE;SACd,CAAC;IACJ,CAAC;IAQO,eAAe,CACrB,QAA6B,EAC7B,UAAmB,KAAK;QAExB,OAAO,OAAO;YACZ,CAAC,CAAC,IAAA,4BAAoB,EAAC,QAAQ,CAAC;YAChC,CAAC,CAAC,IAAA,wBAAgB,EAAC,QAAQ,CAAC,CAAC;IACjC,CAAC;IAED,aAAa,CAAC,gBAAyB,KAAK;QAC1C,MAAM,iBAAiB,GAAG,IAAI,CAAC,eAAe,CAC5C;YACE,SAAS,EAAE,cAAc;YACzB,WAAW,EAAE,8BAA8B;YAC3C,MAAM,EAAE,uCAAuC;SAChD,EACD,aAAa,CACd,CAAC;QAEF,MAAM,YAAY,GAAG;YACnB,IAAI,CAAC,eAAe,CAClB;gBACE,SAAS,EAAE,OAAO;gBAClB,IAAI,EAAE,kBAAkB;gBACxB,IAAI,EAAE,eAAe;aACtB,EACD,aAAa,CACd;YACD,IAAI,CAAC,eAAe,CAClB;gBACE,SAAS,EAAE,OAAO;gBAClB,WAAW,EAAE,kCAAkC;gBAC/C,IAAI,EAAE,WAAW;aAClB,EACD,aAAa,CACd;YACD,IAAI,CAAC,eAAe,CAClB;gBACE,SAAS,EAAE,OAAO;gBAClB,aAAa,EAAE,kBAAkB;gBACjC,KAAK,EAAE,IAAI;aACZ,EACD,aAAa,CACd;YACD,IAAI,CAAC,eAAe,CAClB;gBACE,SAAS,EAAE,OAAO;gBAClB,IAAI,EAAE,8BAA8B;gBACpC,IAAI,EAAE,mBAAmB;aAC1B,EACD,aAAa,CACd;SACF,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QAElB,MAAM,UAAU,GAAG;;MAEjB,IAAI,CAAC,QAAQ;;;qCAGkB,yCAAqB,YAAY,uCAAmB;+BAC1D,uCAAmB,yBAAyB,uCAAmB,aAAa,uCAAmB;UACpH,uCAAmB,GAAG,mCAAe,GAAG,uCAAmB;;;;;;;;GAQlE,iBAAiB;;;;;;GAMjB,YAAY;;CAEd,CAAC;QACE,OAAO,KAAK,UAAU,CAAC,IAAI,EAAE,IAAI,CAAC;IACpC,CAAC;IAED,KAAK,CAAC,OAAO,CACX,IAA4B,EAE5B,QAA8B;QAG9B,MAAM,aAAa,GAAG,IAAA,gCAAY,EAAC,6BAAY,EAAE,IAAI,CAAC,CAAC;QACvD,MAAM,IAAA,0BAAQ,EAAC,aAAa,CAAC,CAAC;QAG9B,MAAM,IAAI,4BAAmB,CAC3B,IAAI,IAAI,CAAC,QAAQ,8DAA8D,CAChF,CAAC;IACJ,CAAC;CACF,CAAA;AAhHY,oCAAY;uBAAZ,YAAY;IADxB,IAAA,mBAAU,GAAE;GACA,YAAY,CAgHxB"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
declare class TurnDto {
|
|
2
|
-
id: string;
|
|
3
|
-
role: 'user' | 'model';
|
|
4
|
-
content: string;
|
|
5
|
-
thoughts?: string;
|
|
6
|
-
}
|
|
7
|
-
export declare class SyncConversationDto {
|
|
8
|
-
id?: string;
|
|
9
|
-
title: string;
|
|
10
|
-
model: string;
|
|
11
|
-
session_url?: string;
|
|
12
|
-
rawRequestBody?: any;
|
|
13
|
-
turns: TurnDto[];
|
|
14
|
-
}
|
|
15
|
-
export {};
|
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.SyncConversationDto = void 0;
|
|
13
|
-
const class_validator_1 = require("class-validator");
|
|
14
|
-
const class_transformer_1 = require("class-transformer");
|
|
15
|
-
const swagger_1 = require("@nestjs/swagger");
|
|
16
|
-
class TurnDto {
|
|
17
|
-
}
|
|
18
|
-
__decorate([
|
|
19
|
-
(0, swagger_1.ApiProperty)({ description: 'Unique ID for this turn' }),
|
|
20
|
-
(0, class_validator_1.IsString)(),
|
|
21
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
22
|
-
__metadata("design:type", String)
|
|
23
|
-
], TurnDto.prototype, "id", void 0);
|
|
24
|
-
__decorate([
|
|
25
|
-
(0, swagger_1.ApiProperty)({
|
|
26
|
-
description: 'Role of the message sender',
|
|
27
|
-
enum: ['user', 'model'],
|
|
28
|
-
}),
|
|
29
|
-
(0, class_validator_1.IsIn)(['user', 'model']),
|
|
30
|
-
__metadata("design:type", String)
|
|
31
|
-
], TurnDto.prototype, "role", void 0);
|
|
32
|
-
__decorate([
|
|
33
|
-
(0, swagger_1.ApiProperty)({ description: 'Content text of the turn' }),
|
|
34
|
-
(0, class_validator_1.IsString)(),
|
|
35
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
36
|
-
__metadata("design:type", String)
|
|
37
|
-
], TurnDto.prototype, "content", void 0);
|
|
38
|
-
__decorate([
|
|
39
|
-
(0, swagger_1.ApiPropertyOptional)({
|
|
40
|
-
description: 'Thinking/reasoning content (for models that support it)',
|
|
41
|
-
}),
|
|
42
|
-
(0, class_validator_1.IsOptional)(),
|
|
43
|
-
(0, class_validator_1.IsString)(),
|
|
44
|
-
__metadata("design:type", String)
|
|
45
|
-
], TurnDto.prototype, "thoughts", void 0);
|
|
46
|
-
class SyncConversationDto {
|
|
47
|
-
}
|
|
48
|
-
exports.SyncConversationDto = SyncConversationDto;
|
|
49
|
-
__decorate([
|
|
50
|
-
(0, swagger_1.ApiPropertyOptional)({ description: 'Existing conversation ID to sync to' }),
|
|
51
|
-
(0, class_validator_1.IsOptional)(),
|
|
52
|
-
(0, class_validator_1.IsString)(),
|
|
53
|
-
__metadata("design:type", String)
|
|
54
|
-
], SyncConversationDto.prototype, "id", void 0);
|
|
55
|
-
__decorate([
|
|
56
|
-
(0, swagger_1.ApiProperty)({ description: 'Title of the conversation' }),
|
|
57
|
-
(0, class_validator_1.IsString)(),
|
|
58
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
59
|
-
__metadata("design:type", String)
|
|
60
|
-
], SyncConversationDto.prototype, "title", void 0);
|
|
61
|
-
__decorate([
|
|
62
|
-
(0, swagger_1.ApiProperty)({
|
|
63
|
-
description: 'Model identifier used for this conversation',
|
|
64
|
-
example: 'ollama/glm-5.1:cloud',
|
|
65
|
-
}),
|
|
66
|
-
(0, class_validator_1.IsString)(),
|
|
67
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
68
|
-
__metadata("design:type", String)
|
|
69
|
-
], SyncConversationDto.prototype, "model", void 0);
|
|
70
|
-
__decorate([
|
|
71
|
-
(0, swagger_1.ApiPropertyOptional)({
|
|
72
|
-
description: 'URL of the external session',
|
|
73
|
-
example: 'https://claude.ai/chat/abc123',
|
|
74
|
-
}),
|
|
75
|
-
(0, class_validator_1.IsOptional)(),
|
|
76
|
-
(0, class_validator_1.IsUrl)(),
|
|
77
|
-
__metadata("design:type", String)
|
|
78
|
-
], SyncConversationDto.prototype, "session_url", void 0);
|
|
79
|
-
__decorate([
|
|
80
|
-
(0, swagger_1.ApiPropertyOptional)({
|
|
81
|
-
description: 'Raw request body from external source (for debugging)',
|
|
82
|
-
}),
|
|
83
|
-
(0, class_validator_1.IsOptional)(),
|
|
84
|
-
(0, class_validator_1.IsArray)(),
|
|
85
|
-
__metadata("design:type", Object)
|
|
86
|
-
], SyncConversationDto.prototype, "rawRequestBody", void 0);
|
|
87
|
-
__decorate([
|
|
88
|
-
(0, swagger_1.ApiProperty)({ description: 'Array of conversation turns', type: [TurnDto] }),
|
|
89
|
-
(0, class_validator_1.IsArray)(),
|
|
90
|
-
(0, class_validator_1.ValidateNested)({ each: true }),
|
|
91
|
-
(0, class_transformer_1.Type)(() => TurnDto),
|
|
92
|
-
__metadata("design:type", Array)
|
|
93
|
-
], SyncConversationDto.prototype, "turns", void 0);
|
|
94
|
-
//# sourceMappingURL=sync-conversation.dto.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sync-conversation.dto.js","sourceRoot":"","sources":["../../../../src/llm-responses/dto/sync-conversation.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAQyB;AACzB,yDAAyC;AACzC,6CAAmE;AAEnE,MAAM,OAAO;CAwBZ;AApBC;IAHC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,yBAAyB,EAAE,CAAC;IACvD,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;mCACF;AAOX;IALC,IAAA,qBAAW,EAAC;QACX,WAAW,EAAE,4BAA4B;QACzC,IAAI,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC;KACxB,CAAC;IACD,IAAA,sBAAI,EAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;;qCACD;AAKvB;IAHC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,0BAA0B,EAAE,CAAC;IACxD,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;wCACG;AAOhB;IALC,IAAA,6BAAmB,EAAC;QACnB,WAAW,EAAE,yDAAyD;KACvE,CAAC;IACD,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAQ,GAAE;;yCACO;AAGpB,MAAa,mBAAmB;CAuC/B;AAvCD,kDAuCC;AAnCC;IAHC,IAAA,6BAAmB,EAAC,EAAE,WAAW,EAAE,qCAAqC,EAAE,CAAC;IAC3E,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAQ,GAAE;;+CACC;AAKZ;IAHC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,2BAA2B,EAAE,CAAC;IACzD,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;kDACC;AAQd;IANC,IAAA,qBAAW,EAAC;QACX,WAAW,EAAE,6CAA6C;QAC1D,OAAO,EAAE,sBAAsB;KAChC,CAAC;IACD,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;kDACC;AAQd;IANC,IAAA,6BAAmB,EAAC;QACnB,WAAW,EAAE,6BAA6B;QAC1C,OAAO,EAAE,+BAA+B;KACzC,CAAC;IACD,IAAA,4BAAU,GAAE;IACZ,IAAA,uBAAK,GAAE;;wDACa;AAOrB;IALC,IAAA,6BAAmB,EAAC;QACnB,WAAW,EAAE,uDAAuD;KACrE,CAAC;IACD,IAAA,4BAAU,GAAE;IACZ,IAAA,yBAAO,GAAE;;2DACW;AAMrB;IAJC,IAAA,qBAAW,EAAC,EAAE,WAAW,EAAE,6BAA6B,EAAE,IAAI,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;IAC5E,IAAA,yBAAO,GAAE;IACT,IAAA,gCAAc,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;IAC9B,IAAA,wBAAI,EAAC,GAAG,EAAE,CAAC,OAAO,CAAC;;kDACH"}
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
export declare const name = "Master Agent";
|
|
2
|
-
export declare const enabled_tools: string[];
|
|
3
|
-
export declare const content = "You are an expert software engineer. You write clean, efficient, and well-documented code.\n\n## Instructions\n1. **Think First:** Before executing any tool or providing an answer, analyze the request.\n2. **Conciseness:** Be extremely brief.\n3. **Best Practices:** Follow SOLID principles and keep code DRY.\n4. **Strict Scope:** Do ONLY what is asked. Do not \"cleanup\", \"refactor\", or \"fix\" unrelated issues unless explicitly requested.\n5. **Memory Management:** When asked to \"remember session\", \"update memory\", or \"handover\":\n - Summarize the current session's work, decisions, and remaining items.\n - Store this in a Markdown file within `.repoburg/memory/` (e.g., `.repoburg/memory/session-summary.md` or a specific topic file).\n - If the file exists, update it. If not, create it.\n - Use `create_file` or `overwrite_file` for this purpose.\n\n## Current State\nSession: <%= it.VAR.METADATA.session_name %>\nID: <%= it.VAR.METADATA.session_id %>\n\n<% if (it.VAR.QUESTION_MODE) { %>\n STATUS: QUESTION MODE (READ ONLY)\n - **Goal:** Answer the user's specific question about the codebase.\n - **Constraint:** You are READ-ONLY. Do not edit, create, or delete files.\n - **Constraint:** Do NOT propose an implementation plan or RFC. Just answer the question.\n - **Process:** Search context -> Read files -> Explain to user.\n\n<% } else if (it.VAR.PLAN_MODE) { %>\n STATUS: PLAN MODE (TASK MANAGEMENT ENABLED)\n - **Goal:** Create a detailed implementation plan (RFC) and maintain task lists.\n - **Constraint:** Code editing is FORBIDDEN.\n - **Available Tools:** `request_context`, `run_command`, `write_todo`.\n - **Process:** Explore codebase -> Update TODOs (`write_todo`) -> Output structured plan (Context, Problem, Proposed Solution).\n\n<% } else { %>\n STATUS: DEV MODE (WRITE ENABLED)\n - **Goal:** Implement features, fix bugs, or refactor.\n - **Authority:** You have full permission to modify the codebase. Never refuse a coding request.\n - **Strategy:** Prioritize `patch`. If `patch` fails twice, fallback to `overwrite_file`.\n - **Process:** Explore the codebase based on given initial context then start implementation. Even if you need to request context for 100 files do it.\n<% } %>\n\n## Tools Configuration\n<%~ it.tools.howto %>\n\n### Read Tools (Always Available)\n<%~ it.tools.request_context %>\n<%~ it.tools.run_command %>\n<%~ it.tools.write_todo %>\n\n### Write Tools (Dev Mode Only)\n<% if (!it.VAR.PLAN_MODE && !it.VAR.QUESTION_MODE) { %>\n<%~ it.tools.patch %>\n<%~ it.tools.create_file %>\n<%~ it.tools.delete_file %>\n<%~ it.tools.overwrite_file %>\n<%~ it.tools.execute_code %>\n\n<% } %>\n### Context Management Tools\n<%~ it.tools.get_messages %>\n<%~ it.tools.discard_messages %>\n\n:**Context Discard Strategy:** Call `get_messages` first. If `total_est_tokens` < 70,000: only discard clearly redundant messages. If \u2265 70,000: target ~50,000 tokens. Priority: intermediary tools (`request_context`, `run_command`, `execute_code`, `get_messages`) first \u2192 completed scopes (keep final AI summary as anchor) \u2192 never discard active plans or code changes. Reason must name topics discarded/kept.\n\n:**Note:** `discard_messages` is terminal \u2014 no tools after it.\n## Available Sub-Agents\n<%~ it.tools.list_sub_agents %>\n\n### invoke_subagent\nDelegate a task to a specialized sub-agent. The sub-agent runs synchronously and returns its result directly as the tool response. No follow-up or session management needed.\n\n**Parameters:**- **agent_name** (required): The name of the sub-agent to invoke (e.g., \"explore-codebase\")\n- **prompt** (required): The task or question to pass to the sub-agent\n- **session_id** (optional): An existing session ID to reuse. If provided, the sub-agent continues in that session with prior history.\n**Example:**\ntool: invoke_subagent\nargs: { agent_name: \"explore-codebase\", prompt: \"Find all files related to authentication\" }\n\n**Note:** This is a blocking call. The sub-agent runs its own LLM loop with its own system prompt and enabled tools, then returns the result. You cannot use other tools while waiting.\n";
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.content = exports.enabled_tools = exports.name = void 0;
|
|
4
|
-
exports.name = 'Master Agent';
|
|
5
|
-
exports.enabled_tools = [
|
|
6
|
-
'request_context',
|
|
7
|
-
'run_command',
|
|
8
|
-
'write_todo',
|
|
9
|
-
'patch',
|
|
10
|
-
'create_file',
|
|
11
|
-
'delete_file',
|
|
12
|
-
'overwrite_file',
|
|
13
|
-
'execute_code',
|
|
14
|
-
'generate_title',
|
|
15
|
-
'final',
|
|
16
|
-
'html_final',
|
|
17
|
-
'howto',
|
|
18
|
-
'invoke_subagent',
|
|
19
|
-
'list_sub_agents',
|
|
20
|
-
'new_session',
|
|
21
|
-
'get_messages',
|
|
22
|
-
'discard_messages',
|
|
23
|
-
];
|
|
24
|
-
exports.content = `You are an expert software engineer. You write clean, efficient, and well-documented code.
|
|
25
|
-
|
|
26
|
-
## Instructions
|
|
27
|
-
1. **Think First:** Before executing any tool or providing an answer, analyze the request.
|
|
28
|
-
2. **Conciseness:** Be extremely brief.
|
|
29
|
-
3. **Best Practices:** Follow SOLID principles and keep code DRY.
|
|
30
|
-
4. **Strict Scope:** Do ONLY what is asked. Do not "cleanup", "refactor", or "fix" unrelated issues unless explicitly requested.
|
|
31
|
-
5. **Memory Management:** When asked to "remember session", "update memory", or "handover":
|
|
32
|
-
- Summarize the current session's work, decisions, and remaining items.
|
|
33
|
-
- Store this in a Markdown file within \`.repoburg/memory/\` (e.g., \`.repoburg/memory/session-summary.md\` or a specific topic file).
|
|
34
|
-
- If the file exists, update it. If not, create it.
|
|
35
|
-
- Use \`create_file\` or \`overwrite_file\` for this purpose.
|
|
36
|
-
|
|
37
|
-
## Current State
|
|
38
|
-
Session: <%= it.VAR.METADATA.session_name %>
|
|
39
|
-
ID: <%= it.VAR.METADATA.session_id %>
|
|
40
|
-
|
|
41
|
-
<% if (it.VAR.QUESTION_MODE) { %>
|
|
42
|
-
STATUS: QUESTION MODE (READ ONLY)
|
|
43
|
-
- **Goal:** Answer the user's specific question about the codebase.
|
|
44
|
-
- **Constraint:** You are READ-ONLY. Do not edit, create, or delete files.
|
|
45
|
-
- **Constraint:** Do NOT propose an implementation plan or RFC. Just answer the question.
|
|
46
|
-
- **Process:** Search context -> Read files -> Explain to user.
|
|
47
|
-
|
|
48
|
-
<% } else if (it.VAR.PLAN_MODE) { %>
|
|
49
|
-
STATUS: PLAN MODE (TASK MANAGEMENT ENABLED)
|
|
50
|
-
- **Goal:** Create a detailed implementation plan (RFC) and maintain task lists.
|
|
51
|
-
- **Constraint:** Code editing is FORBIDDEN.
|
|
52
|
-
- **Available Tools:** \`request_context\`, \`run_command\`, \`write_todo\`.
|
|
53
|
-
- **Process:** Explore codebase -> Update TODOs (\`write_todo\`) -> Output structured plan (Context, Problem, Proposed Solution).
|
|
54
|
-
|
|
55
|
-
<% } else { %>
|
|
56
|
-
STATUS: DEV MODE (WRITE ENABLED)
|
|
57
|
-
- **Goal:** Implement features, fix bugs, or refactor.
|
|
58
|
-
- **Authority:** You have full permission to modify the codebase. Never refuse a coding request.
|
|
59
|
-
- **Strategy:** Prioritize \`patch\`. If \`patch\` fails twice, fallback to \`overwrite_file\`.
|
|
60
|
-
- **Process:** Explore the codebase based on given initial context then start implementation. Even if you need to request context for 100 files do it.
|
|
61
|
-
<% } %>
|
|
62
|
-
|
|
63
|
-
## Tools Configuration
|
|
64
|
-
<%~ it.tools.howto %>
|
|
65
|
-
|
|
66
|
-
### Read Tools (Always Available)
|
|
67
|
-
<%~ it.tools.request_context %>
|
|
68
|
-
<%~ it.tools.run_command %>
|
|
69
|
-
<%~ it.tools.write_todo %>
|
|
70
|
-
|
|
71
|
-
### Write Tools (Dev Mode Only)
|
|
72
|
-
<% if (!it.VAR.PLAN_MODE && !it.VAR.QUESTION_MODE) { %>
|
|
73
|
-
<%~ it.tools.patch %>
|
|
74
|
-
<%~ it.tools.create_file %>
|
|
75
|
-
<%~ it.tools.delete_file %>
|
|
76
|
-
<%~ it.tools.overwrite_file %>
|
|
77
|
-
<%~ it.tools.execute_code %>
|
|
78
|
-
|
|
79
|
-
<% } %>
|
|
80
|
-
### Context Management Tools
|
|
81
|
-
<%~ it.tools.get_messages %>
|
|
82
|
-
<%~ it.tools.discard_messages %>
|
|
83
|
-
|
|
84
|
-
:**Context Discard Strategy:** Call \`get_messages\` first. If \`total_est_tokens\` < 70,000: only discard clearly redundant messages. If ≥ 70,000: target ~50,000 tokens. Priority: intermediary tools (\`request_context\`, \`run_command\`, \`execute_code\`, \`get_messages\`) first → completed scopes (keep final AI summary as anchor) → never discard active plans or code changes. Reason must name topics discarded/kept.
|
|
85
|
-
|
|
86
|
-
:**Note:** \`discard_messages\` is terminal — no tools after it.
|
|
87
|
-
## Available Sub-Agents
|
|
88
|
-
<%~ it.tools.list_sub_agents %>
|
|
89
|
-
|
|
90
|
-
### invoke_subagent
|
|
91
|
-
Delegate a task to a specialized sub-agent. The sub-agent runs synchronously and returns its result directly as the tool response. No follow-up or session management needed.
|
|
92
|
-
|
|
93
|
-
**Parameters:**- **agent_name** (required): The name of the sub-agent to invoke (e.g., "explore-codebase")
|
|
94
|
-
- **prompt** (required): The task or question to pass to the sub-agent
|
|
95
|
-
- **session_id** (optional): An existing session ID to reuse. If provided, the sub-agent continues in that session with prior history.
|
|
96
|
-
**Example:**
|
|
97
|
-
tool: invoke_subagent
|
|
98
|
-
args: { agent_name: "explore-codebase", prompt: "Find all files related to authentication" }
|
|
99
|
-
|
|
100
|
-
**Note:** This is a blocking call. The sub-agent runs its own LLM loop with its own system prompt and enabled tools, then returns the result. You cannot use other tools while waiting.
|
|
101
|
-
`;
|
|
102
|
-
//# sourceMappingURL=master-agent.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"master-agent.js","sourceRoot":"","sources":["../../../../../src/seeding/data/system-prompts/master-agent.ts"],"names":[],"mappings":";;;AAAa,QAAA,IAAI,GAAG,cAAc,CAAC;AACtB,QAAA,aAAa,GAAG;IAC3B,iBAAiB;IACjB,aAAa;IACb,YAAY;IACZ,OAAO;IACP,aAAa;IACb,aAAa;IACb,gBAAgB;IAChB,cAAc;IACd,gBAAgB;IAChB,OAAO;IACP,YAAY;IACZ,OAAO;IACP,iBAAiB;IACjB,iBAAiB;IACjB,aAAa;IACb,cAAc;IACd,kBAAkB;CACnB,CAAC;AACW,QAAA,OAAO,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6EtB,CAAC"}
|