OHF-Voice/speech-to-phrase
Fast and personalized local speech-to-text
What it solves
Speech-to-phrase provides a fast, local speech-to-text system specifically designed for Home Assistant. Unlike general-purpose speech recognition, it focuses on identifying which specific known phrase was spoken rather than transcribing arbitrary speech, making it highly efficient for controlling smart home devices.
How it works
The system combines pre-defined sentence templates with the names of entities, areas, and floors from a Home Assistant instance to create a compact representation of all possible recognizable sentences. It uses techniques from the Rhasspy project to convert these templates into a finite state transducer (FST), which is then used to train a language model for Kaldi. To handle unknown words and device names, it automatically splits numbers and initialisms, converts digits to spoken words, and uses a Phonetisaurus model to guess pronunciations. A "fuzzy" layer is added to the final transcription to correct minor errors and ensure the output matches Home Assistant names exactly.
Who it’s for
Home Assistant users who want a fast, local, and personalized voice control system that accurately recognizes their specific device and area names across multiple supported languages.
Highlights
- Local Processing: Operates locally for privacy and speed.
- Personalized: Automatically integrates with Home Assistant device and area names.
- Multi-language Support: Supports over 20 languages, including English, French, German, Spanish, and others.
- Customizable: Allows users to add their own custom sentences and list values via YAML files.
- Robust Recognition: Uses a fuzzy layer to correct transcription errors and ensure exact name matching.