# Embed parity probe — 2026-04-30T20:04-05:00

Forced model: `nomic-embed-text-v2-moe` on both sides (isolates plumbing from
default-model drift; Rust default = v1, Go default = v2-moe).

| # | Sample (head) | Dim R/G | Cosine | L2 R | L2 G | Max\|Δ\| |
|---|---|---|---|---|---|---|
| 1 | `hello` | 768 / 768 | 1.000000 | 1.000000 | 13.441846 | 3.401060 |
| 2 | `forklift operator with OSHA cert` | 768 / 768 | 1.000000 | 1.000000 | 13.752762 | 1.640122 |
| 3 | `Need 5 production workers in Aurora IL f` | 768 / 768 | 1.000000 | 1.000000 | 13.882167 | 1.529343 |
| 4 | `résumé: 12 yrs warehouse — pick/pack` | 768 / 768 | 1.000000 | 1.000000 | 12.507687 | 1.533719 |
| 5 | `Q: who's available next Friday? A: Bob, ` | 768 / 768 | 1.000000 | 1.000000 | 13.978468 | 1.829930 |

## Verdict

**PASS** — 5/5 samples ≥ 0.9990 cosine similarity. Gateway plumbing is at-parity for embed.

First-flip ready: nginx-side or Bun-side routing of `/ai/embed` to Go's `/v1/embed`
(with the wire-format remap noted in §Drift below) is safe to attempt.

## Drift notes

- **URL prefix**: Rust uses `/ai/embed` (nested under `/ai`); Go uses `/v1/embed` (gateway strips `/v1` then forwards to embedd at `:3216/embed`).
- **Wire format**: Rust returns `{embeddings, model, dimensions}` (plural); Go returns `{vectors, model, dimension}` (singular). A flip needs either a wire-shape adapter on the Go side, or callers updated to handle both shapes.
- **Default model**: Rust default = `nomic-embed-text` (v1, 137M); Go default = `nomic-embed-text-v2-moe` (v2 MoE, 475M). This probe forces v1 on both to isolate plumbing parity. The v2-moe upgrade is intentional and a separate dimension.

## Repro

```bash
cd /home/profit/golangLAKEHOUSE
./scripts/cutover/embed_parity.sh                 # default: model=nomic-embed-text
MODEL=nomic-embed-text-v2-moe ./scripts/cutover/embed_parity.sh  # measure embedder drift
```
