Multi-model · 137.56 MB Cross-Lingual CJK Dense Retrieval + EN Brief Translation

2-Stage Pipeline: BGE Small ZH v1.5 → OPUS-MT ZH→EN

Chain Stage 1: BAAI/bge-small-zh-v1.5 (Xenova/bge-small-zh-v1.5, 24.45 MB q8 WASM) to retrieve relevant Chinese passages natively, then feed Top-K hits into Stage 2: Helsinki-NLP/opus-mt-zh-en (Xenova/opus-mt-zh-en, 113.11 MB q8 WASM) for live on-device English briefs.

1. Load both stages (137.56 MB total WASM q8)

Stage 1 · BGE Small ZH v1.5 (24.45 MB)

Stage 2 · OPUS-MT ZH→EN (113.11 MB)

2. Live Stage 1 Chinese Retrieval + Stage 2 English Briefs

Stage 1 · BGE Small ZH v1.5 (512-d CLS)

Load Stage 1 to embed the Chinese corpus and shortlist Top-K hits.

    Stage 2 · OPUS-MT ZH→EN (English Briefs)

    Load Stage 2 to translate Stage 1 Top-K Chinese hits into English.

      Stage 1 Cosine vs Stage 2 Translation Latency

      Cross-Lingual Retrieval Brief Table

      Comparison of Stage 1 Chinese dense retrieval and Stage 2 English translation
      Rank Doc BGE cos Chinese Source Live English Brief (OPUS-MT) EN ms
      Run both stages above to populate live Chinese hits and English translations.

      Show the code

      Show the code: OPUS-MT ZH→EN Stage 2 batch translation (opus-mt-zh-en/worker.js)
      Show the code: Stage 1 + Stage 2 cross-lingual merge helper (bge-zh-core.mjs)