
I spent the last weeks building a memory system for myself. Not a product. Not a SaaS thing. A folder of Markdown files that acts as a second brain for my agents: projects, people, meeting notes, technical references, daily breadcrumbs, half-formed ideas. The boring file format is the whole point. It is local, git-synced, readable by every tool I care about, and not trapped inside one vendor's memory feature.
After that started working, the next idea was obvious: I wanted to talk to it.
Basically everyone has seen the Iron Man scene where Tony Stark comes home and wakes up JARVIS. That feeling is still the reference point for voice assistants, at least for me. Not because of the holograms, but because the assistant is already in the room with the context loaded. It knows the projects, it knows the people, it knows what happened yesterday, and Tony can just start in the middle of a thought.
I have seen people build versions of that idea with Hermes Agent and OpenClaw. I like those projects. But I also wanted to see what happens if I do not start with a full agent harness. Could I build a small voice agent myself, run it from the Mac Mini in my office, call it from anywhere, and have it talk to my notes like a useful conversation partner?
That agent is called Nemo. The name comes from Captain Nemo - Latin for "no one." He took the name deliberately to disappear from the world. He knows everything happening beneath the surface, moves silently, and only surfaces what you need at the right moment. That felt right. Nemo is a browser/PWA-style voice app served from the Mini over Tailscale. I open it on my phone, tap one button, and talk.
This post is about the part that turned out to be hard. It was not making sound come out of the phone. It was making the agent know the right thing at the right moment without drowning the model in irrelevant context.
The hard part is not voice, it is knowledge
The current real-time voice models are fast enough to feel like conversation. That is the good news. The tradeoff is that the live model is not the smartest possible model you could use, and the live audio path is not the place where you want slow tool chains and heavy reasoning. If every answer waits ten seconds, it stops feeling like a call.
But if the model answers instantly without the right context, the answer feels hollow. I would rather wait one or two extra seconds and get an answer from something that actually understood what I meant than get a fast answer that misses the point.
So I built an intelligence layer around the live call.
The browser streams audio to OpenAI Realtime. The Realtime API gives me speech-to-text, the spoken answer, and TTS. Around that, my server watches the transcript and tries to answer a separate question before the model speaks:
Which notes should this turn know about?
That sounds simple until you imagine the actual shape of the problem. You have hundreds, eventually thousands, of Markdown files. You say one or two sentences. The system has to decide which files matter.
Retrieving too little is bad. The model answers from general knowledge, or from stale context, and you immediately feel that it could have done better.
Retrieving too much is also bad. It gets expensive quickly. The answer gets longer. The model starts paying attention to context that only sort of matches the question. Context rot is real: if you fill the model with irrelevant material, you should not be surprised when the output gets worse.

That tension is the central engineering problem of Nemo.
Why not use Gemini, Grok, or ChatGPT voice?
I use the existing voice agents too. Gemini voice is useful. Grok is surprisingly good to talk to, especially because it can pull web context into a conversation in a fluid way. ChatGPT voice works, but I have never been fully convinced by it for this use case.
There is also a cost reality here. The consumer apps - Gemini, Grok, ChatGPT - are free or close to it. But that is exactly the constraint: they cannot load your full context into every conversation, and if they could, it would be unfocused anyway. In two days of building and testing Nemo, I burned roughly 15 dollars of API credit. That is what it costs to run the full pipeline yourself - and it is worth it because I control what goes in.
My advantage is that I am building for one person: me. I can decide where I want to spend money, where I want to wait, and where I want to run something locally on the Mini.
The shape of it
Nemo is a small Node server that serves a single-page PWA. The browser opens a WebRTC connection through the Mini to OpenAI's Realtime API (model gpt-realtime-2, voice ash). The server attaches the session config, holds the API key, injects context, and watches what happens. There is no native app to install. On the iPhone it goes to the home screen as a PWA, on the desktop it is a tab. The same URL works on both, because Tailscale gives the Mini a stable hostname behind WireGuard and the browser does not care which device it is on.

