<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: iCe Gaming</title>
    <description>The latest articles on DEV Community by iCe Gaming (@icegaming).</description>
    <link>https://dev.to/icegaming</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3181195%2Fee20f9ef-f613-487a-9e0a-d084dcaaf229.png</url>
      <title>DEV Community: iCe Gaming</title>
      <link>https://dev.to/icegaming</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/icegaming"/>
    <language>en</language>
    <item>
      <title>CLAUDE.md Is the Grandpa Approach. Your Harness Lives in Memory Now.</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Tue, 24 Nov 2026 08:58:43 +0000</pubDate>
      <link>https://dev.to/icegaming/claudemd-is-the-grandpa-approach-your-harness-lives-in-memory-now-4hoe</link>
      <guid>https://dev.to/icegaming/claudemd-is-the-grandpa-approach-your-harness-lives-in-memory-now-4hoe</guid>
      <description>&lt;p&gt;We're about to walk into 2027 and a huge part of this industry still thinks "agent memory" means a markdown file.&lt;/p&gt;

&lt;p&gt;CLAUDE.md. AGENTS.md. GEMINI.md. &lt;code&gt;.cursor/rules&lt;/code&gt;. Pick your flavour. People write them, paste them into threads, compare line counts like it's a flex, and call the whole thing their "harness".&lt;/p&gt;

&lt;p&gt;It's not a harness. It's a sticky note on the monitor. It's the grandpa approach: write the rules on paper, pin them to the fridge, hope everyone reads them.&lt;/p&gt;

&lt;p&gt;Things evolved. &lt;strong&gt;Memory is everything now. But only if it's good memory.&lt;/strong&gt; And a rules file is not memory. Treating it like memory is exactly why your agent keeps repeating the fix you rejected last Tuesday.&lt;/p&gt;

&lt;h2&gt;
  
  
  A rules file is rules. That's all it is.
&lt;/h2&gt;

&lt;p&gt;Rules files are great at one job: telling the agent how to behave. "Use pnpm." "Never force push." "Tests live next to the code." Fine. Those are rules, and rules are the smallest part of the job.&lt;/p&gt;

&lt;p&gt;But look at what people actually shove in there once they figure out the agent forgets everything between sessions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the architecture explained for the fifth time&lt;/li&gt;
&lt;li&gt;"we tried X, it didn't work" (sometimes, if somebody remembered to write it down)&lt;/li&gt;
&lt;li&gt;the deploy quirk from March&lt;/li&gt;
&lt;li&gt;a decision from a meeting nobody can find anymore&lt;/li&gt;
&lt;li&gt;a paragraph about a bug that was fixed months ago and is still sitting there, shouting at every session&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That's not a rules file anymore. That's a junk drawer you load into the model's head every single time.&lt;/p&gt;

&lt;h2&gt;
  
  
  Five ways the markdown file fails as memory
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;1. It's loaded whole, every session.&lt;/strong&gt; Every line, every time. Your agent is fixing a CSS bug and it's paying context for your database migration saga. The agent uses a small slice of that file on any given task and you pay for all of it, in tokens and in attention. Context is the scarcest thing your agent has, and you're burning it on a wall of text that has nothing to do with the question in front of it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. It can't hold the why, and it definitely can't hold the why-not.&lt;/strong&gt; The most valuable memory on a project is not "we use SQLite". It's &lt;em&gt;why&lt;/em&gt; you use SQLite, and &lt;em&gt;why not&lt;/em&gt; Redis, and what broke when somebody tried Redis. That reasoning is what stops an agent from confidently proposing the thing you already rejected. Nobody writes rejected options into CLAUDE.md, because the file would explode. So the agent proposes Redis. Again.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. It never expires.&lt;/strong&gt; A fact that was true in June is still in the file in December, stated with the same confidence. There's no date on it. There's no "this stopped being true on the 3rd". There's just a line, and the model believes it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. It has no sources.&lt;/strong&gt; When the agent acts on a line from your rules file, where did that line come from? Who wrote it? When? Was it a decision or a guess? You can't tell, and neither can the agent.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5. It doesn't scale.&lt;/strong&gt; Memory should get &lt;em&gt;better&lt;/em&gt; the more you work. A rules file gets &lt;em&gt;worse&lt;/em&gt;: longer, staler, more contradictory, more expensive. Every week you either prune it by hand or let it rot. Most people let it rot.&lt;/p&gt;

&lt;p&gt;So, before you scroll on: &lt;strong&gt;how many lines is your CLAUDE.md right now? And where do you record the options you rejected, and why?&lt;/strong&gt; If the answer is "nowhere", your agent has amnesia with extra steps.&lt;/p&gt;

&lt;h2&gt;
  
  
  The harness lives in memory
&lt;/h2&gt;

&lt;p&gt;Here's the part people don't get yet. The harness is not a folder of static files. The harness is everything that shapes what the agent does, and the part that matters most is the part that changes as you work:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Hooks&lt;/strong&gt; that run at session start, when you send a prompt, after a tool call, when the session stops.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Tools&lt;/strong&gt;, including MCP servers, that the agent can call to look things up and write things down.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Memory&lt;/strong&gt; that stores what actually happened and gives back only the part that matters for &lt;em&gt;this&lt;/em&gt; question.&lt;/li&gt;
&lt;li&gt;And yes, &lt;strong&gt;rules files&lt;/strong&gt;, doing the one job they're good at.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fsdwhetqt32vw38qmef3m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fsdwhetqt32vw38qmef3m.png" alt="A rules file loads every line into every session. A harness with memory recalls only matching drawers, with sources, dates and invalidation." width="800" height="427"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Memory is not a document you maintain. It's a harness that maintains itself. The agent writes down what it decided and why. It kills facts that stopped being true. It recalls only what matters for the task in front of it. Every session leaves the harness a little smarter than it found it. That's a &lt;strong&gt;self-evolving harness&lt;/strong&gt;, and a static file can't do a single one of those things.&lt;/p&gt;

&lt;p&gt;And retrieval is solved enough that loading 400 lines to answer a question that needs five is just waste.&lt;/p&gt;

&lt;h2&gt;
  
  
  What that looks like in practice
&lt;/h2&gt;

&lt;p&gt;I built &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;palace-rs&lt;/a&gt; because I was sick of this. Here's what a harness that lives in memory looks like, straight from the code.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;It's one Rust binary and one SQLite file.&lt;/strong&gt; No API key, no cloud, no Python, no vector database, no Docker. Embeddings run locally on your CPU with &lt;code&gt;all-MiniLM-L6-v2&lt;/code&gt; on ONNX Runtime.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Text is stored verbatim.&lt;/strong&gt; Code, notes, conversations go into "drawers" as written, not as an LLM summary that quietly drops the detail you'll need later.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Retrieval is hybrid.&lt;/strong&gt; BM25 keyword scoring fused with cosine similarity over local embeddings, then boosts for coding questions. No LLM anywhere in the retrieval path. No GPU. On LongMemEval (&lt;code&gt;s_cleaned&lt;/code&gt;, 470 questions, each over a haystack of about 50 sessions and 115k tokens), storing chats as exchange pairs gets &lt;strong&gt;R@1 0.915, R@5 0.987, R@10 0.996&lt;/strong&gt;. The five drawers behind R@5 hold about &lt;strong&gt;1,700 tokens&lt;/strong&gt; between them, 1.3% of the haystack. That's the whole point: the right five things, not the whole pile.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;It's time-aware.&lt;/strong&gt; Ask "what did we decide two weeks ago" or "in March" and the query parser turns that into a date target, and drawers dated near that target rank higher. Your rules file has no idea what "two weeks ago" means. It doesn't even know what day it is.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Facts expire.&lt;/strong&gt; The knowledge graph stores facts as subject, predicate, object with &lt;code&gt;valid_from&lt;/code&gt; and &lt;code&gt;valid_to&lt;/code&gt;. When something stops being true, the agent invalidates it: &lt;code&gt;valid_to&lt;/code&gt; gets set, and queries for a given date only return facts that were valid then. The timeline keeps both the old fact and the new one. That's the difference between memory and a list of claims that never die.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The why goes in with the decision.&lt;/strong&gt; After real work, the agent writes a diary entry and stores durable decisions as facts. So "we dropped Redis because the deploy target had no persistent volume" is a thing the agent can find later, instead of a thing someone forgot to type into a file.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Every result is cited.&lt;/strong&gt; Each hit comes back with its wing, room, source file, drawer id and a score breakdown. You can ask where an answer came from and get a real answer.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The agent doesn't have to remember to remember.&lt;/strong&gt; &lt;code&gt;palace install&lt;/code&gt; registers hooks. At session start it injects your standing preferences and recent diary entries for this project. When you send a prompt (in Claude Code and Codex), it searches with your actual question and injects the matching drawers. While the agent greps and reads files, related memory surfaces. Coverage differs per client, and the README has the table. When the session stops having done real work without saving anything, it asks the agent to write it down. And every hook fails open: no palace, no problem, the agent works as normal.&lt;/p&gt;

&lt;p&gt;That's the self-evolving loop: recall, work, write back, invalidate what's wrong. Not a file. Hooks, MCP tools and memory working as one harness that gets better every session.&lt;/p&gt;

&lt;h2&gt;
  
  
  "But injecting memory into context is a prompt injection risk"
&lt;/h2&gt;

&lt;p&gt;This one gets thrown around a lot. It's wrong.&lt;/p&gt;

&lt;p&gt;Everything your agent reads is text in context. Your CLAUDE.md is text in context. The README it greps is text in context. Every tool result, every web page, every stack trace is text in context. If "text in context" is your whole threat model, your harness was a threat model failure long before memory showed up.&lt;/p&gt;

&lt;p&gt;The real question is: &lt;em&gt;whose&lt;/em&gt; text, and can you check it?&lt;/p&gt;

&lt;p&gt;Memory that you and your agent filed, on your own machine, in one SQLite file, where every recalled drawer carries its source and id, and where you can see who stored it, when and from where, is &lt;em&gt;more&lt;/em&gt; auditable than a 400-line markdown file that four people edited and nobody has read top to bottom since summer.&lt;/p&gt;

&lt;p&gt;And preferences belong in memory. That's what they are: things you told your agent before. Palace recalls them as exactly that, preferences you stated earlier, not as commands that override the harness. Ranked by importance and recency, capped at 20 per session start. Refusing to let an agent remember your preferences "for safety" isn't safety. It's choosing amnesia and calling it a feature.&lt;/p&gt;

&lt;h2&gt;
  
  
  Rules files are the old way
&lt;/h2&gt;

&lt;p&gt;CLAUDE.md doesn't disappear. Palace itself writes a short rule block into it so the agent knows when to search memory and when to write to it. That's all a rules file is good for now: a few lines that point at the real harness.&lt;/p&gt;

&lt;p&gt;If your plan for "my agent should remember things" is "make the markdown file longer", you're stuck. You're paying for context you don't use, losing every why-not you ever had, and feeding the model facts that expired months ago with no way to tell.&lt;/p&gt;

&lt;p&gt;Static rules were the grandpa approach. The harness lives in memory now: hooks, tools, MCP servers and a memory the agent writes, corrects and recalls every session. The markdown file is a footnote.&lt;/p&gt;

&lt;p&gt;So tell me in the comments:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;How many lines is your CLAUDE.md or AGENTS.md?&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Where do you record the options you rejected, and why?&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;When a fact in it stops being true, how does your agent find out?&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If your answers are "a lot", "nowhere" and "it doesn't", you're running grandpa's harness. Time to upgrade.&lt;/p&gt;




&lt;p&gt;palace-rs is open source, local-first memory for coding agents, for individual developers: &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;github.com/AncientiCe/palace-rs&lt;/a&gt;. If you want shared memory for a team, that's &lt;a href="https://palacememory.com" rel="noopener noreferrer"&gt;Palace&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Not associated in any way with the popular mempalace python.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>programming</category>
      <category>productivity</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Claude Code Is Great. It Also Forgets Everything.</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Mon, 23 Nov 2026 17:18:00 +0000</pubDate>
      <link>https://dev.to/icegaming/claude-code-is-great-it-also-forgets-everything-3hd8</link>
      <guid>https://dev.to/icegaming/claude-code-is-great-it-also-forgets-everything-3hd8</guid>
      <description>&lt;p&gt;Claude Code is great. I use it most days. Then I close the session, open a new one in the morning, and I am briefing a very sharp intern who has never met me.&lt;/p&gt;

&lt;p&gt;The architecture I already explained is gone. The fix I rejected last week is back on the table. The reason we dropped Redis lives in a chat I can no longer see. The model is the same. The memory is not.&lt;/p&gt;

&lt;p&gt;This is not a model-quality problem. The models are already good enough to do real work in a repo. The expensive part is the tax you pay at the start of every session: re-teaching the agent the project, the decisions, and the dead ends, just so it can reach the point where it was useful yesterday.&lt;/p&gt;

&lt;h2&gt;
  
  
  Markdown is a briefing, not memory
&lt;/h2&gt;

&lt;p&gt;The usual answer is a markdown file. &lt;code&gt;CLAUDE.md&lt;/code&gt;, &lt;code&gt;AGENTS.md&lt;/code&gt;, a growing &lt;code&gt;MEMORY.md&lt;/code&gt;, maybe an auto-memory file the agent appends to when it feels like it. I have used all of these. They are a reasonable briefing. They are not memory.&lt;/p&gt;

&lt;p&gt;A briefing is loaded in full, every session, whether today's task needs it or not. That is fine when the file is two dozen lines of install commands and the test incantation. It stops being fine when the file becomes the dumping ground for every lesson, preference, and near-miss from the last three months. Every line costs context. The one line you needed is sitting under a pile of advice about a migration you finished in June.&lt;/p&gt;

&lt;p&gt;Real memory is a lookup. You ask a question, and the relevant bit comes back, with enough of the original wording that you can trust it, and a pointer to where it came from. A markdown file cannot do that. It is either in the window or it is not. There is no "search last month's checkout investigation." There is only "read this blob again."&lt;/p&gt;

&lt;p&gt;It also goes stale without anyone noticing. The file still says "use the v2 client." The v2 client was removed. The agent trusts the file, because that is what the file is for.&lt;/p&gt;

&lt;p&gt;And the moment you use more than one agent, the briefing splits. Claude Code in the morning, Cursor in the afternoon, maybe Codex for a quick pass. Each one has its own file, or no file at all. None of them know what the others learned. You become the sync layer.&lt;/p&gt;

&lt;p&gt;I am not saying you should delete &lt;code&gt;CLAUDE.md&lt;/code&gt;. Keep it for the stable rules: how to install, how to test, the conventions that do not change. That is what it is good at. Do not ask it to remember a year of decisions.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I wanted instead
&lt;/h2&gt;

&lt;p&gt;I wanted the agent to remember the way a teammate does. Not by rereading the entire wiki at standup, but by recalling the one investigation that matters for this prompt, in the words it was originally written in, with a citation I can check.&lt;/p&gt;

&lt;p&gt;That is what I built Palace for. It is one Rust binary and one SQLite file. It stores the original text, not an LLM summary. It embeds locally and searches with hybrid vector and BM25. There is no API key and no cloud on the default path.&lt;/p&gt;

&lt;p&gt;Not associated in any way with the popular mempalace python.&lt;/p&gt;

&lt;p&gt;The important part is not that a memory database exists. Plenty of people have a store they forget to query. The important part is that recall happens without the model having to remember to search.&lt;/p&gt;

&lt;h2&gt;
  
  
  The plugin, and the hooks that do the remembering
&lt;/h2&gt;

&lt;p&gt;Palace now ships as a Claude Code plugin. If the &lt;code&gt;palace&lt;/code&gt; binary is on your &lt;code&gt;PATH&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;/plugin marketplace add AncientiCe/palace-rs
/plugin install palace@palace-rs
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;palace install&lt;/code&gt; still wires the always-on rule and the user-level hooks, so memory works in every project without a per-repo edit. After that, you do not paste last week's notes into the prompt. The hooks do the lookup.&lt;/p&gt;

&lt;p&gt;At &lt;strong&gt;session start&lt;/strong&gt;, Palace injects the memory protocol, your standing preferences, recent diary entries for this project, and the top drawers of the project's wing. The new session is not empty. It already has a short, cited briefing that came from actual work, not from a file you have been hand-curating.&lt;/p&gt;

&lt;p&gt;At &lt;strong&gt;prompt submit&lt;/strong&gt;, it searches with the question you just typed and injects matching drawers before the agent answers. If you ask "why did we switch the queue to SQLite?" and there is a decision on file, it shows up, with the drawer it came from. You did not have to type &lt;code&gt;palace_search&lt;/code&gt;. The hook did.&lt;/p&gt;

&lt;p&gt;While the agent greps and reads files, a &lt;strong&gt;post tool use&lt;/strong&gt; hook can surface related decisions so an earlier choice appears without a separate search.&lt;/p&gt;

&lt;p&gt;When the session did real work but saved nothing, a &lt;strong&gt;stop&lt;/strong&gt; hook asks the agent once to write a diary entry and record decisions before it finishes. Memory compounds only if something gets written back.&lt;/p&gt;

&lt;p&gt;All of those hooks fail open. If the palace is missing or empty, Claude Code works as it always did. Auto-recall stays inside the current project, so a drawer from another repo does not wander in.&lt;/p&gt;

&lt;p&gt;That is the difference I care about. Markdown asks you to maintain a briefing. Hooks look up the cited bit at the moment it is useful, and they put yesterday's lessons back when the session ends.&lt;/p&gt;

&lt;h2&gt;
  
  
  The number I will stand behind
&lt;/h2&gt;

&lt;p&gt;I do not want this to be a vibes argument, so I run a public retrieval eval.&lt;/p&gt;

&lt;p&gt;On LongMemEval &lt;code&gt;s_cleaned&lt;/code&gt; (470 questions, each over a haystack of about 50 sessions and 115k tokens), Palace's exchange-pair setup, the same way it mines real chats, reaches retrieval recall &lt;strong&gt;R@1 0.915, R@5 0.987, R@10 0.996&lt;/strong&gt;. There is no LLM and no GPU in the retrieval path.&lt;/p&gt;

&lt;p&gt;That number is "did the right session appear in the top results," not "did a model then answer the question." I am careful not to line it up against QA leaderboard scores. They measure a different thing. The method is in the repo, including what was and was not tuned. I would rather someone rerun it than take the figure on faith.&lt;/p&gt;

&lt;h2&gt;
  
  
  It is not only a Claude Code plugin
&lt;/h2&gt;

&lt;p&gt;The same binary talks to other agents, because the memory should follow the work, not the editor.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;OpenCode: &lt;code&gt;npm i opencode-palace&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;LangGraph: &lt;code&gt;pip install langgraph-store-palace&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Antigravity: &lt;code&gt;palace install --client antigravity&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Cursor, Codex, and a few others are supported the same way, through MCP plus hooks. The store is still one SQLite file on your machine.&lt;/p&gt;

&lt;p&gt;If this is useful, the repo is &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;https://github.com/AncientiCe/palace-rs&lt;/a&gt;. If you just wanted the argument, that is fine too: stop asking a markdown file to be a memory system, and stop re-teaching a capable agent from zero every morning.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>claudecode</category>
      <category>productivity</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Best memory for AI agents. Period. 98.7% recall, one Rust binary, no LLM</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Sun, 22 Nov 2026 14:33:51 +0000</pubDate>
      <link>https://dev.to/icegaming/best-memory-for-ai-agents-period-987-recall-one-rust-binary-no-llm-399h</link>
      <guid>https://dev.to/icegaming/best-memory-for-ai-agents-period-987-recall-one-rust-binary-no-llm-399h</guid>
      <description>&lt;p&gt;Every coding agent you use has the same flaw. It is brilliant for one session, and then it forgets everything.&lt;/p&gt;

&lt;p&gt;You explain the architecture again. It suggests the fix you rejected last Tuesday. It greps 40 files to rediscover a convention you settled three months ago. It asks which test command you use. You told it. Yesterday. And the day before.&lt;/p&gt;

&lt;p&gt;The industry answer has mostly been one of two things:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A giant instruction file (CLAUDE.md, AGENTS.md, .cursorrules) that you maintain by hand and that gets loaded, in full, into every single session whether it is relevant or not.&lt;/li&gt;
&lt;li&gt;A cloud "memory layer" that sends your conversations to an LLM, asks it to summarise them into "facts", stores the summaries in a hosted vector database, and bills you per call.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I think both are wrong. So I built &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;Palace&lt;/a&gt;: local-first memory for coding agents. One Rust binary. One SQLite file. No API keys, no Python, no Docker, no vector database, no cloud.&lt;/p&gt;

&lt;p&gt;And here is the part that surprised even me: it does not need an LLM to be good at this. On LongMemEval, the standard long-term memory benchmark, Palace finds the right session in the top 5 for 98.7% of questions, using nothing but a 23 MB embedding model on your CPU and 6 ms per query.&lt;/p&gt;

&lt;p&gt;Let me show you how.&lt;/p&gt;

&lt;h2&gt;
  
  
  The 30-second version
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# macOS / Linux&lt;/span&gt;
curl -fsSL https://raw.githubusercontent.com/AncientiCe/palace-rs/main/scripts/install.sh &lt;span class="o"&gt;|&lt;/span&gt; sh

&lt;span class="c"&gt;# Windows (PowerShell)&lt;/span&gt;
irm https://raw.githubusercontent.com/AncientiCe/palace-rs/main/scripts/install.ps1 &lt;span class="o"&gt;|&lt;/span&gt; iex

palace install    &lt;span class="c"&gt;# wires up every agent on this machine&lt;/span&gt;
palace doctor     &lt;span class="c"&gt;# checks that each one is connected&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Restart your agent. Then, the next day, in a brand-new session:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;You:    why did we switch the queue to SQLite last month?
Agent:  [palace_search → wing my_api, room decisions, filed 2026-09-03]
        You dropped Redis because the deploy target had no persistent volume.
        The benchmark you ran is in the same drawer.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's it. That is the product. Your agent remembers, and it tells you where it remembered it from.&lt;/p&gt;

&lt;p&gt;It works with Claude Code, Codex, Cursor, Gemini CLI, VS Code, OpenCode, Cline, Zed, Goose, Windsurf and Claude Desktop. Eleven agents, one memory. A Codex session can pick up exactly where yesterday's Claude Code session left off, because they read from the same palace.&lt;/p&gt;

&lt;h2&gt;
  
  
  The numbers
&lt;/h2&gt;

&lt;p&gt;I'm going to lead with benchmarks, because "AI memory" is a category full of vibes and very short on reproducible results.&lt;/p&gt;

&lt;h3&gt;
  
  
  LongMemEval
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://github.com/xiaowu0162/LongMemEval" rel="noopener noreferrer"&gt;LongMemEval&lt;/a&gt; gives a retriever a long chat history and asks questions about it. Every question comes with its own haystack of past sessions, and you have to find the session that holds the answer. Some questions need facts that were later updated. Some need reasoning about time ("what did I buy two weeks before the trip?"). Some need several sessions at once.&lt;/p&gt;

