Lecture 03 · N-grams

المحاضرة 03 · نماذج N-grams

Generalization and Zeros

التعميم والأصفار

Slides 53–59الشرائح 53–59 P3 SKIMP3 تصفّح سريع

Why bigger n looks better but memorizes more, why genre matters, and the zero to infinity chain that forces you to smooth.

لماذا تبدو قيم n الأكبر أفضل لكنها تحفظ أكثر، ولماذا يهم نوع النص (genre)، وسلسلة الصفر إلى اللانهاية التي تجبرك على smoothing.

Bigger n: more coherent, more memorized

قيمة n أكبر: تماسك أكثر وحفظ أكثر

Slide 53. There is a trade-off baked into the choice of n.

الشريحة 53. هناك مقايضة (trade-off) متأصلة في اختيار قيمة n.

The slide gives the reason in one line: because tables are sparse, there are few continuations after a long prefix. That sentence is the whole mechanism. Read it again.

تعطي الشريحة السبب في سطر واحد: because tables are sparse, there are few continuations after a long prefix، أي أن الجداول متفرقة فلا تبقى إلا استمرارات قليلة بعد prefix طويل. هذه الجملة هي كل الآلية، فاقرأها مرة أخرى.

Why a long prefix forces memorization

لماذا يفرض الـ prefix الطويل الحفظ

With a long context, almost every prefix you look up occurred only a handful of times in training. If the prefix It cannot be appeared six times and was followed by six different words, then your 4-gram "distribution" over the next word has exactly six options. You are not sampling from a model of English. You are sampling from a short list copied out of the corpus.

مع سياق طويل، كل prefix تبحث عنه تقريباً ظهر مرات قليلة جداً في التدريب. فإذا ظهر It cannot be ست مرات وتبعته ست كلمات مختلفة، فإن "distribution" نموذج 4-gram على الكلمة التالية فيه ستة خيارات بالضبط. أنت لا تسحب عينات من نموذج للإنجليزية، بل من قائمة قصيرة منسوخة من الـ corpus.

context length (n) unigram bigram trigram 4-gram fluency generality memorization zone
Slide 53. Fluency climbs with n because the context is more informative. Generality falls with n because each long prefix is backed by fewer and fewer training observations. The 4-gram region is where the model is quoting rather than generating.
الشريحة 53. ترتفع السلاسة (fluency) مع n لأن السياق يصبح أكثر إفادة. وتنخفض العمومية (generality) مع n لأن كل prefix طويل يستند إلى مشاهدات تدريب أقل فأقل. ومنطقة 4-gram هي حيث ينقل النموذج نصاً بدل أن يولّده.

يوضح الرسم مقايضة الشريحة 53: منحنى fluency يصعد مع كبر n لأن السياق يصبح أكثر إفادة، ومنحنى generality يهبط لأن كل prefix طويل يستند إلى مشاهدات تدريب أقل. والمنطقة المظللة على اليمين هي memorization zone عند 4-gram، حيث يصبح النموذج ينقل نصاً بدل أن يولّده.

Shakespeare: the sampling comparison

Shakespeare: مقارنة العينات

Slide 54 samples from unigram, bigram, trigram and 4-gram models all trained on Shakespeare's complete works.

تسحب الشريحة 54 عينات من نماذج unigram وbigram وtrigram و4-gram، كلها مُدرَّبة على أعمال Shakespeare الكاملة.

ModelالنموذجSampled outputالمخرج المُولَّدVerdictالحكم
1-gram To him swallowed confess hear both. Which. Of save on trail for are ay device and rote life have No syntax, no sentence-final punctuation, no relation between adjacent wordsلا نحو، ولا علامات ترقيم في نهاية الجمل، ولا علاقة بين الكلمات المتجاورة
2-gram What means, sir. I confess she? then all sorts, he is trim, captain. Local word-to-word coherence onlyتماسك محلي بين كل كلمة وجارتها فقط
3-gram This shall forbid it should be branded, if renown made it empty. Starting to look a lot like Shakespeareبدأ يشبه Shakespeare كثيراً
4-gram It cannot be but so. Too much like Shakespeare. This line is lifted directly from King Johnيشبه Shakespeare أكثر من اللازم. هذا السطر منقول مباشرة من King John

