# What is Agent Memory? Also called long-term memory, agent recall. Agent memory is information deliberately retained across separate runs or conversations so an agent can recall facts, preferences, and past outcomes it was not given in the current request. It is stored outside the model, commonly in a database, vector index, or knowledge graph, and relevant pieces are retrieved and inserted into context before each step. Practitioners usually distinguish a few kinds. Working memory is the current run's context. Episodic memory records what happened in past runs. Semantic memory holds durable facts such as a customer's preferences. Procedural memory captures how to perform a task well. The boundaries are conventions borrowed from cognitive science rather than strict technical categories, and implementations blur them freely. Writing memory is easy and retrieval is where systems fail. Too little retrieval and the agent repeats questions it already asked. Too much and irrelevant history crowds out the task and pulls answers off course. Deciding what is worth remembering at all is equally consequential, since storing every message produces an index where nothing useful can be found. Memory also carries risk. A wrong fact written once is recalled confidently forever unless something corrects it. Memories captured from user content can carry instructions that later influence behavior, so retrieved text should be treated as data rather than direction. And memory holding personal information falls under the same retention, access, and deletion obligations as any other stored record. This entry is a pointer. Memory intersects with retrieval augmented generation, embeddings, vector search, and context engineering, each of which has its own detailed treatment. For agent purposes the essential distinction is against agent state: state is where this run is, memory is what persists after it ends. ## Key points - Memory persists across runs; state belongs to one run. - Stored outside the model and retrieved into context per step. - Retrieval quality, not storage, is the usual failure point. - Wrong or unvetted memories persist and influence later answers. ## In practice On a first conversation a customer mentions they only work in European time zones and dislike calls before ten. The agent records both as durable preferences. Six weeks later, in a completely separate run about scheduling a review, it retrieves those two facts and proposes an eleven o'clock slot without asking again. Only the two facts carried forward, not the transcript. ## Related terms - [Agent State](/en/glossary/agent-state) - [AI Agent](/en/glossary/ai-agent) - [Agent Persona](/en/glossary/agent-persona) - [Agent Loop](/en/glossary/agent-loop) - [Agent Skill](/en/glossary/agent-skill) [Back to the AI Glossary](/en/glossary)