10. Interview Prep Guide¶
2-minute script¶
"I built an IndicTrans2 ONNX export factory for browser translation. Optimum couldn't export the custom model, so I wrote wrappers and a three-graph encoder–decoder export, then optimized bundles with tied-weight sharing so WASM downloads shrink. Fast tokenizers remap SentencePiece IDs to Fairseq dicts. Everything passes a 99% token-exact parity gate on thousands of fixtures before fp16/int8/q4f16 variants go to Hugging Face for the browser demo and local-voice-chat."
5-minute outline¶
- Problem: browser NMT needs ONNX, not PyTorch
- Why Optimum failed
- Graph layout + KV past
- Size optimization story
- Tokenizer pitfalls
- Quantization tradeoffs (200M vs 1B)
- Consumers: demo + voice chat
- Gaps: no export CI, some README drift
Likely questions¶
| Q | Angle |
|---|---|
| Why not Optimum? | Custom architecture rejection |
| How validate? | Token-exact parity vs PyTorch |
| Why shared sidecar? | Browser download size |
| Q4 vs int8? | Size vs accuracy tables |
| 1B differences? | Config-driven dims, protobuf limits |
Weak spots¶
No automated CI for parity; README references missing files; quant quality uneven on small models.
Proud of¶
Turning a research PyTorch checkpoint into a reproducible, size-aware, browser-consumable artifact pipeline with honest benchmarks.