Introduction
Automatic Speech Recognition (ASR) systems typically rely on a two-stage process: an acoustic model generates a set of candidate transcriptions (an N-best list), and a Language Model (LM) rescores these candidates to identify the most linguistically probable sentence. Traditionally, LMs have been unidirectional, predicting words based solely on preceding context. This paper introduces the biSANLM (Bidirectional Self-Attention Network Language Model), a Transformer-based approach that leverages both past and future context to significantly improve ASR accuracy.
Methodology: The biSANLM Architecture
The core innovation of this work lies in the application of a bidirectional architecture to the task of sentence scoring. Unlike previous bidirectional models that often failed to effectively integrate information from both directions, the biSANLM utilizes deep self-attention layers to fuse context from both the "past" and the "future."
The Masking Scoring Strategy
To calculate a sentence score, the researchers employ a "Masked Language Modeling" (MLM) approach. For a sentence of length $N$, the model performs $N$ separate inference passes. In each pass, a single word is replaced with a special mask token <M>. The model then predicts the original word based on the surrounding context.
The final score for a sentence is the sum of the log-likelihoods of the correct words at each masked position. This allows the model to capture complex linguistic dependencies that unidirectional models might miss, as it is forced to learn linguistic structure rather than just copying nearby words.
Experimental Results
The proposed method was evaluated on the LibriSpeech ASR corpus, a standard benchmark of 1,000 hours of read English speech. The biSANLM was compared against a baseline acoustic model and a standard unidirectional SANLM (uniLM) across various vocabulary sizes.
| Model | Test-Clean WER | Test-Other WER |
|---|---|---|
| Baseline (No LM) | 7.26 | 20.37 |
| + uniSANLM (40k) | 6.11 | 18.13 |
| + biSANLM (40k) | 5.65 | 17.44 |
The biSANLM achieved a 22.2% relative improvement in Word Error Rate (WER) over the baseline on the test-clean set, significantly outperforming the unidirectional model's 16.3% improvement.
Key Insights: Context Fusion and Positional Robustness
A significant advantage of the bidirectional approach is its performance at the beginning of sentences. Unidirectional models often struggle with the initial words of a sequence because they lack prior context. By looking "ahead" to the rest of the sentence, the biSANLM effectively resolves this "Beginning of Sentence" problem.
As shown in the figure above, the error count for the biSANLM is consistently lower, particularly in the early word positions (1-10), where the gap between the bidirectional and unidirectional models is most pronounced. This robustness makes the model particularly effective for short sentences or instances where early errors might otherwise cascade.
Conclusion and Future Work
While the biSANLM provides substantial accuracy gains, it introduces a computational bottleneck. Because scoring requires $N$ passes per sentence (where $N$ is the number of words), it is significantly slower than single-pass unidirectional models. Future research will focus on optimizing this inference process to make bidirectional rescoring more viable for real-time ASR applications.
Summary updated