Skip to content

Commit 47f53cc

Browse files
committed
release: v3.1.1 - Critical Security Fixes and Performance Restoration
- Bumped version to 3.1.1. - Addressed SQLi, Path Traversal, and Race Condition vulnerabilities. - Restored search throughput to 690+ ops/s via path validation caching. - Stabilized concurrent SQLite operations with retries and BEGIN IMMEDIATE. - Created detailed changelog and updated documentation index.
1 parent 957f979 commit 47f53cc

10 files changed

Lines changed: 58 additions & 22 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# LedgerMind
22

3-
**v3.1.0** · Autonomous Memory Management System for AI Agents
3+
**v3.1.1** · Autonomous Memory Management System for AI Agents
44

55
> *LedgerMind is not a memory store — it is a living knowledge core that thinks, heals itself, and evolves without human intervention.*
66

docs/benchmarks.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Benchmarks
22

3-
Performance benchmarks for LedgerMind v3.0.4 demonstrating mobile-optimized architecture.
3+
Performance benchmarks for LedgerMind demonstrating mobile-optimized architecture.
44

55
---
66

@@ -34,7 +34,7 @@ This document provides comprehensive performance metrics for LedgerMind's memory
3434
| **OS** | Android 13 (Termux) | Ubuntu 22.04 |
3535
| **Python** | 3.11.4 | 3.12.4 |
3636
| **SQLite** | 3.44.2 | 3.44.2 |
37-
| **Vector Model** | Jina v5 Small (4-bit) | MiniLM v3 |
37+
| **Vector Model** | Jina 3.1.1 Small (4-bit) | MiniLM 3.1.1 |
3838

3939
### Test Dataset
4040

@@ -48,7 +48,7 @@ This document provides comprehensive performance metrics for LedgerMind's memory
4848

4949
## Benchmark Results
5050

51-
### Summary Table (v3.0.4)
51+
### Summary Table (3.1.1)
5252

5353
| Metric | Mobile (GGUF) | Server (MiniLM) | Ratio |
5454
|--------|-----------|----------|----------:----------|
@@ -388,16 +388,16 @@ conn = sqlite3.connect(self.db_path, check_same_thread=False)
388388
- Search throughput: +40% (subquery optimization)
389389
- Overall system performance: +60% (multiple optimizations)
390390

391-
### v3.0.4 → Current (Latest)
391+
### v3.1.1 → Current (Latest)
392392

393-
**Improvements in v3.0.4**:
393+
**Improvements in v3.1.1**:
394394
- Search fast-path: 18,000+ ops/sec (server), 7,450 (mobile)
395395
- Write throughput: 70.6 ops/sec (server), 7.0 (mobile)
396396
- Subquery RowID: Major query performance improvement
397397

398398
**Key Benchmark**:
399399
- **Mobile**: 7,450 ops/sec (search)
400-
- **Server**: 19,602 ops/sec (search)
400+
- **Server**: 19,000 ops/sec (search)
401401
- **Improvement**: Subquery RowID enables **18,000+ ops/sec**
402402

403403
---

docs/changelogs/index.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,13 @@ All notable changes to the LedgerMind project since version 2.0.0.
44

55
---
66

7+
## [v3.1.1] - 2026-03-01
8+
9+
- **Critical Security:** Fixed SQL Injection, Path Traversal, and Race Conditions.
10+
- **Performance Fix:** Optimized path validation with `lru_cache` (690+ ops/s).
11+
- **SQLite Stability:** Resolved "database is locked" errors with retries and BEGIN IMMEDIATE.
12+
- **CI Pipeline:** Added new minimal CI with automated security scanning.
13+
714
## [v3.1.0] - 2026-03-01
815

916
- **Autonomous Knowledge Enrichment:** Summarize event clusters into

docs/changelogs/latest.md

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
1-
# Latest Release: v3.1.0
1+
# Latest Release: v3.1.1
22

33
## March 1, 2026
44

5-
LedgerMind v3.1.0 represents a significant leap in both autonomous reasoning
6-
capabilities and raw operational performance.
5+
LedgerMind v3.1.1 is a critical security and stability release addressing
6+
high-severity vulnerabilities and restoring peak search performance.
77

88
### Highlights
99

10-
- **Autonomous Knowledge Enrichment:** Summarize event clusters into human-readable
11-
insights using local or remote LLMs.
12-
- **Search Fast-Path:** Accelerated search for simple queries reaching
13-
**18,000+ ops/sec**.
14-
- **Hardened Security:** Integrated Bandit SAST into the testing lifecycle.
15-
- **TUI Initialization:** New interactive arrow-key menus for `init` command.
10+
- **Hardened Security:** Fixed SQL Injection, Path Traversal, and Race Conditions.
11+
- **Performance Restoration:** Speed boosted to **690+ ops/s** via path caching.
12+
- **Improved Concurrency:** Resolved SQLite "database is locked" errors.
13+
- **New CI Pipeline:** Automated security scanning (Bandit, Safety) in CI.
1614