يعرض الجدول مخرجات العينات الأربع من الشريحة 54 مع الحكم على كل واحدة: 1-gram بلا نحو إطلاقاً، 2-gram تماسك بين الكلمة وجارتها فقط، 3-gram يشبه Shakespeare فعلاً، و4-gram يشبهه أكثر من اللازم لأن السطر "It cannot be but so." منقول حرفياً من King John. اقرأ الجدول من الأعلى إلى الأسفل كتدرج من العشوائية إلى النسخ.

Worked: why the 4-gram quotesمثال محلول: لماذا ينقل نموذج 4-gram حرفياً

Shakespeare's corpus: N = 884,647 tokens, V = 29,066 types.

corpus أعمال Shakespeare: N = 884,647 من الـ tokens، وV = 29,066 من الـ types.

possible bigrams   = V^2 = 29,066^2  = 844,832,356   (~844 million)
observed bigrams  <= N - 1          =     884,646   (at most)

fraction of the bigram table that is non-zero
  = 884,646 / 844,832,356
  = 0.00105
  = about 0.1 percent

possible 4-grams   = V^4            = about 7 x 10^17

يحسب الصندوق حجم جدول الـ bigrams الممكن V^2 وهو نحو 844 مليون، مقابل ما يمكن رصده فعلاً وهو N - 1 أي 884,646 على الأكثر، فتكون النسبة غير الصفرية 0.00105 أي نحو 0.1 بالمئة فقط. والسطر الأخير يبين أن جدول الـ 4-grams أكبر بكثير: V^4 أي نحو 7 x 10^17.

So 99.9 percent of the bigram table is already zero, and the 4-gram table is astronomically emptier. Once the generator has chosen the trigram It cannot be, the corpus offers only six possible continuations: but, I, that, thus, this, and the period. With six options, "generating" is indistinguishable from "recalling".

إذن 99.9 بالمئة من جدول الـ bigram أصفار أصلاً، وجدول الـ 4-gram أكثر خلواً بمراحل. وبعد أن يختار المولّد الـ trigram It cannot be، لا يعرض الـ corpus إلا ست استمرارات ممكنة: but, I, that, thus, this, والنقطة. وبستة خيارات فقط، لا فرق بين "التوليد" و"الاسترجاع".

Wall Street Journal: the same algorithm, a different world

Wall Street Journal: الخوارزمية نفسها في عالم مختلف

Slides 55 and 56. Now train on 40 million words of WSJ newswire and sample again.

الشرائح 55 و56. الآن درّب النموذج على 40 مليون كلمة من أخبار WSJ ثم اسحب عينات من جديد.

ModelالنموذجSampled outputالمخرج المُولَّد
1-gramMonths the my and issue of year foreign new exchange's september were recession exchange new endorsed a acquire to six executives
2-gramLast December through the way to preserve the Hudson corporation N. B. E. C. Taylor would seem to complete the major central planners one point five percent of U. S. E. has already old M. X. corporation of living on information such as more frequently fishing to keep her
3-gramThey also point to ninety nine point six billion dollars from two hundred four oh six three percent of the rates of interest stores as Mexico and Brazil on market conditions

يعرض الجدول عينات WSJ من الشرائح 55 و56 بالترتيب نفسه: 1-gram ركام من كلمات مالية، 2-gram عبارات سليمة محلياً وجملة بلا معنى، 3-gram يُقرأ كأنه خبر اقتصادي حقيقي. المهم ليس الجمل نفسها، بل أن المفردات كلها مالية، لأن النموذج لا يعرف غير corpus تدريبه.

The comparison that matters

المقارنة المهمة

DimensionالبُعدShakespeare LMنموذج ShakespeareWSJ LMنموذج WSJ
Vocabulary on displayالمفردات الظاهرةforsooth, canopy, renown, Exeuntrecession, corporation, percent, billion dollars
Registerالسجل اللغوي (register)Early Modern dramatic verseشعر مسرحي من الإنجليزية الحديثة المبكرةFinancial newswire proseنثر أخبار مالية
Corpus sizeحجم الـ corpus884,647 tokens, very sparse884,647 من الـ tokens، متفرق جداً40 million words, far denser40 مليون كلمة، أكثف بكثير
Overlap with the other corpusالتداخل مع الـ corpus الآخرNone in generated sentences, little even in short phrasesلا شيء في الجمل المولَّدة، وقليل حتى في العبارات القصيرةNone in generated sentences, little even in short phrasesلا شيء في الجمل المولَّدة، وقليل حتى في العبارات القصيرة
Usefulness on the other genreالفائدة على نوع النص الآخرEssentially nilمعدومة عملياًEssentially nilمعدومة عملياً

