Skip to content
AI Skills Central

Type to search Agent Skills, workflows, tutorials, tools and the glossary.

Agent memory

Topic: AgentsAlso called long-term memory

Definition

Information an agent keeps beyond a single context window, such as user preferences, past decisions or task notes, and retrieves when needed.

In more detail

A model remembers nothing between calls, so memory is something the harness builds. Short-term memory is the conversation in the context window. Long-term memory is stored outside it: files the agent writes and reads, like CLAUDE.md or a notes file, a database of extracted facts, or a vector index searched by similarity.

The hard parts are deciding what is worth remembering, updating facts that change, and keeping memory from filling up with stale or wrong entries that mislead later runs. Tools such as Mem0 and Letta specialise in this; many coding agents use plain Markdown files the agent maintains.

  • Compaction

    Summarising earlier parts of a long conversation and replacing them with the summary to free context space for the work still to do.

  • Context engineering

    Deciding what information, tools and history a model sees at each step, and what to leave out, to get the result you want.

  • Context window

    The maximum number of tokens a model can consider in one request, covering both the input you send and the output it writes.

  • Retrieval-augmented generation (RAG)

    Retrieving relevant documents and adding them to the prompt before the model generates an answer from them.

  • Agent harness

    The software around a model that turns it into an agent: the loop, tools, prompts, context management, permissions and limits.

  • Mem0

    Memory layer that extracts facts from conversations and retrieves them later.

    Tool

  • Letta

    Platform for stateful agents that keep long-term memory across sessions.

    Tool

  • Context engineering

    Deciding what instructions, documents, tools and history a model sees at each step.

    SkillIntermediate