> ## Documentation Index
> Fetch the complete documentation index at: https://docs.duckbrain.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# embed

> Generate local embeddings for everything in the lake

```bash theme={null}
duckbrain embed [--limit n]
```

Embeds every text row with **EmbeddingGemma-300M** running locally via node-llama-cpp (Metal-accelerated; the model auto-downloads to `~/.duckbrain/models/` on first run, \~334MB). Nothing leaves the machine.

**Incremental:** only rows without an embedding for the current model are processed (anti-join on `record_id + model`) — re-running is free. Model name and dimensions are recorded per row, so switching models later is additive, never destructive.

Throughput reference: \~105 docs/s on Apple Silicon (9,088 docs in 87s).


## Related topics

- [sync](/commands/sync.md)
- [index](/commands/index.md)
- [ingest](/commands/ingest.md)
