Token Efficiency Encyclopedia

Hierarchical Memory

Separate agent memory into layers of varying resolution. The model queries the appropriate layer based on the current task, keeping the active context small while preserving access to deeper history.

Layers

How It Works

When the agent needs context, it first checks working memory. If the information is not there, it queries episodic or semantic memory. This avoids inflating the prompt with irrelevant historical detail.

Trade-offs

See Also

Tools