يقارن الجدول بين نموذج Shakespeare ونموذج WSJ في المفردات والسجل اللغوي (register) وحجم الـ corpus. والصفّان الأخيران هما الخلاصة: لا تداخل تقريباً بينهما، وفائدة كل نموذج على نوع النص الآخر تساوي صفراً عملياً.

Both models speak English. Neither can predict the other's text. That is the point of slide 56: an LM encodes the statistics of its training corpus, nothing more. A model trained on Shakespeare is a bad model for newswire and the reverse is equally true.

النموذجان يتحدثان الإنجليزية، ومع ذلك لا يستطيع أي منهما التنبؤ بنص الآخر. وهذا هو مقصد الشريحة 56: النموذج اللغوي يرمّز إحصاءات corpus تدريبه فقط، لا أكثر. فنموذج مُدرَّب على Shakespeare نموذج سيئ للأخبار، والعكس صحيح تماماً.

Memory hookمفتاح للحفظ

Train on the right genre. Legal translation needs legal documents. A question-answering system needs questions. And match more than topic: match domain, dialect, and style. Slide 56 names all three. Social media and spoken transcripts are the usual examples of dialect mismatch.

درّب على نوع النص الصحيح. الترجمة القانونية تحتاج وثائق قانونية، ونظام question-answering يحتاج أسئلة. ولا تطابق الموضوع فقط، بل طابق domain وdialect وstyle. الشريحة 56 تذكر الثلاثة. ووسائل التواصل والنصوص المنطوقة المحوّلة هي المثال المعتاد على عدم تطابق الـ dialect.

Unseen words versus unseen tokens

الكلمات غير المرئية مقابل الـ tokens غير المرئية

Slide 57. This is a short slide with a sharp distinction, and it is easy to misread.

الشريحة 57. شريحة قصيرة فيها تمييز حاد، ويسهل جداً أن تُقرأ خطأ.

Unseen word

كلمة غير مرئية (unseen word)

A word that never appeared in training and shows up in the test set. The classic example is a proper noun like Jurafsky. This is the out-of-vocabulary case.

كلمة لم تظهر في التدريب أبداً ثم تظهر في test set. والمثال الكلاسيكي اسم علم مثل Jurafsky. هذه هي حالة out-of-vocabulary.

Can still happen. No finite corpus contains every word.

قد يحدث فعلاً. لا يوجد corpus محدود يحتوي كل كلمات اللغة.

Unseen token

Token غير مرئي (unseen token)

A unit in the model's actual vocabulary that was never observed. Modern LMs run on subword or byte-level tokens, not words.

وحدة موجودة في vocabulary النموذج نفسه لكنها لم تُرصد أبداً. النماذج الحديثة تعمل على subword أو byte-level tokens، لا على كلمات كاملة.

Need not happen. With BPE or byte-level tokenization, any string decomposes into known pieces, down to single characters if necessary.

لا يلزم أن يحدث. مع BPE أو byte-level tokenization، أي نص يتفكك إلى أجزاء معروفة، وصولاً إلى الحروف المفردة إذا لزم الأمر.

The slide's conclusion, stated exactly: test sets need not contain unseen tokens, even when unseen words occur. Jurafsky is an unseen word, but it tokenizes into known subwords such as jur + af + sky, all of which the model has seen. So the vocabulary is closed at the token level even though it is open at the word level.

خلاصة الشريحة بنصها: ليس من الضروري أن تحتوي test sets على tokens لم تُرَ، حتى لو احتوت كلمات لم تُرَ. فكلمة Jurafsky كلمة غير مرئية في التدريب، لكنها تتفكك إلى subwords معروفة مثل jur + af + sky، وكلها رآها النموذج. إذن vocabulary مغلق على مستوى الـ token، ومفتوح على مستوى الكلمة.

Trapفخ

Do not conflate these two with the zero-probability problem. They are different failures.

لا تخلط بين هاتين الحالتين وzero-probability problem، فهما فشلان مختلفان.

Subword tokenization solves the first one. It does not solve the second one, and the second one is what smoothing exists for.

يحل subword tokenization المشكلة الأولى، لكنه لا يحل الثانية، والثانية هي سبب وجود smoothing أصلاً.

