Memory quality depends on embeddings, and embeddings usually depend on an API key, a per-token bill and a privacy decision. Memo avoids all three by running small open models locally.
The defaults
Xenova/bge-small-zh-v1.5Xenova/bge-small-en-v1.5Both are MIT-licensed BGE models, vendored in the repository and executed through ONNX on the server. No text leaves the deployment to be embedded.
Per-row model tracking
Each memory stores its vector and the model id that produced it, in an untyped vector column. That means two models can coexist, and switching models later does not require a dimension migration — old rows keep their 512-dimensional vector, new rows carry 384 (or the reverse), and comparisons only happen within a model.
Queries are embedded once per model
A query is embedded with each model that exists in the store. A Chinese question can therefore still match English memories and the other way round, which is the common case for bilingual users.
If the models cannot load
The server falls back to a deterministic hash embedder. Recall gets noticeably weaker but the app keeps working; nothing returns an error page because a model file was missing.
Using another provider
Any OpenAI-compatible embedding server can replace the local models, which is useful if you run Ollama or a private gateway:
EMBEDDING_PROVIDERopenaiEMBEDDING_BASE_URLhttp://localhost:11434/v1EMBEDDING_MODELbge-m3HF_ENDPOINThttps://hf-mirror.comThe extraction and answer routes can optionally use Claude when ANTHROPIC_API_KEY is set. Embeddings never do — they stay on-device regardless.