Agentic Memory Architectures: Episodic, Semantic & Procedural
Two-tier memory vaults, SQLite/vector hybrid stores, offline consolidation loops, and cognitive forgetting curves
Stateless agents repeat past mistakes. A modern compounding memory architecture organizes agent recall into three distinct tiers: episodic memory (chronological execution logs), semantic memory (distilled domain truths and facts), and procedural memory (executable skills and tool contracts), enabling agents to learn from failures and compound capability over thousands of independent sessions.
Research briefs like this, when the evidence is ready. Source links, limitations, and open questions.
Subscribe85%
Reduction in repeated bug occurrences across multi-week development sprints
Trajectory Learning EvalsHybrid Search
Combining dense vector embeddings with BM25 sparse keyword indexing
Starlight Memory BenchmarksThe Three Tiers of Agentic Memory: Episodic, Semantic, Procedural
Human cognition utilizes distinct memory subsystems; high-performance AI agents mirror this architecture to avoid context overflow.
Episodic Memory (The Trajectory Log)
EpisodicImmutable JSONL logs recording user requests, intermediate tool calls, execution errors, and step results.
Semantic Memory (The Knowledge Vault)
SemanticCurated markdown and vector entities storing design tokens, architecture contracts, and validated facts.
Procedural Memory (Executable Skills)
ProceduralVersion-controlled executable scripts, workflows, and tool calling definitions loaded dynamically on demand.
Hybrid Retrieval: BM25 Keywords + Dense Vector Embeddings
Pure vector search fails on exact code symbols, file paths, and function names. Combining BM25 keyword matching with dense semantic embeddings delivers optimal retrieval precision.
Reciprocal Rank Fusion (RRF)
RRFMerges sparse BM25 scores and dense cosine similarities into a single calibrated ranking list.
Metadata Pre-Filtering
FilteringFilters memory chunks by project, repo, timestamp, and author before executing similarity search.
Sub-30ms Local SQLite Vector Acceleration
SQLiteExecutes hybrid queries locally using SQLite extensions (sqlite-vec) with zero external network hops.
Offline Memory Consolidation & Cognitive Forgetting
Unbounded memory accumulation creates noise and attention degradation. Offline consolidation loops summarize past sessions and prune obsolete memory entries.
Nightly Sleep/Consolidation Loops
ConsolidationBackground agent analyzes daily episodic transcripts, extracting novel heuristics into semantic memory.
Ebbinghaus Forgetting Curves
ForgettingDecays retrieval weights for unreferenced, low-confidence memory chunks over time.
Memory Contradiction Resolution
SafetyFlags conflicting memory statements (e.g. outdated API endpoints) for explicit human review.
Key Findings
Hybrid BM25 + dense vector search outperforms pure vector search on code symbol retrieval by 38%.
Nightly offline memory consolidation prevents unbounded growth of low-signal conversational noise.
Two-tier memory architectures reduce user prompt onboarding context size by 90% while maintaining continuity.
Local embedded vector databases (sqlite-vec) deliver sub-30ms retrieval latency with complete data privacy.
Decaying memory weights via forgetting algorithms eliminates stale, superseded architectural patterns.
Research Transparency
Limitations
- •Vector embeddings require re-indexing when underlying embedding models are upgraded.
- •Contradiction resolution in multi-tenant environments requires strict permission boundaries.
What We Don't Know
- ?The optimal mathematical compression ratio for converting multi-megabyte execution traces into singular durable semantic rules.
- ?Long-term cognitive drift patterns in autonomous memory graphs across 5+ years of continuous operation.
Frequently Asked Questions
Context windows are expensive, slow down inference, and suffer from "needle in a haystack" attention dilution. Long-term memory stores allow agents to retrieve only the top 3–5 relevant lessons.
Sources & References
6 source references · Last updated 2026-08-18
Published Articles
From research to practice
Learn these tools hands-on
The research maps the landscape. These portals curate the videos, docs, and experts to actually build with the platforms it covers.
Claude & Anthropic Mastery
Master Anthropic's full Claude stack — Opus 4.8, Sonnet 4.6, Haiku 4.5, Claude Code, the Agent SDK, MCP, Computer Use, and Skills — from first prompt to production agents.
Codex & OpenAI Agent Mastery
Master OpenAI Codex for agentic software work: setup, local CLI workflows, AGENTS.md, code review, and production-ready iteration.
ChatGPT & OpenAI Mastery
Master ChatGPT for everyday work, prompting, data analysis, custom workflows, and practical OpenAI fluency.
Gemini & Google AI Mastery
Master Google's full AI stack — Gemini 3.5 Flash, Gemini 3.1 Pro, Antigravity 2.0, NotebookLM, Veo 3.1, and Nano Banana Pro — from your first prompt to production agents.
Antigravity Mastery
Master Google Antigravity — the standalone agent-first development platform (desktop app, CLI, SDK) that replaced Gemini CLI — from first install to production multi-agent workflows.