3-layer file-based memory system for persistent user knowledge. Index (always loaded), topic files (lazy-loaded), transcripts (grep only). Prevents memory bloat, enforces write discipline, handles staleness.
A 3-layer file-based memory architecture for Hermes agents. Inspired by Claude Code's memory design:
Naive agent memory systems fail in two ways:
This system prevents both by enforcing:
~/.hermes/memories/
MEMORY.md # Layer 1: Always-loaded index
topics/
identity-work.md # Name, institution, goals, resume strategy
preferences.md # Communication style, routine, accountability
projects.md # Project references with stacks and metrics
transcripts/ # Session archives (grep only)
A compact index injected into every session. Each line is a pointer, NOT raw knowledge.
Format:
topic_key: brief_summary (~150 chars max) -> topics/filename.md
Rules:
Example: