Answers.Body: <p>The simple language model will give you the probability of a sequence of tokens(sentence) for that language. So lets say if you have trained a model for English language your model can give you the probability for any random english sentence.</p>
  <p>Consider some sentence</p>
  <p><span class="math-container">$X$</span> <span class="math-container">$=$</span> &quot;the quick brown fox jumps over the lazy dog&quot; <span class="math-container">$=$</span>  <span class="math-container">$x_1 \ x_2 \ x_3 \ ... \ x_n$</span></p>
  <p>model will give you <span class="math-container">$P(X)$</span></p>
  <p>Moreover if the model has been trained properly, in the following scenario, where</p>
  <p><span class="math-container">$X$</span> <span class="math-container">$=$</span> &quot;the quick brown fox jumps over the lazy dog&quot; <span class="math-container">$=$</span>  <span class="math-container">$x_1 \ x_2 \ x_3 \ ... \ x_n$</span></p>
  <p><span class="math-container">$Y$</span> <span class="math-container">$=$</span> &quot;dog brown quick fox over the jumps lazy the&quot; <span class="math-container">$=$</span>  <span class="math-container">$y_1 \ y_2 \ y_3 \ ... \ y_m$</span></p>
  <p>model will always give <span class="math-container">$P(X) &gt; P(Y)$</span>, as it has learnt the structure of language.</p>
  <p>On the other hand Machine translation model gives you the conditional probability of the next token given your source sentence and partial-target sentence.
  So if</p>
  <p><span class="math-container">$X = $</span> &quot;I am a student&quot; and <span class="math-container">$Y = $</span> &quot;je suis&quot; <span class="math-container">$=y_1, \ y_2$</span></p>
  <p>model will give you <span class="math-container">$P(y_3 | X,y1_,y_2)$</span> .</p>
  <p>where <span class="math-container">$X$</span> is a source sentence and <span class="math-container">$Y= y_1, y_2$</span> is a partial target sentence. The probability of word/token &quot;étudiant&quot; would be maximum among all words of vocabulary.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-06-23T11:47:57.540Z
Answers.LastActivityDate: 2020-06-23T11:47:57.540Z
Answers.UserDisplayName: Jayendra Parmar
Body: <p>What are the main differences between a language model and a machine translation model?</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-06-22T23:00:06.997Z
Comments.Text: cf. [_Deep Learning_](https://www.deeplearningbook.org/) "[12.4 Natural Language Processing](https://www.deeplearningbook.org/contents/applications.html#pf13)", "[12.4.2 Neural Language Models](https://www.deeplearningbook.org/contents/applications.html#pf15)", and _passim_.
Comments.UserDisplayName: Geremia
Tags: <natural-language-processing><comparison><models><machine-translation><language-model>
Title: What are the main differences between a language model and a machine translation model?
UserDisplayName: DRV
ThreadText: # What are the main differences between a language model and a machine translation model?
  
  (Asked by: username_0 on 2020-06-23)
  
  What are the main differences between a language model and a machine translation model?
  
  **Tags:** natural-language-processing, comparison, models, machine-translation, language-model
  
  > **Comments:**
  > **username_1**: cf. [_Deep Learning_](https://www.deeplearningbook.org/) "[12.4 Natural Language Processing](https://www.deeplearningbook.org/contents/applications.html#pf13)", "[12.4.2 Neural Language Models](https://www.deeplearningbook.org/contents/applications.html#pf15)", and _passim_.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_2 on 2020-06-23. Score: 3
  
  The simple language model will give you the probability of a sequence of tokens(sentence) for that language. So lets say if you have trained a model for English language your model can give you the probability for any random english sentence.
  
  Consider some sentence
  
  $X$ $=$ "the quick brown fox jumps over the lazy dog" $=$ $x\_1 \ x\_2 \ x\_3 \ ... \ x\_n$
  
  model will give you $P(X)$
  
  Moreover if the model has been trained properly, in the following scenario, where
  
  $X$ $=$ "the quick brown fox jumps over the lazy dog" $=$ $x\_1 \ x\_2 \ x\_3 \ ... \ x\_n$
  
  $Y$ $=$ "dog brown quick fox over the jumps lazy the" $=$ $y\_1 \ y\_2 \ y\_3 \ ... \ y\_m$
  
  model will always give $P(X) > P(Y)$, as it has learnt the structure of language.
  
  On the other hand Machine translation model gives you the conditional probability of the next token given your source sentence and partial-target sentence.
  So if
  
  $X = $ "I am a student" and $Y = $ "je suis" $=y\_1, \ y\_2$
  
  model will give you $P(y\_3 | X,y1\_,y\_2)$ .
  
  where $X$ is a source sentence and $Y= y\_1, y\_2$ is a partial target sentence. The probability of word/token "étudiant" would be maximum among all words of vocabulary.
  
  
  ---
  
  