agent-enderun 1.1.1 → 1.1.2
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/.enderun/STATUS.md +2 -2
- package/.enderun/agents/analyst.json +4 -4
- package/.enderun/agents/backend.json +4 -4
- package/.enderun/agents/database.json +4 -4
- package/.enderun/agents/devops.json +4 -4
- package/.enderun/agents/explorer.json +4 -4
- package/.enderun/agents/frontend.json +4 -4
- package/.enderun/agents/git.json +4 -4
- package/.enderun/agents/manager.json +4 -6
- package/.enderun/agents/mobile.json +4 -4
- package/.enderun/agents/native.json +4 -4
- package/.enderun/agents/quality.json +4 -4
- package/.enderun/agents/security.json +4 -4
- package/.enderun/config.json +3 -2
- package/.enderun/logs/manager.json +4 -0
- package/.enderun/memory/PROJECT_MEMORY.md +38 -0
- package/CLAUDE.md +5 -4
- package/GEMINI.md +5 -4
- package/GROK.md +3 -3
- package/README.md +2 -2
- package/agent.md +6 -6
- package/bin/cli.js +3 -4
- package/bin/compile.js +22 -0
- package/bin/test-init-run.js +136 -0
- package/dist/framework-mcp/src/index.js +1 -1
- package/dist/framework-mcp/src/tools/definitions.js +3 -1
- package/dist/framework-mcp/src/tools/definitions.js.map +1 -1
- package/dist/framework-mcp/src/tools/file_system/read_file.js +20 -0
- package/dist/framework-mcp/src/tools/file_system/read_file.js.map +1 -1
- package/dist/framework-mcp/src/tools/messaging/send_message.js +37 -14
- package/dist/framework-mcp/src/tools/messaging/send_message.js.map +1 -1
- package/dist/src/cli/adapters.d.ts +3 -1
- package/dist/src/cli/adapters.js +13 -11
- package/dist/src/cli/adapters.js.map +1 -1
- package/dist/src/cli/commands/check.js +12 -1
- package/dist/src/cli/commands/check.js.map +1 -1
- package/dist/src/cli/commands/init.js +21 -11
- package/dist/src/cli/commands/init.js.map +1 -1
- package/dist/src/cli/commands/orchestrate.d.ts +15 -0
- package/dist/src/cli/commands/orchestrate.js +45 -1
- package/dist/src/cli/commands/orchestrate.js.map +1 -1
- package/dist/src/cli/index.js +84 -19
- package/dist/src/cli/index.js.map +1 -1
- package/dist/src/cli/utils/memory.js +4 -0
- package/dist/src/cli/utils/memory.js.map +1 -1
- package/dist/src/cli/utils/pkg.js +5 -1
- package/dist/src/cli/utils/pkg.js.map +1 -1
- package/dist/tests/adapter.test.js +10 -8
- package/dist/tests/adapter.test.js.map +1 -1
- package/dist/tests/gemini.test.js +8 -7
- package/dist/tests/gemini.test.js.map +1 -1
- package/dist/vitest.config.js +1 -1
- package/dist/vitest.config.js.map +1 -1
- package/docs/project_analysis_report.md +1 -1
- package/eslint.config.js +2 -2
- package/framework-mcp/dist/src/index.js +1 -1
- package/framework-mcp/dist/src/tools/definitions.js +3 -1
- package/framework-mcp/dist/src/tools/file_system/read_file.js +20 -0
- package/framework-mcp/package.json +2 -2
- package/framework-mcp/src/index.ts +1 -1
- package/framework-mcp/src/tools/definitions.ts +3 -1
- package/framework-mcp/src/tools/file_system/read_file.ts +24 -0
- package/package.json +10 -8
- package/src/cli/adapters.ts +10 -10
- package/src/cli/commands/check.ts +13 -1
- package/src/cli/commands/init.ts +12 -11
- package/src/cli/commands/orchestrate.ts +1 -1
- package/src/cli/utils/memory.ts +4 -0
- package/src/cli/utils/pkg.ts +5 -1
- package/tsconfig.json +0 -2
- package/.enderun/ARCHITECTURE.md +0 -1
- package/.enderun/SECURITY.md +0 -1
- package/bin/init-check.js +0 -86
- package/bin/update-contract.js +0 -93
- package/dist/apps/backend/src/types/index.d.ts +0 -9
- package/dist/apps/backend/src/types/index.js +0 -5
- package/dist/apps/backend/src/types/index.js.map +0 -1
- package/dist/apps/web/src/main.d.ts +0 -1
- package/dist/apps/web/src/main.js +0 -9
- package/dist/apps/web/src/main.js.map +0 -1
- package/dist/apps/web/vite.config.d.ts +0 -2
- package/dist/apps/web/vite.config.js +0 -6
- package/dist/apps/web/vite.config.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/index.d.ts +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/index.js +0 -71
- package/dist/tests/framework-init-test/framework-mcp/src/index.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/definitions.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/definitions.js +0 -111
- package/dist/tests/framework-init-test/framework-mcp/src/tools/definitions.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/patch_file.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/patch_file.js +0 -19
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/patch_file.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/read_file.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/read_file.js +0 -8
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/read_file.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/replace_text.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/replace_text.js +0 -32
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/replace_text.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/write_file.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/write_file.js +0 -10
- package/dist/tests/framework-init-test/framework-mcp/src/tools/file_system/write_file.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/get_status.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/get_status.js +0 -6
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/get_status.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/orchestrate.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/orchestrate.js +0 -6
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/orchestrate.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/update_contract_hash.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/update_contract_hash.js +0 -6
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/update_contract_hash.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/update_memory.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/update_memory.js +0 -9
- package/dist/tests/framework-init-test/framework-mcp/src/tools/framework/update_memory.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/index.d.ts +0 -5
- package/dist/tests/framework-init-test/framework-mcp/src/tools/index.js +0 -26
- package/dist/tests/framework-init-test/framework-mcp/src/tools/index.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/messaging/log_action.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/messaging/log_action.js +0 -23
- package/dist/tests/framework-init-test/framework-mcp/src/tools/messaging/log_action.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/messaging/send_message.d.ts +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/messaging/send_message.js +0 -24
- package/dist/tests/framework-init-test/framework-mcp/src/tools/messaging/send_message.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/tools/types.d.ts +0 -47
- package/dist/tests/framework-init-test/framework-mcp/src/tools/types.js +0 -2
- package/dist/tests/framework-init-test/framework-mcp/src/tools/types.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/utils/cli.d.ts +0 -5
- package/dist/tests/framework-init-test/framework-mcp/src/utils/cli.js +0 -21
- package/dist/tests/framework-init-test/framework-mcp/src/utils/cli.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/src/utils/security.d.ts +0 -12
- package/dist/tests/framework-init-test/framework-mcp/src/utils/security.js +0 -54
- package/dist/tests/framework-init-test/framework-mcp/src/utils/security.js.map +0 -1
- package/dist/tests/framework-init-test/framework-mcp/tests/tools/file_system/replace_text.test.d.ts +0 -1
- package/dist/tests/framework-init-test/framework-mcp/tests/tools/file_system/replace_text.test.js +0 -69
- package/dist/tests/framework-init-test/framework-mcp/tests/tools/file_system/replace_text.test.js.map +0 -1
- package/dist/tests/framework-init-test/panda.config.d.ts +0 -4
- package/dist/tests/framework-init-test/panda.config.js +0 -95
- package/dist/tests/framework-init-test/panda.config.js.map +0 -1
- package/dist/tests/framework-init-test/vitest.config.d.ts +0 -2
- package/dist/tests/framework-init-test/vitest.config.js +0 -19
- package/dist/tests/framework-init-test/vitest.config.js.map +0 -1
package/src/cli/adapters.ts
CHANGED
|
@@ -22,14 +22,14 @@ export interface AdapterConfig {
|
|
|
22
22
|
export const ADAPTERS: Record<AdapterId, AdapterConfig> = {
|
|
23
23
|
gemini: {
|
|
24
24
|
id: "gemini",
|
|
25
|
-
frameworkDir: ".
|
|
26
|
-
shimFile: "
|
|
25
|
+
frameworkDir: ".enderun",
|
|
26
|
+
shimFile: "GEMINI.md",
|
|
27
27
|
templateDir: ".enderun",
|
|
28
28
|
nestedDirs: ["agents", "skills", "knowledge"],
|
|
29
29
|
},
|
|
30
30
|
claude: {
|
|
31
31
|
id: "claude",
|
|
32
|
-
frameworkDir: ".
|
|
32
|
+
frameworkDir: ".enderun",
|
|
33
33
|
shimFile: "CLAUDE.md",
|
|
34
34
|
templateDir: ".enderun",
|
|
35
35
|
nestedDirs: ["agents", "skills", "knowledge"],
|
|
@@ -50,24 +50,24 @@ export const ADAPTERS: Record<AdapterId, AdapterConfig> = {
|
|
|
50
50
|
},
|
|
51
51
|
grok: {
|
|
52
52
|
id: "grok",
|
|
53
|
-
frameworkDir: ".
|
|
54
|
-
shimFile: "
|
|
53
|
+
frameworkDir: ".enderun",
|
|
54
|
+
shimFile: "GROK.md",
|
|
55
55
|
templateDir: ".enderun",
|
|
56
|
-
nestedDirs: ["
|
|
56
|
+
nestedDirs: ["agents", "skills", "knowledge"],
|
|
57
57
|
},
|
|
58
58
|
antigravity: {
|
|
59
59
|
id: "antigravity",
|
|
60
|
-
frameworkDir: ".
|
|
60
|
+
frameworkDir: ".enderun",
|
|
61
61
|
shimFile: "agent.md",
|
|
62
62
|
templateDir: ".enderun",
|
|
63
|
-
nestedDirs: ["
|
|
63
|
+
nestedDirs: ["agents", "skills", "knowledge"],
|
|
64
64
|
},
|
|
65
65
|
"antigravity-cli": {
|
|
66
66
|
id: "antigravity-cli",
|
|
67
|
-
frameworkDir: ".
|
|
67
|
+
frameworkDir: ".enderun",
|
|
68
68
|
shimFile: "agent.md",
|
|
69
69
|
templateDir: ".enderun",
|
|
70
|
-
nestedDirs: ["agents", "skills"],
|
|
70
|
+
nestedDirs: ["agents", "skills", "knowledge"],
|
|
71
71
|
},
|
|
72
72
|
};
|
|
73
73
|
|
|
@@ -41,7 +41,6 @@ export function checkCommand() {
|
|
|
41
41
|
{ name: "MCP Config (mcp.json)", path: "mcp.json" },
|
|
42
42
|
{ name: "ESLint Config (eslint.config.js)", path: "eslint.config.js" },
|
|
43
43
|
{ name: "ESLint Standards", path: path.join(frameworkDir, `${knowledgeDir}/eslint-standards.md`) },
|
|
44
|
-
{ name: "Backend Contract", path: path.join(pathsMap.backend, "contract.version.json") },
|
|
45
44
|
{ name: "MCP Server", path: "framework-mcp/package.json" },
|
|
46
45
|
{ name: "Panda CSS Config", path: "panda.config.ts" },
|
|
47
46
|
{ name: "Brain Dashboard", path: path.join(frameworkDir, "BRAIN_DASHBOARD.md") },
|
|
@@ -52,6 +51,11 @@ export function checkCommand() {
|
|
|
52
51
|
{ name: "Atomic Component Standards", path: path.join(pathsMap.docs, "frontend/component-patterns.md") },
|
|
53
52
|
];
|
|
54
53
|
|
|
54
|
+
// Optional app-level checks (only when apps/ has content)
|
|
55
|
+
const optionalChecks = [
|
|
56
|
+
{ name: "Backend Contract", path: path.join(pathsMap.backend, "contract.version.json") },
|
|
57
|
+
];
|
|
58
|
+
|
|
55
59
|
for (const check of checks) {
|
|
56
60
|
if (fs.existsSync(path.join(process.cwd(), check.path))) {
|
|
57
61
|
console.warn(`✅ ${check.name} found.`);
|
|
@@ -61,6 +65,14 @@ export function checkCommand() {
|
|
|
61
65
|
}
|
|
62
66
|
}
|
|
63
67
|
|
|
68
|
+
for (const check of optionalChecks) {
|
|
69
|
+
if (fs.existsSync(path.join(process.cwd(), check.path))) {
|
|
70
|
+
console.warn(`✅ ${check.name} found.`);
|
|
71
|
+
} else {
|
|
72
|
+
console.warn(`ℹ️ ${check.name} not found (${check.path}) — created with 'create-app'.`);
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
64
76
|
// Dependency Check
|
|
65
77
|
const mcpNodeModules = path.join(process.cwd(), "framework-mcp/node_modules");
|
|
66
78
|
const rootNodeModules = path.join(process.cwd(), "node_modules");
|
package/src/cli/commands/init.ts
CHANGED
|
@@ -10,15 +10,14 @@ import {
|
|
|
10
10
|
runAdapterPostInit,
|
|
11
11
|
type AdapterConfig,
|
|
12
12
|
} from "../adapters.js";
|
|
13
|
-
import { mergePackageJson, deepCleanProtocols, sanitizeJson, getPackageVersion, getValidatorPath } from "../utils/pkg.js";
|
|
13
|
+
import { mergePackageJson, deepCleanProtocols, sanitizeJson, getPackageVersion, getValidatorPath, getPackageRoot } from "../utils/pkg.js";
|
|
14
14
|
import { updateGitIgnore, ensureDir, writeJsonFile, copyDir, writeTextFile } from "../utils/fs.js";
|
|
15
15
|
import { initializeMemory } from "../utils/memory.js";
|
|
16
16
|
import { checkCommand } from "./check.js";
|
|
17
17
|
|
|
18
18
|
const __filename = fileURLToPath(import.meta.url);
|
|
19
19
|
const __dirname = path.dirname(__filename);
|
|
20
|
-
const sourceDir =
|
|
21
|
-
const targetDir = process.cwd();
|
|
20
|
+
const sourceDir = getPackageRoot();
|
|
22
21
|
|
|
23
22
|
const FRAMEWORK_VERSION = getPackageVersion();
|
|
24
23
|
|
|
@@ -130,7 +129,7 @@ const allAgents = [
|
|
|
130
129
|
}
|
|
131
130
|
];
|
|
132
131
|
|
|
133
|
-
function scaffoldCoreAgents(agentsBaseDir: string, dryRun: boolean) {
|
|
132
|
+
function scaffoldCoreAgents(targetDir: string, agentsBaseDir: string, dryRun: boolean) {
|
|
134
133
|
ensureDir(agentsBaseDir, dryRun);
|
|
135
134
|
const agentSchemaDir = path.join(agentsBaseDir, "schema");
|
|
136
135
|
ensureDir(agentSchemaDir, dryRun);
|
|
@@ -230,8 +229,11 @@ function buildDirsToCreate(adapter: AdapterConfig): string[] {
|
|
|
230
229
|
const dirs = [
|
|
231
230
|
adapter.frameworkDir,
|
|
232
231
|
...FRAMEWORK_SUBDIRS.map((d) => `${adapter.frameworkDir}/${d}`),
|
|
233
|
-
"
|
|
232
|
+
"docs", "framework-mcp",
|
|
234
233
|
];
|
|
234
|
+
if (process.env.ENDERUN_SKIP_INSTALL !== "1") {
|
|
235
|
+
dirs.push("tests");
|
|
236
|
+
}
|
|
235
237
|
if (adapter.nestedDirs) {
|
|
236
238
|
for (const nested of adapter.nestedDirs) dirs.push(`${adapter.frameworkDir}/${nested}`);
|
|
237
239
|
}
|
|
@@ -240,6 +242,7 @@ function buildDirsToCreate(adapter: AdapterConfig): string[] {
|
|
|
240
242
|
}
|
|
241
243
|
|
|
242
244
|
export async function initCommand(adapterInput?: string, dryRun = false) {
|
|
245
|
+
const targetDir = process.cwd();
|
|
243
246
|
const adapter = resolveAdapter(adapterInput);
|
|
244
247
|
const { frameworkDir, shimFile, templateDir } = adapter;
|
|
245
248
|
const targetFrameworkDir = path.join(targetDir, frameworkDir);
|
|
@@ -252,11 +255,9 @@ export async function initCommand(adapterInput?: string, dryRun = false) {
|
|
|
252
255
|
|
|
253
256
|
const filesToProcess = [...CORE_FILES, shimFile].filter(f => CORE_FILES.includes(f) || f === shimFile || fs.existsSync(path.join(sourceDir, f)));
|
|
254
257
|
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
writeJsonFile(initContractPath, { contract_hash: "initial_hash_placeholder", last_updated: new Date().toISOString() }, dryRun);
|
|
259
|
-
}
|
|
258
|
+
// apps/ directory is intentionally left empty during init.
|
|
259
|
+
// Users create apps via `agent-enderun create-app` command.
|
|
260
|
+
// Contract file is created during app scaffolding, not init.
|
|
260
261
|
|
|
261
262
|
let targetPkg: Record<string, unknown> = {};
|
|
262
263
|
try {
|
|
@@ -332,7 +333,7 @@ export async function initCommand(adapterInput?: string, dryRun = false) {
|
|
|
332
333
|
agentFolder = "plugins";
|
|
333
334
|
}
|
|
334
335
|
}
|
|
335
|
-
scaffoldCoreAgents(path.join(targetFrameworkDir, agentFolder), dryRun);
|
|
336
|
+
scaffoldCoreAgents(targetDir, path.join(targetFrameworkDir, agentFolder), dryRun);
|
|
336
337
|
|
|
337
338
|
if (!fs.existsSync(path.join(targetDir, ".git")) && !dryRun) {
|
|
338
339
|
try { execSync("git init", { cwd: targetDir, stdio: "ignore" }); } catch { /* ignore */ }
|
|
@@ -82,7 +82,7 @@ export async function orchestrateCommand() {
|
|
|
82
82
|
}
|
|
83
83
|
|
|
84
84
|
console.log("\n🤖 Görev Devredildi!");
|
|
85
|
-
console.log(`👉 Lütfen ${to} agent talimatlarını (${frameworkDir}/${agentFolder}/${to.replace("@", "")}.
|
|
85
|
+
console.log(`👉 Lütfen ${to} agent talimatlarını (${frameworkDir}/${agentFolder}/${to.replace("@", "")}.json) okuyun ve görevi yerine getirin.`);
|
|
86
86
|
console.log("\n💡 İpucu: İş bittiğinde, mesajı PROCESSED olarak işaretlemek ve ajanı boşa çıkarmak için:");
|
|
87
87
|
console.log(" npx agent-enderun status komutuyla kontrol edin.");
|
|
88
88
|
}
|
package/src/cli/utils/memory.ts
CHANGED
|
@@ -167,6 +167,10 @@ This file is the Single Source of Truth (SSOT) and the persistent memory of the
|
|
|
167
167
|
if (dryRun) {
|
|
168
168
|
console.warn(`[DRY RUN] Would initialize PROJECT_MEMORY.md at ${memoryPath}`);
|
|
169
169
|
} else {
|
|
170
|
+
const parentDir = path.dirname(memoryPath);
|
|
171
|
+
if (!fs.existsSync(parentDir)) {
|
|
172
|
+
fs.mkdirSync(parentDir, { recursive: true });
|
|
173
|
+
}
|
|
170
174
|
fs.writeFileSync(memoryPath, finalTemplate);
|
|
171
175
|
console.warn(`✅ PROJECT_MEMORY.md initialized in ${targetBase}`);
|
|
172
176
|
}
|
package/src/cli/utils/pkg.ts
CHANGED
|
@@ -35,6 +35,10 @@ function findAgentEnderunPackageRoot(): string {
|
|
|
35
35
|
let current = path.dirname(new URL(import.meta.url).pathname);
|
|
36
36
|
const root = path.parse(current).root;
|
|
37
37
|
while (current !== root) {
|
|
38
|
+
// Sandbox boundary guard: do not access parent paths outside the project workspace
|
|
39
|
+
if (!current.includes("agent-enderun")) {
|
|
40
|
+
break;
|
|
41
|
+
}
|
|
38
42
|
const pkgPath = path.join(current, "package.json");
|
|
39
43
|
if (fs.existsSync(pkgPath)) {
|
|
40
44
|
try {
|
|
@@ -191,7 +195,7 @@ export function mergePackageJson(targetPath: string, sourcePath: string): void {
|
|
|
191
195
|
if (!targetPkg.name) targetPkg.name = path.basename(process.cwd());
|
|
192
196
|
if (!targetPkg.version) targetPkg.version = "0.1.0";
|
|
193
197
|
if (!targetPkg.type) targetPkg.type = "module";
|
|
194
|
-
if (!targetPkg.workspaces) targetPkg.workspaces = ["
|
|
198
|
+
if (!targetPkg.workspaces) targetPkg.workspaces = ["framework-mcp"];
|
|
195
199
|
|
|
196
200
|
// Add metadata
|
|
197
201
|
targetPkg.enderun = {
|
package/tsconfig.json
CHANGED
package/.enderun/ARCHITECTURE.md
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
# Agent Enderun Architecture Rules
|
package/.enderun/SECURITY.md
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
# Agent Enderun Security Rules
|
package/bin/init-check.js
DELETED
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Agent Enderun — Init Validation Helper
|
|
5
|
-
*
|
|
6
|
-
* 📌 Low-usage dev/reference script.
|
|
7
|
-
* Not wired into main `agent-enderun` CLI commands.
|
|
8
|
-
* Use for manual post-init validation during development or testing.
|
|
9
|
-
* See `src/cli/commands/check.ts` and `bin/validate-agent-army.js` for primary paths.
|
|
10
|
-
*/
|
|
11
|
-
|
|
12
|
-
import fs from "fs";
|
|
13
|
-
import path from "path";
|
|
14
|
-
|
|
15
|
-
const targetDir = process.cwd();
|
|
16
|
-
|
|
17
|
-
const candidates = [
|
|
18
|
-
".gemini/antigravity",
|
|
19
|
-
".gemini/antigravity-cli",
|
|
20
|
-
".gemini",
|
|
21
|
-
".claude",
|
|
22
|
-
".grok",
|
|
23
|
-
".agent",
|
|
24
|
-
".enderun",
|
|
25
|
-
];
|
|
26
|
-
let frameworkDir = ".enderun";
|
|
27
|
-
for (const dir of candidates) {
|
|
28
|
-
if (fs.existsSync(path.join(targetDir, dir))) {
|
|
29
|
-
frameworkDir = dir;
|
|
30
|
-
break;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
let backend = "apps/backend";
|
|
35
|
-
let docs = "docs";
|
|
36
|
-
|
|
37
|
-
try {
|
|
38
|
-
const configPath = path.join(targetDir, frameworkDir, "config.json");
|
|
39
|
-
if (fs.existsSync(configPath)) {
|
|
40
|
-
const config = JSON.parse(fs.readFileSync(configPath, "utf8"));
|
|
41
|
-
if (config.paths) {
|
|
42
|
-
if (config.paths.backend) backend = config.paths.backend;
|
|
43
|
-
if (config.paths.docs) docs = config.paths.docs;
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
} catch {
|
|
47
|
-
// ignore
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
const CRITICAL_STRUCTURE = [
|
|
51
|
-
`${frameworkDir}/agents`,
|
|
52
|
-
`${frameworkDir}/knowledge`,
|
|
53
|
-
`${frameworkDir}/memory-graph/agent-contexts`,
|
|
54
|
-
`${frameworkDir}/logs`,
|
|
55
|
-
`${frameworkDir}/queue`,
|
|
56
|
-
`${frameworkDir}/PROJECT_MEMORY.md`,
|
|
57
|
-
`${docs}/architecture/standards`,
|
|
58
|
-
`${backend}/src/database`,
|
|
59
|
-
`${backend}/src/seeds`,
|
|
60
|
-
`${backend}/migrations`
|
|
61
|
-
];
|
|
62
|
-
|
|
63
|
-
function checkIntegrity() {
|
|
64
|
-
console.warn("🔍 Running Agent Enderun Framework Integrity Check...");
|
|
65
|
-
let isHealthy = true;
|
|
66
|
-
|
|
67
|
-
for (const item of CRITICAL_STRUCTURE) {
|
|
68
|
-
const fullPath = path.join(targetDir, item);
|
|
69
|
-
if (!fs.existsSync(fullPath)) {
|
|
70
|
-
console.error(`❌ Missing critical component: ${item}`);
|
|
71
|
-
isHealthy = false;
|
|
72
|
-
} else {
|
|
73
|
-
console.warn(`✅ Verified: ${item}`);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
if (isHealthy) {
|
|
78
|
-
console.warn("\n✨ Framework integrity verified. System is healthy.");
|
|
79
|
-
process.exit(0);
|
|
80
|
-
} else {
|
|
81
|
-
console.error("\n❌ Framework integrity check FAILED. Some components are missing.");
|
|
82
|
-
process.exit(1);
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
checkIntegrity();
|
package/bin/update-contract.js
DELETED
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
|
-
import fs from "fs";
|
|
4
|
-
import path from "path";
|
|
5
|
-
import crypto from "crypto";
|
|
6
|
-
import { fileURLToPath } from "url";
|
|
7
|
-
|
|
8
|
-
const __filename = fileURLToPath(import.meta.url);
|
|
9
|
-
const __dirname = path.dirname(__filename);
|
|
10
|
-
const projectRoot = path.join(__dirname, "..");
|
|
11
|
-
|
|
12
|
-
const candidates = [
|
|
13
|
-
".gemini/antigravity",
|
|
14
|
-
".gemini/antigravity-cli",
|
|
15
|
-
".gemini",
|
|
16
|
-
".claude",
|
|
17
|
-
".grok",
|
|
18
|
-
".agent",
|
|
19
|
-
".enderun",
|
|
20
|
-
];
|
|
21
|
-
let frameworkDir = ".enderun";
|
|
22
|
-
for (const dir of candidates) {
|
|
23
|
-
if (fs.existsSync(path.join(projectRoot, dir))) {
|
|
24
|
-
frameworkDir = dir;
|
|
25
|
-
break;
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
let backend = "apps/backend";
|
|
30
|
-
try {
|
|
31
|
-
const configPath = path.join(projectRoot, frameworkDir, "config.json");
|
|
32
|
-
if (fs.existsSync(configPath)) {
|
|
33
|
-
const config = JSON.parse(fs.readFileSync(configPath, "utf8"));
|
|
34
|
-
if (config.paths && config.paths.backend) {
|
|
35
|
-
backend = config.paths.backend;
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
} catch {
|
|
39
|
-
// ignore
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
const contractPath = path.join(projectRoot, backend, "contract.version.json");
|
|
43
|
-
const sharedTypesDir = path.join(projectRoot, backend, "src/types");
|
|
44
|
-
|
|
45
|
-
function collectTypeFiles(dir) {
|
|
46
|
-
const entries = fs.readdirSync(dir, { withFileTypes: true });
|
|
47
|
-
const files = [];
|
|
48
|
-
|
|
49
|
-
for (const entry of entries) {
|
|
50
|
-
const fullPath = path.join(dir, entry.name);
|
|
51
|
-
if (entry.isDirectory()) {
|
|
52
|
-
files.push(...collectTypeFiles(fullPath));
|
|
53
|
-
} else if (entry.name.endsWith(".ts")) {
|
|
54
|
-
files.push(fullPath);
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
return files;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
function calculateHash(dir) {
|
|
62
|
-
const hash = crypto.createHash("sha256");
|
|
63
|
-
const files = collectTypeFiles(dir).sort();
|
|
64
|
-
|
|
65
|
-
files.forEach(file => {
|
|
66
|
-
const content = fs.readFileSync(file);
|
|
67
|
-
hash.update(path.relative(projectRoot, file));
|
|
68
|
-
hash.update("\0");
|
|
69
|
-
hash.update(content);
|
|
70
|
-
hash.update("\0");
|
|
71
|
-
});
|
|
72
|
-
|
|
73
|
-
return hash.digest("hex");
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
try {
|
|
77
|
-
console.log("🔍 Calculating shared-types contract hash...");
|
|
78
|
-
const newHash = calculateHash(sharedTypesDir);
|
|
79
|
-
|
|
80
|
-
const contract = JSON.parse(fs.readFileSync(contractPath, "utf-8"));
|
|
81
|
-
|
|
82
|
-
if (contract.contract_hash === newHash) {
|
|
83
|
-
console.log("✅ Contract hash is already up to date.");
|
|
84
|
-
} else {
|
|
85
|
-
contract.contract_hash = newHash;
|
|
86
|
-
contract.last_updated = new Date().toISOString();
|
|
87
|
-
fs.writeFileSync(contractPath, JSON.stringify(contract, null, 2));
|
|
88
|
-
console.log(`🚀 Contract updated with new hash: ${newHash.slice(0, 10)}...`);
|
|
89
|
-
}
|
|
90
|
-
} catch (error) {
|
|
91
|
-
console.error("❌ Failed to update contract hash:", error.message);
|
|
92
|
-
process.exit(1);
|
|
93
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../apps/backend/src/types/index.ts"],"names":[],"mappings":"AAAA;;GAEG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import ReactDOM from "react-dom/client";
|
|
3
|
-
const rootElement = document.getElementById("root");
|
|
4
|
-
if (rootElement) {
|
|
5
|
-
ReactDOM.createRoot(rootElement).render(<React.StrictMode>
|
|
6
|
-
<h1>Agent Enderun Web Active</h1>
|
|
7
|
-
</React.StrictMode>);
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=main.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"main.js","sourceRoot":"","sources":["../../../../apps/web/src/main.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,QAAQ,MAAM,kBAAkB,CAAC;AAExC,MAAM,WAAW,GAAG,QAAQ,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC;AACpD,IAAI,WAAW,EAAE,CAAC;IACd,QAAQ,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC,MAAM,CACnC,CAAC,KAAK,CAAC,UAAU,CACb;YAAA,CAAC,EAAE,CAAC,wBAAwB,EAAE,EAAE,CACpC;QAAA,EAAE,KAAK,CAAC,UAAU,CAAC,CACtB,CAAC;AACN,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"vite.config.js","sourceRoot":"","sources":["../../../apps/web/vite.config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,KAAK,MAAM,sBAAsB,CAAC;AAEzC,eAAe,YAAY,CAAC;IACxB,OAAO,EAAE,CAAC,KAAK,EAAE,CAAC;CACrB,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
import { Server } from "@modelcontextprotocol/sdk/server/index.js";
|
|
2
|
-
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
3
|
-
import { CallToolRequestSchema, ListToolsRequestSchema, } from "@modelcontextprotocol/sdk/types.js";
|
|
4
|
-
import { TOOLS, toolHandlers } from "./tools/index.js";
|
|
5
|
-
// ─── Server Setup ─────────────────────────────────────────────────
|
|
6
|
-
const server = new Server({
|
|
7
|
-
name: "@agent-enderun/mcp",
|
|
8
|
-
version: "1.0.9",
|
|
9
|
-
}, {
|
|
10
|
-
capabilities: {
|
|
11
|
-
tools: {},
|
|
12
|
-
},
|
|
13
|
-
});
|
|
14
|
-
server.setRequestHandler(ListToolsRequestSchema, async () => {
|
|
15
|
-
return { tools: TOOLS };
|
|
16
|
-
});
|
|
17
|
-
server.setRequestHandler(CallToolRequestSchema, async (request) => {
|
|
18
|
-
const typedRequest = request;
|
|
19
|
-
const { name, arguments: args } = typedRequest.params;
|
|
20
|
-
const projectRoot = process.env.ENDERUN_PROJECT_ROOT || process.cwd();
|
|
21
|
-
try {
|
|
22
|
-
const handler = toolHandlers[name];
|
|
23
|
-
if (!handler) {
|
|
24
|
-
return {
|
|
25
|
-
isError: true,
|
|
26
|
-
content: [{ type: "text", text: `Unknown tool: ${name}` }],
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
return handler(projectRoot, args || {});
|
|
30
|
-
}
|
|
31
|
-
catch (error) {
|
|
32
|
-
const message = error instanceof Error ? error.message : "Unknown error occurred";
|
|
33
|
-
return {
|
|
34
|
-
isError: true,
|
|
35
|
-
content: [{ type: "text", text: message }],
|
|
36
|
-
};
|
|
37
|
-
}
|
|
38
|
-
});
|
|
39
|
-
// ─── Graceful Startup & Shutdown ──────────────────────────────────
|
|
40
|
-
async function run() {
|
|
41
|
-
const transport = new StdioServerTransport();
|
|
42
|
-
// Prevent unhandled errors from crashing the MCP stream
|
|
43
|
-
process.on("uncaughtException", (error) => {
|
|
44
|
-
process.stderr.write(`[agent-enderun-mcp] Uncaught exception: ${error.message}
|
|
45
|
-
`);
|
|
46
|
-
});
|
|
47
|
-
process.on("unhandledRejection", (reason) => {
|
|
48
|
-
const message = reason instanceof Error ? reason.message : String(reason);
|
|
49
|
-
process.stderr.write(`[agent-enderun-mcp] Unhandled rejection: ${message}
|
|
50
|
-
`);
|
|
51
|
-
});
|
|
52
|
-
// Graceful shutdown on SIGINT/SIGTERM
|
|
53
|
-
const shutdown = async () => {
|
|
54
|
-
try {
|
|
55
|
-
await server.close();
|
|
56
|
-
}
|
|
57
|
-
catch {
|
|
58
|
-
// Already closed or failed — safe to ignore
|
|
59
|
-
}
|
|
60
|
-
process.exit(0);
|
|
61
|
-
};
|
|
62
|
-
process.on("SIGINT", shutdown);
|
|
63
|
-
process.on("SIGTERM", shutdown);
|
|
64
|
-
await server.connect(transport);
|
|
65
|
-
}
|
|
66
|
-
run().catch((error) => {
|
|
67
|
-
process.stderr.write(`[agent-enderun-mcp] Fatal startup error: ${error.message}
|
|
68
|
-
`);
|
|
69
|
-
process.exit(1);
|
|
70
|
-
});
|
|
71
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../tests/framework-init-test/framework-mcp/src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,2CAA2C,CAAC;AACnE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EACH,qBAAqB,EACrB,sBAAsB,GACzB,MAAM,oCAAoC,CAAC;AAG5C,OAAO,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAGvD,qEAAqE;AAErE,MAAM,MAAM,GAAG,IAAI,MAAM,CACrB;IACI,IAAI,EAAE,oBAAoB;IAC1B,OAAO,EAAE,OAAO;CACnB,EACD;IACI,YAAY,EAAE;QACV,KAAK,EAAE,EAAE;KACZ;CACJ,CACJ,CAAC;AAEF,MAAM,CAAC,iBAAiB,CAAC,sBAAsB,EAAE,KAAK,IAAI,EAAE;IACxD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC;AAC5B,CAAC,CAAC,CAAC;AAEH,MAAM,CAAC,iBAAiB,CAAC,qBAAqB,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE;IAC9D,MAAM,YAAY,GAAG,OAA0B,CAAC;IAChD,MAAM,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,GAAG,YAAY,CAAC,MAAM,CAAC;IACtD,MAAM,WAAW,GAAG,OAAO,CAAC,GAAG,CAAC,oBAAoB,IAAI,OAAO,CAAC,GAAG,EAAE,CAAC;IAEtE,IAAI,CAAC;QACD,MAAM,OAAO,GAAG,YAAY,CAAC,IAAI,CAAC,CAAC;QACnC,IAAI,CA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AC,KAAK,EAAE,CAAC;QACzB,CAAC;QAAC,MAAM,CAAC;YACL,4CAA4C;QAChD,CAAC;QACD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACpB,CAAC,CAAC;IACF,OAAO,CAAC,EAAE,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;IAC/B,OAAO,CAAC,EAAE,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IAEhC,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;AACpC,CAAC;AAED,GAAG,EAAE,CAAC,KAAK,CAAC,CAAC,KAAY,EAAE,EAAE;IACzB,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,4CAA4C,KAAK,CAAC,OAAO;CACjF,CAAC,CAAC;IACC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AACpB,CAAC,CAAC,CAAC"}
|
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
export const TOOLS = [
|
|
2
|
-
{
|
|
3
|
-
name: "read_file",
|
|
4
|
-
description: "Read the content of a file within the project.",
|
|
5
|
-
inputSchema: {
|
|
6
|
-
type: "object",
|
|
7
|
-
properties: {
|
|
8
|
-
path: { type: "string", description: "Path to the file relative to project root" },
|
|
9
|
-
},
|
|
10
|
-
required: ["path"],
|
|
11
|
-
},
|
|
12
|
-
},
|
|
13
|
-
{
|
|
14
|
-
name: "write_file",
|
|
15
|
-
description: "Write content to a file. Creates directories if missing.",
|
|
16
|
-
inputSchema: {
|
|
17
|
-
type: "object",
|
|
18
|
-
properties: {
|
|
19
|
-
path: { type: "string", description: "Path to the file relative to project root" },
|
|
20
|
-
content: { type: "string", description: "Complete content of the file" },
|
|
21
|
-
},
|
|
22
|
-
required: ["path", "content"],
|
|
23
|
-
},
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
name: "replace_text",
|
|
27
|
-
description: "Surgically replace a string in a file with another string.",
|
|
28
|
-
inputSchema: {
|
|
29
|
-
type: "object",
|
|
30
|
-
properties: {
|
|
31
|
-
path: { type: "string", description: "Path to the file" },
|
|
32
|
-
oldText: { type: "string", description: "The exact text to find" },
|
|
33
|
-
newText: { type: "string", description: "The text to replace it with" },
|
|
34
|
-
},
|
|
35
|
-
required: ["path", "oldText", "newText"],
|
|
36
|
-
},
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
name: "patch_file",
|
|
40
|
-
description: "Safely update a file by replacing a specific line range with new content.",
|
|
41
|
-
inputSchema: {
|
|
42
|
-
type: "object",
|
|
43
|
-
properties: {
|
|
44
|
-
path: { type: "string", description: "Path to the file" },
|
|
45
|
-
startLine: { type: "number", description: "Starting line number (1-indexed)" },
|
|
46
|
-
endLine: { type: "number", description: "Ending line number (inclusive)" },
|
|
47
|
-
newContent: { type: "string", description: "The new lines to insert" },
|
|
48
|
-
},
|
|
49
|
-
required: ["path", "startLine", "endLine", "newContent"],
|
|
50
|
-
},
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
name: "get_framework_status",
|
|
54
|
-
description: "Get the current project phase, active traces, and agent states.",
|
|
55
|
-
inputSchema: { type: "object", properties: {} },
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
name: "update_project_memory",
|
|
59
|
-
description: "Update a specific section in PROJECT_MEMORY.md.",
|
|
60
|
-
inputSchema: {
|
|
61
|
-
type: "object",
|
|
62
|
-
properties: {
|
|
63
|
-
section: { type: "string", description: "Section name (e.g., HISTORY, ACTIVE TASKS)" },
|
|
64
|
-
content: { type: "string", description: "Markdown content to append or set" },
|
|
65
|
-
},
|
|
66
|
-
required: ["section", "content"],
|
|
67
|
-
},
|
|
68
|
-
},
|
|
69
|
-
{
|
|
70
|
-
name: "orchestrate_loop",
|
|
71
|
-
description: "Process the pending Hermes messages and trigger dynamic state transitions.",
|
|
72
|
-
inputSchema: { type: "object", properties: {} },
|
|
73
|
-
},
|
|
74
|
-
{
|
|
75
|
-
name: "send_agent_message",
|
|
76
|
-
description: "Send a Hermes protocol message to another agent.",
|
|
77
|
-
inputSchema: {
|
|
78
|
-
type: "object",
|
|
79
|
-
properties: {
|
|
80
|
-
from: { type: "string", description: "Sender agent (e.g., @manager, @backend). Defaults to @mcp if omitted." },
|
|
81
|
-
to: { type: "string", description: "Target agent (e.g., @backend, @qa)" },
|
|
82
|
-
category: { type: "string", enum: ["ACTION", "DELEGATION", "INFO", "ALERT"] },
|
|
83
|
-
content: { type: "string", description: "Message content" },
|
|
84
|
-
traceId: { type: "string", description: "Active Trace ID" },
|
|
85
|
-
},
|
|
86
|
-
required: ["to", "category", "content", "traceId"],
|
|
87
|
-
},
|
|
88
|
-
},
|
|
89
|
-
{
|
|
90
|
-
name: "log_agent_action",
|
|
91
|
-
description: "Log an agent action to the framework logs.",
|
|
92
|
-
inputSchema: {
|
|
93
|
-
type: "object",
|
|
94
|
-
properties: {
|
|
95
|
-
agent: { type: "string", description: "The agent name (e.g., @manager, @backend)" },
|
|
96
|
-
action: { type: "string", description: "Action type or name" },
|
|
97
|
-
traceId: { type: "string", description: "The active Trace ID" },
|
|
98
|
-
status: { type: "string", enum: ["SUCCESS", "FAILURE"], description: "The status of the action" },
|
|
99
|
-
summary: { type: "string", description: "Brief description of the action taken" },
|
|
100
|
-
findings: { type: "string", description: "Optional comma-separated findings or details" }
|
|
101
|
-
},
|
|
102
|
-
required: ["agent", "action", "traceId", "status", "summary"]
|
|
103
|
-
}
|
|
104
|
-
},
|
|
105
|
-
{
|
|
106
|
-
name: "update_contract_hash",
|
|
107
|
-
description: "Re-generate and synchronize the backend contract SHA-256 hash.",
|
|
108
|
-
inputSchema: { type: "object", properties: {} }
|
|
109
|
-
}
|
|
110
|
-
];
|
|
111
|
-
//# sourceMappingURL=definitions.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"definitions.js","sourceRoot":"","sources":["../../../../../../tests/framework-init-test/framework-mcp/src/tools/definitions.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,KAAK,GAAqB;IAC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