Production-Grade Multi-Agent Memory

Memory for
the Fleet

A persistent, human-memory-inspired memory system for LLM agents. Durable, secure, observable, and explainable.

1.1ms Recall Latency
3,852 Writes/sec
421 Commits

Core Capabilities

Built for production agents that need persistent, secure, explainable memory.

Memory Tiers

Working, episodic, semantic, procedural, and shared memory with automatic lifecycle management.

Anti-Poisoning

Trust tiers, quarantine, lineage tracking, and blast-radius limiting protect against memory attacks.

Hybrid Retrieval

Combines vector similarity, keyword search, recency, and importance for optimal recall.

Explainability

Full score breakdown for every retrieval. Know why each memory was returned.

Encryption

AES-256-GCM encryption at rest with keys from secrets manager.

Observability

Prometheus metrics, structured logging, and audit trails for compliance.

Architecture

Horizontal scaling with tenant-aware sharding and eventual consistency for shared memory.

    +--------------------------+
    |    API Gateway / Ingress  |
    |  authn, rate limiting     |
    +------------+-------------+
                 |
    +------------v-------------+
    |      Memory Service       |
    |  stateless, scalable      |
    +------------+-------------+
         +------+-------+
    +----v----+ +----v----+      +----v----+
    | Shard 0 | | Shard 1 | ...  | Shard N |
    | (WAL +  | | (WAL +  |      | (WAL +  |
    |  HNSW + | |  HNSW + |      |  HNSW + |
    | tantivy)| | tantivy)|      | tantivy)|
    +---------+ +---------+      +---------+

Quick Start

Get running in minutes.

Install
cargo add muninn-lib
Usage
use muninn_lib::MuninnMemory;

#[tokio::main]
async fn main() {
    let memory = MuninnMemory::new("./data").await.unwrap();

    // Write a memory
    memory.write("agent-1", "Deadline is March 15", 0.8).await.unwrap();

    // Retrieve memories
    let results = memory.retrieve("agent-1", "What is the deadline?", 5).await.unwrap();

    for result in &results {
        println!("{} (score: {:.2})", result.content, result.score);
    }
}

API Reference

REST API for server mode, or use the library directly.

POST /api/v1/memory/write

Write a memory record

POST /api/v1/memory/retrieve

Retrieve matching memories

GET /api/v1/memory/{id}

Get a specific record

GET /api/v1/memory/{id}/lineage

Trace record lineage

DELETE /api/v1/tenants/{id}/purge

Purge all tenant data

GET /api/healthz

Health check

Performance

Measured against published baselines.

1.1ms
Recall Latency (p99)
3,852
Writes/sec
260us
Hot Recall (p99)
2,024
Mixed Ops/sec