LongMemOS: Zero-LLM-Write Deterministic Enterprise Agent Memory

LongMemOS (arXiv:2612.04831) is a single-executable Rust deterministic memory operating system that eliminates write-time LLM and embedding calls ($0 ingestion model cost). Persisting turns into an encrypted append-only store partitioned at 32 KiB UTF-8 boundaries with SHA-256 digests and supersedes version chains, it achieves 95.40% on LongMemEval-S and 92.86% on LoCoMo Cat 1-4.
LongMemOS: Zero-LLM-Write Deterministic Enterprise Agent Memory: LongMemOS (arXiv:2612.04831) is a single-executable Rust deterministic memory operating system that eliminates write-time LLM and embedding calls ($0 ingestion model cost). Persisting turns into an encrypted append-only store partitioned at 32 KiB UTF-8 boundaries with SHA-256 digests and supersedes version chains, it achieves 95.40% on LongMemEval-S and 92.86% on LoCoMo Cat 1-4. Designed as a zero-dependency, open-source TypeScript architecture under the MIT License with native Model Context Protocol (MCP) support and deterministic phase state machines.
- $0 Write-Time LLM & Embedding Cost: Writes bypass remote LLM fact extractors completely, decoupling write availability from model outages and rate limits.
- 95.40% LongMemEval-S & 92.40% LongMemEval-M: Verified across 10,957 dataset-item evaluations, including 92.86% on LoCoMo Cat 1-4 and 71.22% pass rate on BEAM 1M/10M.
- Sub-60ms Cold Start & Minimal Footprint: v2.1 enterprise tests hit 40.3 ms cold start (5.97 MB idle VmRSS) on Linux/WSL2; frozen binary 6fe5dc92 peaks at ~195 MB on BEAM-10M.
- Cryptographic & Verbatim Auditability: Partitions raw turns at 32 KiB UTF-8 boundaries with monotonic sequence numbers, SHA-256 per-row digests, and supersedes conflict chains.
import { createAgent } from '@smoke-monkey/harness';// Attach LongMemOS UAMP v0.2.0 deterministic memory binary to an enterprise coding agentconst agent = createAgent({agentId: 'longmemos-enterprise-agent',provider: 'anthropic',model: 'claude-sonnet-4-5',workspacePath: process.cwd(),mcpServers: {longmemos: {command: 'longmemos-uamp',args: ['--ledger', './.longmemos/vault.enc', '--partition-bytes', '32768'],env: {LONGMEMOS_VERIFY_SHA256: 'true',LONGMEMOS_PROTOCOL: 'UAMP-v0.2.0',},},},permissions: {read_file: 'allow',write_file: 'ask',run_command: 'ask',},});async function main() {const result = await agent.run('Query the UAMP memory ledger for Q3 compliance policy revisions and trace supersedes chains.');console.log('Verified Memory Output:', result.summary);}main().catch(console.error);
Watch: Related Video Guides
Agent Memory EXPLAINED - Complete Architecture
The Complete Guide to AI Agent Memory
What Is LongMemOS and Why Avoid Write-Time LLM Extraction?
LongMemOS is a single-executable Rust memory operating system built around a zero-LLM, zero-learned-embedding write path for long-horizon enterprise agents. Instead of invoking an LLM to summarize or extract facts during ingestion, it writes verbatim turns into an encrypted append-only store partitioned at 32 KiB UTF-8 boundaries with monotonic sequence numbers and SHA-256 verification.
Write-time LLM pipelines incur per-turn inference fees, fail when upstream model APIs throttle, and silently overwrite verbatim provenance when summaries mutate. LongMemOS separates durable truth storage from conflict resolution via explicit supersedes version chains and optional asynchronous consolidation—preserving 100% verbatim audit trails while scaling cleanly to 10M-token histories.
| Benchmark (10,957 Total Items Evaluated) | Items | LongMemOS Verified Offline Result |
|---|---|---|
| LongMemEval-S | 500 | 95.40% accuracy (477 / 500) |
| LongMemEval-M | 500 | 92.40% accuracy (462 / 500) |
| LoCoMo (Cat 1–4 / Full) | 1,986 | 92.86% Cat 1–4 (1,430/1,540); 86.61% overall (Cat 5: 65.02%) |
| BEAM (1M & 10M Subsets) | 900 | 71.22% pass rate (641 / 900; mean rubric 65.24%) |
| PersonaMem-v2 128k | 5,000 | 75.92% mean score (80.36% pass rate; 65.42% >= 0.9) |
| MemoryAgentBench | 2,071 | 75.92% micro-average (91.00% CR-SH) |
Offline Judgment Verification & Enterprise Binary Footprint
LongMemOS v2.1 measures 40.3 ms median cold start (5.97 MB idle VmRSS) on Linux/WSL2 and 59.3 ms on Windows NTFS (8.33 MiB working set). Even under 10M-token BEAM workloads, the frozen audit binary (6fe5dc92...) stays within ~75 MB typical RSS (47.1 MiB floor) and ~195 MB peak memory.
# Verify the published 10,957-record LongMemOS benchmark kit offline
git clone https://github.com/LongmemOS/longmemos-benchmarks.git
cd longmemos-benchmarks
sha256sum -c SHA256SUMS.txt
python3 -I verify_public_kit.pyPreserve Verbatim Provenance for Regulated Audits
Because LongMemOS persists raw turns at 32 KiB UTF-8 boundaries without lossy write-time summarization, compliance auditors can trace any retrieved policy revision back to its exact monotonic sequence number and SHA-256 request/response digest.
Frequently Asked Questions
Q:Does LongMemOS call an LLM or embedding API when storing new messages?
No. LongMemOS uses a zero-LLM, zero-learned-embedding critical write path, incurring $0 in write-time model charges and avoiding write failures during upstream API outages.
Q:How does LongMemOS handle contradicting or updated user facts?
Updates are tracked through explicit supersedes version chains and an embedded lightweight graph index, allowing newer facts to override older records without erasing verbatim historical entries.
Q:What is the memory and cold-start footprint of LongMemOS?
In v2.1 enterprise benchmarks, LongMemOS achieved 40.3 ms median cold start with 5.97 MB idle VmRSS on Linux/WSL2, and ~195 MB peak RAM on 10M-token BEAM workloads.
Q:How does LongMemOS connect to existing agent frameworks?
It exposes the Unified Agent Memory Protocol (UAMP v0.2.0) data plane specification and SDKs alongside an offline SHA-256 verifier.
Related Alternatives & Comparisons
Related Architecture Guides
View all guidesBest Open Source Coding Agents in 2026: Free, Local & Fully Hackable Harnesses
MCP Server Security Best Practices: Hardening Model Context Protocol Agents in 2026
Open Source Coding Agent Harness: Build a Forkable, Local AI Engineering Runtime
Build with Smoke Monkey Harness
Zero dependencies. 24 built-in tools. Human-in-the-loop safety. 100% open source under the MIT License.