One note for completeness: older treatments handled unseen words by converting rare training words into a special <UNK> token and giving it a probability. This deck does not take that route. Slide 57 replaces <UNK> with subword tokenization. Know the term, but answer from the slide.

ملاحظة للإكمال: المعالجات القديمة كانت تحل مشكلة الكلمات غير المرئية بتحويل الكلمات النادرة في التدريب إلى token خاص هو <UNK> ثم إعطائه احتمالاً. هذه الشرائح لا تسلك هذا الطريق، فالشريحة 57 تستبدل <UNK> بـ subword tokenization. اعرف المصطلح، لكن أجب من الشريحة.

The zero-probability problem

مشكلة الاحتمال الصفري

Slide 58. This is the single most exam-relevant idea on the page because it is the motivation for everything that follows.

الشريحة 58. هذه أهم فكرة في الصفحة من ناحية الامتحان، لأنها الدافع لكل ما يأتي بعدها.

A finite training corpus is always missing perfectly acceptable English sequences. Those missing n-grams are called zeros: sequences that do not occur in the training set but do occur in the test set.

أي corpus تدريب محدود تغيب عنه دائماً تسلسلات إنجليزية مقبولة تماماً. وتسمى هذه الـ n-grams الغائبة zeros: تسلسلات لا تظهر في training set لكنها تظهر في test set.

C(ruby slippers) = 0 P(slippers|ruby) = 0 P(whole sentence) = 0 perplexity undefined MLE product 1 / 0 never seen 0 / C(ruby) one zero factor kills it cannot divide by zero
Slide 58. The chain you must be able to recite. Each arrow is forced by the step before it.
الشريحة 58. السلسلة التي يجب أن تستطيع سردها. كل سهم تفرضه الخطوة التي قبله.

يرسم المخطط سلسلة الشريحة 58: C(ruby slippers) = 0، ثم بـ MLE يصبح P(slippers|ruby) = 0، ثم حاصل الضرب يجعل احتمال الجملة كلها = 0، ثم 1 / 0 يجعل perplexity غير معرّفة. كل سهم مفروض بالخطوة التي قبله، فاحفظ السلسلة بهذا الترتيب.

The chain, in words

السلسلة بالكلمات

  1. Zero count. The bigram never occurred in training, so C(wn−1, wn) = 0.

    عدّ صفري. الـ bigram لم يظهر في التدريب، إذن C(wn−1, wn) = 0.

  2. Zero probability. MLE divides that count by C(wn−1). Zero over anything positive is zero.

    احتمال صفري. يقسم MLE ذلك العدّ على C(wn−1)، والصفر مقسوماً على أي عدد موجب يساوي صفراً.

  3. Zero sentence probability. Sentence probability is a product of the n-gram probabilities. One zero factor annihilates the entire product, no matter how well the rest of the sentence scored.

    احتمال جملة صفري. احتمال الجملة هو حاصل ضرب احتمالات الـ n-grams، وعامل واحد صفري يمحق الحاصل كله، مهما كانت بقية الجملة جيدة الدرجة.

  4. Undefined perplexity. Perplexity is built on the inverse probability of the test set. With P(W) = 0 you would compute 1/0, which is undefined. The model cannot be evaluated at all.

    perplexity غير معرّفة. الـ perplexity مبنية على مقلوب احتمال test set. ومع P(W) = 0 ستحسب 1/0 وهي غير معرّفة، فلا يمكن تقييم النموذج إطلاقاً.

Worked: one zero destroys a good sentenceمثال محلول: صفر واحد يدمّر جملة جيدة

Score <s> the ruby slippers shone </s> with a bigram model where every bigram is common except ruby slippers, which was never seen.

قيّم الجملة <s> the ruby slippers shone </s> بنموذج bigram كل أزواجه شائعة إلا ruby slippers الذي لم يُرَ أبداً.

P(the|<s>)        = 0.08
P(ruby|the)       = 0.0004
P(slippers|ruby)  = 0        <-- the only zero
P(shone|slippers) = 0.01
P(</s>|shone)     = 0.3

P(W) = 0.08 x 0.0004 x 0 x 0.01 x 0.3
     = 0

PP(W) = P(W)^(-1/5)
      = (0)^(-1/5)
      = 1 / (0)^(1/5)
      = 1 / 0        -> undefined

Drop the zero and the same sentence scores
  0.08 x 0.0004 x 0.01 x 0.3 = 9.6e-8   perfectly fine.

يحسب الصندوق احتمال الجملة: أربعة عوامل معقولة وعامل واحد صفري، فيصبح P(W) = 0، ومنه PP(W) = (0)^(-1/5) = 1 / 0 أي غير معرّفة. والسطران الأخيران يبينان أنه لو حُذف الصفر لكانت الجملة نفسها تساوي 9.6e-8، وهي قيمة سليمة تماماً.

Four of the five factors say this is a reasonable English sentence. The one missing bigram overrules all of them. That asymmetry is why you cannot just ignore zeros.

أربعة من العوامل الخمسة تقول إن هذه جملة إنجليزية معقولة، لكن الـ bigram الغائب الوحيد يبطل حكمها كلها. هذا اللاتناظر هو سبب استحالة تجاهل الـ zeros.

Trapفخ

Zeros are a problem for two separate reasons, and exams like the second one.

الـ zeros مشكلة لسببين منفصلين، والامتحانات تحب الثاني.

  1. You are underestimating the probability of sequences that genuinely can occur, which hurts whatever application sits on top of the LM.

    أنت تقلّل من احتمال تسلسلات يمكن أن تحدث فعلاً، وهذا يضر أي تطبيق مبني على النموذج اللغوي.

  2. You cannot compute perplexity at all, so you cannot even measure how bad the model is.

    أنت لا تستطيع حساب perplexity إطلاقاً، فلا تستطيع حتى قياس مدى سوء النموذج.

Also: a zero does not mean the sentence is ungrammatical. It only means your corpus happened not to contain that pair. Absence of evidence is being treated as evidence of impossibility, and that is the actual bug.

وأيضاً: الصفر لا يعني أن الجملة خاطئة نحوياً، بل يعني فقط أن corpus تدريبك لم يحتوِ ذلك الزوج. فغياب الدليل يُعامَل كدليل على الاستحالة، وهذا هو الخلل الحقيقي.

Memory hookمفتاح للحفظ

Zero count, zero probability, zero sentence, infinite perplexity. Four words, in that order. If you can say that sentence you have the whole motivation for smoothing.

عدّ صفري، احتمال صفري، جملة صفرية، perplexity لا نهائية. أربع خطوات بهذا الترتيب. إذا قدرت أن تقولها فأنت تملك كل دافع smoothing.

The fix, named

الحل، باسمه

Slide 58 ends by naming the solution: smoothing, also called discounting. Slide 59 gives the one-line idea.

تنتهي الشريحة 58 بتسمية الحل: smoothing، ويسمى أيضاً discounting. والشريحة 59 تعطي الفكرة في سطر واحد.

Smoothing, slide 59التنعيم (smoothing)، الشريحة 59

Shave a bit of probability mass off the frequent events and give it to the unseen events.

اقتطع جزءاً صغيراً من كتلة الاحتمال (probability mass) من الأحداث المتكررة، وأعطه للأحداث التي لم تُرَ.

You want non-zero probability for plausible unseen sequences such as ruby slippers. Many smoothing families exist. The next page does add-one and add-k, the two you are most likely to have to compute by hand.

أنت تريد احتمالاً غير صفري للتسلسلات المعقولة التي لم تُرَ، مثل ruby slippers. وهناك عائلات كثيرة من smoothing، والصفحة التالية تتناول add-one وadd-k، وهما الأرجح أن تحسبهما يدوياً في الامتحان.

zeros exist P = 0 product = 0 PP undefined smoothing

Check yourself

اختبر نفسك

A 4-gram model trained on Shakespeare generates "It cannot be but so.", a line taken directly from King John. What does this illustrate?

نموذج 4-gram مُدرَّب على Shakespeare يولّد "It cannot be but so."، وهو سطر منقول حرفياً من King John. على أي شيء يدل هذا؟

C. With V = 29,066 there are about 7 × 1017 possible 4-grams but only 884,647 tokens of training data, so almost every long prefix has a handful of observed continuations. After "It cannot be" the corpus offers six. A is the tempting one: the output reads better, but reading better by quoting is the opposite of generalizing.

الجواب C. مع V = 29,066 هناك نحو 7 × 1017 من الـ 4-grams الممكنة، مقابل 884,647 من الـ tokens في التدريب فقط، فكل prefix طويل تقريباً له استمرارات قليلة مرصودة، وبعد "It cannot be" لا يعرض الـ corpus إلا ستاً. والجواب A هو المُغري: الناتج يُقرأ أفضل، لكن القراءة الأفضل عن طريق النقل هي عكس التعميم تماماً.

