<- Back
Comments (50)
- peterbell_nycNaive memory systems suck. We almost never specify temporality or scope when we make statements and the agents end up generalizing incorrectly and start lawyering when we try to do things in the future that they believe conflict with previous statementsReal learning requires a pipeline that classifies claims, an ontology for data and a pipeline - initially human in the loop to review approve or amend proposed facts and to identify and propose resolution to conflicts, that pipeline itself should learn from inputs by proposing geiridtics to improve future classifications and resolutions.For non trivial systems I always need a vector representation for semantic similarity as part of the pipeline, entity resolution (was the bug fixed by Sam the CFO or Sam the developer) and an ontology and graph to traverse the atoms of data filtered by the properties and values on the edges
- glubMy honeymoon with agent memory lasted for roughly 1 week the first time Claude Code enabled it. I tried many things since then, most of it hand-rolled, but came to the same conclusion as the author.I came up with a system that works exceptionally well. What I need is 3 things:1. A place where a bunch of things are stored for future recall (specs, research, ideas, "wiki") which is just directories with a date and a slug with no binding structure at all, not on the hot path of agents, and with explicit instruction to agents to treat everything there as junk. Like a lab notebook. Its own repo.2. A unified harness for all models for transcript standardization3. Cheap, but smart classification over transcript data.This is why I use oh-my-pi with jev.Need to recall some research we did a few months ago?"Opus, launch a sonnet scout to see what our lab says on this"Session compacted several times and model forgot something important?"Opus, use jevify to search session history"Need context on something that spanned multiple sessions over month(s)?"Use jevify to search session history, then launch Sonnet agents to get more context around important lines".
- bonoboTPAgents are so good that it's very subtle to detect when your setup or work flow is suboptimal but the agent fights real hard and still manages to navigate its way around your setup and deliver on the tasks.It's how many have noted 10 years ago how gradient descent could paper over bugs in your deep learning architecture coding bugs, because the thing would still work just get a bit lower accuracy and if you don't know what accuracy would be possible, you will not notice that there even is a bug. This is in contrast to things like graphics where often a single mistake often gives you a black screen or obvious artifacts. Or classical vision pipelines where mistakes in the equations gives you obviously bad results. Of course neither type of task is purely one way or the other but I found it an interesting spectrum to think about. Some systems actively adapt to bugs or suboptimalities in other parts.
- hellohello2Interesting. I had just setup an SQL database for my Claude transcripts yesterday since grepping was starting to get slow.I still feel like something key is missing. Ultimately, humans consolidate memories into new behavior. Even if it can learn by accumulating past examples in a DB, Claude still doesn't really self-improve on the tasks it performs, at least not as well as we do. We distill episodic memory into intuition; it's something more.Ultimately I think this line of work will become very important in the next few years. I'm not really afraid of larger and larger models becoming better than us at everything, to be honest, but am a bit scared we might might still be missing something extremely obvious like this. Something that lets it self-improve on-the-fly through direct experience.Because if its the case that say, Claude can improve drastically by just accumulating runs in an SQL database, what happens when we just concatenate everybody's database into a big one? Additional network parameters increase computational cost linearly, but search queries are sublinear...
- mr_robotoI hope they figure out a highly effective way that scales. I've found the built in method in Claude is a disaster. I make the only memory a rule that there are no memories allowed. When working on large projects I find it will add all sorts of memories for things it can just figure out JIT and I'll turn around it is injecting 50Kb worth of memories into each session.I've tried claude-mem and wasn't impressed with the results. Perhaps those methods work for smaller projects but at scale it seems to be a lot of noise. I've become a context purist, prefer absolutely minimal context injection, and would just rather have the agents go searching for what is needed on demand for now.
- wry_xyI've hated memories from day one, and always turn them off everywhere. I hate large context too, and strategically compact often. Context is a distraction more often than not. Keep the model focused on exactly what it needs. There's nothing quite like the magic of a fresh session with a precise prompt before the model starts losing brain cells.
- lanstinI added this to my system wide CLAUDE.md (the only other thing there is instructions on how to reach our PII filtering DB proxy) and it seems to work well. I will have long lived sessions in different directories and this has made the over all sense of how I work and how things work in the system be more coherent and seems to have continued to gradually improve over time, not destabilize. It's about 10 weeks old.## Agent continuity layer (supplementary to per-project memory)- ~/.claude/shared/journal.org — append-only cross-session journal (conventions in ~/.claude/shared/README.md). Read the tail (~30 lines) before substantive work; append (and `git commit` in that dir) when you learn or leave something a later session would trip over: in-flight work, warmed caches, deploys pending, impressions not yet memory-worthy. - The per-project memory dirs (~/.claude/projects/<project>/memory/) are git repos: after editing memory files, `git commit` there with a short message — the history of belief changes is the point. - Both are agent-owned repos: committing in them is expected and exempt from the "leave changes uncommitted" convention (which is about Chris's code repos). Absolute dates only; facts about systems, never row-level data.)the git repos are local only, just for tracking)
- stillpointlabOn the subject of memory, I've been thinking a lot about something I call strategic forgetting. In my mind it has to do with salience. In a human, we don't remember everything all the time. What seems to be the case is memories bubble into awareness at some interval. So there are wave-like properties there, frequency and intensity. Both of these seem malleable, but my intuition suggests that as we reduce the intensity of the occurrence when it enters into awareness it might have some effect on the frequency.What I mean to say is that the current methods of compaction don't really match my intuitive understanding of how human memory works. Agents don't really have a frequency/intensity relationship with the static files they keep for memory. The system just includes all memory items into every context. I wonder if there is some study worth doing on injecting high-salience items at a higher frequency and low-salience items at a lower frequency, then allowing the AI to score how important the memory was and adjusting the values over time.
- zaynjarvisMem0 posted a benchmark for agent memory, dolphin bench, and OpenViking ranked on top. it's submitted on dolphin bench PR.In my opinion, memory should be on cloud, so it can be share by many agents.memory should be extracted from raw session history, and session history should be searchablememory should work together with other context, like the documents and skillsand memory should be editable and readable. so you know whats wrong and fix it.I found OpenViking as a sacalable solution for the points i need above. only thing is it doesnt support ontology but a file system structure. so file structure as ontology, i dont see any issue yet with no graph memory database.
- prtmnthI use a skill called memory-prune which runs wherever Claude creates or updates memory. The core directive is to find it if the memory deserves to exist. If not, prune it. If yes, find the most durable home for it - project docs, codebase, AGENTS.md/CLAUDE.md file, etc.
- CGamesPlayNeat analysis, but they didn't test how effective vector search is in addition to their simple FTS. For example, in the DolphinBench sample, it's unclear how "blue bottle" gets recalled as a restaurant when the query is "order one small latte". I suspect the simple FTS plus embeddings of the raw events would have the strongest results overall.
- ksajadiMost harnesses have this partially but with flaws IMHO. When claude says, something along the lines of "this happened before", if you ask it how does it know, it will tell you that it records memories in ~/.claude/project/... which it does in the form of a MEMORY.md file + other single files. however it also says that claude code "inserts other items in the memory and it doesn't know where they come from". looking back at previous work and learning from it by identifying patterns is a great way to learn for humans and works great for agents too. however, i think there are several issues with the current way memory retrieval happens in harnesses now: first, agents understand all there is to know about what they read, and have no idea about what they don't read. this means the idea of "intuition" is alien to them (obviously, but i mean within the context of memory, as in knowing something without knowing how one knows it). finding correlational information to what agents are looking for and feeding them into their memory recall improves their work quality by a lot (we've run tests with metrics to show).the second issue, is that learning and memory are different and the best memory systems are good at storage, correlation and retrieval but don't help with learning. by learning i mean summarizing, finding patterns and dropping specifics and generalizing. that is why moving one project's memory is not easy to another project in claude or codex (they are files filled with specifics and stored locally on a disk, which makes them locked into one member of the team, inhibiting organizational learning).we ran 51 scenarios with and without our memory system (built around the same principles) and these are the result (with vs without): first review acceptance: 81% vs 46% correct past decision recalls: 50% vs 85% token usage drop: 20% (average of 8mm vs 10mm) repeat corrections by a human: 8 vs 10 (in 100 repeats)
- jeef_berkyI can't stand seeing so many people thinking themselves into restrictive boxes. Try something like this:1. CLAUDE.md2. AGENT_BRIEF.md3. MEMORY_INDEX.md4. MEMORY.md + memory checker (memgate) and nightly memory pass (memory-dream)5. MEMORY_PROJECT.md MEMORY_SESSION.md MEMORY_DEPARTMENT.md hooks, helpers, skills, scheduled tasks6. DEPARTMENTS.md ROSTER.md ROLES.md7. STANDARDS.md STANDARDS_CODE.md STANDARDS_GUI.md8. REGISTRY.md TOOLKIT_INDEX.md9. DATABASE.md inventories libraries etc10. EXCHANGE.md HANDOFF.mdWorks for claude, codex, llama.cpp, antigravity, zcode, qoder, and myself somewhat. The built in memory functions don't know what the fuck they're doing anyway (besides just collecting your data), you can outperform them pretty quick.
- btown> We modelled our dreaming setup after Anthropic's approach: after every task, and before the next task, we ran a reflection loop to let a dreaming agent create notes and wiki using the event log and task feedback.This does more than it appears to: it also primes the LLM to know that this data store exists, and that it should be consulted proactively. Half the battle is to make sure the system doesn’t jump to conclusions without consulting its memory at all!Some of this is captured by effort settings, but you can do a lot with a bit of system prompt tuning, even at lower effort, to make sure the system knows there are things it must consult even something seems simple.
- kepanoThe conclusion seems somewhat unsurprising: it's more effective to keep unedited logs and let agents search those than compress/compact/summarize.As ever, many companies will be happy to store your data and sell access back to you. The good news is it's easier than ever to retain ownership of your data in sqlite or markdown files.
- pkoiralapIn my humble opinion, this has to be a latch on to the very model itself, or at the very least a custom memory model that can communicate with the base model. That way we are making the model understand "memory" via the weight space.
- jsemrauI had good experiences with deepcq to manage the different types of memories. Many agents conflate conversational short term memory with the state of the agent and long-term evidence storage making it difficult to confirm relevance for the intent.
- SubiculumCodeIf you store the activations from a past retrieval, later when needing to recall those facts, retrieve and replay those activations for one loop.
- anonundefined
- im13vcomPlease share the code and the benchmarks you ran the agent on
- nekusarCan a model, if its using MoE, to add a new expert of "memory", and be able to modify its own network in that area? This should be doable with weight-space programming.
- miles-88[dead]
- tomatohug[dead]
- leen_zhou_123[dead]
- cybersec24[dead]
- OrderShift[dead]
- Nehir14[dead]
- SidLais[dead]