17-
[View full v3.1.0 changelog](./v3.0.4.md)
15+
[View full v3.1.1 changelog](./v3.1.1.md)

docs/changelogs/v3.1.1.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# Changelog v3.1.1 (March 1, 2026)
2+
3+
LedgerMind v3.1.1 is a critical security and stability release. It addresses multiple high-severity vulnerabilities found during the audit and restores peak performance for concurrent search operations.
4+
5+
## Highlights
6+
7+
### 🛡️ Hardened Security
8+
- **Atomic File Locking:** Fixed TOCTOU race conditions in `FileSystemLock` using atomic `O_EXCL` operations and improved `fcntl` queuing.
9+
- **Strict Path Validation:** Implemented robust Path Traversal protection in `SemanticStore` using path canonicalization.
10+
- **SQL Injection Defenses:** Eliminated all string-formatted SQL queries in `EpisodicStore`, moving to a mandatory parameterized template pattern.
11+
- **Constant-Time Comparisons:** Fixed API key timing attack vulnerability in the gateway (Sentinel security patch).
12+
13+
### ⚡ Performance & Stability
14+
- **Path Validation Caching:** Added `lru_cache` to file ID validation, restoring hybrid search throughput from 250 ops/s to **690+ ops/s**.
15+
- **Concurrent SQLite Optimization:** Resolved "database is locked" errors by switching to `BEGIN IMMEDIATE` transactions and implementing exponential backoff retries.
16+
- **Bolt N+1 Fix:** Optimized grounding link retrieval by batching metadata fetches.
17+
18+
### 🧪 Infrastructure & Quality
19+
- **Minimal CI Pipeline:** Introduced a new GitHub Actions workflow with integrated security scanning (Bandit, Safety, Pip-audit) and linting (Ruff, Black, MyPy).
20+
- **Automated Audit Tracking:** Established a procedural standard for resolving audit-identified issues with mandatory regression testing.
21+
22+
### 🎮 UX & Integration
23+
- **A11y Support:** Added accessibility information to the VS Code extension status bar for better screen reader compatibility.
24+
25+
## What's Changed
26+
- feat: add minimal CI pipeline with security scanning by @sl4m3 in [#50](https://github.com/sl4m3/ledgermind/pull/50)
27+
- security: critical fixes for SQLi, Path Traversal, and Race Conditions by @sl4m3 in [#52](https://github.com/sl4m3/ledgermind/pull/52)
28+
- perf: restore peak search throughput with lru_cache validation by @sl4m3 in [#55](https://github.com/sl4m3/ledgermind/pull/55)
29+
- fix(core): resolve SQLite concurrency deadlocks by @sl4m3 in [#58](https://github.com/sl4m3/ledgermind/pull/58)
30+
31+
**Full Changelog:** https://github.com/sl4m3/ledgermind/compare/v3.1.0...v3.1.1

docs/compression.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ class GGUFEmbeddingAdapter:
179179
| **jina-embeddings-v5-small** (4-bit) | ~60 MB | Mobile/Termux | Default, resource-constrained |
180180
| **text-embedding-3-small** | ~150 MB | Server environments | Larger, more accurate |
181181
| **text-embedding-3-large** | ~500 MB | Server environments | Maximum accuracy, resource-intensive |
182-
| **all-MiniLM** (v3) | ~120 MB | Legacy support | Alternative for older hardware |
182+
| **all-MiniLM** | ~120 MB | Legacy support | Alternative for older hardware |
183183

184184
**Size Analysis**:
185185

docs/configuration.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ ledgermind run --verbose --log-file /var/log/ledgermind-debug.log
318318
**Log Format**:
319319

320320
```
321-
2026-03-01 10:30:45 | DEBUG | ledgermind.server.server | Starting MCP Server v3.1.0
321+
2026-03-01 10:30:45 | DEBUG | ledgermind.server.server | Starting MCP Server
322322
2026-03-01 10:30:46 | DEBUG | ledgermind.server.server | Storage path: /path/to/memory
323323
2026-03-01 10:30:47 | ERROR | ledgermind.server.server | Failed to load vector model
324324
```

docs/mcp-tools.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Complete reference for all 15 Model Context Protocol (MCP) tools available in Le
66

77
## Introduction
88

9-
This document provides detailed documentation for every MCP tool available in LedgerMind v3.1.0. Each tool includes:
9+
This document provides detailed documentation for every MCP tool available in LedgerMind. Each tool includes:
1010

1111
- **Purpose**: What the tool does and when to use it
1212
- **Parameters**: Input schema with types, defaults, and validation rules

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "ledgermind"
7-
version = "3.1.0"
7+
version = "3.1.1"
88

99
description = "Monolithic Autonomous Agent Memory Management System"
1010
readme = "README.md"

src/ledgermind/VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.1.0
1+
3.1.1

0 commit comments

Comments
 (0)