Repository navigation
v1.3.0 — QA Audit, Transactions, 73% Test Coverage
What's New
Auto-Context Injection
New mnemo inject command integrates with Claude Code's UserPromptSubmit hook — every prompt you type automatically searches past sessions and injects relevant context. Three modes:
- off — no injection
- helper — AI sees past sessions as helper context
- assistant — AI sees past sessions as its own memory (recommended)
Configure with mnemo configure or during first-run onboarding.
QA Audit — 50 bugs fixed
Comprehensive audit covering error handling, type safety, and edge cases across all 35 source files.
Transaction Atomicity
All 12 indexers now use BeginTx() with atomic commit/rollback. No more partial session writes on errors.
Typed Return Structs
Replaced map[string]interface{} patterns with RecentSession, UsageStats, ToolUsageSummary, ModelUsageSummary — compile-time type safety for all callers.
Test Coverage
internal/db/— 73.1% (up from 17.9%)- 8 new test files, 70+ tests covering transactions, FTS5 triggers, search ranking, token tracking, and edge cases
Key Fixes
rows.Err()checked after everyfor rows.Next()loop- All
_ =patterns on fallible calls eliminated - Type assertion safety with comma-ok pattern throughout
- Temporal decay: zero-timestamp fallback, future clamping, density caps
- UTC normalization for all timestamp parsing
- Streaming JSONL parser for large files (replaces
io.ReadAll) - HTTP status code forwarding in proxy
- Directory permissions hardened to
0700 - UTF-8 safe string truncation
Architecture
execerinterface abstracting*sql.DBand*sql.Tx- Tx variants:
TxInsertSession,TxInsertMessage,TxInsertSessionSimple - Scan error logging with
log.Printf - Godoc comments on all exported functions
Full Changelog: v1.2.0...v1.3.0