open-mem 0.14.0 → 0.14.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [0.14.1] - 2026-03-03
9
+
10
+ ### Changed
11
+ - `AGENTS.md` folder context mode now defaults to `single`, generating one root context file instead of creating `AGENTS.md` files across touched subfolders.
12
+ - Documentation updated to reflect `single` as the default `OPEN_MEM_FOLDER_CONTEXT_MODE` / `folderContextMode`.
13
+
8
14
  ## [0.14.0] - 2026-02-23
9
15
 
10
16
  ### Added
package/README.md CHANGED
@@ -76,7 +76,7 @@ Also supports Anthropic, AWS Bedrock, OpenAI, and OpenRouter. Auto-detects from
76
76
 
77
77
  **9 memory tools** — `memory.find`, `memory.create`, `memory.history`, `memory.get`, `memory.revise`, `memory.remove`, `memory.transfer.export`, `memory.transfer.import`, `memory.help`. See [Tools reference](docs/tools.md).
78
78
 
79
- **AGENTS.md generation** — auto-generates folder-level context files on session end so the agent has project awareness even without the plugin loaded.
79
+ **AGENTS.md generation** — auto-generates a root `AGENTS.md` context file by default on session end (or per-folder files in `dispersed` mode) so the agent has project awareness even without the plugin loaded.
80
80
 
81
81
  **Web dashboard** — timeline, sessions, search, stats, operations, and settings. Real-time updates via SSE. Config control plane with live preview and rollback.
82
82
 
@@ -104,6 +104,63 @@ export OPEN_MEM_DASHBOARD=true
104
104
 
105
105
  Six pages: Timeline, Sessions, Search, Stats, Operations, Settings. The Settings page doubles as a config control plane — preview changes, apply them, roll back if needed.
106
106
 
107
+ ## SQLite resiliency contracts
108
+
109
+ open-mem now uses a fail-safe multi-process model for SQLite. Startup and routine operations are non-destructive by default.
110
+
111
+ - **No destructive startup recovery**: if DB setup or pragma initialization fails, open-mem returns an error and does not delete `.db`, `-wal`, or `-shm` files.
112
+ - **Coordinated writes**: mutating operations use advisory lock coordination plus SQLite write-lock semantics to reduce cross-process contention.
113
+ - **Daemon-aware workers**: platform workers check daemon liveness on startup. With a healthy daemon they run in `enqueue-only` mode and signal `PROCESS_NOW`; if daemon is unavailable they automatically fall back to `in-process` mode.
114
+ - **Safe maintenance defaults**: `reset-db` runs a preflight process check and is blocked when daemon/workers are active unless explicit `--force` is provided.
115
+
116
+ ### Maintenance safety workflow
117
+
118
+ Use SQLite-native maintenance first:
119
+
120
+ ```bash
121
+ # Non-destructive WAL checkpoint
122
+ bunx open-mem-maintenance sqlite checkpoint --project /path/to/project --mode PASSIVE
123
+
124
+ # Non-destructive integrity check
125
+ bunx open-mem-maintenance sqlite integrity --project /path/to/project --max-errors 10
126
+ ```
127
+
128
+ If a full reset is required:
129
+
130
+ ```bash
131
+ # Safe-by-default reset (blocked when active processes are detected)
132
+ bunx open-mem-maintenance reset-db --project /path/to/project
133
+
134
+ # If blocked, follow CLI remediation exactly:
135
+ # 1) Stop daemon and platform workers for this project.
136
+ # 2) Retry reset-db after processes exit.
137
+ # 3) To override (destructive), rerun with --force.
138
+
139
+ # Project-scoped stop sequence (PID file based)
140
+ PROJECT=/path/to/project
141
+ for pid_file in \
142
+ "$PROJECT/.open-mem/worker.pid" \
143
+ "$PROJECT/.open-mem/platform-worker-claude.pid" \
144
+ "$PROJECT/.open-mem/platform-worker-cursor.pid"; do
145
+ if [ -f "$pid_file" ]; then
146
+ kill "$(cat "$pid_file")" 2>/dev/null || true
147
+ fi
148
+ done
149
+
150
+ # Retry safe reset after processes exit
151
+ bunx open-mem-maintenance reset-db --project "$PROJECT"
152
+
153
+ # Explicit destructive override (only after stopping daemon/workers)
154
+ bunx open-mem-maintenance reset-db --project /path/to/project --force
155
+ ```
156
+
157
+ For platform workers, `{"command":"health"}` (or HTTP `GET /v1/health`) reports `status.queue.mode`:
158
+
159
+ - `enqueue-only`: daemon is healthy; worker enqueues and signals `PROCESS_NOW`.
160
+ - `in-process`: local fallback mode when daemon is unavailable, dies, or signaling fails.
161
+
162
+ Migration note: previous workflows that relied on destructive reset during startup or ad-hoc `rm -rf .open-mem/` should move to the maintenance CLI flow above so active process checks and force intent are explicit.
163
+
107
164
  ## Documentation
108
165
 
109
166
  - [Getting Started](docs/getting-started.md) — installation and first steps