Zendoric
← Back to the day · July 27, 2026

OptMem: the portable memory Victor Taelin gives any AI agent, with no vendor lock-in

🕒 Published on Zendoric: July 27, 2026 · 00:21

OptMem is an open-source tool from a single developer that gives any AI agent permanent memory: a 426-token prompt and a dependency-free Python script. It promises to recall a million notes in 0.03 seconds, without tying you to any model or provider.

By Zendoric · July 27, 2026.

OptMem is an open-source project published on GitHub by developer Victor Taelin, known in the Hacker News community for other parallel-computing projects such as HVM and Bend. Its promise is simple to state: give any AI agent (Claude Code, Codex, Cursor or any that reads an AGENTS.md or CLAUDE.md file) permanent memory with a minimal installation. A script prints a 426-token block of instructions that is pasted at the top of that configuration file, and the agent ends up equipped with a memory system that, as the repository itself describes, «survives every session, every context compaction, every change of model and provider».

Technically, OptMem is a single Python 3 tool with no external dependencies. It stores each memory as a line of text in an append-only log (never edited or deleted) and builds on top of it a binary tree of increasingly compressed summaries, so that the startup command (`memo wake`) always reads a fixed context budget —the repository itself puts it at 208 lines in about 16,000 tokens, and the value is configurable— regardless of whether the agent has a thousand or a million memories stored. According to the figures the project itself provides, with one million memories (608 MB on disk) that startup takes 0.03 seconds, because the records are fixed-width and the position in the file acts as an index: each lookup is a single direct disk access. The rest of the system is rounded out with commands to note (`note`), search by exact word (`recall`), merge pending summaries (`nap`) or navigate the tree node by node (`zoom`).

It is worth situating the problem it attacks. A current coding agent remembers nothing between sessions except whatever is written by hand in a project file: when the context window fills up, the tools compress or summarize it and nuance is lost along the way; when the session ends, almost everything is lost. The industry's usual answer has been to add native memory to the product —ChatGPT's memory, Claude's projects— or to build external layers based on vector databases and embeddings, such as Mem0 or Letta (formerly MemGPT), which retrieve memories by semantic similarity. OptMem takes the opposite route: no vectors, no databases, just plain text, regular expressions and a tree of summaries that the agent itself helps maintain when the system asks it to. It is a deliberate bet on auditable simplicity —the data is a text file anyone can read, sync via git or move to another provider— over the probabilistic sophistication of semantic search.

We should be honest about the real scope of the story: this is the work of a single developer, with 219 stars and 11 forks on GitHub, and it generated barely any traction on Hacker News (1 point, zero comments). The performance figures —a 0.03-second startup at one million memories— are those reported by the author himself, not an independent benchmark, and they deserve the same caution we apply to any in-house benchmark from a large provider.

Our reading goes beyond this particular tool. OptMem is a symptom of a gap no major lab has yet closed satisfactorily: AI agents remain, by default, entities without continuity, reinventing their understanding of the project and the user every few hours. That it is an independent developer, with a Python script, proposing a solution like this says something about how agentic infrastructure is being built: in modular, lightweight layers, often open source, before the big providers absorb or standardize the piece. We already saw the same pattern with the credential managers that mediate between an agent and its passwords: the community solves it first with minimal tools, then the market decides whether that becomes a standard or a platform product.

In the long run, OptMem's most relevant detail is not startup speed but the provider independence its own tagline claims: a memory that survives a change of model keeps the knowledge an agent has accumulated from being held hostage by the vendor that hosted it. If agents are going to take on knowledge work sustained over time —rather than one-off single-session tasks— they need to accumulate experience the way an employee does, without losing it every time they switch tools. It is a small piece, not validated at scale, but it points in the right direction for our underlying thesis: the more continuity and less friction agents have, the sooner they stop being a disposable substitute for one-off tasks and start behaving like collaborators with a memory of their own, the kind of tool that frees up human time instead of merely speeding up repetitive tasks.

🔗 Related on Zendoric

Sources & references