&lt;p&gt;s_cleaned: ~50 sessions, ~115k tokens of haystack per question (470 questions, abstention excluded, the usual convention):&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fynindjkj0ln0w9fzzf96.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fynindjkj0ln0w9fzzf96.png" alt="LongMemEval s_cleaned results: Recall@1 0.91, Recall@5 0.987, Recall@10 0.996, with per-question-type scores and m_cleaned" width="800" height="480"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Metric&lt;/th&gt;
&lt;th&gt;Score&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Recall@1&lt;/td&gt;
&lt;td&gt;0.91&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Recall@5&lt;/td&gt;
&lt;td&gt;0.987&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Recall@10&lt;/td&gt;
&lt;td&gt;0.996&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Per question type, at @5:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Question type&lt;/th&gt;
&lt;th&gt;R@5&lt;/th&gt;
&lt;th&gt;R@10&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;knowledge-update&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;single-session-user&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;single-session-assistant&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;multi-session&lt;/td&gt;
&lt;td&gt;0.992&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;temporal-reasoning&lt;/td&gt;
&lt;td&gt;0.976&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;single-session-preference&lt;/td&gt;
&lt;td&gt;0.933&lt;/td&gt;
&lt;td&gt;0.933&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Read that again: perfect recall@10 on knowledge updates, multi-session questions and temporal reasoning, the three categories that are supposed to be hard.&lt;/p&gt;

&lt;p&gt;And it isn't just finding one of the right sessions. On questions that need several, recall_all@10 (every gold session in the top 10) is 0.938.&lt;/p&gt;

&lt;p&gt;What comes back is tiny. The five drawers behind the @5 score hold about 1,700 tokens between them. That's 1.3% of the haystack. Your agent doesn't need a million-token context window to remember last month. It needs the right 1,700 tokens.&lt;/p&gt;

&lt;p&gt;Then I made it ten times harder. m_cleaned has ~500 sessions and ~1.5M tokens of haystack per question, around 4,000 drawers to search for every single question:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Metric&lt;/th&gt;
&lt;th&gt;Score&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Recall@5&lt;/td&gt;
&lt;td&gt;0.919&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Recall@10&lt;/td&gt;
&lt;td&gt;0.949&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Avg query time&lt;/td&gt;
&lt;td&gt;78 ms&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Over 9 in 10 questions answered from the top 5, out of a million and a half tokens, on a laptop CPU, in under a tenth of a second.&lt;/p&gt;

&lt;h3&gt;
  
  
  What's not in that pipeline
&lt;/h3&gt;

&lt;p&gt;This is the part I want people to sit with:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fn46g9nb067jdt9ju1fz8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fn46g9nb067jdt9ju1fz8.png" alt="What's not in that pipeline: no LLM, no GPU, no API calls, no summarisation, no parameters fitted, 6 ms average. palace is the whole thing, palace.db is all of your memory." width="800" height="469"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;No LLM. Not at ingestion, not at query time, not for "fact extraction", not for reranking.&lt;/li&gt;
&lt;li&gt;No GPU. all-MiniLM-L6-v2, int8 quantised, on ONNX Runtime, on the CPU.&lt;/li&gt;
&lt;li&gt;No API calls. Nothing leaves the machine.&lt;/li&gt;
&lt;li&gt;No summarisation. Every session is stored verbatim, one drawer per user turn and reply.&lt;/li&gt;
&lt;li&gt;No parameters fitted on the benchmark. Nothing was tuned on s_cleaned.&lt;/li&gt;
&lt;li&gt;6 ms average per question, including embedding the question itself.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A lot of memory systems put an LLM in the loop and call the result "intelligent memory". Every LLM call is latency, money, a privacy boundary you just crossed, and a lossy rewrite of what actually happened. Palace gets to 98.7% without one, and the retrieval is deterministic: run it twice, get the same answer.&lt;/p&gt;

&lt;p&gt;The runner is public and the method is documented in &lt;a href="https://github.com/AncientiCe/palace-rs/blob/main/docs/benchmarks.md" rel="noopener noreferrer"&gt;docs/benchmarks.md&lt;/a&gt;. Please run it yourself. I would genuinely love to see the numbers reproduced on other hardware.&lt;/p&gt;

&lt;h3&gt;
  
  
  Coding-agent memory eval
&lt;/h3&gt;

&lt;p&gt;LongMemEval is about chat. Coding agents have their own kind of memory: decisions, past failures, commands, conventions, preferences. So Palace ships an eval built from exactly that, 51 questions like "why did we choose bundled sqlite?" and "what clippy command should I run?":&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;R@1&lt;/th&gt;
&lt;th&gt;R@5&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Palace (default model)&lt;/td&gt;
&lt;td&gt;0.922&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Every question answered from the top 5. It runs as a normal test: &lt;code&gt;cargo test --test coding_agent_eval -- --nocapture&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Speed
&lt;/h3&gt;

&lt;p&gt;On a real palace of 10,800 drawers:&lt;/p&gt;

&lt;p&gt;| Indexing | 150 drawers/s |&lt;br&gt;
| Query p95 | 2.0 ms |&lt;/p&gt;

&lt;p&gt;I tried bigger embedding models (bge-small, bge-base). They were 2-4x slower to index, 2-3x slower to query, and no better on the coding eval. The smallest model won. Sometimes the boring answer is the right one.&lt;/p&gt;
&lt;h2&gt;
  
  
  Why it's this good without an LLM
&lt;/h2&gt;

&lt;p&gt;There is no single trick. There are a lot of small, unglamorous decisions that compound.&lt;/p&gt;
&lt;h3&gt;
  
  
  1. Verbatim storage
&lt;/h3&gt;

&lt;p&gt;Palace never rewrites your memory. A drawer is a chunk of the actual text, with its embedding and metadata. When an LLM summarises "we dropped Redis because the deploy target had no persistent volume" into "user prefers SQLite", the why is gone forever. Palace keeps the why.&lt;/p&gt;
&lt;h3&gt;
  
  
  2. Hybrid search, not "just vectors"
&lt;/h3&gt;

&lt;p&gt;Pure vector search is bad at exact identifiers, error codes, file paths and the name of that one flag. Pure keyword search is bad at paraphrase. Palace fuses BM25 with cosine similarity on every query, and it computes the real cosine for every keyword match instead of assuming zero for drawers outside the nearest-neighbour shortlist. (That one fix alone moved R@1 on a 12,500-drawer real palace from 0.345 to 0.430.)&lt;/p&gt;
&lt;h3&gt;
  
  
  3. It knows what kind of question you asked
&lt;/h3&gt;

&lt;p&gt;Each query is classified: decision, how_to, preference, definition, temporal, or unknown. A preference question ("how do I like my commits?") gets a dedicated pass over tagged preference spans. A temporal question resolves "two weeks ago" against the date it's asked. A question that names code (an identifier, a path) ranks mined source and filed notes evenly; a plain-English question favours the decisions you and your agent actually filed.&lt;/p&gt;
&lt;h3&gt;
  
  
  4. It cleans up agent garbage
&lt;/h3&gt;

&lt;p&gt;Agents love to paste half a stack trace and three tool outputs into a search query. Palace sanitises the query before retrieval, so a 2,000-character dump doesn't drown the one sentence that matters.&lt;/p&gt;
&lt;h3&gt;
  
  
  5. Structure, not a flat pile
&lt;/h3&gt;

&lt;p&gt;Memory is organised like a building:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fahhvxd8ibpccx3luqqof.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fahhvxd8ibpccx3luqqof.png" alt="Inside a palace: wings hold rooms, rooms hold drawers, plus a knowledge graph and agent diaries" width="800" height="294"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Concept&lt;/th&gt;
&lt;th&gt;What it is&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Wing&lt;/td&gt;
&lt;td&gt;A project or topic (my_api, sales_notes)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Room&lt;/td&gt;
&lt;td&gt;An area inside it (backend, decisions, testing)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Drawer&lt;/td&gt;
&lt;td&gt;One verbatim chunk + embedding + metadata&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Knowledge graph&lt;/td&gt;
&lt;td&gt;Time-stamped facts: my_api → uses_queue → SQLite (valid from 2026-09-03)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Diary&lt;/td&gt;
&lt;td&gt;Per-agent session notes for continuity&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Tunnel&lt;/td&gt;
&lt;td&gt;A link between rooms in different wings&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Facts in the knowledge graph have validity windows. When something changes, the agent invalidates the old fact and adds the new one, and the timeline keeps both. So "what did we use before SQLite?" is a question Palace can actually answer.&lt;/p&gt;
&lt;h2&gt;
  
  
  The part nobody else gets right: the agent doesn't have to remember to remember
&lt;/h2&gt;

&lt;p&gt;Here's the dirty secret of most MCP memory servers: they expose a search tool and then hope the model calls it. It usually doesn't. Models are trained to be helpful now, not to stop and check what happened last week.&lt;/p&gt;

&lt;p&gt;Palace doesn't hope. &lt;code&gt;palace install&lt;/code&gt; registers hooks:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fgvw89se3bko0x4rrjxr8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fgvw89se3bko0x4rrjxr8.png" alt="One agent session, four hooks: Session start, Prompt submit, Post tool use and Stop, all wired to palace.db" width="800" height="275"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Hook&lt;/th&gt;
&lt;th&gt;What it does&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Session start&lt;/td&gt;
&lt;td&gt;Injects your standing rules, recent diary entries for this project (from any agent) and the project's most important drawers.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Prompt submit&lt;/td&gt;
&lt;td&gt;Searches the palace with your actual question and injects matching memory before the agent answers.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Post tool use&lt;/td&gt;
&lt;td&gt;While the agent greps and reads files, it surfaces related decisions, so the agent sees "we tried this in October and it broke prod" without ever searching.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Stop&lt;/td&gt;
&lt;td&gt;If the session did real work but saved nothing, it asks the agent once to write a diary entry and record decisions before it finishes.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;That last one closes the loop. Memory only works if something gets written. Palace makes sure today's lessons become tomorrow's recall.&lt;/p&gt;

&lt;p&gt;Every hook fails open. A missing or broken palace never blocks your agent.&lt;/p&gt;
&lt;h2&gt;
  
  
  Every answer has a receipt
&lt;/h2&gt;

&lt;p&gt;Every search result carries its wing, room, source file, drawer id and a full score breakdown: combined, cosine, bm25, coding_boost, preference_match, intent, plus the chunks right before and after the hit in its source.&lt;/p&gt;

&lt;p&gt;That means when your agent says "we decided X", you can check. No more confident hallucinations about decisions that never happened. If Palace said it, Palace can show you where.&lt;/p&gt;

&lt;p&gt;And you can measure whether it's paying for itself:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;palace gain
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;reports hit rate, precision@1 and @5, estimated tokens saved, repeat questions avoided, knowledge-graph facts recalled and p95 latency for your own sessions, from your own palace.db.&lt;/p&gt;

&lt;h2&gt;
  
  
  One binary. Really.
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;palace         ← the whole thing
palace.db      ← all of your memory
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Rust, from a single &lt;code&gt;cargo build --release&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Embedded SQLite. Back up your memory with &lt;code&gt;cp&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;23 MB embedding model, downloaded once.&lt;/li&gt;
&lt;li&gt;Linux, macOS (Apple Silicon) and Windows.&lt;/li&gt;
&lt;li&gt;Installers verify SHA-256 checksums. Homebrew tap. MCPB bundle for one-click install in Claude Desktop. Listed in the official MCP registry as &lt;code&gt;io.github.ancientice/palace-rs&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;50 MCP tools, with the nine core protocol tools marked always-load so Claude Code keeps them available instead of hiding them behind tool search.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Want to mine an existing codebase?&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;palace init ~/my-project --yes --auto-mine
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It detects rooms, writes a &lt;code&gt;palace.yaml&lt;/code&gt;, and indexes the project. Re-running only touches what changed.&lt;/p&gt;

&lt;p&gt;Coming from the Python MemPalace? &lt;code&gt;palace migrate&lt;/code&gt; reads &lt;code&gt;~/.mempalace&lt;/code&gt; (ChromaDB or the SQLite backend), keeps your timestamps, importance, diaries, knowledge graph and tunnels, and re-embeds everything. No Python needed.&lt;/p&gt;

&lt;p&gt;Want to switch embedding models? &lt;code&gt;palace embeddings migrate &amp;lt;model&amp;gt;&lt;/code&gt; rebuilds vectors in the background while search keeps working, then verifies the new model against 200 probes from your own palace and only switches if recall@5 doesn't drop and latency stays in budget. Rollback is instant. Your memory is never at the mercy of a model swap.&lt;/p&gt;

&lt;h2&gt;
  
  
  Privacy isn't a feature. It's the architecture.
&lt;/h2&gt;

&lt;p&gt;Your agent's memory is the most sensitive data you have about your work: architecture decisions, security fixes, incident notes, customer names in a debugging session, the half-formed idea you haven't told your team about yet.&lt;/p&gt;

&lt;p&gt;With Palace, storage, embeddings and search all run on your machine. The only network calls are the one-time model download and, if you explicitly turn it on, your own self-hosted Palace Server for shared team memory. There is no telemetry to opt out of, because there is nothing to send.&lt;/p&gt;

&lt;h2&gt;
  
  
  "Isn't this just CLAUDE.md with extra steps?"
&lt;/h2&gt;

&lt;p&gt;No. CLAUDE.md is instructions you write by hand, and every line of it is loaded into every session. It doesn't grow on its own, it doesn't know which parts are relevant, and Codex can't read Claude's.&lt;/p&gt;

&lt;p&gt;Palace is memory that grows as you work, recalls only what's relevant to the current question, and is shared across every agent you use. Keep your instruction file for rules. Use Palace for history.&lt;/p&gt;

&lt;h2&gt;
  
  
  Not just for code
&lt;/h2&gt;

&lt;p&gt;The creative and personal profiles tune Palace for worldbuilding, fiction, coaching, caregiving and household notes. It reads Markdown and plain text, so Claude Desktop users can install the MCPB bundle and start without touching a terminal.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl -fsSL https://raw.githubusercontent.com/AncientiCe/palace-rs/main/scripts/install.sh &lt;span class="o"&gt;|&lt;/span&gt; sh
palace install
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then close your agent, open it again tomorrow, and ask it what you worked on today.&lt;/p&gt;

&lt;p&gt;⭐ GitHub: &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;AncientiCe/palace-rs&lt;/a&gt;&lt;br&gt;
📊 Benchmarks and method: &lt;a href="https://github.com/AncientiCe/palace-rs/blob/main/docs/benchmarks.md" rel="noopener noreferrer"&gt;docs/benchmarks.md&lt;/a&gt;&lt;br&gt;
💬 Using it? Tell me in &lt;a href="https://github.com/AncientiCe/palace-rs/discussions/categories/show-and-tell" rel="noopener noreferrer"&gt;Show and tell&lt;/a&gt;: which agents, and what it remembers for you. One line there helps more than a star.&lt;/p&gt;

&lt;p&gt;Your agent is smart. It should also remember.&lt;/p&gt;

</description>
      <category>rust</category>
      <category>ai</category>
      <category>mcp</category>
      <category>opensource</category>
    </item>
    <item>
      <title>I spent a week with Claude Code trying to squeeze more out of my memory tool's LongMemEval score. Almost nothing worked. Is it my code or the benchmark?</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Thu, 19 Nov 2026 21:54:44 +0000</pubDate>
      <link>https://dev.to/icegaming/i-spent-a-week-with-claude-code-trying-to-squeeze-more-out-of-my-memory-tools-longmemeval-score-20h3</link>
      <guid>https://dev.to/icegaming/i-spent-a-week-with-claude-code-trying-to-squeeze-more-out-of-my-memory-tools-longmemeval-score-20h3</guid>
      <description>&lt;p&gt;I built a local-first memory for coding agents. It's a Rust binary and one SQLite file, using MiniLM embeddings plus BM25 keyword search, with no LLM in the retrieval path and no re-ranker.&lt;/p&gt;

&lt;p&gt;On LongMemEval S (470 scored questions) it scores R@1 0.913 (429), R@5 0.987 (464) and R@10 0.996 (468).&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F2mjz3z4j0mdqcmvc0f7n.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F2mjz3z4j0mdqcmvc0f7n.png" alt="palace-rs recall on LongMemEval S" width="800" height="416"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I wanted more, mainly at R@1 and recall_all (every gold session in the top K). But all while preserving the strict rules of NO LLM, no re-ranker model and not tuning for the benchmark.&lt;/p&gt;

&lt;p&gt;Claude Code did most of the legwork:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;offline replays of chunk-score dumps&lt;/li&gt;
&lt;li&gt;a DEV/TEST split by question-id hash&lt;/li&gt;
&lt;li&gt;a "guard" suite (my coding eval plus probes against a snapshot of my real palace), so a benchmark gain couldn't quietly hurt real use&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What we tried
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Idea&lt;/th&gt;
&lt;th&gt;LongMemEval&lt;/th&gt;
&lt;th&gt;Real-palace guards&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Fix two WordPiece tokenizer deviations&lt;/td&gt;
&lt;td&gt;0 questions changed&lt;/td&gt;
&lt;td&gt;probes -1/200&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Embed at MiniLM's trained 128 tokens, not 512&lt;/td&gt;
&lt;td&gt;R@1 +1, recall_all@5 -7&lt;/td&gt;
&lt;td&gt;probes 0.900 -&amp;gt; 0.875, fail&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;256 tokens&lt;/td&gt;
&lt;td&gt;+4/-4 at R@1&lt;/td&gt;
&lt;td&gt;fail&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Re-weight cosine vs BM25 (0.70 to 0.85), DEV only&lt;/td&gt;
&lt;td&gt;+/- 2 questions&lt;/td&gt;
&lt;td&gt;probes 0.885 -&amp;gt; 0.790, coding eval 0.922 -&amp;gt; 0.882&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Count BM25 only when cosine &amp;gt; 0&lt;/td&gt;
&lt;td&gt;&amp;lt;= 1 question&lt;/td&gt;
&lt;td&gt;probes -4 to -6 pts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;RRF, min-max, z-score, saturating BM25&lt;/td&gt;
&lt;td&gt;all within 3 questions of baseline&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Split two-part questions and merge best scores&lt;/td&gt;
&lt;td&gt;R@1 +2/-0 DEV, 0/0 TEST&lt;/td&gt;
&lt;td&gt;unchanged&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Treat advice requests as preferences&lt;/td&gt;
&lt;td&gt;R@1 -5&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The only clean win was 429 -&amp;gt; 431 at &lt;a href="mailto:R@1"&gt;R@1&lt;/a&gt;. BEAM 100K is already 355/355 at R@5.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F6x0u2ukhkw2dlzcvkm67.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F6x0u2ukhkw2dlzcvkm67.png" alt="A week of tuning: almost everything is noise" width="800" height="448"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  How I read it
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;One question is 0.2%. Most "improvements" were 1 to 4 questions, moving in both directions.&lt;/li&gt;
&lt;li&gt;The right sessions are already in the top 30 for 469 of 470 questions. The losses come from ordering, not from failing to find them.&lt;/li&gt;
&lt;li&gt;Fusion is saturated: every way of combining cosine and BM25 lands within 3 questions of the others.&lt;/li&gt;
&lt;li&gt;Every LongMemEval gain cost my real-palace probes more than it gained.&lt;/li&gt;
&lt;li&gt;The leftover misses are reasoning, not retrieval: questions about dates and counting across sessions. The paper's own gains there come from an LLM, which I avoid on purpose.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;So my answer is both, but mostly the benchmark. For a pure retriever, S is close to its ceiling. At R@1 I'm at the limit of a small embedding model plus BM25. The next real step is probably a local cross-encoder reranker, not more tuning.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Claude Code part
&lt;/h2&gt;

&lt;p&gt;The most useful thing it did was keep me honest. It flagged when a "win" was 2 questions, reported failed guards plainly, and stopped when I said "stop if we don't have clear wins". Nothing from the week shipped, and I think that's the right result.&lt;/p&gt;

&lt;h2&gt;
  
  
  Questions
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;At 98%+, is LongMemEval S still a useful signal for you, or have you moved to M, BEAM 1M or your own evals?&lt;/li&gt;
&lt;li&gt;Has anyone gotten a real R@1 lift from a local cross-encoder on conversational memory without bad latency?&lt;/li&gt;
&lt;li&gt;Is there a non-LLM trick for the date questions that I'm missing?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Repo, runner and per-question outputs: &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;https://github.com/AncientiCe/palace-rs&lt;/a&gt;&lt;/p&gt;

</description>
      <category>rust</category>
      <category>ai</category>
      <category>llm</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Two Machines, One Ticket: A Shared Agent Handoff on Claude Code Issue 38536</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Wed, 18 Nov 2026 14:13:06 +0000</pubDate>
      <link>https://dev.to/icegaming/two-machines-one-ticket-a-shared-agent-handoff-on-claude-code-issue-38536-1dmb</link>
      <guid>https://dev.to/icegaming/two-machines-one-ticket-a-shared-agent-handoff-on-claude-code-issue-38536-1dmb</guid>
      <description>&lt;p&gt;There's a public feature request on the Claude Code repo, &lt;a href="https://github.com/anthropics/claude-code/issues/38536" rel="noopener noreferrer"&gt;issue 38536&lt;/a&gt;, asking for shared team memory. The first pain point is a sprint handoff.&lt;/p&gt;

&lt;p&gt;An engineer starts a task, builds deep context with their agent, then hits a blocker. A different engineer picks it up. Today, that second person either rebuilds the context from scratch, asks the first engineer to export it and attach it to the ticket, or gets a verbal recap. The issue calls those last two options "friction-heavy, rarely done well" and "a verbal summary that loses nuance and technical detail."&lt;/p&gt;

&lt;p&gt;What the issue says should happen: the second engineer's agent already knows what was tried, what failed, what the blockers were, and what approach was in progress.&lt;/p&gt;

&lt;p&gt;I wanted to run that handoff, on this same ticket, with two coding agents that share one memory. Full disclosure: I build Palace, so this is me showing my own work.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Two developers. One ticket. Here's what happens when their coding agents share one memory.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/AncientiCe/palace-rs/blob/main/docs/images/palace-handoff-demo.mp4" rel="noopener noreferrer"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fo1453ract2gkq73i7aai.gif" alt="90-second Palace handoff demo" width="720" height="405"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;That's about 90 seconds. Below is the same walkthrough, slower, with the sources.&lt;/p&gt;

&lt;h2&gt;
  
  
  The setup
&lt;/h2&gt;

&lt;p&gt;Palace Server is the self-hosted team edition. It runs on your own infrastructure as Docker Compose or a single binary, with Postgres and pgvector, and embeddings computed there. The open source solo engine, &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;palace-rs&lt;/a&gt;, stays free if you're working alone. This walkthrough is the team path.&lt;/p&gt;

&lt;p&gt;I pointed two isolated environments at one Palace Server, each with its own API token, the way two developers' laptops would be set up. Nothing was copied from A to B. Both talk to the same server over MCP.&lt;/p&gt;

