@djibrilm/lazy-review 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +95 -0
- package/dist/bin.d.ts +3 -0
- package/dist/bin.d.ts.map +1 -0
- package/dist/bin.js +17 -0
- package/dist/bin.js.map +1 -0
- package/dist/client/assets/geist-cyrillic-ext-wght-normal-DjL33-gN.woff2 +0 -0
- package/dist/client/assets/geist-cyrillic-wght-normal-BEAKL7Jp.woff2 +0 -0
- package/dist/client/assets/geist-latin-ext-wght-normal-DC-KSUi6.woff2 +0 -0
- package/dist/client/assets/geist-latin-wght-normal-BgDaEnEv.woff2 +0 -0
- package/dist/client/assets/geist-vietnamese-wght-normal-6IgcOCM7.woff2 +0 -0
- package/dist/client/assets/index-4oL_AGyI.css +1 -0
- package/dist/client/assets/index-CJtKCyBg.js +848 -0
- package/dist/client/favicon.png +0 -0
- package/dist/client/favicon.svg +1 -0
- package/dist/client/icons.svg +24 -0
- package/dist/client/index.html +17 -0
- package/dist/client/resources/images/logo.png +0 -0
- package/dist/client/resources/images/openai.png +0 -0
- package/dist/constants.d.ts +3 -0
- package/dist/constants.d.ts.map +1 -0
- package/dist/constants.js +3 -0
- package/dist/constants.js.map +1 -0
- package/dist/dev.d.ts +2 -0
- package/dist/dev.d.ts.map +1 -0
- package/dist/dev.js +10 -0
- package/dist/dev.js.map +1 -0
- package/dist/modules/ai-agent/agent-context-manager.d.ts +57 -0
- package/dist/modules/ai-agent/agent-context-manager.d.ts.map +1 -0
- package/dist/modules/ai-agent/agent-context-manager.js +159 -0
- package/dist/modules/ai-agent/agent-context-manager.js.map +1 -0
- package/dist/modules/ai-agent/ai-agent.module.d.ts +17 -0
- package/dist/modules/ai-agent/ai-agent.module.d.ts.map +1 -0
- package/dist/modules/ai-agent/ai-agent.module.js +24 -0
- package/dist/modules/ai-agent/ai-agent.module.js.map +1 -0
- package/dist/modules/ai-agent/ai-agent.utils.d.ts +10 -0
- package/dist/modules/ai-agent/ai-agent.utils.d.ts.map +1 -0
- package/dist/modules/ai-agent/ai-agent.utils.js +389 -0
- package/dist/modules/ai-agent/ai-agent.utils.js.map +1 -0
- package/dist/modules/ai-agent/base.agent.d.ts +26 -0
- package/dist/modules/ai-agent/base.agent.d.ts.map +1 -0
- package/dist/modules/ai-agent/base.agent.js +101 -0
- package/dist/modules/ai-agent/base.agent.js.map +1 -0
- package/dist/modules/ai-agent/chat.agent.d.ts +35 -0
- package/dist/modules/ai-agent/chat.agent.d.ts.map +1 -0
- package/dist/modules/ai-agent/chat.agent.js +590 -0
- package/dist/modules/ai-agent/chat.agent.js.map +1 -0
- package/dist/modules/ai-agent/code-base-indexer.agent.d.ts +13 -0
- package/dist/modules/ai-agent/code-base-indexer.agent.d.ts.map +1 -0
- package/dist/modules/ai-agent/code-base-indexer.agent.js +506 -0
- package/dist/modules/ai-agent/code-base-indexer.agent.js.map +1 -0
- package/dist/modules/ai-agent/codebase-scanner.d.ts +37 -0
- package/dist/modules/ai-agent/codebase-scanner.d.ts.map +1 -0
- package/dist/modules/ai-agent/codebase-scanner.js +260 -0
- package/dist/modules/ai-agent/codebase-scanner.js.map +1 -0
- package/dist/modules/ai-agent/model-loader.d.ts +7 -0
- package/dist/modules/ai-agent/model-loader.d.ts.map +1 -0
- package/dist/modules/ai-agent/model-loader.js +129 -0
- package/dist/modules/ai-agent/model-loader.js.map +1 -0
- package/dist/modules/ai-agent/orientation-loader.d.ts +2 -0
- package/dist/modules/ai-agent/orientation-loader.d.ts.map +1 -0
- package/dist/modules/ai-agent/orientation-loader.js +70 -0
- package/dist/modules/ai-agent/orientation-loader.js.map +1 -0
- package/dist/modules/ai-agent/pr-review-session.manager.d.ts +36 -0
- package/dist/modules/ai-agent/pr-review-session.manager.d.ts.map +1 -0
- package/dist/modules/ai-agent/pr-review-session.manager.js +106 -0
- package/dist/modules/ai-agent/pr-review-session.manager.js.map +1 -0
- package/dist/modules/ai-agent/pr-review.agent.d.ts +22 -0
- package/dist/modules/ai-agent/pr-review.agent.d.ts.map +1 -0
- package/dist/modules/ai-agent/pr-review.agent.js +269 -0
- package/dist/modules/ai-agent/pr-review.agent.js.map +1 -0
- package/dist/modules/ai-agent/research-loop.d.ts +3 -0
- package/dist/modules/ai-agent/research-loop.d.ts.map +1 -0
- package/dist/modules/ai-agent/research-loop.js +691 -0
- package/dist/modules/ai-agent/research-loop.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/agent-loop.d.ts +36 -0
- package/dist/modules/ai-agent/review-pipeline/agent-loop.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/agent-loop.js +178 -0
- package/dist/modules/ai-agent/review-pipeline/agent-loop.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/change-analyzer.d.ts +8 -0
- package/dist/modules/ai-agent/review-pipeline/change-analyzer.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/change-analyzer.js +93 -0
- package/dist/modules/ai-agent/review-pipeline/change-analyzer.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/finding-ranker.d.ts +47 -0
- package/dist/modules/ai-agent/review-pipeline/finding-ranker.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/finding-ranker.js +91 -0
- package/dist/modules/ai-agent/review-pipeline/finding-ranker.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/finding-verifier.d.ts +29 -0
- package/dist/modules/ai-agent/review-pipeline/finding-verifier.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/finding-verifier.js +130 -0
- package/dist/modules/ai-agent/review-pipeline/finding-verifier.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/repository-explorer.d.ts +21 -0
- package/dist/modules/ai-agent/review-pipeline/repository-explorer.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/repository-explorer.js +247 -0
- package/dist/modules/ai-agent/review-pipeline/repository-explorer.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/review-controller.d.ts +22 -0
- package/dist/modules/ai-agent/review-pipeline/review-controller.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/review-controller.js +102 -0
- package/dist/modules/ai-agent/review-pipeline/review-controller.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/review-writer.d.ts +4 -0
- package/dist/modules/ai-agent/review-pipeline/review-writer.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/review-writer.js +52 -0
- package/dist/modules/ai-agent/review-pipeline/review-writer.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/secret-scanner.d.ts +25 -0
- package/dist/modules/ai-agent/review-pipeline/secret-scanner.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/secret-scanner.js +159 -0
- package/dist/modules/ai-agent/review-pipeline/secret-scanner.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/specialist-reviewer.d.ts +9 -0
- package/dist/modules/ai-agent/review-pipeline/specialist-reviewer.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/specialist-reviewer.js +114 -0
- package/dist/modules/ai-agent/review-pipeline/specialist-reviewer.js.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/types.d.ts +53 -0
- package/dist/modules/ai-agent/review-pipeline/types.d.ts.map +1 -0
- package/dist/modules/ai-agent/review-pipeline/types.js +45 -0
- package/dist/modules/ai-agent/review-pipeline/types.js.map +1 -0
- package/dist/modules/ai-agent/tool-executor.d.ts +37 -0
- package/dist/modules/ai-agent/tool-executor.d.ts.map +1 -0
- package/dist/modules/ai-agent/tool-executor.js +199 -0
- package/dist/modules/ai-agent/tool-executor.js.map +1 -0
- package/dist/modules/ai-agent/tool-types.d.ts +72 -0
- package/dist/modules/ai-agent/tool-types.d.ts.map +1 -0
- package/dist/modules/ai-agent/tool-types.js +2 -0
- package/dist/modules/ai-agent/tool-types.js.map +1 -0
- package/dist/modules/ai-agent/tools/fs-tools.d.ts +54 -0
- package/dist/modules/ai-agent/tools/fs-tools.d.ts.map +1 -0
- package/dist/modules/ai-agent/tools/fs-tools.js +237 -0
- package/dist/modules/ai-agent/tools/fs-tools.js.map +1 -0
- package/dist/modules/ai-agent/tools/git-tools.d.ts +322 -0
- package/dist/modules/ai-agent/tools/git-tools.d.ts.map +1 -0
- package/dist/modules/ai-agent/tools/git-tools.js +557 -0
- package/dist/modules/ai-agent/tools/git-tools.js.map +1 -0
- package/dist/modules/ai-agent/tools/pr-chat-tools.d.ts +15 -0
- package/dist/modules/ai-agent/tools/pr-chat-tools.d.ts.map +1 -0
- package/dist/modules/ai-agent/tools/pr-chat-tools.js +232 -0
- package/dist/modules/ai-agent/tools/pr-chat-tools.js.map +1 -0
- package/dist/modules/database/database.module.d.ts +10 -0
- package/dist/modules/database/database.module.d.ts.map +1 -0
- package/dist/modules/database/database.module.js +36 -0
- package/dist/modules/database/database.module.js.map +1 -0
- package/dist/modules/database/vector-database.service.d.ts +27 -0
- package/dist/modules/database/vector-database.service.d.ts.map +1 -0
- package/dist/modules/database/vector-database.service.js +170 -0
- package/dist/modules/database/vector-database.service.js.map +1 -0
- package/dist/modules/github/github.module.d.ts +964 -0
- package/dist/modules/github/github.module.d.ts.map +1 -0
- package/dist/modules/github/github.module.js +316 -0
- package/dist/modules/github/github.module.js.map +1 -0
- package/dist/modules/main.module.d.ts +20 -0
- package/dist/modules/main.module.d.ts.map +1 -0
- package/dist/modules/main.module.js +59 -0
- package/dist/modules/main.module.js.map +1 -0
- package/dist/modules/qvac/qvac.module.d.ts +28 -0
- package/dist/modules/qvac/qvac.module.d.ts.map +1 -0
- package/dist/modules/qvac/qvac.module.js +146 -0
- package/dist/modules/qvac/qvac.module.js.map +1 -0
- package/dist/modules/server/dtos/create-project.dto.d.ts +9 -0
- package/dist/modules/server/dtos/create-project.dto.d.ts.map +1 -0
- package/dist/modules/server/dtos/create-project.dto.js +2 -0
- package/dist/modules/server/dtos/create-project.dto.js.map +1 -0
- package/dist/modules/server/entities/agent-task.entity.d.ts +16 -0
- package/dist/modules/server/entities/agent-task.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/agent-task.entity.js +72 -0
- package/dist/modules/server/entities/agent-task.entity.js.map +1 -0
- package/dist/modules/server/entities/ai-provider.entity.d.ts +11 -0
- package/dist/modules/server/entities/ai-provider.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/ai-provider.entity.js +47 -0
- package/dist/modules/server/entities/ai-provider.entity.js.map +1 -0
- package/dist/modules/server/entities/deployment-plan-approval.entity.d.ts +10 -0
- package/dist/modules/server/entities/deployment-plan-approval.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/deployment-plan-approval.entity.js +42 -0
- package/dist/modules/server/entities/deployment-plan-approval.entity.js.map +1 -0
- package/dist/modules/server/entities/deployment-plan-artifact.entity.d.ts +10 -0
- package/dist/modules/server/entities/deployment-plan-artifact.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/deployment-plan-artifact.entity.js +42 -0
- package/dist/modules/server/entities/deployment-plan-artifact.entity.js.map +1 -0
- package/dist/modules/server/entities/deployment-plan-feedback.entity.d.ts +9 -0
- package/dist/modules/server/entities/deployment-plan-feedback.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/deployment-plan-feedback.entity.js +37 -0
- package/dist/modules/server/entities/deployment-plan-feedback.entity.js.map +1 -0
- package/dist/modules/server/entities/deployment-plan-revision.entity.d.ts +11 -0
- package/dist/modules/server/entities/deployment-plan-revision.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/deployment-plan-revision.entity.js +47 -0
- package/dist/modules/server/entities/deployment-plan-revision.entity.js.map +1 -0
- package/dist/modules/server/entities/deployment-plan.entity.d.ts +13 -0
- package/dist/modules/server/entities/deployment-plan.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/deployment-plan.entity.js +58 -0
- package/dist/modules/server/entities/deployment-plan.entity.js.map +1 -0
- package/dist/modules/server/entities/project.entity.d.ts +26 -0
- package/dist/modules/server/entities/project.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/project.entity.js +122 -0
- package/dist/modules/server/entities/project.entity.js.map +1 -0
- package/dist/modules/server/entities/settings.entity.d.ts +12 -0
- package/dist/modules/server/entities/settings.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/settings.entity.js +62 -0
- package/dist/modules/server/entities/settings.entity.js.map +1 -0
- package/dist/modules/server/entities/terminal-log.entity.d.ts +10 -0
- package/dist/modules/server/entities/terminal-log.entity.d.ts.map +1 -0
- package/dist/modules/server/entities/terminal-log.entity.js +42 -0
- package/dist/modules/server/entities/terminal-log.entity.js.map +1 -0
- package/dist/modules/server/middleware/auth.middleware.d.ts +8 -0
- package/dist/modules/server/middleware/auth.middleware.d.ts.map +1 -0
- package/dist/modules/server/middleware/auth.middleware.js +26 -0
- package/dist/modules/server/middleware/auth.middleware.js.map +1 -0
- package/dist/modules/server/routes/auth.routes.d.ts +13 -0
- package/dist/modules/server/routes/auth.routes.d.ts.map +1 -0
- package/dist/modules/server/routes/auth.routes.js +59 -0
- package/dist/modules/server/routes/auth.routes.js.map +1 -0
- package/dist/modules/server/routes/github.routes.d.ts +14 -0
- package/dist/modules/server/routes/github.routes.d.ts.map +1 -0
- package/dist/modules/server/routes/github.routes.js +124 -0
- package/dist/modules/server/routes/github.routes.js.map +1 -0
- package/dist/modules/server/routes/project.routes.d.ts +11 -0
- package/dist/modules/server/routes/project.routes.d.ts.map +1 -0
- package/dist/modules/server/routes/project.routes.js +78 -0
- package/dist/modules/server/routes/project.routes.js.map +1 -0
- package/dist/modules/server/routes/qvac.routes.d.ts +11 -0
- package/dist/modules/server/routes/qvac.routes.d.ts.map +1 -0
- package/dist/modules/server/routes/qvac.routes.js +24 -0
- package/dist/modules/server/routes/qvac.routes.js.map +1 -0
- package/dist/modules/server/routes/routes.d.ts +20 -0
- package/dist/modules/server/routes/routes.d.ts.map +1 -0
- package/dist/modules/server/routes/routes.js +35 -0
- package/dist/modules/server/routes/routes.js.map +1 -0
- package/dist/modules/server/routes/settings.controller.d.ts +14 -0
- package/dist/modules/server/routes/settings.controller.d.ts.map +1 -0
- package/dist/modules/server/routes/settings.controller.js +65 -0
- package/dist/modules/server/routes/settings.controller.js.map +1 -0
- package/dist/modules/server/server.module.d.ts +19 -0
- package/dist/modules/server/server.module.d.ts.map +1 -0
- package/dist/modules/server/server.module.js +63 -0
- package/dist/modules/server/server.module.js.map +1 -0
- package/dist/modules/server/services/auth.services.d.ts +19 -0
- package/dist/modules/server/services/auth.services.d.ts.map +1 -0
- package/dist/modules/server/services/auth.services.js +87 -0
- package/dist/modules/server/services/auth.services.js.map +1 -0
- package/dist/modules/server/services/deployment-plan.services.d.ts +6 -0
- package/dist/modules/server/services/deployment-plan.services.d.ts.map +1 -0
- package/dist/modules/server/services/deployment-plan.services.js +8 -0
- package/dist/modules/server/services/deployment-plan.services.js.map +1 -0
- package/dist/modules/server/services/github.services.d.ts +939 -0
- package/dist/modules/server/services/github.services.d.ts.map +1 -0
- package/dist/modules/server/services/github.services.js +46 -0
- package/dist/modules/server/services/github.services.js.map +1 -0
- package/dist/modules/server/services/project.services.d.ts +41 -0
- package/dist/modules/server/services/project.services.d.ts.map +1 -0
- package/dist/modules/server/services/project.services.js +360 -0
- package/dist/modules/server/services/project.services.js.map +1 -0
- package/dist/modules/server/services/qvac.services.d.ts +10 -0
- package/dist/modules/server/services/qvac.services.d.ts.map +1 -0
- package/dist/modules/server/services/qvac.services.js +58 -0
- package/dist/modules/server/services/qvac.services.js.map +1 -0
- package/dist/modules/server/services/settings.service.d.ts +60 -0
- package/dist/modules/server/services/settings.service.d.ts.map +1 -0
- package/dist/modules/server/services/settings.service.js +125 -0
- package/dist/modules/server/services/settings.service.js.map +1 -0
- package/dist/modules/socket-gateway/interfaces/project-creation-log.interface.d.ts +14 -0
- package/dist/modules/socket-gateway/interfaces/project-creation-log.interface.d.ts.map +1 -0
- package/dist/modules/socket-gateway/interfaces/project-creation-log.interface.js +2 -0
- package/dist/modules/socket-gateway/interfaces/project-creation-log.interface.js.map +1 -0
- package/dist/modules/socket-gateway/socket-gateway.module.d.ts +28 -0
- package/dist/modules/socket-gateway/socket-gateway.module.d.ts.map +1 -0
- package/dist/modules/socket-gateway/socket-gateway.module.js +92 -0
- package/dist/modules/socket-gateway/socket-gateway.module.js.map +1 -0
- package/package.json +95 -0
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
import { DataSource, Repository } from 'typeorm';
|
|
2
|
+
import si from 'systeminformation';
|
|
3
|
+
import os from 'os';
|
|
4
|
+
import fs from 'fs';
|
|
5
|
+
import path from 'path';
|
|
6
|
+
import SettingsEntity from '../entities/settings.entity.js';
|
|
7
|
+
import { LLM_MODEL_ID, EMBEDDING_MODEL_ID } from '../../../constants.js';
|
|
8
|
+
export class SettingsService {
|
|
9
|
+
dataSource;
|
|
10
|
+
mainModule;
|
|
11
|
+
repository;
|
|
12
|
+
constructor(dataSource, mainModule) {
|
|
13
|
+
this.dataSource = dataSource;
|
|
14
|
+
this.mainModule = mainModule;
|
|
15
|
+
this.repository = this.dataSource.getRepository(SettingsEntity);
|
|
16
|
+
}
|
|
17
|
+
async getSettings() {
|
|
18
|
+
let settings = await this.repository.findOneBy({ id: 1 });
|
|
19
|
+
if (!settings) {
|
|
20
|
+
settings = this.repository.create({ id: 1, useExperimentalGpu: false });
|
|
21
|
+
await this.repository.save(settings);
|
|
22
|
+
}
|
|
23
|
+
return settings;
|
|
24
|
+
}
|
|
25
|
+
async getHardwareInfo() {
|
|
26
|
+
const totalRamGb = Math.round((os.totalmem() / 1024 / 1024 / 1024) * 10) / 10;
|
|
27
|
+
const availableRamGb = Math.round((os.freemem() / 1024 / 1024 / 1024) * 10) / 10;
|
|
28
|
+
const cpuCores = os.cpus().length;
|
|
29
|
+
const graphics = await si.graphics();
|
|
30
|
+
let gpuRamGb = 0;
|
|
31
|
+
if (graphics.controllers && graphics.controllers.length > 0) {
|
|
32
|
+
// Get the total dedicated VRAM from all GPUs
|
|
33
|
+
gpuRamGb =
|
|
34
|
+
Math.round((graphics.controllers.reduce((total, gpu) => total + (gpu.vram || 0), 0) /
|
|
35
|
+
1024 /
|
|
36
|
+
1024 /
|
|
37
|
+
1024) *
|
|
38
|
+
10) / 10;
|
|
39
|
+
}
|
|
40
|
+
return {
|
|
41
|
+
cpuCores,
|
|
42
|
+
totalRamGb,
|
|
43
|
+
availableRamGb,
|
|
44
|
+
gpuRamGb,
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
async getModelInfo() {
|
|
48
|
+
const qvacModule = this.mainModule?.qvac;
|
|
49
|
+
if (qvacModule) {
|
|
50
|
+
const models = await qvacModule.getAvailableModels();
|
|
51
|
+
const llmModel = models.find((m) => m.id === LLM_MODEL_ID);
|
|
52
|
+
const embeddingModel = models.find((m) => m.id === EMBEDDING_MODEL_ID);
|
|
53
|
+
const llmSize = llmModel?.actualSize || 0;
|
|
54
|
+
const embeddingSize = embeddingModel?.actualSize || 0;
|
|
55
|
+
const totalModelSize = llmSize + embeddingSize;
|
|
56
|
+
return {
|
|
57
|
+
llmModel: llmModel
|
|
58
|
+
? {
|
|
59
|
+
id: llmModel.id,
|
|
60
|
+
name: llmModel.name,
|
|
61
|
+
requiredRamGb: llmModel.requiredRamGb,
|
|
62
|
+
expectedSize: llmModel.expectedSize,
|
|
63
|
+
actualSize: llmModel.actualSize,
|
|
64
|
+
isLoaded: llmModel.isLoaded,
|
|
65
|
+
isCompatible: llmModel.isCompatible,
|
|
66
|
+
}
|
|
67
|
+
: null,
|
|
68
|
+
embeddingModel: embeddingModel
|
|
69
|
+
? {
|
|
70
|
+
id: embeddingModel.id,
|
|
71
|
+
name: embeddingModel.name,
|
|
72
|
+
requiredRamGb: embeddingModel.requiredRamGb,
|
|
73
|
+
expectedSize: embeddingModel.expectedSize,
|
|
74
|
+
actualSize: embeddingModel.actualSize,
|
|
75
|
+
isLoaded: embeddingModel.isLoaded,
|
|
76
|
+
isCompatible: embeddingModel.isCompatible,
|
|
77
|
+
}
|
|
78
|
+
: null,
|
|
79
|
+
totalModelSize,
|
|
80
|
+
models,
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
return {
|
|
84
|
+
llmModel: null,
|
|
85
|
+
embeddingModel: null,
|
|
86
|
+
totalModelSize: 0,
|
|
87
|
+
models: [],
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
async getStorageInfo() {
|
|
91
|
+
const settings = await this.getSettings();
|
|
92
|
+
const modelInfo = await this.getModelInfo();
|
|
93
|
+
const totalModelSize = modelInfo.totalModelSize || 0;
|
|
94
|
+
// Calculate SQLite database size
|
|
95
|
+
let sqliteDbSize = 0;
|
|
96
|
+
try {
|
|
97
|
+
const dbPath = path.resolve(process.cwd(), 'database.sqlite');
|
|
98
|
+
if (fs.existsSync(dbPath)) {
|
|
99
|
+
const stats = fs.statSync(dbPath);
|
|
100
|
+
sqliteDbSize = stats.size;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
catch (e) {
|
|
104
|
+
console.warn('Could not get SQLite database size:', e);
|
|
105
|
+
}
|
|
106
|
+
// Application storage = embedding model + LLM + SQLite database
|
|
107
|
+
const applicationStorageBytes = totalModelSize + sqliteDbSize;
|
|
108
|
+
return {
|
|
109
|
+
storageUsedGb: settings.storageUsedGb,
|
|
110
|
+
storageTotalGb: settings.storageTotalGb,
|
|
111
|
+
contextSizeLimit: settings.contextSizeLimit,
|
|
112
|
+
totalModelSize,
|
|
113
|
+
sqliteDbSize,
|
|
114
|
+
applicationStorageBytes,
|
|
115
|
+
};
|
|
116
|
+
}
|
|
117
|
+
async updateSettings(data) {
|
|
118
|
+
const settings = await this.getSettings();
|
|
119
|
+
if (data.useExperimentalGpu !== undefined) {
|
|
120
|
+
settings.useExperimentalGpu = data.useExperimentalGpu;
|
|
121
|
+
}
|
|
122
|
+
return await this.repository.save(settings);
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
//# sourceMappingURL=settings.service.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"settings.service.js","sourceRoot":"","sources":["../../../../src/modules/server/services/settings.service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C;QACrB,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,iBAAiB,CAAC,CAAC;YAC9D,IAAI,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE,CAAC;gBAC1B,MAAM,KAAK,GAAG,EAAE,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;gBAClC,YAAY,GAAG,KAAK,CAAC,IAAI,CAAC;YAC5B,CAAC;QACH,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,OAAO,CAAC,IAAI,CAAC,qCAAqC,EAAE,CAAC,CAAC,CAAC;QACzD,CAAC;QAED,gEAAgE;QAChE,MAAM,uBAAuB,GAAG,cAAc,GAAG,YAAY,CAAC;QAE9D,OAAO;YACL,aAAa,EAAE,QAAQ,CAAC,aAAa;YACrC,cAAc,EAAE,QAAQ,CAAC,cAAc;YACvC,gBAAgB,EAAE,QAAQ,CAAC,gBAAgB;YAC3C,cAAc;YACd,YAAY;YACZ,uBAAuB;SACxB,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,cAAc,CAAC,IAAsC;QACzD,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,WAAW,EAAE,CAAC;QAC1C,IAAI,IAAI,CAAC,kBAAkB,KAAK,SAAS,EAAE,CAAC;YAC1C,QAAQ,CAAC,kBAAkB,GAAG,IAAI,CAAC,kBAAkB,CAAC;QACxD,CAAC;QACD,OAAO,MAAM,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IAC9C,CAAC;CACF"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export interface emitProjectCreationLog {
|
|
2
|
+
name: string;
|
|
3
|
+
id: string;
|
|
4
|
+
message: string;
|
|
5
|
+
type: LogType;
|
|
6
|
+
actionProgress?: LogActionProgress;
|
|
7
|
+
}
|
|
8
|
+
export interface ProjectCreationSuccess {
|
|
9
|
+
projectId: string;
|
|
10
|
+
time: string;
|
|
11
|
+
}
|
|
12
|
+
export type LogType = 'action' | 'error' | 'info' | 'warning';
|
|
13
|
+
export type LogActionProgress = 'pending' | 'success' | 'error';
|
|
14
|
+
//# sourceMappingURL=project-creation-log.interface.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-creation-log.interface.d.ts","sourceRoot":"","sources":["../../../../src/modules/socket-gateway/interfaces/project-creation-log.interface.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,sBAAsB;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,OAAO,CAAC;IACd,cAAc,CAAC,EAAE,iBAAiB,CAAC;CACpC;AAED,MAAM,WAAW,sBAAsB;IACrC,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,MAAM,OAAO,GAAG,QAAQ,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,CAAC;AAC9D,MAAM,MAAM,iBAAiB,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-creation-log.interface.js","sourceRoot":"","sources":["../../../../src/modules/socket-gateway/interfaces/project-creation-log.interface.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import type http from 'http';
|
|
2
|
+
import { Server, Socket } from 'socket.io';
|
|
3
|
+
import { MainModule } from '../main.module.js';
|
|
4
|
+
import type { AgentConfirmationRequest } from '../ai-agent/tool-types.js';
|
|
5
|
+
export default class SocketModule {
|
|
6
|
+
io: Server;
|
|
7
|
+
mainModule: MainModule;
|
|
8
|
+
connections: Map<string, Socket>;
|
|
9
|
+
private pendingConfirmations;
|
|
10
|
+
constructor(server: http.Server, mainModule: MainModule);
|
|
11
|
+
/**
|
|
12
|
+
* Request a structured confirmation from a specific socket. The confirmation
|
|
13
|
+
* is bound to the initiating socket so no other connected client can respond.
|
|
14
|
+
*/
|
|
15
|
+
requestConfirmation(socketId: string, confirmation: AgentConfirmationRequest): Promise<boolean>;
|
|
16
|
+
/**
|
|
17
|
+
* Request a tool confirmation from a specific socket and wait for the user's
|
|
18
|
+
* reply. The tool handler uses this to gate mutation actions (e.g. posting a
|
|
19
|
+
* PR comment) behind explicit user approval. Returns true if approved, false
|
|
20
|
+
* if rejected or timed out.
|
|
21
|
+
*/
|
|
22
|
+
requestToolConfirmation(socketId: string, confirmation: AgentConfirmationRequest): Promise<boolean>;
|
|
23
|
+
emitProjectCreationLog(log: any): void;
|
|
24
|
+
emitModelProgress(progress: any): void;
|
|
25
|
+
emitIndexingProgress(progress: any): void;
|
|
26
|
+
emitReviewProgress(progress: any): void;
|
|
27
|
+
}
|
|
28
|
+
//# sourceMappingURL=socket-gateway.module.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"socket-gateway.module.d.ts","sourceRoot":"","sources":["../../../src/modules/socket-gateway/socket-gateway.module.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,IAAI,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAG/C,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,2BAA2B,CAAC;AAQ1E,MAAM,CAAC,OAAO,OAAO,YAAY;IAC/B,EAAE,EAAE,MAAM,CAAC;IACX,UAAU,EAAE,UAAU,CAAC;IACvB,WAAW,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAa;IAC7C,OAAO,CAAC,oBAAoB,CAA+C;gBAE/D,MAAM,EAAE,IAAI,CAAC,MAAM,EAAE,UAAU,EAAE,UAAU;IA0CvD;;;OAGG;IACH,mBAAmB,CAAC,QAAQ,EAAE,MAAM,EAAE,YAAY,EAAE,wBAAwB,GAAG,OAAO,CAAC,OAAO,CAAC;IA2B/F;;;;;OAKG;IACH,uBAAuB,CACrB,QAAQ,EAAE,MAAM,EAChB,YAAY,EAAE,wBAAwB,GACrC,OAAO,CAAC,OAAO,CAAC;IAInB,sBAAsB,CAAC,GAAG,EAAE,GAAG;IAI/B,iBAAiB,CAAC,QAAQ,EAAE,GAAG;IAI/B,oBAAoB,CAAC,QAAQ,EAAE,GAAG;IAIlC,kBAAkB,CAAC,QAAQ,EAAE,GAAG;CAGjC"}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { Server, Socket } from 'socket.io';
|
|
2
|
+
import { MainModule } from '../main.module.js';
|
|
3
|
+
import crypto from 'crypto';
|
|
4
|
+
export default class SocketModule {
|
|
5
|
+
io;
|
|
6
|
+
mainModule;
|
|
7
|
+
connections = new Map();
|
|
8
|
+
pendingConfirmations = new Map();
|
|
9
|
+
constructor(server, mainModule) {
|
|
10
|
+
this.mainModule = mainModule;
|
|
11
|
+
this.io = new Server(server, {
|
|
12
|
+
cors: {
|
|
13
|
+
origin: '*',
|
|
14
|
+
},
|
|
15
|
+
});
|
|
16
|
+
this.io.on('connection', (socket) => {
|
|
17
|
+
console.log('a user connected');
|
|
18
|
+
this.connections.set(socket.id, socket);
|
|
19
|
+
socket.on('disconnect', () => {
|
|
20
|
+
console.log('user disconnected');
|
|
21
|
+
this.connections.delete(socket.id);
|
|
22
|
+
// Reject any pending confirmations owned by this socket.
|
|
23
|
+
for (const [id, pending] of this.pendingConfirmations) {
|
|
24
|
+
if (pending.socketId === socket.id) {
|
|
25
|
+
pending.resolve(false);
|
|
26
|
+
this.pendingConfirmations.delete(id);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
socket.on('agent-confirmation-response', (data) => {
|
|
31
|
+
const pending = this.pendingConfirmations.get(data.id);
|
|
32
|
+
if (!pending)
|
|
33
|
+
return;
|
|
34
|
+
// Only the socket that initiated the confirmation may respond.
|
|
35
|
+
if (pending.socketId !== socket.id) {
|
|
36
|
+
console.warn('Rejected confirmation response from wrong socket');
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
pending.resolve(data.approved);
|
|
40
|
+
this.pendingConfirmations.delete(data.id);
|
|
41
|
+
});
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Request a structured confirmation from a specific socket. The confirmation
|
|
46
|
+
* is bound to the initiating socket so no other connected client can respond.
|
|
47
|
+
*/
|
|
48
|
+
requestConfirmation(socketId, confirmation) {
|
|
49
|
+
const id = crypto.randomUUID();
|
|
50
|
+
return new Promise((resolve) => {
|
|
51
|
+
this.pendingConfirmations.set(id, {
|
|
52
|
+
resolve,
|
|
53
|
+
socketId,
|
|
54
|
+
sessionId: confirmation.sessionId,
|
|
55
|
+
});
|
|
56
|
+
this.io.to(socketId).emit('agent-confirmation-request', {
|
|
57
|
+
id,
|
|
58
|
+
...confirmation,
|
|
59
|
+
});
|
|
60
|
+
// Timeout after 15 minutes (defaults to false / deny)
|
|
61
|
+
setTimeout(() => {
|
|
62
|
+
const pending = this.pendingConfirmations.get(id);
|
|
63
|
+
if (!pending)
|
|
64
|
+
return;
|
|
65
|
+
pending.resolve(false);
|
|
66
|
+
this.pendingConfirmations.delete(id);
|
|
67
|
+
}, 900000);
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Request a tool confirmation from a specific socket and wait for the user's
|
|
72
|
+
* reply. The tool handler uses this to gate mutation actions (e.g. posting a
|
|
73
|
+
* PR comment) behind explicit user approval. Returns true if approved, false
|
|
74
|
+
* if rejected or timed out.
|
|
75
|
+
*/
|
|
76
|
+
requestToolConfirmation(socketId, confirmation) {
|
|
77
|
+
return this.requestConfirmation(socketId, confirmation);
|
|
78
|
+
}
|
|
79
|
+
emitProjectCreationLog(log) {
|
|
80
|
+
this.io.emit('project_creation_log', log);
|
|
81
|
+
}
|
|
82
|
+
emitModelProgress(progress) {
|
|
83
|
+
this.io.emit('model_progress', progress);
|
|
84
|
+
}
|
|
85
|
+
emitIndexingProgress(progress) {
|
|
86
|
+
this.io.emit('indexing_progress', progress);
|
|
87
|
+
}
|
|
88
|
+
emitReviewProgress(progress) {
|
|
89
|
+
this.io.emit('review_progress', progress);
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
//# sourceMappingURL=socket-gateway.module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"socket-gateway.module.js","sourceRoot":"","sources":["../../../src/modules/socket-gateway/socket-gateway.module.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAE/C,OAAO,MAAM,MAAM,QAAQ,CAAC;AAS5B,MAAM,CAAC,OAAO,OAAO,YAAY;IAC/B,EAAE,CAAS;IACX,UAAU,CAAa;IACvB,WAAW,GAAwB,IAAI,GAAG,EAAE,CAAC;IACrC,oBAAoB,GAAqC,IAAI,GAAG,EAAE,CAAC;IAE3E,YAAY,MAAmB,EAAE,UAAsB;QACrD,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,EAAE,GAAG,IAAI,MAAM,CAAC,MAAM,EAAE;YAC3B,IAAI,EAAE;gBACJ,MAAM,EAAE,GAAG;aACZ;SACF,CAAC,CAAC;QAEH,IAAI,CAAC,EAAE,CAAC,EAAE,CAAC,YAAY,EAAE,CAAC,MAAM,EAAE,EAAE;YAClC,OAAO,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAAC;YAChC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,EAAE,MAAM,CAAC,CAAC;YAExC,MAAM,CAAC,EAAE,CAAC,YAAY,EAAE,GAAG,EAAE;gBAC3B,OAAO,CAAC,GAAG,CAAC,mBAAmB,CAAC,CAAC;gBACjC,IAAI,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
|
+
"version": "0.0.1",
|
|
5
|
+
"description": "",
|
|
6
|
+
"bin": {
|
|
7
|
+
"lazy-review": "./dist/bin.js",
|
|
8
|
+
"lrv": "./dist/bin.js"
|
|
9
|
+
},
|
|
10
|
+
"main": "dist/bin.js",
|
|
11
|
+
"devDependencies": {
|
|
12
|
+
"@eslint/js": "^9.37.0",
|
|
13
|
+
"@types/better-sqlite3": "^9.6.0",
|
|
14
|
+
"@types/chalk-animation": "^1.6.3",
|
|
15
|
+
"@types/express": "^5.0.3",
|
|
16
|
+
"@types/node": "^24.6.2",
|
|
17
|
+
"@types/ssh2": "^1.15.5",
|
|
18
|
+
"@typescript-eslint/eslint-plugin": "^8.45.0",
|
|
19
|
+
"@typescript-eslint/parser": "^8.45.0",
|
|
20
|
+
"concurrently": "^9.2.1",
|
|
21
|
+
"eslint": "^9.37.0",
|
|
22
|
+
"eslint-config-prettier": "^10.1.8",
|
|
23
|
+
"eslint-plugin-prettier": "^5.5.4",
|
|
24
|
+
"husky": "^9.1.7",
|
|
25
|
+
"nodemon": "^3.1.10",
|
|
26
|
+
"prettier": "^3.6.2",
|
|
27
|
+
"typescript": "^5.9.3",
|
|
28
|
+
"typescript-eslint": "^8.45.0"
|
|
29
|
+
},
|
|
30
|
+
"dependencies": {
|
|
31
|
+
"@aws-sdk/client-ec2": "^3.1066.0",
|
|
32
|
+
"@aws-sdk/client-s3": "^3.1066.0",
|
|
33
|
+
"@langchain/anthropic": "^1.4.0",
|
|
34
|
+
"@langchain/core": "^1.1.48",
|
|
35
|
+
"@langchain/google-genai": "^2.1.31",
|
|
36
|
+
"@langchain/openai": "^1.4.7",
|
|
37
|
+
"@octokit/core": "^7.0.6",
|
|
38
|
+
"@qvac/sdk": "^0.16.0",
|
|
39
|
+
"@types/cors": "^2.8.19",
|
|
40
|
+
"bare-runtime-darwin-x64": "^1.30.3",
|
|
41
|
+
"better-sqlite3": "^12.10.0",
|
|
42
|
+
"chalk": "^5.6.2",
|
|
43
|
+
"chalk-animation": "^2.0.3",
|
|
44
|
+
"commander": "^14.0.1",
|
|
45
|
+
"cors": "^2.8.6",
|
|
46
|
+
"dotenv": "^17.4.2",
|
|
47
|
+
"express": "^5.1.0",
|
|
48
|
+
"inquirer": "^12.9.6",
|
|
49
|
+
"octokit": "^5.0.5",
|
|
50
|
+
"open": "^10.2.0",
|
|
51
|
+
"ora": "^9.0.0",
|
|
52
|
+
"reflect-metadata": "^0.2.2",
|
|
53
|
+
"simple-git": "^3.36.0",
|
|
54
|
+
"socket.io": "^4.8.3",
|
|
55
|
+
"sqlite-vec": "^0.1.9",
|
|
56
|
+
"sqlite3": "^6.0.1",
|
|
57
|
+
"ssh2": "^1.17.0",
|
|
58
|
+
"systeminformation": "^5.33.1",
|
|
59
|
+
"tree-sitter": "^0.25.1",
|
|
60
|
+
"tree-sitter-go": "^0.25.0",
|
|
61
|
+
"tree-sitter-javascript": "^0.25.0",
|
|
62
|
+
"tree-sitter-python": "^0.25.0",
|
|
63
|
+
"tree-sitter-rust": "^0.24.0",
|
|
64
|
+
"tree-sitter-typescript": "^0.23.2",
|
|
65
|
+
"tweetnacl": "^1.0.3",
|
|
66
|
+
"tweetnacl-util": "^0.15.1",
|
|
67
|
+
"typeorm": "^1.0.0",
|
|
68
|
+
"uuid": "^13.0.0",
|
|
69
|
+
"zod": "^4.4.3"
|
|
70
|
+
},
|
|
71
|
+
"keywords": [],
|
|
72
|
+
"author": "",
|
|
73
|
+
"license": "MIT",
|
|
74
|
+
"files": [
|
|
75
|
+
"dist"
|
|
76
|
+
],
|
|
77
|
+
"scripts": {
|
|
78
|
+
"agent": "tsx agent.ts",
|
|
79
|
+
"test": "echo \"Error: no test specified\" && exit 0",
|
|
80
|
+
"dev": "concurrently \"pnpm:watch\" \"pnpm:link-watch\" \"pnpm:frontend:dev\"",
|
|
81
|
+
"dev:server": "nodemon --watch dist --ext js dist/dev.js",
|
|
82
|
+
"dev:local": "concurrently \"pnpm:watch\" \"pnpm:dev:server\" \"pnpm:frontend:dev\"",
|
|
83
|
+
"watch": "tsc --watch",
|
|
84
|
+
"build": "tsc && cp .env dist/ || true",
|
|
85
|
+
"clean": "rm -rf dist",
|
|
86
|
+
"frontend:dev": "cd frontend && pnpm run dev",
|
|
87
|
+
"frontend:build": "cd frontend && pnpm run build",
|
|
88
|
+
"postbuild": "chmod +x dist/bin.js",
|
|
89
|
+
"prod:build": "pnpm run clean && pnpm run build && pnpm run frontend:build",
|
|
90
|
+
"link": "pnpm run postbuild && pnpm run prod:build && pnpm link --global",
|
|
91
|
+
"link-watch": "nodemon --watch dist --ext js --exec \"pnpm link --global\"",
|
|
92
|
+
"lint": "eslint \"src/**/*.ts\"",
|
|
93
|
+
"format": "prettier --write \"**/*.{ts,js,json,md}\""
|
|
94
|
+
}
|
|
95
|
+
}
|