Skip to content
Guide8 min read

CoALA Explained: Working, Episodic, Semantic and Procedural Memory

A practical breakdown of CoALA (Cognitive Architectures for Language Agents): working, episodic, semantic, and procedural memory, the action space, the decision loop, and where the framework falls short.

**CoALA (Cognitive Architectures for Language Agents) is a conceptual framework published by Theodore Sumers, Shunyu Yao, Karthik Narasimhan and Thomas Griffiths in Transactions on Machine Learning Research (arXiv:2309.02427).** It organises any language agent along three axes: a modular memory system, a structured action space, and a decision-making loop. It is the reason the phrase "episodic memory" now appears in AI infrastructure marketing.

It is worth reading the actual paper. It is also worth understanding what it does not settle, because the field has largely adopted its vocabulary while skipping its caveats.

Why the paper exists

The framing is historical. Language models are production systems in the classical AI sense: they take text in and produce text out according to learned rules. Prompt engineering, in that reading, is control flow. Symbolic AI spent decades building cognitive architectures on top of production systems, and the authors argue that fifty years of that work applies to language agents.

The stated purpose is taxonomic. The paper describes its own use as looking backwards to survey existing agents and forwards to identify gaps. It is not a build recipe, and reading it as one is the most common mistake people make with it.

The formal shape

An agent in CoALA is:

  • M_w: working memory
  • M_lt: long-term memory, subdivided
  • A_i: internal action space
  • A_e: external action space
  • D: decision procedure

Memory is the part everyone quotes. The action space is the part that actually makes the framework useful, and it gets ignored.

The four memory types

The taxonomy comes from cognitive psychology, largely Tulving's work on distinguishing memory systems, with structural debts to ACT-R's split between declarative and procedural memory.

CoALA's taxonomy, and the category error it leaves unresolved.
CoALA's taxonomy, and the category error it leaves unresolved.

Working memory

Active state for the current decision cycle. Perceptual inputs, whatever knowledge has been retrieved or reasoned into existence, goals carried over from the previous cycle. In a real implementation this is your context window plus whatever variables your orchestration code holds.

Working memory is short-term by construction. Everything else is long-term and optional. An agent can have none of the three long-term memories and still be an agent under this framework.

Semantic memory

Facts about the world. The client is incorporated in Delaware. Water boils at 100°C at sea level. Storable as text, embeddings, or a knowledge graph; the framework does not prescribe.

The defining property is that a semantic fact makes a claim independent of when it was learned. That property is what makes it different from episodic memory, and as we will get to, CoALA does not push on it hard enough.

Episodic memory

Specific past events, with the agent as participant. When I tried approach X in March, the migration failed on a foreign key constraint.

Episodic memory is what makes an agent able to learn from its own history rather than only from its training data. The paper's example is Generative Agents (Park et al., 2023), which retrieves events using a combination of recency, importance, and relevance scores. That combination is instructive: pure semantic similarity is a poor retrieval strategy for episodes, because the most similar past event is often not the most useful one.

Procedural memory

How to do things. Skills, tool definitions, learned routines. This is the type that breaks the neat analogy, because CoALA locates procedural memory in two very different places: explicitly, as code and skill definitions the agent can read and write, and implicitly, in the LLM's own weights.

The paper's example is Voyager (Wang et al., 2023), which retrieves code-based skills from a skill library via dense retrieval and executes them in Minecraft. That is procedural memory you can inspect and version. Weights are procedural memory you cannot.

Practically: treat explicit procedural memory as code. Version it, review it, test it. The moment your agent starts writing its own tools, you have an unreviewed deployment pipeline.

The action space

Two halves, and this is where CoALA earns its keep as a diagnostic.

External actions interact with the world. The paper calls this grounding: API calls, filesystem writes, robot movement, sending an email.

Internal actions operate on the agent's own memory. Three of them:

  • Retrieval: reading from long-term memory into working memory. The paper is explicit that this can be rule-based, sparse, or dense. It does not have to be embeddings, and treating similarity search as the only option is a self-inflicted constraint.
  • Reasoning: generating new information into working memory from what is already there.
  • Learning: writing to long-term memory. Committing an episode, updating a fact, adding a skill.

Here is the useful part. If an agent has no semantic or episodic memory, it structurally cannot have retrieval or learning actions. The paper works through this: ReAct has reasoning and grounding but no long-term memory, so no retrieval and no learning. SayCan has procedural memory only, with an external action space of a fixed set of grounding skills and no internal actions at all.

