sentence-similarity · feature-extraction · 18.16 MB WASM q8 · Apache-2.0

paraphrase-MiniLM-L3-v2 — 3-Layer Edge Paraphrase Encoder

The smallest Transformer sentence encoder in the catalogue: a 3-layer, 12-head BertModel trained on paraphrase pairs to map English sentences into 384-d mean-pooled unit vectors in just 18.16 MB total (q8 CPU WASM via shared ../../lib/webai.js on @huggingface/transformers@3.7.5).

Model Card & Runtime Contract

Tasks
sentence-similarity via feature-extraction
Backend & Quant
WASM · q8 (17.45 MB ONNX + 0.71 MB tok = 18.16 MB)
Architecture
3L · 12H · 384-d · 1,536 FFN · 30,522 uncased WordPiece · pooling: "mean"
Seq Limit & License
128 SentenceTransformer (512 BERT max) · Apache-2.0
Ultra-Light 3-Layer Speed vs 6/12-Layer Encoders: Halving the depth from 6 layers to 3 Transformer blocks keeps the same 384-d output space and 30,522-token WordPiece vocabulary while shrinking the quantized ONNX weights to 17.45 MB (18.16 MB first visit). Use pooling: "mean" with L2 normalization and no query/passage prefix.

Load & Cache Status

Live Paraphrase Scorer & Similarity Matrix

Drop, paste, or upload a .txt, .md, .csv, or .json list of candidate sentences.

Ranked Paraphrase Similarity

Load the model to embed and rank all sentences locally.

    2D PCA Semantic Constellation

    Diamond marks the reference sentence; dashed rays connect top-3 closest paraphrases.

    See Inside the Model (384-d Tensor & WordPiece Telemetry)

    384-d Embedding Sparkline & Distribution

    Run inference to inspect live 384-d coordinate min, max, mean, std, and L2 norm.

    Pairwise Cosine Heatmap (All Sentences)

    Live Uncased WordPiece Tokenization & 128-Token Limit Audit

    Inspects real uncased WordPiece IDs ([CLS] 101, [SEP] 102, [UNK] 100) before truncation.

    Per-sentence WordPiece token count, [UNK] count, L2 norm, and cosine score
    ID Tokens [UNK] 128-tok Norm Cosine
    Awaiting live inference…

    Show the Code (Exact Worker & Pooling Pipeline)

    Show the code: Off-main-thread feature-extraction + mean pooling (worker.js)
    Show the code: FIFO ParaphraseL3Engine lifecycle & dispose client (l3-client.js)