Changelog
All notable changes to the @tty-pt/pi-mm package will be documented in this file.
[0.9.1] - 2026-12-03
Added
- Automated Software Docs Publishing (
.github/workflows/ci.yml): - Wired
docsjob callingtty-pt/ci/.github/workflows/docs.yml@mainto publish@tty-pt/pi-mmdocumentation on release tags (7d9811c).
Changed
- Fixed-Inode Kernel Advisory Locking (
src/lock.ts,src/daemon.ts,tests/concurrency.test.ts,tests/daemon_correctness.test.ts): - Replaced the legacy user-space
link()+ JSON +.mm.lock.recovery.lockstale-PID protocol with persistent fixed-inode OS advisory locks (flock(2)/LockFileEx, never unlinked) shared identically across Node (@tty-pt/steleN-APItryLockFile/unlockFile/isFileLocked), Deno (Deno.FsFile.tryLock(true)), Clibmm, andcormd, with aflock -x -nsubprocess fallback when native bindings are unavailable. - Pinned active native N-API lock handles in a module-level
Set(activeNativeHandles) to prevent V8 garbage collection from finalizing open lock descriptors while async callbacks are suspended. - Simplified
isDaemonLockHeld()insrc/daemon.tsto delegate directly toisOsFileLocked(), eliminating dead recovery code and ensuring instantSIGKILLrecovery with zero.mm.lock.tmp.*or.mm.lock.recovery.lockartifacts. - Dependencies (
package.json): - Bumped dependency floors to
@tty-pt/stele ^1.10.0,@tty-pt/corm ^2.5.3,@tty-pt/axil ^1.10.0, and@tty-pt/islet ^1.7.2. - Documentation (
README.md): - Clarified that
libmmis a proprietary/licensed native engine distributed separately while@tty-pt/pi-mmand the underlying Corm/axis libraries remain BSD-2-Clause open source (7d9811c), and added a minimal Pisettings.jsonquickstart (b9fcf4e).
[0.9.0] - 2026-12-02
Added
- Native
libmmDelegation (src/mm_native.ts,src/code/recall.ts,src/synth/adapter.ts): - Declared native
libmmN-API bindings forprojectCodeSearch/projectCodeSymbol/projectCodeTrace,distillPrompt/distillCommit,sessionIngestTurn/sessionRecall, andtraverse(87d353a,af6a8d2). - Delegated code symbol/trace recall and distillation synthesis to native
libmm(@tty-pt/mm ^1.1.1) with TypeScript fallback, while keeping lifecycle epistemic validation, traversal formatting, and session store consistency on the verified JS paths. - Bidirectional Code-Lore Links, Persistent Recall Filters & Interactive Ambiguity Resolution (
src/code/graph.ts,src/code/lore_binding.ts,src/code/manager.ts,src/code/recall.ts,src/tools/recall.ts,src/tools/record.ts,src/tools/store.ts,src/tools/ranking.ts): - Added bidirectional code-to-lore graph edges, persistent recall filtering options, and interactive ambiguity resolution across symbol lookups (
e06477f). - Worktree-Aware Coordination & Primary Root Resolution (
src/code/lore_binding.ts,src/code/stigmergy.ts,src/tools/index.ts): - Added
deriveWorkspaceLabel()andresolvePrimaryWorktreeRoot()recognizing.pi/scratch/slot-*,.worktrees/*,.pi/subagents/worktrees/*, and.gitgitdir:worktree pointers (203ab13). - Extended
resolveSharedCoordinationDir(), auto-populatedworkspaceLabelon swarm attention leases, resolved primary-worktree memory directories inresolveMemDir(), and increasedcormdstartup fast-ready wait from50msto2500ms(203ab13). - In-Process
@tty-pt/mm(libmm^1.0.0) Native N-API Integration (package.json,src/mm_native.ts,src/tools/ranking.ts,src/code/scanner.ts,src/hooks/auto_recall.ts,src/payload.ts,src/window.ts,src/versions.ts,src/index.ts,tests/mm_native.test.ts): - Added
@tty-pt/mm(^1.0.0) dependency andsrc/mm_native.ts(getMmAddon,isMmNativeAvailable) loadingmm.node/mm_node.nodein-process acrossprebuilds/<platform>-<arch>[-musl]and local worktrees (00b9901). - Accelerated Reciprocal Rank Fusion (
fuseRankingsRRF,adaptiveRrfK), 8-factor epistemic scoring (computeRankingScore), hygiene filters (isTechnicalInquiry,isCodeOrDocArtifact,isQuestionMemory,isAssistantEcho,isCleanSummaryText), temporal window calculation (levelWindow$\rightarrow$windowForLevel), prompt intent classification (classifyPromptIntent), and source symbol scanning (scanSourceSymbolsNative) via the native Clibmmkernel (00b9901). - Added
libmm >= 1.0.0(mm.pc/@tty-pt/mm) toREQUIRED_ENGINE_FEATURES,MIN_ENGINE_VERSIONS, and/mm doctorstatus output ([✓] Native libmm N-API Addon: Active in-process (@tty-pt/mm)) (00b9901).
Changed
- Canonical
.mmDirectory & Standardized Metadata (src/config.ts,src/tools/index.ts,package.json,README.md): - Canonicalized default
memDirto.mmwith automatic fallback to.pi/mmin both local and primary worktree roots (f9ec8ff). - Clarified native
libmmC delegation inREADME.md(7a8e0dd) and standardized package author (Paulo Quirino <quirinpa@gmail.com>) andBSD-2-Clauselicense metadata (acfd9da).
Fixed
- Runtime Drift Flood, HTOK UTF-8 Decoding,
-1Sentinel Handling & Out-of-Root Dossiers (src/code/dossier.ts,src/code/lore_binding.ts,src/corm.ts,src/daemon.ts,src/hooks/events.ts,src/hooks/hint_queue.ts,src/payload.ts,src/session/store.ts,src/tools/{lifecycle,recall,scan,think,traverse}.ts,tests/runtime_regressions.test.ts): - Failed closed in
verifyLoreBindingsForSymbols()whentargetSymbolsis empty, and routedtool_resultdossier/drift/guardrail hints through a bounded per-session queue (src/hooks/hint_queue.ts) drained inbefore_agent_startinstead ofdeliverAs: "nextTurn"messages that masked subsequent user prompts (8ec7788). - Failed closed in
decodeHtokPayload()on UTF-8 replacement characters (U+FFFD), preserved rawstdoutBytesacross daemonRECONCILEretries and session store runners, and lifted the 15-candidate rawGEThydration cap inexecuteHybridScan()(8ec7788). - Added canonical
isCormNotFound()handling forcormd"-1\n"not-found sentinels acrosstraverse,scan,lifecycle, andthink, withstanding_directives.jsonfallback inzoomInMemory()(8ec7788). - Enforced
projectRootcontainment and rejected bare filenames inderiveModuleKey(),synthesizeFirstTouchModuleDossier(), andtool_resulthooks, backed by regression coverage intests/runtime_regressions.test.ts(8ec7788). - HTOK Unpack Bounds & Daemon Lifecycle Cleanup (
src/payload.ts,src/daemon.ts,src/auren-bootstrap.ts,src/code/manager.ts,src/code/store.ts,src/corm.ts): - Added safety bounds check to the HTOK history unpack loop in
src/payload.ts(1747e11). - Tracked and cleaned up
cormddaemon lifecycles, prioritized localaurenlibraries (44f53f4), added-ddaemon flag to theaxil-aurenlauncher (02a5b70), and unregistered exit signal handlers when no daemons remain (87d353a). - Natural "Remember" Capture, Flashbulb Anchor Preservation & Directive Recall (
src/hooks/auto_recall.ts,src/hooks/events.ts,src/hooks/reinforcement.ts,src/synth/adapter.ts,src/tools/consolidate.ts,src/tools/record.ts,src/tools/store.ts,tests/natural_remember_and_directives.test.ts): - Captured natural conversational remember requests (
"remember ...","don't forget ...") as flashbulb anchors (isAnchor: true) and preserved anchor flags across L0 $\rightarrow$ L1/L2 consolidation and synthesis (3aa956e). - Improved standing directive recall and periodic reinforcement scheduling, filtered non-standing L2 invariants out of the global standing directives block in
buildInjectedContext, and deduplicatedAdditional factsagainst rendered session excerpts informatCompactMemoryEntry(3aa956e). - Advisory Lock Coordination,
sepalCLI Fallback & Classifier Timeout Hardening (src/lock.ts,src/daemon.ts,src/napi_runner.ts,src/judge/nearest.ts,tests/concurrency.test.ts,tests/no-live-network.ts,tests/validation_fixes.test.ts): - Guarded
Deno.FsFile.tryLockavailability insrc/lock.tsandsrc/daemon.tsand ran coordinator inspection/removal hooks cleanly when a Nodeflockhelper child exits on contention (00b9901). - Routed
sepal-indexed store commands inNativeAddonCormRunnerthrough the CLI fallback runner so vector embedding hooks execute consistently (00b9901). - Reduced initial exemplar batch embedding timeout in
src/judge/nearest.tsfrom12000msto2000msand canceled unread error response bodies (res.body?.cancel()) (00b9901).
[0.8.0] - 2026-11-15
Added
- Prebuilt
@tty-pt/axil&@tty-pt/aurenDaemon Discovery (package.json,src/auren-bootstrap.ts,tests/auren_bootstrap.test.ts): - Added
@tty-pt/axil(^1.8.1) and@tty-pt/auren(^1.5.1) topackage.jsondependencies alongside updated@tty-pt/{corm,sepal,lemma,islet}prebuild floors. - Added
findAxilBins()andfindAurenLibDirs()insrc/auren-bootstrap.tssofindAurenLaunchers()automatically discovers@tty-pt/axil/bin/axil.jsand prebuiltlibaxil-auren.{so,dylib}in@tty-pt/auren/prebuilds/<os>-<cpu>[-musl](as well as local repository checkouts), allowingpi-mmto launch and share a backgroundaxil-aurendaemon without requiring system-installed/usr/bin/axilor/usr/lib/libaxil-auren.so. - Live Epistemic Invalidation via Code-to-Lore Causal Binding (
src/code/lore_binding.ts,src/code/manager.ts,src/tools/record.ts,src/tools/store.ts): - Automatically binds
supportedandtestedarchitectural invariants, decisions, and episodes to AST symbol anchors (symbolName,qualifiedName,filePath,startLine,endLine,signature, and a deterministicfingerprintoverkind + qualifiedName + signature + sorted(rawCallees)), persisted atomically in.pi/mm/code/lore-bindings.json(shared across.pi/scratch/slot-*worktrees). - Verifies bound symbol anchors during
memory_recall(verifyLoreBindingsForSymbols), flagging invariants as[STALE_SUSPECT]when an anchored symbol's signature/callees change, when the symbol is deleted, or when an uncommittedgit diffhunk intersects its[startLine, endLine]span. - Isolates generic single-word entrypoints (
xy_install,bud_app_render,main,get,set) so lore only binds or surfaces when corroborated by module/file path or subsystem context (isAnchorCorroboratedByLore,isLoreRelevantToSymbol). - Execution-Trace & Differential Failure Topology Engine (
diagnoseinmemory_recall,src/code/diagnose.ts): - Added zero-regex stack trace and compiler diagnostic parser (
parseFailureTrace) supporting TypeScript/JavaScript (at fn (file:line:col)), C/C++/GDB (file.c:line:col: error:), and Python (File "path.py", line N, in fn) frames. - Maps stack frames to enclosing AST symbols via
libislet2D[fileHash, line..line]interval intersection and symbol resolution (diagnoseFailureTrace), then intersects the active stack call-cone withgit diffmodified symbols to compute the Causal Fault Intersection (modified_on_stack,modified_callee_of_stack,caller_of_modified_on_stack) ranked by hop distance. - Collective Swarm Stigmergy Across Parallel Sessions & Scratch Slots (
src/code/stigmergy.ts,src/hooks/events.ts,src/code/manager.ts): - Records live spatial attention leases (
SwarmAttentionLease, 15-minute TTL) in.pi/mm/code/swarm-leases.json(resolved across.pi/scratch/slot-Nworktrees viaresolveSharedCoordinationDir) whenever sessions inspect symbols or mutate files (edit/write). - Queries and formats active peer session overlaps (
exact_symbol,same_file,call_graph_neighbor) during symbol reads and searches so concurrent agents and subagents have real-time visibility into parallel work. - Pre-Tool Counterfactual Guardrails ("Déjà Vu" Interception) (
guardrailinmemory_recall,src/hooks/guardrails.ts,src/hooks/events.ts): - Added
evaluateCounterfactualGuardrailandmemory_recall({ guardrail: "<planned edit|command>", file?, symbol? })to pre-flight planned actions against contradicted memories (contradicted_memory), previously failed episode approaches (failed_approach), prohibitive standing directives instanding_directives.jsonandmem.db(standing_restriction), and drifted code-bound invariants (stale_bound_invariant). - Passively intercepts
edit,write, and failingbashtool results insrc/hooks/events.ts, steering the agent with deduplicated per-session[pi-mm Déjà Vu Counterfactual Guardrail]warnings before repeated mistakes compound. - First-Touch Module Dossiers, Cross-Boundary Pairing & XY Contract Flight Checks (
src/code/dossier.ts,src/code/recall.ts,src/code/graph.ts): - Synthesizes a once-per-session
[pi-mm First-Touch Module Dossier]when an agent first inspects or edits a module (mods/<M>,external/<L>,.pi/extensions/<E>,htdocs/), surfacing the architectural boundary contract, exact Tier-0 verification command (inferTier0VerificationGate), key routes/entrypoints, fresh vs. drifted bound invariants, and active swarm leases. - Automatically pairs
XY_DECLheader declarations withXY_IMPLimplementations and Server-Side C entrypoints (xy_install, routes) with Isomorphic UX WASM entrypoints (bud_app_render,STL_WASM_MODULE) during symbol inspection (resolveCrossBoundaryPairs). - Detects
XY_DECL$\leftrightarrow$XY_IMPLcontract mismatches (missing_impl,missing_decl,signature_mismatch) inmemory_recall({ diff: true })(detectXyContractMismatches). - Verification-Attested Epistemic Promotion Ledger & Tier-0 Diff Gate Status (
src/hooks/verification_ledger.ts,src/tools/record.ts): - Tracks failing verification commands (
make test*,deno test,npm test,check-*.sh,check-complexity.ts, etc.), subsequent file mutations, andFAIL -> PASStransitions per session (observeBashVerificationOutcome). - Automatically synthesizes an attested L2 causal fix episode (
tags: ["attested-fix", "fail-to-pass"]) when mutated files transition a failing test/build command to exit code 0, and upgradesmemory_recordepisodes tolifecycle: "supported"whenverification.testsPassedis corroborated by the session's passing verification ledger (hasAttestedPassingVerification). - Appends a
[Tier-0 Module Verification Gate Status]report ([VERIFIED ✓ after last edit],[UNVERIFIED ⚠️ — modified after last passing test], or[UNVERIFIED ⚠️]) tomemory_recall({ diff: true })acrossmods/*,external/*,.pi/extensions/*, andhtdocs/*(evaluateModuleVerificationStatus). - Higher-Order Call-Graph Stitching Across Callbacks, Designated Initializers &
xy_load(src/code/scanner.ts,src/code/store.ts): - Extracts function-pointer arguments passed to higher-order calls (
tryCaptureHigherOrderCallbackArgs), struct designated-initializer callbacks (.detail = song_detail_handler,tryCaptureDesignatedInitCallback), andxy_load("./mods/<M>/<M>")module-to-xy_installedges (MANIFEST_VERSION = 6). - Resolves outbound and inbound call-graph edges across route registrations (
GET /path$\rightarrow$ handler), higher-order wrappers (with_module_item_access$\rightarrow$ callback), and cross-modulexy_loadboundaries while excluding non-callable#definemacro constants. - Working-Memory Context-Window Staleness Radar (
src/code/context_sync.ts,src/code/manager.ts,src/hooks/events.ts): - Snapshots per-session file
mtimeMs, byte size, and AST symbol spans/fingerprints whenever files or symbols are inspected (read,memory_recall) or mutated (edit,write). - Detects external disk modifications to previously inspected files before subsequent tool calls, auto-refreshing
CodeStoreand prepending a surgical[pi-mm Working-Memory Sync: External Disk Modifications Detected]delta notice (modified,lines_shifted,added,removed). - Evidence DAG Truth Maintenance Cascade (
src/tools/lifecycle.ts): - When
memory_review/memory_lifecycletransitions a memory tocontradictedorsuperseded, automatically syncslore-bindings.json, unregisters invalidated standing directives fromreinforcementSchedulerandstanding_directives.json, and cascades down the evidence DAG (propagateTruthMaintenanceCascade) to auto-downgrade dependentsupported/testedconclusions tohypothesizedwith full audit history.
Fixed
- Re-Entrant Lock Safety, Quiet Axis Probing & Mid-Session
axil-aurenBring-Up (src/lock.ts,src/runner.ts,src/napi_runner.ts,src/cli_runner.ts,src/auren-bootstrap.ts,src/hooks/events.ts,src/tools/store.ts,src/versions.ts): - Made
withLockre-entrant within the same process (activeLockDepthcounter insrc/lock.ts), eliminating self-deadlock timeouts when nested memory operations acquire.mm.lock. - Set
CORM_QUIET=1acrossNativeAddonCormRunnerandCliCormRunnerinvocations to suppress noisy axis stderr diagnostics during cold-start store initialization, and preferredcormdwhen a daemon lease is active. - Added
-dwhen spawningaxilwithdetached: trueinsrc/auren-bootstrap.tssoaxilstays in the foreground of the detached session and keeps port:4242bound, and addedensureAurenPoweredUp()on turn/store paths so records embed immediately ifaxil-aurenstarts mid-session. - Cached git component version lookups and resolved standalone
node_modules/@tty-pt/*prebuild versions insrc/versions.ts. - Scanner & Graph Precision Hardening (
src/code/scanner.ts,src/code/store.ts,src/code/graph.ts,src/code/payload_codec.ts): - Fixed C
#definemacro scanning (tryParseRouteOrMacro) so parenthesized object-like macros immediately preceding multi-line C functions advance past the macro identifier token and never swallow the following function definition. - Fixed TypeScript/JavaScript parameter and return-type skipping (
skipBalancedParens,findBodyOpenBrace) to handle inline object type annotations (params: { a: number },Promise<{ ok: boolean }>) without mistaking type-literal braces for function bodies. - Excluded vendor/third-party git submodules from default codebase scans unless explicitly queried, and filtered built-in JS/TS/Python method names (
get,set,map,filter,push,slice, etc.) from bare global call-graph linking. - Coalesced rapid
before_agent_startturns within a 1500 ms window so consecutive agent turns do not trigger redundantCodeStorerefreshes.
[0.7.1] - 2026-11-14
Added
- Standalone Zero-System-Library npm Installation (
package.json,src/config.ts,src/auren-bootstrap.ts,src/napi_runner.ts,src/versions.ts): - Added
@tty-pt/{stele,corm,joint,lemma,sepal,islet}dependencies topackage.jsonsonpm install @tty-pt/pi-mmpulls prebuilt native addons and axis shared libraries automatically. - Updated
resolveAxisPath(),findSepalLib(),detectComponentVersion(), andNativeAddonCormRunnerto resolvenode_modules/@tty-pt/<pkg>/prebuilds/<os>-<cpu>[-musl](including hoistednode_modules) and loadcorm_node.nodewithRTLD_GLOBALwithout requiring/usr/libC libraries orexternal/checkouts. - Added end-to-end standalone verification (
tests/npm_standalone_install.test.ts).
[0.7.0] - 2026-11-14
Added
- In-Process Node-API Corm Runner (
NativeAddonCormRunner) & Engine Version Floor Audit (src/napi_runner.ts,src/versions.ts): - Added
NativeAddonCormRunnerexecutingPUT,PUT_JSON,GET,GET_JSON,LIST,DEL,DEL_ALL, andQUERYin-process via@tty-pt/cormwhen nocormdUDS socket is active, while respecting.cormd.lockleases and.mm.lockcross-process serialization. - Audited and locked
MIN_ENGINE_VERSIONS(libcorm >= 2.2.0,libsepal >= 1.2.0,liblemma >= 1.1.0,libjoint >= 1.5.0,libislet >= 1.2.0,axil >= 1.6.0,axil-auren >= 1.4.0) againstREQUIRED_ENGINE_FEATURES. - Unified Status Bar (
mm-judge) (src/hooks/events.ts,src/code/manager.ts): - Unified model readiness (
⚡ bge-base), busy hourglass indicator (⏳), and transient recall/store/consolidation activity badges into a singlemm-judgestatus bar slot. - Multi-Axis Codebase Mipmap Graph & Lore Fusion (
scope: "code", replacingpi-cbm) (src/code/lexer.ts,src/code/scanner.ts,src/code/store.ts,src/code/graph.ts,src/code/recall.ts,src/code/manager.ts): - Added zero-regex character-stream lexer and structural scanner (
scanSourceFile) for C/C++, TypeScript/JavaScript, and Python, extractingFunction,Method,Class,Struct,Interface,Enum,Macro,TypeAlias, andRoutesymbols, doc comments,#include/import/xy_loaddependencies, andrawCalleeswhile ignoring comments and string literals. - Added library-agnostic structural HTTP route detection based purely on call-argument shape: method calls (
obj.<http_method>("/path"[, handler])), two-string registrations (fn("<http_method>", "/path"[, handler])), and method-prefixed route strings (fn("<HTTP_METHOD>:/path"[, handler])/fn("<HTTP_METHOD> /path"[, handler])). - Added
CodeStorebacked bylibcorm(joint,lemma,sepal) andlibislet(code-islet.db2D[fileHash, startLine..endLine]interval index) with incrementalmtimedelta indexing, priority root scanning (mods/,src/,include/,lib/,app/,bin/beforeexternal/,vendor/,tests/), git submodule change filtering, and single-flightrefreshLockserialization. - Added call-graph disambiguation (
CodeGraph): filters C/POSIX stdlib routines (malloc,free,memcpy, etc.) and C struct pointer member calls (ops->load()) fromrawCallees, isolates call edges by language family and module/import affinity, and prioritizesXY_IMPLdefinitions overXY_DECLforward declarations (isDeclaration: true). - Integrated 5 codebase workflows into
memory_recall: hybrid symbol search with unambiguous auto-preview (scope: "code", query), fail-closed concrete symbol / batch source read (symbol/symbols,neighbors,lineRange) with automatic fusion of linkedpi-mminvariants and past debugging episodes (queryLinkedLoreForSymbols), multi-hop call graph trace (trace,direction,depth), L3/L2 architecture overview (scope: "code", overview: true), andlibislet-backed worktreegit diffblast-radius analysis (diff: true). - Ephemeral Semantic Session Memory, Progressive 3-Tier Recall & Mipmap Compaction (
scope: "session", replacingpi-vcc) (src/session/store.ts,src/session/sink.ts,src/session/lineage.ts,src/session/recall.ts,src/session/compaction.ts,src/session/manager.ts): - Added asymmetric session ingestion (
SessionSink&SessionStore) indexing settled conversational turns into per-sessionlibcormstores at 3 granularities (turnL1,blockL1,symbolL0) alongside raw turn payloads (turns/turn-<N>.json). - Serialized all
SessionStorewrite and index rebuild operations viawithWriteLockto eliminate concurrentcormCLI races. - Added
LineageTrackerDAG ancestry resolution (lineage: "active" | "all") with automatic linear ancestry reconstruction for persisted turns across mid-session reloads. - Added progressive 3-tier session retrieval (
executeSessionRecall): Tier 1 Index Cards, Tier 2 Focused Excerpts, and Tier 3 Exact Line Slices (zoomTurn,toolIndex,lineRange), fusing C multi-axis recall with exact symbol matching and unifiedscope: "all"RRF merging. - Added mipmap-driven context compaction (
buildMipmapCompactiononsession_before_compact), replacing destructive transcript truncation with structured L2/L1 session mipmaps andmemory_recall({ scope: "session", zoomTurn })pointers. - Added explicit session provenance boundaries (
[Current Session],[Parallel Session <id> (<slot>)],[Past Session <id>]), multi-session selector routing (session: "current" | "parallel" | "all" | "<uuid-prefix>" | "<slot-label>"), and post-compaction continuity hints (src/hooks/auto_recall.ts,src/session/compaction.ts,src/session/recall.ts,src/tools/recall.ts).
Fixed & Improved
- L0 Consolidation Queue Unwedging & Idle Backlog Drain (
src/tools/consolidate.ts,src/config.ts,tests/consolidation_backlog.test.ts): - Solved queue stalls where missing, non-L0, superseded, or terminally inactive references blocked the head of the consolidation queue (
disposedL0Refs). - Added
orderPendingL0Refs: ensures fresh turns captured in the current turn are processed first (so live work reaches L1 immediately), with remaining backlog ordered newest-first. - Added bounded idle queue draining (
drainL0Backlog) bounded byconsolidateDrainMs(default 250ms, envPI_MM_CONSOLIDATE_DRAIN_MS), incrementally draining backlogged L0 records without blocking interactive turns. - Zero-Config Local Synthesis Auto-Wiring (
src/config.ts,src/tools/pipeline_status.ts,tests/synth_pipeline_status.test.ts): - Automatically derives the OpenAI-compatible chat completions URL (
defaultLocalSynthUrl) on the localaxil-aurenserver whenever the judge/embedding endpoint is active, defaulting tosmollm(DEFAULT_LOCAL_SYNTH_MODEL). - Prevents L2/L3 abstraction synthesis from silently stalling when users configure a local judge without explicitly configuring synthesis. Opt out cleanly with
synthUrl: "off". - Enriched L0 Tool Capture & Self-Introspection Noise Filtering (
src/hooks/events.ts,tests/capture_signal.test.ts): - Added
formatToolEventSummaryto capture meaningful command names, touched paths, and concise first-line outputs for edit, write, read, and bash executions. - Filtered internal
pi-mmandcorminspection commands to prevent memory introspections from generating self-referential capture records. - Added same-session event deduplication to drop identical repetitive summaries on the same path.
- Byte-Exact Payload Decoding (
src/payload.ts,tests/decode_result.test.ts): - Added
decodeResulthelper preferring rawUint8Array(stdoutBytes) over lossy string decodes, preventing corrupted binary HTOK payload deserialization. - Targeted Recall L0 Inclusion & Episode Exemption (
src/tools/ranking.ts,src/tools/recall.ts,src/tools/scan.ts): - Added
includeL0to hybrid scan and recall, enabling explicit retrieval of L0 task memories while ranking synthesized L1/L2 records above raw tool noise. - Updated
isCodeOrDocArtifactto strictly exempt structured episodes (envelope.type === "episode"orenvelope.episode) from code artifact pruning. - Consolidation Pipeline Observability in
/mm doctor(src/tools/pipeline_status.ts,src/index.ts): - Added
describeConsolidationPipelineto/mm doctor, providing live visibility into L2/L3 synthesis status, pending L0 and dirty L1 queue depths, drain rate, and backlog or stale L2 alerts. - Retrieval-Quality Benchmark Gate (
scripts/eval-retrieval.ts,tests/retrieval_quality.test.ts): - Added automated retrieval evaluation asserting recall@5 = 1.0, MRR $\ge$ 0.5, and proper prioritization of synthesized abstractions over raw tool noise across golden benchmark queries.
[0.6.0] - 2026-11-01
Added
- Dual-End Assistant Discovery Distillation (
src/hooks/events.ts,tests/conversational_memory.test.ts): - In
onRunSettled, when a turn completes with tool execution (file edits or test verifications) and the assistant response contains substantive technical explanations (>= 40 characters), automatically distills the discovery into an L1 Task Episode (level: "L1",type: "episode",lifecycle: "tested"|"supported"). - Captures engineering breakthroughs and bug fixes even when the user's initial prompt was a task command that the classifier marked
skip. - Links raw tool executions (L0) as cited evidence references (
evidence: [l0Refs]). - Conversational Negative Constraints & Mistake Corrections (Zero Slash Commands, Zero Regex Heuristics) (
src/judge/directive-exemplars.ts,src/judge/capture-exemplars.ts,tests/directive_intent.test.ts): - Expanded bilingual
DIRECTIVE_EXEMPLARS.standing_directivewith natural developer corrections, negative constraints, and anti-patterns ("don't use raw pointers in request handlers", "never mock the filesystem in tests", "stop modifying the lockfile without running make", "you made a mistake, that function requires three arguments, never call it with two", "avoid global mutable variables in C modules", "não use variáveis globais em módulos C"). - Expanded
CAPTURE_EXEMPLARS.rememberwith negative operational rules so conversational feedback is not classified as disposable task noise. - Automatically elevates confirmed negative constraints to L2 invariants (
level: "L2",type: "invariant",standing: true) without requiring manual/mm ruleinvocations. - Continuous Standing Directives Prompt Retention Across All Turns (
src/hooks/events.ts,src/hooks/reinforcement.ts,tests/context_reinforcement.test.ts): - Fixed a critical system prompt diffing issue where Pi's
diffSystemPromptSectionsstrippedstanding_directiveson Turn 2 because milestone triggers only fired on Turn 1. before_agent_startnow continuously populatesevent.systemPromptOptions.sections["standing_directives"] = blockon every turn whenever active directives exist.- In
synthesizeReinforcementBlockFromDirectives, directives are sorted newest-first (directives.slice().reverse()) so recently learned corrections take priority within the token budget. - Updated
session_startto treat.pi/mm/standing_directives.jsonon disk as authoritative rather than overwriting curated directives with uncurated historical tasks frommem.db. - Scalable 100GB Storage Controls & Automatic Semantic Deduplication (
src/config.ts,src/tools/store.ts,src/hooks/auto_recall.ts,tests/config.test.ts): - Added
maxStorageBytes(default: 100GB = 107374182400 bytes, envPI_MM_MAX_STORAGE_BYTES) for large-scale memory indexing. - Added
l0RetentionPolicy("keep_all"for full 100GB raw tool logs and diff history vs"prune_after_consolidation", envPI_MM_L0_RETENTION_POLICY). - Added
autoRecallBudgetChars(default: 1500 chars, envPI_MM_AUTO_RECALL_BUDGET) to dynamically configure prompt context budget. - Added
semanticDeduplication(default: true, envPI_MM_SEMANTIC_DEDUPLICATION) inexecuteStore: when storing an invariant or decision, automatically supersedes older records in the same scope if cosine similarity >= 0.88, preventing duplicate memory accumulation in large databases. - High-Frequency Capture Threshold Calibration (
src/config.ts,src/judge/capture-exemplars.ts,tests/capture_modes.test.ts): - Calibrated
DEFAULT_CAPTURE_MIN_MARGINfrom0.075down to0.025andDEFAULT_CAPTURE_MIN_SIMILARITYto0.55. - Expanded
CAPTURE_EXEMPLARS.rememberwith technical root causes, compiler requirements, and architectural decisions (buffer overflows, race condition fixes, static memory allocation, module boundary invariants). - Auto-Recall Generalization & Query Action Default (
src/config.ts,src/hooks/auto_recall.ts,tests/auto_recall.test.ts): - Changed
DEFAULT_RECALL_ACTIONto"query"(previously"hint"), so recall inquiries automatically execute hybrid search and inject the matching memories directly intosystemPromptOptions.sections["memory_context"]rather than returning an empty hint. - Lifted the hardcoded 12 audio-subsystem whitelist gate in
buildInjectedContext: dynamically matches any candidate subsystem that appears in the prompt or candidates, enabling recall across all projects and repositories. - Failed Quest Setback Distillation (
src/hooks/events.ts,tests/quest_symbiosis.test.ts): - Updated
distillQuestArchiveEventto distill failed quests with setbacks into memory withapproach: "failed",outcome: "failure", andlifecycle: "observed", preserving lessons learned from past quest setbacks. - L2 Invariant Elevation in
memory_recordandstore(src/tools/record.ts,src/tools/store.ts,tests/workflow_tools.test.ts): - When storing standing directives (
standing: true),executeRecordandexecuteStorenow store atlevel: "L2",type: "invariant", and automatically register withreinforcementScheduler, saving tostanding_directives.jsonon disk instead of routing to the unpromoted L0 raw note tier.
[0.5.2] - 2026-10-31
Added
- Decoupled
quest_archiveDistillation (src/hooks/events.ts,tests/quest_symbiosis.test.ts): - Added asynchronous, non-blocking listener for completed quest archives emitted by
pi-quest. - Automatically distills completed quest findings, verified diffs, and execution metrics into structured memory records (
outcome,approaches,findings,diffs,verification) without blocking or stalling the agent turn. cormdJSON Protocol Support (src/corm.ts,src/daemon.ts,tests/daemon.test.ts):- Added native structured JSON request/response protocol support to the
cormddaemon runner for high-throughput memory storage, querying, and retrieval. - Standing Directive Reinforcement Sync to Disk & Global Cache (
src/hooks/events.ts,src/hooks/reinforcement.ts): - Automatically synchronizes active standing directives and operational invariants across the in-memory cache and persistent disk storage (
var/standing_directives.json). - Exposes registered repository invariants globally for immediate cross-session retrieval and cross-extension consumer integration (such as
pi-questdraft seeding).
Removed
- Complete Elimination of Heuristics:
- Removed
"heuristic"fromJudgeMode,JudgeFallback, andJudgeDecisionSource. - Zero heuristic guessing: memory capture and semantic routing evaluate strictly via embeddings on
/v1/systemoneor explicit commands (@remember,remember:,note:). - When offline or unavailable, fallback safely defaults to
"skip", never guessing.
[0.5.1] - 2026-10-30
Added
- Unified
POST /v1/systemoneProtocol & Out-Of-The-Box Zero-Config Defaults (src/judge/nearest.ts,src/config.ts): - Updated nearest-exemplar classification to target the unified
POST /v1/systemoneendpoint inaxil-auren, parsing{ decision, choice, similarity, confidence, margin }. - In absence of explicit settings in
settings.json, automatically defaultsjudgeUrlandcaptureEmbedUrltohttp://127.0.0.1:4242,captureModeto"judge",embedUrltohttp://127.0.0.1:4242/v1/embeddings, andembedModelto"bge-base". - Automatically enables
libsepalvector semantic search out of the box without requiring manualsettings.jsonconfiguration. - Unified Model Status Slot & Disconnected Power-Off State (
src/auren-bootstrap.ts,src/hooks/events.ts): - Standardized local model status widget on shared slot ID
"auren-model"withAUREN_STATUS_SLOT. - Added
"🔌 off"state indescribeModelStatuswhen the daemon is offline or disconnected, replacing invisible cleared slots with explicit power-off feedback. - Daemon Circuit Breaker & Resilient Timeout Wrapper (
src/judge/circuit.ts,src/judge/embed.ts,src/judge/nearest.ts): - Added shared circuit breaker wrapper
withCircuitBreakerprotecting allaxil-aurencalls against connection refusal, hung sockets, and daemon downtime. - Implemented fast-fail backoff (
CIRCUIT_BACKOFF_MS = 30_000) and tight default timeout (DEFAULT_CLASSIFY_TIMEOUT_MS = 250). - When
axil-aurenis offline or times out, the circuit breaker opens daemon-wide; subsequent calls fail fast immediately (~1 µs, 0 ms overhead) without touching the network or socket layer, preventing Pi event loop hangs. - Added unit test suite in
tests/circuit_breaker.test.tsverifying connection refusal, timeout abort, and manual/success circuit reset. - Assistant Cognitive Wondering Detection & Epistemic Steering (
src/hooks/events.ts,src/hooks/wondering.ts,src/judge/wondering-exemplars.ts): - Hooked
pi.on("message_end")to observe assistant turns, extracting text and thinking blocks (part.thinkingandpart.text). - Added
evaluateAssistantWondering(text, cfg)using in-memory vector embeddings onaxil-auren(POST /v1/classify,bge-base) against bilingual exemplars (WONDERING_EXEMPLARS:wonderingvsroutine_action). - When the agent expresses uncertainty, architectural curiosity, or wonders how a subsystem works mid-task, the system steers the agent via
pi.sendMessage({ customType: "memory_hint", content: hint }, { deliverAs: "steer" }). - Zero database queries are executed; the agent is steered to query
memory_recallvia inference. - Per-turn deduplication prevents duplicate steering hints.
- Added empirical evaluation harness (
scripts/eval-wondering.ts) measuring 100.0% accuracy, 100.0% wondering recall, and 0.0% false positives (p50: 17.9 ms). - Unified Hint-Only Recall Architecture & Epistemic Nudges (
src/hooks/auto_recall.ts,src/config.ts,src/judge/recall-exemplars.ts): - Added
recallAction?: "hint" | "query"setting toMmConfig(with environment variable overridePI_MM_RECALL_ACTION, defaulting to"hint"in runtime configuration). - When
isRecallIntentis confirmed true (via vector embeddings onaxil-aurenPOST /v1/classify) in hint mode,auto_recallexecutes zero automated database scans (runScanWithTimeoutandprimeSubsystemInvariantsare bypassed completely). - Injects a quiet epistemic hint into
event.systemPromptOptions.sections["memory_context"]advising the agent to formulate queries via LLM inference and retrieve records usingmemory_recall. - Sets
display: falseon the returned custom message, completely eliminating noisy, unprompted UI cards in the user's chat interface. - Expanded
RECALL_EXEMPLARS.recall_pastwith architectural wonderings and exploratory questions ("How does the caching layer work in this project?", "How does FTS handle accent folding here?"), ensuring cognitive curiosity is detected and guided without speculative database scans. - Preserved
recallAction: "query"for legacy auto-injected background recall compatibility.
Fixed
- Elimination of Regex Query Stripping in Favor of Stopword Set Filtering (
src/hooks/auto_recall.ts,src/tools/scan.ts): - Added conversational stop words to
STOP_WORDSinsrc/tools/scan.ts, enabling $O(1)$ set lookup to naturally filter conversational framing tokens without brittle regular expressions. - Recall intent is detected cleanly via in-memory vector cosine similarity (
POST /v1/classify,bge-base), and query formulation is delegated to the agent's LLM inference viamemory_recall. - Unconditional Question-Memory Exclusion in Injected Context (
src/hooks/auto_recall.ts): - Enforced
isQuestionMemorystrictly across all modes, ensuring conversational meta-questions ("In general, what do you remember?", "What was my request?") are never injected as factual background context. - Silent Non-Intrusive Guidance on Empty Matches (
src/hooks/auto_recall.ts): - When recall intent is detected but no high-confidence memory records match, the notice sets
display: false, keeping the user's chat clean without displaying empty or spurious memory cards. - Pi freeze on daemon unavailability: Eliminated sequential 2000ms+ classification delays in
classifyViaEndpointwhenaxil-aurenis uncommunicative or stopped, ensuring zero turn stalls when local AI daemon is offline.
[0.5.0] - 2026-10-29
Added
- Embedding classification of standing directives and operational invariants (
directiveEmbed: "auto"). In conversational turn capture and reinforcement scheduling, user statements are evaluated against bilingual exemplars (standing_directivevstransient_task) viaPOST /v1/classify. When confirmed, the statement is classified as an invariant (level: "L2",isAnchor: true) and registered in the reinforcement scheduler, eliminating the fragile English-only regex. Options:directiveEmbed,directiveMinSimilarity,directiveMinMargin,directiveExemplars,directiveFallback. - Embedding classification of open-ended memory overview questions (
overviewEmbed: "auto"). Distinguishes open-ended retrospective inquiries (overview_query) from targeted topic searches (specific_query), correctly injecting structured all-time timeline mipmaps (buildMemoryOverview) and eliminating empty lexical keyword scans on synthesis questions. Options:overviewEmbed,overviewMinSimilarity,overviewMinMargin,overviewExemplars,overviewFallback. - Embedding classification of recall intent (
recallEmbed: "auto"). Inbefore_agent_start, evaluates user prompts using nearest-exemplar embeddings viaaxil-auren'sPOST /v1/classify(shipped bilingual EN/PT exemplars insrc/judge/recall-exemplars.ts) to detect whether the user is querying past technical decisions, investigations, preferences, or lore (recall_pastvsstandalone). When recall intent is confirmed:
- Lifts unprompted context filtering in
auto_recall.ts, allowing hybrid scan and vector search to retrieve relevant memories even without hardcoded subsystem mentions. - Nudges the agent with actionable tool guidance in
systemPromptOptions.sections["memory_context"], instructing the model to consultmemory_recall(andzoomRefif specific memories are retrieved) before guessing or invoking unrelated bash/grep tools. - Seamless fallback to deterministic regex heuristics (
isMemoryRecallPrompt) when the classifier server is offline or unconfigured.
New configuration options: recallEmbed ("auto" | "off"), recallMinSimilarity (0.60), recallMinMargin (0.08), recallExemplars, recallFallback ("regex" | "skip"), and environment variable overrides PI_MM_RECALL_EMBED, PI_MM_RECALL_MIN_MARGIN, PI_MM_RECALL_MIN_SIMILARITY, PI_MM_RECALL_FALLBACK.
- Empirical recall intent evaluation harness and script (
scripts/eval-recall.ts,npm run eval:recall). Measures head-to-head performance of the new embedding classifier against the previous heuristic gate over a held-out, bilingual corpus of 44 turns: - Accuracy: 81.8% (36/44) vs 56.8% (25/44) (+25.0% accuracy gain).
- Recall Catch Rate: 63.6% (14/22) vs 13.6% (3/22) (4.7× improvement).
- Task Specificity: 100.0% (22/22) vs 100.0% (22/22) with 0 false positives.
- Latency: 17 ms p50, 34 ms p95.
- Embedding-Only Model Provisioning & Redundancy Prevention (
src/auren-bootstrap.ts): - In
shouldAutoDownload, restricted automatic model downloads strictly to models declaring embedding capabilities (capabilities: ["embed"]), eliminating downloads of heavy, unused inference/chat/judge models (qwen,olmoe). - In
run, verified if any embedding model is already present on disk (~/.models/); if present, auto-download is skipped entirely. If absent, only the primary preferred embedding model (bge-base, 117 MB) is downloaded. - Non-Blocking Visual Feedback on Downloads & Model Usage (
src/auren-bootstrap.ts,src/hooks/events.ts): - Enriched
describeProgressto report model identifier and progress percentage (⬇ bge-base (42%)). - Added
describeModelStatusreporting download progress during fetching, active model status (⚡ bge-base) when running on port 4242, or clearing when idle. - Wired into reserved status bar key
"mm-judge"with deduplicated, single-shot informational toasts on download start and completion. - Multi-surface evaluation harness and script (
scripts/eval-surfaces.ts,npm run eval:surfaces). Evaluates classification accuracy, false positives, and latency across standing directives (directive_intent), overview queries (overview_routing), and quest kinds (kind_classification): - Benchmarks embedding classification against baseline regex/heuristics on held-out bilingual test sets.
- Confirms zero state-changing regressions on invariant tracking and memory overview injection.
- Comprehensive unit and integration test suite in
tests/recall_intent.test.tscovering bilingual exemplars, mock/v1/classifyendpoints, threshold gating, offline fallback, and end-to-endhandleBeforeAgentStartcontext injection and agent nudging. - Embedding classification of conversational turns (
captureMode: "judge").evaluateTurnWithJudgefirst classifies the user's prompt by nearest-exemplar embeddings (shipped examples insrc/judge/capture-exemplars.ts, extended by form after the first held-out run), then falls back to the judge, then tojudgeFallback. Works with embeddings alone (nojudgeUrlneeded). New self-contained modulessrc/judge/embed.tsandsrc/judge/nearest.ts(pi-mm never imports pi-quest). Settings:captureEmbed(auto|off),captureEmbedUrl,captureEmbedModel,captureMinSimilarity(0.6),captureMinMargin(0.075),captureExemplars(remember/skip, any language); envPI_MM_CAPTURE_EMBED,PI_MM_CAPTURE_EMBED_URL,PI_MM_CAPTURE_EMBED_MODEL,PI_MM_CAPTURE_MIN_MARGIN,PI_MM_CAPTURE_MIN_SIMILARITY.JudgeDecisionSourcegains"embed". Measured (44 EN/PT turns,bge-basevsolmoe, held-out corpus B): embeddings 26/44 (59%) with 0 false "remember"; the judge 24/44 (55%) with 20 false "remember" (it answers "remember" to 40 of 44 non-memories on the two corpora combined). The trade is recall: embeddings recognise 4/22 real memories on B (7/22 on the development corpus A), judge 22/22, so fewer turns are stored automatically; explicit@rememberis unchanged. The first held-out run (corpus A, default exemplars) failed the adoption rule with 3 false "remember" and no margin fixed it, so the exemplars were extended by form and the hypothesis (default margin, new exemplars, zero false "remember") was recorded before corpus B was written.captureEmbed: "off"restores the judge-only path. - Measurement harness
tests/eval/harness.ts(ported from pi-quest) and the opt-in live evaluationtests/eval/capture-eval.test.ts(PI_MM_EVAL_JUDGE=1); its corpus/exemplar disjointness checks run innpm test. - README:
captureModeand the new settings are documented, with a "what decides what" table and the numbers above.
Changed
npm testis hermetic. The previous suite quietly made 14 requests to the live auren server (the zero-config discovery probe and/mm doctor's health check). The test script now preloadstests/no-live-network.ts(refuses non-loopback hosts and port 4242; ephemeral loopback fake servers still work) and setsPI_MM_AUTO_START_AUREN=0(without it, refused discovery made one smoke test take 62 s by trying to start a local server). Both are asserted bytests/no_live_network.test.ts;PI_MM_ALLOW_LIVE=1lifts the guard. Measured: 0 requests to the live server during the suite.- Daemon Runner Decoupling and Memoization (
src/tools/index.ts): Decoupledcormddaemon startup latency and memoized daemon runner instance to eliminate process spawn overhead and improve tool execution responsiveness. - Note: in a project that sets neither
captureModenorjudgeUrl,captureModeresolves to"all"and none of the above applies.
judgeModeldefaults toolmoe(the protocol already defaulted tosystemone), so a fresh install uses the model/protocol pair that measured best; documented in the README configuration table. axil-auren now answers an unparseable judge reply withchoice: null, which the judge client treats as unavailable.- Removed legacy generative judge helpers
callLlmJudge,normalizeSystemOneUrl, andparseJevAnswerfromsrc/judge/adapter.ts.
[0.4.0] - 2026-10-27
Added
- Zero-Configuration
axil-aurenInference Server Bring-Up (src/auren-bootstrap.ts,src/auren.ts): - Automatically provisions local inference configuration at
~/.config/auren/config.jsonif absent, mapping detected models and capabilities without requiring manual setup. - Automatically manages background daemon startup on port 4242 with socket/HTTP readiness polling and process lifecycle management.
- Intelligent Model Provisioning & Tiered Consent (
~/.models/): - Supports automatic discovery and downloading of local models (
bge-base,bge-small,qwen2.5-0.5b,olmoe) with cryptographicsha256verification, resumable range downloads, and atomic file swaps. - Tiered consent: light models download seamlessly, while large MoE models (
olmoe, 3.3 GB) prompt interactively viactx.ui.confirm()to respect user bandwidth and disk budget. - Proactive C Engine Dependency Tracking on
session_start(src/versions.ts,src/hooks/events.ts): - Pure TypeScript SemVer parser and engine detector inspecting system packages (
pkgconfig), source repositories (external/), and git tags foraxil,libcorm,libsepal,liblemma,libjoint, andaxil-auren. - Automatically alerts users on
session_startwith concise TUI remediation toasts if any required engine is missing or outdated, eliminating the need to manually invoke/mm doctor. - Integrated C Engine Diagnostics in
/mm doctor(src/index.ts): - Displays full matrix of core C engines, installed versions, required thresholds, and exact copy-paste remediation commands for package managers and source compilation.
- Turnkey Verification Playbook (
scripts/test-bootstrap-playbook.sh,npm run test:playbook): - Comprehensive, non-destructive test suite validating daemon recovery, zero-config file generation, model consent dialogues, and proactive dependency warning toasts.
- Standing Directives & Context Reinforcement (
src/hooks/reinforcement.ts,src/hooks/events.ts): - Automatic detection of standing rules, operational directives, and project invariants (
isStandingDirective(),/mm rule <directive>). - Periodic context milestone re-anchoring (e.g. at 33% and 66% context capacity) and post-compaction re-injection into
systemPromptOptions.sections.standing_directives. - Subsystem-aware directive routing with strict token budget capping.
[0.3.5]
Fixed
- Doctor Diagnostic Accuracy & Architecture Clarity (
src/index.ts): - Replaced misleading
Axis Sepal (Vectors): In-Memory (Ephemeral, zero disk bytes)withIn-Memory (Ephemeral index)and labeledSepal Embeddings Cacheas an L2 disk cache to resolve user confusion between in-memory vector index and on-disk embedding cache. - Replaced confusing
Axis Roster: Persistent Disk (0.0 KB)line withBound Axes (mem.db.roster): joint, lemma, sepalparsing active bound axes from the database header.
[0.3.4]
Fixed
- Doctor Diagnostic Accuracy (
src/index.ts): - Fixed
/mm doctor//mm statusTotal Indexed Records counting by queryingcorm list(via residentcormdsocket or CLI runner) instead of attempting to parse the binarymem.db.rosterfile as raw text lines. - Aligns
/mm doctorrecord reporting with/mm overviewand/mm timeline. - Roster Diagnostic Reporting (
src/index.ts): - Added explicit persistent disk size reporting for
mem.db.rosterunder secondary axes. - Complexity Compliance (
src/index.ts): - Modularized TUI reporting logic into
runOverviewReportandrunDoctorReportto satisfy strict function complexity ceilings. - Documentation & Installation Guidance (
README.md): - Separated core axis package installation (
libcorm,libjoint,liblemma,libsepal,axil) from optionalaxil-aurendaemon. - Documented
universerepository prerequisite foraxil-aurenon Debian/Ubuntu. - Documented
libjointv1.6.1 fix resolving/usr/bin/testpackaging collision.
[0.3.3]
Added
- All-Time Timeline Overview & Multi-Resolution Recall (
src/tools/overview.ts,src/tools/recall.ts): - Added
overviewflag tomemory_recallto synthesize a structured high-level summary of active operational principles (L3), invariants (L2), task investigations (L1), and chronological epochs across all time. - Added direct
zoomRefdrill-down inmemory_recallto retrieve full vertical context: problem statements, attempted approaches (worked/failed/abandoned), diffs, findings, and complete upward/downward evidence lineage trees. - Added slash commands
/mm overviewand/mm timelinewith rich TUI report formatting. - Automated proactive overview context injection in
before_agent_startwhen users pose open-ended introspection questions ("What do you remember?").
Changed
- Modularized Architecture & Complexity Ceilings (
src/tools/overview_render.ts,scripts/check-complexity.ts): - Extracted overview markdown rendering into pure helper module
overview_render.ts. - Refactored
executeRecallinto compact sub-handlers (executeOverviewRecall,executeTargetedHybridRecall). - Added subsystem baseline complexity ceilings in
check-complexity.tswhile enforcing strict LOC limits on new modules.
Fixed
- Static Analysis & Lint Cleanliness (
src/associative.ts,tests/payload.test.ts,tests/hybrid.test.ts): - Resolved all 10
deno linterrors (require-await inrecordAssociationsandreplay_session.ts; unused imports/variables inpayload.test.ts,hybrid.test.ts, andcognitive_memory.test.ts). - 93 files checked with 0 warnings and 0 errors.
- Native Benchmark Streaming (
scripts/benchmark-mm.ts): - Fixed binary payload streaming over stdin in native C benchmark runner (
-p <ref>:-). - Fixed payload stringification in synthetic benchmark ranking.
[0.3.2]
Added
- Decoupled Socket Runtime Path & DrvFs Auto-Fallback (
src/config.ts,src/tools/index.ts): - Added
socketPathandruntimeDirconfiguration keys, withPI_MM_SOCKETandPI_MM_RUNTIME_DIRenvironment variable overrides. - Added automatic detection and routing of
cormd.sockto$XDG_RUNTIME_DIR/pi-mm/cormd-<hash>.sockor/tmp/pi-mm/cormd-<hash>.sockwhenmemDiris located on non-POSIX socket filesystems (such as WSL Windows mounts under/mnt/*/ DrvFs). - Cleanly separates ephemeral host IPC endpoints from persistent repository data (
mem.db, vector indexes, crash journals).
Changed
- System-Wide Axis Library Resolution (
src/config.ts): resolveAxisPath()now detects and defaults to system-installed CORM axis libraries (/usr/lib,/usr/local/lib,/usr/lib/ttypt,/lib,/usr/lib64) when monorepo submodules (<cwd>/external/lib*) are not present.- Allows
pi-mmto run out-of-the-box in standalone repositories without triggeringcormd: unknown axis 'joint'/'lemma'/'sepal'. - Preserves local monorepo checkout priority when
external/libjoint/libexists on disk.
Fixed
- Global Settings Fallback (
src/config.ts): readMmConfig()andresolveAdvancedTools()now check global settings candidates (PI_SETTINGS_PATH,${PI_CODING_AGENT_DIR}/settings.json,~/.pi/agent/settings.json, and~/.pi/settings.json) when<cwd>/.pi/settings.jsonis missing or does not configurepi-mm.- Project-level settings continue to override global settings field-by-field.
- Added support for
"mm"key alongside"pi-mm". - Updated database compaction script (
scripts/compact_db.ts) to usereadMmConfig().
[0.3.1]
Added
- Latent Human-Like Mipmap Recall & LOD Gating (
src/hooks/auto_recall.ts): - Gated proactive context injection on conversational turns: unprompted conversational and task prompts lacking subsystem mentions yield zero context injection.
- Proactive priming on technical turns strictly bounded to L2 subsystem invariants and active hypotheses matching mentioned subsystems.
- Episodic memories (L1) remain latent, surfacing on-demand only upon explicit recall inquiries.
- Sanitized binary payload decoding and mojibake prevention (
src/payload.ts,src/tools/ranking.ts).
[0.3.0]
Added
- Flashbulb Memory Anchors (
FLAG_IS_ANCHOR = 0x08): - Implemented 1-bit anchor flag in HTOK v4 header byte 11 (0 extra storage bytes).
- Automatically tagged on explicit
@remembermarkers, breakthrough multi-attempt tasks, and user persona background stories. - Applied $+25\%$ salience multiplier in hybrid ranking (
src/tools/ranking.ts), protecting anchor memories from temporal decay and window pruning. - Associative Co-occurrence Graph & Spreading Activation (
src/associative.ts): - Entity extraction filtering English stop words, digits, and noise tokens.
- Atomic persistence in
.pi/mm/associations.jsonwith temporary file creation and atomic rename. - Lateral spreading activation in
src/tools/scan.ts:scanTokenFallback, expanding fallback queries with top associated concept terms. - Automatic association indexing on settled conversational turns and stored episodes.
- Proactive Subsystem Invariant Priming (
src/hooks/auto_recall.ts): detectSubsystemMentions()detects known project subsystems in prompt turns (song,gig,poem,corm,joint,sepal,lemma,axil,bud).primeSubsystemInvariants()proactively fetches active L2 invariants with bounded deadline enforcement (Promise.race), preventing slow runners from stalling prompt start.- User Persona & Tenet Priming (
src/hooks/auto_recall.ts): - Segregates memories scoped to
project: "user"orsubsystem: "persona". - Injects
[User Persona & Engineering Tenets]directly into persistent memory context with strict token budget deduction. - Prunes duplicates between primed blocks and general memories.
- Negative Rule Invariant Extraction (
src/synth/adapter.ts): - L2 synthesis extracts structured "Do NOT" rules from disproven approaches into
constraints?: string[]. - Rendered with prominent
[RESTRICTION]markers in auto-recall prompt context. - Enhanced Diagnostic Reporting (
/mm doctor): /mm doctorreports primary storage size, exact HTOK null-byte density, secondary axis modes (Joint in-memory vs disk, Sepal ephemeral status, embed cache size), and indexed record counts.
Changed
- Stdin-Streaming IPC Protocol (
src/corm.ts,src/daemon.ts): - Replaced eager Latin-1 string conversion with direct stdin-streaming convention
["-p",${ref}:-, filespec]for binary payloads. DaemonCormRunnerstreams raw binary buffers overcormd.sockwith zero V8 heap string allocations.ShellCormRunnerpipespayloadBytesdirectly to child processstdin.- Added poison-pill check in
formatProtocolCommandrejecting literal"-"commands without payload bytes. - Fault-Isolated Multi-Token Fallback (
src/tools/scan.ts): - Replaced unshielded
Promise.allwithPromise.allSettled, isolating individual socket errors or query timeouts from crashing fallback searches. - Asynchronous Consolidation Queue (
src/hooks/events.ts): - Implemented
ConsolidationQueuebounded toMAX_DIRTY_SCOPES_QUEUE = 50. - Integrated
SessionDrainRegistrywith 3,000ms safety timeout onsession_shutdown. - Intent-Aware Candidate Pruning (
src/tools/ranking.ts): - Added
isTechnicalInquiry()to detect code terms, paths, and symbols. - Strictly prunes syntax artifacts on casual conversational queries while preserving them during technical investigation.
[0.2.0]
- Associative Memory Co-occurrence Graph & Priming (
src/associative.ts): - Implemented graph-based associative memory activation spreading and proactive cognitive priming across connected episode nodes.
- Flashbulb Anchor Salience Boost:
- Added flashbulb anchor scoring heuristics for critical milestones and security constraints.
- HTOK v3 Binary Tokenization:
- Integrated HTOK v3 subword tokenization format and binary container serialization compatible with
liblemmaandlibhyle-source. - Content-Addressed Prompt Blocks & Stdin Streaming:
- Introduced
PromptBlockrepresentation, deterministic 64-bit FNV-1a hashing (fnv1a64), and direct stdin-streaming protocol. - Stable Working Memory Ordering:
- Recalled candidate memories canonically sorted by ascending
refID (canonicalSortByRef), preventing KV cache invalidation across turns.
[0.1.0]
- Initial release of Memory Mipmaps extension for Pi Coding Agent.
- Hierarchical episodic memory persistence (L0-L3), Corm backing with Joint/Lemma/Sepal/Islet axes, Reciprocal Rank Fusion (RRF), and resident
cormdsupport.