MCP SERVER • RUST • MEMORY

Octobrain

Hybrid Search • Sleep Consolidation • Knowledge Boxes

Give your AI assistant a long-term memory that outlives the context window — 22 memory types, hybrid BM25 + vector search, and a sleep-consolidation pass that folds a finished goal into one summary instead of leaving a hundred loose notes behind. Retrieval quality is a measured, reproducible BEIR benchmark, not a claim.

brew install muvon/tap/octobrain
BEIR-Benchmarked· HyDE Query Expansion· Git-Scoped· Apache 2.0
22 Memory Types
4 MCP Tools
+2 nDCG@10 vs Bare Embedding
10-30% Recall Lift from HyDE

Key Features

💾

Persistent Semantic Memory

LLMs don't actually remember — they re-read every message from scratch and drop context when the window fills. Octobrain stores memories externally with vector embeddings and hybrid BM25 + vector RRF fusion, so your AI retains critical context across sessions, not just within them.

😴

Sleep Consolidation

Close a goal and octobrain folds every contributing memory into one archived summary — sleep-consolidate auto-clusters similar recent memories by similarity threshold, the same way biological sleep consolidates the day into fewer, stronger memories instead of a thousand loose fragments.

📦

Knowledge Boxes

Import a git-backed knowledge bundle — box import <repo>, scoped to one project or --global across all of them — and octobrain box sync pulls and re-indexes it. Shareable, versioned context a whole team subscribes to, not memory trapped in one machine.

🎯

Query Expansion (HyDE-lite)

Pseudo-relevance feedback rewrites a query before search runs, lifting recall 10-30% on the long-tail queries where exact wording rarely matches how a memory was originally phrased. On by default, alongside the cross-encoder reranking stage.

🔗

Auto-Linking & Memory Graph

Memories connect to related memories automatically via semantic similarity, or explicitly (depends_on, related_to). memory graph walks the connections multi-hop. Ebbinghaus temporal decay fades stale memories while frequently accessed ones stay strong.

📚

Knowledge Base Indexing

Index URLs, PDFs, and docs (.txt, .md, .pdf, .docx, .html) into chunked, searchable storage — knowledge search finds passages by meaning, knowledge match runs a regex pass, and a stale source auto-reindexes the next time it is searched.

Why Octobrain?

AI forgets everything between sessions.

Persistent vector storage means memories survive across conversations. Context that matters is always available — not re-explained every time.

A finished project leaves behind a hundred loose, unsearchable notes.

consolidate folds a goal's contributing memories into one archived summary; sleep-consolidate auto-clusters similar recent memories the same way.

Team knowledge lives in one person's local memory store.

Knowledge boxes are git-backed and shareable — import once, box sync keeps every subscriber current, scoped per project or global.

"Better retrieval" is usually a claim, not a number.

octobrain ships a reproducible BEIR benchmark against its own real retrieval path — hybrid search beats classic BM25 and the bare embedding on both measured datasets, numbers anyone can rerun.

MCP Tools

Available via Model Context Protocol for AI assistants

memorize Store a memory with metadata; related_to links it inline at creation
remember Semantic search with filters, returns 1-hop graph neighbors
forget Delete memories, with confirmation required
knowledge Unified knowledge-base tool — search, store, delete, read, match via one command field

When to Use Octobrain

Cross-Session Context

Your AI assistant remembers decisions, patterns, and preferences from previous sessions. No more repeating "we use PostgreSQL, not MySQL" every conversation.

A Finished Project Becomes One Summary

Consolidate a goal and every memory that contributed to it archives into a single record. Six weeks of debugging notes become one paragraph — searchable, not scrolled through.

Team Knowledge Shared, Not Re-Explained

Publish a knowledge box once — architecture decisions, runbooks, onboarding docs — and every teammate's AI subscribes to the same git-backed source with box sync.

Research & Documentation Recall

Index API docs, design specs, and competitor analysis. Your AI references previously read material without re-fetching — instant recall of anything it has processed.

Install

Recommended

Homebrew

brew install muvon/tap/octobrain

One command. Auto-updates. No build step.

Build from Source

git clone https://github.com/muvon/octobrain && cd octobrain && cargo build --release
Requires: Rust 1.95+ • Local embeddings by default, cloud provider key optional

Tech Stack

LanceDB Vector storageVoyage AI Embeddings (optional, cloud)rmcp MCP server
FastEmbed Local embeddings, default, no API key
Tokio Async runtime
Reqwest HTTP client
OPEN SOURCE

Built in the Open

Octobrain is open source under the Apache 2.0 license. Contributions, issues, and stars are welcome.

v0.14.0 • Apache 2.0 • Built by Muvon