--- license: mit base_model: ai-sage/GigaAM-v3 base_model_relation: quantized library_name: mlx pipeline_tag: automatic-speech-recognition language: - ru tags: - automatic-speech-recognition - speech-recognition - russian - offline - mlx - apple - apple-silicon - ios - ipados - macos - rnnt - conformer - sentencepiece - native-apple --- # GigaAM v3 MLX **GigaAM v3 MLX** is a native Apple MLX runtime bundle for offline Russian automatic speech recognition on iPhone, iPad, and Mac. This repository contains converted model assets for running `ai-sage/GigaAM-v3` revision `e2e_rnnt` with a native Apple runtime. The bundle is intended for native on-device inference on Apple platforms without Python, PyTorch, Transformers, torchaudio, librosa, pyannote, or server-side inference at runtime. ## Model * Base model: `ai-sage/GigaAM-v3` * Revision: `e2e_rnnt` * Architecture: Conformer RNN-T * Language: Russian * Runtime target: native Apple MLX * Precision: FP16 * Sample rate: 16 kHz * Audio channels: mono * Tokenizer: SentencePiece * Vocabulary size: 1024 * Blank ID: 1024 * Output classes: 1025 ## Target platforms This model bundle is intended for native Apple applications: | Platform | Target | | -------- | ----------------- | | iOS | iPhone | | iPadOS | iPad | | macOS | Apple Silicon Mac | ## Intended use This bundle is intended for offline speech recognition in native Apple applications: * iPhone apps * iPad apps * macOS apps * local transcription tools * privacy-preserving offline ASR * Russian speech-to-text without cloud inference * native Swift/MLX ASR runtimes This repository contains model assets only. It is not a Python inference package. ## Repository files ```text README.md .gitattributes manifest.json checksums.sha256 weights.fp16.safetensors tokenizer.model hann_window.f32.bin mel_filterbank_mel_freq.f32.bin ``` | File | Description | | --------------------------------- | ------------------------------------------------------------ | | `weights.fp16.safetensors` | FP16 converted model weights | | `tokenizer.model` | SentencePiece tokenizer | | `manifest.json` | Runtime manifest with model, frontend, and decoding metadata | | `hann_window.f32.bin` | Hann window used by the frontend | | `mel_filterbank_mel_freq.f32.bin` | Mel filterbank used by the frontend | | `checksums.sha256` | SHA-256 checksums for integrity checks | | `.gitattributes` | Git LFS rules for binary model assets | ## Runtime pipeline The intended native runtime pipeline is: ```text Audio file / PCM samples → native audio loader → 16 kHz mono Float32 PCM → mel spectrogram frontend → Conformer encoder → RNNT greedy decoder → SentencePiece tokenizer → text ``` The model bundle includes frontend assets so that native runtimes can reproduce the original preprocessing without relying on Python audio libraries. ## Frontend configuration | Parameter | Value | | ------------------ | ----: | | Sample rate | 16000 | | Channels | 1 | | Number of mel bins | 64 | | FFT size | 320 | | Window length | 320 | | Hop length | 160 | | Center | false | | Mel scale | HTK | | Mel normalization | none | | Power | 2.0 | The effective feature hop is 10 ms before encoder subsampling. The encoder uses a subsampling factor of 4, so one encoder frame corresponds approximately to 40 ms of audio. ## Architecture details | Component | Value | | ------------------------ | --------------------- | | Encoder type | Conformer | | Number of encoder layers | 16 | | Model dimension | 768 | | Attention heads | 16 | | Attention type | Rotary self-attention | | Convolution kernel size | 5 | | Subsampling | Conv1D | | Subsampling factor | 4 | | Prediction network | RNNT predictor | | Joint network | RNNT joint | | Decoding | Greedy RNNT | | Tokenizer | SentencePiece | | Vocabulary size | 1024 | | Blank ID | 1024 | | Output classes | 1025 | ## Validation The conversion was validated against the original PyTorch/Hugging Face model using tensor-level golden references. Validated components include: * audio frontend * mel spectrogram * pre-encoder * Conformer feed-forward blocks * rotary self-attention * Conformer convolution block * full Conformer layer * encoder stack * RNNT predictor * RNNT joint network * RNNT greedy decoding * SentencePiece tokenizer * full WAV-to-text pipeline ### Selected validation results #### Mel frontend parity ```text feature_shape: [64, 99] max_abs_diff: 0.0004234314 mean_abs_diff: 2.8040542e-05 ``` #### Encoder stack parity ```text stack_max_abs_diff: 2.5629997e-06 stack_mean_abs_diff: 3.8420205e-07 ``` #### Full encoder parity ```text output_shape: [1, 768, 25] max_abs_diff: 2.682209e-06 mean_abs_diff: 4.0401252e-07 ``` #### End-to-end smoke test A short Russian WAV sample was used to verify end-to-end decoding against the Python reference implementation. The native runtime and the Python reference produced identical text for the same input audio. The audio fixture is not included in this model repository. It is used only for runtime validation. ## Performance Benchmarks were measured on Apple M1 Max with a native Apple MLX runtime in release mode. ### Short audio benchmark | Runtime | Audio duration | Total time | RTF | Speed | | ------------------------ | -------------: | ---------: | -----: | --------------: | | Native Apple MLX runtime | ~6 s | ~0.168 s | ~0.028 | ~35.8× realtime | | Python reference | ~6 s | ~0.701 s | ~0.117 | ~8.6× realtime | The native runtime was approximately 4.2× faster than the Python reference in this short-audio warm benchmark. ### Long-form benchmark Long-form audio is processed in chunks to keep memory usage predictable and enable efficient transcription on Apple devices. | Metric | Value | | ------------------------ | --------------: | | Audio duration | 911.252 s | | Audio duration | 15 min 11 s | | Chunk size | 20.0 s | | Chunk count | 46 | | Total transcription time | 24.2145 s | | Real-time factor | 0.02657 | | Speed | ~37.6× realtime | | Peak resident memory | ~1.15 GB | ### Long-form stage breakdown | Stage | Time | Share | | -------------------- | -------: | -----: | | Audio load | 0.019 s | ~0.1% | | Mel frontend | 5.993 s | ~24.8% | | Model total | 18.203 s | ~75.2% | | Encoder | 5.463 s | ~22.6% | | RNNT greedy decoding | 12.736 s | ~52.6% | | RNNT decoder | 1.821 s | ~7.5% | | RNNT joint | 10.680 s | ~44.1% | | RNNT readback | 0.169 s | ~0.7% | | Tokenizer | 0.003 s | ~0.0% | The current main runtime bottleneck is the RNNT joint network during greedy decoding. ### Memory | Scenario | Peak RSS | | ----------------------------------------- | -------: | | Native Apple MLX runtime, short audio | ~1.10 GB | | Native Apple MLX runtime, long-form audio | ~1.15 GB | | Python reference, short audio | ~1.76 GB | ## Long-form transcription Long-form audio is intended to be processed in chunks. Recommended initial long-form settings: ```text chunk_seconds: 20 overlap_seconds: 0-2 sample_rate: 16000 channels: mono ``` Future runtimes may use VAD, overlap merging, and timestamp-aware segmentation for improved long-form quality. ## Limitations * This bundle is optimized for native Apple MLX runtimes. * Long audio should be processed in chunks. * Current validation focuses on numerical parity and runtime behavior. * Word-level timestamps are not included in the model bundle itself. * Diarization is not included. * This repository contains model assets only, not application code or SDK source code. ## Relation to the original model This bundle is a native Apple MLX runtime conversion of: ```text ai-sage/GigaAM-v3 revision: e2e_rnnt ``` No additional training or fine-tuning was performed. The conversion preserves the original Conformer RNN-T architecture, SentencePiece tokenizer layout, and preprocessing configuration, while packaging the model assets for native offline inference on iOS, iPadOS, and macOS. ## License This model bundle follows the license terms of the original `ai-sage/GigaAM-v3` model. License: MIT ## Attribution If you use this bundle, please also reference the original GigaAM model: ```text ai-sage/GigaAM-v3 ``` ## Summary GigaAM v3 MLX provides a native Apple MLX model bundle for offline Russian ASR. It is intended for local, private, on-device speech recognition on Apple platforms without requiring Python or server-side inference at runtime.