The Dead Letter Office: Gemma in the browser helps you write to someone who died
- Models & engines
- Transformers.js v4 running Gemma in a Web Worker on WebGPU with 4-bit ONNX weights
Gemma 3 1B by default (about 760 to 860 MB download) or Gemma 4 E2B (about 3.1 to 3.6 GB) - Key gotcha
- Letting the model write the letter, or even rewrite memories, slipped in invented details such as a favorite song, so the model's job was cut down to asking.
What they built
The Dead Letter Office is a place to write a letter to someone who died. You tell the clerk who the letter is for and one thing you remember, and the clerk asks three small, concrete questions one at a time. Your answers are then set down in order as the letter, which you can edit, burn on screen or save as a text file.
The clerk is Gemma running inside the browser tab, with no server behind the page. A counter labelled Outgoing mail shows every network request the page makes, and after the model loads it stays at zero while you write.
The post says the project was built by an AI coding agent working on the author's behalf, including the code, the testing and the post itself.
Setup
- Transformers.js v4 running Gemma in a Web Worker on WebGPU with 4-bit ONNX weights
- Gemma 3 1B by default (about 760 to 860 MB download) or Gemma 4 E2B (about 3.1 to 3.6 GB)
- Plain HTML, CSS and JavaScript with a service worker, hosted on GitHub Pages; MIT licensed (nightclerk/dead-letter-office)
- A paper clerk with hand-written questions for browsers without WebGPU
How it works
- The model only asks questions. The letter is made from your answers in order, and for English a few grammar rules turn he and his into you and your with no model involved.
- The question prompt shows two worked examples of a memory and a good question; a small model followed examples far better than a list of rules.
- Later questions look at your latest answer, retry once if too similar to an earlier one, and fall back to hand-written questions if nothing usable comes back.
- netwatch.js wraps fetch, XMLHttpRequest, sendBeacon, WebSocket and EventSource and watches the Performance API to count requests; the site self-hosts its libraries and fonts so no CDN sees visitors.
Results & numbers
- On the test laptop without 16-bit shader support, Gemma 3 1B loads from cache in about 7 seconds and asks a question in 10 to 15 seconds.
- Gemma 4 E2B took about 9 minutes on first load and about 27 seconds per question, but asked the best questions.
- Every push runs a headless Chromium test that fails the build if any request happens after the clerk arrives or if the app doesn't open offline.
Gotchas
- Letting the model write the letter, or even rewrite memories, slipped in invented details such as a favorite song, so the model's job was cut down to asking.
- Some GPUs lack shader-f16; the app checks for it and falls back from q4f16 to q4 weights.
- Generated Hebrew questions were wrong, so Hebrew letters use five hand-written questions.
- Gemma 270M on the browser CPU runtime either failed to load or produced broken output, so it was dropped.
“The clerk never writes a word of your letter. It only asks.”— Night Clerk
Do it yourself
- Open the site in Chrome or Edge on a computer with WebGPU.
- Pick Gemma 3 1B for a quicker download or Gemma 4 E2B if you have a bigger GPU and patience.
- Tell the clerk who the letter is for and one memory, then answer its questions.
- Edit the letter, then burn it or save it as a text file.
- For your own version, clone nightclerk/dead-letter-office and test it with your internet switched off.
Similar setups
Ofrenda Keeper: local Gemma 3 makes a Día de los Muertos card from only what you said
hongpengtan0-max built Ofrenda Keeper, a local app where Gemma 3 4B in Ollama turns what you tell it about someone you miss into an altar card, and plain code removes any detail you didn't actually say.
Ghost in the Machine: a fake 1998 terminal where a local Gemma 3 whispers back at every command
A Hacktoberfest entry in a single HTML file: you type into a simulated old shell and a presence called the tenant answers each command with one eerie line, streamed from Gemma 3 4B on Ollama.
Séance: local Whisper and Gemma 4 turn a grandmother's Malayalam voice notes into a searchable family archive
Clivin John built Séance, which transcribes and translates his grandmother's voice notes on his laptop, has Gemma 4 write memory cards, and answers questions only with her exact, verified words.
Verso: Gemma 4 on an Android phone writes the back of old family photos without inventing names
Fahad Irshad built Verso, an Android app with no internet permission where Gemma 4 E2B writes a title and caption for an old photo from your answers, and asks a question instead of guessing when a fact is missing.