GrepMem: Plain-Text Log Plus Regex Beats Summarization for Long-Horizon Agents

dair_ai · x · 2026-11-20

USC researchers introduce GrepMem (paper: "Forget Freely, Grep Later"), a lossless, index-free memory mechanism for long-horizon LLM agents: keep the agent's full history as an append-only plain-text log and recall on demand with a regex search tool — no embeddings, retrieval index, or extra model.

Key results (RL-trained Qwen3.5-9B under five context strategies):

Why it works: summarization decides what to keep before the agent knows what it'll need later; the log keeps everything and search finds details on demand. A plain-text log plus grep is a simple yet competitive alternative to structured memory systems.

Original post →

More from coding & agent

coding & agent channel →