Hugging Face releases AnySpeechRecognizer and AnyDecisionModel for on-device Apple AI
Hugging Face's new Swift packages let developers swap Apple's proprietary speech-to-text engine for open models like NVIDIA Parakeet and Qwen3-ASR running locally via Core ML, with speaker diarization and deterministic decision APIs.
Summary
Hugging Face has released two new Swift packages that extend its AnyLanguageModel approach to speech recognition and decision-making on Apple platforms. AnySpeechRecognizer wraps Apple's SpeechAnalyzer API while allowing developers to substitute open-weight models including NVIDIA's Parakeet variants and Alibaba's Qwen3-ASR, all converted to Core ML and downloadable from the Hugging Face Hub. The package adds speaker diarization through NVIDIA's Streaming Sortformer, a capability absent from Apple's native framework. AnyDecisionModel provides typed yes/no, multiple-choice, and rating-scale answers derived directly from model probabilities rather than text generation, supporting MLX, Core AI, llama.cpp, and hosted services like Jev and Ollama.
Both packages maintain familiar Swift APIs that mirror Apple's frameworks, requiring only import changes for basic adoption. The Core ML conversions are published with source checkpoints, checksums, and conversion workflows, with models ranging from approximately 250 MB for diarization to 2.4 GB for the largest Qwen3-ASR variant. Files are cached in the standard Hugging Face cache directory, enabling sharing between Mac apps and Python tooling.
Architecture and model runtime details
- Speech engine abstraction: AnySpeechRecognizer mirrors Apple's SpeechAnalyzer, SpeechTranscriber, DictationTranscriber, SpeechDetector, and AssetInventory types, with Apple's Speech framework as the default engine and alternative engines selectable via model configuration at transcriber initialization.
- Core ML runtime for Parakeet: The package includes its own Core ML runtime for Parakeet variants supporting file and live input, volatile results, word timing, and word confidence; Parakeet repositories include an 8-second encoder for live input that reduces analysis time by roughly one-third at the cost of higher word error rate.
- Qwen3-ASR GPU execution: Qwen3-ASR runs on GPU rather than the Core ML runtime, produces one final result per 40-second segment without volatile results or word-level timing/confidence, and covers 30 languages plus 22 Chinese dialects including Cantonese and Japanese that Parakeet lacks.
- Speaker diarization extension: SpeakerDiarizer adds Streaming Sortformer on Core ML alongside any transcriber, operating on the same timeline; Apple's native Speech framework provides no equivalent module.
- Decision model probability extraction: AnyDecisionModel derives answers from raw model probabilities rather than generated text, yielding typed results with probability scores across yes/no, multiple-choice, and rating-scale question formats.
Why it matters
These packages reduce dependency on Apple's proprietary speech stack while preserving API familiarity, giving iOS and macOS developers a migration path toward auditable, locally-run open models. The Core ML conversions and published conversion workflows also lower barriers for researchers and independent developers to port additional Hugging Face models to Apple silicon without vendor lock-in, though the ecosystem remains Apple-platform-specific rather than cross-platform.
Original reference: huggingface.co →