# Vendored third-party files (browser app)

`web/vendor/` is not in git (root `.gitignore`). `web/scripts/fetch_vendored_deps.sh` fetches
everything below with SHA-256 verification; re-run it after a clean checkout. Same policy as
`app/THIRD_PARTY_PROVENANCE.md`. Recorded 2026-09-20.

## `vendor/onnxruntime-web/` — onnxruntime-web 1.29.0 (MIT)

Runs both ONNX models in the browser and in the node tests. Only the wasm-only ES-module entry
and the single-threaded-capable SIMD wasm are vendored: no WebGPU/WebGL/JSEP builds, no
threaded/asyncify/jspi variants.

| file | SHA-256 |
|---|---|
| npm tarball `https://registry.npmjs.org/onnxruntime-web/-/onnxruntime-web-1.29.0.tgz` | `7a934b7811c3b050ecfb7619722e2b4de771ce6da20520e17a2018a440316ef3` |
| `ort.wasm.min.mjs` (from `package/dist/`) | `14a0a63ad1a0fe8127722929fd16fb26c2e5352ea221bc9034d12daf314d0b92` |
| `ort-wasm-simd-threaded.mjs` | `5a15f1fd086b3f6c2baf1f35105b8f502653b567e165cef80028870b39748747` |
| `ort-wasm-simd-threaded.wasm` | `ec8580a9d7b9476ceee52e10a7f94124e4dc71a019d666ed6d4726697c109a4d` |

npm integrity of the tarball: `sha512-LuQlpX6MFLJZu756erwUeb1mNfoJGbs1kzDwJGNlf5RvfYMdqhcY3vNpDPK40CUV2HoWTkIj+uS0o36GFHjeYw==`.

Why 1.29.0: when it was chosen the Android app ran 1.28.0 (1.32.0 since 2026-11-15,
`DEVELOPMENT_PLAN.md` §59; this pin did not move with it), and `onnxruntime-web@1.28.0` does not exist on npm
(the registry lists 1.27.0, `1.28.0-dev.20260624-ba45260eed`, then 1.29.0). 1.29.0 is the nearest
stable release. The §13 telemetry-file concern with onnxruntime 1.29.0 on Android does not carry
over to a wasm build (no filesystem) behind the CSP; `js/pipeline/ort.js` pins its `wasmPaths` to the vendored folder (the vendored
`ort.wasm.min.mjs` contains no CDN URL; `test/no_network.test.mjs` reports this), and
`connect-src 'self'` would block a CDN regardless.

Note: the file is named `...-threaded...` upstream for every wasm build; with `numThreads = 1`
it runs single-threaded and needs no SharedArrayBuffer.

## `vendor/models/silero_vad.onnx` — Silero VAD (MIT)

The exact bytes the Android app runs: extracted from the android-vad 2.0.6 AAR on JitPack, the
same artefact `research/models/PROVENANCE.md` documents. The app itself resolves android-vad
2.0.10 since 2026-10-07 (`DEVELOPMENT_PLAN.md` §48); the `silero_vad.onnx` inside that AAR has the
same SHA-256 as the one below (compared 2026-11-15), so the fetch still takes it from 2.0.6.

| artefact | SHA-256 |
|---|---|
| `https://jitpack.io/com/github/gkonovalov/android-vad/silero/2.0.6/silero-2.0.6.aar` | `4a771f0f332562d008209ff32ebc2e0eb270e517889dec82109fa7758790f24d` |
| `assets/silero_vad.onnx` inside it (1,807,522 bytes) | `a35ebf52fd3ce5f1469b2a36158dba761bc47b973ea3382b3186ca15b1f5af28` |

Licence: MIT (snakers4/silero-vad; `research/models/LICENSE.silero_vad`). The VAD parity test
only means something against this exact file.

## `vendor/models/3dspeaker_speech_eres2net_sv_en_voxceleb_16k.onnx` — 3D-Speaker ERes2Net

Identical to the file the Android app and the research harness use
(`app/THIRD_PARTY_PROVENANCE.md`, `research/models/PROVENANCE_embedding_candidates.md`).

