@bonginkan/maria 4.3.40 → 4.3.42

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # MARIA - AI Development Platform v4.3.40
1
+ # MARIA - AI Development Platform v4.3.42
2
2
 
3
3
  [![npm version](https://img.shields.io/npm/v/@bonginkan/maria.svg)](https://www.npmjs.com/package/@bonginkan/maria)
4
4
  [![License](https://img.shields.io/badge/license-Multi--tier-blue.svg)](LICENSE)
@@ -10,7 +10,7 @@
10
10
 
11
11
  > **Enterprise-grade AI development platform with 100% command availability and comprehensive fallback support**
12
12
 
13
- ## 🚀 What's New in v4.3.40 (October, 2025)
13
+ ## 🚀 What's New in v4.3.42 (October, 2025)
14
14
 
15
15
  ### Functinal enhancements
16
16
  - **Enhanced Natural Language Support**: Main commands called automatically by natural language input
@@ -927,7 +927,7 @@ await secureWorkflow.executeWithAuth(workflowDefinition, securityContext);
927
927
  ### Quick Installation
928
928
  ```bash
929
929
  # Install globally (recommended)
930
- npm install -g @bonginkan/maria@4.3.40
930
+ npm install -g @bonginkan/maria@4.3.42
931
931
 
932
932
  # Verify installation
933
933
  maria --version # Should show v4.3.9
@@ -1131,7 +1131,7 @@ MARIA CODE is distributed under a comprehensive licensing system designed for in
1131
1131
 
1132
1132
  *MARIA v4.1.4 represents the pinnacle of multimodal AI development platform evolution - combining revolutionary voice-to-code capabilities, advanced memory systems, and comprehensive command ecosystems with enterprise-grade security and performance. This release establishes MARIA as the definitive choice for developers and Fortune 500 enterprises seeking intelligent, multimodal development experiences with GraphRAG intelligence, multilingual support, and zero-anxiety coding workflows.*
1133
1133
 
1134
- **Transform your development experience today**: `npm install -g @bonginkan/maria@4.3.40`
1134
+ **Transform your development experience today**: `npm install -g @bonginkan/maria@4.3.42`
1135
1135
 
1136
1136
  🌐 **Official Website**: [https://maria-code.ai](https://maria-code.ai)
1137
1137
  💬 **Community**: [https://discord.gg/SMSmSGcEQy](https://discord.gg/SMSmSGcEQy)
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": "lite-1.0.0",
3
- "generatedAt": "2025-10-05T10:57:31.633Z",
3
+ "generatedAt": "2025-10-05T11:54:11.483Z",
4
4
  "totalCommands": 19,
5
5
  "readyCount": 19,
6
6
  "partialCount": 0,
@@ -26066,8 +26066,8 @@ var require_package = __commonJS({
26066
26066
  "package.json"(exports, module) {
26067
26067
  module.exports = {
26068
26068
  name: "@bonginkan/maria",
26069
- version: "4.3.40",
26070
- description: "\u{1F680} MARIA v4.3.40 - Enterprise AI Development Platform with identity system and character voice implementation. Features 74 production-ready commands with comprehensive fallback implementation, local LLM support, and zero external dependencies. Includes natural language coding, AI safety evaluation, intelligent evolution system, episodic memory with PII masking, and real-time monitoring dashboard. Built with TypeScript AST-powered code generation, OAuth2.0 + PKCE authentication, quantum-resistant cryptography, and enterprise-grade performance.",
26069
+ version: "4.3.42",
26070
+ description: "\u{1F680} MARIA v4.3.42 - Enterprise AI Development Platform with identity system and character voice implementation. Features 74 production-ready commands with comprehensive fallback implementation, local LLM support, and zero external dependencies. Includes natural language coding, AI safety evaluation, intelligent evolution system, episodic memory with PII masking, and real-time monitoring dashboard. Built with TypeScript AST-powered code generation, OAuth2.0 + PKCE authentication, quantum-resistant cryptography, and enterprise-grade performance.",
26071
26071
  keywords: [
26072
26072
  "ai",
26073
26073
  "cli",
@@ -28104,7 +28104,7 @@ var init_AuthenticationManager = __esm({
28104
28104
  const response = await fetch(`${this.apiBase}/api/user/profile`, {
28105
28105
  headers: {
28106
28106
  "Authorization": `Bearer ${tokens2.accessToken}`,
28107
- "User-Agent": `maria-cli/${process.env.CLI_VERSION || "4.3.40"}`
28107
+ "User-Agent": `maria-cli/${process.env.CLI_VERSION || "4.3.42"}`
28108
28108
  }
28109
28109
  });
28110
28110
  if (response.status === 401) {
@@ -28758,7 +28758,7 @@ async function callApi(path65, init3 = {}) {
28758
28758
  "Authorization": `Bearer ${token}`,
28759
28759
  "X-Device-Id": getDeviceId(),
28760
28760
  "X-Session-Id": getSessionId() || "",
28761
- "User-Agent": `maria-cli/${process.env.CLI_VERSION || "4.3.40"}`,
28761
+ "User-Agent": `maria-cli/${process.env.CLI_VERSION || "4.3.42"}`,
28762
28762
  "Content-Type": init3.headers?.["Content-Type"] || "application/json"
28763
28763
  });
28764
28764
  const doFetch = async (token) => {
@@ -29103,7 +29103,7 @@ async function callAPI(endpoint, options = {}) {
29103
29103
  }
29104
29104
  }
29105
29105
  async function executeChat(messages) {
29106
- const response = await callAPI("/v1/chat", {
29106
+ const response = await callAPI("/v1/ai-proxy", {
29107
29107
  method: "POST",
29108
29108
  body: { messages }
29109
29109
  });
@@ -51261,7 +51261,7 @@ var init_about_command = __esm({
51261
51261
  async execute(args2, context2) {
51262
51262
  const output3 = [];
51263
51263
  output3.push("");
51264
- output3.push(chalk14__default.default.cyan.bold("\u{1F916} About MARIA v4.3.40"));
51264
+ output3.push(chalk14__default.default.cyan.bold("\u{1F916} About MARIA v4.3.42"));
51265
51265
  output3.push(chalk14__default.default.gray("\u2550".repeat(40)));
51266
51266
  output3.push("");
51267
51267
  output3.push(chalk14__default.default.white.bold("MARIA - Minimal API, Maximum Power"));
@@ -55955,20 +55955,6 @@ var init_policy = __esm({
55955
55955
  }
55956
55956
  });
55957
55957
 
55958
- // src/utils/esm-compat.ts
55959
- var esm_compat_exports = {};
55960
- __export(esm_compat_exports, {
55961
- loadGlobby: () => loadGlobby
55962
- });
55963
- async function loadGlobby() {
55964
- const mod = await import('globby');
55965
- return mod?.globby ?? mod?.default ?? mod;
55966
- }
55967
- var init_esm_compat = __esm({
55968
- "src/utils/esm-compat.ts"() {
55969
- }
55970
- });
55971
-
55972
55958
  // src/services/code-orchestrator/Orchestrator.ts
55973
55959
  var Orchestrator_exports = {};
55974
55960
  __export(Orchestrator_exports, {
@@ -56042,6 +56028,14 @@ async function readHeadTail(root, rel, n) {
56042
56028
  return { head: "", tail: "" };
56043
56029
  }
56044
56030
  }
56031
+ function extractJsonSafe(text, kind) {
56032
+ if (!text) return null;
56033
+ const fenceRegex = /```\s*(json)?\s*\r?\n([\s\S]*?)```/i;
56034
+ const fence = fenceRegex.exec(text);
56035
+ if (fence && fence[2]) text = fence[2];
56036
+ const match2 = kind === "object" ? text.match(/\{[\s\S]*\}/) : text.match(/\[[\s\S]*\]/);
56037
+ return match2 ? match2[0] : null;
56038
+ }
56045
56039
  async function llmSelectEditTargets(root, request, repoFiles) {
56046
56040
  try {
56047
56041
  const candidates = repoFiles.filter((p) => /\.(html|css|js|ts|tsx)$/i.test(p)).slice(0, 150);
@@ -56054,7 +56048,7 @@ ${h2.head}`);
56054
56048
  const system = [
56055
56049
  "You select existing repository files that should be EDITED to satisfy a user request.",
56056
56050
  "Consider path names and the first lines. Return JSON array of repo-relative paths to edit.",
56057
- "Keep the list short (<= 10). If none are relevant, return []. Do not invent paths."
56051
+ "If none are relevant, return []. Do not invent paths."
56058
56052
  ].join("\n");
56059
56053
  const user = [`Request: ${request}`, "Candidates:", samples.join("\n\n")].join("\n\n");
56060
56054
  const resp = await executeChat([
@@ -56174,9 +56168,10 @@ async function orchestrate(request, opts) {
56174
56168
  explicitAbsMap[rel] = pathMod.join(opts.root, rel);
56175
56169
  }
56176
56170
  }
56177
- const isEditIntent = await detectEditIntentEnhanced(opts.root, request, {
56178
- hasAttachments: !!(opts.attachedFiles && opts.attachedFiles.length > 0),
56179
- explicitFiles});
56171
+ const isEditIntent = await detectEditIntentLLM(opts.root, request, {
56172
+ explicitFiles,
56173
+ attachmentsCount: Array.isArray(opts.attachedFiles) ? opts.attachedFiles.length : 0
56174
+ });
56180
56175
  let editTargets = explicitFiles;
56181
56176
  if (isEditIntent && editTargets.length === 0) {
56182
56177
  try {
@@ -56280,7 +56275,6 @@ ${editContext}`;
56280
56275
  if (attachedPathSet.has(key)) continue;
56281
56276
  const stat13 = await fs52.stat(full).catch(() => null);
56282
56277
  if (!stat13 || !stat13.isFile()) continue;
56283
- const ext2 = (pathMod.extname(full) || "").toLowerCase();
56284
56278
  const buf = await fs52.readFile(full);
56285
56279
  pathAttachments.push({
56286
56280
  name: pathMod.basename(full),
@@ -56536,7 +56530,7 @@ ${editContext}`;
56536
56530
  }
56537
56531
  }
56538
56532
  const allowOverwrite = opts.flags.overwriteAllowed === true || !!opts.flags.yes || isEditIntent;
56539
- const applyRes = await applyPlans(approved, { root: opts.root, overwriteAllowed: allowOverwrite, rollback: opts.flags.rollback !== false, signal: opts.abortSignal, onProgress: (w, t2) => {
56533
+ const applyRes = await applyPlans(approved, { root: opts.root, overwriteAllowed: allowOverwrite, rollback: opts.flags.rollback !== false, signal: opts.abortSignal, onProgress: () => {
56540
56534
  }, eol: profile.eol });
56541
56535
  appliedCount = applyRes.appliedCount;
56542
56536
  durationMs = applyRes.durationMs;
@@ -56816,73 +56810,50 @@ function parseExplicitFilenames(request) {
56816
56810
  }
56817
56811
  return out;
56818
56812
  }
56819
- function detectEditIntent(request, ctx2) {
56820
- const r2 = request.toLowerCase();
56821
- const editKeywords = ["modify", "edit", "update", "fix", "refactor", "change", "patch", "\u5DEE\u5206", "\u4FEE\u6B63", "\u5909\u66F4", "\u65E2\u5B58", "\u8FFD\u8A18"];
56822
- const mentionsEdit = editKeywords.some((k) => r2.includes(k));
56823
- return ctx2.hasAttachments || ctx2.explicitFilesCount > 0 || mentionsEdit;
56824
- }
56825
- async function detectEditIntentEnhanced(root, request, ctx2) {
56826
- const baseline = detectEditIntent(request, { hasAttachments: ctx2.hasAttachments, explicitFilesCount: ctx2.explicitFiles.length });
56827
- if (baseline) return true;
56828
- const r2 = request.toLowerCase();
56829
- const softHints = ["improve", "enhance", "make it", "change the", "adjust", "tweak", "rework", "revamp", "retro", "modernize", "clean up", "polish"];
56830
- const hasSoftHint = softHints.some((k) => r2.includes(k));
56831
- if (!hasSoftHint) return false;
56832
- try {
56833
- const fs52 = await import('fs/promises');
56834
- const pathMod = await import('path');
56835
- const { loadGlobby: loadGlobby2 } = await Promise.resolve().then(() => (init_esm_compat(), esm_compat_exports));
56836
- const globby = await loadGlobby2();
56837
- const ignore = [
56838
- "**/node_modules/**",
56839
- "**/.git/**",
56840
- "**/dist/**",
56841
- "**/build/**",
56842
- "**/.maria/**",
56843
- "**/.next/**",
56844
- "**/coverage/**",
56845
- "**/.DS_Store/**",
56846
- "**/.DS_Store",
56847
- "**/.Spotlight-V100/**",
56848
- "**/.Spotlight-V100",
56849
- "**/.Trashes/**",
56850
- "**/.Trashes",
56851
- "**/.fseventsd/**",
56852
- "**/.fseventsd",
56853
- "**/.TemporaryItems/**",
56854
- "**/.TemporaryItems"
56855
- ];
56856
- const candidates = await globby(["**/*.{html,css,js,ts,tsx}"], { cwd: root, absolute: true, gitignore: true, ignore, deep: 3 });
56857
- if (candidates && candidates.length > 0) return true;
56858
- } catch {
56859
- }
56813
+ async function detectEditIntentLLM(root, request, ctx2) {
56860
56814
  try {
56861
- const short = request.trim().length <= 160;
56862
- if (!short) return false;
56815
+ const repoFiles = await getRepoFiles(root);
56816
+ const candidates = repoFiles;
56817
+ const headSnippets = [];
56818
+ for (const p of candidates) {
56819
+ const h2 = await readHeadTail(root, p, 5);
56820
+ headSnippets.push(`- ${p}
56821
+ ${h2.head}`);
56822
+ }
56863
56823
  const system = [
56864
- "You are classifying whether the user intends to EDIT existing files vs CREATE a new project.",
56865
- 'Return JSON: { "edit": true|false } only.'
56824
+ "Classify the user intent for the MARIA code orchestrator.",
56825
+ "Decide strictly between EDIT_EXISTING (modify existing files) or CREATE_NEW (generate new project/files).",
56826
+ "User is likely to have EDIT_EXITING intent when:",
56827
+ "- the coding language is not specified",
56828
+ "- it has a clear and/or relevant path of the file/directory exists",
56829
+ "- it has attachments",
56830
+ "- the wording implies modifying existing files (ex. fix, improve, update, change, patch, make it, clean up, etc.)",
56831
+ 'Return JSON: { "intent": "EDIT_EXISTING" | "CREATE_NEW" } only. No commentary.'
56866
56832
  ].join("\n");
56867
- const user = `Instruction: ${request}`;
56833
+ const user = [
56834
+ `Request: ${request}`,
56835
+ `ExplicitFiles: ${JSON.stringify(ctx2.explicitFiles || [])}`,
56836
+ `AttachmentsCount: ${ctx2.attachmentsCount}`,
56837
+ "Repo snapshot (paths with file heads):",
56838
+ headSnippets.join("\n\n")
56839
+ ].join("\n\n");
56840
+ const spin1 = new ProcessAnimation();
56841
+ spin1.start();
56868
56842
  const resp = await executeChat([
56869
56843
  { role: "system", content: system },
56870
56844
  { role: "user", content: user }
56871
56845
  ]);
56846
+ try {
56847
+ spin1.stop();
56848
+ } catch {
56849
+ }
56872
56850
  const raw = (resp?.output || "").trim();
56873
- const jsonText = (() => {
56874
- try {
56875
- const m2 = raw.match(/\{[\s\S]*\}/);
56876
- return m2 ? m2[0] : raw;
56877
- } catch {
56878
- return raw;
56879
- }
56880
- })();
56851
+ const jsonText = extractJsonSafe(raw, "object") || raw;
56881
56852
  const parsed = JSON.parse(jsonText);
56882
- if (typeof parsed?.edit === "boolean") return !!parsed.edit;
56853
+ return parsed?.intent === "EDIT_EXISTING";
56883
56854
  } catch {
56855
+ return ctx2.explicitFiles && ctx2.explicitFiles.length > 0 || ctx2.attachmentsCount > 0;
56884
56856
  }
56885
- return false;
56886
56857
  }
56887
56858
  function sanitizeFolderName(name2) {
56888
56859
  const base = name2.toLowerCase().replace(/[`~!@#$%^&*()+=\[\]{}|;:'",<>/?\\]/g, " ").replace(/\s+/g, "-").replace(/^-+|-+$/g, "").slice(0, 48);
@@ -57004,7 +56975,6 @@ async function resolveExplicitPaths(root, files, hintText) {
57004
56975
  const lowerRel = normalized.toLowerCase();
57005
56976
  const ext2 = (pathMod.extname(normalized) || "").toLowerCase();
57006
56977
  const base = pathMod.basename(normalized);
57007
- base.replace(/\.[^.]+$/, "").toLowerCase();
57008
56978
  const parentPath = pathMod.dirname(normalized);
57009
56979
  const parent = parentPath.split("/").pop() || "";
57010
56980
  const dirParts = parentPath === "." ? [] : parentPath.split("/").filter(Boolean).map((s2) => s2.toLowerCase());
@@ -57165,6 +57135,7 @@ var init_Orchestrator = __esm({
57165
57135
  init_AttachmentMapper();
57166
57136
  init_FallbackManager();
57167
57137
  init_policy();
57138
+ init_animations();
57168
57139
  codeFallbackManager = null;
57169
57140
  _repoFileIndexCache = null;
57170
57141
  codeFallbackPolicySignature = null;
@@ -58416,6 +58387,16 @@ var init_resume_command = __esm({
58416
58387
  }
58417
58388
  });
58418
58389
 
58390
+ // src/utils/esm-compat.ts
58391
+ async function loadGlobby() {
58392
+ const mod = await import('globby');
58393
+ return mod?.globby ?? mod?.default ?? mod;
58394
+ }
58395
+ var init_esm_compat = __esm({
58396
+ "src/utils/esm-compat.ts"() {
58397
+ }
58398
+ });
58399
+
58419
58400
  // src/services/init/scanner.ts
58420
58401
  var scanner_exports = {};
58421
58402
  __export(scanner_exports, {