// OPEN SOURCE

Shared Memory Layer for AI Agents

Cortex is a persistent, distributed AI memory system. Give every agent in your stack a shared brain. No API keys for embeddings. One deploy.
// THE PROBLEM

Agents Forget Everything

Curly braces icon with scattered diamond-shaped fragments breaking away from the lower right, representing data parsing or JSON processing

Context Rot

Switch from Claude to Cursor and your agent gets amnesia. Every conversation, decision, and preference is siloed inside each tool.
Two interlocking gear icons separated by a vertical divider line, representing system integration or configuration management

No Shared State

Multi-agent systems need shared memory. Today you might stitch together SQLite, Redis, Postgres, and an embedding API. That is four services for one capability.
Padlock icon flanked by castle turrets with battlements and arched doorways, representing fortified security or data protection

Local-Only Memory

File-based vector stores die with the process. They do not survive restarts, do not scale horizontally, and cannot be shared across agents or teams.
// WHAT CORTEX GIVES YOU

All-in-one Memory Infrastructure.

Server-side ONNX embeddings

Embeddings run locally inside Harper with no external API calls. No OpenAI key, no Voyage key, nothing to configure. Text is embedded automatically when stored and searched automatically when queried.

HNSW vector indexing

384-dimensional cosine similarity search built into the table layer. Sub-millisecond recall on millions of memories.

Multi-agent isolation

Namespace memories by agent ID. Shared table, scoped reads. Or give each agent its own table. Both patterns, one config.

Real-time propagation (MQTT)

When one agent learns something, every subscribed agent gets it immediately. Built-in messaging. No Kafka. No Redis Pub/Sub.

Semantic + attribute search

Hybrid retrieval. Vector similarity for meaning, structured filters for classification, source, channel, and author. One query, both axes.

Distributed via Harper Fabric

Host locally for free or deploy across a secure distributed cloud cluster. Memory survives restarts, scales horizontally, and syncs across regions for low latency access wherever systems need it.
// ARCHITECTURE

How it works.

INGESTION CORTEX RETRIEVAL Slack GitHub Linear via webhooks CLAUDE.md .cursor/rules .windsurf/ via Synapse CLI webhook synapse Classify Embed (ONNX) Store Memory Table HNSW vector index SynapseEntry HNSW vector index MQTT Real-time Content Safety MemorySearch REST API MCP Server MCP Claude Code Cursor Windsurf Any MCP Client OpenClaw / NemoClaw LangChain.js via plugins (coming soon)
// WHY CORTEX

Compared to the alternatives.

CORTEX
Mem0
LanceDB
Markdown Files
Local
Single runtime, $0 embeddings
npm install, run locally. ONNX embeddings built in.
Docker stack + external APIs
3 containers (API + Postgres + Neo4j) + OpenAI key
Embedded file + external API
Local vector store, but needs OpenAI for embeddings
Flat file, no dependencies
No vector search, no semantic retrieval
Cloud
(Free Tier)
Up to 1.6M retrievals/mo
2M writes. 5GB storage. 20M real-time messages. $0 embedding cost.
×1,600 more vs. Mem0
1k retrievals/mo
10K memories. Plus external embedding API costs.
No cloud option
No cloud option
Cloud
(@ ~$250)
Up to 33M retrievals/mo
20M writes. 10GB storage. 500M real-time messages. $0 embedding cost.
×660 more vs. Mem0
50k retrievals/mo
$249/month, fully managed
No cloud option
No cloud option
Persistence
Distributed via Fabric
Survives restarts, replicates to multiple locations
Cloud or self-hosted
Platform managed, or Docker (API + Postgres + Neo4j)
Local file
Dies with the agent process
Local file
Multi-agent sharing
Namespace isolation + shared pools
Per-agent, per-team, or global scoping
User/agent/session scoping
Supports user_id, agent_id, and run_id
No
Known memory bleed issues
No
Search
HNSW vector + attribute filters
Hybrid retrieval in a single query
Semantic + graph relationships
Entity extraction via Neo4j
HNSW vector search
Text match only
Also an app runtime
Unified Runtime (Harper)
DB, cache, API, messaging in one process
✕ Memory layer only
✕ Vector store only

// ECOSYSTEM

Plug into any agent stack.

Cortex connects to the tools and frameworks your agents already use.
// GET STARTED

Three steps. Five minutes.

1

Create a Free Fabric Cluster

Cortex runs on Harper Fabric, a distributed application runtime with built-in vector search. Create a free cluster in under a minute. No credit card required.
Create Free Cluster
White arrow pointing right
2

Deploy Cortex

Clone the Cortex repo, add your cluster credentials, and deploy. This sets up memory tables, vector indexes, and API endpoints on your Fabric cluster. Embeddings run server-side via ONNX, no external API key needed.
# 1. Clone the repo and install dependencies
git clone https://github.com/HarperFast/Cortex.git
cd Cortex
npm install -g harperdb
npm install

# 2. Add your Fabric cluster credentials
cp .env.example .env
# Edit .env → add cluster URL, username, and password
# Anthropic key optional (for memory classification)
# Embeddings run locally — no key needed

# 3. Deploy to your cluster
npm run deploy

3

Connect Your Tools

Cortex is running. Now install the package that matches how you work. An SDK for custom code, an MCP server for AI-assisted editors, or a plugin for agent frameworks.
SDK — for custom agents and backend services.

# 1. Install
npm i @harperfast/cortex-client

# 2. Store and search memories
import { CortexClient } from "@harperfast/cortex-client";

const cortex = new CortexClient({
 url: "https://your-cluster.harperdbcloud.com",
 token: "your-auth-token",
});

// Store a memory
await cortex.memory.store({
 content: "Harper Fabric replicates writes across regions via MQTT, so Cortex memories stored in us-east are immediately available in eu-west without a separate sync layer",
 source: "architecture-decision",
});

// Search by meaning — not keywords
const results = await cortex.memory.search({
 query: "how does memory sync work across regions",
});
MCP Server — for Claude, Cursor, Windsurf

# 1. Install
npm i @harperfast/cortex-mcp-server

# 2. See the setup guide for your editor
# → https://github.com/HarperFast/Cortex/blob/main/packages/cortex/docs/mcp-setup.md
OpenClaw Plugin — drop-in memory for OpenClaw / NemoClaw

# 1. Install
npm i @harperfast/openclaw-memory

# 2. See plugin docs for configuration and lifecycle hooks
# → https://github.com/HarperFast/Cortex/tree/main/packages/openclaw-memory
Explore Ecosystem
White arrow pointing right
// DEPLOY TODAY

Give your agents a brain.

Open source. Free on Harper Fabric. No credit card.