phase~1 min readUpdated 2026-07-16#phase#models#browser-inference

Phase 03 — From Models to Browser Inference

This phase moves from hand-built kernels to real exported models. Success now depends on three contracts agreeing: model graph and weights, runtime operator/backend support, and the media transformations surrounding inference.

Branches

Workbench milestone

v3 — Real models and real runtimes: export the same small model to ONNX and TFLite/LiteRT in FP32 and a justified quantized form, execute it through ONNX Runtime Web and LiteRT.js, and compare each complete pipeline with golden outputs.

What this phase establishes

  • Reproducible export commands and artifact manifests.
  • Operator and shape compatibility checked before product integration.
  • One conceptual backend interface without erasing runtime-specific behavior.
  • Explicit tensor ownership, disposal, preprocessing, and postprocessing.
  • Numerical comparisons that separate conversion, quantization, runtime, and pipeline drift.

Exit criteria

  • Every model artifact has source, format, precision, checksum, size, and operator assumptions.
  • The same fixtures run through both runtime paths or produce an explicit unsupported result.
  • Preprocessing and postprocessing match the reference implementation within declared tolerances.
  • Initialization, first inference, warm inference, peak memory, cleanup, and fallback are recorded.

Continue with Phase 04: Hardware Acceleration.