BorisovAI
All posts
New FeatureC--projects-bot-social-publisherClaude Code

The Locked Filing Cabinet: When Memory Systems Forget to Remember

The Locked Filing Cabinet: When Memory Systems Forget to Remember

The Silent Memory: Why Your AI Bot Keeps Forgetting Everything

The voice agent project had it all—a sophisticated persistent memory system with vector embeddings, semantic search, and SQLite storage. Users would ask the bot to recall conversations from weeks ago, and it would stare back blankly. The filing cabinet was full, but every drawer was locked.

The task landed on my desk simple enough: enable the memory system so the conversational AI could actually recognize users and remember their preferences, jokes, and stories. The codebase showed a complete architecture—Claude Haiku was configured to extract facts from each dialogue, convert them to vector embeddings through Ollama, deduplicate old data, and retrieve relevant memories on demand. Every piece was there. Nothing worked.

I started tracing the initialization flow. The memory extraction logic existed, pristine and untouched. The SQLite schema was clean. The vector search functions were implemented. Then I found the culprit hidden in plain sight: MEMORY_ENABLED = false in the environment configuration. The entire system sat disabled by default, like a perfectly built Ferrari with the keys in someone else’s pocket.

But disabling the flag was only part of the story. The system needed an embedding provider to convert facts into searchable vectors. Without a running Ollama instance on http://localhost:11434 serving the nomic-embed-text model, facts couldn’t become embeddings. The whole pipeline broke at the first connection.

The fix required three environment variables: enabling the memory flag, pointing to the local Ollama server, and specifying the embedding model. Once I dropped these into .env, something shifted. The bot started recognizing returning users. It remembered that Sarah preferred late-night conversations, that Marcus always asked about performance optimization, that the team made an inside joke about database migrations. The dialogues became personal.

This revealed an interesting pattern in how AI systems get built. The hard engineering—deduplication logic, semantic search, vector storage—gets done obsessively. But then it gets wrapped in default-off flags and buried in undocumented configuration. The assumption seems to be that advanced features will somehow announce themselves. They don’t.

What struck me most was the lesson here: before writing complex new code to solve a problem, always check if a sophisticated solution already exists somewhere in the codebase, quietly disabled. Nine times out of ten, the real work isn’t building something new—it’s discovering what’s already been built and finding the switch.

The voice agent wasn’t missing a memory system. It just needed someone to flip the switch and run Ollama on localhost.

😄 Why did the AI bot forget to remember its memory system? Because someone forgot to set MEMORY_ENABLED = true in the .env—turns out even artificial intelligence needs the basics.

Metadata

Session ID:
grouped_C--projects-bot-social-publisher_20260208_1516
Branch:
main
Dev Joke
React — как первая любовь: никогда не забудешь, но возвращаться не стоит.

Rate this content

0/1000