use case · multi-model · PP-OCRv5 Mobile (21.5 MB) → Opus-MT ZH→EN (113.11 MB) · ~134.6 MB total · CC-BY-4.0 & Apache-2.0

Chinese Photo / Sign / Receipt OCR → English Translator

Chain two completely independent browser AI runtimes locally in one tab: Stage 1 runs PP-OCRv5 Mobile (21.5 MB fp32 ONNX via onnxruntime-web@1.21.0, 18,383-character CJK+Latin dictionary, reusing pp-ocrv5-mobile/worker.js with zero weight duplication) to detect and transcribe Chinese lines from any sign, menu, or receipt; Stage 2 feeds every extracted Chinese line into Opus-MT ZH→EN (113.11 MB q8 WASM via @huggingface/transformers@3.7.5, CC-BY-4.0) and paints translated English overlays directly onto the image canvas.

1 · Two isolated WASM workers (~134.6 MB combined)

Stage 1 · PP-OCRv5 Mobile (21.5 MB fp32)

Shared pp-ocrv5-mobile/worker.js · PaddlePaddle/PP-OCRv5_mobile_det_onnx + rec_onnx · Apache-2.0

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

Helsinki-NLP/opus-mt-zh-en → Xenova/opus-mt-zh-en · CC-BY-4.0

2 · Select a Chinese Sign / Photo or Upload Your Own

Curated Chinese OCR cards & verified street photograph
Drop any Chinese sign, menu, screenshot, or receipt photo — processed 100% on-device:

Prepare both workers above (or either stage independently) to run local Chinese OCR → English translation.

Stage 1 OCR—
Detected lines—
Stage 2 ZH→EN—
Combined time—
Tokens (in→out)—
NaN count—

Live Translated Image Overlay

Extracted Chinese Lines → English Translations

# Stage 1 OCR (Chinese) Conf Stage 2 English ms
Run Stage 1 (or the full pipeline) to extract and translate Chinese lines.

Stage 1: PaddlePaddle/PP-OCRv5_mobile_det_onnx + PaddlePaddle/PP-OCRv5_mobile_rec_onnx (Apache-2.0, 21.5 MB fp32 ONNX). Stage 2: Helsinki-NLP/opus-mt-zh-en → Xenova/opus-mt-zh-en (113.11 MB q8 ONNX, CC-BY-4.0). Verified street photo: media/assets/city-street.webp by Ken & Nyetta (CC-BY-2.0, image-provenance/ledger.json).