Noisy channel model
The noisy channel model is a framework used in spell checkers, question answering, speech recognition, and machine translation. In this model, the goal is to find the intended word given a word where the letters have been scrambled in some manner.
In spell-checking
See Chapter B of.[1]
Given an alphabet [math]\displaystyle{ \Sigma }[/math], let [math]\displaystyle{ \Sigma^* }[/math] be the set of all finite strings over [math]\displaystyle{ \Sigma }[/math]. Let the dictionary [math]\displaystyle{ D }[/math] of valid words be some subset of [math]\displaystyle{ \Sigma^* }[/math], i.e., [math]\displaystyle{ D\subseteq\Sigma^* }[/math].
The noisy channel is the matrix
- [math]\displaystyle{ \Gamma_{ws} = \Pr(s|w) }[/math],
where [math]\displaystyle{ w\in D }[/math] is the intended word and [math]\displaystyle{ s\in\Sigma^* }[/math] is the scrambled word that was actually received.
The goal of the noisy channel model is to find the intended word given the scrambled word that was received. The decision function [math]\displaystyle{ \sigma : \Sigma^* \to D }[/math] is a function that, given a scrambled word, returns the intended word.
Methods of constructing a decision function include the maximum likelihood rule, the maximum a posteriori rule, and the minimum distance rule.
In some cases, it may be better to accept the scrambled word as the intended word rather than attempt to find an intended word in the dictionary. For example, the word schönfinkeling may not be in the dictionary, but might in fact be the intended word.
Example
Consider the English alphabet [math]\displaystyle{ \Sigma = \{a, b, c, ..., y, z, A, B, ..., Z, ...\} }[/math]. Some subset [math]\displaystyle{ D\subseteq\Sigma^* }[/math] makes up the dictionary of valid English words.
There are several mistakes that may occur while typing, including:
- Missing letters, e.g., leter instead of letter
- Accidental letter additions, e.g., misstake instead of mistake
- Swapping letters, e.g., recieved instead of received
- Replacing letters, e.g., fimite instead of finite
To construct the noisy channel matrix [math]\displaystyle{ \Gamma }[/math], we must consider the probability of each mistake, given the intended word ([math]\displaystyle{ \Pr(s|w) }[/math] for all [math]\displaystyle{ w\in D }[/math] and [math]\displaystyle{ s\in\Sigma^* }[/math]). These probabilities may be gathered, for example, by considering the Damerau–Levenshtein distance between [math]\displaystyle{ s }[/math] and [math]\displaystyle{ w }[/math] or by comparing the draft of an essay with one that has been manually edited for spelling.
In machine translation
One naturally wonders if the problem of translation could conceivably be treated as a problem in cryptography. When I look at an article in Russian, I say: 'This is really written in English, but it has been coded in some strange symbols. I will now proceed to decode.
See chapter 1, and chapter 25 of.[2]
Suppose we want to translate a foreign language to English, we could model [math]\displaystyle{ P(E|F) }[/math] directly: the probability that we have English sentence E given foreign sentence F, then we pick the most likely one [math]\displaystyle{ \hat E = \arg\max_E P(E|F) }[/math]. However, by Bayes law, we have the equivalent equation:[math]\displaystyle{ \hat{E}=\underset{E \in \text { English }}{\operatorname{argmax}} \overbrace{P(F \mid E)}^{\text {translation model }} \overbrace{P(E)}^{\text {language model}} }[/math]The benefit of the noisy-channel model is in terms of data: If collecting a parallel corpus is costly, then we would have only a small parallel corpus, so we can only train a moderately good English-to-foreign translation model, and a moderately good foreign-to-English translation model. However, we can collect a large corpus in the foreign language only, and a large corpus in the English language only, to train two good language models. Combining these four models, we immediately get a good English-to-foreign translator and a good foreign-to-English translator.[3]
The cost of noisy-channel model is that using Bayesian inference is more costly than using a translation model directly. Instead of reading out the most likely translation by [math]\displaystyle{ \arg\max_E P(E|F) }[/math], it would have to read out predictions by both the translation model and the language model, multiply them, and search for the highest number.
In speech recognition
Speech recognition can be thought of as translating from a sound-language to a text-language. Consequently, we have[math]\displaystyle{ \hat{T}=\underset{T \in \text { Text }}{\operatorname{argmax}} \overbrace{P(S \mid T)}^{\text {speech model }} \overbrace{P(T)}^{\text {language model}} }[/math]where [math]\displaystyle{ P(S|T) }[/math] is the probability that a speech sound S is produced if the speaker is intending to say text T. Intuitively, this equation states that the most likely text is a text that's both a likely text in the language, and produces the speech sound with high probability.
The utility of the noisy-channel model is not in capacity. Theoretically, any noisy-channel model can be replicated by a direct [math]\displaystyle{ P(T|S) }[/math] model. However, the noisy-channel model factors the model into two parts which are appropriate for the situation, and consequently it is generally more well-behaved.
When a human speaks, it does not produce the sound directly, but first produces the text it wants to speak in the language centers of the brain, then the text is translated into sound by the motor cortex, vocal cords, and other parts of the body. The noisy-channel model matches this model of the human, and so it is appropriate. This is justified in the practical success of noisy-channel model in speech recognition.
Example
Consider the sound-language sentence (written in IPA for English) S = aɪ wʊd laɪk wʌn tuː. There are three possible texts [math]\displaystyle{ T_1, T_2, T_3 }[/math]:
- [math]\displaystyle{ T_1 = }[/math] I would like one to.
- [math]\displaystyle{ T_2 = }[/math] I would like one too.
- [math]\displaystyle{ T_3 = }[/math] I would like one two.
that are equally likely, in the sense that [math]\displaystyle{ P(S|T_1) = P(S|T_2) = P(S|T_3) }[/math]. With a good English language model, we would have [math]\displaystyle{ P(T_2) \gt P(T_1) \gt P(T_3) }[/math], since the second sentence is grammatical, the first is not quite, but close to a grammatical one (such as "I would like one to [go]."), while the third one is far from grammatical.
Consequently, the noisy-channel model would output [math]\displaystyle{ T_2 }[/math] as the best transcription.
See also
References
- ↑ Speech and Language Processing. Daniel Jurafsky & James H. Martin. Copyright © 2023. All rights reserved. Draft of January 7, 2023. https://web.stanford.edu/~jurafsky/slp3/B.pdf
- ↑ Jurafsky, Dan (2009). Speech and language processing: an introduction to natural language processing, computational linguistics, and speech recognition. James H. Martin (2nd ed.). Upper Saddle River, N.J.. ISBN 978-0-13-187321-6. OCLC 213375806. https://www.worldcat.org/oclc/213375806.
- ↑ Brown, Peter F.; Della Pietra, Stephen A.; Della Pietra, Vincent J.; Mercer, Robert L. (1993). Hirschberg, Julia. ed. "The Mathematics of Statistical Machine Translation: Parameter Estimation". Computational Linguistics 19 (2): 263–311. https://aclanthology.org/J93-2003.
- Brill, Eric; Moore, Robert C. (Jan 2000). "An Improved Error Model for Noisy Channel Spelling Correction". Proceedings of ACL 2000: 286–293. doi:10.3115/1075218.1075255. http://www.aclweb.org/anthology/P00-1037.
Original source: https://en.wikipedia.org/wiki/Noisy channel model.
Read more |