agent-working-memory 0.12.0 → 0.12.3

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
@@ -22,14 +22,14 @@ Use it through Claude Code via MCP or as a local HTTP service for custom agents.
22
22
 
23
23
  ## Quick Start
24
24
 
25
- **Node.js 20+** required — check with `node --version`.
25
+ **Node.js 22 LTS+** required — check with `node --version`. (Node 20 reached EOL 2026-04-30; AWM 0.8.6+ requires 22.)
26
26
 
27
27
  ```bash
28
28
  npm install -g agent-working-memory
29
29
  awm setup --global
30
30
  ```
31
31
 
32
- Restart Claude Code. That's it — 16 memory tools appear automatically.
32
+ Restart Claude Code. That's it — 19 tools appear automatically (17 memory + 2 onboarding).
33
33
 
34
34
  ### Upgrading
35
35
 
@@ -70,12 +70,17 @@ First conversation will be ~30 seconds slower while ML models download (~200MB t
70
70
 
71
71
  ## Why it's different
72
72
 
73
+ > **New to the vocabulary?** Terms like *engram, salience, activation, Hebbian, staging*
74
+ > are defined plainly, one paragraph each, in
75
+ > [`docs/onboarding-vocabulary.md`](https://github.com/CompleteIdeas/agent-working-memory/blob/master/docs/onboarding-vocabulary.md) — a 5-minute read if any of the table below is unfamiliar.
76
+
73
77
  Most "memory for AI" projects are vector databases with a retrieval wrapper. AWM goes further:
74
78
 
75
79
  | | Typical RAG / Vector Store | AWM |
76
80
  |---|---|---|
77
81
  | **Storage** | Everything | Salience-filtered with low-confidence fallback (novel events go active, borderline enter staging, low-salience stored at reduced confidence) |
78
82
  | **Retrieval** | Cosine similarity | 10-phase pipeline: dual BM25 (keyword + expanded) + vectors + reranking + graph walk + decay + coref expansion |
83
+ | **Named things** | Vocabulary-dependent — misses if the query doesn't lexically match | Entity inverted index: exact lookup on named entities ("ticket 19252", a person's name), immune to phrasing mismatch |
79
84
  | **Connections** | None | Hebbian edges that strengthen when memories co-activate |
80
85
  | **Over time** | Grows forever, gets noisier | Consolidation: diameter-enforced clustering, cross-topic bridges, synaptic-tagged decay |
81
86
  | **Forgetting** | Manual cleanup | Cognitive forgetting: unused memories fade, reinforced knowledge persists (access-count modulated) |
@@ -132,7 +137,13 @@ Two structural advantages a file or a flat vector store cannot match:
132
137
  Two kinds of tests, both reproducible (see [Testing & Evaluation](#testing--evaluation)).
133
138
  First, **recall quality** — does the pipeline return the right memory? Second,
134
139
  **behavior under stress** — does it stay honest, filter noise, and hold up as the
135
- store grows and ages? Numbers below were re-run on the 0.9-staged line (2026-06-17).
140
+ store grows and ages? Numbers below were last re-run on the 0.9-staged line
141
+ (2026-06-17) — the retrieval pipeline itself is unchanged since, but re-run these
142
+ yourself (`npm run eval`) if you want current-build numbers; 0.12.x added
143
+ reliability/telemetry/entity-index work on top, not retrieval-scoring changes.
144
+ See [`docs/gauntlet-baseline-2026-07-30.md`](docs/gauntlet-baseline-2026-07-30.md)
145
+ for the newer end-to-end memory-ablation acceptance test (74%±5pp memory-dependent
146
+ vs 0% no-memory control).
136
147
 
137
148
  ### 1 · Recall quality (eval harness)
138
149
 
@@ -221,7 +232,7 @@ even on a corpus far too small to play to its strengths.
221
232
 
222
233
  ## Features
223
234
 
224
- ### Memory Tools (16)
235
+ ### Memory Tools (17 + 2 onboarding = 19)
225
236
 
226
237
  | Tool | Purpose |
227
238
  |------|---------|
@@ -231,6 +242,7 @@ even on a corpus far too small to play to its strengths.
231
242
  | `memory_retract` | Invalidate a wrong memory with optional correction |
232
243
  | `memory_supersede` | Replace outdated memory with current version |
233
244
  | `memory_stats` | View memory health metrics and activity |
245
+ | `memory_whoami` | Identify the instance — agent id, workspace, backend, store path, sibling agent spaces |
234
246
  | `memory_checkpoint` | Save execution state (survives context compaction) |
235
247
  | `memory_restore` | Recover state + relevant context at session start |
236
248
  | `memory_task_add` | Create a prioritized task |
@@ -242,6 +254,15 @@ even on a corpus far too small to play to its strengths.
242
254
  | `compress_output` | Encode a structured tool output as TOON — ~50-65% fewer tokens, lossless, output-only |
243
255
  | `retrieve_original` | Get the verbatim source back for a `compress_output` ref |
244
256
 
257
+ ### Onboarding Tools (2)
258
+
259
+ For warm-starting a cold store from a project's own docs/repo — see [What's New in v0.11.0](#whats-new-in-v0110).
260
+
261
+ | Tool | Purpose |
262
+ |------|---------|
263
+ | `onboard_scan` | Extract candidate memories from a project's docs/repo for review |
264
+ | `onboard_questions` | Anchored interview questions to refine what a cold store should know |
265
+
245
266
  ### Separate Memory Pools
246
267
 
247
268
  By default, all projects share one memory pool. For isolated pools per folder, place a `.mcp.json` in each parent folder with a different `AWM_AGENT_ID`:
@@ -459,7 +480,7 @@ src/
459
480
  sqlite.ts - SQLite + FTS5 persistence layer
460
481
  api/
461
482
  routes.ts - HTTP endpoints (memory + task + system)
462
- mcp.ts - MCP server (14 tools, incognito support)
483
+ mcp.ts - MCP server (19 tools: 17 memory + 2 onboarding, incognito support)
463
484
  cli.ts - CLI (setup, serve, hook config)
464
485
  index.ts - HTTP server entry point (auto-backup on startup)
465
486
  ```
@@ -524,6 +545,9 @@ npm run test:locomo # LoCoMo industry benchmark (28.2%)
524
545
  | `AWM_DISABLE_RERANK_SKIP` | *(unset)* | Set to `1` to disable the reranker skip on clear-winner queries (0.7.10+). Forces every recall through the cross-encoder |
525
546
  | `AWM_DISABLE_EXPANSION_CACHE` | *(unset)* | Set to `1` to disable the query expansion skip heuristic + LRU cache (0.7.11+). Forces every recall through the flan-t5-small expander |
526
547
  | `AWM_WORKSPACE` | *(unset)* | Default workspace for cross-agent recall in hive setups |
548
+ | `AWM_SLOW_WRITE_MS` | `250` | Slow-write telemetry threshold in ms; any write over this logs one stderr line with a phase-time breakdown (embed/novelty/persist, event-loop lag, cold-load ms). `0` disables (v0.12.0) |
549
+ | `AWM_ENTITY_INDEX_FETCH` | *(unset)* | Set to `1` to let query-named entities ("ticket 19252", a person's name) resolve through the entity inverted index for a guaranteed reranker audition, including alias hops. Default off pending broader eval (v0.12.0) |
550
+ | `AWM_ENTITY_INDEX_CAP` | `12` | Max entity-index candidates injected per recall when `AWM_ENTITY_INDEX_FETCH=1` (v0.12.0) |
527
551
  | `AWM_STORE_BACKEND` | `sqlite` | `sqlite` (better-sqlite3 + FTS5), `pglite` (PGlite + pgvector + pgroonga), or `postgres` (node-postgres + pgvector, networked/multi-connection — **experimental**, 0.10.0). |
528
552
  | `AWM_DB_PATH` | `memory.db` (SQLite) / `./memory-pglite` (PGlite) | Storage path. Directory for PGlite, file for SQLite. Ignored for `postgres` (uses `AWM_DATABASE_URL`). |
529
553
  | `AWM_DATABASE_URL` | *(unset)* | Postgres connection string when `AWM_STORE_BACKEND=postgres` (0.10.0). |
@@ -555,323 +579,42 @@ npm run test:locomo # LoCoMo industry benchmark (28.2%)
555
579
 
556
580
  All three ML models run locally via ONNX. No external API calls for retrieval. The entire system is a single SQLite file + a Node.js process.
557
581
 
558
- ## What's New (Unreleased 2026-07-30 wave)
559
-
560
- A design-proposal implementation pass (D1–D15 waves 1–3 + D11) grounded in a full-stack
561
- eval and gauntlet-tested end to end. All additive; 599/599 tests. Highlights:
562
-
563
- - **Write-path telemetry (D1):** always-on slow-write attribution (`AWM_SLOW_WRITE_MS`,
564
- default 250 ms) one stderr line names the phase (embed / novelty / persist), event-loop
565
- lag, consolidation state, and `SQLITE_BUSY` when a write is slow.
566
- - **Local-first security defaults (D2):** HTTP binds `127.0.0.1` by default; widening
567
- beyond loopback without `AWM_API_KEY` fails closed (`AWM_BIND`, `AWM_ALLOW_INSECURE`,
568
- `AWM_COORD_REQUIRE_TOKENS`).
569
- - **Instance identity (D3):** `memory_whoami` / `GET /whoami` agent id, workspace,
570
- backend, store path, sibling agent spaces; `/health` reports consolidation state (D15).
571
- - **Memory spine (D5/D8, log-only):** `origin_class` / `writer_session` / `recipe_id` /
572
- `valid_from` / `valid_to` provenance on every write; superseded-but-ranking results are
573
- flagged, never silently down-ranked. Not used in ranking until an eval proves it (D6).
574
- - **Cognition recipes (D14):** AWM contains no LLM versioned prompt+contract pairs
575
- (`skill-derivation@1`, `friction-lesson@1`) the host agent runs as a separate focused
576
- pass, with validated write-backs.
577
- - **Entity inverted index (D9) + index-backed retrieval (D11):** `entity_mentions` +
578
- `entity_aliases` on all three backends, populated at write time from structured sources;
579
- behind `AWM_ENTITY_INDEX_FETCH=1`, query-named entities inject candidates with a
580
- **guaranteed cross-encoder audition** (no score boost — the reranker decides), including
581
- alias hops no lexical/vector channel can make.
582
- - **Gauntlet baseline:** the end-to-end memory ablation now anchors acceptance
582
+ ## What's New in v0.12.x (latest)
583
+
584
+ Three releases (0.12.0-0.12.2), eval-driven. All additive, no breaking API changes.
585
+
586
+ - **Instance identity (`memory_whoami`)** — agent id, workspace, mode, backend, store
587
+ path, code provenance, sibling agent spaces. Call it first whenever you're unsure
588
+ which store or which running code you're talking to.
589
+ - **Entity inverted index** structured identifier tags (`ticket=`, `person=`, bare
590
+ ids) feed an exact-match index. A query naming an entity resolves through it even
591
+ when the wording doesn't lexically match. Default off (`AWM_ENTITY_INDEX_FETCH=1`),
592
+ guaranteed reranker audition, no score boost.
593
+ - **Local-first security defaults** HTTP binds `127.0.0.1` by default; widening
594
+ beyond loopback without `AWM_API_KEY` fails closed.
595
+ - **Write-path telemetry** always-on slow-write attribution (`AWM_SLOW_WRITE_MS`,
596
+ default 250ms) names the phase, event-loop lag, and cold-load cost on any write
597
+ that's slow enough to matter.
598
+ - **Memory spine (provenance)**`origin_class`, `recipe_id`, `valid_from`/`valid_to`
599
+ on every write. `valid_to` expires operational facts instead of relying on the
600
+ reader to notice they're stale; recall renders `[valid until ...]` on results
601
+ carrying it.
602
+ - **Cognition recipes** AWM contains no LLM. When memory needs real thinking
603
+ (distilling a procedure, reflecting on a failure), `memory_task_end` hands the host
604
+ agent a versioned prompt+contract pair (`skill-derivation@1`, `friction-lesson@1`)
605
+ to run as its own focused pass, then validates the write-back.
606
+ - **Recall results carry engram ids** (`[id: <uuid>]`) feed a recalled memory
607
+ straight into `memory_supersede`/`memory_feedback` with no separate lookup.
608
+ - **Eager warm at MCP startup + sidecar warm recall** — model load overlaps session
609
+ start instead of your first message; the hook sidecar gained `POST /memory/activate`
610
+ for ~0.8s warm recall from a hook, with no standing server needed.
611
+ - **Gauntlet baseline** — end-to-end memory ablation now anchors acceptance:
583
612
  **74%±5pp memory-dependent vs 0% no-memory control**, six of nine probes at 100%.
584
- Methodology, per-probe mechanism table, and the six-config flag ablation:
585
- [`docs/gauntlet-baseline-2026-07-30.md`](docs/gauntlet-baseline-2026-07-30.md).
586
-
587
- ## What's New in v0.11.0
588
-
589
- **`awm onboard` — warm-start a cold store from a project's own knowledge.** A fresh store
590
- knows nothing, so recall returns nothing until interactions accumulate; onboarding seeds it up
591
- front so an agent is useful from the first turn.
592
-
593
- - **Scan:** `awm onboard <docs> --repo <path> --project <name>` extracts atomic, recall-shaped
594
- memories from docs (one per heading) + the repo (stack, layout) → an `awm import`-compatible
595
- pack + a human review file. Edit, then `awm import --dedupe`. Model-free, no API keys.
596
- - **Agent-driven interview (no AWM→LLM calls):** two MCP tools — `onboard_scan` (candidate
597
- memories to refine) and `onboard_questions` (anchored on "what is the goal of this memory
598
- system?"). The host agent (Codex, Claude Code) refines, confirms with you, and writes them.
599
- Works air-gapped.
600
- - **The skill is a memory:** `awm setup` seeds a canonical "onboard a new project" skill the
601
- agent can recall; a cold-store nudge in `memory_restore` reminds it to warm-start.
602
-
603
- Also folds in the **0.10.1** version-reporting fix (below) and fixes the npm README links
604
- (absolute GitHub / Pages URLs + the `repository` field).
605
-
606
- ## What's New in v0.10.1
607
-
608
- A patch — no functional or recall-behavior change.
609
-
610
- - **Reported version is now the truth.** Hand-maintained version strings had drifted
611
- (a 0.10.0 build announced `0.8.5`/`0.8.8`/`0.9.2` on the banner, `/health`, the MCP
612
- server, and the export payload). A new `src/version.ts` reads `version` from
613
- `package.json` at runtime, so the reported number can never diverge from the build.
614
- - README now documents the v0.10.0 Postgres backend (below) + `AWM_STORE_BACKEND=postgres`
615
- / `AWM_DATABASE_URL`.
616
-
617
- ## What's New in v0.10.0
618
-
619
- A networked **Postgres** backend + backend-agnostic memory portability, plus
620
- correctness/stability fixes from a deep audit. No API changes — existing SQLite
621
- callers keep working unmodified.
622
-
623
- - **New `postgres` backend** (`AWM_STORE_BACKEND=postgres`, `AWM_DATABASE_URL=…`).
624
- A real-server adapter over node-postgres (`pg`) + pgvector — the first backend
625
- that is multi-**connection** safe (vs SQLite's single-machine WAL and PGlite's
626
- single-process WASM), for cloud / multi-replica deployments. Sub-1.0 on purpose:
627
- the backend is **experimental** until the remaining SQLite-only paths
628
- (coordination, hot backups, integrity check) are ported and cross-backend
629
- recall-quality parity is confirmed.
630
- - **Backend-agnostic `awm import` / `awm export`.** Both route through `openStore()`,
631
- so you can export from any backend and **import INTO Postgres or PGlite** (import
632
- was previously SQLite-only). **Export now includes embedding vectors** — a faithful,
633
- recall-ready port with no re-embed when source/target embedding models match
634
- (`--no-embeddings` to skip for a model mismatch). New flags: `--all-stages`,
635
- `--include-retracted`; associations + supersession links are preserved.
636
- - **`awm merge` no longer silently drops data.** The old hand-rolled merge used a
637
- truncated schema (no `embedding`, `memory_class`, task/supersession columns) and
638
- never populated FTS — killing both vector and BM25 recall for merged rows. Rewritten
639
- to route every source engram through the authoritative `EngramStore`/`createEngram`
640
- path (+ stage/retracted/supersession restore), wrapped in `try/finally`.
641
- - **`awm import` preserves stage + retracted** — previously `--include-retracted`
642
- resurrected retracted memories and flattened all stages to `active`.
643
- - **Cross-agent contamination guard (write pipeline)** — a workspace/hive recall can
644
- surface another agent's same-concept engram; the reinforce/supersede branch now
645
- refuses to mutate an engram whose `agentId` differs from the writer's.
646
- - **Hive degradation is visible** — `getWorkspaceAgentIds` on Postgres/PGlite emits a
647
- one-time warning (workspace coordination is SQLite-only) instead of silently
648
- returning self-only.
649
-
650
- ## What's New in v0.9.0
651
-
652
- A recall-quality default + new tuning knobs + a builder/researcher doc set.
653
- Every change is an **env-revertible default** with no API changes — existing
654
- callers keep working unmodified. Validated: official LoCoMo **22.7% → 25.7%**
655
- (every category up) **and** adversarial precision **73.4 → 74.9** (strictly
656
- better on each axis); recall latency ~35 → ~77ms (sub-100ms, tunable); zero
657
- regression across the standard suite (eval 4-suite identical, 569/569 unit,
658
- edge 32/34, workday = old config).
659
-
660
- - **Wide rerank pool + top-K abstention (the win).** A pipeline-attribution
661
- study (new tracer, `tests/locomo-eval/trace.ts`) found the dominant recall
662
- loss wasn't candidate generation *or* the reranker — it was the stage between:
663
- ~50% of answerable queries had gold that *cleared the candidate floor* but was
664
- squeezed out of the rerank pool by the decay-compressed composite **before the
665
- high-lift (+3.29) reranker saw it**. Fix: the composite becomes a cheap **wide
666
- pre-filter** (`AWM_TOPN_MULT=8`, was 3×), the reranker discriminates on a wider
667
- pool (`AWM_RERANK_POOL=max(limit*4,40)`, was `max(limit*2,15)`), and the
668
- out-of-domain abstention gate judges only the **post-rerank top-K**
669
- (`AWM_ABSTAIN_GATE_K=5`) so widening for recall doesn't inflate the in-domain
670
- signal. Reverses the v0.7.13 "pool reduction" change. See
671
- [reference.md → Recall tuning](https://github.com/CompleteIdeas/agent-working-memory/blob/master/docs/reference.md#recall-tuning-env-overrides).
672
-
673
- - **Tunable similarity floors.** `AWM_SIM_FLOOR_TARGETED` / `_EXPLORATORY`
674
- (defaults 0.50 / 0.35, unchanged) and the candidate-entry floors are now env
675
- overrides for retuning against a different embedder.
676
-
677
- - **Opt-in / experimental flags (default-off).** `AWM_QUERY_BRIDGE`
678
- (query-named-entity boost — lifts attribution "what does X think" 36% → 92% on
679
- a controlled eval; small adversarial cost, so opt-in), `AWM_AUTOTAG`
680
- (write-time `entity:`/`cat:` meta-tags), `AWM_BROAD_EDGES`. `AWM_SPREAD`
681
- (in-engine spreading activation) is **parked** — it regressed recall by
682
- displacing gold; multi-hop is solved harness-side instead (see the playbook).
683
-
684
- - **New docs for builders & researchers.** [`docs/awm-for-agents.html`](https://completeideas.github.io/agent-working-memory/awm-for-agents.html)
685
- — the agent playbook (why AWM exists, the PRIME→ACT→VERIFY→LEARN harness, the
686
- full agent feature surface, how multi-hop is solved, and the honest gauntlet
687
- findings). [`docs/pipeline-walkthrough.html`](https://completeideas.github.io/agent-working-memory/pipeline-walkthrough.html)
688
- redesigned for devs/researchers. Both are published on GitHub Pages. A new
689
- **Storage Backends + Postgres roadmap** section in
690
- [architecture.md](https://github.com/CompleteIdeas/agent-working-memory/blob/master/docs/architecture.md) documents SQLite (default) vs PGlite
691
- and the path to a networked-Postgres backend (v1 target).
692
-
693
- ## What's New in v0.8.5
694
-
695
- A research-grounded hardening pass on recall quality, retraction propagation,
696
- and lifecycle management. Every change is **fully additive** — existing
697
- callers keep working without modification. Full validation at the milestone:
698
- `vitest run` 549/549 pass; `test:self` 97.6% EXCELLENT (was 91.4% on 0.8.0);
699
- `test:ab` AWM 89.3% vs Baseline 83.0% (+6.4 points); `test:perf` 4/4 PASS.
700
-
701
- - **Recall confidence as data (PR-1).** Every `ActivationResult` now carries
702
- a `confidence` field in [0, 1] — a score-distribution-aware signal
703
- (sharpness + cliff + floor blended via weighted geometric mean) that tells
704
- the caller how trustworthy the recall set is. Same value on every result
705
- in a recall — it describes the *set*, not the individual. Research grounding:
706
- Geifman & El-Yaniv (NeurIPS 2017), Roitero et al (SIGIR 2022). Default
707
- behavior unchanged; this is data, not a gate.
708
-
709
- - **Opt-in confidence-based abstention (PR-2).** Callers can pass
710
- `requireConfidence` (typical values: 0.10 strict, 0.25 balanced, 0.40
711
- aggressive). When set, the engine returns `[]` on recalls whose
712
- distribution shape falls below the threshold — defeats the
713
- "best-of-bad-bunch" leak where a noisy recall returns a weak top result
714
- that the agent then trusts.
715
-
716
- - **Coherence-weighted retraction (#18).** Retraction penalty propagation
717
- is no longer uniform. Multiplier scales with local neighborhood cohesion:
718
- dense topically-coherent clusters (a narrative) get heavier penalties when
719
- the seed is wrong; hub structures (popular node with heterogeneous edges)
720
- get lighter penalties. Implements Carrillo et al, "Continued Influence
721
- Effect" (ICCM 2025).
722
-
723
- - **Counter-narrative replacement on supersede/correction (#19).** When
724
- retraction creates a counter-content correction, the new engram inherits
725
- the original's `'connection'` edges (scaled 0.7×, capped at 10
726
- inheritances, with `invalidation` / `causal` / `temporal` skipped). The
727
- corrected fact takes over the graph role of the wrong fact rather than
728
- leaving the corrected fact disconnected.
729
-
730
- - **Content fade stage (#20) — Paper 1.** New intermediate `'fading'`
731
- lifecycle stage between `'active'` and `'archived'`. Engrams accessed
732
- before but stale (no access in 45+ days, content > 250 chars) get content
733
- trimmed to 150 chars + `… [faded]` marker. Concept, tags, and embedding
734
- preserved — the engram still participates in BM25 + vector recall, just
735
- with less body to score against. Models human memory's loss of surface
736
- detail while retaining cue-association pathways (PLOS Comp Biology on
737
- storage degradation). Heavily-used (`accessCount >= 10`), `canonical`,
738
- `structural`, and retracted engrams excluded.
739
-
740
- - **Adaptive output granularity (#21) — Paper 3.** New
741
- `granularity: 'full' | 'compact' | 'auto'` on `ActivationQuery`.
742
- `'compact'` attaches a 200-char `summary` to every result. `'auto'` is
743
- confidence-adaptive: when recall confidence ≥ 0.4, the top result gets
744
- a long-form summary and the rest are compact; when confidence is low,
745
- everything is compact so the agent can scan a diverse set without
746
- drowning in content. Engram body never modified — just the response shape.
747
- Models cognitive teaming (Brill 2018 ACT-R collaboration).
748
-
749
- ## What's New in v0.8.1
750
-
751
- - **Coordination control layer** — `FailureMode` classifier + mutation-hint
752
- retry on `cleanupStale`, per-worker `CircuitBreaker`, and voluntary
753
- `POST /assignment/:id/fail` endpoint. Designed to reduce the 11.5%
754
- failure-with-no-retry rate observed in production hive runs (81/703).
755
- Two new schema columns on `coord_assignments` plus a `coord_circuit_state`
756
- table — both additive `CREATE IF NOT EXISTS` migrations.
757
-
758
- ## What's New in v0.8.0
759
-
760
- - **Substrate primitives for long-running structured projects** — four new
761
- HTTP endpoints (`/memory/latest-by-tag`, `/memory/top-by`,
762
- `/memory/resolve`, `/memory/supersede` Form B), three query operators
763
- (`tagsAll`, `tagsAny`, `tagsNone`), and a fourth `memory_class` value
764
- (`structural`). Optional engram columns `sequence` + `references_json`
765
- enable race-free chronology and typed cross-record links. Designed against
766
- the NovelForge 36,000-word "Drawdown" test bed.
767
-
768
- ## What's New in v0.7.16
769
-
770
- - **`awm setup --global` template now teaches *write quality*.** Two new sections in `AWM_INSTRUCTION_CONTENT`:
771
- - **Writing for recall** — explicit guidance that recall quality is determined at write time. Lead with the rule/fact, pick the most specific topic, include 2+ retrievable identifiers (file paths, function names, IDs), write in the vocabulary of the future query, reserve canonical for stable invariants, include the *why* for feedback memories.
772
- - **Recall strategy** — formalizes the multi-query reformulation pattern observed in practice. When one query returns nothing, agents reformulate (synonyms, more specific nouns, exact identifiers). Recall is ~300ms — two-three reformulations cost less than one filesystem search. Cap at three to prevent loops.
773
-
774
- These document the writer + reader behaviors AWM was always designed around but were previously implicit. No retriever change — pure system-prompt improvement. Run `npm install -g agent-working-memory@latest && awm setup --global` to apply.
775
-
776
- - **LongMemEval headline number updated.** Re-running the benchmark on 0.7.16 (single-session-user, 50 questions, same adapter as the original 0.7.1 baseline): **68% accuracy with gpt-4o-mini**, up from the original 40-50%. Recall latency 0.12s avg (was 7-11s on 0.7.2). Multi-tier reader sweep on the same memory inputs:
777
- - gpt-4o-mini (cheap, non-thinking): 68%
778
- - gpt-4o (strong, non-thinking): 68%
779
- - o4-mini (cheap, thinking): 78%
780
- - gpt-5-mini (mid, thinking): 80%
781
-
782
- Non-thinking models cap at 68% on this category — the bottleneck is reasoning over recalled context, not raw scale. Thinking models add 10-12pp. Memory quality is fixed; reader determines the ceiling.
783
-
784
- ## What's New in v0.7.15
785
-
786
- - **Documentation refresh** — `awm setup --global` now writes a CLAUDE.md template that documents all four perf env-var escape hatches (`AWM_DISABLE_POOL_FILTER`, `AWM_DISABLE_SLIM_CACHE`, `AWM_DISABLE_RERANK_SKIP`, `AWM_DISABLE_EXPANSION_CACHE`) instead of just the first one. Troubleshooting / quickstart / user-guide docs updated to reflect the current ~300ms recall floor. No code change — version bumped solely so the new template ships via `npm install -g agent-working-memory@latest`.
787
-
788
- ## What's New in v0.7.14
789
-
790
- - **Recall latency 0.4-0.8s → 0.3-0.6s (~25-50% on top of 0.7.13)** — three fixes:
791
- 1. **Batched cross-encoder inference** — reranker now tokenizes + runs all query-passage pairs in one batched forward pass. 15-passage rerank: 210ms → 27ms (~7×).
792
- 2. **Truncate passages to 400 chars before rerank** — cross-encoder has 512-token max anyway and pads to the longest passage; full content (5000+ chars) meant everything padded to max length. Truncation drops tokenization + inference 3-4× on long memory pools.
793
- 3. **Eager slim-cache populate at startup** — first user recall no longer pays the ~600ms cache populate cost.
794
-
795
- Recall quality A/B: 8/8 top-1, 4.50/5 top-5. **Cumulative since 0.7.4 baseline: 11s → 0.3-0.6s (~25-37× faster).**
796
-
797
- ## What's New in v0.7.13
798
-
799
- - **Reranker pool size reduction** — cross-encoder pool dropped from `max(limit*3, 30)` to `max(limit*2, 15)`. For typical agent queries (limit=5 or 10), that's 15-20 candidates reranked instead of 30, halving the cross-encoder cost. Top-K quality preserved (8/8 top-1, identical top-5/top-10 overlap) — reranking the 21st-30th candidates was wasted when the user only wants top-5 anyway.
800
- > **⚠️ Superseded in 0.9.0 — this reduction was reversed.** A pipeline-attribution study found that "wasted" tail was actually where ~50% of retrievable answers were being squeezed out *before* the reranker saw them (the small 8-query A/B above missed it). 0.9.0 widens the pool back to `max(limit*4, 40)` and adds a top-K abstention gate — lifting LoCoMo recall 22.7%→25.7% **and** adversarial precision 73.4→74.9, with no regression. See the CHANGELOG and `docs/reference.md` → "Recall tuning."
801
-
802
- ## What's New in v0.7.12
803
-
804
- - **Recall latency 0.9s → 0.4-0.8s (~40-60% on top of 0.7.11)** — phase-breakdown showed `getAssociationsForBatch` over ~300 survivors was 222ms (25% of remaining floor) but the scoring loop only reads `count` + `sumWeight` from each engram's edges. New `getAssociationStatsForBatch` returns scalar stats via a single GROUP BY aggregate. Graph walk still uses full associations, but only on top-N (~30) so its lookups are cheap. Recall quality A/B: 8/8 top-1, 4.50/5 top-5. **Cumulative since 0.7.4 baseline: 11-23s → 0.4-0.8s (~25× faster median).**
805
-
806
- ## What's New in v0.7.11
807
-
808
- - **Query expansion skip + LRU cache** — flan-t5-small was 164ms per recall (18% of post-0.7.10 floor). Two fixes in `core/query-expander.ts`: (1) skip heuristic for long/specific queries (>50 chars OR ≥5 distinct meaningful tokens), and (2) 500-entry LRU cache for repeated queries. ~30% of typical agent recalls hit the skip; repeated recalls hit the cache. Avg savings: ~100-150ms per recall. Recall quality A/B: 8/8 top-1, 4.63/5 top-5. Disable via `AWM_DISABLE_EXPANSION_CACHE=1`.
809
-
810
- ## What's New in v0.7.10
811
-
812
- - **Recall latency 1.4s → 0.9s median (~35% on top of 0.7.9)** — two more fixes after phase-breakdown showed the slim fetch was still 310ms (Buffer→Float32Array on every recall) and the reranker was 354ms (40% of remaining cost):
813
- 1. **In-memory slim cache** — `Map<id, SlimCacheEntry>` populated once per process, mutated in lock-step with engram writes/updates/retracts. Slim fetch 306ms → **5ms** with warm cache (~60×). Disable via `AWM_DISABLE_SLIM_CACHE=1`. Memory cost ~15MB at 10K engrams.
814
- 2. **Reranker skip on clear winners** — when BM25 has a clear top-1 (textMatch ≥ 0.8, ≥1.5× the next score, small pool), skip the cross-encoder. Saves ~300ms on confident queries. Disable via `AWM_DISABLE_RERANK_SKIP=1`.
815
-
816
- Quality preserved: 8/8 top-1, 4.63/5 top-5, 9.75/10 top-10 on the A/B suite. **Cumulative since 0.7.4 baseline: 11s → 0.9s (~12-15× faster).**
817
-
818
- ## What's New in v0.7.9
819
-
820
- - **Recall latency 1.6s → 1.0s end-to-end (~30% on top of 0.7.7)** — phase-breakdown showed the fullSELECT-over-10K-engrams was the new bottleneck (440ms / 40% of recall) due to row materialization of content/tags/JSON for rows the pre-filter doesn't read. Two-pass fetch: slim `(id, concept, embedding)` for the cosine + filter pass, then hydrate only the survivors via `getEngramsByIds`. Recall quality A/B verified 8/8 top-1 identical, top-K overlap slightly improved (4.75/5 vs 4.50). **Cumulative since 0.7.4 baseline: 11-23s → 1.0-1.6s (~10-20× faster).**
821
-
822
- ## What's New in v0.7.8
823
-
824
- - **Install template updated for the 0.7.5/0.7.6/0.7.7 behaviors** — `awm setup` now writes a richer CLAUDE.md that teaches agents about memory classes (`canonical | working | ephemeral`), salience auto-promotion patterns (`detectUserFeedback` for stakeholder quotes, `detectVerifiedFinding` for operational records with action-verb + concrete IDs), and the new env-var escape hatches. Existing installs upgrade via `npm install -g agent-working-memory@latest && awm setup --global` then restart Claude Code. No functional code change in this release — version bumped solely so the new template ships.
825
-
826
- ## What's New in v0.7.7
827
-
828
- - **Recall latency 2.5s → 1.0s end-to-end (~50% on top of 0.7.6)** — phase-breakdown spike showed that after the 0.7.6 BM25 fix, the new bottleneck was `getAssociationsForBatch` over all ~10K candidates (68% of recall latency). Added a cheap pre-filter before deep scoring: candidates survive only if they have a BM25 hit, a cosine z-score above the gate, or concept-token overlap with the query. From ~10K candidates → typically 100-300 survivors. Graph-walk correctness preserved (it only boosts neighbors with `textMatch >= 0.05`, which would also pass this filter). Recall quality A/B verified: 8/8 top-1 matches, 90% top-5 overlap, 94% top-10 overlap on diverse queries. Set `AWM_DISABLE_POOL_FILTER=1` to revert. **Cumulative since 0.7.4 baseline: 11-23s → 0.9-1.6s (~10-15× faster).**
829
-
830
- ## What's New in v0.7.6
831
-
832
- - **Recall latency 11-23s → 2.5s end-to-end (~5× faster)** — measurement spike found the slow path was a SQLite query-plan trap, not vector search. The BM25 query `JOIN engrams_fts ON e.rowid + WHERE MATCH + ORDER BY rank LIMIT N` materialized all matching rows (with 1.5KB embedding blobs) before the LIMIT applied. CTE prefilter forces FTS5 LIMIT first, then joins only the top-K rowids. Same SQLite, same data, same results — 567× faster for wide OR queries (3682ms → 6.5ms verified). Also added `getAssociationsForBatch` to replace the per-candidate N+1 in the activation scoring loop. Top-K results are byte-identical to the old query (verified by the equivalence test in `spike/`).
833
- - **Salience filter — auto-promote verified operational records** — operational batch summaries (e.g., "Submitted 6 events 2026-05-07 — IDs 18969, 18971…") were being discarded at salience 0.14 because BM25 novelty couldn't distinguish "useful new operational record" from "duplicate observation" when topic terminology repeated. New `detectVerifiedFinding()` pattern detector parallel to `detectUserFeedback()`: requires action-verb header (Submitted/Finalized/Completed/Reconciled/Triaged/etc.) plus ≥2 concrete identifiers (ISO date or contextual numeric ID). Matched memories get a 0.45 salience floor (active disposition, not canonical). 7 new tests, 23 salience tests pass.
834
-
835
- ## What's New in v0.7.4
836
-
837
- - **Channel push telemetry** — new `GET /telemetry/channels` JSON endpoint and Prometheus counters (`coord_channel_push_attempts_total`, `..._delivered_total`, `..._failed_total{reason}`, `..._no_session_total`, `..._fallback_mailbox_total`, `..._session_disconnects_total`). Surfaces real delivery rate so coordination reliability can be measured rather than guessed.
838
- - **Role-based `/channel/push` addressing** — accepts `{role, workspace, message}` as alternative to `{agentId, message}`. Server resolves role+workspace to most-recently-seen alive agent. Lets workers notify the coordinator without hardcoding its UUID (which changes across coordinator restarts). Enables event-driven worker → coordinator hand-off in place of fragile coordinator self-polling.
839
- - **`/checkin` writes role on every call** — previously the UPDATE on existing rows preserved a stale role from initial registration; now agents can correct their own role via re-checkin.
840
- - **`/workers` JOINs channel sessions** — `alive` field is now `recent_pulse OR connected_channel_session`. Stops false-dead duplicate-spawn loops where a busy worker's `/pulse` went stale during long tool sequences while their channel-server stayed reachable.
841
- - **`cleanupStale` runs on a 5-minute schedule** — was only invoked manually; now zombie agents get marked dead automatically with a 600s threshold (forgiving for long edits).
842
- - **`user_feedback` salience event type** — new event type with bonus 0.3 (highest of any). Auto-detect heuristic on `memory_write` content matching `^(Robert|Katherine|Nancy|...) (said|verbatim|directed|decided|...)` forces `memoryClass='canonical'` so user-stated decisions can't be discarded by the BM25 novelty floor in populated DBs.
843
-
844
- ### v0.7.3
845
-
846
- - **Salience filter production tuning** — fixed BM25 novelty floor that was discarding ~17% salience for most writes in 10K+ engram DBs. Quadratic dampening curve (`max(0.05, 1 - topScore²)`); concept-match penalty scoped to last 30 days; floor lowered 0.10 → 0.05.
847
- - Maintenance scripts for backup pruning + lme/bench database cleanup.
848
-
849
- ### v0.7.2
850
-
851
- - Workspace recall fix (was returning UUIDs not names in v0.7.1 release).
852
-
853
- ### v0.7.1
854
-
855
- - **Agent-provided metadata tags** — `memory_write` accepts `project`, `topic`, `source`, `confidence_level`, `session_id`, `intent`. Stored as searchable prefixed tags (`proj=X`, `sid=Z`). Session ID tags alone improved LongMemEval recall 3x.
856
- - **Dual synthesis** — consolidation creates two types of summary memories: session summaries (tag-based, for perfect recall) and pattern syntheses (cross-session, for novel recall/creative connections).
857
- - **Bulk write + supersession** — `POST /memory/write-batch` for batch ingestion with `POST /memory/supersede` for knowledge updates.
858
- - **LongMemEval benchmark** — adapter built, baseline established at 40-50% with gpt-4o-mini.
859
-
860
- ### v0.7.0
861
-
862
- - Workspace-scoped recall, validation-gated Hebbian (Kairos), multi-graph traversal (MAGMA), power-law edge decay (DASH).
863
-
864
- ### v0.6.1
865
-
866
- - Embedding version tracking, batch backfill, deeper retraction propagation, retrieval timeouts, channel push delivery.
867
-
868
- ### v0.6.0
613
+ See [`docs/gauntlet-baseline-2026-07-30.md`](docs/gauntlet-baseline-2026-07-30.md).
869
614
 
870
- - **Memory taxonomy** memories classified as `episodic`, `semantic`, `procedural`, or `unclassified`. Auto-classified on write. Filter by type on recall.
871
- - **Query-adaptive retrieval** pipeline adapts to query type: `targeted` | `exploratory` | `balanced` | `auto`.
872
- - **Decision propagation** decisions broadcast to coordination layer for cross-agent discovery.
873
- - **Eval harness** — `npm run eval` benchmarks retrieval, associative, redundancy, and temporal performance.
874
- - **DB hardening** — busy_timeout, integrity check on startup, hot backups every 10 min, WAL checkpoint on shutdown.
615
+ Full version-by-version historyevery release back to v0.6.0, including the
616
+ 0.7.6→0.7.14 latency work (11s→300ms) and the 0.8.5 recall-quality hardening pass
617
+ lives in the changelog, not here:
875
618
 
876
619
  See [CHANGELOG.md](https://github.com/CompleteIdeas/agent-working-memory/blob/master/CHANGELOG.md) for full details.
877
620
 
@@ -918,24 +661,26 @@ gotchas (incl. the Windows CRLF/s6 clone fix) — is in
918
661
 
919
662
  ## Project Status
920
663
 
921
- AWM is in active development (v0.8.5). The core memory pipeline, consolidation
664
+ AWM is in active development (v0.12.2). The core memory pipeline, consolidation
922
665
  system, multi-agent coordination, and MCP integration are stable and used
923
666
  daily in production coding workflows.
924
667
 
925
668
  - Core retrieval and consolidation: **stable**
926
- - MCP tools and Claude Code integration: **stable**
669
+ - MCP tools and Claude Code integration: **stable** (19 tools: 17 memory + 2 onboarding)
927
670
  - Other MCP hosts (e.g. [Hermes Agent](https://github.com/CompleteIdeas/agent-working-memory/blob/master/docs/integrations/hermes.md)): **supported** — AWM drops in as an MCP memory server with no adapter code
928
671
  - Multi-agent coordination: **stable** (v0.8.1 hardening)
929
672
  - Task management: **stable**
930
- - Hook sidecar and auto-checkpoint: **stable**
673
+ - Hook sidecar and auto-checkpoint: **stable** — plus `POST /memory/activate` warm recall for hooks (v0.12.2)
931
674
  - HTTP API: **stable** (for custom agents)
932
- - Eval harness: **stable** (v0.6.0, extended through 0.8.x)
675
+ - Eval harness: **stable** (v0.6.0, extended through 0.8.x); gauntlet acceptance test added (v0.12.0)
933
676
  - Recall confidence + opt-in abstention (PR-1, PR-2): **stable** (v0.8.5)
934
677
  - Coherence-weighted retraction + counter-narrative inheritance: **stable** (v0.8.5)
935
678
  - Content fade stage + adaptive output granularity: **stable** (v0.8.5)
936
679
  - PGlite backend (alternative to SQLite, with pgvector + ivfflat): **stable** (v0.8.x)
937
680
  - Networked Postgres backend (`pg` + pgvector, multi-connection): **experimental** (v0.10.0)
938
681
  - Backend-agnostic `import`/`export` (embeddings included, cross-backend port): **stable** (v0.10.0)
682
+ - Instance identity (`memory_whoami`), local-first security defaults, write-path telemetry, memory-spine provenance (`origin_class`/`valid_from`/`valid_to`), cognition recipes: **stable** (v0.12.0)
683
+ - Entity inverted index + guarded index-backed retrieval: **stable, opt-in** (`AWM_ENTITY_INDEX_FETCH=1`, default off pending broader eval) (v0.12.0)
939
684
 
940
685
  See [CHANGELOG.md](https://github.com/CompleteIdeas/agent-working-memory/blob/master/CHANGELOG.md) for version history.
941
686
 
@@ -1 +1 @@
1
- {"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../src/adapters/common.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAK/C,gEAAgE;AAChE,wBAAgB,kBAAkB,IAAI,MAAM,CAG3C;AAED,2EAA2E;AAC3E,wBAAgB,aAAa,CAAC,WAAW,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,CAOnF;AAED,8CAA8C;AAC9C,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAUxD;AAED,8DAA8D;AAC9D,wBAAgB,YAAY,CAC1B,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,MAAM,EAChB,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,OAAO,GACjB,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAOxB;AAED;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,YAAY,GAAG;IACpD,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,EAAE,CAAC;CAChB,CAkBA;AAED,uDAAuD;AACvD,wBAAgB,iBAAiB,CAAC,IAAI,EAAE;IACtC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;CAClB,GAAG,YAAY,CA6Bf;AAED,sBAAsB;AACtB,wBAAgB,OAAO,IAAI,MAAM,CAEhC;AAID;;;GAGG;AACH;;;;;;;;;;;;;GAaG;AACH,wBAAgB,gBAAgB,CAC9B,QAAQ,EAAE,MAAM,EAChB,UAAU,EAAE,MAAM,EAClB,OAAO,GAAE;IAAE,UA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M,EAChB,UAAU,EAAE,MAAM,EAClB,OAAO,GAAE;IAAE,UAAU,CAAC,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAA;CAAO,GACrD,MAAM,CA8CR;AAED,eAAO,MAAM,uBAAuB,QAsWvB,CAAC"}
@@ -258,6 +258,29 @@ and entity-bridge boosts at recall time.
258
258
  - \`person=<Name>\` for stakeholder quotes / decisions
259
259
  - \`version=<X.Y.Z>\` for release-specific findings
260
260
 
261
+ ### Entity index — exact-match recall for named things (default off)
262
+ Structured identifier tags (\`ticket=\`, \`person=\`, \`horse=\`, \`member=\`, bare 4+ digit
263
+ ids, etc.) feed a dedicated entity inverted index, separate from BM25/embedding scoring.
264
+ A query naming an entity ("ticket 19252", "Kaleigh Collett") can reach the memory through
265
+ this index even when the wording doesn't lexically match — it's a deterministic exact
266
+ lookup, immune to vocabulary mismatch. Keep identifier tags exact and consistent for
267
+ this reason, not just for the BM25 boost described above.
268
+
269
+ Off by default; opt in with \`AWM_ENTITY_INDEX_FETCH=1\` (bounded by
270
+ \`AWM_ENTITY_INDEX_CAP\`, default 12). Matched entities get no score boost — they're
271
+ guaranteed a reranker audition instead, so the cross-encoder alone decides whether they
272
+ surface. Worth trialing on identifier-heavy workloads (ticket/event numbers, named
273
+ people/things you refer to by name often); not yet the default pending evaluation.
274
+
275
+ ### Temporal validity — memories that expire or start in the future
276
+ \`memory_write\` accepts \`valid_from\` / \`valid_to\` (ISO dates). Use \`valid_to\` on
277
+ **operational** facts with a real shelf life — a deploy state, "waiting on X's reply",
278
+ a ticket status — so the memory expires instead of relying on you to remember it's
279
+ stale. Recall renders \`[valid until …]\` on results carrying this field. Use
280
+ \`valid_from\` for a fact that becomes true on a known future date (a policy change, a
281
+ season that hasn't started yet). Don't set either for durable facts — most memories
282
+ don't need them.
283
+
261
284
  ### Memory classes (controls how strictly the salience filter gates the write)
262
285
  - \`memory_class: canonical\` — source-of-truth memories. Floor 0.7 salience, never staged.
263
286
  Use for: user-stated decisions, project requirements, verified architectural facts,
@@ -414,8 +437,14 @@ memory_write(
414
437
 
415
438
  ### Also:
416
439
  - To track work items: memory_task_add, memory_task_update, memory_task_list, memory_task_next
440
+ - \`memory_whoami\` (MCP tool) / \`GET /whoami\` — identify the instance you're actually
441
+ talking to: agent id, workspace, mode, backend, store path, code provenance, sibling
442
+ agent spaces sharing the store. Call this FIRST whenever you're unsure which store,
443
+ which agent identity, or which running code you're dealing with — before reasoning
444
+ about AWM's own state from a stale memory or an assumed port number.
417
445
  - AWM is shared across all agents in real time. When any agent writes or supersedes a
418
- memory, every other agent can recall it immediately.
446
+ memory, every other agent can recall it immediately — but only within the same
447
+ workspace and agent scope.
419
448
 
420
449
  ### Output compression (token efficiency, output-only)
421
450
  When a tool returns a LARGE STRUCTURED result you need to keep in context — a JSON
@@ -458,11 +487,7 @@ for A/B testing if a regression appears in your workload:
458
487
  Recall pipeline (0.7.x):
459
488
  - \`AWM_DISABLE_POOL_FILTER=1\` — disables the candidate pool reduction
460
489
  pre-filter in recall. Reverts to scoring all active candidates.
461
- - \`AWM_SLOW_WRITE_MS\` — slow-write telemetry threshold in ms (default 250;
462
- 0 disables the always-on slow-write stderr line).
463
- - \`memory_whoami\` (MCP) / \`GET /whoami\` — identify the instance (agent, mode,
464
- backend, store path, code provenance, sibling agent spaces) when unsure
465
- which AWM you are talking to.
490
+ - \`AWM_ENTITY_INDEX_FETCH=1\` — see "Entity index" above (0.12.x, default off).
466
491
  - \`AWM_DISABLE_SLIM_CACHE=1\` — disables the in-memory slim cache.
467
492
  Reverts to per-recall SQL fetch + Buffer→Float32Array conversion.
468
493
  - \`AWM_DISABLE_RERANK_SKIP=1\` — disables the cross-encoder skip on
@@ -470,7 +495,11 @@ Recall pipeline (0.7.x):
470
495
  - \`AWM_DISABLE_EXPANSION_CACHE=1\` — disables the query expansion skip
471
496
  heuristic + LRU cache. Forces every recall through flan-t5-small.
472
497
 
473
- Write pipeline + lifecycle (0.8.x):
498
+ Write pipeline + lifecycle (0.8.x, plus 0.12.x telemetry):
499
+ - \`AWM_SLOW_WRITE_MS=250\` (0.12.x) — any write slower than this logs one stderr
500
+ line with a phase-time breakdown (embed/novelty/persist, event-loop lag,
501
+ embed-model cold-load ms). \`0\` disables. Useful for diagnosing why a session's
502
+ first write/recall feels slow.
474
503
  - \`AWM_REINFORCE_MAX_CONTENT_LEN=1500\` — max chars an engram's content
475
504
  can grow to via merge-on-reinforce (drop-oldest on overflow). Higher =
476
505
  preserves more reinforced detail; lower = leaner recall output.
@@ -1 +1 @@
1
- {"version":3,"file":"common.js","sourceRoot":"","sources":["../../src/adapters/common.ts"],"names":[],"mappings":"AAAA,gDAAgD;AAChD,sCAAsC;AAEtC;;;;;GAKG;AAEH,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC7E,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAC7D,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,SAAS,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAGzC,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;AAEtC,gEAAgE;AAChE,MAAM,UAAU,kBAAkB;IAChC,uEAAuE;IACvE,OAAO,OAAO,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;AACxC,CAAC;AAED,2EAA2E;AAC3E,MAAM,UAAU,aAAa,CAAC,WAAmB,EAAE,QAAwB;IACzE,MAAM,MAAM,GAAG,QAAQ,IAAI,IAAI,CAAC,WAAW,EAAE,MAAM,EAAE,WAAW,CAAC,CAAC;IAClE,MAAM,KAAK,GAAG,O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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsWtC,CAAC,SAAS,EAAE,CAAC"}
@@ -34,7 +34,7 @@ async function loadInProcess() {
34
34
  inProcessInitPromise = pipeline('feature-extraction', MODEL_ID, { dtype: 'fp32' }).then(pipe => {
35
35
  inProcessInstance = pipe;
36
36
  noteModelLoad(performance.now() - tLoadStart);
37
- console.log(`Embedding model loaded in-process: ${MODEL_ID} (${DIMENSIONS}d)`);
37
+ console.error(`Embedding model loaded in-process: ${MODEL_ID} (${DIMENSIONS}d)`);
38
38
  return pipe;
39
39
  });
40
40
  return inProcessInitPromise;