Luigi commited on
Commit
bbc906f
·
verified ·
1 Parent(s): b39d698

v2: q4-mix LiteRT of the zh-TW FINE-TUNED model (CV zh-TW CER 13.90 vs ~38 for v1 warm-start; fp32 ref 12.03)

Browse files
README.md CHANGED
@@ -2,69 +2,62 @@
2
  license: other
3
  license_name: nvidia-open-model-license
4
  license_link: https://www.nvidia.com/en-us/agreements/enterprise-software/nvidia-open-model-license/
5
- base_model: nvidia/nemotron-3.5-asr-streaming-0.6b
6
- language:
7
- - zh
8
- - en
9
- - ja
10
- - ko
11
- tags:
12
- - litert
13
- - tflite
14
- - automatic-speech-recognition
15
- - streaming-asr
16
- - FastConformer
17
- - RNNT
18
- - zh-tw
19
- - traditional-chinese
20
  pipeline_tag: automatic-speech-recognition
21
  library_name: litert
22
  ---
23
 
24
- # Nemotron-3.5-ASR-Streaming-0.6B — LiteRT q4-mix (zh-TW variant)
25
 
26
- zh-TW-enabled variant of
27
- [Luigi/nemotron-asr-litert](https://huggingface.co/Luigi/nemotron-asr-litert)
28
- (the faithful q4-mix port). The base model's **zh-TW** language slot (5) is
29
- untrained (100% CER); this variant **warm-starts it from the working zh-CN slot**
30
- — a lossless copy of the zh-CN column of the prompt projector into the zh-TW
31
- column, baked into `nemotron_prompt_fuse_fp32.tflite`. Nothing else changes
32
- (encoder / decoder / joint are byte-identical to the base repo).
33
 
34
- **Result:** the `zh-TW` slot now works natively at **15.78% CER end-to-end** (on
35
- par with zh-CN), up from 100% (dead). Output is Simplified Chinese; add OpenCC
36
- `s2t` for Traditional.
37
 
38
- > This is v1.1 — a zero-training warm-start. A future v2 fine-tune will add native
39
- > Traditional output + far-field/meeting-domain robustness (IVOD).
40
 
41
- ## Files
 
 
 
 
 
 
 
42
 
43
- Identical layout to the base repo; only `nemotron_prompt_fuse_fp32.tflite` differs.
44
 
45
  | file | role | precision | size |
46
  |---|---|---|---|
47
- | `nemotron_encoder_q4.tflite` | FastConformer encoder | INT4 FC (QAT) + fp32 convs | 569 MB |
48
- | `nemotron_prompt_fuse_fp32.tflite` | 128-slot prompt fusion (**zh-TW warm-started**) | fp32 | 17 MB |
49
- | `nemotron_decoder_fp16.tflite` | RNN-T prediction net | fp16 | 29 MB |
50
- | `nemotron_joint_fp16.tflite` | RNN-T joint (→ vocab 13088) | fp16 | 17 MB |
51
  | `tokenizer.json` / `processor_config.json` / `config.json` | runtime | — | — |
52
 
53
- ## Usage
54
 
55
- Same 4-graph RNN-T greedy pipeline as the base repo (see the
56
- [port + runner](https://github.com/vieenrose/LiteRT/tree/nemotron/litert/samples/asr/nemotron)):
57
 
58
  ```bash
59
- python -m nemotron.runner --models ./ --wav clip.wav --lang zh-TW --s2t
60
  ```
61
 
 
 
 
62
  The INT4 encoder needs the LiteRT-Next `CompiledModel` runtime (Android NNAPI /
63
  XNNPACK-QD8); the classic `Interpreter` cannot allocate dynamic-range INT4.
 
64
 
65
  ## Provenance
66
 
67
- Base: nvidia/nemotron-3.5-asr-streaming-0.6b (NVIDIA Open Model License). The INT4
68
- encoder is QAT'd (label-based RNN-T self-distillation); the zh-TW slot is warm-
69
- started from zh-CN (weight copy, no training). Everything else is
70
- numerics-preserving conversion.
 
2
  license: other
3
  license_name: nvidia-open-model-license
4
  license_link: https://www.nvidia.com/en-us/agreements/enterprise-software/nvidia-open-model-license/
5
+ base_model: Luigi/nemotron-3.5-asr-streaming-0.6b-zhtw
6
+ language: [zh, en, de, fr, es, ar, ja, ko]
7
+ tags: [litert, tflite, automatic-speech-recognition, streaming-asr, FastConformer, RNNT, zh-tw, q4]
 
 
 
 
 
 
 
 
 
 
 
 
8
  pipeline_tag: automatic-speech-recognition
9
  library_name: litert
10
  ---
11
 
12
+ # Nemotron-3.5-ASR — LiteRT q4-mix, zh-TW fine-tuned (v2)
13
 
14
+ On-device (Android) LiteRT build of
15
+ [Luigi/nemotron-3.5-asr-streaming-0.6b-zhtw](https://huggingface.co/Luigi/nemotron-3.5-asr-streaming-0.6b-zhtw)
16
+ — the zh-TW **fine-tuned** Nemotron (3.2× better Taiwan Mandarin than base).
17
+ **q4-mix**: INT4 encoder + fp16 decoder/joint + fp32 prompt-fusion. Bundle **663 MB**.
 
 
 
18
 
19
+ Supersedes v1 (which packaged the zero-training warm-start).
 
 
20
 
21
+ ## Accuracy
 
22
 
23
+ | build | CV zh-TW CER |
24
+ |---|---|
25
+ | fp32 fine-tuned model (reference) | 12.03 |
26
+ | **this q4-mix LiteRT** | **13.90** (+1.87 INT4 cost) |
27
+ | v1 q4-mix (base warm-start) | ~38 |
28
+
29
+ Other languages (fp32 FT, vs base): ko/de/ja/hi/en all improve, ar flat,
30
+ fr/es +1.5 — see the [source model card](https://huggingface.co/Luigi/nemotron-3.5-asr-streaming-0.6b-zhtw).
31
 
32
+ ## Files
33
 
34
  | file | role | precision | size |
35
  |---|---|---|---|
36
+ | `nemotron_encoder_q4.tflite` | FastConformer encoder | INT4 FC (blockwise-128) + fp32 convs | 596 MB |
37
+ | `nemotron_prompt_fuse_fp32.tflite` | 128-slot language-prompt fusion | fp32 | 18 MB |
38
+ | `nemotron_decoder_fp16.tflite` | RNN-T prediction net | fp16 | 31 MB |
39
+ | `nemotron_joint_fp16.tflite` | RNN-T joint (→ vocab 13088) | fp16 | 18 MB |
40
  | `tokenizer.json` / `processor_config.json` / `config.json` | runtime | — | — |
41
 
42
+ ## Run
43
 
44
+ Port, runner and integration note:
45
+ https://github.com/vieenrose/LiteRT/tree/nemotron/litert/samples/asr/nemotron
46
 
47
  ```bash
48
+ python -m nemotron.runner --models ./ --wav clip.wav --lang zh-TW --s2t --itn
49
  ```
50
 
51
+ **Output is Simplified Chinese** — the tokenizer cannot represent many common
52
+ Traditional characters, so apply OpenCC `s2t` (`--s2t`) for Traditional.
53
+
54
  The INT4 encoder needs the LiteRT-Next `CompiledModel` runtime (Android NNAPI /
55
  XNNPACK-QD8); the classic `Interpreter` cannot allocate dynamic-range INT4.
56
+ Set the CPU thread count explicitly (big-core count on big.LITTLE).
57
 
58
  ## Provenance
59
 
60
+ Base: nvidia/nemotron-3.5-asr-streaming-0.6b (NVIDIA Open Model License),
61
+ fine-tuned for zh-TW (see source model card), then exported with
62
+ `litert_torch` 0.9.1 + `ai_edge_quantizer` 0.7.0 (INT4 weights pre-baked to the
63
+ export grid before quantization).
config.json CHANGED
@@ -4,6 +4,7 @@
4
  ],
5
  "blank_token_id": 13087,
6
  "decoder_hidden_size": 640,
 
7
  "dtype": "float32",
8
  "durations": [],
9
  "encoder_config": {
@@ -15,6 +16,7 @@
15
  "default_num_lookahead_tokens": 3,
16
  "dropout": 0.1,
17
  "dropout_positions": 0.0,
 
18
  "hidden_act": "silu",
19
  "hidden_size": 1024,
20
  "initializer_range": 0.02,
@@ -48,7 +50,6 @@
48
  "num_prompts": 128,
49
  "pad_token_id": 0,
50
  "prompt_intermediate_size": 2048,
51
- "transformers_version": "5.13.0.dev0",
52
- "vocab_size": 13088,
53
- "default_prompt_id": 101
54
- }
 
4
  ],
5
  "blank_token_id": 13087,
6
  "decoder_hidden_size": 640,
7
+ "default_prompt_id": 101,
8
  "dtype": "float32",
9
  "durations": [],
10
  "encoder_config": {
 
16
  "default_num_lookahead_tokens": 3,
17
  "dropout": 0.1,
18
  "dropout_positions": 0.0,
19
+ "dtype": "float32",
20
  "hidden_act": "silu",
21
  "hidden_size": 1024,
22
  "initializer_range": 0.02,
 
50
  "num_prompts": 128,
51
  "pad_token_id": 0,
52
  "prompt_intermediate_size": 2048,
53
+ "transformers_version": "5.14.1",
54
+ "vocab_size": 13088
55
+ }
 
nemotron_decoder_fp16.tflite CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:93a3b8d91ab604305cb5c3014c4fb389cfd7b6a7397dc2e6e22df459f3f8859f
3
  size 30733936
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e92dfa900ebd9d7cd87429c9bb7c304b7e3fa61dc233c74f2e074fbb4342222b
3
  size 30733936
nemotron_encoder_q4.tflite CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:9e817d29ab20013de9962a8c347e7f68f9a896eef1e29ffcf9b0e0a0f1ef691c
3
  size 596222224
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b1b3c93add91ee2253c8d6d24172614a83f6572720dea0150fb34285be53a0c2
3
  size 596222224
nemotron_joint_fp16.tflite CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:8e5f46279a288ff5c0ce11f581fcd3753308c2151559046c90ca62aa632d48f2
3
  size 18121056
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d728fb09aa034b85b1549772fef6cfc4f85d7df0faf59c6db4ad2e7fbbfdc848
3
  size 18121056
nemotron_prompt_fuse_fp32.tflite CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:b4dcdc802c4124b0b0b0ff5b56344705f9b15f10c9f4983aa3503176b2e9e9b9
3
  size 17841444
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:21c59326f8633c3824f9e92dcaded6148978dcd53591846c85c9b1ac982a1bba
3
  size 17841444