Live data from Hacker News

Show HN: Knowl – CLAUDE.md hit 1000 lines, so I built memory that prunes itself

github.com

1–2 of 2 posts

Show HN: Knowl – CLAUDE.md hit 1000 lines, so I built memory that prunes itself

#1
Using AI agents is amazing, but in long-term, I started to have more and more problems about the context of them. They keep forgetting what we are working on, opening a new chat session clears all their context, my CLAUDE.md had like 1000 lines.

So I thought to install those agent memory that are on the market. Started out great, but I noticed that those memory only append and does not fix what is stale. First day I told it to use Lemon Squeezy as our MoR but second day I tell it to change to Polar. But when I ask it again, they keeps returning both answers or cannot decide which we are using.

That's why I created Knowl. Knowl solves the problem with freshness of the knowledge. It split the knowledge into small data bits called "atom". Atoms can be of the following types: fact, decision, goal, constraint, architecture, state, skill so we can retrive atoms in categories.

When conflict happens at write-time (a new atom conflicts with an old one), Knowl retires the old one (flag it with superseded) and remove it out of main retrieval but still keeps full history.

There are many more cool features like transcript search, multi-workspace sharing, change detection impact... and Knowl Cloud for team-sync too.

We benchmarked Knowl on MemoryAgentBench - FactConsolidation single-hop @262K context and got suprising result:

- Knowl: 0.90 - agentmemory: 0.79 - Gpt-4o (full context): 0.60

- Mem0: 0.18

- Zep: 0.07

In multi-hop we scored 0.07 (ceiling of all time is 0.14) I ran at temperature 0.7. You can find full benchmark in my repo.

This is fully open-source, connect to almost every providers through MCP (Claude Code, Codex, Cursor, Antigravity...). And it is fully local (unless you use Knowl Cloud).

I'd love to get some feedback. Cheers!

Show HN: Knowl – CLAUDE.md hit 1000 lines, so I built memory that prunes itself
github.com

Re: Show HN: Knowl – CLAUDE.md hit 1000 lines, so I built memory that prunes itself

#2
Install takes 30 seconds:

npm install -g @dat999zx/knowl

knowl init

That's it, fully working now.

Also all your atoms are stored inside of knowl.db file which is at root of your project after initializing. You can use knowl view command to watch the atoms and how they interact with each other.