cc-os/memory-systems-compared060326

327 lines
54 KiB
Plaintext
Raw Normal View History

Add Graphify setup & best-practices guide (11 docs + research) Research: dispatched 11 subagents to synthesize a creator interview into 11 standalone documents (overview, install, code/doc ingestion, backends, querying, token economics, workflows, best practices, and community tips), then reconciled cross-document contradictions against the GitHub repo (v0.8.30 release). Verified all substantive claims against primary sources (GitHub, interview, community, PyPI). Corrected interview errors: package is graphifyy (double-y), shell scripts now AST-supported, Slack/meetings/OneNote connectors are roadmap not shipped. Settled flag version disputes (--token-budget vs. --budget) by grepping raw README bytes. Applied honest token-savings framing (1–49x measured, not 70–90x marketing). Every claim tagged inline by source confidence ([github] / [interview] / [community] / [unverified]). Zero broken links, zero residual contradictions. Deliverable: docs/graphify/ - 00-README.md: index, reading order, provenance - 01-overview-concepts.md: god nodes, neuro-symbolic, vs. Obsidian - 02-installation-setup.md: install, register, first run - 03-ingesting-code-ast.md: tree-sitter, 33 languages, multi-repo - 04-ingesting-docs-knowledge.md: PDF/media/YouTube/Google Workspace - 05-local-models-and-backends.md: Ollama vs. cloud, privacy - 06-querying-and-god-nodes.md: god-nodes-first discipline - 07-token-economics-and-updates.md: savings honestly, --update, SHA hashing - 08-workflows-and-use-cases.md: onboarding, bug-trace, audits, second brain - 09-best-practices-checklist.md: do/don't reference + quick commands - external-tips.md: community tips, gotchas, savings debate Also included: graphify-interview (raw creator interview, source material), memory-systems-compared060326 (research reference).
2026-06-03 20:45:07 +00:00
Chapter 1: Intro: The 6 Levels of Claude Code Memory
0:00Right now, if you search for the best claw code memory system, you get absolutely buried. Mem zero, Carpathy's
0:066 secondsObsidian Wiki, Open Claw and Hermes, Mem Palace, Light Rag, Clawude Mem, Claw Mem. It's getting ridiculous to keep up
0:1515 secondswith it. But after spending hours researching it, these aren't competing tools. They're different ways of handling memory depending on your use
0:2222 secondscase. And the reason I went deep on this is because I've been building out my own agentic operating system. basically a business brain that runs across
0:2929 secondseverything I do. So, I needed to figure out what actually works, what scales, and what just adds complexity to my existing setup. So, in this video, I'll
0:3737 secondswalk through six levels of memory that build on top of each other, all the way to systems that work across every single AI tool that you use. So, by the end,
0:4545 secondsyou'll know exactly which one makes sense for your use case and which ones you can completely ignore. But before we go ahead through the levels, one thing I want you to know now because it will
0:5454 secondsmake the rest of the video easier to follow is that every memory system is answering exactly the same question.
1:001 minuteWhen you give claw code a task, how does it pull the right context at the right time? So the difference I'm going to show you between each level is just two
1:081 minute, 8 secondsthings. First is where your memory lives. So it's going to be the storage mechanism for your data and what the file structure looks like, whether it's
1:161 minute, 16 secondsmarked down or stored as vectors, for example. And secondly is how Claude actually gets hold of that data, which is just the retrieval stage. So some
1:241 minute, 24 secondsstuff's going to get copied into Claude's context automatically. Some stuff is going to sit in a database and get searched exactly when it's needed.
1:311 minute, 31 secondsSome stuff's going to live on your laptop. Some's going to live on the cloud, etc., etc. So let's jump now into level one. So you can think of level one
Chapter 2: Level 1: What Ships With Claude Code Natively
1:391 minute, 39 secondsas the native stuff that ships inside claw code. So most of you have already heard of the claw.md file. Some of you
1:451 minute, 45 secondshave heard of memory.mmd, but very few people are actually using both together properly. So, let's do claw.md first.
1:531 minute, 53 secondsAnd as most of you know this one already, I'll keep it quick, but it's effectively a plain markdown file inside your project folder where you store your rules, stuff about your brand, things
2:022 minutes, 2 secondsabout how you work with clients, coding style, and it's always loaded into every single session you pull up inside the terminal. You can think of it like a
2:102 minutes, 10 secondsnote that is just at the start of the context, almost like a system prompt that you're giving to Claude. So you can actually have this at the Claude project
2:172 minutes, 17 secondsfolder level to pass to all of your Claude instances. You can have it slightly lower at the root folder level if you have multiple projects which sit
2:252 minutes, 25 secondswithin the same folder. Or you can even have it in the individual project level for specific project instructions. The lower down the folder structure you go,
2:332 minutes, 33 secondsit still inherits the parent claude.mmd, but any conflicting rules, it will always take the local claw.md as gospel for specific project level instructions.
2:422 minutes, 42 secondsBut here's the thing that most people actually get wrong with their claude.md.
2:452 minutes, 45 secondsAnd I've seen this a lot, which is stuffing too much into the claude.md. So putting in your full brand guide, your tone of voice document, your complete
2:532 minutes, 53 secondsclient list. Think about when Claude actually starts a session every single time. It's going to burn through that context window reading all of it. So yes, it's important context, but only when you load it in at the right time.
3:033 minutes, 3 secondsAnd this is exactly the problem we're trying to solve called context ro. So this is the inability for AI and LLM models to actually recall 100% of the
3:123 minutes, 12 secondsinformation that we've loaded in as we increase the amount of context that's loaded in in the first place. So as a general rule of thumb, keep your claud
3:193 minutes, 19 secondsunder 200 lines. And then if you've got more context like a brand voice document then you can put that in a separate external file that's referenced from the
3:263 minutes, 26 secondsclaw.md and therefore it will only pull it in at the right time when it needs it. So the second built-in memory system inside claw code already running on your
3:343 minutes, 34 secondsmachine is called automemory and that forms a memory.mmd file. So you can jump into an existing project folder to see this best and what you can do is type in /memory.
3:443 minutes, 44 secondsYou'll hit enter and you'll see there are a few different things. There can be imported memory if you're using a separate memory system and we'll come to separate memory systems. You've got
3:523 minutes, 52 secondsproject and user memory which are effectively your claude.md files at different levels in the root folder.
3:573 minutes, 57 secondsWe're going to open up the automemory folder. You'll see that we have on a per project basis effectively a memory structure with an me memory file. So if
4:064 minutes, 6 secondsI open up all these files inside the memory MD file, we effectively have an index of lots of different memories that claw code can actually reference and
4:144 minutes, 14 secondsopen up other files of. So it's not just dumped a a huge amount of memories in here. What it's done is said on a project basis, we've got a specific
4:224 minutes, 22 secondsproject level feedback and on a more general scale, we've got a bunch of different feedback for specific things that it can refer back to kept as
4:314 minutes, 31 secondsseparate documents. It's following exactly what we've talked about, which is don't just dump more than 200 lines in a single file. Always reference a
4:394 minutes, 39 secondsseparate file and treat the memory MD or the claw.md as an index and then point to another file. So for example, we've got here a file that's feedback on
4:474 minutes, 47 secondsproject structure. So level two or three projects go under project/briefs.
4:524 minutes, 52 secondsAnd you can see separately we've got feedback project structure.md which is a specific bit of feedback that only needs to be loaded in when Claude understands
5:005 minutesthat we're looking at project structures table of contents of different bits of feedback that you've given it over time or it's understood from the way that you
5:085 minutes, 8 secondswork. Hence this file here on a specific project basis. And to demonstrate this further, I'll go to an empty folder. And you'll see that there's no memory. MD
5:175 minutes, 17 secondsfile or claude.md file inside that. So if I run the /memory command and I hit autoopen memory folder, then you can see
5:255 minutes, 25 secondsthat because it's done on a project level basis. There's no memory consolidation there. So you don't actually have to create that memory.md
5:325 minutes, 32 secondsfile. It's just quietly taking notes on your tasks and on your feedback in the background. And then it's created all those files as an index for me. So
5:395 minutes, 39 secondsclaude.md and memory. IMD is what Claude has today. And it's also very clear that Anthropic is trying to tackle this problem themselves. And that's evident
5:475 minutes, 47 secondsbecause when the Claude code source accidentally leaked a couple of weeks back, people found references to a system or framework called Chyros and
5:555 minutes, 55 secondshad a look through the code. And it's an unreleased always on demon that watches your project continuously, decides what's worth remembering, and then consolidates old notes while you sleep.
6:056 minutes, 5 secondsSo it's not in any public build yet, but for sure Anthropic in the background is working on features to actually solve this context rock problem and improve
6:146 minutes, 14 secondsthe native memory system. So it's only going to get better from this point. So level one, the setup is already done for you. It's in the background. It's
6:216 minutes, 21 secondscompletely free to use. You just need to be able to actually use them properly.
6:256 minutes, 25 secondsSo you might have noticed this if you keep repeating information to Claude that you think it should already know.
6:306 minutes, 30 secondsAnd that is where level two comes in. So level two improves the reliability of feeding those memory files in at the right time as well as improves the
Chapter 3: Level 2: Forcing Reliable Memory Recall
6:386 minutes, 38 secondsin-built structure inside cla MD. I found an article by a guy called John Connelly who's taken a concept by Pavl
6:466 minutes, 46 secondsHurin a huge name in tech who wrote this on the 18th of Feb. How to give claude code memory paste this into your projects claude. MD and bearing in mind
6:556 minutes, 55 secondsthis was before it was announced that Claude had this automemory feature but what it now does is effectively build on
7:027 minutes, 2 secondsthat structure of Claude and then when we combine it with John's we've got the ability to actually inject that automatically at the start of every
7:107 minutes, 10 secondssingle session. So basically what we're doing is we're adding in to the claude.md a big prompt all about how to manage memory and the rules in managing
7:187 minutes, 18 secondsmemory too structured memory system rooted atclaude/memory.
7:227 minutes, 22 secondsWe already saw our automatic memory system inside Claude, but instead we've got a structure here. We've got memory.mmd general.mmd which stores all
7:307 minutes, 30 secondscross project facts preferences environment setups but then we've also got domainspecific knowledge where we effectively have domain/topic
7:397 minutes, 39 secondsand each topic can have its own markdown file with domain specific knowledge one file per topic and the same with tools we can have individual tools like
7:477 minutes, 47 secondsslack.md with a specific tool config workaround edge cases for that specific tool and what this basically does is
7:557 minutes, 55 secondswe're going to add this to our claw md and we're going to go into plan mode.
7:587 minutes, 58 secondsWe're effectively going to get it to set up a memory structure for our project that we then can automatically inject into every single session. Now, this
8:078 minutes, 7 secondsworks using a claude code session start hook to ensure that when you open up that new terminal or even spin-off sub aents, it automatically loads the memory
8:168 minutes, 16 secondsor the memory MD index into session files. And if you've not used a hook before, it does exactly that. It's just a little script that basically says at
8:238 minutes, 23 secondsspecific moments like session start I'm going to inject that context into claude and we're not loading in the full context. We're just loading in the
8:318 minutes, 31 secondsmemory.mmd file which is that index if you remember. And the second most exciting thing about this is the potential for sharing this between
8:388 minutes, 38 secondsteammates. So imagine if you could sync those domain files that we talked about.
8:428 minutes, 42 secondsSo we have different products and different projects between your teammates. So if somebody's working on a different project, they can save memory files to do with that context in the
8:518 minutes, 51 secondsshared folder that we all can access inside our team. And the idea is it's specific granular detail that claw code actually needs to be useful for that
8:598 minutes, 59 secondsdomain or that tool. Now let's get it set up to show you exactly how it works.
9:039 minutes, 3 secondsSo what we're going to do is go to the link that I'll leave down below in the description under level one and we're going to copy this whole markdown section for part one. So basically
9:129 minutes, 12 secondsadding this to claw.md. What it's going to do is create a global memory directory structure which you'll probably have already based on claude's auto memory. We're going to update the
9:209 minutes, 20 secondsclaude.md file. We're going to initialize project memory.mmd files. And what it's basically looking out for is when I say reorganize memory, it's going
9:289 minutes, 28 secondsto read all the memory files. Remove the duplicates and outdated entries. Merge our entries that belong together. So basically consolidating our memories,
9:369 minutes, 36 secondssplit files that cover too many topics, restore entries by date, and update the memory. MD index. So every so often we're effectively going to be
9:459 minutes, 45 secondsreorganizing our memories. But first we just need to copy this into a prompt.
9:499 minutes, 49 secondsWe're not actually putting this directly in our claude.md file. What we are doing is opening up a new terminal window inside an existing project or an empty
9:569 minutes, 56 secondsproject. I've got my Aenttos demo project here. I'm going to switch mode using shift and tab twice to put it on plan mode. And I'm going to paste in
10:0410 minutes, 4 secondsthat entire prompt. What it's going to effectively do then is plan out a structure for our memory files and what to add to our Claude. MD file based on
10:1310 minutes, 13 secondswhat already exists and based on what already exists in our memory files. And once Claude has built the plan for part one, which was the one we copied in above, we're going to switch into plan mode again and run reorganize memory.
10:2410 minutes, 24 secondsSo, we're planning out this first. We're going to build it and then we're going to run reorganize memory with a plan to basically tidy up our memory files and
10:3210 minutes, 32 secondssee what it's built out of our previous project. So super simple. We're just going to wait for that to execute, check the plan, build it, and then execute the
10:4110 minutes, 41 secondsphrase reorganize memory to actually then push through all those changes. And you can see right now it's exploring the memory system state before it comes back
10:4910 minutes, 49 secondsto us with a plan. And it's come back to us with a plan structured persistent memory management system, setting up a global structured memory system for claw code so that knowledge persists across
10:5810 minutes, 58 secondssessions and projects. So currently our root claw.md exists but is empty. Claude memory does not exist and only one of
11:0511 minutes, 5 secondsour 28 projects has a memory/memory.mmd file. So you can see this has checked all the way up the parent tree to
11:1211 minutes, 12 secondsunderstand what exists at the highest level that will be inherited downwards.
11:1711 minutes, 17 secondsAnd the current project because it's a demo has an empty memory/ directory. No memory md. So it's going to create a
11:2411 minutes, 24 secondsglobal memory directory structure with general tools domain. It's going to update our claw.md
11:3111 minutes, 31 secondswith all five sections. Memory management, global memory, repo memory, auto init, which basically autocreates memory.mmd on a session start. And it's
11:4011 minutes, 40 secondseffectively going to go through all of our files and create that memory system and structure that we can then use to
11:4711 minutes, 47 secondsactually reorganize memory and basically set up a bunch of different domain and tool files. So, we're going to yes, clear context and bypass permissions and
11:5511 minutes, 55 secondsget it to execute on that. Then after that we will set up the ability to actually auto inject using the hook so that every time we load up a session it
12:0412 minutes, 4 secondsauto injects that memory index. So it's now built all of that. So it's created the global memory structure and you can
12:1112 minutes, 11 secondsactually commandclick into any of these files and we can see sync rules between global memories and project memories the
12:1912 minutes, 19 secondsstructure of the file and it's got the general andd the tools the domains. We can also see that got a uh cross project conventions like a general MD file and it's also done project memory.mmd file.
12:3012 minutes, 30 secondsSo on a specific project basis for all the projects we've done 28 projects it's created a specific memory MD file or consolidated that for that specific
12:3912 minutes, 39 secondsproject and you saw before that I didn't have any for previous projects except for the Aentic OS in which there was one
12:4612 minutes, 46 secondsmemory file. So what we need to do do now is just run reorganize memory. We'll make sure it's on plan mode and not bypass permissions mode. And it's going
12:5412 minutes, 54 secondsto come up with a plan to reorganize the memory and therefore it will start filling these memory MD and the claude.mmd files with the relevant
13:0113 minutes, 1 secondfolder structure outlined here. So we should see the general MD start to fill out the tools and the specific domain structure and it will tell us what it's
13:1013 minutes, 10 secondsactually going to create and then it will actually start creating that.
13:1213 minutes, 12 secondsWhilst that is happening, let's take a look at step two which is actually introducing the hook. So this hook basically injects your project memory
13:2013 minutes, 20 secondsand the global memory. MD index, if you remember that just points to the right memory files before the first tool call
13:2713 minutes, 27 secondsof every session. So this means that when you spin up an agent or a sub agent, it's going to basically throw in
13:3413 minutes, 34 secondsthat index so it knows what memories it has access to. And we're just going to copy this file here. And in summary, tells it to create the settings.json
13:4213 minutes, 42 secondsJSON hook that says when it's uh pre-tool use, make sure to run the pre-toolmemory.sh
13:5013 minutes, 50 secondsfile and it's going to create the pre-toolmemory.sh file, which is just the script to effectively load in the memory files that we've just created.
13:5713 minutes, 57 secondsAnd then it's going to go and update our claude.md to say instead of reading the claude/memory/memory md at session start, it's going to auto
14:0514 minutes, 5 secondsinject it this time. So it's not relying on Claude actually reading it and taking action. It's going to auto inject it automatically because this is a hook.
14:1314 minutes, 13 secondsAnd you can see after 5 days of usage for John specifically the number of memory files had increased significantly. So up 90% and
14:2114 minutes, 21 secondssignificantly more lines but it hasn't increased the memory. MD or general MD by a huge amount because those are just
14:2914 minutes, 29 secondsindex files pointing to the correct tools, the correct domains and the correct cycle files. So, I've asked it to reorganize the memory. And this is really brilliant. I'm just reading
14:3714 minutes, 37 secondsthrough this now. It's basically looked through my Aenttos folder and said it's
14:4314 minutes, 43 secondsfound 11 or 12, sorry, empty memory files, like daily memory files. So, there's an empty template, empty
14:5114 minutes, 51 secondstemplate, two empty sessions. So, it's saying actually, we just need to delete those because what's the point in having them? It's a waste of loading them in.
14:5814 minutes, 58 secondsSome identical first run onboarding empties. A bunch of empties there. And then part of phase two, it's basically going to trim the empty sessions. Phase
15:0615 minutes, 6 secondsthree, resolve stale open threads. So it's actually read through the specific threads in our daily memories and basically going to go and find exactly
15:1315 minutes, 13 secondswhat happened after those actions were taken to make sure that they're updated.
15:1715 minutes, 17 secondsAnd you can see it does this for a few different daily memory files. And then it's going to go through and actually add some cross references to all of these different projects that we've done
15:2515 minutes, 25 secondsto make sure that they link together correctly. It's going to update our general MD with all of these different projects that we've been working on,
15:3215 minutes, 32 secondsupdate the indexes inside the memory.mmd file, and then go through a verification phase to make sure that that all happens. So, we're basically going to run yes, clear context, and bypass
15:4115 minutes, 41 secondspermissions. It's going to make all those changes for us. And from this point onwards, we have a memory system that has a clear structure at our global directory. So, all verifications pass.
15:5115 minutes, 51 secondsIt deleted the 13 files, trimmed six sessions, finished the nine open threads, added 10 cross references,
15:5915 minutes, 59 secondsthree patterns were added to general.mmd.
16:0216 minutes, 2 secondsIt has remaining daily files of 12 with meaningful content, so it's got rid of the rubbish, and it's cleared all the empty memory directories inside the
16:1016 minutes, 10 secondsclient's folders. So now we're going to run the second prompt. And again, we're going to run it on plan mode, and then we're going to execute the plan to add
16:1816 minutes, 18 secondsto the settings.json. So that injects this every time we start a new session.
16:2216 minutes, 22 secondsOkay. So it's come up with a plan. It's going to basically register the hook in settings.json, update our global memory and claw.md so that it effectively has
16:3016 minutes, 30 secondsall of this knowledge that we're building into it. And that means everything will be executed automatically when a session starts. So for a lot of you, this will be enough.
16:3916 minutes, 39 secondsBut the moment you start running this for more than a few weeks, you're going to hit a couple of problems and your files are starting to get really messy.
16:4816 minutes, 48 secondsAnd the keyword search that works for a small amount of files using this system is going to stop working as we grow and
Chapter 4: Level 3: Search by Meaning, Not Just Keywords
16:5516 minutes, 55 secondsstart to scale. So this is where level three comes in. And this is where we start to get a bit more serious about how memory is actually organized and how
17:0217 minutes, 2 secondsit is searchable. But before we move on to that, YouTube tells me that 97% of you are watching this video right now
17:1017 minutes, 10 secondshaven't subscribed to the channel. So do me a quick favor and hit the subscribe button below if you've made it this far.
17:1617 minutes, 16 secondsSo only add to level two if these two things are true. One, you've been using Claude code for more than a month and
17:2317 minutes, 23 secondsyour memory files have grown past a handful of files. And two, if you've ever typed a question to Claude where you know the answer is somewhere in your
17:3117 minutes, 31 secondsnotes, but Claude couldn't actually find it, then it might be a sign to move on to level three. So at level two, we've got Claude loading memory more reliable.
17:3917 minutes, 39 secondsBut as you start to scale this, when you're running it for real for months across multiple clients or projects, the structure eventually stops scaling. So
17:4617 minutes, 46 secondsyou end up with a giant general MD file that can't be read efficiently. And because it's summarizing key topics and not taking words verbatim, the keyword
17:5517 minutes, 55 secondssearch starts falling apart as well. So level 3 is designed to solve both. And the template for level 3 comes from an AI agent that you're probably familiar
18:0318 minutes, 3 secondswith called openclaw. So the open claw file structure is effectively from that standalone open claw agent. It's not
18:1118 minutes, 11 secondsfrom claw code but their memory design system is something that's really genuinely powerful and clean. So it's got three different layers. First you have a memory MD which is your long-term
18:2018 minutes, 20 secondsdurable facts. So things that don't change often like your preferences, your decisions, facts about your business, and these are loaded in at the start of
18:2818 minutes, 28 secondsa recession. Second, you've got your daily note files. So you've got one file per date and you can think of these as a running log. What happened today, what
18:3618 minutes, 36 secondsgot decided, what got shipped, what didn't work, and it's basically today and yesterday's notes that get loaded automatically. And older ones are going
18:4418 minutes, 44 secondsto stay on the disc, but they're not going to get loaded into context. And then third, with open claw, there's an optional thing called dreaming. So it's a background process that's going to
18:5318 minutes, 53 secondsread through your daily notes, score them, and promote the ones that keep coming up again and again into your long-term memories. Memory MD. and the
19:0019 minutesstale stuff is going to get forgotten completely so it doesn't blow your context. So you basically then have a mechanism with a proper short-term
19:0719 minutes, 7 secondsmemory deciding with the dreaming process what is actually embedded into our long-term memory and fed into claude. So it brings us to a framework
19:1619 minutes, 16 secondscalled memsarch which is actually a plugin and it basically ports that framework from open core over to claw code. So it's built by a company called
19:2419 minutes, 24 secondszillus and that's a team behind one of the most popular open-source vector databases out there. So they know a thing or two about searching by
19:3219 minutes, 32 secondssemantics and searching by meaning and that's exactly what this is designed to do. So they've extracted open claw's memory architecture into a standalone
19:4019 minutes, 40 secondslibrary that plugs straight into claw code with a twoline install. So it's got all the benefits of the openclaw method which is the markdown first philosophy.
19:4719 minutes, 47 secondsSo everything we can go we can see we can read through and we can port it to different systems. It's got the same chunking strategy as open claw, the same
19:5519 minutes, 55 secondsfile structure with the memory.mmd and the daily notes, but now it works inside claw code too. And the way it works is it basically chunks your documents,
20:0320 minutes, 3 secondseverything you write into semantic vectors so that when we are actually searching for information, it's understanding the meaning behind our
20:1120 minutes, 11 secondsquestions and the meaning behind the stuff we've stored rather than just using keyword search. But it takes that one level further and applies a concept we've already seen already, which is
20:2020 minutes, 20 secondsactually hooks. So it auto injects the top matches into every single prompt. So as soon as we write a prompt, it's going to use a hook called user prompt submit
20:2920 minutes, 29 secondsand it's going to feed in our top three semantic matches from our memory files directly into the context for claw code.
20:3720 minutes, 37 secondsSo you don't have to remember to ask cla to search it. It's going to inject the most relevant parts of your memory files into the context pretty quickly as soon
20:4620 minutes, 46 secondsas you're actually typing in a query. So if you want to install this, we just need to take these two lines here. I'm going to go and open up a new folder and
20:5420 minutes, 54 secondsopen up cl code. And I'm just going to use the /plugin marketplace. Add zillastte mem search. It's going to find the repository and clone the repository.
21:0421 minutes, 4 secondsAnd we're going to choose to add this to our local folder so that we're not adding it above all the other memory systems that we're considering today.
21:1021 minutes, 10 secondsAnd then I'll grab the second line, plugin install memarch, and I'm going to install for you in this repo only like we just mentioned. And you can see it's
21:1821 minutes, 18 secondsspun up a settings.local.json file enabled plugins inside there and mem search plugins is true inside there. So
21:2621 minutes, 26 secondsyou need to run / reload plugins and that will help activate it. And we'll also just c twice and then reopen claw
21:3421 minutes, 34 secondscode. And then to actually verify it's working there's some GitHub instructions which I'll leave down below. We basically need to have a few conversations. So have a few
21:4121 minutes, 41 secondsconversations with it and then check your memory files. So to check your memory files, you just need to basically use the ls command inside a terminal, which is going to list whatever we're
21:5021 minutes, 50 secondsasking it to list. So mem search/memory files, and you should see today's date inside a memory file. So go ahead, have
21:5821 minutes, 58 secondsa conversation and then list and verify that that's working correctly. Or you can actually use the built-in skill that installs and that is uh memory recall.
22:0722 minutes, 7 secondsSo you can see me search, search and recall relevant memories from past sessions via mem search. So you can run that even as a slash command if you wanted to, but obviously we've got no
22:1522 minutes, 15 secondsdaily memory files yet. It will start from this point as we start building out conversations. And you can see it's using the hook user prompt submit and
22:2222 minutes, 22 secondsit's searching through the mem search files now. And this system is super similar to what we're actually using in our own Aentic OS to keep those daily
22:2922 minutes, 29 secondslog files as well as that long-term memory file that we can actually semantically push into the context at the right time. Now, there's another
22:3622 minutes, 36 secondsalternative worth knowing about, but in my opinion, not really as suitable for us called Claude MEEN. And it's a claude code plugin that automatically captures everything Claude does during your
22:4522 minutes, 45 secondscoding session, compresses it with AI, injects relevant context back into future sessions. So, sounds almost exactly the same, super popular, has a similar goal, but a different
22:5422 minutes, 54 secondsphilosophy. So, this uses MCP tools and a three tier storage model. So, it stores summaries, timeline, and
23:0123 minutes, 1 secondobservations. And it has more features than me search out the box. like it's got a little dashboard to actually search through the memories if you want.
23:0823 minutes, 8 secondsIt's got team collaboration features, cost tracking, privacy labels, but in my opinion, it's a bit overkill for what we actually need. So, if you want that
23:1623 minutes, 16 secondsmanagement layer on top of your memory, then claude mem might be able to give you that. But for our use case, it's MCP based, which means Claude has to
23:2323 minutes, 23 secondsactively decide to call the search tool rather than just injecting it from a local database like me search. And the other major difference between claude mem and mems search is claude mem is
23:3223 minutes, 32 secondsactually going to store everything in the background whereas mems search is going to keep everything in plain markdown so you can actually go back and read it. So you've got auto injections
23:4023 minutes, 40 secondseverything in readable markdown and open clause great memory patterns without actually having to leave claw code. Now level four is where we get serious with
Chapter 5: Level 4: Recall Verbatim Conversations
23:4823 minutes, 48 secondsconversation recall. So word for word recall using a service called me palace or a framework called me palace. So, you
23:5623 minutes, 56 secondsonly need to go to this level if you catch yourself thinking, I know we discussed this a few weeks ago, but I can't remember exactly what was decided.
24:0224 minutes, 2 secondsSo, where level three finds our notes and a summary of those notes, level four is designed to find exactly the words that were used when you made a decision.
24:1224 minutes, 12 secondsAnd the best part about it is it's all stored locally on your system. So, compared to the other levels so far, this is a proper RAG system. It's free
24:2224 minutes, 22 secondsand right now it's got the highest benchmark score of any memory system ever published apparently. So because it stores words verbatim, nothing ever gets
24:3124 minutes, 31 secondssummarized. So nothing can actually theoretically get lost. So here are a few snippets from the website. You can see the content stays verbatim always.
24:3924 minutes, 39 secondsThe index above it is written in a a k a dense symbolic dialect and LLM can scan at a glance. So it's written in
24:4624 minutes, 46 secondseffectively a different language. And this is what it looks like. It's got a bunch of pointers that are pointing to locations of specific data. So you
24:5524 minutes, 55 secondseffectively are searching an index which is pointing to a specific area or draw as they call it inside the second
25:0225 minutes, 2 secondsdatabase and therefore it's able to go and retrieve that information straight away. So they've got an example here. My son's name is Noah. He turns six on
25:0925 minutes, 9 secondsSeptember the 12th. So this is what you'd say into the LLM. He loves dinosaurs, etc., etc. And the pointer is
25:1625 minutes, 16 secondsthen indexed as okay, Noah, son, age six, date of birth. And it stores a bunch of information in that drawer that
25:2425 minutes, 24 secondscan then basically point it directly to draw 007 inside wing 42 room 11. And
25:3125 minutes, 31 secondswe'll come to the importance of that structure in a second. But we can basically pull information out directly as it is stored. So when we are
25:3825 minutes, 38 secondssemantically searching for information, it basically uses this memory palace which is an ancient method of memory to
25:4625 minutes, 46 secondsstore things in wings, rooms, closets and drawers. And we just saw exactly that. The pointer of a wing represents people's projects and topics. The rooms
25:5425 minutes, 54 secondscould be days, sessions or threads. The closets could be topics, threads or bundles. And then inside that is the verbatim text. So it's got a series of
26:0226 minutes, 2 secondsnested bits of information that points it to the exact correct place. And that's how it's able to actually retrieve information or store
26:0926 minutes, 9 secondsinformation. And because it's stored in that symbolic index, the AA language, it lets the model scan thousands of draws
26:1726 minutes, 17 secondsin a single pass. And it happens super quickly. So you can see an example up here without me palace and with meal. So with me palace, it basically as soon as
26:2526 minutes, 25 secondsyou say something, it's going to go and file it in a specific draw. So wing room draw. Two weeks later when you ask it a question, you're going to see it's going
26:3326 minutes, 33 secondsto retrieve in such a quick time 42 milliseconds from that exact draw and it can even pull the verbatim text to. Now
26:4126 minutes, 41 secondsthis effectively uses two separate databases. An SQL database that tracks entities and relationships between them and a Chroma DB or a Chroma vector
26:5026 minutes, 50 secondsdatabase that stores every single conversation as searchable chunks as we've seen in the drawers. And similar to some of the previous levels, it's
26:5826 minutes, 58 secondsalso using background hooks to silently store and index information. So filing and indexing happen silently through
27:0527 minutes, 5 secondsclaw code hooks on session end. So we've seen the session start hook on session end on pre-ompaction. So if you're about to compact, it will also fire the hook.
27:1427 minutes, 14 secondsYou write it and the palace is going to basically put that information somewhere behind the curtain. Now it's super easy to install. You're basically building
27:2127 minutes, 21 secondsyour palace. One command to install. So, you're going to run the commands listed down here. I'll link down in the description below to the me palaceofficial.com. But you're going to
27:3027 minutes, 30 secondsbasically install it, initialize it, and it's going to create a palace structure, wings, rooms, drawers in a me palace
27:3727 minutes, 37 secondsfolder. It's going to register all the hooks in your settings.json file, and then it's going to start working. And you can even retrospectively mine your
27:4527 minutes, 45 secondsprevious information, your previous sessions by using this mine function. So at this level then with me palace Claude can literally search every single
27:5427 minutes, 54 secondsconversation you've ever had in plain English word for word because it's all going to be indexed in that memory palace file structure in the background.
28:0228 minutes, 2 secondsNow one of the downsides here is we don't have that verbatim in markdown. So it's not exactly readable directly but we can retrieve information easily and
28:1128 minutes, 11 secondsquickly in that way. But even now everything's still locked to your local machine. Everything we talked about so far most of it is locked on your local
28:1828 minutes, 18 secondsmachine. But what about the research you did in chat GPT 3 or 4 months ago, the brainstorming you did on your phone? So that's where level five and six come in.
28:2628 minutes, 26 secondsAnd they're totally different because it's not about remembering conversations anymore. It's about how do we actually have conversations across multiple tools
28:3528 minutes, 35 secondsand also reliably store research that connects all of our different information. So everything sits in an isolated drawer in this instance and
28:4328 minutes, 43 secondsactually none of the knowledge is connected. So let's move on to level five. So at this level for the me palace, Claude can literally search every single conversation you've ever
Chapter 6: Level 5: Build a Self-Organizing Knowledge Base
28:5128 minutes, 51 secondshad in plain English word for word because it's all index in your memory palace. But even now up to this point, everything's still locked into your
29:0029 minutesmachine. So what about the research you did in chatbt last year, the brainstorm you did on your phone the other day? That's where level five and six come in.
29:0829 minutes, 8 secondsAnd they're totally different. They're not about remembering conversations anymore. It's about building up a knowledge base across tools. So level
29:1629 minutes, 16 secondsfive is totally different actually. It's not anymore about remembering conversations. The me palace is kind of
29:2429 minutes, 24 secondsthe best the pinnacle of remembering word for word conversations. So now it's about actually if you want to build a
29:3029 minutes, 30 secondsknowledge base of interconnected information. So you want to add level five if you regularly consume
29:3929 minutes, 39 secondsinformation that you want to keep and connect over time. So think about articles, videos, podcasts, client notes, anywhere where you're actually
29:4729 minutes, 47 secondsjust reading a lot of information and losing track of what you actually learned. You can connect that all into a interconnected knowledge base. So it's
29:5529 minutes, 55 secondsless about one-off projects and more about building that second brain on topics that you actually care about. But to be honest, I'd skip this if you
30:0330 minutes, 3 secondsconsume content casually and don't need to come back to it later. The most popular library out there for this you might have seen already. It's Andre
30:1030 minutes, 10 secondsCarpathy's GitHub repo called LLM wiki or his markdown file which talks about the idea of LLM wikis and it's received
30:1830 minutes, 18 secondsa huge amount of coverage. So what makes it a bit different is that it's a pattern for using claude to build a living wiki about any topic that you
30:2630 minutes, 26 secondscare about. So you literally just create two folders inside your project. You create a raw folder where you drop your source documents which your articles,
30:3330 minutes, 33 secondsyour reports, your podcast transcripts, YouTube video transcripts, PDFs and Claude is going to read from this folder but never actually write to this folder.
30:4130 minutes, 41 secondsAnd then you have a wiki folder which Claude owns completely. So it's going to write every file, maintain the structure, update cross references as
30:4930 minutes, 49 secondsyou go and you never actually write yourself to the wiki. And the whole thing again is in just plain markdown files. So we don't have an external
30:5630 minutes, 56 secondsdatabase or a vector database. It's all in readable markdown files again. And all you effectively need are the files
31:0431 minutes, 4 secondsthat we've spoken about Obsidian and an AI. And effectively inside Obsidian, which is a separate software that you
31:1231 minutes, 12 secondscan download for free. Once you compile all of your resources, you'll get this knowledge graph of how your different resources interconnect. And you've
31:2031 minutes, 20 secondsprobably seen a ton of other people demonstrating this on videos. I'm not going to do a video specifically dedicated to this method because actually I don't think it's super
31:2731 minutes, 27 secondsrelevant for how we want to synthesize information and I think Donnelly in this article summarized it quite well. It's best in use cases where you have a
31:3531 minutes, 35 secondsfolder called save for later which is basically a pile of bookmarked Slack threads, YouTube videos, client notes that you never go back to that you want
31:4331 minutes, 43 secondsto see the interlinking relationships with and as it sounds effectively create a Wikipedia on a specific subject topic.
31:5131 minutes, 51 secondsSo this is if you want to do deep research on interconnected topics. But in my opinion, I can't see the directly applicable use cases for retrieving this
31:5931 minutes, 59 secondsinformation in this manner inside a system like the business OS or the Aentic OS. If you disagree with me, I'd love to hear why in the comments below. Maybe I've missed the point of this one.
32:0832 minutes, 8 secondsI can see some use cases like actually opening up wikis for specific key topic areas you're researching in and actually having those visualized and
32:1632 minutes, 16 secondsinterconnected. But in the way that we're using it for business use cases to build out projects, I'm not sure it's the best way to utilize a memory system
32:2432 minutes, 24 secondsapart from just doing deep research on a specific topic. I've also had a few people actually surface a similar alternative called recall because it's
32:3232 minutes, 32 secondsbeen blowing up online. So recall is a hosted service that's basically Karpathy's wiki, the LLM wiki done for
32:3932 minutes, 39 secondsyou. So you install a browser extension, you can save articles, you can save all your podcasts, PDFs, etc. and Recall
32:4632 minutes, 46 secondssummarizes, tags, and auto builds that knowledge graph for you without the the setup headache, but to be honest, it's quite easy to set up the LLM wiki for
32:5432 minutes, 54 secondsyourself. There's plenty of tutorials out there that can show you how. And Recall seems to give you its own AI chat interface, so you can actually go and chat to your saved content, so it works
33:0333 minutes, 3 secondson your phone. And they also have MCP access, so you can directly connect it to claw code. And this in some ways is better than LLM Wiki because there's
33:1033 minutes, 10 secondszero setup. You don't need to configure or download Obsidian and it's basically just available through a login and all the work is obviously done for you too.
33:1833 minutes, 18 secondsWhy I think it's not as good as Carpathy's pattern for most people. The first one is ownership. So you don't actually own the data. Recall lets you export everything to markdown if you
33:2733 minutes, 27 secondswant to. But while it's live, it's actually live on their servers. So you're effectively renting and not owning your own information. And secondly, Recall seems to be built for
33:3633 minutes, 36 secondscontent consumption, not operational memory. So, it would be really good for a use case like I've watched 40 YouTube
33:4333 minutes, 43 secondsvideos on blog code. Uh, which one talked about memory and what did they mention about memory? But it's not necessarily designed for what did we
33:5133 minutes, 51 secondsdecide about client X's landing page and the conversion rates back in March. And then thirdly, because it is a off-the-shelf software, there is a
33:5833 minutes, 58 secondspricing implication too with that. So, my take is if you're non-technical and you mainly want to organize articles, videos, and podcasts, then recall is
34:0634 minutes, 6 secondsgreat. But if you want maximum control and you still want to build out that Wikipedia, then the LLM wiki will definitely beat you there. There's also
34:1434 minutes, 14 secondsa quick mention for a heavyweight alternative which is similar like knowledge graph style called light rag.
34:1934 minutes, 19 secondsSo light rag is an enterprisegrade knowledge graph and it's designed for heavier entity extraction dual level retrieval the full research grade thing
34:2834 minutes, 28 secondsbasically but it's completely overkill for 99% of business owners. You don't need the setup headache. You don't need the massive database in the background
34:3634 minutes, 36 secondsfor that and you're better off either going back to level four or if you're looking for a visual knowledge base then you can install carpathies or use recall but to be clear I think both of these
34:4534 minutes, 45 secondsare for building knowledge bases not for operational memory and therefore it probably wouldn't be used in many of our own use cases apart from research so at
34:5334 minutes, 53 secondsthis point we've covered a huge amount and well done if you stuck with it so far but also up until this point everything lives inside core code and
35:0135 minutes, 1 secondsome of you may actually not just use core code you might use chatbt on your phone, you might use cursor. And when you start using multiple AI tools, none of them know anything about each other.
35:1035 minutes, 10 secondsSo everything we've installed so far has been inside CL code. But level six is a method I've seen called open brain by Nate Jones, who has brilliant knowledge
Chapter 7: Level 6: A Single Brain For ALL Your AI Tools
35:1835 minutes, 18 secondsin this space. And the intent of this is to actually allow you to switch between AI tools constantly like chat on your
35:2635 minutes, 26 secondsphone, claw code at your desk, and it's the only system today where all of your different AIs that you're using are able to see the same memory automatically in
35:3335 minutes, 33 secondsreal time. So arguably it's the most futurep proof and most portable because actually your memory for this is going to live in a Postgress database that you
35:4035 minutes, 40 secondsown. So when the next big AI tool drops in 6 months, say you just connect it to your existing Postgress brain and
35:4835 minutes, 48 secondsthere's no actual migration needed. But if you're still living mostly in Cycl code on one machine, then it's probably worth skipping this part. So it is what
35:5635 minutes, 56 secondsit says on the tin. It's an infrastructure layer for your thinking.
36:0036 minutesSo it's one database, one chat channel, and any AI you use can plug into it, which makes it super powerful if you
36:0736 minutes, 7 secondswork across apps. You're not connected to any SAS and it's super cheap to run.
36:1136 minutes, 11 secondsI think it's less than a dollar a month to run this. So it runs on a Postgress database hosted on Superbase and inside that database there's basically one
36:2036 minutes, 20 secondstable called thoughts and every row is a single memory. So it's a chunk of text an embedding vector to be able to search for it and some tags and an associated
36:2936 minutes, 29 secondstime stamp when it was said and then it uses in-built extensions that handle all that semantic search for you. So we basically have an MCP server running
36:3736 minutes, 37 secondsfrom claw code that connects up to superbas's edge functions that act as a front door for every ai tool that wants
36:4436 minutes, 44 secondsto read from the database. So if that's sounding a little bit complicated it's because one of the downsides of this it does have an AI assisted setup but it is
36:5236 minutes, 52 secondsgoing to take significantly longer to set up than some of these others and significantly longer to understand versus others here. So, you have a full
37:0037 minutessetup guide, which I'll link down below, or a video walkthrough on YouTube from Nate himself, as well as some companion prompts that help you migrate your
37:0837 minutes, 8 secondsmemories from existing Claw Code memory systems over to this open brain. And the idea is super simple and follows a lot
37:1637 minutes, 16 secondsof what we've seen so far. For retrieval, Claude Code is going to directly query it and chat is also able to query it. Claude Desktop is able to query it. Cursor is able to query it.
37:2637 minutes, 26 secondsThey all use just the same brain effectively. And I'm not going to set this one up live as it is probably overkill for most people, but I'll link to Nate's guide which is written for
37:3537 minutes, 35 secondsnontechnical people and you'll get through it if you want to do the setup in about 30 to 45 minutes. Now, there is a live community about this. So, I
37:4237 minutes, 42 secondsrecommend having a look in the GitHub and actually joining that community if you're interested in hearing more or getting some help with the setup there.
37:4937 minutes, 49 secondsBut if you're somebody that wants to actually keep your memory portable and not associated with just claw code, then this is probably the right solution for
37:5637 minutes, 56 secondsyou. Now, there is an alternative that I quickly wanted to mention here called Mem0ero. And it's another cross tool memory layer. It's wellunded. It's
38:0438 minutes, 4 secondsreally well marketed and widely used already by developers. And you can see like used by 100,000 developers from all
38:1138 minutes, 11 secondsof these large companies. So, if you wanted something that's more production ready strength, then definitely check out mem.ai. Especially because the setup
38:1938 minutes, 19 secondsis designed to actually just get you started in less than a minute and you still have a universal self-improving AI memory layer for your LLM applications and it's completely cross tool as well.
38:2938 minutes, 29 secondsSo if you're actually shipping an AI product for example, then this might be a sensible choice for you. But again, one of the downsides here is that your data is going to live on their servers
38:3838 minutes, 38 secondspermanently. Whereas something like open brain, you actually own the superbase project and you can export the whole Postgress database whenever you want and
38:4638 minutes, 46 secondscontrol access to multiple different tools. So in terms of level six versus all the different levels, this is probably the most complex to set up. Not
38:5438 minutes, 54 secondsmem, but open brain. And it's the only one really that's going to introduce significant costs per month. Although Open Brain, as we mentioned, is going to
39:0139 minutes, 1 secondbe like 10 to 30 p per month on the free tier of Superbase. But one of the downsides compared to the other levels we've seen one we're still storing away
39:0939 minutes, 9 secondsfrom our laptop. So it's not locally held data. It is secure in a database but it effectively means we have to query an external facing database every
39:1839 minutes, 18 secondssingle time which is going to add some latency to our process. But that might be the compromise you're willing to make if you want every single AI tool you use
39:2639 minutes, 26 secondsto share that same memory for you. So I know that has been a ton of different information. So I wanted to just touch on how do you just get started today and
39:3439 minutes, 34 secondswhich one should you pick. So if you are literally just starting then don't worry about these memory systems. Turn on level one by just utilizing your
39:4239 minutes, 42 secondsclaude.md and your memory.mmd files in the right way. It's going to take you 10 minutes and it's going to be a massive improvement on the inbuilt memory
39:5039 minutes, 50 secondsinside. If you've been using claude code for a little bit then you can go to level two install John's hook and then honestly most of you should stop right
39:5839 minutes, 58 secondsthere. But if you started to build up significant amount of context and you're losing old decisions across months of work, then you can either go to level
40:0640 minutes, 6 secondsthree and install mem search or level four where we're actually verbatim word for word retrieving information from me palace. Level five and six kind of took
40:1540 minutes, 15 secondsus into a completely different realm for specific use cases. Level five was Karpathy's LLM wiki, which is best if you want to do some deep research on a
40:2340 minutes, 23 secondsspecific topic and reference the relationship between the subtopics in that topic. And then level six was all about actually if you want something that you own that's still relatively
40:3140 minutes, 31 secondscheap but you can plug into any external AI tool or LLM in the future then you want to go with something like open brain or mem. And the best part about
40:3940 minutes, 39 secondsall the things that we covered today is a lot of them do stack together. So you can run levels 1 2 and three together with no issues and actually the folder
40:4740 minutes, 47 secondsstructure is fairly sim similar and you can ask claw code to actually integrate those yourself. And in terms of what I am personally implementing, I'm
40:5540 minutes, 55 secondsimplementing up to level three inside the agentic operating system. So following those open claw conventions, but also adding on the semantic search
41:0341 minutes, 3 secondscapability and the hooks that enable actually injection of certain context at a certain time and that just improves the search and recall functionality
41:1241 minutes, 12 secondsinside the business operating system. So if you want to see more about exactly how to build out your own agentic operating system, then watch the next video. Thanks for watching. didn't see you in the next one.