Your training corpus contains both "ruby" and "slippers" but never the phrase "ruby slippers". In the test set the phrase appears. What kind of problem is this?

corpus تدريبك يحتوي "ruby" و"slippers" لكنه لا يحتوي العبارة "ruby slippers" أبداً، ثم تظهر العبارة في test set. ما نوع هذه المشكلة؟

B. Both words are in the vocabulary, so there is no OOV problem. The missing item is the pair, and C(ruby, slippers) = 0 makes P(slippers | ruby) = 0. A is the classic confusion: BPE fixes unseen words, not unseen combinations of seen words. D is wrong because bigram probability depends on the joint count, not on the two words existing separately.

الجواب B. الكلمتان كلتاهما في vocabulary، فلا توجد مشكلة OOV. الغائب هو الزوج، وC(ruby, slippers) = 0 يجعل P(slippers | ruby) = 0. والجواب A هو اللبس الكلاسيكي: BPE يحل الكلمات غير المرئية، لا التجاورات غير المرئية لكلمات مرئية. والجواب D خاطئ لأن احتمال bigram يعتمد على العدّ المشترك، لا على وجود الكلمتين كل واحدة على حدة.

A 20-word test sentence has 19 bigrams. Eighteen of them have high probability and one has probability 0. What is the sentence probability and the perplexity?

جملة اختبار من 20 كلمة فيها 19 من الـ bigrams: ثمانية عشر منها باحتمال عالٍ وواحد باحتمال 0. ما احتمال الجملة وما الـ perplexity؟

D. The sentence probability is a product, so a single zero factor makes the whole product 0 regardless of the other 18 terms. Perplexity is based on the inverse probability, so it requires dividing by 0 and is undefined. C is the common slip: zero probability gives you the worst possible model, which corresponds to unbounded perplexity, never zero perplexity.

الجواب D. احتمال الجملة حاصل ضرب، فعامل صفري واحد يجعل الحاصل كله 0 بغض النظر عن الحدود الثمانية عشر الأخرى. والـ perplexity مبنية على مقلوب الاحتمال، فتحتاج القسمة على 0 وتصبح غير معرّفة. والجواب C هو الزلة الشائعة: الاحتمال الصفري يعطيك أسوأ نموذج ممكن، وهذا يقابل perplexity غير محدودة، لا صفرية.

According to slide 57, why can a modern LM's test set avoid containing unseen tokens even though unseen words still occur?

حسب الشريحة 57، لماذا يستطيع test set لنموذج حديث أن يخلو من tokens لم تُرَ، مع أن كلمات لم تُرَ ما زالت تظهر فيه؟

A. With BPE or byte-level tokenization any string decomposes into known pieces, falling back to individual characters or bytes in the worst case, so the token vocabulary is closed. D is the tempting answer because smoothing also deals with unseen things, but smoothing addresses zero n-gram counts, not the vocabulary itself.

الجواب A. مع BPE أو byte-level tokenization يتفكك أي نص إلى أجزاء معروفة، ويرتد إلى الحروف أو الـ bytes المفردة في أسوأ الحالات، فيكون vocabulary الـ tokens مغلقاً. والجواب D مُغرٍ لأن smoothing يتعامل أيضاً مع ما لم يُرَ، لكنه يعالج أصفار عدّ الـ n-gram، لا الـ vocabulary نفسه.

Slide 56 says to train on the right genre. What exactly should you match between training data and task?

تقول الشريحة 56 إن عليك التدريب على نوع النص الصحيح. فما الذي يجب أن تطابقه بالضبط بين بيانات التدريب والمهمة؟

B. The slide names all three. The WSJ comparison makes the point: Shakespeare and WSJ are both English and the WSJ corpus is roughly forty times larger, yet neither model is useful on the other's text. Size (C) does not rescue you from a genre mismatch, which is why the comparison is on the slide at all.

الجواب B. الشريحة تذكر الثلاثة: domain وdialect وstyle. ومقارنة WSJ توضح الفكرة: Shakespeare وWSJ كلاهما إنجليزي، وcorpus الـ WSJ أكبر نحو أربعين مرة، ومع ذلك لا ينفع أي نموذج منهما على نص الآخر. فالحجم (الخيار C) لا ينجيك من عدم تطابق النوع، ولهذا وُضعت المقارنة في الشريحة من الأصل.