lfm3-audio-2b-coreai

0 downloads 0 likes on Hugging Face updated

Model card

LFM3-Audio-2B language model for Core AI

The language model of LiquidAI/LFM3-Audio-2B as a Core AI bundle (.aimodel, macOS 27 / iOS 27) for FluidAudio's LFM3AudioManager with backend: .coreAI. The audio encoder, depth decoder and codec come from FluidInference/lfm3-audio-2b-coreml and stay on Core ML (the codec and the LiveASR encoder run on the Neural Engine there).

This is a modified version of the original model: the backbone was exported to Core AI and quantized (see below).

Files

File What
coreai/LFM3-Audio-u8b32-f16L20-23.aimodel LFM3 backbone (2048 x 24) taking inputs_embeds; entrypoints prefill (state update), main (logits of the last row), hidden (final-norm hidden of the last row, for speech frames); states keyCache / valueCache / convStates. 2.16 GB

Quantization: asymmetric uint8 weights with block size 32, decoder layers 20-23 kept in fp16. Plain int8 (per channel or per block) is fine for ASR but flips too many speech codes in TTS; the last layers carry most of that error.

Use (Swift)

import FluidAudio

let manager = try await LFM3AudioManager.downloadAndLoad(backend: .coreAI)  // macOS 27 / iOS 27
let text = try await manager.transcribe(samples).text
let speech = try await manager.synthesize("Hello from Core AI.")

FluidAudio loads one AIModel per entrypoint, all bound to the same host-owned states: with a single shared AIModel, macOS 27.0 aborts in GPUMemrefOps ("Failed to resolve dynamic dimensions for memref.alloc") when one function runs twice at consecutive positions with the same row count and another function is then called with the next shape (the first main after speech frames in TTS). The first load specializes the graph for the GPU and caches it (~3.3 GB under ~/Library/Caches/coreai-cache).

Parity (vs the original fp32 model)

Check Result
ASR, 20 golden LibriSpeech clips (greedy) 18/20 token-identical (2 differ by a comma), WER 1.46% = original
TTS, 319 teacher-forced speech frames LM hidden cosine min 0.99988 / mean 0.999985; depth-decoder codes 98.35% identical

Speed and accuracy

Apple M5 Pro (24 GB), macOS 27.0, FluidAudio release build; wall time includes warm-up after load.

Task Data Result
Offline ASR LibriSpeech test-clean, first 100 utterances (901 s) WER 1.32%, RTFx 24.6 (Core ML LM: 18.4); 98/100 transcripts identical to the original model
LiveASR (160 ms pieces) LibriSpeech test-clean, first 20 utterances WER 1.46%, RTFx 13.3 (Core ML LM: 10.4)
TTS 20 phrases (71 s of speech) RTFx 4.28, first audio 37 ms (median), Parakeet round-trip WER 2.5%

ASR peak memory footprint: 1.9 GB. TTS is bound by the LM step (fp16 last layers); the Core ML LM is slightly faster there (RTFx 4.48).

License

LFM Open License v1.0 (Liquid AI). Commercial use by organizations with annual revenue of USD 10 million or more requires a separate license from Liquid AI; see the license for the full terms.

Changelog

Date Files Change Issue FluidAudio PR HF commit
2026-10-29 all Initial release: Core AI LM bundle (uint8 b32, layers 20-23 fp16) FluidAudio #49 TBD this commit