Skip to main content

Memory & Context

Memory is how Codebolt agents accumulate, retain, and retrieve knowledge — across turns, across sessions, and across projects. Context is what gets selected from memory and handed to the LLM each turn.

Two sides of the same system

SideWhat it doesDirection
Read pathContext Assembly Engine selects from storage and composes the promptStorage → LLM
Write pathMemory Ingestion pipeline captures, processes, and stores new informationEvents → Storage

Both sides operate on the same set of storage backends. Understanding which layer to use — and how to configure retrieval and ingestion — gives you direct control over what your agents know and how quickly they learn.

Storage layers at a glance

LayerLifetimeBest for
Working memorySingle turnScratchpad, intermediate notes
Episodic memorySingle runTurn history, short-term coherence
KV storePersistentPreferences, flags, small values
JSON storePersistentStructured records, config objects
Markdown notesPersistentHuman-editable long-form notes
Knowledge graphPersistentEntities, relationships, code structure
Vector storePersistentSemantic recall, similarity search
Event logPersistentAudit trail, searchable history

In this section

See also