Open Source · Apache 2.0 · Built in Rust · PostgreSQL-native

Context engineering
infrastructure for AI

Rust-native memory platform for LLM applications. One binary. One PostgreSQL database. Sub-5ms latency. Deploy in 60 seconds.

No Neo4j · No Qdrant · No Redis required · Just PostgreSQL

Built for the modern AI stack

RustPostgreSQL + pgvectorNATS JetStreamRedisDocker / KubernetesAny LLM Provider
<5ms
Gateway Latency
P95 measured
75%
LLM Cost Savings
7-layer optimization
10x
Smaller Footprint
vs Python alternatives
1
PostgreSQL
Only database needed

LLMs forget everything between requests.
Knol gives them context.

Context engineering is about assembling the right information at the right time. Knol automates this across every interaction.

01

Ingest

Feed conversations through the write pipeline. Knol extracts entities, relationships, and facts using LLM-powered analysis with 75% cost optimization.

02

Consolidate

Memories evolve from episodic to semantic knowledge. Duplicates merge, conflicts resolve automatically, and importance decays naturally over time.

03

Retrieve

Hybrid search fuses vector similarity, BM25 text matching, and N-hop graph traversal with intent-aware routing — all in under 5ms.

Why teams choose Knol

The only open-source memory platform that doesn't require Neo4j, Qdrant, or external vector databases.

PostgreSQL-only

Radical Simplicity

Everything runs on PostgreSQL + pgvector. No Neo4j for graphs, no Qdrant for vectors, no separate Redis for caching. One database to operate, backup, and scale.

Sub-5ms latency

Infrastructure-Grade Performance

Rust-native core delivers sub-5ms gateway latency and a 10x smaller memory footprint than Python alternatives. Starts in milliseconds, barely uses RAM.

75% cost reduction

LLM Cost Intelligence

7-layer optimization pipeline with prompt caching, batching, model routing, and deduplication. Cut extraction costs by 75% without sacrificing quality.

Everything you need, out of the box

Production-grade context engineering infrastructure with no assembly required.

Hybrid Retrieval

Intent-aware routing fuses vector similarity, BM25 full-text, and N-hop graph traversal using Reciprocal Rank Fusion. Sub-5ms latency.

Knowledge Graph

Automatic entity and relationship extraction from every conversation. N-hop traversal surfaces hidden connections across your data.

Memory Decay & Consolidation

Importance scores decay naturally over time. Episodic memories consolidate into semantic knowledge. Duplicates merge automatically.

Conflict Detection

Automatically detects contradictions between new and existing memories. Configurable resolution: supersede, skip, merge, or flag for review.

Four Memory Types

Episodic, Semantic, Procedural, and Working memory — modeled after human cognition for richer, contextually-aware AI responses.

Multi-Tenant Isolation

PostgreSQL Row-Level Security ensures strict data isolation. Each tenant sees only their own memories, entities, and graph data.

PII Detection & Guardrails

Built-in detection and redaction for emails, phone numbers, SSNs, and credit cards. Compliance-ready before you write any rules.

Webhook Event System

Real-time event dispatch for memory.created, entity.created, edge.created, conflict.detected, and more. Build reactive pipelines.

Async Pipeline

Writes return instantly. NATS JetStream handles extraction, embedding generation, graph building, and conflict detection in the background.

Write-Time Embeddings

Embedding generation happens at write time, not at query time. Every memory is searchable the moment it is stored.

Built in Rust

Memory-safe, zero-cost abstractions. Sub-5ms latency, 10x smaller footprint than Python alternatives. Starts in milliseconds.

Admin Dashboard

Web dashboard for API keys, rate limits, tenants, system health, and audit logs. Zero-downtime config changes via database.

Microservice architecture

Each concern in its own Rust service. Scale the pieces that matter. All talking to one PostgreSQL database.


  ┌─────────────┐      ┌──────────────┐      ┌────────────────┐
  │   Gateway    │─────▶│  Write Svc   │─────▶│  NATS Stream   │
  │  auth/rate   │      │  episodes    │      │  extraction    │
  └──────┬──────┘      └──────────────┘      └───────┬────────┘
         │                                            │
         │             ┌──────────────┐      ┌────────▼────────┐
         └────────────▶│ Retrieve Svc │      │   Graph Svc     │
                       │ vector+BM25  │      │  entities/edges │
                       │  RRF fusion  │      │  LLM extraction │
                       │  graph walk  │      │  conflict detect│
                       └──────────────┘      │  embedding gen  │
                                             └─────────────────┘

