agentskit.js

createHierarchicalMemory

Auto-generated API reference for createHierarchicalMemory.

Function: createHierarchicalMemory()

createHierarchicalMemory(options): HierarchicalMemory

Defined in: hierarchical.ts:66

MemGPT-style tiered memory. Three tiers:

  • working: always-loaded hot window (bounded by workingLimit).
  • recall: mid-term searchable layer (usually a vector store).
  • archival: cold store that always holds the full conversation.

On every save, new messages are appended to archival, messages that overflow the working window are indexed into recall, and the working tier is trimmed to workingLimit.

On every load, the hub returns working + up to recallTopK messages surfaced by the recall tier, spliced chronologically.

#Parameters

#options

HierarchicalMemoryOptions

#Returns

HierarchicalMemory

Explore nearby

✎ Edit this page on GitHub·Found a problem? Open an issue →·How to contribute →

On this page