Japanese speech recognition for Apple Silicon, converted from Haas-ja-v1.0 by Third Intelligence.
This bundle contains the FastConformer encoder, the Kimi Delta Attention prediction network and TDT joint network, and the tokenizer and preprocessing assets needed for local inference. The models use the original checkpoint weights without additional training.
| Property | Value |
|---|---|
| Language | Japanese |
| Architecture | FastConformer encoder, KDA prediction network, TDT joint network |
| Input audio | Mono 16 kHz float32 PCM |
| Audio per inference call | 0.64–30.72 seconds |
| Encoder | INT8 weights with FP16 compute (recommended), or FP16 weights and compute |
| Prediction and joint network | FP32 ML Program |
| Tokenizer | SentencePiece BPE, 3,072 tokens, byte fallback |
| Deployment target | macOS 14 or later |
| Source revision | 660728d39019e5e065046154beca44ac9a66a540 |
Inference runs locally after downloading the bundle. Longer recordings should be segmented into utterances before being passed to the example below.
The Python example runs on macOS with Apple Silicon. It loads the compiled models, preprocesses audio, performs greedy TDT decoding, and prints a JSON transcript.
Download the model bundle with the Hugging Face CLI:
hf download ooookao/haas-ja-v1.0-coreml \
--local-dir ./haas-ja-v1.0-coreml \
--include "encoder-int8.mlmodelc/*" "predictor.mlmodelc/*" "assets/*" \
tokenizer.model config.json infer.py requirements.txt SHA256SUMS-int8 \
README.md LICENSE NOTICE
Create an environment and install the example dependencies:
python3.12 -m venv .venv
.venv/bin/pip install -r haas-ja-v1.0-coreml/requirements.txt
Transcribe a mono 16 kHz WAV file:
.venv/bin/python haas-ja-v1.0-coreml/infer.py speech.wav --model-dir ./haas-ja-v1.0-coreml
The example uses the INT8 encoder and the shared FP32 predictor. The INT8 encoder uses symmetric per-channel weight quantization; its floating-point compute and tensor interface are unchanged.
To use the FP16 encoder, download it and select it explicitly:
hf download ooookao/haas-ja-v1.0-coreml \
--local-dir ./haas-ja-v1.0-coreml --include "encoder.mlmodelc/*"
.venv/bin/python haas-ja-v1.0-coreml/infer.py speech.wav \
--model-dir ./haas-ja-v1.0-coreml --encoder encoder.mlmodelc
Applications can also load the Core ML models directly. The tensor contract is recorded in config.json.
| Path | Contents |
|---|---|
encoder-int8.mlmodelc/ |
Compiled INT8-weight encoder with FP16 compute; recommended |
encoder-int8-1500.mlmodelc/ |
INT8-weight encoder for up to 1,500 mel frames (15 seconds) |
encoder-int8-3072.mlmodelc/ |
INT8-weight encoder for up to 3,072 mel frames (30.72 seconds) |
assets-1500/, assets-3072/ |
Runtime assets for each matching encoder |
encoder.mlmodelc/ |
Compiled FP16 encoder |
predictor.mlmodelc/ |
Compiled FP32 KDA prediction and joint network |
mlpackages/ |
Editable Core ML model packages |
assets/ |
Window, mel filterbank, embeddings, tokenizer JSON, and preprocessing metadata |
tokenizer.model |
Original SentencePiece tokenizer |
config.json |
Source revision, conversion precision, tensor shapes and decoding parameters |
infer.py |
WAV-to-text inference example |
requirements.txt |
Dependencies for the Python example |
SHA256SUMS-int8 |
Checksums for the recommended INT8 runtime download |
SHA256SUMS |
Checksums for the complete repository download |
To check the downloaded files, run this from the bundle directory:
shasum -a 256 -c SHA256SUMS-int8
The encoders accept float32 features of shape [1, 128, 1500] or [1, 128, 3072] and int32 length of shape [1]. Pair the encoder with the corresponding assets directory and the shared predictor.mlmodelc/. Normalize over the true input length, then zero-pad to the encoder's frame count. length is the number of valid mel frames before padding. The Python example uses the 3,072-frame variant.
The predictor accepts the previous token embedding x: [1, 640], one encoder frame encoder: [1, 1024], memory: [2, 1, 5, 64, 64], and conv: [2, 3, 1, 320, 3], all in float32. Its output contains 3,073 token logits followed by five duration logits for durations 0–4.
Initialize the KDA memory and convolution states to zero for each independent utterance and start with blank token ID 3,072. Keep the previous states on blank emissions; accept next_state and next_conv only after a nonblank token. The example implements the complete preprocessing and decoding sequence.
The encoder was exported from the original BF16 checkpoint through a float32 NeMo encoder to an FP16 ML Program. The KDA prediction and joint graph uses float32. The conversion used coremltools 9.0, PyTorch 2.9.1, and NeMo 2.7.3. The model packages are included for integration with Core ML tooling.
The original Haas-ja-v1.0 model was developed by Third Intelligence and released under Apache 2.0. This conversion is distributed under the same license. See LICENSE and NOTICE.
有文件?提交种子。
提交种子encoder.mlmodelc/weights/weight.bin 1.2 GBmlpackages/encoder.mlpackage/Data/com.apple.CoreML/weights/weight.bin 1.2 GBencoder-int8-3072.mlmodelc/weights/weight.bin 604 MBencoder-int8.mlmodelc/weights/weight.bin 604 MBmlpackages/encoder-int8.mlpackage/Data/com.apple.CoreML/weights/weight.bin 604 MBencoder-int8-1500.mlmodelc/weights/weight.bin 594 MBmlpackages/predictor.mlpackage/Data/com.apple.CoreML/weights/weight.bin 20 MBpredictor.mlmodelc/weights/weight.bin 20 MBpredictor.mlmodelc/coremldata.bin 0.5 kBencoder-int8-1500.mlmodelc/coremldata.bin 0.4 kBencoder-int8-3072.mlmodelc/coremldata.bin 0.4 kBencoder-int8.mlmodelc/coremldata.bin 0.4 kBencoder.mlmodelc/coremldata.bin 0.4 kBencoder-int8-1500.mlmodelc/analytics/coremldata.bin 0.2 kBencoder-int8-3072.mlmodelc/analytics/coremldata.bin 0.2 kBencoder-int8.mlmodelc/analytics/coremldata.bin 0.2 kBencoder.mlmodelc/analytics/coremldata.bin 0.2 kBpredictor.mlmodelc/analytics/coremldata.bin 0.2 kB