Cognitive memory model

Inspired by human cognition. Four memory types that mirror how people actually remember.

Episodic

Raw conversation events with full context, timestamps, and participant metadata. The foundation of memory.

Semantic

Distilled facts, preferences, and knowledge extracted from conversations via LLM-powered analysis.

Working

Short-lived session context that provides immediate conversational continuity within a session.

Procedural

Learned patterns, workflows, and behavioral preferences for deep personalization over time.

How Knol compares

The only open-source context engineering platform with hybrid retrieval, knowledge graphs, memory decay, and PostgreSQL-only architecture.

FeatureMem0ZepKnol
Vector semantic retrieval
Knowledge graph storage
Temporal fact validity model
Hybrid retrieval (vector + BM25 + graph)
Memory decay & consolidation
Conflict detection & resolution
N-hop graph traversal
Working/session memory layer
Procedural memory support
PostgreSQL-only (no Neo4j/Qdrant)
Built-in PII detection/redaction
Webhook event system
Multi-tenant RLS isolation
Open-source self-host

Complete SDK ecosystem

Six integration paths, all ready at launch. From raw REST to framework-native adapters.

🐍

Python SDK

pip install knol

Async Python

from knol import AsyncKnolClient
📘

TypeScript SDK

npm install @knol/sdk
🦜

LangChain

from knol.langchain import KnolMemory
🚢

CrewAI

from knol.crewai import KnolMemory
🔌

MCP Server

npx @aiknol/knol-mcp-server

Switch from Mem0 or Zep with confidence

Use migration tooling built for low-risk cutovers: schema mapping checks, replay utilities, and validation reports.

Import and normalize historical memory records
Replay events to validate retrieval quality before cutover
Generate a migration verification report for launch review

Open core, commercial operations

The full context engineering engine stays open source forever. We monetize managed reliability, security, and compliance.

Always Open Source (Apache 2.0)

  • All core services: gateway, write, retrieve, graph
  • Full SDKs: Python, TypeScript, LangChain, CrewAI, MCP
  • Hybrid retrieval, knowledge graphs, memory decay
  • Conflict detection, PII guardrails, webhooks
  • Docker Compose one-command deploy

Paid Cloud / Enterprise

  • Managed uptime, scaling, and automated backups
  • SSO/SAML/SCIM identity management
  • SOC 2 / HIPAA compliance controls
  • Admin dashboard with audit logging
  • SLA commitments and dedicated support

Integrate in minutes

Python SDK, TypeScript SDK, REST API, or deploy the full stack with Docker.

Python SDK
from knol import KnolClient

client = KnolClient(
    base_url="http://localhost:3000",
    api_key="your-api-key"
)

# Store a memory — extraction happens automatically
client.add(
    content="User prefers dark mode and concise responses",
    user_id="user-123"
)

# Hybrid retrieval: vector + BM25 + knowledge graph
results = client.search(
    query="What are the user's preferences?",
    user_id="user-123"
)

# Access the knowledge graph directly
entities = client.list_entities(user_id="user-123")
TypeScript SDK
import { KnolClient } from '@knol-dev/sdk';

const knol = new KnolClient({
  baseUrl: 'http://localhost:3000',
  apiKey: 'your-api-key',
});

// Store and search with the same clean API
await knol.add({
  content: 'User prefers TypeScript and functional patterns',
  userId: 'user-123',
});

const results = await knol.search({
  query: 'programming preferences',
  userId: 'user-123',
});
Quick Start
# Start the full stack in one command
docker compose up -d

# Or install the Python SDK
pip install knol

# TypeScript? We've got you covered
npm install @knol-dev/sdk

Built for AI teams

From solo developers to enterprise teams building production AI applications.

AI Agents & Copilots

Build agents that remember user preferences, past interactions, and evolving context across sessions. Full context engineering for autonomous workflows.

Customer Support

Give support agents full customer history, previous resolutions, and preference data. Reduce resolution time with contextual memory.

Healthcare AI

Maintain patient interaction history, treatment context, and care plan continuity. HIPAA-ready encryption and compliance controls.

Education Platforms

Personalize learning paths by tracking student progress, knowledge gaps, and learning style. Adaptive tutoring at scale.

Enterprise RAG

Combine document retrieval with conversational memory for context-aware enterprise search. Graph-enhanced results.

Multi-Agent Systems

Shared memory across LangChain, CrewAI, and custom agents. MCP server support for tool-use architectures.

Ready to give your AI persistent context?

Deploy the open-source stack in 60 seconds. Scale with managed cloud when you're ready.