← All models

image-feature-extraction Β· vision + language Β· WASM Β· ~236 MB

Nomic multimodal embeddings β€” search images by meaning

Two aligned models project pictures and words into the same 768-number space, so a phrase and an image become comparable. Type a dog and the dog photo rises to the top; click an image and find the ones most like it. CLIP-style cross-modal search β€” from the Nomic family β€” with real embeddings you can see, all on your device.

At a glance

Modelsnomic-ai/nomic-embed-vision-v1.5 (image) + nomic-ai/nomic-embed-text-v1.5 (text)
Task / pipelineimage-feature-extraction + text feature-extraction, one shared space
ArchitectureViT image tower + nomic-BERT text tower, aligned (Nomic Embed multimodal)
Output768-d embedding per image / per text, L2-normalised (cosine = dot product)
Quantizationq8 (8-bit) ONNX, both towers
BackendWebAssembly (runs anywhere; no WebGPU needed)
Download~236 MB total (~96 MB vision + ~140 MB text), cached after first load
LicenseApache-2.0 (Nomic AI)
Web APIsWebAssembly, Web Workers, Canvas, FileReader β€” all Baseline widely available

Run it

When the models load, the gallery is embedded once. Then search it two ways: type a phrase (text β†’ image), or pick a photo to find look-alikes (image β†’ image). Everything is on-device.

Drop your own image here to add it to the gallery, or click to choose

Gallery

Gallery images via Wikimedia Commons β€” see references for full attribution.

See inside

Every image and every phrase becomes one 768-number vector, unit-normalised so its length is 1. Similarity is the cosine β€” here a plain dot product β€” between the query vector and each image vector. Below is the query's vector as a colour fingerprint (warm = positive, blue = negative), then the exact cosine to each gallery image. Same gallery, different phrase β†’ different ranking. That is the whole trick, and it is cross-modal: text and image share one space.

Run a search to see the query vector and the cosine table.

Why it matters

A shared image–text space turns "search" into "compare vectors." No fixed tags, no per-image API call β€” you embed once, then rank by meaning, in the browser, for free.

Use cases

Basics

Type a phrase and watch the gallery re-rank by meaning β€” feel cross-modal search first-hand.

Practical

Zero-shot image tagging: score any image against label phrases you type, no training.

Wild

Embedding explorer: see the whole gallery arranged by similarity to whatever you pick.

Multi-model

Search β†’ caption: retrieve the best image for a phrase, then ViT-GPT2 describes it.

How the API works

Both towers load with the low-level Transformers.js classes and share a 768-d space:

import { AutoModel, AutoProcessor, AutoTokenizer, RawImage } from "@huggingface/transformers";

const proc  = await AutoProcessor.from_pretrained("nomic-ai/nomic-embed-vision-v1.5");
const vis   = await AutoModel.from_pretrained("nomic-ai/nomic-embed-vision-v1.5", { dtype: "q8" });
const tok   = await AutoTokenizer.from_pretrained("nomic-ai/nomic-embed-text-v1.5");
const txt   = await AutoModel.from_pretrained("nomic-ai/nomic-embed-text-v1.5", { dtype: "q8" });

// image β†’ 768-d (CLS token of last_hidden_state)
const img = await (await vis(await proc(await RawImage.read(url)))).last_hidden_state;
// text  β†’ 768-d (mean-pooled), prefixed "search_query: " for queries
const q   = await txt(tok("search_query: a dog", { padding: true }));
// cosine of the L2-normalised vectors = similarity

This page runs both towers in a Web Worker and L2-normalises every vector there, so ranking the gallery on the main thread is a handful of dot products. Nothing is uploaded.

References

Gallery images (all via Wikimedia Commons): person β€” Jones, W. A. (Public domain); dog β€” Tudor Washington Collins (CC BY 4.0); citrus β€” Scott Bauer, USDA (Public domain); mountains β€” KennyOMG (CC BY-SA 3.0); night city β€” King of Hearts (CC BY-SA 3.0); bicycle β€” Ingolfson (Public domain); market β€” Francisco Anzola (CC BY 3.0); glass β€” steven powell (CC BY 2.0).