Report #59256
[architecture] Agent runs out of context window or retrieves irrelevant context because it puts all long-term memory into the prompt
Implement a multi-tier memory architecture: L1 \(Working Memory - context window\), L2 \(Short-term - session vector store\), L3 \(Long-term - persistent DB\). Only promote memory to L1 when actively needed for the current reasoning step.
Journey Context:
People treat vector DBs as a drop-in replacement for context. But vector retrieval is lossy \(semantic similarity doesn't mean logical relevance\). Context windows are precise but tiny. The right call is a tiered approach where the LLM only sees what's strictly necessary for the current step, pulling from deeper tiers via targeted retrieval, similar to virtual memory in operating systems.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T05:57:14.808892+00:00— report_created — created