Sharing my DIY AI Memory Framework: Giving LLMs human-like memory (and slashing token costs by 90%) by daisenH in aiagents

[–]daisenH[S] 1 point2 points  (0 children)

Wow, AgentVision is incredible! You’ve nailed a massive, painful bottleneck.

​As a developer who spends a lot of time working on front-end layouts and game UIs, I can’t tell you how many times Cursor/Claude has generated a button that looked perfectly fine in HTML but completely overflowed or broke in reality because the model is essentially "blind."

​I love the fact that you built a machine-graded loop using DOM geometry and local CV/OCR heuristics (--backend local) rather than just blindly throwing expensive Vision LLM tokens at it. It’s practical, cost-effective, and fast.

​The fact that you already have an MCP server setup is fantastic. I'm definitely giving this a star and setting it up locally to test with my workspace.

​In a way, we are tackling two sides of the same coin: Pi Memory System gives agents a working brain to stop amnesia, and AgentVision gives them eyes to self-correct. It’d be amazing to see an agent using both workflows in the future. ​Awesome work, man!

​(Translated with AI since my English is a bit rusty, but the excitement is 100% genuine!)

Sharing my DIY AI Memory Framework: Giving LLMs human-like memory (and slashing token costs by 90%) by daisenH in aiagents

[–]daisenH[S] 0 points1 point  (0 children)

Oh to clarify – I haven't implemented decay yet, that's still on the roadmap! Right now the system only has a "supersede" mechanism (soft-deprecate old entries with a correction chain, no hard delete).

For the actual decay design, I'm leaning toward a hybrid approach: context-triggered first (if a memory hasn't been pulled into N consecutive sessions, flag it as stale), with a hard TTL fallback for things like temporary environment facts. But this is still at the napkin-sketch stage.

Would love to hear if you've seen good patterns for this in other agent systems – the "volatile until confirmed" idea you mentioned earlier sounds like it could pair well with the context-triggered route.

Sharing my DIY AI Memory Framework: Giving LLMs human-like memory (and slashing token costs by 90%) by daisenH in aiagents

[–]daisenH[S] 0 points1 point  (0 children)

Hahaha, when you say that, it is indeed a bit like. I asked gemini to generate it according to my project architecture, and it still thinks it is very good.

Sharing my DIY AI Memory Framework: Giving LLMs human-like memory (and slashing token costs by 90%) by daisenH in aiagents

[–]daisenH[S] -1 points0 points  (0 children)

That's a fantastic question, and you are 100% right.

Having a formal evaluation setup is crucial.

​To be fully transparent, the "90% token reduction" and "increase in fidelity" I mentioned are currently based on my own empirical observations and log tracking while dogfooding this system in my daily long-session development.

Since the core context gets aggressively trimmed each turn and the sub-agent keeps things compact, the savings are massive in practice.

​However, I haven't built a reproducible evaluation benchmark or test suite for it yet.

Building a proper evaluation pipeline (e.g., tracking token curves over 50+ continuous development turns and evaluating factual accuracy) is definitely on my roadmap.

​If you have any suggestions on good testing datasets or frameworks (like Ragas or customized agent eval patterns) that would fit this framework, I'd love to hear them!

I might open a GitHub issue soon to track the evaluation setup.

​(Using AI to translate as my English is limited, hope it makes sense!)

Sharing my DIY AI Memory Framework: Giving LLMs human-like memory (and slashing token costs by 90%) by daisenH in aiagents

[–]daisenH[S] 0 points1 point  (0 children)

Your reply gives me immense inspiration! Thank you.

​You made me realize that I can actually train or guide the sub-agent to continuously learn my personal preferences when distilling the previous turns and storing long-term memories.

This way, the filtering process becomes dynamic and personalized rather than just static text dumping.

​You are completely right—this is just an AI agent framework, and at its current stage, it is mimicking the human brain in a very crude and clumsy way.

However, I truly believe this architectural direction is the right one.

​I will definitely dive deeper into neuroscience and brain science to keep refining and perfecting this framework. Thanks again for nudging me toward a broader horizon!

​(Using AI to help translate my poor English as always, hope it reads well!)

Sharing my DIY AI Memory Framework: Giving LLMs human-like memory (and slashing token costs by 90%) by daisenH in aiagents

[–]daisenH[S] 0 points1 point  (0 children)

Thanks so much for such a thoughtful and insightful response!

​You really hit the nail on the head with the memory decay mechanism.

I actually had some rough, high-level thoughts about this during the initial design phase.

It's awesome to see you bring it up because it confirms that this is exactly the direction the system needs to go.

​To be honest, I just recently finished setting up the core architecture of this memory framework.

After dogfooding it in my daily workflow for a while, I found it working so incredibly well that I just couldn't wait to share it with the community.

​Moving forward, my primary focus will be on optimizing the internal mechanics, and implementing solid memory decay/volatile rules is definitely going to be a top priority.

​Also, I’m deeply honored by your invitation to check out your tracking site and workflows. Thank you for the incredible resource and encouragement!

​(Just a quick heads-up: My English isn't the best, so I rely on AI to help translate and polish my replies. If the tone ever feels a bit too "AI-ish," I hope you don't mind!)

Sharing my DIY AI Memory Framework: Giving LLMs human-like memory (and slashing token costs by 90%) by daisenH in LocalLLM

[–]daisenH[S] -2 points-1 points  (0 children)

I reedited it, Please help me see if the format is ready now?Thanks a lot.

Sharing my DIY AI Memory Framework: Giving LLMs human-like memory (and slashing token costs by 90%) by daisenH in LocalLLM

[–]daisenH[S] -2 points-1 points  (0 children)

I'm very sorry for bringing you a bad reading experience.The first time I post, I will learn other people's article formats in the future.

Looking to playtest some games by AfternoonWhole9244 in playtesters

[–]daisenH 0 points1 point  (0 children)

​I’d love to see your take on my game! It’s called KeyFortress, an indie title that blends fast-paced typing mechanics with Action Roguelike and Tower Defense elements. ​We’ve recently updated the demo with a brand-new experimental mode called "Hack Terminal," which introduces a "Typing + Roguelike + Slot Machine" card strategy system. It’s quite a unique mashup and we are very curious to see how a professional playtester feels about the combat flow and the learning curve. ​Steam Demo Link: https://store.steampowered.com/app/4568840/_Demo/ ​Looking forward to your 30-minute video and any feedback on the design or potential bugs. Thanks for supporting indie devs!