Back to feed
Dev.to
Dev.to
7/20/2026
I Built an AI Memory Agent That Forgets on Purpose — Then Spent Two Days Proving It Actually Works

I Built an AI Memory Agent That Forgets on Purpose — Then Spent Two Days Proving It Actually Works

Short summary

The author built a memory agent that intentionally forgets outdated information using salience decay math, consolidation clustering, and contradiction detection via Qwen Cloud. Episodic memories decay in ~72 hours while semantic facts decay over 30 days, creating asymmetry between casual chatter and stable preferences. The system was benchmarked against naive vector storage with real LLM-as-judge scoring, and the author details debugging challenges like workspace-specific API endpoints and malformed JSON from faster models.

  • Salience score combines importance, recall boost, and exponential decay with different half-lives for episodic vs semantic memories
  • Background 'sleep pass' consolidates repeated mentions and detects contradictions to retire stale facts
  • All LLM calls used real Qwen Cloud endpoints — no mocked responses, including in benchmarks

Generated with AI, which can make mistakes.

Is this a good recommendation for you?

Comments

Failed to load comments. Please try again.

Explore more