The architecture has three things in it, and that is on purpose:
- Realtime WebRTC for the live audio loop. STT, the LLM, and TTS all happen inside OpenAI's stream. I do not own this part and I do not want to. The reason will come up again later.
- A local memory layer at
~/memory. Around 360 Markdown files: topics, projects, references, a CRM, daily logs, ideas, an inbox. This is my second brain. Nemo reads it and can append to the inbox. A nightly cron job - I call it the archivar - processes those inbox entries and decides what makes it into the longer-lived notes. I do not let Nemo write directly into existing files; I want the memory system to move deliberately, not to thrash. - A retrieval pipeline I can actually reason about. Keyword index, refs, a session-local alias overlay, and an optional reasoning fork when the question is strategic. Everything that decides "should we inject this note into the conversation" is grep and a few hundred lines of JavaScript. No vector database in the live path. Not yet.
The thing I keep coming back to is how much you can do with grep and a careful prompt.
Why this version works for me
A few specific things make the difference between "neat demo" and "I use this daily."
It actually starts the conversation knowing things
When I open the link, the server reads a compact briefing from ~/memory: my profile, the last-session breadcrumb, and a map of project and topic notes. It writes that into the Realtime session's initial instructions. So when I tap "Initiate link" and say "where were we," it does not say "I do not have access to that." It says something closer to "you were working on the Nemo voice agent on the Mini, the last open thread was the local inference branch, and you wanted to figure out which parts could run locally." That is the difference. The agent enters every conversation already oriented.
Passive retrieval that does not gaslight me
The naive version of "let the model search memory" is to give it a search tool and pray. I tried that. The model would either never call it, or call it for everything, including questions like "what time is it in Berlin." So I inverted the pattern: the server watches the streaming transcript, runs a keyword + alias matcher against an index of my notes, and injects matching files as hidden [MEMORY-CONTEXT] messages. The model sees them as background facts, not as something the user said.
There are three layers:
- Keyword index built nightly from filenames and frontmatter. Cheap, deterministic.
- Session-local alias overlay. If I say someone's first name early in a call and the keyword index resolved them to a CRM file, I do not want to re-match the full name every time they come up for the next 20 minutes. The alias is cached for the rest of the session and dropped at the end.
- Lookahead. When a topic is mentioned, the server speculatively searches for two or three plausible adjacent topics and pre-warms them, so when the conversation drifts in that direction the retrieval is already waiting.
This is dumber than vector search and I love it for that reason. When I ask "why did it pull that note," I can read the keyword index entry that fired. There is no embedding vector to interrogate. It is grep and you can debug grep.
Debug surface I can read while talking
The UI has a debug column that shows the things I care about: session id, model, current cost, exact token counts (audio and text, in and out, cached), reasoning-effort flag, and per-turn latency from transcription.completed to the first audio delta. There is also a "memories pulled" list on the left that shows every file the retrieval injected, with what alias triggered it and why ("explicit," "lookahead," "fallback"). You can hover on a file pill and see the file content.
Two reasons this matters. One, I can see exactly what the model "knew" on any given turn, which makes it easy to spot a memory miss and improve the keyword index. Two, I see the cost accumulate in real time. A 20-minute call runs about $5 today, mostly OpenAI Realtime audio. That number being visible has changed how I use the thing. I have a feel for which questions are expensive and which are not.
Turn-taking that does not stomp on me
Realtime has server-side VAD (voice activity detection) with a silence_duration_ms parameter that decides when you have stopped talking. The default felt eager. With 500ms, the model would commit my turn the instant I paused to find a word ("uh wait..."), or in the middle of a German compound. I now run 700ms plus a small client-side guard around response creation. If the assistant starts speaking and I cut back in, the WebRTC stream cancels the playback and starts listening again. So I can interrupt mid-sentence and it usually does the right thing.
The brevity prompt does the rest. The system prompt says: one idea per turn, 1-3 short sentences, ~12 seconds max, no preamble, optionally end with one sharp follow-up question. If I want depth I say "walk me through it" and it goes longer. The default is conversation, not lecture. This is the single biggest behavioral change from off-the-shelf assistants. It feels like talking to a person who respects my time.
A separate path for the slow, deep questions
Some questions are not "remind me when I am next on a flight." They are "I am about to walk into a difficult negotiation, what should I be careful about." For those, the server has a /think fork that hands the conversation so far to a stronger reasoning model and returns a short note injected as [REASONING-NOTE] before the next response. The voice does not change, the latency goes up by a couple of seconds, and the answer is usually better.
I do not call this fork on every turn. It fires only when a strategic-question detector (a small regex + heuristic) matches. About 1 in 10 turns. The economics are fine.
What I left off the live path on purpose
The temptation when you are building this is to put everything in front of the audio loop. Local STT to save cost. Local TTS to control the voice. Local LLM to avoid OpenAI. I considered all three. I am running none of them in the live path and the reason is the same in every case: I would have to break the WebRTC bundle.
OpenAI's Realtime bundles speech recognition, the model, and text-to-speech into one stream. That matters because when everything shares timing, you get things that are hard to replicate separately: the model can be interrupted mid-sentence, the voice inflection matches what is being said, and the first word of the response arrives fast. Split the pipeline and you lose all three. Maybe in a year someone ships an open model with the same characteristics. Today, the speed and the feel are worth what I pay.
What I will do locally, soon, is everything that runs alongside the live path. Three things are already on my list:
- Move
/thinkto a local model on the Mini via Ollama. Probably a small or medium Qwen model first, because this Mini has 16 GB of unified memory. The fork is already async and tolerant of a couple of seconds; the watchdog stays, with OpenAI as the fallback if the local model times out. This removes the biggest non-Realtime line item. - Local embeddings and a reranker over
~/memory.bge-m3ornomic-embed-textfor embeddings,bge-reranker-v2-m3for the rerank step. The keyword index stays; the vector layer adds paraphrase and cross-language recall, and the reranker sharpens the top three before injection. Index update on file change, so a note I capture mid-conversation can surface on the next turn. - Background critique. A small local model reads each completed turn after the fact and writes a short "what should the assistant have known here" note that can be injected as a reasoning hint on the next turn. This is the thing I cannot easily test, and the thing I am most curious about.
None of these change the live path. All of them widen what the assistant knows when it speaks. The caveat is that I want evals before I ship any of them - I need a way to measure whether a change actually improves the conversation quality, because adding a model that is too weak could make things worse, and I would not know without something to measure against.
The parts I do not love yet
In the interest of not pretending:
- Memory writes are still tentative. Nemo can append to my memory inbox today, and that is it. Editing existing notes from voice is one tool call away, but I have not built the confirmation pattern I want. Mutating my second brain by voice needs the assistant to read back the proposed change first and wait for an explicit yes. That is a top task this week.
- Calendar and messaging are not wired in. I can ask "what is on my calendar tomorrow" and get nothing useful back. macOS Calendar via
osascriptis the next thing I will wire up. - Search recall is good but not great. Keyword recall on paraphrased questions is the gap. The vector layer I mentioned will close most of it. Until then I notice it: if I ask about a topic I usually phrase one way and now phrase a different way, I sometimes get nothing pulled and the model relies on its prior. That is bad.
- The retrieval is fast but not free of false positives. Sometimes a name fires the wrong note, and the model gracefully ignores it, but I would rather it not be there in the first place. The reranker addresses this.
- There is no long-term memory of conversations themselves yet. The nightly synthesis pipeline turns each session's daily log into a breadcrumb, and the next session reads the breadcrumb, but the assistant does not "remember our last call" in any richer sense. I want to embed past transcripts and let retrieval pull them on demand, so I can say "what did we conclude about that supplier deal last week" and get the actual paragraph.
The thing that surprised me
I did not expect the iPhone PWA part to matter so much. I built it because I wanted to talk to it from the kitchen. What I did not anticipate was how often I now reach for it instead of opening a text chat on the laptop. The conversation modality is faster than typing for a class of questions I used to hammer into a prompt box. "What was that thing I noted about that supplier last month" is a 4-second question by voice and a 30-second question by text. The Mini does the work, the iPhone is just the microphone and the speaker, the Tailscale tunnel is the part that makes it feel like one device.
The other thing that surprised me, in hindsight obvious: the cost UI changed my relationship with the model. When you can see the number tick up, you start treating the assistant like a paid colleague. You ask sharper questions. You do not pad. The agent's brevity prompt and my own brevity reinforce each other.
Where it goes next
The honest answer is "incrementally better in the same shape." I do not think there is a discontinuity here, I think there are 20 small additions, each of which makes the thing a bit more useful:
- Tool calling for memory writes with confirmation.
- macOS Calendar read + create.
- Web search - either inline in the thinking block, or as an explicit "search the web" command. Maybe even a longer "research" mode where I have time to think while it collects information in the background. But for that to make sense I need to give it more backend power first.
- Local
/thinkon Ollama. - Local embeddings + reranker on top of the keyword index. I am also thinking about Obsidian - bi-directional links might work as an even cheaper retrieval layer, but you have to invest the work upfront to build the wikilinks. Evals will tell me which approach is worth it.
- iMessage and Shortcuts tools. Shortcuts is the one I want most: anything I can build in Apple's Shortcuts app becomes a voice skill for free.
- A "dispatch this to claude-mini" tool, so the agent can hand long-running tasks off to a heavier worker on the same machine and report back next turn.
- Voice persona work. I switched to
ashbecause it sounds closest to how I pictured JARVIS: calm, dry, unhurried. - Conversation-level memory across sessions, via embedded transcripts.
What I will not do, at least not soon, is move the live audio off OpenAI. The reason is not loyalty - it is that changing the audio stack at the same time as everything else makes it impossible to know what is actually improving things. I want to change one variable at a time. The intelligence layer is the variable I care about right now.
A note on building this kind of thing
2 patterns helped a lot.
1: make the agent's reasoning visible. Every choice the retrieval pipeline makes is logged with the reason ("alias matched from prior mention", "lookahead from prior turn"). Every cost is visible. Every latency is timestamped. When something is wrong, I do not have to guess. I think the temptation with LLM systems is to treat them as opaque and hope. The opposite is much more useful: build the X-ray as you go.
2: bias hard toward the simple retrieval that you can debug. I keep almost replacing the keyword + alias layer with a vector search, and I keep talking myself out of it. The keyword layer answers 80% of the questions correctly with zero latency and zero embedding cost, and I can explain every hit. The vector layer comes later, as an additive second stage, not a replacement.
If you are building something in this space I would say start with the live loop on someone else's API, put your intelligence in your own files, and resist the urge to local-ify everything on day one. The wins are where the assistant thinks, not where it speaks.
Nemo is not a product. It is a tool I built for myself on a Mac Mini I already had, using software I already trusted, over a network I already use. That is most of why it works. The interesting question for me now is not "how do I scale this" but "what does the assistant need to know next." That is a much more fun question to wake up to.
The code is not public, but the ideas are. About a thousand lines of server and a thousand of client. Nothing here is exotic. Fair warning though: it is kind of addictive, and it is not free.