You can run this diagnostic on your own system in about ten minutes and it usually finds something. Most production "agents" have grounding, some reasoning, and no learning action whatsoever. They act on the world and never write anything down. That is not an architecture choice anyone made deliberately; it is what you get by default.

The decision loop

Each cycle has two stages.

Planning. The agent uses reasoning and retrieval to propose candidate actions, evaluate them, and select one. This can iterate.

Execution. The selected learning or grounding action runs, changing either internal memory or the external world.

Propose, evaluate, select, execute. The loop is deliberately generic, which is the point: it describes a single Copilot autocomplete and a multi-hour agent session equally well.

Where CoALA falls short

Three criticisms worth taking seriously.

It conflates the persistence semantics of facts and experiences

This is the substantive one, argued in The Missing Knowledge Layer in Cognitive Architectures for AI Agents. CoALA files semantic and episodic memory under "long-term memory" with no formal difference in update mechanism, ownership scope, or decay behaviour.

But they behave nothing alike. Take two entries:

  • "LoRA achieves 95% of full fine-tuning quality" is a claim that should be superseded when better evidence arrives, with the old value retained so you can explain why the answer changed.
  • "The user corrected me about LoRA yesterday" is an experience that should decay unless it consolidates into a durable pattern.

Same architectural category in CoALA. Opposite correct behaviour. Apply episodic decay to your fact store and you lose knowledge you needed. Apply semantic permanence to your event log and it grows without bound while retrieval quality falls.

If you build one long-term memory store because the framework describes one, you have inherited a category error. This is the practical reason OctaMem implements semantic, episodic, and procedural memory as separate layers with separate update and decay rules rather than one store with type tags.

The taxonomy can be pure vocabulary churn

If your team already says "context window", "transcript", "RAG index" and "skills file", and everyone knows what those mean, renaming them working, episodic, semantic, and procedural memory buys nothing. It also breaks search across your existing docs.

The rename is worth it only when it changes behaviour: different retrieval strategies per type, different decay policies, different review requirements. If you adopt the words and keep one undifferentiated vector store, you have adopted a diagram.

The biology only goes so far

The authors are careful about this and their readers often are not. LLMs are not subject to biological limitations, as the paper notes. Human working memory holds a handful of items because of neural constraints that do not apply to a context window.

Designing memory consolidation to mimic sleep cycles because human memory works that way is inventing a constraint the medium does not have. The cognitive science is a source of useful distinctions, not a specification.

Using it as a checklist

The framework is most valuable as an audit. For your system, answer:

1. What is in working memory at the start of a cycle, and who put it there? 2. Do you have semantic memory? What happens when two facts contradict? 3. Do you have episodic memory? What is the retrieval strategy, and is it more than similarity? 4. Is procedural memory explicit and versioned, or hiding in weights and prompt strings? 5. Do you have a learning action at all, or does your agent only act and never record? 6. In your decision loop, what evaluates proposed actions before execution?

Question 5 catches the most systems. Question 2 causes the most production incidents.

Primary source: Sumers, Yao, Narasimhan and Griffiths, "Cognitive Architectures for Language Agents", TMLR / arXiv:2309.02427. Last updated 10 August 2026.

Frequently asked questions

What does CoALA stand for?

Cognitive Architectures for Language Agents.

Who wrote the CoALA paper?

Theodore Sumers, Shunyu Yao, Karthik Narasimhan and Thomas Griffiths, 2023. Published in Transactions on Machine Learning Research; preprint at arXiv:2309.02427.

What are the four memory types in CoALA?

Working memory (short-term active state), and three long-term types: semantic (facts), episodic (events), procedural (skills).

Is CoALA an implementation?

No. It is a taxonomy for classifying and comparing agents, not a build specification.

What is the difference between semantic and episodic memory?

Semantic memory holds facts independent of when they were learned. Episodic memory holds specific events the agent participated in. They need different update and decay behaviour, which is the framework's main unresolved gap.

Where does procedural memory live?

Either explicitly, as code and skill definitions, or implicitly in the model's weights. Only the first kind can be inspected or versioned.

Give your agents memory that persists.

Semantic, episodic, and procedural memory behind one API. Connect it once, and the knowledge stays.

Browse all articles