An architecture pattern for building AI agents with persistent memory, self-correction, and multi-terminal continuity. Not a library or a framework you install — a blueprint for agents that actually learn from experience, share context across sessions, and operate autonomously when you're not watching.
The Problem
Every conversation with an AI starts from zero. Your agent doesn't remember what it learned yesterday, repeats the same mistakes, and loses all context when the window closes.
The industry's answer is RAG and vector search — bolted-on memory that retrieves but doesn't learn. Real persistence means an agent that corrects its own behavior, shares context across terminals, and operates autonomously when you're not watching.
This framework is the architecture I built to solve that.
What It Does
Six primitives that turn a stateless LLM into a persistent, self-correcting operational agent.
Persistent Identity
Soul files, behavioral directives, and emotional state that carry across every session. Your agent doesn’t just remember facts — it remembers who it is, what it values, and how it should behave.
Self-Correcting Behavior
Structured mistake logging with pattern detection. When the same error appears three times, it automatically promotes to a behavioral directive. Agents that fix their own failure modes.
Multi-Terminal Continuity
Session handoffs through a shared database. Start a conversation in one terminal, pick it up in another. Every instance has access to what every other instance learned.
Autonomous Operations
Daemon jobs, scheduled tasks, and proactive messaging. Your agent works when you’re not watching — monitoring, processing, and reaching out when something needs attention.
Knowledge Graph
A weighted graph with signal scoring, heat decay, and typed edges. Not flat memory — structured knowledge that strengthens connections through use and prunes what’s no longer relevant.
Agent Hierarchy
Multiple agents with different roles, shared infrastructure, and clear authority boundaries. A senior agent that delegates, subordinates that specialize, and a persistence layer they all share.
Under the Hood
The persistence layer is Supabase with PostgreSQL and pgvector. A knowledge graph with signal scoring, heat decay, and typed edges replaces flat memory. Session handoffs are structured database rows, not prompts stuffed into context. Behavioral directives live in a soul table that every instance reads on boot.
Agent communication runs through Telegram and Discord. Daemon jobs handle autonomous operations. The whole system is designed around Claude Code as the runtime — but the architecture is model-agnostic. Swap the LLM, keep the persistence.
Build agents that actually persist.
Open source. Production-tested. Ready to fork.