&lt;p&gt;On each machine, after you have a token:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;palace remote &lt;span class="nb"&gt;set&lt;/span&gt; --endpoint https://palace.yourco.com
palace remote on
palace install
palace remote &lt;span class="nb"&gt;test&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;palace remote set&lt;/code&gt; prompts for the API key and stores it (mode 0600) in &lt;code&gt;~/.palace/config.json&lt;/code&gt;. &lt;code&gt;palace remote test&lt;/code&gt; runs the MCP handshake and reports the tool count. Client registrations do not change. Cursor, Claude Code, and Codex keep using the same MCP setup. They just point at the shared server.&lt;/p&gt;

&lt;p&gt;Issue one token per developer. Do not share a single key across the team. How to mint the second token is in the &lt;a href="https://palacememory.com/docs/connect" rel="noopener noreferrer"&gt;connect docs&lt;/a&gt;. The install and remote commands are in the &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;palace-rs README&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Dev A saved
&lt;/h2&gt;

&lt;p&gt;Dev A worked through issue 38536, "Shared Team Memory for Claude Code," and saved three things the thread already rules out, each with a why and a source.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Feltyk5yhkihfgx0ioxu5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Feltyk5yhkihfgx0ioxu5.png" alt="Machine A: Dev A saves three ruled-out approaches to Palace, each with a source" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Exporting agent context and attaching it to the ticket by hand.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The issue describes this as friction-heavy and rarely done well. A verbal summary loses nuance and technical detail. Source: the &lt;a href="https://github.com/anthropics/claude-code/issues/38536" rel="noopener noreferrer"&gt;sprint handoffs section&lt;/a&gt; of the issue itself.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. A project &lt;code&gt;CLAUDE.md&lt;/code&gt; as the team memory.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The issue calls project-level &lt;code&gt;CLAUDE.md&lt;/code&gt; "static sharing." That is a real use, and I still use one for conventions that rarely change. It is a poor fit for an investigation in progress, because updates only reach a teammate after commit, push, and pull. A &lt;a href="https://github.com/anthropics/claude-code/issues/38536#issuecomment-4346449525" rel="noopener noreferrer"&gt;comment on the thread&lt;/a&gt; asks for decisions and context updates to be "visible immediately, not after commit-push-pull."&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. One shared API secret for the whole team.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A &lt;a href="https://github.com/anthropics/claude-code/issues/38536#issuecomment-4690568231" rel="noopener noreferrer"&gt;later comment&lt;/a&gt; from someone running shared memory in production puts this plainly. The "engineer leaves the team" case is the headline scenario, and rotating one shared secret (which kills everyone's tokens) is painful enough that, in practice, nobody does it, so departed members keep access. The fix they argue for is per-member credentials that you can revoke one at a time.&lt;/p&gt;

&lt;p&gt;That is also why A and B did not share a key.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Dev B got back
&lt;/h2&gt;

&lt;p&gt;Dev B opened a fresh session on the other machine. Nothing was copied over. They asked:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;What did we already rule out on this ticket, and where's the evidence?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fjozfp34461s1sd73w99z.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fjozfp34461s1sd73w99z.png" alt="Machine B: a fresh session asks what was ruled out and gets all three findings with sources" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Palace returned all three findings, ranked, each with a source link. B checked when each one was filed and where the evidence lives, then opened the source. It is the original issue on GitHub, and the comments above.&lt;/p&gt;

&lt;p&gt;Nobody had to redo the investigation. Nobody had to paste a recap into the ticket.&lt;/p&gt;

&lt;p&gt;The recording shows those MCP calls (save, search, and open the source) against a live self-hosted server. That is the same path your agents use once &lt;code&gt;palace install&lt;/code&gt; has registered them.&lt;/p&gt;

&lt;h2&gt;
  
  
  When a markdown file is enough
&lt;/h2&gt;

&lt;p&gt;I don't think &lt;code&gt;CLAUDE.md&lt;/code&gt;, a &lt;code&gt;decisions/&lt;/code&gt; folder, or good commit messages are a waste. For one person, on a small repo, with decisions that rarely change, they work. Keep them.&lt;/p&gt;

&lt;p&gt;They recall what someone wrote down, when they remembered to write it. They do not, by themselves, carry a live investigation from one teammate's agent to another's: what was tried, why it failed, and the source, available in a fresh session on another machine, without a git pull.&lt;/p&gt;

&lt;p&gt;If you are solo, the open source engine is enough. The &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;palace-rs README&lt;/a&gt; has the install. This post is about the handoff you cannot do with a file in the repo.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it on one of your tickets
&lt;/h2&gt;

&lt;p&gt;Pick a real issue on your team. Deploy Palace Server on your own infrastructure (the starter kit is in the &lt;a href="https://palacememory.com/docs" rel="noopener noreferrer"&gt;docs&lt;/a&gt;). Connect two developers, each with their own API token. Dev A saves what they tried, why it failed, and the source. Dev B, in a fresh session, asks the same question: "What did we already rule out on this ticket, and where's the evidence?" If the answer cites its source, the handoff is doing its job.&lt;/p&gt;

&lt;p&gt;If you need a security review, there is an &lt;a href="https://palacememory.com/it-evaluation" rel="noopener noreferrer"&gt;IT brief&lt;/a&gt; you can forward.&lt;/p&gt;

&lt;p&gt;Try this with one teammate and one ticket. Give both agents access to the same investigation on your own infrastructure. The team trial includes 10 seats for 60 days, with no credit card.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://palacememory.com/trial?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=team_trial_14d" rel="noopener noreferrer"&gt;Start the team trial&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;If this helped your teammate continue the investigation, keep the shared server on Team for €149/month for up to 10 developers. &lt;a href="https://palacememory.com/pricing" rel="noopener noreferrer"&gt;Get Team&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;How do you pass an investigation to a teammate's agent today? A ticket comment, a Slack recap, a &lt;code&gt;CLAUDE.md&lt;/code&gt;, or do they start over? I read every comment.&lt;/p&gt;

</description>
      <category>aiagents</category>
      <category>mcp</category>
      <category>claudecode</category>
      <category>cursor</category>
    </item>
    <item>
      <title>116,000 Stars vs. One Binary: claude-mem and palace-rs, Fact by Fact</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Thu, 12 Nov 2026 14:46:30 +0000</pubDate>
      <link>https://dev.to/icegaming/116000-stars-vs-one-binary-claude-mem-and-palace-rs-fact-by-fact-2c6g</link>
      <guid>https://dev.to/icegaming/116000-stars-vs-one-binary-claude-mem-and-palace-rs-fact-by-fact-2c6g</guid>
      <description>&lt;p&gt;claude-mem is the most popular memory plugin for AI coding agents. At the time of writing it has &lt;strong&gt;116,434 GitHub stars&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;palace-rs does the same job. It has &lt;strong&gt;10&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Stars tell you what people clicked. They don't tell you what you have to install, what runs in the background, who writes your memories, or whether anyone measured if the thing finds the right memory. So I went through both projects' own READMEs, docs and source and wrote down what each one actually does.&lt;/p&gt;

&lt;p&gt;Every claim below links back to something you can open. No guesses.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F4lywpp9fbyexf1x1jtv5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F4lywpp9fbyexf1x1jtv5.png" alt="claude-mem has 116,434 GitHub stars; palace-rs has 10" width="800" height="352"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What you install
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;claude-mem&lt;/strong&gt; (from its README and &lt;code&gt;package.json&lt;/code&gt;, v15.18.1):&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Node.js&lt;/strong&gt; &lt;code&gt;^20.19.0 || &amp;gt;=22.12.0&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Bun&lt;/strong&gt; &lt;code&gt;&amp;gt;=1.1.31&lt;/code&gt;, "JavaScript runtime and process manager"&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;uv&lt;/strong&gt;, "Python package manager for vector search"&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Chroma&lt;/strong&gt;, enabled by default (&lt;code&gt;CLAUDE_MEM_CHROMA_ENABLED: 'true'&lt;/code&gt;), run locally as &lt;code&gt;chroma-mcp&lt;/code&gt; through &lt;code&gt;uvx&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;A &lt;strong&gt;worker&lt;/strong&gt;, "a local HTTP service managed by Bun", that takes tool activity from hooks, runs the observer, and serves the viewer and search&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That's a JavaScript runtime, a second JavaScript runtime, a Python toolchain, a vector database and a long-running HTTP service.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;palace-rs&lt;/strong&gt; (from its README, v0.20.0):&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;One binary, one SQLite file, no API keys, no cloud.&lt;/p&gt;

&lt;p&gt;No Python, no vector database, no Docker. One &lt;code&gt;palace&lt;/code&gt; executable and one &lt;code&gt;palace.db&lt;/code&gt; file.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Embeddings run on your CPU through ONNX Runtime. There's no server process to keep alive. The install script downloads the release binary, verifies its SHA-256 checksum, and you run &lt;code&gt;palace install&lt;/code&gt; to wire up your agents.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fs9ccl0zox2v1bzbrwxt5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fs9ccl0zox2v1bzbrwxt5.png" alt="claude-mem install stack is Node.js, Bun, uv, Chroma and an HTTP worker; palace-rs is one palace binary and one palace.db file" width="800" height="448"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Who writes your memories
&lt;/h2&gt;

&lt;p&gt;This is the biggest difference, and it's a design choice, not a detail.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;claude-mem uses an LLM to write your memory.&lt;/strong&gt; In its own words:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Hooks in your agent hand each tool call (what it reads, edits and runs) to a small local worker.&lt;br&gt;
A second agent turns that activity into short observations, and writes a summary when the session ends.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The default settings in &lt;code&gt;SettingsDefaultsManager.ts&lt;/code&gt; are &lt;code&gt;CLAUDE_MEM_PROVIDER: 'claude'&lt;/code&gt; and &lt;code&gt;CLAUDE_MEM_MODEL: 'haiku'&lt;/code&gt;. So what ends up in memory is a model's summary of what happened, not what happened.&lt;/p&gt;

&lt;p&gt;That second agent also has to be paid for by someone. The README lists three options: the hosted "claude-mem observer" (a 30-day free trial that asks for a payment method), your own OpenRouter or Gemini key, or your Anthropic plan. It then says:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;With the observer, memory runs off-plan, so you get up to 100% more usage from your plan.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Read that the other way round: when memory runs on your plan, it's using your plan. And when the trial ends, "memory automatically falls back to your Anthropic plan unless you subscribe."&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;palace-rs stores text verbatim and uses no LLM.&lt;/strong&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Code, notes, and conversations are stored as written, not as an LLM summary that loses detail.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;No API key, no model calls, no second agent, no subscription. Recall is hybrid search (BM25 fused with cosine similarity over local embeddings) plus intent-aware ranking. A local cross-encoder reranker is optional. Nothing in the memory path costs tokens to create.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fjaspj6fr4ix33ghr4dhm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fjaspj6fr4ix33ghr4dhm.png" alt="claude-mem uses an LLM observer (default Claude Haiku) to write summaries; palace-rs stores text verbatim and uses no LLM" width="800" height="416"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Does it find the right memory?
&lt;/h2&gt;

&lt;p&gt;A memory tool has one job: when the agent needs something from last week, return it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;palace-rs publishes its numbers.&lt;/strong&gt; On LongMemEval &lt;code&gt;s_cleaned&lt;/code&gt; (470 evaluated questions, each over a haystack of about 50 sessions and 115k tokens), stored the way Palace actually stores conversations:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Metric&lt;/th&gt;
&lt;th&gt;palace-rs&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;R@1&lt;/td&gt;
&lt;td&gt;0.915&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;R@5&lt;/td&gt;
&lt;td&gt;0.987&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;R@10&lt;/td&gt;
&lt;td&gt;0.996&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;From the README's method notes: "No LLM at any stage, no GPU." The one ranking weight picked on LongMemEval data was chosen on a different split (&lt;code&gt;m_cleaned&lt;/code&gt;) and frozen before the run. Per-question-type results are published too, including the weakest category.&lt;/p&gt;

&lt;p&gt;It also ships a coding-agent eval (51 questions like "why did we choose bundled sqlite?") that runs with one command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;cargo &lt;span class="nb"&gt;test&lt;/span&gt; --test coding_agent_eval -- --nocapture
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The README says plainly that this eval is partly tuned, and prints the untuned numbers next to the tuned ones.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;claude-mem's README publishes no retrieval benchmark.&lt;/strong&gt; There's no LongMemEval score, no recall@K, no eval command. The token figures it does give ("~50-100 tokens/result" for the index, "~500-1,000 tokens/result" for full details) come with its own disclaimer:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The ratio is not a measured recall or end-to-end saving.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;So for the most-starred memory tool in this space, there's no published number for how often it returns the right memory. For the 10-star one, there is, with the command to reproduce it.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fnqlw46pqffz11r45940o.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fnqlw46pqffz11r45940o.png" alt="claude-mem README publishes no retrieval benchmark; palace-rs reports LongMemEval s_cleaned R@1 0.915, R@5 0.987, R@10 0.996" width="800" height="416"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Recall that doesn't depend on the agent remembering to search
&lt;/h2&gt;

&lt;p&gt;Both tools use hooks. palace-rs installs four:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Session start&lt;/strong&gt; injects your standing rules, recent diary entries for this project (from any agent), and the top memories of the project.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Prompt submit&lt;/strong&gt; searches Palace with your actual question and injects matching memories before the agent answers (Claude Code and Codex).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Post tool use&lt;/strong&gt; recalls related memory while the agent greps and reads files, so earlier decisions surface without a search.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Stop&lt;/strong&gt; asks the agent to write a diary entry and record decisions if the session did real work but saved nothing.&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;All hooks fail open: if the palace is missing or empty, the agent works as normal. Every result carries its wing, room, source file, drawer id and score breakdown, so you can see where an answer came from.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fjywdhkyzgd1eeakoaiqa.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fjywdhkyzgd1eeakoaiqa.png" alt="palace-rs four hooks: session start, prompt submit, post tool use, and stop; all hooks fail open" width="800" height="480"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Facts that change over time
&lt;/h2&gt;

