micro-models-agent 0.57.1 → 0.57.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.
Files changed (3) hide show
  1. package/CHANGELOG.md +37 -0
  2. package/dist/main.js +2351 -1640
  3. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -4,6 +4,43 @@ All notable changes to Micro Models Agent (MMA) will be documented in this file.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/), and this project adheres to [Semantic Versioning](https://semver.org/).
6
6
 
7
+ ## [0.57.2] - 2026-08-30
8
+
9
+ ### Changed
10
+ - **KV-cache**: plan block removed from system prompt; plan status now injected into `<system-summary>` envelope after every tool batch. System prompt is immutable per session — local backends retain prefix cache.
11
+ - **Provenance**: provider entry resolution uses active entry label, not bare `provider.type`
12
+ - **Reasoning signals**: `consecutiveToolSuccesses` and `isRepetitive` now feed real values to the reasoning policy (were hardcoded)
13
+ - **Token estimation**: tool-def token estimate in agent loop uses `estimateTokens()` instead of flat `/4`
14
+ - **Agent split**: `agent.ts` 1550→950 lines; 10 extracted modules (`loop-state`, `compaction`, `tool-batch`, `hallucination-gate`, `audit-gate`, `reasoning-resolver`, `token-tracker`, `context-renderer`, `tool-output`, `constants`)
15
+ - **Plan-tool**: `plan-tool.ts` 741→232 lines; per-action handlers in `plan-actions.ts`
16
+ - **CLI**: `createProgram` 513→thin orchestrator; `registerMmaCommands` 470→8 lines (5 per-domain registers)
17
+ - **Bash handler**: `bash.ts` 236→~100 lines (`resolveBashSecurityConfig`, `decorateCommandOutput`)
18
+ - **Orchestrator**: reuse `parseChunks` instead of hand-rolled `any[]` aggregation; `createPlan` uses own `parseJSON`; constructor deduplicated via `createProviderInstance`
19
+ - **Shared utils**: `src/utils/` with `errMsg()`, `sleep()`, `truncate()`, `backoffDelay()`
20
+ - **errMsg**: replaces 23 occurrences of `e instanceof Error ? e.message : String(e)` across 12 files
21
+
22
+ ### Fixed
23
+ - **chunk_query**: one failing chunk no longer kills the entire query; per-chunk `catch` → `[FAILED]`
24
+ - **chunk_query**: synthesis prompt capped at 20K chars with `[TRUNCATED]` marker
25
+ - **chunk_query**: `AbortSignal` propagated to `chatText` for cancellation support
26
+ - **Executor**: `failFast` cleanup guard prevents nested scope clobbering
27
+ - **probe.ts**: transient errors (network/auth) no longer cached as "reasoning not supported" for 24h; returns `null` → caller skips cache
28
+ - **LSP**: startup timeout unified on `DEFAULT_TIMEOUT` (15000) instead of conflicting hardcoded 10000
29
+ - **Browser**: `BridgeResponse.data` typed (was `any`)
30
+ - **Agent**: `Agent.runTool()` public API replaces `(ctx.agent as any).deps` reach-in; `/reload` no longer mutates readonly context
31
+ - **LSP /lsp check**: fixed latent bug where `.execute()` was called with `.executeByName` signature
32
+
33
+ ### Added
34
+ - **Plan Reminder**: static `[Plan Reminder]` block in system prompt (never mutates)
35
+ - **Documentation**: reentrancy warning on `executeByName()`, `PlanResult` JSDoc
36
+ - **Tests**: `probe.test.ts` (6 cases), `command-suggest.test.ts`, `providers-factory.test.ts`, `subagent-tool.test.ts`, `agent-moe-write.test.ts`, `chunk-query.test.ts`
37
+ - **probe.ts**: `null` return for transient errors; bootstrap skips cache on `null`
38
+ - **Execution-plugin**: `resetStepFlags`/`resetPlanState` helpers (dedup 3 inline reset blocks)
39
+ - **Security-policies**: `comparePolicies` typed (`keyof SecurityConfig` replaces `as any`)
40
+
41
+ ### Removed
42
+ - **Browser**: dead `buildWaitScript` export (never imported)
43
+
7
44
  ## [0.57.1] - 2026-08-28
8
45
 
9
46
  ### Fixed