| artefact | SHA-256 |
|---|---|
| `https://github.com/k2-fsa/sherpa-onnx/releases/download/speaker-recongition-models/3dspeaker_speech_eres2net_sv_en_voxceleb_16k.onnx` (26,485,263 bytes) | `c59158379255ad66e161679cca6af8d52d51e389e3224ab7d7a7baae295c2db5` |

Licence: Apache-2.0 repository licence; **the checkpoint's own model card on ModelScope has not
been read** (STATUS.md), which gates any distribution of this app as much as the Android one.
Model metadata (read from the file): `framework=3d-speaker`, `sample_rate=16000`,
`normalize_samples=1`, `feature_normalize_type=global-mean`, `output_dim=192`, input `x[N,T,80]`.

## Not vendored: sherpa-onnx wasm (v1.13.7)

Inspected on 2026-09-20 at the version the app ran then, not used; not re-inspected for v2.0.1. `sherpa-onnx-wasm-simd-v1.13.7-speaker-diarization.tar.bz2`
(SHA-256 `f197725498893010a8da8f18c62ee67c62ed7294ab33d68a0b182211fcba0b7d`) exports only the
`OfflineSpeakerDiarization` C API and bakes a pyannote segmentation model plus an embedding model
into its `.data`; no `SpeakerEmbeddingExtractor` symbols. `sherpa-onnx-wasm-simd-v1.13.7-vad.tar.bz2`
(SHA-256 `b21cbf646b9bde6b5fcb393db981f4ffa3cdf60868cb1e7248695f6a068070c6`) exposes sherpa-onnx's
own `VoiceActivityDetector`, whose hang-time semantics differ from android-vad's. See
`README.md` "Why not the sherpa-onnx wasm".

## Ported source (not binaries)

- `js/pipeline/fbank.js` is a port of kaldi-native-fbank **v1.22.3** (Apache-2.0; the version
  sherpa-onnx v1.13.7's `cmake/kaldi-native-fbank.cmake` pins, tarball SHA-256
  `9176cc66fc7ce1edf85cf355b06e320c57db6297df74277f575183468893cf61`): `feature-window.cc`,
  `feature-fbank.cc`, `mel-computations.cc`, `feature-functions.cc`, `online-feature.cc`, with the
  option values from sherpa-onnx v1.13.7 `sherpa-onnx/csrc/features.{h,cc}` and
  `speaker-embedding-extractor-general-impl.h`.
  **Checked against sherpa-onnx v2.0.1 on 2026-11-16** (`DEVELOPMENT_PLAN.md` §61), the version the
  Android app runs since then: those three sherpa files are byte-identical to v1.13.7's; v2.0.1
  pins kaldi-native-fbank v1.22.4 (tarball SHA-256
  `257fea639585ca6ee00860493bb9d7ab32488b8a5407ffe434c1f361ea545fae` per its cmake file), whose
  diff to v1.22.3 touches only `feature-fbank.{h,cc}` among the ported files: the log floor
  became configurable (`use_log_floor`, `eps`), with defaults equal to the old hard-coded
  `log(max(e, FLT_EPSILON))` that the port implements, and sherpa sets neither. The port did not
  change, and the parity fixture regenerated under 2.0.1 has the same embeddings bit for bit.
- `js/pipeline/vad_silero.js` is a port of `research/src/laberampel_research/vad_silero.py`,
  itself a port of android-vad 2.0.6's `VadSilero.kt` (MIT).

## `models/adult_child_logreg.json` (committed, not vendored)

Produced by the research harness (`scripts/train_adult_child_classifier.py`, 2026-09-20) and
copied from `research/models/adult_child_logreg.json` by the fetch script whenever the harness
file differs. Contents: `model_id`, 192 weights, bias, threshold 0.47, the training-set
description and held-out accuracy by age band. Trained on speechocean762 (CC BY 4.0) plus
far-field adult segments from AMI / ICSI / AISHELL-4.