&lt;p&gt;palace-rs has a temporal knowledge graph: subject → predicate → object, with a valid-from date. When a fact changes, the agent invalidates the old one and adds the new one, so the timeline keeps both. &lt;code&gt;palace_conflicts&lt;/code&gt; flags facts that look stale or contradictory.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F0w6g41fjsrfdizp329he.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F0w6g41fjsrfdizp329he.png" alt="palace-rs temporal knowledge graph: subject, predicate, object with a valid-from date; when a fact changes the old one is invalidated and the new one is added; palace_conflicts flags stale or contradictory facts" width="800" height="416"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Privacy
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;claude-mem:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;"Anonymous usage analytics are on by default." Its telemetry page says it uses PostHog and calls it "on by default (opt-out)". You turn it off with &lt;code&gt;npx claude-mem telemetry disable&lt;/code&gt; (or &lt;code&gt;DO_NOT_TRACK&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;The installer "asks you to sign in to claude-mem in your browser (email magic link)".&lt;/li&gt;
&lt;li&gt;Screenshots are "kept by default" under &lt;code&gt;~/.claude-mem/media-v1/&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;palace-rs:&lt;/strong&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;No telemetry. &lt;code&gt;palace gain&lt;/code&gt; statistics are written to your local database only.&lt;/p&gt;

&lt;p&gt;The only network calls are the one-time model download from Hugging Face and, if you turn it on, your own Palace Server in remote mode.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;No account, no sign-in, no analytics. Back up with &lt;code&gt;palace export&lt;/code&gt; or by copying &lt;code&gt;palace.db&lt;/code&gt;. Delete everything by removing &lt;code&gt;~/.palace&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F11bnhhhvje2h3o5b3kbp.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F11bnhhhvje2h3o5b3kbp.png" alt="claude-mem telemetry is on by default (PostHog, opt-out), sign-in at install, and screenshots kept by default; palace-rs has no telemetry, no account, and no sign-in" width="800" height="416"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Side by side
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;claude-mem 15.18.1&lt;/th&gt;
&lt;th&gt;palace-rs 0.20.0&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Language&lt;/td&gt;
&lt;td&gt;TypeScript&lt;/td&gt;
&lt;td&gt;Rust&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;What you run&lt;/td&gt;
&lt;td&gt;Node + Bun + uv/Python + Chroma + HTTP worker&lt;/td&gt;
&lt;td&gt;One &lt;code&gt;palace&lt;/code&gt; binary&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Storage&lt;/td&gt;
&lt;td&gt;SQLite + Chroma&lt;/td&gt;
&lt;td&gt;One SQLite file&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;What's stored&lt;/td&gt;
&lt;td&gt;Observations and summaries written by an LLM observer (default: Claude Haiku)&lt;/td&gt;
&lt;td&gt;Your files, chats and notes, verbatim&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;LLM / API key needed&lt;/td&gt;
&lt;td&gt;Yes (hosted observer, your key, or your Anthropic plan)&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Published retrieval benchmark&lt;/td&gt;
&lt;td&gt;None in README&lt;/td&gt;
&lt;td&gt;LongMemEval R@5 0.987, no LLM&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Telemetry&lt;/td&gt;
&lt;td&gt;On by default (PostHog), opt-out&lt;/td&gt;
&lt;td&gt;None&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Account / sign-in at install&lt;/td&gt;
&lt;td&gt;Yes (email magic link)&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;License&lt;/td&gt;
&lt;td&gt;Apache-2.0&lt;/td&gt;
&lt;td&gt;MIT&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;GitHub stars&lt;/td&gt;
&lt;td&gt;116,434&lt;/td&gt;
&lt;td&gt;10&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fxom7p2qd02qoa0fsu6ym.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fxom7p2qd02qoa0fsu6ym.png" alt="Side-by-side summary of claude-mem 15.18.1 and palace-rs 0.20.0 on language, stack, storage, what is stored, LLM need, published benchmark, telemetry, sign-in, license, and GitHub stars" width="800" height="544"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The point
&lt;/h2&gt;

&lt;p&gt;claude-mem is popular, and it covers a lot of agents. But popularity isn't architecture, and it isn't a benchmark.&lt;/p&gt;

&lt;p&gt;If you want memory that:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;is one binary you can audit,&lt;/li&gt;
&lt;li&gt;stores what happened rather than a model's summary of it,&lt;/li&gt;
&lt;li&gt;costs zero tokens to write,&lt;/li&gt;
&lt;li&gt;sends nothing anywhere,&lt;/li&gt;
&lt;li&gt;and comes with recall numbers you can reproduce,&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;that's palace-rs, today.&lt;/p&gt;

&lt;p&gt;Don't trust the stars. Don't trust me either. Every quote above is from the projects' own pages. Open them and check.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fp0bys94w9ag15st3lrp2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fp0bys94w9ag15st3lrp2.png" alt="Checklist: one binary you can audit, stores what happened rather than a model's summary, costs zero tokens to write, sends nothing anywhere, and comes with recall numbers you can reproduce" width="800" height="480"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# macOS / Linux&lt;/span&gt;
curl -fsSL https://raw.githubusercontent.com/AncientiCe/palace-rs/main/scripts/install.sh &lt;span class="o"&gt;|&lt;/span&gt; sh

&lt;span class="c"&gt;# Windows&lt;/span&gt;
irm https://raw.githubusercontent.com/AncientiCe/palace-rs/main/scripts/install.ps1 &lt;span class="o"&gt;|&lt;/span&gt; iex

palace install
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Sources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;palace-rs README: &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;https://github.com/AncientiCe/palace-rs&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;claude-mem README: &lt;a href="https://github.com/thedotmack/claude-mem" rel="noopener noreferrer"&gt;https://github.com/thedotmack/claude-mem&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;claude-mem &lt;code&gt;package.json&lt;/code&gt; (engines, version, license): &lt;a href="https://github.com/thedotmack/claude-mem/blob/main/package.json" rel="noopener noreferrer"&gt;https://github.com/thedotmack/claude-mem/blob/main/package.json&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;claude-mem default settings: &lt;a href="https://github.com/thedotmack/claude-mem/blob/main/src/shared/SettingsDefaultsManager.ts" rel="noopener noreferrer"&gt;https://github.com/thedotmack/claude-mem/blob/main/src/shared/SettingsDefaultsManager.ts&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;claude-mem telemetry doc: &lt;a href="https://github.com/thedotmack/claude-mem/blob/main/docs/public/telemetry.mdx" rel="noopener noreferrer"&gt;https://github.com/thedotmack/claude-mem/blob/main/docs/public/telemetry.mdx&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;LongMemEval: &lt;a href="https://github.com/xiaowu0162/LongMemEval" rel="noopener noreferrer"&gt;https://github.com/xiaowu0162/LongMemEval&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;Star counts and versions as of 2026-11-12.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>rust</category>
      <category>opensource</category>
      <category>productivity</category>
    </item>
    <item>
      <title>Stars Aren't Benchmarks: How a 10-Star Memory Tool Out-Scored the 60k-Star One</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Mon, 09 Nov 2026 12:00:37 +0000</pubDate>
      <link>https://dev.to/icegaming/stars-arent-benchmarks-how-a-10-star-memory-tool-out-scored-the-60k-star-one-42mk</link>
      <guid>https://dev.to/icegaming/stars-arent-benchmarks-how-a-10-star-memory-tool-out-scored-the-60k-star-one-42mk</guid>
      <description>&lt;p&gt;Open source has a discovery problem, and it isn't search. It's that &lt;strong&gt;attention gets mistaken for quality&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;A GitHub star costs one click. A benchmark run costs days or weeks of careful work. Yet when a developer goes looking for a tool, the star count decides what they try first. That decides which projects get issues filed, contributors, tutorials, and trust. Careful new tools get buried under whatever launched loudest.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fm9wxu65mha7z6lhvz550.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fm9wxu65mha7z6lhvz550.png" alt="A GitHub star costs one click; a benchmark run costs days or weeks of careful work" width="800" height="352"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I've been on the receiving end of this for a while, so let me make it concrete with numbers anyone can check.&lt;/p&gt;

&lt;h2&gt;
  
  
  The claim
&lt;/h2&gt;

&lt;p&gt;MemPalace is one of the most-starred open-source AI memory projects, with well over 60,000 stars. Its README describes it as the best-benchmarked open-source AI memory system.&lt;/p&gt;

&lt;p&gt;"Best-benchmarked" is a strong phrase. It isn't a statement about popularity or vibes. It's a statement about measurements, and measurements can be compared.&lt;/p&gt;

&lt;h2&gt;
  
  
  The numbers
&lt;/h2&gt;

&lt;p&gt;On &lt;strong&gt;LongMemEval&lt;/strong&gt; (500 questions, the &lt;code&gt;s_cleaned&lt;/code&gt; split), here is what each project publishes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;MemPalace (from its README):&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Mode&lt;/th&gt;
&lt;th&gt;R@5&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Raw&lt;/td&gt;
&lt;td&gt;96.6%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Hybrid (v4), held-out 450 questions&lt;/td&gt;
&lt;td&gt;98.4%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;With an LLM rerank step&lt;/td&gt;
&lt;td&gt;99% or higher&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;palace-rs (from its repo):&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Metric&lt;/th&gt;
&lt;th&gt;Result (all 500 questions)&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;R@1&lt;/td&gt;
&lt;td&gt;0.912&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;R@5&lt;/td&gt;
&lt;td&gt;0.986 (493 of 500)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;R@10&lt;/td&gt;
&lt;td&gt;0.994 (497 of 500)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F2tzsc59bzw6mhjahbdm6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F2tzsc59bzw6mhjahbdm6.png" alt="palace-rs on LongMemEval s_cleaned, all 500 questions: R@1 0.912, R@5 0.986 (493 of 500), R@10 0.994 (497 of 500)" width="800" height="416"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The benchmark itself is designed around &lt;strong&gt;470 questions&lt;/strong&gt;: the other 30 are abstention questions, which are meant to be excluded from retrieval scoring. On that standard 470-question set, palace-rs scores &lt;strong&gt;R@5 0.987 (98.7%)&lt;/strong&gt;. That is above MemPalace's 98.4% hybrid number, the one that depends on boosts built from looking at three specific questions, and it needs no such boosts. I report the all-500 figure above as well so nobody can say the exclusion flatters the result.&lt;/p&gt;

&lt;p&gt;The palace-rs run uses its normal exchange-pair chunking, a MiniLM-family local embedder, and hybrid search (BM25 weighted 0.35, cosine 0.65). It uses no generative LLM anywhere in the retrieval path. All 500 questions are scored, including the 30 abstention questions, which all have answer sessions and so can be scored for recall.&lt;/p&gt;

&lt;p&gt;That puts palace-rs at 98.6% R@5 against 96.6% raw. It's also slightly ahead of the 98.4% hybrid number, which is the one MemPalace itself calls its honest figure.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frae4gek49hlomgi5768o.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frae4gek49hlomgi5768o.png" alt="R@5 on LongMemEval s_cleaned: MemPalace raw 96.6% (all 500), MemPalace hybrid v4 98.4% (held-out 450), palace-rs 98.6% (all 500), palace-rs 98.7% (standard 470); MemPalace's 99%+ LLM-rerank result is a different system and not shown" width="800" height="464"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The gap is small. On 500 questions, 2 points is 10 questions. I'm not claiming a breakthrough. I'm making a narrower and more useful point: &lt;strong&gt;a project with about ten stars published the higher number, and nobody would have found out from the star count.&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Where the 98.4% comes from
&lt;/h2&gt;

&lt;p&gt;This part matters more than the headline, and MemPalace deserves credit for how it handled it.&lt;/p&gt;

&lt;p&gt;Its hybrid mode adds targeted boosts: one for quoted phrases, one for person names, and one for nostalgia-style phrasing. Those fixes were developed by looking at three specific questions out of the 500.&lt;/p&gt;

&lt;p&gt;That is a normal thing to do while improving a retriever. But fixing the failures you can see in the test set stops being a clean measurement. So they publish the held-out 450 as the honest number, which is the right call and the transparent one.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fdyji6kshorv4ef4y5qfy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fdyji6kshorv4ef4y5qfy.png" alt="MemPalace's hybrid boosts for quoted phrases, person names, and nostalgia-style phrasing came from 3 of the 500 questions, so its honest 98.4% is reported on the held-out 450; palace-rs reports all 500 with no parameters fitted on the test set" width="800" height="384"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Compare that with the approach palace-rs takes. It reports all 500, and no retrieval parameters were fitted on the test set. The weights, chunking, and scoring were set independently of those questions. Tuning retrieval for three particular questions is not the same thing as having a better baseline, and I'd rather publish the baseline.&lt;/p&gt;

&lt;h2&gt;
  
  
  The stack difference
&lt;/h2&gt;

&lt;p&gt;Benchmark numbers are one axis. What you actually have to run is another.&lt;/p&gt;

&lt;p&gt;MemPalace defaults to &lt;strong&gt;ChromaDB&lt;/strong&gt;. That's a vector database dependency: a service, a client library, a storage format, and a set of failure modes that come with it.&lt;/p&gt;

&lt;p&gt;palace-rs is &lt;strong&gt;one binary and one SQLite file&lt;/strong&gt;. Embeddings are computed locally. There is no server to start, no extra process, and nothing to keep in sync. You can copy the whole memory by copying a file. You can back it up with &lt;code&gt;cp&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F32l9mmt3h57kmaxcqoly.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F32l9mmt3h57kmaxcqoly.png" alt="MemPalace defaults to ChromaDB (a service, a client library, a storage format, and its failure modes); palace-rs is one binary with local embeddings and one SQLite file" width="800" height="400"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Simpler to run, and (on published numbers) not worse at retrieval. That combination is the thing I'd want to know about if I were choosing a tool, and star counts hide it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why this is bigger than two repos
&lt;/h2&gt;

&lt;p&gt;I don't actually care about the 2 points. I care about what the situation shows.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Stars are a poor proxy for quality, and we use them as one anyway.&lt;/strong&gt; A star is cheap, public, and instantly legible. Quality is expensive, takes effort to verify, and doesn't fit in a badge. So the cheap signal wins by default.&lt;/p&gt;

&lt;p&gt;That causes real damage:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Good tools starve.&lt;/strong&gt; A new project doing careful work has no way to get in front of people who'd benefit from it. Without attention it doesn't get issues, without issues it doesn't improve, and without improvement it never earns attention.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Marketing rewards itself.&lt;/strong&gt; A strong claim attracts stars, and stars make the claim look more credible, which attracts more stars. At no point does a measurement have to enter the loop.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Users inherit the cost.&lt;/strong&gt; If the popular option is heavier, slower to set up, or less accurate than a quieter alternative, every adopter pays for that, and most never find out.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Claims drift.&lt;/strong&gt; When a superlative like "best" is never checked, it stops needing to be true. It only needs to be said first and loudest.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ffa7cg0t1ch7ma0ev55if.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ffa7cg0t1ch7ma0ev55if.png" alt="Feedback loop: a strong claim attracts stars, stars make the claim look more credible, credibility attracts more stars; measurement never enters the loop" width="800" height="344"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;None of this requires bad faith. A popular project can make an honest claim that simply becomes outdated, and a launch can go viral for reasons unrelated to engineering. But a claim stays rubbish if it's wrong, however many stars sit next to it.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I'd like to see instead
&lt;/h2&gt;

&lt;p&gt;If we want popularity to track quality even loosely, claims about quality have to be cheaper to check. A few habits would help:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Publish reproducible commands.&lt;/strong&gt; If I can't rerun your benchmark in one command, it's an anecdote.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Publish per-question outputs, not just aggregates.&lt;/strong&gt; Aggregates hide where a system fails. Per-question results let anyone audit them.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Separate tuned from held-out numbers.&lt;/strong&gt; If you fixed failures you saw in the test set, say so and report the clean split too. MemPalace does this, and more projects should.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;State what's in the loop.&lt;/strong&gt; "No generative LLM" and "with an LLM rerank" are different systems. Put them in different rows.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Report on the full, standard question set.&lt;/strong&gt; Same dataset and same question count is what makes two READMEs comparable at all.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Treat superlatives as claims.&lt;/strong&gt; "Best", "fastest", and "most accurate" need a measurement and a date next to them.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fwjict2qi1hc7ls3p9ujd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fwjict2qi1hc7ls3p9ujd.png" alt="Six habits: publish reproducible commands, publish per-question outputs, separate tuned from held-out numbers, state what's in the loop, report on the full standard question set, treat superlatives as claims" width="800" height="480"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What this post does not prove
&lt;/h2&gt;

&lt;p&gt;I want to be clear about the limits, because a post about checking claims should hold itself to the same standard.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Each project ran its own runner.&lt;/strong&gt; Both numbers are on the same 500 LongMemEval questions, so the comparison is like for like on the data. Anyone who wants to rule out runner differences can rerun both.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;LongMemEval S is one benchmark.&lt;/strong&gt; It says nothing about every kind of memory workload. I'm comparing on the split both projects report, not claiming a win everywhere.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Two points is small.&lt;/strong&gt; It's enough to disprove "nobody is ahead". It's not enough to call anyone dramatically better.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;MemPalace also reports a 99%-or-higher figure with an LLM rerank step.&lt;/strong&gt; That's a different system with a generative model in the loop. I'm comparing retrieval without one.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Check it yourself
&lt;/h2&gt;

&lt;p&gt;The palace-rs run is on all 500 questions, with the command and per-question outputs in the repo. MemPalace's 96.6% is on the same 500. Rerun either one and tell me if you get different numbers.&lt;/p&gt;

&lt;p&gt;If you maintain a memory tool, an agent framework, or anything else with a benchmark number in the README, do the same. Give the command, give the raw outputs, and let people check.&lt;/p&gt;

&lt;h2&gt;
  
  
  The takeaway
&lt;/h2&gt;

&lt;p&gt;The next time you pick a tool, put the star count aside for a minute and ask three questions:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;What exactly did they measure?&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Can I reproduce it?&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;What do I have to run to get it?&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ffeab76bw46a4unftxoei.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ffeab76bw46a4unftxoei.png" alt="Three questions before picking a tool: What exactly did they measure? Can I reproduce it? What do I have to run to get it?" width="800" height="368"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If the answer to all three is on the page, that tool has earned your attention, with ten stars or sixty thousand.&lt;/p&gt;

&lt;p&gt;The numbers are public. Check them. Don't trust the stars, and don't just trust me either.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;palace-rs is a local-first AI memory tool: one Rust binary, one SQLite file, no external services. Repo and benchmark outputs below.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Links
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;palace-rs: &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;https://github.com/AncientiCe/palace-rs&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;MemPalace: &lt;a href="https://github.com/mempalace/mempalace" rel="noopener noreferrer"&gt;https://github.com/mempalace/mempalace&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;LongMemEval benchmark: &lt;a href="https://github.com/xiaowu0162/LongMemEval" rel="noopener noreferrer"&gt;https://github.com/xiaowu0162/LongMemEval&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>opensource</category>
      <category>ai</category>
      <category>rust</category>
      <category>productivity</category>
    </item>
    <item>
      <title>Knowledge graphs, explained for AI memory (and how Palace uses one)</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Tue, 03 Nov 2026 15:53:59 +0000</pubDate>
      <link>https://dev.to/icegaming/knowledge-graphs-explained-for-ai-memory-and-how-palace-uses-one-1g67</link>
      <guid>https://dev.to/icegaming/knowledge-graphs-explained-for-ai-memory-and-how-palace-uses-one-1g67</guid>
      <description>&lt;p&gt;Most AI memory systems today come down to the same recipe. Split text into chunks, turn each chunk into an embedding, store the vectors, and when a question comes in, return the chunks closest to it. That recipe works well, and it's the backbone of &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;Palace&lt;/a&gt;, the memory server I build for coding agents.&lt;/p&gt;

&lt;p&gt;Some questions, though, it answers badly. "What database does the billing service use &lt;strong&gt;now&lt;/strong&gt;?" "Who owns the deploy pipeline?" "Which services depend on this queue?" Those are questions about &lt;strong&gt;facts&lt;/strong&gt;: things with one current answer, a history of past answers, and connections to other things.&lt;/p&gt;

&lt;p&gt;That's what knowledge graphs are for. This post covers what a knowledge graph is, why it complements vector search instead of replacing it, what adding time to it changes, and what it costs. It ends with how Palace uses one, including where Palace keeps it deliberately simple.&lt;/p&gt;

&lt;h2&gt;
  
  
  What a knowledge graph is
&lt;/h2&gt;

&lt;p&gt;A knowledge graph stores knowledge as &lt;strong&gt;entities&lt;/strong&gt; and the &lt;strong&gt;relationships&lt;/strong&gt; between them.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;An &lt;strong&gt;entity&lt;/strong&gt; is a thing you can name: a person, a service, a library, a team, a decision.&lt;/li&gt;
&lt;li&gt;A &lt;strong&gt;relationship&lt;/strong&gt; is a typed, directed link between two entities: &lt;code&gt;depends_on&lt;/code&gt;, &lt;code&gt;owned_by&lt;/code&gt;, &lt;code&gt;uses_queue&lt;/code&gt;, &lt;code&gt;replaced_by&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The basic unit is a &lt;strong&gt;triple&lt;/strong&gt;: subject, predicate, object.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight dot"&gt;&lt;code&gt;&lt;span class="nv"&gt;billing_service&lt;/span&gt;  &lt;span class="err"&gt;→&lt;/span&gt;  &lt;span class="nv"&gt;uses_database&lt;/span&gt;  &lt;span class="err"&gt;→&lt;/span&gt;  &lt;span class="nv"&gt;Postgres&lt;/span&gt;
&lt;span class="nv"&gt;billing_service&lt;/span&gt;  &lt;span class="err"&gt;→&lt;/span&gt;  &lt;span class="nv"&gt;owned_by&lt;/span&gt;       &lt;span class="err"&gt;→&lt;/span&gt;  &lt;span class="nv"&gt;payments_team&lt;/span&gt;
&lt;span class="nv"&gt;payments_team&lt;/span&gt;    &lt;span class="err"&gt;→&lt;/span&gt;  &lt;span class="nv"&gt;reports_to&lt;/span&gt;     &lt;span class="err"&gt;→&lt;/span&gt;  &lt;span class="nv"&gt;Dana&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F8uafca1td7wj2dgpjh25.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F8uafca1td7wj2dgpjh25.png" alt="Three triples drawn as a graph: billing_service uses_database Postgres, billing_service owned_by payments_team, payments_team reports_to Dana" width="800" height="400"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Put enough triples together and you get a graph: entities are the nodes, relationships are the edges. Since every edge has a type, you can ask precise questions, like "follow &lt;code&gt;owned_by&lt;/code&gt; out of &lt;code&gt;billing_service&lt;/code&gt;" or "find everything with a &lt;code&gt;uses_database&lt;/code&gt; edge pointing at &lt;code&gt;Postgres&lt;/code&gt;."&lt;/p&gt;

&lt;p&gt;The idea isn't new. The W3C's RDF standard has modeled data as triples for over two decades, and Wikidata stores its facts that way. Google introduced its Knowledge Graph in 2012 under the slogan "things, not strings." That slogan is the core idea: a knowledge graph stores &lt;em&gt;things&lt;/em&gt; and how they relate, not text that happens to mention them.&lt;/p&gt;

&lt;p&gt;There are two common styles:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;RDF / triple stores&lt;/strong&gt;: everything is a triple, queried with SPARQL.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Property graphs&lt;/strong&gt; (Neo4j and similar): nodes and edges can carry key/value properties, queried with languages like Cypher.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;For agent memory, the distinction matters less than the core idea: knowledge as explicit, typed, queryable links.&lt;/p&gt;

&lt;h2&gt;
  
  
  What vector search is good at, and what it isn't
&lt;/h2&gt;

&lt;p&gt;To see why a graph helps, be clear about what embeddings do.&lt;/p&gt;

&lt;p&gt;An embedding model maps text to a point in a high-dimensional space, so that text with similar meaning lands close together. Vector search finds the stored chunks nearest to your question. It's very good at:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Fuzzy recall.&lt;/strong&gt; You can ask "that time the build broke because of the lockfile" without knowing any exact words.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Evidence.&lt;/strong&gt; It returns the original text, with all its nuance and reasoning.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Zero structure up front.&lt;/strong&gt; Nobody has to decide a schema before storing anything.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Its weaknesses all follow from one property: &lt;strong&gt;similarity isn't truth&lt;/strong&gt;.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;It doesn't know what's current.&lt;/strong&gt; Suppose your team moved a queue from Redis to SQLite in October. Memory now holds a long March thread about tuning Redis and a short October note saying "switched to SQLite." Ask "which queue do we use?" and both match well. The detailed Redis thread may well rank higher. Nothing in the vectors records that one superseded the other.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Facts get scattered.&lt;/strong&gt; "Billing uses Postgres" may never appear as one sentence. It's spread across a config discussion, a migration log, and a code review. Each chunk holds part of the fact.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;It can't enumerate.&lt;/strong&gt; "Which services use Postgres?" is a question about &lt;em&gt;all&lt;/em&gt; matches. Top-k search returns the k most similar chunks, not a complete list.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;It can't detect contradictions.&lt;/strong&gt; Two chunks that disagree are just two nearby points. Nothing marks them as a conflict.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A knowledge graph covers exactly these weak spots. It doesn't replace search, because a triple keeps no nuance and no reasoning. Search gives you the &lt;em&gt;evidence&lt;/em&gt;. The graph gives you the &lt;em&gt;state&lt;/em&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Adding time: temporal knowledge graphs
&lt;/h2&gt;

&lt;p&gt;A plain knowledge graph has a problem of its own: facts change. If you just overwrite &lt;code&gt;uses_queue → Redis&lt;/code&gt; with &lt;code&gt;uses_queue → SQLite&lt;/code&gt;, you lose the history. Worse, you lose the context that makes old evidence readable. A future reader who finds the March Redis thread can't tell it describes the past.&lt;/p&gt;

&lt;p&gt;A &lt;strong&gt;temporal knowledge graph&lt;/strong&gt; gives each fact a validity interval:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;my_api → uses_queue → Redis    valid 2026-03-02 … 2026-10-12
my_api → uses_queue → SQLite   valid 2026-10-12 … (still true)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frnz3fnqros9uihsn3b2d.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frnz3fnqros9uihsn3b2d.png" alt="Timeline of my_api uses_queue: Redis valid from 2026-03-02 to 2026-10-12, then SQLite from 2026-10-12 with no end date" width="800" height="416"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Three things follow:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Facts are ended, not deleted.&lt;/strong&gt; When something stops being true, you close its interval. The record stays.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;"Current" is a query, not a guess.&lt;/strong&gt; A fact with no end date is the current one.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;You can ask about the past.&lt;/strong&gt; "What did we use in June?" filters to facts valid on that date.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The database world calls this &lt;em&gt;valid time&lt;/em&gt;: when a fact was true in reality. It's different from &lt;em&gt;transaction time&lt;/em&gt;: when the system recorded it. Systems that track both are called &lt;em&gt;bitemporal&lt;/em&gt;. Valid time is usually what an agent needs, because the question is "what's true?", not "when did someone write it down?"&lt;/p&gt;

&lt;h2&gt;
  
  
  What a knowledge graph adds to retrieval
&lt;/h2&gt;

&lt;p&gt;Put vector search and a temporal graph side by side, and an agent gets several things it didn't have before:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;A direct answer for state questions.&lt;/strong&gt; "Which queue does my_api use?" turns into an exact lookup that returns one current fact. There's no similarity ranking to second-guess.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Context for interpreting search results.&lt;/strong&gt; The graph also says Redis was in use until October 12. When search turns up the March thread, the agent knows it's history, not instructions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Reverse and complete lookups.&lt;/strong&gt; Following an edge backwards ("what points at SQLite?") returns every match, not the top k.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Contradiction detection.&lt;/strong&gt; Two current facts with the same subject and predicate but different objects are a structural signal. Something changed and nobody closed out the old fact, or two sources disagree.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Compactness.&lt;/strong&gt; A triple is a handful of tokens. Stating a fact as a triple is far cheaper to put in a model's context than the paragraphs that originally established it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multi-hop questions.&lt;/strong&gt; Graphs make it natural to chain relationships: billing → owned_by → payments team → reports_to → Dana. Each hop is a precise step, not another fuzzy search.&lt;/p&gt;

&lt;h2&gt;
  
  
  What knowledge graphs cost
&lt;/h2&gt;

&lt;p&gt;Graphs aren't free, and pretending otherwise is how graph projects fail.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Entity resolution.&lt;/strong&gt; Are "Postgres", "PostgreSQL" and "pg" one thing or three? If you get it wrong, the graph splits one fact into several pieces, or merges facts that should stay separate. This is one of the hardest problems in the field.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Schema drift.&lt;/strong&gt; Without discipline you end up with &lt;code&gt;uses_db&lt;/code&gt;, &lt;code&gt;uses_database&lt;/code&gt; and &lt;code&gt;database_is&lt;/code&gt;, all meaning the same thing.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Getting facts in.&lt;/strong&gt; Someone has to write the triples. Systems such as Microsoft's GraphRAG use an LLM to extract them from text automatically. That scales, but extraction makes mistakes, and those mistakes become "facts." Writing triples explicitly is accurate but needs a writer who reliably does it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Maintenance.&lt;/strong&gt; A temporal graph only stays correct if old facts get closed when new ones arrive.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  How Palace uses a knowledge graph
&lt;/h2&gt;

&lt;p&gt;Palace stores memory in two complementary forms. By default, both live in the same local SQLite file:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Drawers&lt;/strong&gt;: verbatim chunks of code, conversations, notes and diaries, retrieved by hybrid search (BM25 keyword scoring plus embedding similarity). This is the evidence.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A temporal knowledge graph&lt;/strong&gt;: entities and triples with &lt;code&gt;valid_from&lt;/code&gt; / &lt;code&gt;valid_to&lt;/code&gt; dates. This is the state.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F67wdihr7007g9o1k8pmk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F67wdihr7007g9o1k8pmk.png" alt="Inside palace.db: drawers found by hybrid search hold the evidence, the temporal knowledge graph holds the state. They don't feed each other. The agent asks both, with palace_search and palace_kg_query" width="800" height="448"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The two don't feed into each other. Search doesn't read the graph, and the graph doesn't rank drawers. Instead, the memory protocol Palace gives agents asks for both before answering anything about past decisions:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;→ palace_search + palace_kg_query — never answer from training data alone.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Here's how the queue example plays out in practice.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Writing a fact.&lt;/strong&gt; After the agent learns that my_api uses Redis, it records that:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;palace_kg_add  my_api → uses queue → Redis   (valid_from 2026-03-02)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Palace normalizes names on the way in. &lt;code&gt;My API&lt;/code&gt;, &lt;code&gt;my api&lt;/code&gt; and &lt;code&gt;my_api&lt;/code&gt; all resolve to the same entity, and &lt;code&gt;uses queue&lt;/code&gt; is the same relationship as &lt;code&gt;uses_queue&lt;/code&gt;. Adding a fact that's already current returns the existing one instead of a duplicate. It's a lightweight form of entity resolution: it covers case and spacing, not synonyms.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Changing a fact.&lt;/strong&gt; In October the agent closes out the old fact and adds the new one:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;palace_kg_invalidate  my_api → uses_queue → Redis    (ended 2026-10-12)
palace_kg_add         my_api → uses_queue → SQLite   (valid_from 2026-10-12)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Nothing is deleted. The Redis fact gets an end date and stays as history.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Confidence is binary on purpose.&lt;/strong&gt; Graphs built by automatic extraction often attach a probability to each fact, and then every reader has to decide what a 0.6 means. Palace stores every fact at full confidence (1.0). When an agent decides a fact is no longer true, it doesn't lower a score. It invalidates the fact. So the graph never holds half-believed facts: a fact is either current or ended, and the dates record when it changed.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Reading it back.&lt;/strong&gt; &lt;code&gt;palace_kg_query&lt;/code&gt; on &lt;code&gt;my_api&lt;/code&gt; returns both facts, each flagged:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;my_api → uses_queue → Redis    2026-03-02 … 2026-10-12   current: false
my_api → uses_queue → SQLite   2026-10-12 …              current: true
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The agent now has the current answer &lt;em&gt;and&lt;/em&gt; the context to read older search results correctly. The same tool takes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a &lt;code&gt;direction&lt;/code&gt; to follow edges backwards ("what uses SQLite?")&lt;/li&gt;
&lt;li&gt;an &lt;code&gt;as_of&lt;/code&gt; date for point-in-time questions. Both ends of the interval count, so on the switch day itself, both facts come back.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Catching contradictions.&lt;/strong&gt; &lt;code&gt;palace_conflicts&lt;/code&gt; lists every subject and predicate pair with more than one distinct object. It includes properly closed-out history like the example above, so it's a review list, not a verdict. The case to act on is a group where more than one fact is still marked current.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Linking state to evidence.&lt;/strong&gt; A fact can store an optional &lt;code&gt;source_closet&lt;/code&gt; pointing at the stored memory that justifies it, so the short triple can lead back to the full discussion.&lt;/p&gt;

&lt;h3&gt;
  
  
  Solving "someone has to write the facts"
&lt;/h3&gt;

&lt;p&gt;This is the cost that sinks most graph efforts, so it's worth being specific. Palace doesn't extract triples from text automatically. Agents add them on purpose, and Palace works to make sure they do:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The protocol that ships in the MCP server's instructions says to use &lt;code&gt;palace_kg_add&lt;/code&gt; for stable facts, and &lt;code&gt;palace_kg_invalidate&lt;/code&gt; plus &lt;code&gt;palace_kg_add&lt;/code&gt; when facts change.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;palace_kg_query&lt;/code&gt; and &lt;code&gt;palace_kg_add&lt;/code&gt; are pinned, so clients that defer MCP tools behind a search still keep them loaded.&lt;/li&gt;
&lt;li&gt;Session hooks remind the agent to save durable facts, including invalidating changed ones first, before it finishes.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The agent writing the fact is already an LLM, and it has the full task context, so there's no need for a second model reading raw messages after the fact. The graph contains what agents decided was worth stating as a fact, not whatever an extractor guessed.&lt;/p&gt;

&lt;h3&gt;
  
  
  Where Palace keeps it simple
&lt;/h3&gt;

&lt;p&gt;The graph is deliberately small. These are its current limits:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;One hop per query.&lt;/strong&gt; Multi-hop questions mean the agent chains calls itself.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Exact names.&lt;/strong&gt; After normalizing case and spacing, the graph matches names exactly, so &lt;code&gt;Postgres&lt;/code&gt; and &lt;code&gt;PostgreSQL&lt;/code&gt; are two entities. Search is the fuzzy layer. It finds the memories that say "PostgreSQL" when the question says "Postgres", and the agent then queries the graph under that name. If two agents record the same fact with different object names, &lt;code&gt;palace_conflicts&lt;/code&gt; flags the pair.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Valid time only.&lt;/strong&gt; Each triple keeps a creation timestamp, but queries filter on validity dates only.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Takeaway
&lt;/h2&gt;

&lt;p&gt;Vector search answers "what have we said about this?" A temporal knowledge graph answers "what is true about this, and since when?" Agent memory needs both. Without the graph, an agent can't tell current facts from history. Without search, it has facts but no reasoning behind them.&lt;/p&gt;

&lt;p&gt;Palace pairs the two in one local file and gets agents to keep the graph up to date. Every connected agent reads and writes the same palace, so a fact Claude Code records today is there for Cursor or Codex in their next session, with the same history of what changed and when.&lt;/p&gt;

&lt;p&gt;Palace is open source (MIT) at &lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;github.com/AncientiCe/palace-rs&lt;/a&gt;. &lt;code&gt;palace install&lt;/code&gt; connects 11 agents over MCP: Claude Code, Codex, Cursor, Gemini CLI, VS Code, OpenCode, Cline, Zed, Goose, Windsurf and Claude Desktop.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;If you want one shared memory across a whole team, that's what we're building at &lt;a href="https://palacememory.com" rel="noopener noreferrer"&gt;palacememory.com&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>mcp</category>
      <category>rag</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Your RAG doesn't need a better embedding model. It needs better chunking.</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Fri, 30 Oct 2026 08:33:20 +0000</pubDate>
      <link>https://dev.to/icegaming/your-rag-doesnt-need-a-better-embedding-model-it-needs-better-chunking-33om</link>
      <guid>https://dev.to/icegaming/your-rag-doesnt-need-a-better-embedding-model-it-needs-better-chunking-33om</guid>
      <description>&lt;p&gt;For the last week I've been running LongMemEval against Palace, a local memory store I build for coding agents. It's a single Rust binary with SQLite, BM25 and a small ONNX embedding model. No LLM sits anywhere in the write or recall path.&lt;/p&gt;

&lt;p&gt;This post isn't about the final number. It's about what I learned getting there: which changes moved recall, which didn't, and how many of the improvements turned out to be plain bugs that only a benchmark run would surface.&lt;/p&gt;

&lt;p&gt;Short version, so you can stop here if you want:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Swapping embedding models did nothing on this dataset. Every difference was 1 to 4 questions.&lt;/li&gt;
&lt;li&gt;Chunking conversations the way the product actually stores them helped more than anything else.&lt;/li&gt;
&lt;li&gt;The ranking gains were mostly bug fixes. A substring match, an overeager phrase rule, and a chunker that silently dropped text.&lt;/li&gt;
&lt;li&gt;int8 models give different vectors depending on what else is in the batch. That one surprised me.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fo97ash1odiah02tenf6s.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fo97ash1odiah02tenf6s.png" alt="Final retrieval recall, session drawers vs exchange pairs" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What's being measured
&lt;/h2&gt;

&lt;p&gt;LongMemEval asks questions about a long chat history. In the &lt;code&gt;s_cleaned&lt;/code&gt; split each question comes with a haystack of about 50 sessions (about 115k tokens), and somewhere in there are the sessions that hold the answer. 470 questions get scored; the 30 abstention questions are excluded, as usual.&lt;/p&gt;

&lt;p&gt;I only measure &lt;strong&gt;retrieval&lt;/strong&gt;: did the right session show up in the top K? The metric is &lt;code&gt;recall_any@K&lt;/code&gt; at session granularity. That is not the same thing as the end-to-end QA accuracy many memory systems report, where an LLM reads the retrieved context and answers. Retrieval recall is an upper bound on what a reader model can do, and it's the part I control. So please don't line these numbers up against QA accuracy tables. They measure different things.&lt;/p&gt;

&lt;p&gt;Setup for every run in this post:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Windows, 16 threads, CPU only&lt;/li&gt;
&lt;li&gt;MiniLM-L6-v2 (384-dim) unless stated otherwise, 512-token cap&lt;/li&gt;
&lt;li&gt;Hybrid search: BM25 fused with cosine, plus the product's normal ranking boosts&lt;/li&gt;
&lt;li&gt;No LLM at any stage: no extraction at ingest, no query rewriting, no answer generation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;One number worth keeping in your head the whole way through: &lt;strong&gt;one question is 0.0021&lt;/strong&gt;. On 470 questions, a "+0.4 points" improvement is two questions. I'll say how many questions a change moved wherever I can, because decimals make small things look bigger than they are.&lt;/p&gt;

&lt;h2&gt;
  
  
  Starting point: the number had drifted
&lt;/h2&gt;

&lt;p&gt;Back in May the README said R@5 0.981. When I reran the same configuration in October, I got 0.977.&lt;/p&gt;

&lt;p&gt;My first instinct was "noise, run it again." But there's no noise here. The retrieval is deterministic: fixed ONNX model, BM25, cosine, no sampling. A rerun gives the same 0.977 every time. So two questions had genuinely moved, and something in the code had moved them.&lt;/p&gt;

&lt;p&gt;Since May, the ranker had grown a few extra boosts on top of the plain BM25/cosine fusion: coding-agent intent boosts, preference matching, recency. I diffed the per-question results against the May baseline and found the first culprit:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The query contained the word &lt;strong&gt;"latest"&lt;/strong&gt;. The intent classifier saw &lt;strong&gt;"test"&lt;/strong&gt; inside it, decided this was a question about running tests, and lifted an unrelated drawer into the top five.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The fix was to match intent terms only at word starts (inflections still match). R@5 went from 0.977 to 0.979. The coding-agent eval didn't change.&lt;/p&gt;

&lt;p&gt;Lesson one: &lt;strong&gt;a benchmark number in your README is a claim about your current code.&lt;/strong&gt; If the ranker changes, the number has to be re-earned. Reproducing an old number is a good way to find out what broke.&lt;/p&gt;

&lt;h2&gt;
  
  
  The model swap that changed nothing
&lt;/h2&gt;

&lt;p&gt;I had just added support for switchable embedding models, so the obvious question was whether a better model would help. I ran five of them through the same per-session configuration:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Model&lt;/th&gt;
&lt;th&gt;R@1&lt;/th&gt;
&lt;th&gt;R@5&lt;/th&gt;
&lt;th&gt;R@10&lt;/th&gt;
&lt;th&gt;Ingest&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;minilm-l6-v2&lt;/code&gt; (fp32)&lt;/td&gt;
&lt;td&gt;0.889&lt;/td&gt;
&lt;td&gt;0.977&lt;/td&gt;
&lt;td&gt;0.991&lt;/td&gt;
&lt;td&gt;508 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;minilm-l6-v2-q8&lt;/code&gt; (int8)&lt;/td&gt;
&lt;td&gt;0.891&lt;/td&gt;
&lt;td&gt;0.977&lt;/td&gt;
&lt;td&gt;0.991&lt;/td&gt;
&lt;td&gt;355 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;bge-small&lt;/code&gt; (fp32)&lt;/td&gt;
&lt;td&gt;0.898&lt;/td&gt;
&lt;td&gt;0.972&lt;/td&gt;
&lt;td&gt;0.985&lt;/td&gt;
&lt;td&gt;920 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;bge-small-q8&lt;/code&gt; (int8)&lt;/td&gt;
&lt;td&gt;0.898&lt;/td&gt;
&lt;td&gt;0.972&lt;/td&gt;
&lt;td&gt;0.985&lt;/td&gt;
&lt;td&gt;622 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;code&gt;bge-base-q8&lt;/code&gt; (int8, 768-dim)&lt;/td&gt;
&lt;td&gt;0.887&lt;/td&gt;
&lt;td&gt;0.970&lt;/td&gt;
&lt;td&gt;0.979&lt;/td&gt;
&lt;td&gt;1181 s&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fbtgxkxwbwwuiuufemdcz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fbtgxkxwbwwuiuufemdcz.png" alt="Five embedding models, recall vs ingest time" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Every recall difference in that table is between 1 and 4 questions. BGE got a slightly better R@1, mostly on single-session-user questions, and paid for it with worse R@5 and R@10 on multi-session ones. Nothing beat MiniLM in a way I'd be willing to call real.&lt;/p&gt;

&lt;p&gt;What &lt;em&gt;was&lt;/em&gt; real was the speed. The int8 MiniLM gave the same recall with about 1.4x faster ingest. That made it the interesting option, not because it's smarter but because it's cheaper for the same answer.&lt;/p&gt;

&lt;p&gt;Lesson two: &lt;strong&gt;on a retrieval benchmark, the embedding model was not the bottleneck.&lt;/strong&gt; I'd assumed it would be. Twelve-layer models cost twice as much per embedding as six-layer ones, and on this data I got nothing back for it.&lt;/p&gt;

&lt;h3&gt;
  
  
  A detour: batching was slower than not batching
&lt;/h3&gt;

&lt;p&gt;While sizing the model work I measured embedding throughput on real drawers and found something backwards: embedding one text at a time did 94 drawers/s, and batching made it &lt;em&gt;slower&lt;/em&gt;. 69/s at batch 16, 53/s at 32, 42/s at 64.&lt;/p&gt;

&lt;p&gt;The cause was padding. A batch gets padded to its longest text, so one long drawer makes every short drawer in the batch pay for its length. Sorting texts by length and capping batches at 8 took it from 29/s (the old batched path) to about 110/s.&lt;/p&gt;

&lt;h3&gt;
  
  
  Another detour: int8 vectors depend on their neighbours
&lt;/h3&gt;

&lt;p&gt;Later, when I made the int8 model the default for new palaces, an existing test started failing. It checks that embedding a text in a batch gives the same vector as embedding it alone.&lt;/p&gt;

&lt;p&gt;For fp32 the worst cosine between "batched" and "alone" was 0.999999. For int8 it was &lt;strong&gt;0.976&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Dynamically quantized ONNX models compute their activation scales over the whole input tensor. That means the whole batch. Put a text next to a long, unusual neighbour and its vector shifts. For a memory store that's a real problem: the same sentence could land in a slightly different place depending on what else happened to be mined in the same call.&lt;/p&gt;

&lt;p&gt;The fix: int8 models embed one text per call. That costs some of the speedup, but the q8 model still indexes faster than fp32 (150 vs 132 drawers/s on real palace drawers, about 1.7x on longer synthetic ones), and now a text's vector depends only on the text.&lt;/p&gt;

&lt;p&gt;I wouldn't have found this without the switch, and I wouldn't have switched without the benchmark telling me q8 was "free."&lt;/p&gt;

&lt;h2&gt;
  
  
  Chunking: measure what you ship
&lt;/h2&gt;

&lt;p&gt;The usual LongMemEval setup stores each session as one document. That's not how Palace stores conversations. When it mines a chat log it splits it into &lt;strong&gt;exchange pairs&lt;/strong&gt;: one chunk per user turn plus the reply to it.&lt;/p&gt;

&lt;p&gt;So the benchmark was measuring a configuration no user ever runs. I added a &lt;code&gt;--chunking&lt;/code&gt; flag to the runner with three modes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;session&lt;/code&gt;: one drawer per session (the standard setup)&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;text&lt;/code&gt;: the generic paragraph chunker used for project files&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;exchange&lt;/code&gt;: each session goes through the exact normaliser and chunker that &lt;code&gt;palace mine-convos&lt;/code&gt; uses&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In the chunked modes a session ranks by its best chunk.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Chunking (q8)&lt;/th&gt;
&lt;th&gt;R@1&lt;/th&gt;
&lt;th&gt;R@5&lt;/th&gt;
&lt;th&gt;R@10&lt;/th&gt;
&lt;th&gt;Drawers&lt;/th&gt;
&lt;th&gt;Ingest&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;session&lt;/td&gt;
&lt;td&gt;0.891&lt;/td&gt;
&lt;td&gt;0.979&lt;/td&gt;
&lt;td&gt;0.991&lt;/td&gt;
&lt;td&gt;22k&lt;/td&gt;
&lt;td&gt;351 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;text&lt;/td&gt;
&lt;td&gt;0.896&lt;/td&gt;
&lt;td&gt;0.983&lt;/td&gt;
&lt;td&gt;0.996&lt;/td&gt;
&lt;td&gt;401k&lt;/td&gt;
&lt;td&gt;1016 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;exchange&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;0.906&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;0.985&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;0.994&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;194k&lt;/td&gt;
&lt;td&gt;1150 s&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fbkupk0x7atphovcqj6ry.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fbkupk0x7atphovcqj6ry.png" alt="A session split into exchange-pair chunks" width="800" height="550"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Exchange pairs won, and the biggest move was where I least expected it: &lt;strong&gt;single-session-preference R@1 went from 0.633 to 0.767&lt;/strong&gt;. A preference (say, "I've been trying to cut down on caffeine") is usually one sentence buried in a long session about something else. As one big document, the session's embedding is dominated by everything else. As an exchange pair, the preference turn gets a vector of its own.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;text&lt;/code&gt; mode is a useful contrast. It has twice as many drawers as &lt;code&gt;exchange&lt;/code&gt; and does worse. More, smaller chunks isn't the point. Chunks that follow the shape of the conversation are.&lt;/p&gt;

&lt;h3&gt;
  
  
  The chunker was dropping text
&lt;/h3&gt;

&lt;p&gt;Wiring the real chunker into the benchmark turned up a bug in the product. The exchange chunker kept the user turn and the first &lt;strong&gt;8 lines&lt;/strong&gt; of the reply, and silently dropped the rest. Any long assistant answer lost everything after line 8.&lt;/p&gt;

&lt;p&gt;Nobody had noticed because nothing ever compared mined conversations against the original. Running the real chunker over thousands of sessions with known answers did.&lt;/p&gt;

&lt;p&gt;Replies are now kept whole. An exchange over about 2,000 characters continues in further chunks that each repeat the user turn, so the question context travels with every piece of the answer. Short sessions with fewer than three user turns fall back to paragraph chunks, the same as in the product.&lt;/p&gt;

&lt;p&gt;Lesson three: &lt;strong&gt;benchmark the code path your users run, not a convenient stand-in.&lt;/strong&gt; If I'd kept the one-document-per-session setup I'd have a slightly lower number and a chunker that was still eating replies.&lt;/p&gt;

&lt;h2&gt;
  
  
  Ranking: three general mechanisms and one bad rule
&lt;/h2&gt;

&lt;p&gt;At this point I set myself a rule, which I'll quote because it shaped everything after it: &lt;em&gt;"We're not tuning for the score, we're tuning for the output."&lt;/em&gt; LongMemEval is a proxy. Reading the misses to find general weaknesses is fine. Writing rules that fix specific questions isn't. Any change has to be a mechanism that would help a real palace, and has to be checked on data other than the data that inspired it before a number gets published.&lt;/p&gt;

&lt;p&gt;With that in place, here's what changed in the ranker.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. "should I" is not a convention question
&lt;/h3&gt;

&lt;p&gt;Palace has an intent classifier, and questions that sound like project conventions ("should we use tabs?") get a boost toward convention-style drawers. The trigger included "should I".&lt;/p&gt;

&lt;p&gt;One preference question in LongMemEval starts with "should I". The classifier filed it under conventions and boosted the wrong drawers. I narrowed the trigger. That question recovered, and R@1 on the coding-agent eval (a separate fixture, not LongMemEval) went up too.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Date-aware ranking
&lt;/h3&gt;

&lt;p&gt;Temporal questions ("what did I buy two weeks ago?") were the category I most wanted to improve. In a live palace every drawer has a date, so a question that points at a time window should favour drawers from that window.&lt;/p&gt;

&lt;p&gt;To make that testable the runner had to stop cheating in the other direction: every question is now asked on its own &lt;code&gt;question_date&lt;/code&gt;, and every drawer is dated by its session. Relative dates like "10 days ago", "last Tuesday" or "in the past month" now resolve the way they would in a real palace.&lt;/p&gt;

&lt;p&gt;The ranker parses those spans and gives drawers inside the window a small boost (weight 0.12). Two bugs came out while building it: spans like "two weeks" have to count in full rather than as a point, and "on Tuesday" in a sentence usually isn't a time reference at all, so that pattern is skipped.&lt;/p&gt;

&lt;p&gt;Honest result: the temporal R@5 didn't move on &lt;code&gt;s_cleaned&lt;/code&gt;. The three temporal misses that remain &lt;strong&gt;lose on topic, not on date&lt;/strong&gt;. The gold chunk is from the right day and still scores below unrelated chunks from the same days. Date-awareness helps break ties; it can't rescue a chunk that doesn't look relevant. On larger haystacks, with many sessions per day, it's mostly a tie-breaker too.&lt;/p&gt;

&lt;p&gt;I kept it anyway, because in a real palace "what did we decide last week" is a very common question, and the mechanism is right even when this dataset doesn't reward it much.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Sources that match in several places
&lt;/h3&gt;

&lt;p&gt;When a session ranks by its best chunk, a session where three different exchanges match the question looks the same as a session where one does. That's throwing away evidence.&lt;/p&gt;

&lt;p&gt;Now a drawer gets a small lift (weight 0.1) from the best &lt;em&gt;other&lt;/em&gt; matching drawer from the same source. I picked the weight on a different split plus probes from a real palace, froze it, then ran &lt;code&gt;s_cleaned&lt;/code&gt; once. 0.1 was best; 0.3 already hurt.&lt;/p&gt;

&lt;h3&gt;
  
  
  The bad rule I'm still carrying
&lt;/h3&gt;

&lt;p&gt;In the interest of honesty: Palace's separate coding-agent eval is partly tuned. The ranker contains a handful of phrases copied from that eval's own questions. With them, the int8 model scores R@1 0.922 on it; without them, 0.902. The README says so and shows both. They have zero effect on LongMemEval and on real-palace probes, and I'm keeping them only until general mechanisms reach the same numbers.&lt;/p&gt;

&lt;p&gt;I mention it because it's exactly the kind of thing that makes benchmark numbers meaningless if nobody discloses it, and it's very easy to do by accident.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where it ended up
&lt;/h2&gt;

&lt;p&gt;With exchange chunking, int8 MiniLM, and the ranking changes above, frozen before the run:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Configuration&lt;/th&gt;
&lt;th&gt;Model&lt;/th&gt;
&lt;th&gt;R@1&lt;/th&gt;
&lt;th&gt;R@5&lt;/th&gt;
&lt;th&gt;R@10&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;One drawer per session&lt;/td&gt;
&lt;td&gt;&lt;code&gt;minilm-l6-v2&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;0.896&lt;/td&gt;
&lt;td&gt;0.981&lt;/td&gt;
&lt;td&gt;0.991&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;One drawer per session&lt;/td&gt;
&lt;td&gt;&lt;code&gt;minilm-l6-v2-q8&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;0.898&lt;/td&gt;
&lt;td&gt;0.981&lt;/td&gt;
&lt;td&gt;0.991&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Exchange pairs&lt;/td&gt;
&lt;td&gt;&lt;code&gt;minilm-l6-v2-q8&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;0.915&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;0.987&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;0.996&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fveh0o5umw3hd9xstcai0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fveh0o5umw3hd9xstcai0.png" alt="Final R@1 and R@5 per question type" width="800" height="500"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Per question type (exchange pairs, q8):&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Question type&lt;/th&gt;
&lt;th&gt;R@1&lt;/th&gt;
&lt;th&gt;R@5&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;knowledge-update&lt;/td&gt;
&lt;td&gt;0.958&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;multi-session&lt;/td&gt;
&lt;td&gt;0.909&lt;/td&gt;
&lt;td&gt;0.992&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;single-session-assistant&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;single-session-preference&lt;/td&gt;
&lt;td&gt;0.767&lt;/td&gt;
&lt;td&gt;0.933&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;single-session-user&lt;/td&gt;
&lt;td&gt;0.984&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;temporal-reasoning&lt;/td&gt;
&lt;td&gt;0.858&lt;/td&gt;
&lt;td&gt;0.976&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;From the start of the week, exchange pairs went from 0.906/0.985/0.994 to 0.915/0.987/0.996. That's four more questions at R@1, one more at &lt;a href="mailto:R@5"&gt;R@5&lt;/a&gt;. Per session, R@5 is back to 0.981, the May number, but now from code that's actually in the repo.&lt;/p&gt;

&lt;h2&gt;
  
  
  What's still weak
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Preferences.&lt;/strong&gt; Still the weakest category. "I prefer X" sentences rarely share words with the question that needs them ("what should I cook tonight?"), so BM25 can't help and a 384-dim embedding only partly can. Exchange chunking helped a lot. The rest probably needs something structural, not a new weight.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Temporal questions that lose on topic.&lt;/strong&gt; As above. Not a date problem.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;code&gt;s_cleaned&lt;/code&gt; is near the ceiling.&lt;/strong&gt; At R@5 0.987 the remaining misses are a handful of questions, and it's very easy to fit them by accident. That's why the source weight was picked elsewhere, and why I'm careful about reading much into the last few points. I've also been running the much larger &lt;code&gt;m_cleaned&lt;/code&gt; split, where the numbers are lower and more informative. I'll write about it once I'm happy with what it says.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;This is retrieval, not answers.&lt;/strong&gt; The next honest step is running other memory systems through the same harness, so the comparison is like for like instead of across different metrics.&lt;/p&gt;

&lt;h2&gt;
  
  
  Things I'd tell myself a week ago
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Rerun your old numbers before chasing new ones.&lt;/strong&gt; The drift pointed straight at a bug.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Count questions, not decimals.&lt;/strong&gt; One question is 0.0021 here. Most "improvements" are one or two.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Benchmark the path you ship.&lt;/strong&gt; The product's chunker beat the standard setup, and testing it found a bug that had been quietly dropping text.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A bigger model isn't a free win.&lt;/strong&gt; On this data it was slower and no better.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Quantization has side effects beyond accuracy.&lt;/strong&gt; int8 vectors depended on batch neighbours. A boring equality test caught it.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Pick weights on data you won't report on, freeze them, then run once.&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Disclose the tuned bits.&lt;/strong&gt; Even small ones, even in a separate eval.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Reproducing it
&lt;/h2&gt;

&lt;p&gt;Everything here runs locally from the repo. The benchmark runner, the exact commands for each row, and the per-question outputs are in the benchmarks docs:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/AncientiCe/palace-rs" rel="noopener noreferrer"&gt;https://github.com/AncientiCe/palace-rs&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you run it on different hardware or another split and get different numbers, I'd like to hear about it.&lt;/p&gt;

&lt;p&gt;One question for you: has anyone else seen int8 or quantized embeddings drift depending on what else is in the batch? I'd love to know if it's just my setup.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>rag</category>
      <category>rust</category>
      <category>machinelearning</category>
    </item>
    <item>
      <title>I gave my AI coding agents a face so they stop waiting on me</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Wed, 28 Oct 2026 18:18:13 +0000</pubDate>
      <link>https://dev.to/icegaming/i-gave-my-ai-coding-agents-a-face-so-they-stop-waiting-on-me-265o</link>
      <guid>https://dev.to/icegaming/i-gave-my-ai-coding-agents-a-face-so-they-stop-waiting-on-me-265o</guid>
      <description>&lt;p&gt;You know the feeling. You give Claude Code a task, switch to another window, and come back twenty minutes later. It has done nothing for nineteen of them, because it stopped at a permission prompt one minute in.&lt;/p&gt;

&lt;p&gt;Running several sessions makes this worse. One is working, one has finished, and one has been asking "Allow &lt;code&gt;npm install&lt;/code&gt;?" for the last quarter of an hour.&lt;/p&gt;

&lt;p&gt;So I built &lt;strong&gt;Agent Needs You&lt;/strong&gt;: a small screen on my desk with a pair of eyes that tells me how my agents are doing.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3bqmntzy6110hzyc6b1k.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3bqmntzy6110hzyc6b1k.gif" alt="All the states of Agent Needs You" width="480" height="480"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What the eyes mean
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Face&lt;/th&gt;
&lt;th&gt;Meaning&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Blue, &lt;strong&gt;focused&lt;/strong&gt;: narrowed eyes reading back and forth, the odd bead of sweat&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Working&lt;/strong&gt;: the agent is busy&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Amber, &lt;strong&gt;curious&lt;/strong&gt;: big eyes looking around, head tilting, a bobbing "?"&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Needs you&lt;/strong&gt;: a permission prompt or an input wait. The message is shown&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Green, &lt;strong&gt;happy&lt;/strong&gt;: ^ ^ eyes bouncing, blushing, sparkles&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Your turn&lt;/strong&gt;: the agent finished its reply&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Lilac, &lt;strong&gt;drowsy&lt;/strong&gt;: half-lidded, slow blinks&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Idle&lt;/strong&gt;: a session is open but nothing is happening&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Lilac, &lt;strong&gt;asleep&lt;/strong&gt;: eyes shut, Zzz&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;No sessions&lt;/strong&gt; at all&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Drowsy and asleep look alike on purpose, because neither needs you. The difference is whether a session exists. Drowsy means at least one agent is open but quiet: it has just started and hasn't had a prompt yet, or it was working and went silent for 30 minutes, so the board stops trusting the "working" state. Asleep means there is nothing to track, and the board shows its IP address so you can point the hooks at it.&lt;/p&gt;

&lt;p&gt;Beside the eyes the screen shows the state, the project name, how long it has been in that state, the agent's message when it needs you, and how many sessions are in each state.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frsignlq9o7lhp54p3rga.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frsignlq9o7lhp54p3rga.jpg" alt="The amber &amp;quot;Needs you&amp;quot; face showing Claude asking for permission to use Bash" width="800" height="496"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Amber is the colour that matters. When I see it out of the corner of my eye, I know something is blocked on me.&lt;/p&gt;

&lt;h2&gt;
  
  
  Hardware
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;LilyGO T-Display S3 AMOLED&lt;/strong&gt;: ESP32-S3, 8 MB PSRAM, and a 240x536 AMOLED panel over QSPI. About $35 from LilyGO's own store, more from resellers.&lt;/li&gt;
&lt;li&gt;A USB cable&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That's the whole bill of materials. Not sponsored and no affiliate links, it's just the board I picked for the job. AMOLED suits this well: the black background really is black, so the eyes seem to float, and the panel isn't a glowing rectangle in the dark.&lt;/p&gt;

&lt;p&gt;The firmware is PlatformIO and Arduino. The board joins Wi-Fi, runs a tiny HTTP server, and accepts JSON on &lt;code&gt;POST /hook&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  How the agents talk to it
&lt;/h2&gt;

&lt;p&gt;Claude Code, Cursor and Codex all support &lt;strong&gt;hooks&lt;/strong&gt;: shell commands that run on lifecycle events. That's all I needed.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fku3o71qiu0fg1tkw12du.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fku3o71qiu0fg1tkw12du.png" alt="How a hook event travels from the agent to the board" width="800" height="297"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Board state&lt;/th&gt;
&lt;th&gt;Claude Code&lt;/th&gt;
&lt;th&gt;Codex&lt;/th&gt;
&lt;th&gt;Cursor&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Working&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;UserPromptSubmit&lt;/code&gt;, &lt;code&gt;PostToolUse&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;UserPromptSubmit&lt;/code&gt;, &lt;code&gt;PostToolUse&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;beforeSubmitPrompt&lt;/code&gt;, &lt;code&gt;postToolUse&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Needs you&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Notification&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;PermissionRequest&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;not available&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Your turn&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Stop&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;Stop&lt;/code&gt;, &lt;code&gt;Interrupt&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;&lt;code&gt;stop&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Added / removed&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;SessionStart&lt;/code&gt; / &lt;code&gt;SessionEnd&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;SessionStart&lt;/code&gt; / &lt;code&gt;SessionEnd&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;sessionStart&lt;/code&gt; / &lt;code&gt;sessionEnd&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Each hook runs one small Python relay. It:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;reads the agent's hook payload from stdin,&lt;/li&gt;
&lt;li&gt;converts it to the board's format,&lt;/li&gt;
&lt;li&gt;POSTs it to the board with a &lt;strong&gt;one-second timeout&lt;/strong&gt;,&lt;/li&gt;
&lt;li&gt;prints whatever that agent expects back from a hook,&lt;/li&gt;
&lt;li&gt;and &lt;strong&gt;always exits 0&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The last point matters most. A status light must never break the agent. If the board is unplugged, the hooks carry on as if nothing happened.&lt;/p&gt;

&lt;p&gt;(Cursor has no hook that fires while it waits for approval without also answering that approval, so Cursor sessions only show working and your turn.)&lt;/p&gt;

&lt;h2&gt;
  
  
  One-line install
&lt;/h2&gt;

&lt;p&gt;The installer finds every supported agent on the machine and wires them all up. It uses the standard library only, needs Python 3.8+, and runs on Windows, macOS and Linux:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-fsSL&lt;/span&gt; https://raw.githubusercontent.com/AncientiCe/agent-needs-you/main/hooks/install.py | python3 - &lt;span class="nt"&gt;--ip&lt;/span&gt; &amp;lt;device-ip&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;irm&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;https://raw.githubusercontent.com/AncientiCe/agent-needs-you/main/hooks/install.py&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;python&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;--ip&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="err"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;device-ip&lt;/span&gt;&lt;span class="err"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It keeps your existing hooks, replaces earlier versions of its own, and backs up every file it changes. &lt;code&gt;--dry-run&lt;/code&gt; shows what it would do and &lt;code&gt;--uninstall&lt;/code&gt; removes it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Juggling several sessions
&lt;/h2&gt;

&lt;p&gt;The board tracks up to 8 sessions and rotates through them &lt;strong&gt;most urgent first&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Needs you&lt;/strong&gt; stays up for 15 seconds&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Working&lt;/strong&gt; stays up for 8 seconds&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Your turn&lt;/strong&gt; stays up for 4 seconds (2 once seen)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;When a session starts waiting on you or finishes, it jumps the queue at once. Idle sessions only show when nothing else is going on.&lt;/p&gt;

&lt;p&gt;There are two buttons. One marks every finished session as &lt;em&gt;seen&lt;/em&gt;, which turns the happy face a calm grey-green. The other cycles through sessions by hand.&lt;/p&gt;

&lt;h2&gt;
  
  
  The gotcha: 400 KB of JSON on a microcontroller
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;PostToolUse&lt;/code&gt; sends the &lt;strong&gt;whole tool output&lt;/strong&gt; in the payload. When an agent reads a big file or runs a noisy command, that means hundreds of kilobytes of JSON hitting an ESP32.&lt;/p&gt;

&lt;p&gt;Buffering it and then parsing it is a quick route to running out of RAM. Instead, the firmware streams the request body through an &lt;strong&gt;ArduinoJson filter&lt;/strong&gt;, which keeps only the handful of fields it needs (&lt;code&gt;hook_event_name&lt;/code&gt;, &lt;code&gt;session_id&lt;/code&gt;, &lt;code&gt;cwd&lt;/code&gt;, &lt;code&gt;message&lt;/code&gt;) and discards the rest as it reads. Memory use stays flat however large the payload is.&lt;/p&gt;

&lt;h2&gt;
  
  
  Not just for AI agents
&lt;/h2&gt;

&lt;p&gt;The board takes plain JSON over HTTP, so anything can drive it:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-s&lt;/span&gt; &lt;span class="nt"&gt;-m&lt;/span&gt; 2 &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="s1"&gt;'{"hook_event_name":"Notification","session_id":"ci-build","cwd":"my-project","message":"CI failed","agent":"ci"}'&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  http://&amp;lt;device-ip&amp;gt;/hook
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;CI failures, long builds and deploys can all make the eyes look at you.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it
&lt;/h2&gt;

&lt;p&gt;The code is MIT-licensed on GitHub: &lt;strong&gt;&lt;a href="https://github.com/AncientiCe/agent-needs-you" rel="noopener noreferrer"&gt;AncientiCe/agent-needs-you&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Since it went on my desk, permission prompts have stopped sitting there for twenty minutes. I've also caught myself saying "aww" at a microcontroller, which I'm choosing not to think about.&lt;/p&gt;

&lt;p&gt;What would you put on yours? Let me know in the comments.&lt;/p&gt;

</description>
      <category>esp32</category>
      <category>ai</category>
      <category>opensource</category>
      <category>showdev</category>
    </item>
    <item>
      <title>We forgot how to review code the moment AI wrote the PR</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Mon, 26 Oct 2026 12:15:39 +0000</pubDate>
      <link>https://dev.to/icegaming/we-forgot-how-to-review-code-the-moment-ai-wrote-the-pr-54dk</link>
      <guid>https://dev.to/icegaming/we-forgot-how-to-review-code-the-moment-ai-wrote-the-pr-54dk</guid>
      <description>&lt;p&gt;Something strange happened when AI coding tools went mainstream. We forgot how to review code.&lt;/p&gt;

&lt;p&gt;A colleague opens a merge request. The description was clearly written with an AI agent. There is a summary, a changelog, a list of what was touched. And the reaction in the channel is not "let me look". It is a sigh. A thumbs down. Sometimes a comment that just says "AI slop?".&lt;/p&gt;

&lt;p&gt;Nobody has read the diff yet.&lt;/p&gt;

&lt;h2&gt;
  
  
  "This is not pair programming anymore"
&lt;/h2&gt;

&lt;p&gt;That is the complaint I keep hearing. The old ideal was pair programming, extreme programming, two people at one keyboard building the thing together. Now one person and an agent build it, and the reviewer gets handed the result. Some people say they feel like a human proxy for a machine: the AI wrote it, and now a human has to rubber stamp it.&lt;/p&gt;

&lt;p&gt;Fair feeling. But let me ask something.&lt;/p&gt;

&lt;p&gt;During covid, when the whole industry went remote overnight and before tools like Tuple made remote pairing pleasant, how did you review code? Somebody wrote it alone, pushed a branch, and asked you to look. You were not at their keyboard. You had a diff, a description and maybe a ticket.&lt;/p&gt;

&lt;p&gt;Were you a proxy then?&lt;/p&gt;

&lt;p&gt;No. You were a reviewer. That is the job. It has always been the job.&lt;/p&gt;

&lt;h2&gt;
  
  
  What a PR is actually for
&lt;/h2&gt;

&lt;p&gt;The purpose of a pull request or merge request is to give you the information you need to review it. That's it. Not to entertain you, not to prove the author suffered, not to show which tool typed the characters.&lt;/p&gt;

&lt;p&gt;So review it like this:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Read the problem statement.&lt;/strong&gt; Two lines. What was broken, or what was needed?&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Read the test.&lt;/strong&gt; Does it actually check that problem? Would it have failed before the change?&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Read the fix.&lt;/strong&gt; Given the problem and the test, does it make sense? Is it the smallest reasonable change?&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ask your own agent to review it.&lt;/strong&gt; You have the same tools the author has. Point yours at the diff and ask what could break.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Approve or request changes.&lt;/strong&gt; With reasons.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F17tavt6xo9mlmiikwkce.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F17tavt6xo9mlmiikwkce.png" alt="Review order: problem, test, fix, your agent, decision. Versus: spot an AI tell, label it slop, skip it." width="800" height="366"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;None of those steps care who or what wrote the code. Every one of them cares whether the code is right.&lt;/p&gt;

&lt;h2&gt;
  
  
  The long dash test
&lt;/h2&gt;

&lt;p&gt;I know. The long dash gives it away. The bullet points are suspiciously tidy. The description says "This PR introduces" and you can smell the model.&lt;/p&gt;

&lt;p&gt;OK. Now does the change make sense?&lt;/p&gt;

&lt;p&gt;Because that is the only question that matters at review time. We are putting a label on work before we read it, before we understand it, and then calling that judgment. It is not judgment. It is pattern matching on punctuation.&lt;/p&gt;

&lt;h2&gt;
  
  
  We never cared about this before
&lt;/h2&gt;

&lt;p&gt;Before AI, merge requests were full of things that had nothing to do with the change. Emojis. ASCII art. Jokes in the description. Party parrot GIFs. A commit titled "fix stuff (again)". All of that was the author asking you to spend a second of attention on their personality instead of their code.&lt;/p&gt;

&lt;p&gt;Nobody wrote angry threads about it. We scrolled past and read the diff.&lt;/p&gt;

&lt;p&gt;An AI-written summary at least tries to describe the change. That is more than the party parrot ever did.&lt;/p&gt;

&lt;h2&gt;
  
  
  The junior test
&lt;/h2&gt;

&lt;p&gt;Here is the one I cannot get past.&lt;/p&gt;

&lt;p&gt;A junior engineer writes a merge request by hand. No AI. The description is two vague sentences, the naming is a bit off, there is one test that only checks the happy path.&lt;/p&gt;

&lt;p&gt;Do you review it? Of course you do. You read it, you leave comments, you help them get it right. That is part of being on a team.&lt;/p&gt;

&lt;p&gt;So why is that PR worth your time and the AI-assisted one is not? If anything, the AI one probably came with a better description and more tests. The difference is not quality. The difference is that we decided in advance which one deserves effort.&lt;/p&gt;

&lt;h2&gt;
  
  
  The part that actually bothers me
&lt;/h2&gt;

&lt;p&gt;Since when did we stop trusting our peers?&lt;/p&gt;

&lt;p&gt;When a colleague asks for a review, the baseline assumption used to be that they read their own change first. They ran it. They looked at the diff before pushing. Review was a second pair of eyes, not the first.&lt;/p&gt;

&lt;p&gt;Using an agent does not remove that responsibility from the author. But treating every AI-assisted PR as if nobody looked at it is an accusation, and it is aimed at a teammate, not at a tool.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fvh2q5etfkjis50gfbgdr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fvh2q5etfkjis50gfbgdr.png" alt="Three PRs: AI-assisted, junior by hand, and one full of emojis and ASCII art. The same review questions apply to all of them." width="799" height="354"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The honest part
&lt;/h2&gt;

&lt;p&gt;There is a real problem hiding under the eye rolling, and I don't want to pretend otherwise.&lt;/p&gt;

&lt;p&gt;A 2,000 line AI-generated PR with no problem statement, no tests and a description that just restates the diff is a burden. It pushes the thinking onto the reviewer. That is not fine, and you should push back.&lt;/p&gt;

&lt;p&gt;But push back on the right thing. The fix is not "this is slop, closing". The fix is: "What problem does this solve, in two lines? Where is the test that proves it? Can you split this?" Those are the same questions you would ask a junior. They are review comments, not verdicts.&lt;/p&gt;

&lt;p&gt;If the author cannot answer them, you have your answer. If they can, you just reviewed code like an engineer.&lt;/p&gt;

&lt;h2&gt;
  
  
  So
&lt;/h2&gt;

&lt;p&gt;Code review did not get harder because of AI. It got more visible how many of us were skimming before. The steps have not changed: problem, test, fix, decision. Your agent can even help you do it faster.&lt;/p&gt;

&lt;p&gt;The question is whether we review the change or the vibe.&lt;/p&gt;

&lt;p&gt;So I'll ask you: what is the last AI-assisted PR you rejected, and was it because the change was wrong, or because it looked like AI wrote it?&lt;/p&gt;

</description>
      <category>ai</category>
      <category>codereview</category>
      <category>programming</category>
      <category>discuss</category>
    </item>
    <item>
      <title>I compared 12 AI coding agent memories. Most only remember what, not why</title>
      <dc:creator>iCe Gaming</dc:creator>
      <pubDate>Sun, 25 Oct 2026 17:16:31 +0000</pubDate>
      <link>https://dev.to/icegaming/i-compared-12-ai-coding-agent-memories-most-only-remember-what-not-why-gnb</link>
      <guid>https://dev.to/icegaming/i-compared-12-ai-coding-agent-memories-most-only-remember-what-not-why-gnb</guid>
      <description>&lt;p&gt;&lt;strong&gt;Your agent does not have a memory problem. It has a "why" problem.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Every tool in this post can make an agent remember &lt;em&gt;something&lt;/em&gt; tomorrow. A markdown file remembers what you typed into it. A memory layer remembers facts it extracted from a chat. A session recorder remembers what tools ran. Very few of them remember the thing that actually costs you time: &lt;em&gt;why&lt;/em&gt; a fix landed, and which three obvious fixes were already tried and failed.&lt;/p&gt;

&lt;p&gt;I spent the last few weeks reading the docs and source of every agent memory option I could find, and sending about 400 cold emails to dev teams asking how they handle memory for Claude Code, Cursor and Codex. Most of them were not convinced they needed anything new. Some of them were right. This post is the guide I wish I had before I started: what each option really stores, who writes it, how it is retrieved, whether a team can share it, and where it breaks.&lt;/p&gt;

&lt;p&gt;Disclosure up front: I build one of the tools in this comparison (palace-rs, and the Palace team server on top of it). I have tried to describe it with the same rules as everything else: only what the repo and docs confirm, drawbacks included. You can weigh my opinions accordingly.&lt;/p&gt;

&lt;h2&gt;
  
  
  The problem in one scene
&lt;/h2&gt;

&lt;p&gt;Monday: Alice's agent hits a flaky test in the payment webhook. It tries a retry wrapper (makes it worse). Then a longer timeout (hides it). Then it finds the real cause: the test fixture shares a database connection across workers. It fixes the fixture. The commit says:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;fix: isolate webhook fixture connection
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Thursday: Bob's agent sees a different flaky test in the same area. It reads &lt;code&gt;CLAUDE.md&lt;/code&gt;. Nothing about webhooks. It reads the git log and finds Alice's commit, but the commit does not say "retries and timeouts are traps here". So Bob's agent tries a retry wrapper. Then a longer timeout. Forty minutes later it lands on the same fixture fix.&lt;/p&gt;

&lt;p&gt;Nothing in that story is exotic. It is three separate failures stacked on top of each other:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Agents forget.&lt;/strong&gt; Every session starts with an empty context window.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Agents repeat dead ends.&lt;/strong&gt; The successful fix is recorded somewhere (the commit). The failed attempts are recorded nowhere.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Teammates' agents do not share.&lt;/strong&gt; Even if Alice's agent remembered, that memory lives on Alice's laptop.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Keep those three in mind. Every option below solves some of them and ignores the rest.&lt;/p&gt;

&lt;h2&gt;
  
  
  A taxonomy of agent memory
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F6khgl57zcy7ijygnow34.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F6khgl57zcy7ijygnow34.png" alt="Landscape of agent memory: seven families, from static instruction files to shared team memory" width="800" height="514"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;"Memory" is used for at least seven different things. Mixing them up is the main reason these comparisons go nowhere.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Instruction files (static context).&lt;/strong&gt; &lt;code&gt;CLAUDE.md&lt;/code&gt;, &lt;code&gt;AGENTS.md&lt;/code&gt;, Cursor rules, &lt;code&gt;.github/copilot-instructions.md&lt;/code&gt;. Text a human (or an agent, when asked) writes, loaded into every session.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Structured repo docs.&lt;/strong&gt; Memory banks, ADRs, commit messages, spec files like Allium. Still files in git, but with a schema or a ritual around them.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Built-in assistant memory.&lt;/strong&gt; Claude Code auto memory, Codex memories, Copilot Memory. The vendor's tool writes notes for itself.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Session recorders.&lt;/strong&gt; claude-mem. Watch what the agent does, compress it into observations, inject them next time.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Personal memory layers.&lt;/strong&gt; Mem0, Supermemory, palace-rs, the official MCP knowledge-graph server, Basic Memory. An API, MCP server or local engine that stores facts or records for one user's agents.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Graph and agent-managed memory.&lt;/strong&gt; Zep/Graphiti (temporal knowledge graphs), Cognee (graph plus vectors), Letta (the agent edits its own memory blocks), LangMem (a library for building any of the above), and palace-rs again (a temporal knowledge graph, a room graph, and memory the working agent manages through MCP tools).&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;palace-rs does not fit in one box: it is a personal memory layer, a temporal graph and agent-managed memory in one local engine. It is still single-machine; the team version of the same model is Palace Server, in family 7.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Shared team memory.&lt;/strong&gt; One store that several developers' agents read and write, with permissions: Palace Server, Copilot's repo-level facts, and DIY team setups. Very few products actually live here.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  The big comparison
&lt;/h2&gt;

&lt;p&gt;The table covers 19 live options (plus Cursor Memories, which no longer exists). The grid after it scores the 12 most common head to head. The table is long because the differences are in the details. "Who writes it" and "can it invalidate" are the two columns that matter most for coding agents, and they are the ones marketing pages skip.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Option&lt;/th&gt;
&lt;th&gt;What it stores&lt;/th&gt;
&lt;th&gt;Who writes it&lt;/th&gt;
&lt;th&gt;Retrieval&lt;/th&gt;
&lt;th&gt;Team / shared&lt;/th&gt;
&lt;th&gt;Where it runs&lt;/th&gt;
&lt;th&gt;Licence&lt;/th&gt;
&lt;th&gt;Setup cost&lt;/th&gt;
&lt;th&gt;Can it mark something as wrong?&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;CLAUDE.md / AGENTS.md / Cursor rules / Copilot instructions&lt;/td&gt;
&lt;td&gt;Rules and conventions as prose&lt;/td&gt;
&lt;td&gt;You (or the agent when asked)&lt;/td&gt;
&lt;td&gt;Loaded whole, every session (Cursor rules can be scoped by glob or "apply intelligently")&lt;/td&gt;
&lt;td&gt;Yes, via git&lt;/td&gt;
&lt;td&gt;Local files&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;td&gt;Minutes&lt;/td&gt;
&lt;td&gt;Only by editing the file&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cline memory bank&lt;/td&gt;
&lt;td&gt;Six markdown files: brief, product context, active context, system patterns, tech context, progress&lt;/td&gt;
&lt;td&gt;The agent, on "update memory bank"&lt;/td&gt;
&lt;td&gt;Agent reads all files at task start&lt;/td&gt;
&lt;td&gt;Yes, via git&lt;/td&gt;
&lt;td&gt;Local files&lt;/td&gt;
&lt;td&gt;n/a (a prompt pattern)&lt;/td&gt;
&lt;td&gt;Minutes&lt;/td&gt;
&lt;td&gt;Only by rewriting the file&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;ADRs + commit messages&lt;/td&gt;
&lt;td&gt;The decision and the final fix&lt;/td&gt;
&lt;td&gt;Humans and agents&lt;/td&gt;
&lt;td&gt;grep, git log, blame&lt;/td&gt;
&lt;td&gt;Yes, via git&lt;/td&gt;
&lt;td&gt;Local&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;td&gt;Habit, not setup&lt;/td&gt;
&lt;td&gt;Superseding ADR; commits are permanent&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Allium (.allium spec files)&lt;/td&gt;
&lt;td&gt;Intended behaviour: entities, rules with when / requires / ensures&lt;/td&gt;
&lt;td&gt;The agent, via /elicit, /distill, /tend, /weed skills&lt;/td&gt;
&lt;td&gt;Read as a spec; CLI validates; generates tests&lt;/td&gt;
&lt;td&gt;Yes, via git&lt;/td&gt;
&lt;td&gt;Local&lt;/td&gt;
&lt;td&gt;MIT&lt;/td&gt;
&lt;td&gt;Low to medium (new language)&lt;/td&gt;
&lt;td&gt;Edit the spec; /weed reconciles spec and code&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Claude Code auto memory&lt;/td&gt;
&lt;td&gt;user, feedback, project and reference notes&lt;/td&gt;
&lt;td&gt;Claude, automatically&lt;/td&gt;
&lt;td&gt;MEMORY.md index (first 200 lines or 25 KB) loaded at start, topic files on demand&lt;/td&gt;
&lt;td&gt;No (per repo, per machine)&lt;/td&gt;
&lt;td&gt;Local, &lt;code&gt;~/.claude/projects/&amp;lt;project&amp;gt;/memory/&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Proprietary tool&lt;/td&gt;
&lt;td&gt;Zero (on by default locally)&lt;/td&gt;
&lt;td&gt;Edit or delete via /memory&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Codex memories&lt;/td&gt;
&lt;td&gt;Summaries and durable entries from prior chats&lt;/td&gt;
&lt;td&gt;Codex, in the background&lt;/td&gt;
&lt;td&gt;Injected into future sessions, not guaranteed&lt;/td&gt;
&lt;td&gt;No (per machine)&lt;/td&gt;
&lt;td&gt;Local, &lt;code&gt;~/.codex/memories/&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Proprietary tool&lt;/td&gt;
&lt;td&gt;Flip a flag (off by default)&lt;/td&gt;
&lt;td&gt;Delete the store; docs say do not hand-edit&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Copilot Memory&lt;/td&gt;
&lt;td&gt;Repo facts with code citations, user preferences&lt;/td&gt;
&lt;td&gt;Copilot agents&lt;/td&gt;
&lt;td&gt;Recent memories in prompt; citations checked against the current branch before use&lt;/td&gt;
&lt;td&gt;Yes, repo facts shared with repo users&lt;/td&gt;
&lt;td&gt;GitHub cloud&lt;/td&gt;
&lt;td&gt;Proprietary&lt;/td&gt;
&lt;td&gt;Toggle (launched as public preview)&lt;/td&gt;
&lt;td&gt;Yes: agent stores a corrected memory when citations contradict it; unused entries expire after 28 days&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cursor Memories&lt;/td&gt;
&lt;td&gt;(removed in Cursor 2.1; export to rules)&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;claude-mem (103k stars)&lt;/td&gt;
&lt;td&gt;Typed observations (bugfix, feature, decision, discovery...) and session summaries&lt;/td&gt;
&lt;td&gt;A separate observer model watching the session&lt;/td&gt;
&lt;td&gt;Session-start injection plus search -&amp;gt; timeline -&amp;gt; get_observations MCP tools; SQLite FTS5, optional Chroma&lt;/td&gt;
&lt;td&gt;Optional TeamBrain shared workspace&lt;/td&gt;
&lt;td&gt;Local worker; hosted options&lt;/td&gt;
&lt;td&gt;Apache-2.0&lt;/td&gt;
&lt;td&gt;npx install; Node, Bun, uv&lt;/td&gt;
&lt;td&gt;Delete via API/viewer; no supersede or validity model found&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Mem0 (OSS + platform)&lt;/td&gt;
&lt;td&gt;LLM-extracted facts ("Project decision: use Postgres")&lt;/td&gt;
&lt;td&gt;An LLM extraction pass on what you send&lt;/td&gt;
&lt;td&gt;Semantic + keyword + entity (+ temporal on platform)&lt;/td&gt;
&lt;td&gt;Scoped by user_id / agent_id / run_id; your app decides&lt;/td&gt;
&lt;td&gt;Self-host or cloud&lt;/td&gt;
&lt;td&gt;Apache-2.0&lt;/td&gt;
&lt;td&gt;Medium (LLM + vector store)&lt;/td&gt;
&lt;td&gt;Explicit update/delete; extraction is additive by default&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Supermemory&lt;/td&gt;
&lt;td&gt;Documents and extracted memories, profiles&lt;/td&gt;
&lt;td&gt;Its extraction pipeline&lt;/td&gt;
&lt;td&gt;Hybrid search via API&lt;/td&gt;
&lt;td&gt;Namespaces&lt;/td&gt;
&lt;td&gt;Cloud, or a local binary (MCP is hosted-only)&lt;/td&gt;
&lt;td&gt;SDKs MIT; local server binary closed source&lt;/td&gt;
&lt;td&gt;Low&lt;/td&gt;
&lt;td&gt;Via API&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;MCP knowledge-graph memory server&lt;/td&gt;
&lt;td&gt;Entities, relations, atomic observations in a JSONL file&lt;/td&gt;
&lt;td&gt;The agent via tools&lt;/td&gt;
&lt;td&gt;Read graph / search nodes&lt;/td&gt;
&lt;td&gt;No (one file)&lt;/td&gt;
&lt;td&gt;Local&lt;/td&gt;
&lt;td&gt;MIT&lt;/td&gt;
&lt;td&gt;Minutes&lt;/td&gt;
&lt;td&gt;Delete observations or entities&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Basic Memory&lt;/td&gt;
&lt;td&gt;Markdown notes with observations and wikilinks&lt;/td&gt;
&lt;td&gt;You and the agent, same files&lt;/td&gt;
&lt;td&gt;Semantic + full-text search over notes&lt;/td&gt;
&lt;td&gt;Cloud Teams offering&lt;/td&gt;
&lt;td&gt;Local files; optional cloud&lt;/td&gt;
&lt;td&gt;AGPL-3.0&lt;/td&gt;
&lt;td&gt;Low (Python)&lt;/td&gt;
&lt;td&gt;Edit the note&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Zep / Graphiti&lt;/td&gt;
&lt;td&gt;Temporal knowledge graph: entities, facts with validity windows, episodes&lt;/td&gt;
&lt;td&gt;LLM extraction from episodes&lt;/td&gt;
&lt;td&gt;Hybrid semantic + keyword + graph traversal&lt;/td&gt;
&lt;td&gt;Graphiti: you build tenancy; Zep cloud: yes&lt;/td&gt;
&lt;td&gt;Graphiti self-host; Zep is cloud (Community Edition discontinued April 2025)&lt;/td&gt;
&lt;td&gt;Apache-2.0 (Graphiti)&lt;/td&gt;
&lt;td&gt;High (graph DB + LLM + embedder + your service)&lt;/td&gt;
&lt;td&gt;Yes, bi-temporal edge invalidation, history kept&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cognee&lt;/td&gt;
&lt;td&gt;Knowledge graph + vector index over text, code, chats&lt;/td&gt;
&lt;td&gt;Its pipeline (remember / improve)&lt;/td&gt;
&lt;td&gt;Routed graph/vector recall; code graph queries&lt;/td&gt;
&lt;td&gt;Dataset permissions; API mode shares one graph&lt;/td&gt;
&lt;td&gt;Local (SQLite, LanceDB, Kuzu) or Postgres/Neo4j&lt;/td&gt;
&lt;td&gt;Apache-2.0&lt;/td&gt;
&lt;td&gt;Medium&lt;/td&gt;
&lt;td&gt;forget; temporal mode keeps superseded facts&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Letta&lt;/td&gt;
&lt;td&gt;Core memory blocks (always in context) + archival memory&lt;/td&gt;
&lt;td&gt;The agent edits its own blocks&lt;/td&gt;
&lt;td&gt;Blocks in prompt; archival via search tools&lt;/td&gt;
&lt;td&gt;Shared blocks across agents possible&lt;/td&gt;
&lt;td&gt;Self-host (Postgres + pgvector) or cloud&lt;/td&gt;
&lt;td&gt;Apache-2.0&lt;/td&gt;
&lt;td&gt;Medium to high&lt;/td&gt;
&lt;td&gt;The agent rewrites its blocks&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;LangMem&lt;/td&gt;
&lt;td&gt;Semantic, episodic, procedural memories in your LangGraph store&lt;/td&gt;
&lt;td&gt;Agent tools + background consolidation&lt;/td&gt;
&lt;td&gt;Your store's search&lt;/td&gt;
&lt;td&gt;Whatever your store allows&lt;/td&gt;
&lt;td&gt;Your infra&lt;/td&gt;
&lt;td&gt;MIT&lt;/td&gt;
&lt;td&gt;Medium (you build it)&lt;/td&gt;
&lt;td&gt;Consolidation updates entries&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;DIY RAG (pgvector, Chroma)&lt;/td&gt;
&lt;td&gt;Whatever you chunk&lt;/td&gt;
&lt;td&gt;Whatever you write&lt;/td&gt;
&lt;td&gt;Vector (+ keyword if you add it)&lt;/td&gt;
&lt;td&gt;If you build it&lt;/td&gt;
&lt;td&gt;Your infra&lt;/td&gt;
&lt;td&gt;Varies&lt;/td&gt;
&lt;td&gt;Medium to high, forever&lt;/td&gt;
&lt;td&gt;If you build it&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;palace-rs&lt;/td&gt;
&lt;td&gt;Verbatim drawers (code, notes, diaries) in wings and rooms, per-agent diaries, a temporal KG of facts with valid_from / valid_to, a room graph with tunnels across wings, standing rules and preferences loaded at every session start (global, plus the project's own wing)&lt;/td&gt;
&lt;td&gt;The working agent, through MCP tools (diary, KG add / invalidate, remember / forget, add / delete drawer), plus mining your repo&lt;/td&gt;
&lt;td&gt;Hooks inject at session start, on prompt, during tool use; BM25 + cosine hybrid with provenance; KG queries with &lt;code&gt;as_of&lt;/code&gt;; graph traversal and tunnels&lt;/td&gt;
&lt;td&gt;Shared across agents on one machine; not a team server&lt;/td&gt;
&lt;td&gt;Local: one binary, one SQLite file, local ONNX embeddings&lt;/td&gt;
&lt;td&gt;MIT&lt;/td&gt;
&lt;td&gt;Low (one binary, &lt;code&gt;palace install&lt;/code&gt;)&lt;/td&gt;
&lt;td&gt;Yes: &lt;code&gt;palace_kg_invalidate&lt;/code&gt; closes a fact's validity window; &lt;code&gt;palace_conflicts&lt;/code&gt; flags contradictions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Palace Server (team)&lt;/td&gt;
&lt;td&gt;Same model as palace-rs, central&lt;/td&gt;
&lt;td&gt;Each developer's agents&lt;/td&gt;
&lt;td&gt;Same MCP tools over the network&lt;/td&gt;
&lt;td&gt;Yes: shared drawers, KG and diaries; roles; row-level isolation; audit log of writes&lt;/td&gt;
&lt;td&gt;Self-hosted only: Docker Compose or binary + Postgres/pgvector&lt;/td&gt;
&lt;td&gt;Commercial (built on the MIT core)&lt;/td&gt;
&lt;td&gt;Medium (a server and a database)&lt;/td&gt;
&lt;td&gt;Same invalidation, for the whole team&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F68gcstxyf1ilu5e76tw0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F68gcstxyf1ilu5e76tw0.png" alt="What each option actually remembers: rules, final fix, dead ends, why, invalidation, shared" width="800" height="471"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Instruction files: necessary, and not memory
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;CLAUDE.md&lt;/code&gt;, &lt;code&gt;AGENTS.md&lt;/code&gt;, &lt;code&gt;.cursor/rules/*.mdc&lt;/code&gt; and &lt;code&gt;.github/copilot-instructions.md&lt;/code&gt; are the right home for rules. Build commands. "Use pnpm, not npm." "Never touch the generated client." Codex concatenates &lt;code&gt;AGENTS.md&lt;/code&gt; files from the repo root down to the current directory and stops at 32 KiB by default. Claude Code loads &lt;code&gt;CLAUDE.md&lt;/code&gt; files at the start of every conversation and can read &lt;code&gt;AGENTS.md&lt;/code&gt; in their place. Cursor rules can be always-on, glob-scoped, agent-selected or manual.&lt;/p&gt;

&lt;p&gt;What works:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Versioned with the code, reviewed in PRs, shared by the whole team for free.&lt;/li&gt;
&lt;li&gt;Zero infrastructure. Nothing to break.&lt;/li&gt;
&lt;li&gt;Deterministic. You know exactly what the agent sees.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;What does not:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Every line costs context in every session.&lt;/strong&gt; So people keep them short, which means history is the first thing cut.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;They store conclusions, not journeys.&lt;/strong&gt; "Use the isolated fixture" is a rule. "Retries and timeouts hide this bug" is history, and history does not belong in a rule file that loads on every prompt.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Nobody writes them at 6pm after a two-hour debugging session.&lt;/strong&gt; The moment with the most valuable knowledge is the moment with the least patience.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Even the vendors draw this line. OpenAI's Codex docs say to keep required team guidance in &lt;code&gt;AGENTS.md&lt;/code&gt; and treat memories as "a helpful recall layer". Anthropic's docs describe &lt;code&gt;CLAUDE.md&lt;/code&gt; as instructions you write and auto memory as notes Claude writes itself. Instruction files are configuration. They are not memory, and they were never meant to be.&lt;/p&gt;

&lt;h2&gt;
  
  
  Memory banks, ADRs, commits and spec files
&lt;/h2&gt;

&lt;p&gt;This is where I disagree with a lot of people, so I will argue it properly.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Cline's memory bank&lt;/strong&gt; is a prompt pattern: six markdown files (&lt;code&gt;projectbrief.md&lt;/code&gt;, &lt;code&gt;productContext.md&lt;/code&gt;, &lt;code&gt;activeContext.md&lt;/code&gt;, &lt;code&gt;systemPatterns.md&lt;/code&gt;, &lt;code&gt;techContext.md&lt;/code&gt;, &lt;code&gt;progress.md&lt;/code&gt;). The agent reads all of them at task start and rewrites them when you say "update memory bank". It is a real improvement over nothing, and for a solo developer on one project it can be enough.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;ADRs and commit messages&lt;/strong&gt; are the oldest memory system we have, and the best one for &lt;em&gt;decisions&lt;/em&gt;. One team I emailed keeps the why of every change in commit messages and swears by it. They are right that the why belongs in git.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Allium&lt;/strong&gt; (from JUXT, MIT, &lt;code&gt;.allium&lt;/code&gt; files) is a behavioural spec language for agentic engineering: entities plus rules in the form &lt;code&gt;when&lt;/code&gt; / &lt;code&gt;requires&lt;/code&gt; / &lt;code&gt;ensures&lt;/code&gt;, with skills like &lt;code&gt;/elicit&lt;/code&gt; (forward from intent), &lt;code&gt;/distill&lt;/code&gt; (backward from code), &lt;code&gt;/weed&lt;/code&gt; (reconcile spec and code) and &lt;code&gt;/propagate&lt;/code&gt; (generate tests). Its own site pitches it as something that "persists between sessions" and surfaces contradictions that markdown lets two requirements hide. It is not YAML, despite looking a bit like it.&lt;/p&gt;

&lt;p&gt;My argument against treating any of these as agent memory:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;They read back what was saved, nothing more.&lt;/strong&gt; A file cannot notice that the question you are asking now is related to something filed under a different name three months ago. Retrieval is "load all of it" or "hope grep matches".&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;They hold the final state.&lt;/strong&gt; A memory bank's &lt;code&gt;progress.md&lt;/code&gt; says what works. A commit says what landed. An Allium spec says what the system should do. None of them has a place for "we tried X and Y first and here is why they failed", and that is exactly what Bob's agent needed on Thursday.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;They decay silently.&lt;/strong&gt; Nothing marks &lt;code&gt;activeContext.md&lt;/code&gt; as stale when the code moves on. A wrong line in a rule file is loaded with full authority every session until a human notices.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;They grow until they are cut.&lt;/strong&gt; The more you put in, the more context each session burns, so the useful history gets pruned first.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Allium deserves a separate note, because it is solving a different problem well. Intent drift inside a long session is real, and a formal spec that generates tests is a sharper tool than a prose PRD. But a behaviour spec is not a memory of what happened. It will tell the next agent that webhooks must be idempotent. It will not tell it that a retry wrapper already made the flaky test worse. If you adopt it, adopt it as a spec, not as your memory layer.&lt;/p&gt;

&lt;p&gt;Where file-based approaches genuinely win: solo developers, small repos, short-lived projects, and anything that must be reviewable line by line in a PR. If that is you, stop reading here and write a good &lt;code&gt;AGENTS.md&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Built-in assistant memory
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Claude Code auto memory&lt;/strong&gt; is on by default in local sessions. Claude writes four kinds of notes for itself (&lt;code&gt;user&lt;/code&gt;, &lt;code&gt;feedback&lt;/code&gt;, &lt;code&gt;project&lt;/code&gt;, &lt;code&gt;reference&lt;/code&gt;) under &lt;code&gt;~/.claude/projects/&amp;lt;project&amp;gt;/memory/&lt;/code&gt;, with a &lt;code&gt;MEMORY.md&lt;/code&gt; index whose first 200 lines or 25 KB load at every session start. The docs are explicit that it skips anything derivable from the code, "such as architecture, file paths, or debugging fixes". That is a sensible design for preferences, and it also means debugging history is out of scope by design. It is per machine; your teammate's Claude does not see it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Codex memories&lt;/strong&gt; are off by default, live under &lt;code&gt;~/.codex/memories/&lt;/code&gt;, are generated in the background once a chat has gone idle, and are described by OpenAI as useful recall that is not guaranteed to load. Again: per machine.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Copilot Memory&lt;/strong&gt; is the most interesting design of the three. Repository facts are stored with citations to the code that supports them, and before using a memory the agent checks those citations against the current branch. If the code contradicts the memory, the agent is encouraged to store a corrected version. Unused memories are deleted after 28 days. Repo facts are shared with everyone who has Copilot Memory on that repo. The catches: it is GitHub-hosted, it works with Copilot's own agents (cloud agent, code review, CLI), and it launched as a public preview, so check its current status.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Cursor Memories&lt;/strong&gt; no longer exist. Cursor removed the feature in 2.1 (November 2025) and told users to export memories into rules. One user in that forum thread summed it up: memories were "almost no different than .mdc files".&lt;/p&gt;

&lt;h2&gt;
  
  
  claude-mem: the most popular, and a recorder rather than a memory
&lt;/h2&gt;

&lt;p&gt;claude-mem had 103,026 stars on GitHub when I checked today, which makes it by far the most starred project in this post. It deserves a careful look.&lt;/p&gt;

&lt;p&gt;How it works, from its README, docs and source:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Lifecycle hooks (SessionStart, UserPromptSubmit, PreToolUse, PostToolUse, Stop, SessionEnd) send tool execution data to a local worker.&lt;/li&gt;
&lt;li&gt;A &lt;strong&gt;separate observer model&lt;/strong&gt; reads that activity and writes typed observations. Its own system prompt says it is "a specialized observer tool", that "you are NOT the one doing the work", and that the watched session "does not know it is being observed".&lt;/li&gt;
&lt;li&gt;Observations have types (&lt;code&gt;bugfix&lt;/code&gt;, &lt;code&gt;feature&lt;/code&gt;, &lt;code&gt;refactor&lt;/code&gt;, &lt;code&gt;change&lt;/code&gt;, &lt;code&gt;discovery&lt;/code&gt;, &lt;code&gt;decision&lt;/code&gt;, plus security types) and concepts (&lt;code&gt;why-it-exists&lt;/code&gt;, &lt;code&gt;problem-solution&lt;/code&gt;, &lt;code&gt;gotcha&lt;/code&gt;, &lt;code&gt;trade-off&lt;/code&gt; and others), with a narrative field for "what was done, how it works, why it matters".&lt;/li&gt;
&lt;li&gt;Storage is SQLite with FTS5 and optional Chroma. Retrieval is session-start injection plus three MCP tools: &lt;code&gt;search&lt;/code&gt; -&amp;gt; &lt;code&gt;timeline&lt;/code&gt; -&amp;gt; &lt;code&gt;get_observations&lt;/code&gt;, a progressive-disclosure pattern that saves tokens.&lt;/li&gt;
&lt;li&gt;There is an optional TeamBrain shared workspace and hosted providers; the default installer flow offers a hosted observer trial.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;What it does well:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Zero effort.&lt;/strong&gt; Install and it starts recording. That alone explains the stars.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Progressive disclosure&lt;/strong&gt; is a genuinely good retrieval pattern: a cheap index first, full details only for the IDs that matter.&lt;/li&gt;
&lt;li&gt;It does try to capture decisions and gotchas, not just file edits.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Why I do not count it as real memory for coding teams:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The narrator is not the actor.&lt;/strong&gt; The observer sees tool calls and outputs. It does not see the reasoning that made the agent abandon the retry wrapper. It can record "added retry wrapper, then reverted it". It has to guess at "because it masked a shared connection". A summary written from outside the head is still a summary of activity.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Recording is not deciding.&lt;/strong&gt; Nothing in the pipeline asks "was this the conclusion, or just something that happened?" Everything observed becomes an observation, so the next agent gets a timeline, not a verdict.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No notion of "this is no longer true".&lt;/strong&gt; I could find delete endpoints for observations and summaries, but no supersede, validity window or contradiction check. When a decision is reversed, the old observation and the new one sit side by side and the reader has to work out which wins.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;It is mostly one person's history.&lt;/strong&gt; The default scope is your sessions on your machine (and by default your current harness). TeamBrain is opt-in and sharing is per person.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you want a searchable black-box recorder of your own Claude Code sessions, claude-mem is good at that. Just be clear that a recorder answers "what happened" and you still need something that answers "what did we learn".&lt;/p&gt;

&lt;h2&gt;
  
  
  Personal memory layers: Mem0, Supermemory, MCP memory servers, Basic Memory
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Mem0&lt;/strong&gt; (Apache-2.0, about 68k stars) is the best known memory layer. You send it conversation turns; an LLM extracts durable facts, deduplicates them, embeds them and stores them. Its own docs show the transform: &lt;code&gt;"Let's use Postgres for this project"&lt;/code&gt; becomes &lt;code&gt;Project decision: use Postgres&lt;/code&gt;. You can pass &lt;code&gt;infer=False&lt;/code&gt; to store text verbatim. Retrieval fuses semantic, keyword and entity signals. Memories are scoped by &lt;code&gt;user_id&lt;/code&gt;, &lt;code&gt;agent_id&lt;/code&gt; and &lt;code&gt;run_id&lt;/code&gt;. The OSS default LLM and embedder are OpenAI models, though both are configurable. OpenMemory, its local MCP server, is being sunset in favour of the Mem0 self-hosted server.&lt;/p&gt;

&lt;p&gt;Mem0 is excellent for what it was built for: assistants that need to remember facts about a person across chats. For coding agents the extraction step is the problem. "Project decision: use Postgres" is exactly the sentence that loses the why. Its docs also note that automatic extraction is additive, so contradictions are handled with explicit &lt;code&gt;update&lt;/code&gt; or &lt;code&gt;delete&lt;/code&gt; calls that your app has to make.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Supermemory&lt;/strong&gt; (MIT SDKs, about 31k stars) offers a hosted API and, more recently, a local single binary with embedded storage and local embeddings. Two details matter: its docs say the downloadable server binary is built from a separate non-public codebase, and its MCP server is available on the hosted platform only.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The official MCP knowledge-graph memory server&lt;/strong&gt; (&lt;code&gt;@modelcontextprotocol/server-memory&lt;/code&gt;) stores entities, relations and atomic observations in a local JSONL file. It describes itself as "a basic implementation". It is a perfect way to learn how MCP memory works, and a weak production choice: no semantic search, no time, one file.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Basic Memory&lt;/strong&gt; (AGPL-3.0) keeps knowledge as markdown notes that you and the agent both edit, with observations, wikilinks and semantic search. It is the best of the "markdown, but searchable" options. The AGPL licence and the shift of its team features to a cloud offering are worth noting if you plan to embed or share it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Graphs and agent-managed memory: Zep, Graphiti, Cognee, Letta, LangMem, palace-rs
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Zep / Graphiti&lt;/strong&gt; brings the most rigorous idea in this space: a bi-temporal knowledge graph. Every fact edge carries when it was true and when the system learned it. When a new fact contradicts an old one, an LLM detects the overlap and the old edge is invalidated, with history kept. Graphiti (Apache-2.0, about 32k stars) is the open framework. Zep is the commercial cloud. Zep Community Edition was discontinued in April 2025. Graphiti's own README is honest about the cost: "You supply the graph database, LLM, and embedder, and you build the service around it: ingestion, tenancy, access control, and operations." It even says "Neither is an agent memory product". If you need temporal reasoning over business data, this is the reference design. If you want your coding agent to stop repeating dead ends this week, it is a lot of building.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Cognee&lt;/strong&gt; (Apache-2.0, about 33k stars) builds a knowledge graph plus vector index from text, code and conversations, runs locally on SQLite, LanceDB and Kuzu by default, and exposes &lt;code&gt;remember&lt;/code&gt;, &lt;code&gt;recall&lt;/code&gt; and &lt;code&gt;forget&lt;/code&gt; over MCP. It adds a code graph for questions like "what breaks if I change this signature", and a temporal mode that keeps superseded facts. Strong if you want a graph of your codebase; the memory of &lt;em&gt;sessions&lt;/em&gt; is a smaller part of what it does.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Letta&lt;/strong&gt; (formerly MemGPT, Apache-2.0) is agent-managed memory: core memory blocks that are always in the prompt and that the agent edits itself, plus archival memory searched with tools. Self-hosting means a server with Postgres and pgvector. The idea that the agent curates its own memory is right. The catch for coding is that Letta works best when you run your agent &lt;em&gt;inside&lt;/em&gt; Letta (including its own Letta Code harness); bolting it onto Claude Code or Cursor gives you less of the benefit.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;LangMem&lt;/strong&gt; (MIT) is a LangGraph library for semantic, episodic and procedural memory with background consolidation. It is a toolkit, not a product. Good if you are already on LangGraph and building your own agent.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;palace-rs&lt;/strong&gt; belongs in this section too, not only with the personal layers. Its repo confirms three things that overlap with the tools above:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;A temporal knowledge graph.&lt;/strong&gt; Facts are subject -&amp;gt; predicate -&amp;gt; object triples with &lt;code&gt;valid_from&lt;/code&gt; and &lt;code&gt;valid_to&lt;/code&gt;. Agents add them with &lt;code&gt;palace_kg_add&lt;/code&gt;, close them with &lt;code&gt;palace_kg_invalidate&lt;/code&gt;, read them with &lt;code&gt;palace_kg_query&lt;/code&gt; (which takes an &lt;code&gt;as_of&lt;/code&gt; date for point-in-time questions) and &lt;code&gt;palace_kg_timeline&lt;/code&gt;, and &lt;code&gt;palace_conflicts&lt;/code&gt; flags facts that look stale or contradictory. Invalidation keeps history, so the timeline shows both the old and the new fact. That is the same core idea as Graphiti's validity windows. The difference: in palace-rs the agent that knows the fact changed records the change explicitly, rather than an LLM pass detecting the contradiction, and it all lives in one local SQLite file instead of a graph database plus an LLM and embedder you wire up yourself. The trade-off is that Graphiti is bi-temporal (it also tracks when the system learned a fact) and does contradiction detection for you; palace-rs relies on the agent, with &lt;code&gt;palace_conflicts&lt;/code&gt; as a check.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A room graph.&lt;/strong&gt; Memory is organised into wings (projects or topics) and rooms, and &lt;code&gt;palace_traverse&lt;/code&gt;, &lt;code&gt;palace_find_tunnels&lt;/code&gt;, &lt;code&gt;palace_create_tunnel&lt;/code&gt;, &lt;code&gt;palace_follow_tunnels&lt;/code&gt; and &lt;code&gt;palace_graph_stats&lt;/code&gt; walk and connect rooms across wings. A "webhooks" room in one project can be linked to the same topic in another, so the next agent can follow it. Cognee's code graph goes deeper on code structure; palace-rs's graph is about connecting memory, not parsing your codebase.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Agent-managed memory.&lt;/strong&gt; The working agent curates its own store through MCP tools: &lt;code&gt;palace_diary_write&lt;/code&gt;, &lt;code&gt;palace_kg_add&lt;/code&gt; / &lt;code&gt;palace_kg_invalidate&lt;/code&gt;, &lt;code&gt;palace_remember&lt;/code&gt; and &lt;code&gt;palace_forget&lt;/code&gt;, &lt;code&gt;palace_add_drawer&lt;/code&gt; / &lt;code&gt;palace_delete_drawer&lt;/code&gt;, and &lt;code&gt;palace_check_duplicate&lt;/code&gt; before filing. &lt;code&gt;palace_recall_check&lt;/code&gt; runs project-memory probes to see whether expected memories are actually found. Hooks inject context at session start, on each prompt and during tool use, and the stop hook asks for a diary entry and decisions if a session did real work and saved nothing. That is Letta's idea (the agent edits its own memory), but delivered as MCP tools and hooks inside the coding agent you already use (Claude Code, Codex, Cursor and others) rather than a separate agent runtime and server. The trade-off: Letta's core blocks are always in context by design, while palace-rs depends on hooks and on agents following the protocol.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So for a coding agent on one machine, palace-rs gives you a temporal graph and agent-managed memory without standing up a graph database, a Postgres server or a new agent runtime. What it does not give you is cross-machine sharing (that is Palace Server), LLM-driven contradiction detection, or Cognee's code-structure graph.&lt;/p&gt;

&lt;h2&gt;
  
  
  DIY RAG with pgvector or Chroma
&lt;/h2&gt;

&lt;p&gt;Every team with a Postgres instance has thought "we could just embed our docs and chats". You can. One team I talked to did it properly, and it is the most impressive setup in this post (see below). The honest cost: you now own chunking, embedding, ranking, deduplication, staleness, permissions and the hooks that make agents use it. Vector search alone is also bad at exact names and commands, so you end up rebuilding hybrid search. DIY is the right call when memory &lt;em&gt;is&lt;/em&gt; your product or your platform team's job. It is the wrong call when you wanted to stop re-explaining the webhook fixture.&lt;/p&gt;

&lt;h2&gt;
  
  
  palace-rs and Palace Server
&lt;/h2&gt;

&lt;p&gt;Disclosure again: I build these. Here is what the repo and docs confirm, and where they fall short.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;palace-rs&lt;/strong&gt; (MIT, Rust) is local-first memory for one developer's agents. One binary, one SQLite file, local &lt;code&gt;all-MiniLM-L6-v2&lt;/code&gt; embeddings on ONNX Runtime, no API keys. &lt;code&gt;palace install&lt;/code&gt; wires it into Claude Code, Codex, Cursor, Gemini CLI, VS Code, OpenCode, Cline, Zed, Goose, Windsurf and Claude Desktop.&lt;/p&gt;

&lt;p&gt;What it stores: verbatim "drawers" (chunks of your repo, notes and transcripts, not LLM summaries) organised into wings (projects or topics) and rooms, with tunnels linking rooms across wings; per-agent diaries; standing rules and preferences in &lt;code&gt;general/preferences&lt;/code&gt;, injected verbatim at every session start in every project, alongside the current project's own knowledge; and a temporal knowledge graph of facts with &lt;code&gt;valid_from&lt;/code&gt; and &lt;code&gt;valid_to&lt;/code&gt; (covered in the graphs section above).&lt;/p&gt;

&lt;p&gt;Who writes it: the working agent. Hooks inject memory at session start, when you send a prompt, and while the agent greps and reads files. The installed rule tells agents to write a diary entry and record durable facts after substantive work, and a stop hook asks once if a session did real work and saved nothing. Because the agent that did the work writes the entry, "tried retries, tried timeouts, real cause was the shared fixture" can be written by the one party that actually knows it.&lt;/p&gt;

&lt;p&gt;Correction: when a fact changes, the agent calls &lt;code&gt;palace_kg_invalidate&lt;/code&gt; and adds the new fact, so the timeline keeps both. &lt;code&gt;palace_conflicts&lt;/code&gt; surfaces facts that look stale or contradictory, and &lt;code&gt;palace_forget&lt;/code&gt; removes drawers. In practice the human is the final judge: you tell the agent what is wrong, and it invalidates and refiles. Agents on the same machine share one palace, so a Codex session can pick up a Claude Code session's diary.&lt;/p&gt;

&lt;p&gt;Drawbacks: it only shares across agents on one machine; there is no human approval gate in the code, so a wrong diary entry is stored until someone or something corrects it; quality depends on agents following the protocol; the embedding model is a one-time ~90 MB download; macOS Intel is not supported; and the published LongMemEval numbers (R@5 0.981) measure retrieval recall, not end-to-end answer quality.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Palace Server&lt;/strong&gt; is the commercial team edition, self-hosted only. Every developer's local &lt;code&gt;palace&lt;/code&gt; points at it with &lt;code&gt;palace remote on&lt;/code&gt;, so the same MCP tools read and write shared drawers, knowledge-graph facts and diaries. It runs as a Docker Compose starter kit (server plus Postgres with pgvector) or a static binary with your own Postgres, computes embeddings locally, and its Docker image ships the embedding model so it can run with no outbound traffic. It adds roles, per-organisation row-level isolation in Postgres, SSO via OIDC and an audit log of memory writes.&lt;/p&gt;

&lt;p&gt;Drawbacks: it is one more server and one more database to run, exactly the objection I heard most (below), and it is not open source.&lt;/p&gt;

&lt;h2&gt;
  
  
  What we heard from about 400 dev teams
&lt;/h2&gt;

&lt;p&gt;I emailed roughly 400 teams that use coding agents, asking how they handle memory. The honest headline: &lt;strong&gt;most were not convinced they needed a memory product.&lt;/strong&gt; The replies were more useful than the silence, though. Anonymised, here is what came back.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;"It is already in the repo."&lt;/strong&gt; Several teams keep decisions and context versioned in git: &lt;code&gt;AGENTS.md&lt;/code&gt;, &lt;code&gt;CLAUDE.md&lt;/code&gt;, plain markdown. They see no need for a separate server, and for their size they may be right.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;"One more server to maintain."&lt;/strong&gt; This was the most common objection by far. Teams are tired of infrastructure that exists to make other infrastructure smarter.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;"Our agents run on our customers' machines."&lt;/strong&gt; One team ships agents that execute in customer environments. A Docker and Postgres dependency is a non-starter for them. Claude Code's built-in memory plus &lt;code&gt;CLAUDE.md&lt;/code&gt; covers their needs. That is the correct answer for that shape of product.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;"We built it ourselves."&lt;/strong&gt; The best setup I saw: versioned markdown decisions and lessons in git with an always-loaded index plus vector search, an agent-to-agent MCP mailbox with acknowledgements, a shared work board with advisory locks so two agents do not grab the same task, the why of every change in commit messages, and one Docker image per developer. It is serious engineering and it works. It is also a platform someone has to maintain.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;"That is a team problem, and I am one person."&lt;/strong&gt; Solo developers mostly said memory across teammates is not their problem yet.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Commits record the fix, not the traps.&lt;/strong&gt; The webhook scene above came out of these conversations. &lt;code&gt;fix: isolate webhook fixture connection&lt;/code&gt; is a perfectly good commit message, and it still lets the next agent walk straight into the retry wrapper and the longer timeout.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And two lessons from comment threads on my earlier posts, which changed how I think about this:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Save the conclusion, not the trace.&lt;/strong&gt; A commenter pointed out that dumping every failed attempt into memory makes the next agent read a "panic spiral". The useful entry is two lines: what was tried, why it failed, what the cause was.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Who writes the conclusion matters.&lt;/strong&gt; If an agent summarises itself, a wrong conclusion can get saved, which is worse than nothing. You need a way for the human to say "that is wrong" and for the next agent to mark it invalid rather than stack a second version next to it.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Foauzfncgve6cb0elx3dg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Foauzfncgve6cb0elx3dg.png" alt="Two agents, same bug, three days apart: what each memory option would have told Bob's agent" width="799" height="434"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  What works and what does not
&lt;/h2&gt;

&lt;p&gt;What works:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Rules in files, history in memory.&lt;/strong&gt; Every vendor doc and every good team I saw separates the two.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The actor writes the lesson.&lt;/strong&gt; Entries written by the agent that did the work, at the end of the work, beat entries reconstructed by someone watching.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Conclusions with their dead ends.&lt;/strong&gt; "Cause: shared fixture connection. Tried: retry wrapper (worse), longer timeout (hides it)." That one entry saves forty minutes.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Facts that can expire.&lt;/strong&gt; Copilot's citation checks, Graphiti's validity windows, palace-rs's &lt;code&gt;valid_to&lt;/code&gt;. Memory without a way to say "no longer true" rots.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Automatic recall.&lt;/strong&gt; If the agent has to remember to search memory, it will forget. Hooks that inject relevant context beat tools that wait to be called.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Provenance.&lt;/strong&gt; Every recalled item should say where it came from and when, so the agent (and you) can judge it.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;What does not:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;LLM extraction for engineering decisions.&lt;/strong&gt; Turning a debugging session into "Project decision: use Postgres" throws away the reason.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Recording everything.&lt;/strong&gt; Timelines of tool calls are searchable, not instructive.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Bigger instruction files.&lt;/strong&gt; Every line you add is paid for in every session, forever.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cloud memory for teams that cannot send code context out.&lt;/strong&gt; For many of the teams I emailed, this ruled out half the market before features came up.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Building a platform when you needed a habit.&lt;/strong&gt; If your team is three people on one repo, a disciplined &lt;code&gt;AGENTS.md&lt;/code&gt; plus good commit messages beats a graph database.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Decision guide
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F2ohtolrvrdurv7f2eqw7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F2ohtolrvrdurv7f2eqw7.png" alt="Decision flowchart: solo or team, can data leave, customer machines, do you need the why and dead ends" width="800" height="629"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Answer these in order.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Do your agents run on your customers' machines?&lt;/strong&gt;&lt;br&gt;
Use the assistant's built-in memory (Claude Code auto memory, Codex memories) plus a tight &lt;code&gt;CLAUDE.md&lt;/code&gt; or &lt;code&gt;AGENTS.md&lt;/code&gt; shipped with your product. Do not add a server or database dependency to someone else's machine.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Are you solo, or is this one person's agents?&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Small repo, short project, mostly rules: &lt;code&gt;AGENTS.md&lt;/code&gt; / &lt;code&gt;CLAUDE.md&lt;/code&gt; plus good commit messages. Add a Cline-style memory bank if you like the ritual.&lt;/li&gt;
&lt;li&gt;You want a zero-effort searchable log of your own Claude Code sessions: claude-mem.&lt;/li&gt;
&lt;li&gt;You want local memory that keeps the why, the dead ends and corrections, shared by all your agents on your machine: &lt;strong&gt;palace-rs&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;3. You are a team. Can memory leave your network?&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Yes, and you are on GitHub with Copilot agents: Copilot Memory, for its citation checks.&lt;/li&gt;
&lt;li&gt;Yes, and you are building a product that remembers users: Mem0 or Zep cloud.&lt;/li&gt;
&lt;li&gt;No: keep going.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;4. Do your agents need to share the why and the dead ends across developers, with invalidation, on your own infrastructure?&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Yes, and you would rather run a server than build one: &lt;strong&gt;Palace Server&lt;/strong&gt;. Budget for one server and one Postgres.&lt;/li&gt;
&lt;li&gt;Yes, and you have a platform team that wants to own it: Graphiti or Cognee as the engine, or the DIY markdown + vector + MCP mailbox setup described above.&lt;/li&gt;
&lt;li&gt;No, you mostly need shared conventions: versioned rule files are enough. Really.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;5. Are you building your own agent rather than using Claude Code, Cursor or Codex?&lt;/strong&gt;&lt;br&gt;
Letta (agent-managed memory) or LangMem (on LangGraph). Both shine when memory is part of the agent's own loop.&lt;/p&gt;

&lt;h2&gt;
  
  
  Anti-patterns
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The 2,000-line CLAUDE.md.&lt;/strong&gt; If your instruction file reads like a wiki, it is costing you context and it is still not memory.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Treating a spec as history.&lt;/strong&gt; Allium specs, ADRs and memory banks describe the destination. They do not remember the road.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The panic spiral.&lt;/strong&gt; Saving every failed attempt verbatim. Save the conclusion and the named dead ends.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Self-graded memory with no correction path.&lt;/strong&gt; An agent that writes its own conclusions with nobody able to invalidate them will eventually teach the next agent something false, confidently.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Two memories at once.&lt;/strong&gt; Built-in auto memory plus a memory server plus a memory bank, all written by the same agent, means three partial truths. Pick one place for history.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Memory nobody reads.&lt;/strong&gt; A tool the agent must remember to call is a tool it will not call. Check that recall is automatic.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Mistaking stars for fit.&lt;/strong&gt; The most popular option in this post is a session recorder. That is fine if you want a recorder.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Checklist
&lt;/h2&gt;

&lt;p&gt;Before you pick anything, answer these on one page:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;[ ] Where do rules live, and is that file under ~200 lines?&lt;/li&gt;
&lt;li&gt;[ ] When an agent fixes something hard, where do the dead ends get written, and by whom?&lt;/li&gt;
&lt;li&gt;[ ] Can a wrong memory be marked invalid, not just deleted or duplicated?&lt;/li&gt;
&lt;li&gt;[ ] Does recall happen automatically at session start and on the prompt?&lt;/li&gt;
&lt;li&gt;[ ] Does every recalled item show its source and date?&lt;/li&gt;
&lt;li&gt;[ ] Can a teammate's agent see it? Does it need to?&lt;/li&gt;
&lt;li&gt;[ ] Can this data leave your network? Your customers' network?&lt;/li&gt;
&lt;li&gt;[ ] Who maintains it in six months?&lt;/li&gt;
&lt;li&gt;[ ] What happens when it is down? (It should fail open.)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you only do one thing after reading this: next time an agent finishes a nasty bug, make it write two lines somewhere the next agent will see: the cause, and the things that looked right but were not. Whatever tool you use, that is the part that is missing today.&lt;/p&gt;

&lt;p&gt;What does your team do with the dead ends? I am genuinely curious, especially if you have a setup that works without any of the tools above.&lt;/p&gt;

</description>
      <category>aiagents</category>
      <category>mcp</category>
      <category>claudecode</category>
      <category>llm</category>
    </item>
  </channel>
</rss>
