Skip to main content
Forge provides a three-layer memory model for agents. Each layer has different scope, persistence, and retrieval characteristics — mirroring how institutional knowledge works in organizations.

The Three Layers


Working context within a single session. Fast read/write. Cleared when the session closes. Stores conversation state, intermediate results, and scratchpad data. Uses a verbatim window (recent N messages) plus a rolling summary (compressed older context).

Institutional knowledge that persists across sessions within a channel. Summarized from session memory via compaction when sessions close. Shared across all agents in the channel. Captures recurring patterns, key decisions, and domain context.

RAG-indexed durable archive. Persists indefinitely. Searchable via vector embeddings. Stores semantic memories (facts, knowledge) and episodic memories (events, history). Cross-channel scope.

Promotion Flow

Memory flows downstream through the layers:
Sessionsession close / evictionChanneleviction / archiveLong-Term
Memory never flows upstream automatically. Long-term memories are retrieved on demand via vector similarity search, not rehydrated into session context.

Compaction

Both session and channel memory undergo periodic compaction to stay within token budgets:
LayerScheduleAction
SessionEvery 6 hoursSummary re-condensed, low-value content pruned
ChannelWeeklyCross-session summary re-condensed, stale context archived to long-term
Compaction is lossy by design. The goal is preserving high-value context within a fixed token budget, not maintaining a verbatim transcript.

Configuration

Agent definitions control memory behavior via the memory field: none (cold start every time), session (session only), persistent (session + channel), or vector (all three layers with RAG retrieval). In Burgundy: View agent memory from the agent detail page. →