micro-models-agent 0.41.0 → 0.41.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/bin/mma.mjs +41 -41
- package/dist/cli/commands.js +9 -19
- package/dist/cli/completer.js +36 -37
- package/dist/cli/index.js +2 -2
- package/dist/cli/main.js +48 -23
- package/dist/cli/plugin-commands.js +36 -0
- package/dist/cli/repl-commands.js +40 -12
- package/dist/cli/repl.js +217 -87
- package/dist/cli/run-result.js +22 -0
- package/dist/cli/security-commands.js +5 -7
- package/dist/cli/setup.js +8 -26
- package/dist/config/config.js +52 -5
- package/dist/config/defaults.js +29 -5
- package/dist/config/experts.js +1 -1
- package/dist/config/index.js +3 -3
- package/dist/config/security.js +3 -10
- package/dist/core/agent-moe.js +2 -10
- package/dist/core/agent.js +273 -82
- package/dist/core/bootstrap.js +80 -13
- package/dist/core/index.js +2 -2
- package/dist/core/prompt-builder.js +23 -2
- package/dist/core/session-logger.js +46 -4
- package/dist/core/version.js +24 -0
- package/dist/i18n/en.json +75 -2
- package/dist/i18n/ru.json +74 -1
- package/dist/index.js +1 -1
- package/dist/llm/image-utils.js +4 -5
- package/dist/llm/index.js +4 -4
- package/dist/llm/model-loader.js +6 -6
- package/dist/llm/openai-compat.js +40 -34
- package/dist/llm/orchestrator.js +33 -29
- package/dist/llm/response.js +9 -9
- package/dist/logger/app-logger.js +1 -1
- package/dist/logger/index.js +1 -1
- package/dist/main.js +1111 -954
- package/dist/migration/backup.js +13 -13
- package/dist/migration/detect.js +11 -11
- package/dist/migration/index.js +2 -2
- package/dist/modules/artifacts/store.js +61 -0
- package/dist/modules/browser/actions.js +34 -4
- package/dist/modules/browser/bridge-client.js +199 -0
- package/dist/modules/browser/bridge-path.js +10 -0
- package/dist/modules/browser/bridge-server.mjs +202 -202
- package/dist/modules/browser/cookie-store.js +6 -6
- package/dist/modules/browser/driver.js +136 -0
- package/dist/modules/browser/index.js +7 -5
- package/dist/modules/browser/module.js +8 -7
- package/dist/modules/browser/session.js +87 -84
- package/dist/modules/browser/snapshot.js +92 -58
- package/dist/modules/browser/types.js +4 -1
- package/dist/modules/certification/cli.js +2 -4
- package/dist/modules/certification/fact-checker.js +1 -3
- package/dist/modules/certification/loader.js +3 -9
- package/dist/modules/certification/runner.js +1 -4
- package/dist/modules/context/chunk-query.js +100 -0
- package/dist/modules/context/fact-extractor.js +162 -0
- package/dist/modules/context/history.js +15 -0
- package/dist/modules/context/index.js +1 -1
- package/dist/modules/context/manager.js +160 -86
- package/dist/modules/execution/audit-runners.js +152 -0
- package/dist/modules/execution/auditor.js +177 -25
- package/dist/modules/execution/execution-plugin.js +272 -0
- package/dist/modules/execution/module.js +201 -544
- package/dist/modules/execution/moe-executor.js +25 -0
- package/dist/modules/execution/plan-store.js +1 -3
- package/dist/modules/execution/plan-tool.js +508 -0
- package/dist/modules/execution/plan-validator.js +10 -10
- package/dist/modules/execution/planner.js +6 -1
- package/dist/modules/execution/stuck-detector.js +173 -10
- package/dist/modules/execution/verifier.js +86 -42
- package/dist/modules/execution/windows-commands.js +41 -0
- package/dist/modules/hallucination/confidence.js +8 -1
- package/dist/modules/hallucination/detector.js +2 -5
- package/dist/modules/hallucination/factual.js +3 -64
- package/dist/modules/hallucination/index.js +1 -1
- package/dist/modules/hallucination/js-identifiers.js +190 -0
- package/dist/modules/hallucination/llm-judge.js +1 -3
- package/dist/modules/indexer/cache.js +9 -7
- package/dist/modules/indexer/index.js +3 -3
- package/dist/modules/indexer/module.js +95 -42
- package/dist/modules/indexer/project-profile.js +183 -0
- package/dist/modules/indexer/walker.js +17 -17
- package/dist/modules/lsp/check-tool.js +58 -0
- package/dist/modules/lsp/client.js +74 -31
- package/dist/modules/lsp/command.js +60 -0
- package/dist/modules/lsp/config.js +87 -33
- package/dist/modules/lsp/index.js +3 -3
- package/dist/modules/lsp/module.js +185 -21
- package/dist/modules/lsp/probe.js +76 -0
- package/dist/modules/lsp/project-root.js +32 -0
- package/dist/modules/lsp/startup-check.js +141 -0
- package/dist/modules/mcp/module.js +2 -6
- package/dist/modules/memory/index.js +1 -1
- package/dist/modules/memory/module.js +71 -23
- package/dist/modules/memory/search.js +11 -9
- package/dist/modules/memory/store.js +13 -13
- package/dist/modules/pipelines/engine.js +10 -10
- package/dist/modules/pipelines/index.js +3 -3
- package/dist/modules/pipelines/parser.js +17 -14
- package/dist/modules/pipelines/template.js +1 -1
- package/dist/modules/plugins/builtin/lint-on-write.js +21 -16
- package/dist/modules/plugins/builtin/notify.js +3 -2
- package/dist/modules/plugins/index.js +1 -1
- package/dist/modules/plugins/loader.js +59 -17
- package/dist/modules/plugins/manager.js +73 -17
- package/dist/modules/processes/detect.js +34 -0
- package/dist/modules/processes/index.js +1 -1
- package/dist/modules/processes/registry.js +135 -46
- package/dist/modules/registry.js +4 -2
- package/dist/modules/security/audit-notifier.js +39 -39
- package/dist/modules/security/command-validator.js +2 -8
- package/dist/modules/security/data-sanitizer.js +1 -9
- package/dist/modules/security/encryption.js +58 -56
- package/dist/modules/security/network-validator.js +1 -9
- package/dist/modules/security/path-validator.js +1 -3
- package/dist/modules/security/security-policies.js +3 -19
- package/dist/modules/security/session-encryption.js +1 -1
- package/dist/modules/security/session-isolation.js +8 -8
- package/dist/modules/session/index.js +3 -3
- package/dist/modules/session/module.js +5 -5
- package/dist/modules/session/store.js +3 -9
- package/dist/modules/skills/matcher.js +27 -0
- package/dist/modules/skills/module.js +1 -2
- package/dist/modules/updater/checker.js +70 -6
- package/dist/modules/updater/index.js +2 -1
- package/dist/modules/updater/module.js +116 -0
- package/dist/modules/user-profile/compressor.js +2 -2
- package/dist/modules/user-profile/index.js +1 -1
- package/dist/modules/user-profile/profile.js +9 -9
- package/dist/tools/attach-image.js +1 -1
- package/dist/tools/bash.js +178 -19
- package/dist/tools/browser.js +46 -29
- package/dist/tools/chunk-query.js +99 -0
- package/dist/tools/download-file.js +116 -0
- package/dist/tools/enable-tools.js +58 -0
- package/dist/tools/executor.js +4 -5
- package/dist/tools/file-info.js +13 -12
- package/dist/tools/filter-tools.js +9 -2
- package/dist/tools/glob-tool.js +11 -11
- package/dist/tools/grep-tool.js +1 -3
- package/dist/tools/hidden-tools-block.js +37 -0
- package/dist/tools/index.js +13 -2
- package/dist/tools/list-dir.js +18 -17
- package/dist/tools/load-skill.js +1 -3
- package/dist/tools/path-utils.js +4 -4
- package/dist/tools/pipeline-run.js +25 -25
- package/dist/tools/process-kill.js +11 -11
- package/dist/tools/process-list.js +20 -22
- package/dist/tools/process-log.js +22 -18
- package/dist/tools/question.js +1 -3
- package/dist/tools/read-file.js +10 -2
- package/dist/tools/recall.js +44 -37
- package/dist/tools/registry.js +15 -4
- package/dist/tools/remember.js +29 -29
- package/dist/tools/scope-check.js +9 -9
- package/dist/tools/subagent.js +54 -9
- package/dist/tools/user-input.js +1 -1
- package/dist/tools/web-browse.js +3 -3
- package/dist/tools/web-fetch.js +3 -3
- package/dist/tools/web-search.js +3 -3
- package/dist/tools/write-file.js +1 -3
- package/dist/ui/box.js +1 -5
- package/dist/ui/index.js +6 -6
- package/dist/ui/line-editor.js +703 -0
- package/dist/ui/line-math.js +69 -0
- package/dist/ui/md-formatter.js +33 -33
- package/dist/ui/output.js +5 -5
- package/dist/ui/plan-view.js +103 -0
- package/dist/ui/renderer.js +15 -10
- package/dist/ui/table.js +1 -1
- package/package.json +48 -48
package/dist/config/defaults.js
CHANGED
|
@@ -2,7 +2,7 @@ import { DEFAULT_SECURITY_CONFIG } from "./security";
|
|
|
2
2
|
import { DEFAULT_LSP_CONFIG } from "../modules/lsp/config";
|
|
3
3
|
export const DEFAULTS = {
|
|
4
4
|
version: "2.0.0",
|
|
5
|
-
model: "qwen3.5-9b",
|
|
5
|
+
model: "qwen/qwen3.5-9b",
|
|
6
6
|
provider: {
|
|
7
7
|
type: "openai-compat",
|
|
8
8
|
baseUrl: "http://localhost:1234/v1",
|
|
@@ -15,20 +15,28 @@ export const DEFAULTS = {
|
|
|
15
15
|
moe: {
|
|
16
16
|
enabled: false,
|
|
17
17
|
},
|
|
18
|
+
tools: {
|
|
19
|
+
defaultTags: ["file", "code"],
|
|
20
|
+
enableOnDemand: true,
|
|
21
|
+
},
|
|
18
22
|
experts: {
|
|
19
23
|
code: {
|
|
20
|
-
model: "qwen3.5-9b",
|
|
24
|
+
model: "qwen/qwen3.5-9b",
|
|
21
25
|
tool_tags: ["file", "code", "shell"],
|
|
22
26
|
max_attempts: 3,
|
|
23
27
|
},
|
|
24
|
-
research: {
|
|
28
|
+
research: {
|
|
29
|
+
model: "qwen/qwen3.5-9b",
|
|
30
|
+
tool_tags: ["research"],
|
|
31
|
+
max_attempts: 3,
|
|
32
|
+
},
|
|
25
33
|
browser: {
|
|
26
|
-
model: "qwen3.5-9b",
|
|
34
|
+
model: "qwen/qwen3.5-9b",
|
|
27
35
|
tool_tags: ["browser", "vision"],
|
|
28
36
|
max_attempts: 3,
|
|
29
37
|
},
|
|
30
38
|
vision: {
|
|
31
|
-
model: "qwen3.5-9b",
|
|
39
|
+
model: "qwen/qwen3.5-9b",
|
|
32
40
|
tool_tags: ["browser", "vision", "file"],
|
|
33
41
|
max_attempts: 2,
|
|
34
42
|
},
|
|
@@ -64,6 +72,9 @@ export const DEFAULTS = {
|
|
|
64
72
|
enabled: true,
|
|
65
73
|
headless: true,
|
|
66
74
|
maxElements: 30,
|
|
75
|
+
maxContentChars: 2500,
|
|
76
|
+
maxConsoleEntries: 40,
|
|
77
|
+
maxConsoleLineChars: 400,
|
|
67
78
|
viewportWidth: 1280,
|
|
68
79
|
viewportHeight: 720,
|
|
69
80
|
navigationTimeout: 15000,
|
|
@@ -96,5 +107,18 @@ export const DEFAULTS = {
|
|
|
96
107
|
skills: {
|
|
97
108
|
budget: 0.15,
|
|
98
109
|
},
|
|
110
|
+
subagent: {
|
|
111
|
+
resultMode: "text",
|
|
112
|
+
maxSummaryChars: 2000,
|
|
113
|
+
artifactsDir: ".mma/artifacts",
|
|
114
|
+
stableSystemPrompt: true,
|
|
115
|
+
maxParallelChunkQueries: 4,
|
|
116
|
+
},
|
|
99
117
|
lsp: DEFAULT_LSP_CONFIG,
|
|
118
|
+
updater: {
|
|
119
|
+
enabled: true,
|
|
120
|
+
checkOnStart: true,
|
|
121
|
+
autoInstall: true,
|
|
122
|
+
intervalMs: 0,
|
|
123
|
+
},
|
|
100
124
|
};
|
package/dist/config/experts.js
CHANGED
|
@@ -7,7 +7,7 @@ export function validateExpertConfig(config, allToolTags) {
|
|
|
7
7
|
for (const [name, expert] of Object.entries(config.experts || {})) {
|
|
8
8
|
for (const tag of expert.tool_tags) {
|
|
9
9
|
if (!knownTags.has(tag)) {
|
|
10
|
-
errors.push(`Expert "${name}" references unknown tool_tag "${tag}". Known tags: ${Array.from(knownTags).join(
|
|
10
|
+
errors.push(`Expert "${name}" references unknown tool_tag "${tag}". Known tags: ${Array.from(knownTags).join(", ")}`);
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
13
|
}
|
package/dist/config/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { DEFAULTS } from
|
|
2
|
-
export { loadConfig, saveConfig, validateConfig } from
|
|
3
|
-
export { getExpertConfig, validateExpertConfig } from
|
|
1
|
+
export { DEFAULTS } from "./defaults";
|
|
2
|
+
export { loadConfig, saveConfig, validateConfig } from "./config";
|
|
3
|
+
export { getExpertConfig, validateExpertConfig } from "./experts";
|
package/dist/config/security.js
CHANGED
|
@@ -147,12 +147,7 @@ export const DEFAULT_SECURITY_CONFIG = {
|
|
|
147
147
|
auditNotifier: {
|
|
148
148
|
enabled: false,
|
|
149
149
|
minSeverity: "medium",
|
|
150
|
-
eventTypes: [
|
|
151
|
-
"security_block",
|
|
152
|
-
"bash_command",
|
|
153
|
-
"file_operation",
|
|
154
|
-
"network_request",
|
|
155
|
-
],
|
|
150
|
+
eventTypes: ["security_block", "bash_command", "file_operation", "network_request"],
|
|
156
151
|
maxRetries: 3,
|
|
157
152
|
webhookTimeout: 5000,
|
|
158
153
|
},
|
|
@@ -176,10 +171,8 @@ export function mergeSecurityConfig(userConfig) {
|
|
|
176
171
|
...DEFAULT_SECURITY_CONFIG.network,
|
|
177
172
|
...userConfig?.network,
|
|
178
173
|
},
|
|
179
|
-
maxRecursionDepth: userConfig?.maxRecursionDepth ??
|
|
180
|
-
|
|
181
|
-
maxFileOperations: userConfig?.maxFileOperations ??
|
|
182
|
-
DEFAULT_SECURITY_CONFIG.maxFileOperations,
|
|
174
|
+
maxRecursionDepth: userConfig?.maxRecursionDepth ?? DEFAULT_SECURITY_CONFIG.maxRecursionDepth,
|
|
175
|
+
maxFileOperations: userConfig?.maxFileOperations ?? DEFAULT_SECURITY_CONFIG.maxFileOperations,
|
|
183
176
|
rateLimits: {
|
|
184
177
|
...DEFAULT_SECURITY_CONFIG.rateLimits,
|
|
185
178
|
...userConfig?.rateLimits,
|
package/dist/core/agent-moe.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { OrchestratorClient } from "../llm/orchestrator";
|
|
2
|
-
import { validatePlan, applyAutoFixes
|
|
2
|
+
import { validatePlan, applyAutoFixes } from "../modules/execution/plan-validator";
|
|
3
3
|
import { MoEExecutor } from "../modules/execution/moe-executor";
|
|
4
4
|
import { StepVerifier } from "../modules/execution/verifier";
|
|
5
5
|
/**
|
|
@@ -53,15 +53,7 @@ export async function runWithMoE(deps, input, fallback, opts = {}) {
|
|
|
53
53
|
const planResults = await executor.executePlan(plan);
|
|
54
54
|
onMeta?.(`✅ Execution complete: ${planResults.results.filter((r) => r.success).length}/${planResults.results.length} succeeded\n`);
|
|
55
55
|
const verifier = new StepVerifier(baseDir);
|
|
56
|
-
const knownTags = [
|
|
57
|
-
"file",
|
|
58
|
-
"code",
|
|
59
|
-
"shell",
|
|
60
|
-
"research",
|
|
61
|
-
"browser",
|
|
62
|
-
"vision",
|
|
63
|
-
"core",
|
|
64
|
-
];
|
|
56
|
+
const knownTags = ["file", "code", "shell", "research", "browser", "vision", "core"];
|
|
65
57
|
const verification = await verifier.verifyMoEManifest(plan, config, knownTags);
|
|
66
58
|
onPhase?.("thinking");
|
|
67
59
|
let verifyResult;
|