← All models · Jina reranker (tiny)

use case · multi-model

Multi-model: MiniLM retrieves, Jina reranks

The two-stage pipeline behind real search and RAG, running entirely in your browser with two tiny models. Stage 1: a MiniLM bi-encoder embeds every passage and the query and ranks by cosine similarity — fast, but only surface-level. Stage 2: the tiny Jina cross-encoder reads each shortlisted (query, passage) pair together and reorders for precision. Compare the two orders — and note both models together are under ~60 MB.

Why two stages?

A bi-encoder embeds each document once, offline, so retrieval is a fast vector lookup over the whole corpus — but it never sees the query and document together, so it misses subtle relevance. A cross-encoder does see them together and is far more precise, but it must run the model on every pair, so you only afford it on a shortlist. Retrieve wide and cheap, then rerank narrow and precise. With a tiny reranker, even that second stage fits on-device.

← Back to Jina reranker (tiny) · About MiniLM embeddings →