Abstract
Accurate recognition of slot values such as domain specific words or named entities by automatic speech recognition (ASR) systems forms the core of the Goal-oriented Dialogue Systems. Although it is a critical step with direct impact on downstream tasks such as language understanding, many domain agnostic ASR systems tend to perform poorly on domain specific or long tail words. They are often supplemented with slot error correcting systems but it is often hard for any neural model to directly output such rare entity words. To address this problem, we propose k-nearest neighbor (k-NN) search that outputs domain-specific entities from an explicit datastore. We improve error correction rate by conveniently augmenting a pretrained joint phoneme and text based transformer sequence to sequence model with k-NN search during inference. We evaluate our proposed approach on five different domains containing long tail slot entities such as full names, airports, street names, cities, states. Our best performing error correction model shows a relative improvement of 7.4% in word error rate (WER) on rare word entities over the baseline and also achieves a relative WER improvement of 9.8% on an out of vocabulary (OOV) test set.
Introduction
Automatic Speech Recognition (ASR) systems are remarkably good at general conversation but often stumble on "long-tail" entities—specific names, niche businesses, or technical terms that don't appear frequently in training data. When an ASR system mishears a "slot" (a key piece of information like a city or name), it can cause a total failure in downstream tasks, such as a digital assistant failing to book a flight or navigate to the correct address.
While error correction models exist to act as post-transcription spell-checkers, they are typically based on neural networks that struggle to generate words they haven't seen many times. This work addresses the difficulty neural models have in predicting rare tokens by shifting the strategy toward retrieving them from an explicit memory.
Methods: The $k$-PAT Architecture
The proposed system, $k$-PAT ($k$-nearest neighbors based Phone Augmented Transformer), augments a standard Transformer model with a $k$-nearest neighbor ($k$-NN) retrieval mechanism.
The architecture consists of three primary components:
- The Base Model (PAT): A Transformer-based sequence-to-sequence model that processes both the incorrect ASR text and its corresponding phonetic sequence (phonemes). By integrating phonetic information, the model can better disambiguate similar-sounding errors.
- The $k$-NN Datastore: During a pre-inference step, training data is passed through the model to save the decoder’s internal representations (keys) alongside the actual target words (values) in an external datastore.
- Inference via Retrieval: During inference, the model queries the datastore for the $k$ most similar contexts. It then blends the probability distribution from the neural model with the distribution found in the datastore to produce the final output. A key innovation is the use of dot-product self-attention pooling to create effective search keys.
Experimental Setup
The approach was evaluated across five distinct domains containing "long-tail" entities:
- Synthetic Data: Generated using Text-to-Speech (TTS) for Airports, Cities, States, and Street names.
- Vendor-Collected Audio: Real-world recordings of common US first and last names.
- Out-of-Vocabulary (OOV) Set: A test set containing words never seen during the training of the base model.
Results and Discussion
The $k$-PAT model demonstrated significant improvements over the baseline PAT model across all tested domains.
Key findings include:
- Overall Accuracy: $k$-PAT achieved a 7.5% relative improvement in Word Error Rate (WER) on a combined dataset compared to the baseline PAT model.
- Rare Word Mastery: On low-frequency words (seen only 10 times in training), the model saw a 6 percentage point absolute gain in slot accuracy.
- Out-of-Vocabulary (OOV) Success: The model showed a 9.8% relative WER improvement on words it had never seen during training, simply by adding them to the datastore.
- Domain-Specific Adaptation: Using smaller, domain-specific "micro-datastores" (e.g., for airports) performed better than a single large datastore, allowing for on-the-fly specialization.
Conclusion
The $k$-NN approach allows ASR systems to "memorize" rare entities without the need for expensive retraining. By leveraging phonetic information and contextual retrieval, $k$-PAT significantly reduces errors on the long-tail of language. Future work will explore integrating this mechanism into end-to-end ASR models and investigating few-shot adaptation techniques.
Summary updated