KAPEX Beta
getkapex.ai GitHub

How KAPEX Is Different

Every team building with LLMs eventually hits the same wall: the model forgets everything between sessions. There are several approaches to solving this. Here is how KAPEX compares to each of them, and when it is the right choice.

KAPEX vs. RAG (Retrieval-Augmented Generation)

RAG systems retrieve chunks of static documents and inject them into the prompt. They work well for knowledge bases, documentation, and factual Q&A. But RAG has no concept of importance or time.

Aspect RAG KAPEX
Data source Static document corpus Living conversation history
Retrieval signal Semantic similarity to query Multi-signal salience scoring + recency + constraints
Temporal awareness None -- all documents are equally "current" Built-in decay -- memories fade unless reinforced
Relationship modeling None -- chunks are independent Entity graph with domain hierarchy and edges
Scoring Cosine similarity only Five linguistic signals combined into a salience score
Update model Re-index documents on change Continuous -- every conversation updates the graph

When RAG is better: You have a fixed corpus of documents (product docs, legal filings, research papers) and need factual retrieval. RAG is simpler and purpose-built for this.

When KAPEX is better: You need to remember users across sessions -- their preferences, history, relationships, and evolving context. KAPEX builds a living model of each user, not a static index.

KAPEX vs. Vector Databases (Pinecone, Weaviate, Chroma)

Vector databases store embeddings and perform similarity search. They are a component of many RAG systems and can also be used for memory. But similarity is not salience.

Aspect Vector DB KAPEX
Core operation Nearest-neighbor similarity search Salience-scored retrieval with decay and framing
Scoring Distance/similarity (static after indexing) Dynamic score that changes over time (decay, spikes, reactivation)
Structure Flat vector space Hierarchical graph (Domain > Entity > Facet/Theme/Interest)
Temporal decay None -- vectors don't age Automatic decay with configurable rates
Context framing Raw text chunks Confidence-gated framing (assert / hedged / hook)
Safety None built in Crisis detection, trigger avoidance, PII scrubbing, topic suppression
GDPR compliance Manual implementation required Built-in node deletion, user erasure, topic suppression, data export

When vector DBs are better: You need fast similarity search at massive scale over millions of embeddings, and you will build your own scoring and lifecycle logic on top.

When KAPEX is better: You need a complete memory system with scoring, decay, safety, and compliance built in. KAPEX can use vector similarity as one retrieval signal alongside salience, recency, and constraints.

KAPEX vs. Context Window Stuffing

The simplest "memory" approach: concatenate the last N messages into the prompt. Some systems extend this by summarizing older messages or using sliding windows.

Aspect Context Window KAPEX
Capacity Limited by model's context window (8K-200K tokens) Unbounded graph -- only injects what matters
Selection Most recent messages (FIFO) Most important memories by salience score
Cross-session Lost unless manually persisted Automatic -- all sessions contribute to the same graph
Cost Token cost grows linearly with history length Fixed token budget (default 6000 tokens) regardless of history size
Relevance No filtering -- irrelevant messages consume tokens Three-channel retrieval selects only relevant context
Old memories Pushed out by newer messages Persist indefinitely; resurface when relevant via salience spikes

When context stuffing is better: Short-lived conversations (single session, fewer than 20 turns) where the full history fits in the context window.

When KAPEX is better: Multi-session applications where users return over days, weeks, or months. Context windows cannot hold weeks of conversation history, and even if they could, most of it would be irrelevant noise.

KAPEX vs. Custom Memory Solutions

Many teams build their own memory layer: a database of conversation summaries, a keyword index, or a hand-rolled scoring system.

Aspect Custom Build KAPEX
Time to production Weeks to months Hours (API integration)
Scoring sophistication Varies -- often basic keyword/recency Five-signal salience scoring with temporal decay and spike reactivation
Safety Must be built from scratch Multi-layer safety pipeline included (crisis detection, PII, triggers, validation)
GDPR/CCPA Must be implemented manually Built-in deletion, suppression, export, audit trail
Entity resolution Rarely implemented Three-tier NER with alias matching and cross-session resolution
Confidence framing Rarely implemented Automatic assert/hedged/hook framing prevents hallucination
Maintenance Ongoing engineering investment Managed service with scheduled decay, compression, and health monitoring

When custom is better: Your memory requirements are extremely specific to your domain and simple enough that a database table with timestamps covers it.

When KAPEX is better: You need a production-grade memory system and do not want to spend months building and maintaining scoring, safety, decay, compliance, and entity resolution yourself.

Feature Comparison Table

Feature KAPEX RAG Vector DB Context Window
Multi-signal salience scoring Yes No No No
Temporal decay Yes No No Implicit (FIFO)
Memory reactivation (spikes) Yes No No No
Entity hierarchy Yes No No No
Cross-session memory Yes Re-index required Manual Manual
Confidence-gated framing Yes No No No
Crisis detection Yes No No No
PII scrubbing Yes No No No
Trigger avoidance Yes No No No
Topic suppression Yes No No No
GDPR node deletion Yes Manual Manual N/A
User data export Yes Manual Manual N/A
Fixed token budget Yes (6000 default) Varies Varies No (grows with history)
Processing-modulated decay Yes No No No
Three-channel retrieval Yes No No No
Post-generation validation Yes No No No

When to Use KAPEX

KAPEX is designed for applications where long-term user relationships matter. It is the right choice when:

Therapeutic and Clinical Applications

Users disclose sensitive information across many sessions. KAPEX remembers what matters, avoids triggers, detects crisis signals, and never fabricates details about a patient's history.

Education and Tutoring

Tutors need to remember what a student has learned, where they struggle, and what motivates them. KAPEX tracks these patterns across sessions and surfaces them when relevant.

Customer Support and Success

Support agents (human or AI) are more effective when they know the customer's history, preferences, and past issues. KAPEX provides this context without the customer having to repeat themselves.

Personal AI Assistants

Any AI assistant that interacts with the same user repeatedly benefits from persistent, scored memory. KAPEX handles the complexity of deciding what to remember, what to surface, and what to let fade.

Coaching and Mentoring

Coaches track goals, progress, setbacks, and breakthroughs across sessions. KAPEX maintains this longitudinal view and surfaces the right context at the right time.

When NOT to Use KAPEX