repoburg 1.3.142 → 1.3.144
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/dist/src/agents/agents.controller.d.ts +15 -0
- package/backend/dist/src/agents/agents.controller.js +154 -0
- package/backend/dist/src/agents/agents.controller.js.map +1 -0
- package/backend/dist/src/agents/agents.module.d.ts +2 -0
- package/backend/dist/src/agents/agents.module.js +26 -0
- package/backend/dist/src/agents/agents.module.js.map +1 -0
- package/backend/dist/src/agents/agents.service.d.ts +20 -0
- package/backend/dist/src/agents/agents.service.js +141 -0
- package/backend/dist/src/agents/agents.service.js.map +1 -0
- package/backend/dist/src/agents/dto/create-agent.dto.d.ts +14 -0
- package/backend/dist/src/agents/dto/create-agent.dto.js +110 -0
- package/backend/dist/src/agents/dto/create-agent.dto.js.map +1 -0
- package/backend/dist/src/agents/dto/update-agent.dto.d.ts +12 -0
- package/backend/dist/src/agents/dto/update-agent.dto.js +93 -0
- package/backend/dist/src/agents/dto/update-agent.dto.js.map +1 -0
- package/backend/dist/src/app.module.js +4 -0
- package/backend/dist/src/app.module.js.map +1 -1
- package/backend/dist/src/core-entities/agent.entity.d.ts +20 -0
- package/backend/dist/src/core-entities/agent.entity.js +153 -0
- package/backend/dist/src/core-entities/agent.entity.js.map +1 -0
- package/backend/dist/src/core-entities/index.d.ts +1 -0
- package/backend/dist/src/core-entities/index.js +1 -0
- package/backend/dist/src/core-entities/index.js.map +1 -1
- package/backend/dist/src/llm-orchestration/action-handlers/manage-agents.handler.d.ts +20 -0
- package/backend/dist/src/llm-orchestration/action-handlers/manage-agents.handler.js +321 -0
- package/backend/dist/src/llm-orchestration/action-handlers/manage-agents.handler.js.map +1 -0
- package/backend/dist/src/llm-orchestration/llm-orchestration.module.js +7 -1
- package/backend/dist/src/llm-orchestration/llm-orchestration.module.js.map +1 -1
- package/backend/dist/src/seeding/agent-seeding.service.d.ts +12 -0
- package/backend/dist/src/seeding/agent-seeding.service.js +147 -0
- package/backend/dist/src/seeding/agent-seeding.service.js.map +1 -0
- package/backend/dist/src/seeding/data/agents/config-manager.d.ts +8 -0
- package/backend/dist/src/seeding/data/agents/config-manager.js +12 -0
- package/backend/dist/src/seeding/data/agents/config-manager.js.map +1 -0
- package/backend/dist/src/seeding/data/agents/default-agent.d.ts +8 -0
- package/backend/dist/src/seeding/data/agents/default-agent.js +12 -0
- package/backend/dist/src/seeding/data/agents/default-agent.js.map +1 -0
- package/backend/dist/src/seeding/data/context-templates/config-manager-followup-context.d.ts +9 -0
- package/backend/dist/src/seeding/data/context-templates/config-manager-followup-context.js +28 -0
- package/backend/dist/src/seeding/data/context-templates/config-manager-followup-context.js.map +1 -0
- package/backend/dist/src/seeding/data/context-templates/config-manager-initial-context.d.ts +9 -0
- package/backend/dist/src/seeding/data/context-templates/config-manager-initial-context.js +22 -0
- package/backend/dist/src/seeding/data/context-templates/config-manager-initial-context.js.map +1 -0
- package/backend/dist/src/seeding/data/system-prompts/config-manager-agent.d.ts +1 -1
- package/backend/dist/src/seeding/data/system-prompts/config-manager-agent.js +10 -2
- package/backend/dist/src/seeding/data/system-prompts/config-manager-agent.js.map +1 -1
- package/backend/dist/src/seeding/seeding.module.js +6 -1
- package/backend/dist/src/seeding/seeding.module.js.map +1 -1
- package/backend/dist/src/seeding/seeding.service.d.ts +3 -1
- package/backend/dist/src/seeding/seeding.service.js +6 -2
- package/backend/dist/src/seeding/seeding.service.js.map +1 -1
- package/backend/dist/src/sub-agents/sub-agent-runner.service.js +15 -0
- package/backend/dist/src/sub-agents/sub-agent-runner.service.js.map +1 -1
- package/backend/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"llm-orchestration.module.js","sourceRoot":"","sources":["../../../src/llm-orchestration/llm-orchestration.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAoD;AACpD,6CAAgD;AAChD,kFAA4E;AAC5E,6EAAuE;AACvE,+DAA0D;AAC1D,+EAA0E;AAC1E,uEAAkE;AAClE,mFAA8E;AAC9E,iEAAwE;AAExE,2DAAuD;AACvD,4FAAuF;AACvF,0EAAqE;AACrE,oDAK0B;AAC1B,mFAA8E;AAE9E,mFAA8E;AAC9E,iEAA6D;AAC7D,oEAAgE;AAChE,kDAA8C;AAC9C,uEAAkE;AAClE,uEAAkE;AAClE,4FAAuF;AACvF,+FAA0F;AAC1F,4FAAuF;AACvF,yFAAoF;AACpF,sFAAiF;AACjF,yFAAoF;
|
|
1
|
+
{"version":3,"file":"llm-orchestration.module.js","sourceRoot":"","sources":["../../../src/llm-orchestration/llm-orchestration.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAoD;AACpD,6CAAgD;AAChD,kFAA4E;AAC5E,6EAAuE;AACvE,+DAA0D;AAC1D,+EAA0E;AAC1E,uEAAkE;AAClE,mFAA8E;AAC9E,iEAAwE;AAExE,2DAAuD;AACvD,4FAAuF;AACvF,0EAAqE;AACrE,oDAK0B;AAC1B,mFAA8E;AAE9E,mFAA8E;AAC9E,iEAA6D;AAC7D,oEAAgE;AAChE,kDAA8C;AAC9C,uEAAkE;AAClE,uEAAkE;AAClE,4FAAuF;AACvF,+FAA0F;AAC1F,4FAAuF;AACvF,yFAAoF;AACpF,sFAAiF;AACjF,yFAAoF;AACpF,2DAAuD;AAGvD,+EAA0E;AAC1E,+EAA0E;AAC1E,qFAAgF;AAChF,+EAA0E;AAC1E,uFAAkF;AAClF,mEAA+D;AAC/D,6EAAwE;AACxE,6EAAwE;AACxE,mEAA+D;AAC/D,+EAA0E;AAC1E,6EAAwE;AACxE,iFAA4E;AAE5E,uFAAkF;AAClF,uFAAiF;AACjF,+FAAyF;AACzF,qFAAgF;AAChF,yEAAoE;AACpE,iFAA4E;AAC5E,yFAAoF;AACpF,6EAAwE;AACxE,mGAA6F;AAC7F,yGAAmG;AACnG,uGAAiG;AACjG,qGAA+F;AAC/F,uGAAiG;AACjG,2FAAqF;AACrF,mF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QACD,OAAO,EAAE;YACP,oDAAuB;YACvB,uCAAiB;YACjB,uDAAyB;YACzB,yBAAyB;SAC1B;KACF,CAAC;GACW,sBAAsB,CAAG"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Repository } from 'typeorm';
|
|
2
|
+
import { Agent } from '../core-entities';
|
|
3
|
+
import { SystemPromptsService } from '../system-prompts/system-prompts.service';
|
|
4
|
+
import { ContextTemplatesService } from '../context-templates/context-templates.service';
|
|
5
|
+
export declare class AgentSeedingService {
|
|
6
|
+
private readonly agentRepository;
|
|
7
|
+
private readonly systemPromptsService;
|
|
8
|
+
private readonly contextTemplatesService;
|
|
9
|
+
private readonly logger;
|
|
10
|
+
constructor(agentRepository: Repository<Agent>, systemPromptsService: SystemPromptsService, contextTemplatesService: ContextTemplatesService);
|
|
11
|
+
seed(): Promise<void>;
|
|
12
|
+
}
|
|
@@ -0,0 +1,147 @@
|
|
|
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
|
+
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
12
|
+
return function (target, key) { decorator(target, key, paramIndex); }
|
|
13
|
+
};
|
|
14
|
+
var AgentSeedingService_1;
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.AgentSeedingService = void 0;
|
|
17
|
+
const common_1 = require("@nestjs/common");
|
|
18
|
+
const typeorm_1 = require("@nestjs/typeorm");
|
|
19
|
+
const typeorm_2 = require("typeorm");
|
|
20
|
+
const core_entities_1 = require("../core-entities");
|
|
21
|
+
const system_prompts_service_1 = require("../system-prompts/system-prompts.service");
|
|
22
|
+
const context_templates_service_1 = require("../context-templates/context-templates.service");
|
|
23
|
+
const path = require("path");
|
|
24
|
+
const glob_1 = require("glob");
|
|
25
|
+
let AgentSeedingService = AgentSeedingService_1 = class AgentSeedingService {
|
|
26
|
+
constructor(agentRepository, systemPromptsService, contextTemplatesService) {
|
|
27
|
+
this.agentRepository = agentRepository;
|
|
28
|
+
this.systemPromptsService = systemPromptsService;
|
|
29
|
+
this.contextTemplatesService = contextTemplatesService;
|
|
30
|
+
this.logger = new common_1.Logger(AgentSeedingService_1.name);
|
|
31
|
+
}
|
|
32
|
+
async seed() {
|
|
33
|
+
this.logger.log('Syncing agents from files...');
|
|
34
|
+
const seedFiles = await (0, glob_1.glob)(path.join(__dirname, 'data', 'agents', '*.{ts,js}'));
|
|
35
|
+
if (seedFiles.length === 0) {
|
|
36
|
+
this.logger.warn('No agent seed files found.');
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
for (const filePath of seedFiles) {
|
|
40
|
+
try {
|
|
41
|
+
const agentModule = await Promise.resolve(`${filePath}`).then(s => require(s));
|
|
42
|
+
const { name, description, system_prompt_name, context_template_name, followup_context_template_name, model_id, reasoning_effort, is_active, } = agentModule;
|
|
43
|
+
const fileName = path.basename(filePath);
|
|
44
|
+
const builtinKey = fileName
|
|
45
|
+
.replace(/\.(ts|js)$/, '')
|
|
46
|
+
.replace(/_/g, '-');
|
|
47
|
+
if (!name) {
|
|
48
|
+
this.logger.warn(`Skipping malformed seed file: ${fileName} (missing name)`);
|
|
49
|
+
continue;
|
|
50
|
+
}
|
|
51
|
+
const existingAgent = await this.agentRepository.findOne({
|
|
52
|
+
where: { builtin_key: builtinKey },
|
|
53
|
+
});
|
|
54
|
+
if (existingAgent && existingAgent.is_builtin) {
|
|
55
|
+
let system_prompt_id = existingAgent.system_prompt_id;
|
|
56
|
+
if (system_prompt_name) {
|
|
57
|
+
const systemPrompt = await this.systemPromptsService.findByBuiltinKey(system_prompt_name.replace(/_/g, '-'));
|
|
58
|
+
system_prompt_id = systemPrompt?.id || null;
|
|
59
|
+
}
|
|
60
|
+
let context_template_id = existingAgent.context_template_id;
|
|
61
|
+
if (context_template_name) {
|
|
62
|
+
const contextTemplate = await this.contextTemplatesService.findByBuiltinKey(context_template_name.replace(/_/g, '-'));
|
|
63
|
+
context_template_id = contextTemplate?.id || null;
|
|
64
|
+
}
|
|
65
|
+
let followup_context_template_id = existingAgent.followup_context_template_id;
|
|
66
|
+
if (followup_context_template_name) {
|
|
67
|
+
const followupContextTemplate = await this.contextTemplatesService.findByBuiltinKey(followup_context_template_name.replace(/_/g, '-'));
|
|
68
|
+
followup_context_template_id = followupContextTemplate?.id || null;
|
|
69
|
+
}
|
|
70
|
+
existingAgent.description = description || existingAgent.description;
|
|
71
|
+
existingAgent.system_prompt_id = system_prompt_id;
|
|
72
|
+
existingAgent.context_template_id = context_template_id;
|
|
73
|
+
existingAgent.followup_context_template_id =
|
|
74
|
+
followup_context_template_id;
|
|
75
|
+
existingAgent.model_id = model_id || existingAgent.model_id;
|
|
76
|
+
existingAgent.reasoning_effort =
|
|
77
|
+
reasoning_effort || existingAgent.reasoning_effort;
|
|
78
|
+
existingAgent.is_active = is_active !== false;
|
|
79
|
+
await this.agentRepository.save(existingAgent);
|
|
80
|
+
this.logger.log(`Built-in agent "${name}" updated (version upgrade).`);
|
|
81
|
+
}
|
|
82
|
+
else if (existingAgent) {
|
|
83
|
+
this.logger.warn(`Agent with builtin_key "${builtinKey}" exists but is not built-in. Skipping.`);
|
|
84
|
+
}
|
|
85
|
+
else {
|
|
86
|
+
let system_prompt_id = null;
|
|
87
|
+
if (system_prompt_name) {
|
|
88
|
+
const systemPrompt = await this.systemPromptsService.findByBuiltinKey(system_prompt_name.replace(/_/g, '-'));
|
|
89
|
+
if (!systemPrompt) {
|
|
90
|
+
this.logger.warn(`System prompt with builtin_key "${system_prompt_name.replace(/_/g, '-')}" not found for agent "${name}"`);
|
|
91
|
+
}
|
|
92
|
+
else {
|
|
93
|
+
system_prompt_id = systemPrompt.id;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
let context_template_id = null;
|
|
97
|
+
if (context_template_name) {
|
|
98
|
+
const contextTemplate = await this.contextTemplatesService.findByBuiltinKey(context_template_name.replace(/_/g, '-'));
|
|
99
|
+
if (!contextTemplate) {
|
|
100
|
+
this.logger.warn(`Context template with builtin_key "${context_template_name.replace(/_/g, '-')}" not found for agent "${name}"`);
|
|
101
|
+
}
|
|
102
|
+
else {
|
|
103
|
+
context_template_id = contextTemplate.id;
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
let followup_context_template_id = null;
|
|
107
|
+
if (followup_context_template_name) {
|
|
108
|
+
const followupContextTemplate = await this.contextTemplatesService.findByBuiltinKey(followup_context_template_name.replace(/_/g, '-'));
|
|
109
|
+
if (!followupContextTemplate) {
|
|
110
|
+
this.logger.warn(`Followup context template with builtin_key "${followup_context_template_name.replace(/_/g, '-')}" not found for agent "${name}"`);
|
|
111
|
+
}
|
|
112
|
+
else {
|
|
113
|
+
followup_context_template_id = followupContextTemplate.id;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
const newAgent = this.agentRepository.create({
|
|
117
|
+
name,
|
|
118
|
+
description: description || null,
|
|
119
|
+
system_prompt_id,
|
|
120
|
+
context_template_id,
|
|
121
|
+
followup_context_template_id,
|
|
122
|
+
model_id: model_id || null,
|
|
123
|
+
reasoning_effort: reasoning_effort || null,
|
|
124
|
+
is_default: builtinKey === 'default-agent',
|
|
125
|
+
is_active: is_active !== false,
|
|
126
|
+
is_builtin: true,
|
|
127
|
+
builtin_key: builtinKey,
|
|
128
|
+
});
|
|
129
|
+
await this.agentRepository.save(newAgent);
|
|
130
|
+
this.logger.log(`Built-in agent "${name}" seeded.`);
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
catch (error) {
|
|
134
|
+
this.logger.error(`Failed to seed agent from ${filePath}`, error.stack);
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
};
|
|
139
|
+
exports.AgentSeedingService = AgentSeedingService;
|
|
140
|
+
exports.AgentSeedingService = AgentSeedingService = AgentSeedingService_1 = __decorate([
|
|
141
|
+
(0, common_1.Injectable)(),
|
|
142
|
+
__param(0, (0, typeorm_1.InjectRepository)(core_entities_1.Agent)),
|
|
143
|
+
__metadata("design:paramtypes", [typeorm_2.Repository,
|
|
144
|
+
system_prompts_service_1.SystemPromptsService,
|
|
145
|
+
context_templates_service_1.ContextTemplatesService])
|
|
146
|
+
], AgentSeedingService);
|
|
147
|
+
//# sourceMappingURL=agent-seeding.service.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-seeding.service.js","sourceRoot":"","sources":["../../../src/seeding/agent-seeding.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2CAAoD;AACpD,6CAAmD;AACnD,qCAAqC;AACrC,oDAAyC;AACzC,qFAAgF;AAChF,8FAAyF;AACzF,6BAA6B;AAC7B,+BAA4B;AAGrB,IAAM,mBAAmB,2BAAzB,MAAM,mBAAmB;IAG9B,YAEE,eAAmD,EAClC,oBAA0C,EAC1C,uBAAgD;QAFhD,oBAAe,GAAf,eAAe,CAAmB;QAClC,yBAAoB,GAApB,oBAAoB,CAAsB;QAC1C,4BAAuB,GAAvB,uBAAuB,CAAyB;QANlD,WAAM,GAAG,IAAI,eAAM,CAAC,qBAAmB,CAAC,IAAI,CAAC,CAAC;IAO5D,CAAC;IAEJ,KAAK,CAAC,IAAI;QACR,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,8BAA8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GAAE;IAKR,WAAA,IAAA,0BAAgB,EAAC,qBAAK,CAAC,CAAA;qCACU,oBAAU;QACL,6CAAoB;QACjB,mDAAuB;GAPxD,mBAAmB,CA+K/B"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const name = "Config Manager";
|
|
2
|
+
export declare const description = "Specialized agent for managing RepoBurg configuration \u2014 system prompts, context templates, snippets, variables, agents, sub-agents, MCP servers, and tool hooks.";
|
|
3
|
+
export declare const system_prompt_name = "config-manager-agent";
|
|
4
|
+
export declare const context_template_name = "config-manager-initial-context";
|
|
5
|
+
export declare const followup_context_template_name = "config-manager-followup-context";
|
|
6
|
+
export declare const model_id: any;
|
|
7
|
+
export declare const reasoning_effort: any;
|
|
8
|
+
export declare const is_active = true;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.is_active = exports.reasoning_effort = exports.model_id = exports.followup_context_template_name = exports.context_template_name = exports.system_prompt_name = exports.description = exports.name = void 0;
|
|
4
|
+
exports.name = 'Config Manager';
|
|
5
|
+
exports.description = 'Specialized agent for managing RepoBurg configuration — system prompts, context templates, snippets, variables, agents, sub-agents, MCP servers, and tool hooks.';
|
|
6
|
+
exports.system_prompt_name = 'config-manager-agent';
|
|
7
|
+
exports.context_template_name = 'config-manager-initial-context';
|
|
8
|
+
exports.followup_context_template_name = 'config-manager-followup-context';
|
|
9
|
+
exports.model_id = null;
|
|
10
|
+
exports.reasoning_effort = null;
|
|
11
|
+
exports.is_active = true;
|
|
12
|
+
//# sourceMappingURL=config-manager.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config-manager.js","sourceRoot":"","sources":["../../../../../src/seeding/data/agents/config-manager.ts"],"names":[],"mappings":";;;AAAa,QAAA,IAAI,GAAG,gBAAgB,CAAC;AACxB,QAAA,WAAW,GACtB,kKAAkK,CAAC;AACxJ,QAAA,kBAAkB,GAAG,sBAAsB,CAAC;AAC5C,QAAA,qBAAqB,GAAG,gCAAgC,CAAC;AACzD,QAAA,8BAA8B,GAAG,iCAAiC,CAAC;AACnE,QAAA,QAAQ,GAAG,IAAI,CAAC;AAChB,QAAA,gBAAgB,GAAG,IAAI,CAAC;AACxB,QAAA,SAAS,GAAG,IAAI,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const name = "Default Agent";
|
|
2
|
+
export declare const description = "Default agent with full tool access for general development tasks";
|
|
3
|
+
export declare const system_prompt_name = "default-native-tool-agent";
|
|
4
|
+
export declare const context_template_name = "default-initial_full-project-context";
|
|
5
|
+
export declare const followup_context_template_name = "default-followup_ad-hoc-focused-context";
|
|
6
|
+
export declare const model_id: any;
|
|
7
|
+
export declare const reasoning_effort: any;
|
|
8
|
+
export declare const is_active = true;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.is_active = exports.reasoning_effort = exports.model_id = exports.followup_context_template_name = exports.context_template_name = exports.system_prompt_name = exports.description = exports.name = void 0;
|
|
4
|
+
exports.name = 'Default Agent';
|
|
5
|
+
exports.description = 'Default agent with full tool access for general development tasks';
|
|
6
|
+
exports.system_prompt_name = 'default-native-tool-agent';
|
|
7
|
+
exports.context_template_name = 'default-initial_full-project-context';
|
|
8
|
+
exports.followup_context_template_name = 'default-followup_ad-hoc-focused-context';
|
|
9
|
+
exports.model_id = null;
|
|
10
|
+
exports.reasoning_effort = null;
|
|
11
|
+
exports.is_active = true;
|
|
12
|
+
//# sourceMappingURL=default-agent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"default-agent.js","sourceRoot":"","sources":["../../../../../src/seeding/data/agents/default-agent.ts"],"names":[],"mappings":";;;AAAa,QAAA,IAAI,GAAG,eAAe,CAAC;AACvB,QAAA,WAAW,GACtB,mEAAmE,CAAC;AACzD,QAAA,kBAAkB,GAAG,2BAA2B,CAAC;AACjD,QAAA,qBAAqB,GAAG,sCAAsC,CAAC;AAC/D,QAAA,8BAA8B,GACzC,yCAAyC,CAAC;AAC/B,QAAA,QAAQ,GAAG,IAAI,CAAC;AAChB,QAAA,gBAAgB,GAAG,IAAI,CAAC;AACxB,QAAA,SAAS,GAAG,IAAI,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const template_name = "Config Manager Follow-up";
|
|
2
|
+
export declare const template_type = "main";
|
|
3
|
+
export declare const is_default_initial = false;
|
|
4
|
+
export declare const is_default_followup = false;
|
|
5
|
+
export declare const is_default_condensed = false;
|
|
6
|
+
export declare const is_builtin = true;
|
|
7
|
+
export declare const builtin_key = "config-manager-followup-context";
|
|
8
|
+
export declare const context_definition: string;
|
|
9
|
+
export declare const template_content = "<% if (it.user_prev_action) { %>\n### Previous Actions Summary\n<%~ it.user_prev_action %>\n<% } %>\n\n<%~ it.context_snippets_content %>\n\n<%~ it.adhoc_files_content %>\n\n<%~ it.adhoc_folders_content %>\n\n<%~ it.adhoc_command_outputs_content %>\n\nUser Request:\n<%~ it.user_input %>\n";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.template_content = exports.context_definition = exports.builtin_key = exports.is_builtin = exports.is_default_condensed = exports.is_default_followup = exports.is_default_initial = exports.template_type = exports.template_name = void 0;
|
|
4
|
+
exports.template_name = 'Config Manager Follow-up';
|
|
5
|
+
exports.template_type = 'main';
|
|
6
|
+
exports.is_default_initial = false;
|
|
7
|
+
exports.is_default_followup = false;
|
|
8
|
+
exports.is_default_condensed = false;
|
|
9
|
+
exports.is_builtin = true;
|
|
10
|
+
exports.builtin_key = 'config-manager-followup-context';
|
|
11
|
+
exports.context_definition = JSON.stringify({ files: [], folders: [] });
|
|
12
|
+
exports.template_content = `<% if (it.user_prev_action) { %>
|
|
13
|
+
### Previous Actions Summary
|
|
14
|
+
<%~ it.user_prev_action %>
|
|
15
|
+
<% } %>
|
|
16
|
+
|
|
17
|
+
<%~ it.context_snippets_content %>
|
|
18
|
+
|
|
19
|
+
<%~ it.adhoc_files_content %>
|
|
20
|
+
|
|
21
|
+
<%~ it.adhoc_folders_content %>
|
|
22
|
+
|
|
23
|
+
<%~ it.adhoc_command_outputs_content %>
|
|
24
|
+
|
|
25
|
+
User Request:
|
|
26
|
+
<%~ it.user_input %>
|
|
27
|
+
`;
|
|
28
|
+
//# sourceMappingURL=config-manager-followup-context.js.map
|
package/backend/dist/src/seeding/data/context-templates/config-manager-followup-context.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config-manager-followup-context.js","sourceRoot":"","sources":["../../../../../src/seeding/data/context-templates/config-manager-followup-context.ts"],"names":[],"mappings":";;;AAAa,QAAA,aAAa,GAAG,0BAA0B,CAAC;AAC3C,QAAA,aAAa,GAAG,MAAM,CAAC;AACvB,QAAA,kBAAkB,GAAG,KAAK,CAAC;AAC3B,QAAA,mBAAmB,GAAG,KAAK,CAAC;AAC5B,QAAA,oBAAoB,GAAG,KAAK,CAAC;AAC7B,QAAA,UAAU,GAAG,IAAI,CAAC;AAClB,QAAA,WAAW,GAAG,iCAAiC,CAAC;AAChD,QAAA,kBAAkB,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAC;AAChE,QAAA,gBAAgB,GAAG;;;;;;;;;;;;;;;CAe/B,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const template_name = "Config Manager Initial";
|
|
2
|
+
export declare const template_type = "main";
|
|
3
|
+
export declare const is_default_initial = false;
|
|
4
|
+
export declare const is_default_followup = false;
|
|
5
|
+
export declare const is_default_condensed = false;
|
|
6
|
+
export declare const is_builtin = true;
|
|
7
|
+
export declare const builtin_key = "config-manager-initial-context";
|
|
8
|
+
export declare const context_definition: string;
|
|
9
|
+
export declare const template_content = "<%~ it.context_snippets_content %>\n\n<%~ it.adhoc_files_content %>\n\n<%~ it.adhoc_folders_content %>\n\nUser Request:\n\n<%~ it.user_input %>\n";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.template_content = exports.context_definition = exports.builtin_key = exports.is_builtin = exports.is_default_condensed = exports.is_default_followup = exports.is_default_initial = exports.template_type = exports.template_name = void 0;
|
|
4
|
+
exports.template_name = 'Config Manager Initial';
|
|
5
|
+
exports.template_type = 'main';
|
|
6
|
+
exports.is_default_initial = false;
|
|
7
|
+
exports.is_default_followup = false;
|
|
8
|
+
exports.is_default_condensed = false;
|
|
9
|
+
exports.is_builtin = true;
|
|
10
|
+
exports.builtin_key = 'config-manager-initial-context';
|
|
11
|
+
exports.context_definition = JSON.stringify({ files: [], folders: [] });
|
|
12
|
+
exports.template_content = `<%~ it.context_snippets_content %>
|
|
13
|
+
|
|
14
|
+
<%~ it.adhoc_files_content %>
|
|
15
|
+
|
|
16
|
+
<%~ it.adhoc_folders_content %>
|
|
17
|
+
|
|
18
|
+
User Request:
|
|
19
|
+
|
|
20
|
+
<%~ it.user_input %>
|
|
21
|
+
`;
|
|
22
|
+
//# sourceMappingURL=config-manager-initial-context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config-manager-initial-context.js","sourceRoot":"","sources":["../../../../../src/seeding/data/context-templates/config-manager-initial-context.ts"],"names":[],"mappings":";;;AAAa,QAAA,aAAa,GAAG,wBAAwB,CAAC;AACzC,QAAA,aAAa,GAAG,MAAM,CAAC;AACvB,QAAA,kBAAkB,GAAG,KAAK,CAAC;AAC3B,QAAA,mBAAmB,GAAG,KAAK,CAAC;AAC5B,QAAA,oBAAoB,GAAG,KAAK,CAAC;AAC7B,QAAA,UAAU,GAAG,IAAI,CAAC;AAClB,QAAA,WAAW,GAAG,gCAAgC,CAAC;AAC/C,QAAA,kBAAkB,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAC;AAChE,QAAA,gBAAgB,GAAG;;;;;;;;;CAS/B,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare const name = "Config Manager";
|
|
2
2
|
export declare const enabled_tools: string[];
|
|
3
|
-
export declare const content = "You are a RepoBurg Configuration Manager \u2014 a specialized agent for managing all aspects of the RepoBurg system configuration.\n\n## Role\nYou manage RepoBurg's own configuration: system prompts, context templates, context snippets, custom snippets, custom variables, sub-agents, MCP servers, and tool hooks. Think of you as the admin panel agent.\n\n## Key Principles\n1. **Read before write:** Always list or get an entity before modifying it to understand the current state.\n2. **Preserve built-ins:** Built-in entities (is_builtin=true) cannot be updated or deleted. Duplicate them to create editable copies.\n3. **Be precise:** Use exact UUIDs when referencing entities by ID. Use exact names when referencing by name.\n4. **JSON data:** When creating or updating entities, provide the data as a structured object with the exact field names documented in each tool.\n\n## Available Tools\n\n### System Prompts (manage_system_prompts)\nSystem prompts define the AI's behavior. They are Eta templates that get rendered with tool definitions and variables.\n- Actions: list, get, get_raw, create, update, delete, duplicate, set_default, set_enabled_tools, set_enabled_mcp_tools, toggle_tool, toggle_mcp_tool, preview\n- Key fields: prompt_name, prompt_content (Eta template), is_default, url, followup_token_limit\n\n### Context Templates (manage_context_templates)\nContext templates define how context (files, folders, tools) is assembled for LLM prompts. They use Eta syntax.\n- Actions: list, get, create, update, delete, duplicate, set_default_initial, set_default_followup, set_default_condensed\n- Key fields: template_name, template_content (Eta), context_definition (JSON), template_type (\"main\"|\"partial\")\n\n### Context Snippets (manage_context_snippets)\nContext snippets are reusable Eta template blocks accessible via it.snippets.handle in context templates.\n- Actions: list, get, create, update, delete\n- Key fields: handle (unique identifier), description, template_content (Eta)\n\n### Custom Snippets (manage_custom_snippets)\nCustom snippets are text expansion templates triggered by a prefix. Like VS Code snippets.\n- Actions: list, get, create, update, delete, duplicate\n- Key fields: prefix (trigger), description, body (expanded content), scope\n\n### Custom Variables (manage_custom_variables)\nCustom variables are key-value pairs available in templates via it.variables.KEY.\n- Actions: list, create, update, delete\n- Key fields: key (unique), value, enabled, is_freq_used, order_number\n\n### Sub-Agents (manage_sub_agents)\nSub-agents are specialized agent configurations
|
|
3
|
+
export declare const content = "You are a RepoBurg Configuration Manager \u2014 a specialized agent for managing all aspects of the RepoBurg system configuration.\n\n## Role\nYou manage RepoBurg's own configuration: system prompts, context templates, context snippets, custom snippets, custom variables, agents, sub-agents, MCP servers, and tool hooks. Think of you as the admin panel agent.\n\n## Key Principles\n1. **Read before write:** Always list or get an entity before modifying it to understand the current state.\n2. **Preserve built-ins:** Built-in entities (is_builtin=true) cannot be updated or deleted. Duplicate them to create editable copies.\n3. **Be precise:** Use exact UUIDs when referencing entities by ID. Use exact names when referencing by name.\n4. **JSON data:** When creating or updating entities, provide the data as a structured object with the exact field names documented in each tool.\n\n## Available Tools\n\n### System Prompts (manage_system_prompts)\nSystem prompts define the AI's behavior. They are Eta templates that get rendered with tool definitions and variables.\n- Actions: list, get, get_raw, create, update, delete, duplicate, set_default, set_enabled_tools, set_enabled_mcp_tools, toggle_tool, toggle_mcp_tool, preview\n- Key fields: prompt_name, prompt_content (Eta template), is_default, url, followup_token_limit\n\n### Context Templates (manage_context_templates)\nContext templates define how context (files, folders, tools) is assembled for LLM prompts. They use Eta syntax.\n- Actions: list, get, create, update, delete, duplicate, set_default_initial, set_default_followup, set_default_condensed\n- Key fields: template_name, template_content (Eta), context_definition (JSON), template_type (\"main\"|\"partial\")\n\n### Context Snippets (manage_context_snippets)\nContext snippets are reusable Eta template blocks accessible via it.snippets.handle in context templates.\n- Actions: list, get, create, update, delete\n- Key fields: handle (unique identifier), description, template_content (Eta)\n\n### Custom Snippets (manage_custom_snippets)\nCustom snippets are text expansion templates triggered by a prefix. Like VS Code snippets.\n- Actions: list, get, create, update, delete, duplicate\n- Key fields: prefix (trigger), description, body (expanded content), scope\n\n### Custom Variables (manage_custom_variables)\nCustom variables are key-value pairs available in templates via it.variables.KEY.\n- Actions: list, create, update, delete\n- Key fields: key (unique), value, enabled, is_freq_used, order_number\n\n### Agents (manage_agents)\nAgents are presets that group a system prompt, context templates, model, and reasoning effort together. Selecting an agent applies all its settings to a session at once.\n- Actions: list, get, create, update, delete, duplicate, set_default\n- Key fields: name, description, system_prompt_id, context_template_id, followup_context_template_id, model_id, reasoning_effort (\"low\"|\"medium\"|\"high\"), is_default, is_active, is_builtin\n- Built-in agents (is_builtin=true) can only have is_active, model_id, and reasoning_effort modified. Duplicate them to create fully editable copies.\n- Setting an agent as default clears the previous default.\n\n### Sub-Agents (manage_sub_agents)\nSub-agents are specialized agent configurations invoked by the master agent for specific tasks. They have their own system prompt, context templates, and restricted tool access.\n- Actions: list, get, create, update, delete, duplicate\n- Key fields: name, description, system_prompt_id, context_template_id, followup_context_template_id, enabled_tools, enabled_mcp_tools, is_active, model_id\n\n### MCP Servers (manage_mcp_servers)\nMCP servers provide external tools. Each active server's tools become available to the AI.\n- Actions: list, create, toggle_active, delete, toggle_tools\n- Key fields: server_name, command, args, env, is_active\n\n### Tool Hooks (manage_tool_hooks)\nTool hooks are custom scripts that run before or after tool execution for validation, logging, or modification.\n- Actions: list, create, update, delete, list_scripts, create_script, test\n- Key fields: tool_name, timing (\"before\"|\"after\"), script_filename, is_active\n\n\n";
|
|
@@ -11,6 +11,7 @@ exports.enabled_tools = [
|
|
|
11
11
|
'manage_context_snippets',
|
|
12
12
|
'manage_custom_snippets',
|
|
13
13
|
'manage_custom_variables',
|
|
14
|
+
'manage_agents',
|
|
14
15
|
'manage_sub_agents',
|
|
15
16
|
'manage_mcp_servers',
|
|
16
17
|
'manage_tool_hooks',
|
|
@@ -23,7 +24,7 @@ exports.enabled_tools = [
|
|
|
23
24
|
exports.content = `You are a RepoBurg Configuration Manager — a specialized agent for managing all aspects of the RepoBurg system configuration.
|
|
24
25
|
|
|
25
26
|
## Role
|
|
26
|
-
You manage RepoBurg's own configuration: system prompts, context templates, context snippets, custom snippets, custom variables, sub-agents, MCP servers, and tool hooks. Think of you as the admin panel agent.
|
|
27
|
+
You manage RepoBurg's own configuration: system prompts, context templates, context snippets, custom snippets, custom variables, agents, sub-agents, MCP servers, and tool hooks. Think of you as the admin panel agent.
|
|
27
28
|
|
|
28
29
|
## Key Principles
|
|
29
30
|
1. **Read before write:** Always list or get an entity before modifying it to understand the current state.
|
|
@@ -58,8 +59,15 @@ Custom variables are key-value pairs available in templates via it.variables.KEY
|
|
|
58
59
|
- Actions: list, create, update, delete
|
|
59
60
|
- Key fields: key (unique), value, enabled, is_freq_used, order_number
|
|
60
61
|
|
|
62
|
+
### Agents (manage_agents)
|
|
63
|
+
Agents are presets that group a system prompt, context templates, model, and reasoning effort together. Selecting an agent applies all its settings to a session at once.
|
|
64
|
+
- Actions: list, get, create, update, delete, duplicate, set_default
|
|
65
|
+
- Key fields: name, description, system_prompt_id, context_template_id, followup_context_template_id, model_id, reasoning_effort ("low"|"medium"|"high"), is_default, is_active, is_builtin
|
|
66
|
+
- Built-in agents (is_builtin=true) can only have is_active, model_id, and reasoning_effort modified. Duplicate them to create fully editable copies.
|
|
67
|
+
- Setting an agent as default clears the previous default.
|
|
68
|
+
|
|
61
69
|
### Sub-Agents (manage_sub_agents)
|
|
62
|
-
Sub-agents are specialized agent configurations
|
|
70
|
+
Sub-agents are specialized agent configurations invoked by the master agent for specific tasks. They have their own system prompt, context templates, and restricted tool access.
|
|
63
71
|
- Actions: list, get, create, update, delete, duplicate
|
|
64
72
|
- Key fields: name, description, system_prompt_id, context_template_id, followup_context_template_id, enabled_tools, enabled_mcp_tools, is_active, model_id
|
|
65
73
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-manager-agent.js","sourceRoot":"","sources":["../../../../../src/seeding/data/system-prompts/config-manager-agent.ts"],"names":[],"mappings":";;;AAAa,QAAA,IAAI,GAAG,gBAAgB,CAAC;AACxB,QAAA,aAAa,GAAG;IAC3B,iBAAiB;IACjB,aAAa;IACb,YAAY;IACZ,uBAAuB;IACvB,0BAA0B;IAC1B,yBAAyB;IACzB,wBAAwB;IACxB,yBAAyB;IACzB,mBAAmB;IACnB,oBAAoB;IACpB,mBAAmB;IACnB,OAAO;IACP,YAAY;IACZ,UAAU;IACV,cAAc;IACd,kBAAkB;CACnB,CAAC;AACW,QAAA,OAAO,GAAG
|
|
1
|
+
{"version":3,"file":"config-manager-agent.js","sourceRoot":"","sources":["../../../../../src/seeding/data/system-prompts/config-manager-agent.ts"],"names":[],"mappings":";;;AAAa,QAAA,IAAI,GAAG,gBAAgB,CAAC;AACxB,QAAA,aAAa,GAAG;IAC3B,iBAAiB;IACjB,aAAa;IACb,YAAY;IACZ,uBAAuB;IACvB,0BAA0B;IAC1B,yBAAyB;IACzB,wBAAwB;IACxB,yBAAyB;IACzB,eAAe;IACf,mBAAmB;IACnB,oBAAoB;IACpB,mBAAmB;IACnB,OAAO;IACP,YAAY;IACZ,UAAU;IACV,cAAc;IACd,kBAAkB;CACnB,CAAC;AACW,QAAA,OAAO,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6DtB,CAAC"}
|
|
@@ -25,6 +25,9 @@ const sub_agent_seeding_service_1 = require("./sub-agent-seeding.service");
|
|
|
25
25
|
const sub_agent_entity_1 = require("../sub-agents/sub-agent.entity");
|
|
26
26
|
const context_snippets_module_1 = require("../context-snippets/context-snippets.module");
|
|
27
27
|
const context_snippet_seeding_service_1 = require("./context-snippet-seeding.service");
|
|
28
|
+
const agents_module_1 = require("../agents/agents.module");
|
|
29
|
+
const agent_seeding_service_1 = require("./agent-seeding.service");
|
|
30
|
+
const core_entities_2 = require("../core-entities");
|
|
28
31
|
let SeedingModule = class SeedingModule {
|
|
29
32
|
};
|
|
30
33
|
exports.SeedingModule = SeedingModule;
|
|
@@ -37,7 +40,8 @@ exports.SeedingModule = SeedingModule = __decorate([
|
|
|
37
40
|
custom_variables_module_1.CustomVariablesModule,
|
|
38
41
|
sub_agents_module_1.SubAgentsModule,
|
|
39
42
|
context_snippets_module_1.ContextSnippetsModule,
|
|
40
|
-
|
|
43
|
+
agents_module_1.AgentsModule,
|
|
44
|
+
typeorm_1.TypeOrmModule.forFeature([core_entities_1.McpConfig, sub_agent_entity_1.SubAgent, core_entities_2.Agent]),
|
|
41
45
|
],
|
|
42
46
|
providers: [
|
|
43
47
|
seeding_service_1.SeedingService,
|
|
@@ -48,6 +52,7 @@ exports.SeedingModule = SeedingModule = __decorate([
|
|
|
48
52
|
custom_variable_seeding_service_1.CustomVariableSeedingService,
|
|
49
53
|
sub_agent_seeding_service_1.SubAgentSeedingService,
|
|
50
54
|
context_snippet_seeding_service_1.ContextSnippetSeedingService,
|
|
55
|
+
agent_seeding_service_1.AgentSeedingService,
|
|
51
56
|
],
|
|
52
57
|
exports: [seeding_service_1.SeedingService],
|
|
53
58
|
})
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"seeding.module.js","sourceRoot":"","sources":["../../../src/seeding/seeding.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAwC;AACxC,uDAAmD;AACnD,mFAA8E;AAC9E,4FAAuF;AACvF,mFAA6E;AAC7E,yFAAmF;AACnF,sFAAiF;AACjF,qFAA+E;AAC/E,6CAAgD;AAChD,oDAA6C;AAC7C,6EAAuE;AACvE,yFAAoF;AACpF,uFAAiF;AACjF,uEAAkE;AAClE,2EAAqE;AACrE,qEAA0D;AAC1D,yFAAoF;AACpF,uFAAiF;
|
|
1
|
+
{"version":3,"file":"seeding.module.js","sourceRoot":"","sources":["../../../src/seeding/seeding.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAwC;AACxC,uDAAmD;AACnD,mFAA8E;AAC9E,4FAAuF;AACvF,mFAA6E;AAC7E,yFAAmF;AACnF,sFAAiF;AACjF,qFAA+E;AAC/E,6CAAgD;AAChD,oDAA6C;AAC7C,6EAAuE;AACvE,yFAAoF;AACpF,uFAAiF;AACjF,uEAAkE;AAClE,2EAAqE;AACrE,qEAA0D;AAC1D,yFAAoF;AACpF,uFAAiF;AACjF,2DAAuD;AACvD,mEAA8D;AAC9D,oDAAyC;AA0BlC,IAAM,aAAa,GAAnB,MAAM,aAAa;CAAG,CAAA;AAAhB,sCAAa;wBAAb,aAAa;IAxBzB,IAAA,eAAM,EAAC;QACN,OAAO,EAAE;YACP,2CAAmB;YACnB,iDAAsB;YACtB,6CAAoB;YACpB,+CAAqB;YACrB,mCAAe;YACf,+CAAqB;YACrB,4BAAY;YACZ,uBAAa,CAAC,UAAU,CAAC,CAAC,yBAAS,EAAE,2BAAQ,EAAE,qBAAK,CAAC,CAAC;SACvD;QACD,SAAS,EAAE;YACT,gCAAc;YACd,0DAA0B;YAC1B,gEAA6B;YAC7B,4DAA2B;YAC3B,oDAAuB;YACvB,8DAA4B;YAC5B,kDAAsB;YACtB,8DAA4B;YAC5B,2CAAmB;SACpB;QACD,OAAO,EAAE,CAAC,gCAAc,CAAC;KAC1B,CAAC;GACW,aAAa,CAAG"}
|
|
@@ -5,6 +5,7 @@ import { McpConfigSeedingService } from './mcp-config-seeding.service';
|
|
|
5
5
|
import { CustomVariableSeedingService } from './custom-variable-seeding.service';
|
|
6
6
|
import { SubAgentSeedingService } from './sub-agent-seeding.service';
|
|
7
7
|
import { ContextSnippetSeedingService } from './context-snippet-seeding.service';
|
|
8
|
+
import { AgentSeedingService } from './agent-seeding.service';
|
|
8
9
|
export declare class SeedingService {
|
|
9
10
|
private readonly systemPromptSeedingService;
|
|
10
11
|
private readonly contextTemplateSeedingService;
|
|
@@ -13,7 +14,8 @@ export declare class SeedingService {
|
|
|
13
14
|
private readonly customVariableSeedingService;
|
|
14
15
|
private readonly subAgentSeedingService;
|
|
15
16
|
private readonly contextSnippetSeedingService;
|
|
17
|
+
private readonly agentSeedingService;
|
|
16
18
|
private readonly logger;
|
|
17
|
-
constructor(systemPromptSeedingService: SystemPromptSeedingService, contextTemplateSeedingService: ContextTemplateSeedingService, customSnippetSeedingService: CustomSnippetSeedingService, mcpConfigSeedingService: McpConfigSeedingService, customVariableSeedingService: CustomVariableSeedingService, subAgentSeedingService: SubAgentSeedingService, contextSnippetSeedingService: ContextSnippetSeedingService);
|
|
19
|
+
constructor(systemPromptSeedingService: SystemPromptSeedingService, contextTemplateSeedingService: ContextTemplateSeedingService, customSnippetSeedingService: CustomSnippetSeedingService, mcpConfigSeedingService: McpConfigSeedingService, customVariableSeedingService: CustomVariableSeedingService, subAgentSeedingService: SubAgentSeedingService, contextSnippetSeedingService: ContextSnippetSeedingService, agentSeedingService: AgentSeedingService);
|
|
18
20
|
seed(): Promise<void>;
|
|
19
21
|
}
|
|
@@ -19,8 +19,9 @@ const mcp_config_seeding_service_1 = require("./mcp-config-seeding.service");
|
|
|
19
19
|
const custom_variable_seeding_service_1 = require("./custom-variable-seeding.service");
|
|
20
20
|
const sub_agent_seeding_service_1 = require("./sub-agent-seeding.service");
|
|
21
21
|
const context_snippet_seeding_service_1 = require("./context-snippet-seeding.service");
|
|
22
|
+
const agent_seeding_service_1 = require("./agent-seeding.service");
|
|
22
23
|
let SeedingService = SeedingService_1 = class SeedingService {
|
|
23
|
-
constructor(systemPromptSeedingService, contextTemplateSeedingService, customSnippetSeedingService, mcpConfigSeedingService, customVariableSeedingService, subAgentSeedingService, contextSnippetSeedingService) {
|
|
24
|
+
constructor(systemPromptSeedingService, contextTemplateSeedingService, customSnippetSeedingService, mcpConfigSeedingService, customVariableSeedingService, subAgentSeedingService, contextSnippetSeedingService, agentSeedingService) {
|
|
24
25
|
this.systemPromptSeedingService = systemPromptSeedingService;
|
|
25
26
|
this.contextTemplateSeedingService = contextTemplateSeedingService;
|
|
26
27
|
this.customSnippetSeedingService = customSnippetSeedingService;
|
|
@@ -28,6 +29,7 @@ let SeedingService = SeedingService_1 = class SeedingService {
|
|
|
28
29
|
this.customVariableSeedingService = customVariableSeedingService;
|
|
29
30
|
this.subAgentSeedingService = subAgentSeedingService;
|
|
30
31
|
this.contextSnippetSeedingService = contextSnippetSeedingService;
|
|
32
|
+
this.agentSeedingService = agentSeedingService;
|
|
31
33
|
this.logger = new common_1.Logger(SeedingService_1.name);
|
|
32
34
|
}
|
|
33
35
|
async seed() {
|
|
@@ -38,6 +40,7 @@ let SeedingService = SeedingService_1 = class SeedingService {
|
|
|
38
40
|
await this.customVariableSeedingService.seed();
|
|
39
41
|
await this.subAgentSeedingService.seed();
|
|
40
42
|
await this.contextSnippetSeedingService.seed();
|
|
43
|
+
await this.agentSeedingService.seed();
|
|
41
44
|
this.logger.log('Seeding complete.');
|
|
42
45
|
}
|
|
43
46
|
};
|
|
@@ -50,6 +53,7 @@ exports.SeedingService = SeedingService = SeedingService_1 = __decorate([
|
|
|
50
53
|
mcp_config_seeding_service_1.McpConfigSeedingService,
|
|
51
54
|
custom_variable_seeding_service_1.CustomVariableSeedingService,
|
|
52
55
|
sub_agent_seeding_service_1.SubAgentSeedingService,
|
|
53
|
-
context_snippet_seeding_service_1.ContextSnippetSeedingService
|
|
56
|
+
context_snippet_seeding_service_1.ContextSnippetSeedingService,
|
|
57
|
+
agent_seeding_service_1.AgentSeedingService])
|
|
54
58
|
], SeedingService);
|
|
55
59
|
//# sourceMappingURL=seeding.service.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"seeding.service.js","sourceRoot":"","sources":["../../../src/seeding/seeding.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAAoD;AACpD,yFAAmF;AACnF,mFAA6E;AAC7E,qFAA+E;AAC/E,6EAAuE;AACvE,uFAAiF;AACjF,2EAAqE;AACrE,uFAAiF;
|
|
1
|
+
{"version":3,"file":"seeding.service.js","sourceRoot":"","sources":["../../../src/seeding/seeding.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAAoD;AACpD,yFAAmF;AACnF,mFAA6E;AAC7E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AD1B,IAAA,mBAAU,GAAE;qCAKoC,0DAA0B;QACvB,gEAA6B;QAC/B,4DAA2B;QAC/B,oDAAuB;QAClB,8DAA4B;QAClC,kDAAsB;QAChB,8DAA4B;QACrC,2CAAmB;GAXhD,cAAc,CAyB1B"}
|
|
@@ -254,6 +254,9 @@ let SubAgentRunner = SubAgentRunner_1 = class SubAgentRunner {
|
|
|
254
254
|
this.eventsGateway.sendToAll('refresh-ui', {
|
|
255
255
|
sessionId: childSession.id,
|
|
256
256
|
});
|
|
257
|
+
this.eventsGateway.sendToAll('refresh-ui', {
|
|
258
|
+
sessionId: parentSessionId,
|
|
259
|
+
});
|
|
257
260
|
let iterations = 0;
|
|
258
261
|
let finalContent = '';
|
|
259
262
|
let success = true;
|
|
@@ -306,6 +309,9 @@ let SubAgentRunner = SubAgentRunner_1 = class SubAgentRunner {
|
|
|
306
309
|
this.eventsGateway.sendToAll('refresh-ui', {
|
|
307
310
|
sessionId: childSession.id,
|
|
308
311
|
});
|
|
312
|
+
this.eventsGateway.sendToAll('refresh-ui', {
|
|
313
|
+
sessionId: parentSessionId,
|
|
314
|
+
});
|
|
309
315
|
if (!llmResponse.tool_calls || llmResponse.tool_calls.length === 0) {
|
|
310
316
|
this.logger.log(`Sub-agent "${agentName}" returned text with no tool calls. Ending loop.`);
|
|
311
317
|
finalContent = llmResponse.text || '';
|
|
@@ -487,6 +493,9 @@ let SubAgentRunner = SubAgentRunner_1 = class SubAgentRunner {
|
|
|
487
493
|
this.eventsGateway.sendToAll('refresh-ui', {
|
|
488
494
|
sessionId: childSession.id,
|
|
489
495
|
});
|
|
496
|
+
this.eventsGateway.sendToAll('refresh-ui', {
|
|
497
|
+
sessionId: parentSessionId,
|
|
498
|
+
});
|
|
490
499
|
if (shouldBreak) {
|
|
491
500
|
break;
|
|
492
501
|
}
|
|
@@ -503,6 +512,9 @@ let SubAgentRunner = SubAgentRunner_1 = class SubAgentRunner {
|
|
|
503
512
|
this.eventsGateway.sendToAll('refresh-ui', {
|
|
504
513
|
sessionId: childSession.id,
|
|
505
514
|
});
|
|
515
|
+
this.eventsGateway.sendToAll('refresh-ui', {
|
|
516
|
+
sessionId: parentSessionId,
|
|
517
|
+
});
|
|
506
518
|
}
|
|
507
519
|
catch (error) {
|
|
508
520
|
this.logger.error(`Sub-agent "${agentName}" failed: ${error.message}`, error.stack);
|
|
@@ -512,6 +524,9 @@ let SubAgentRunner = SubAgentRunner_1 = class SubAgentRunner {
|
|
|
512
524
|
this.eventsGateway.sendToAll('refresh-ui', {
|
|
513
525
|
sessionId: childSession.id,
|
|
514
526
|
});
|
|
527
|
+
this.eventsGateway.sendToAll('refresh-ui', {
|
|
528
|
+
sessionId: parentSessionId,
|
|
529
|
+
});
|
|
515
530
|
}
|
|
516
531
|
const durationMs = Date.now() - startTime;
|
|
517
532
|
this.logger.log(`Sub-agent "${agentName}" completed in ${durationMs}ms, ${iterations} iterations, success: ${success}`);
|