Lecture 03 · N-grams
المحاضرة 03 · نماذج N-grams
General and Modified Kneser-Ney
Kneser-Ney العام والمعدَّل
P3 SKIMP3 تصفّح سريعThe recursive version for any n-gram order, plus one fact you must not get wrong: which count is used at which level.
الصيغة التكرارية (recursive) لأي رتبة n-gram، مع حقيقة واحدة لا يصح أن تخطئ فيها: أي count يُستخدم في أي مستوى.
This page is lower priority than the bigram page. Seven slides, four of them prose with no formulas. Budget ten minutes. If you are short on time, learn the cKN table and the 1/V floor, know that modified Kneser-Ney means three discounts d₁, d₂, d₃₊, and move on to entropy and the summary.
هذه الصفحة أقل أهمية من صفحة bigram. سبع شرائح، أربع منها نصّ بلا معادلات. خصّص لها عشر دقائق. وإذا ضاق وقتك، فاحفظ جدول cKN وأرضية 1/V، واعرف أن modified Kneser-Ney تعني ثلاثة discounts هي d₁, d₂, d₃₊، ثم انتقل إلى entropy والملخص.
The recursive form
الصيغة التكرارية (recursive)
Slide 94. Same shape as the bigram formula, written for arbitrary order.
الشريحة 94. الشكل نفسه الذي رأيته في صيغة bigram، لكن مكتوباً لأي رتبة.
اقرأ الصيغة في جزئين. الجزء الأول كسر: بسطه max(cKN(wi−n+1:i) − d, 0)، أي عدّاد الـ n-gram كاملاً بعد خصم d منه مع منع السالب، ومقامه Σv cKN(wi−n+1:i−1 v)، أي مجموع العدّادات على كل كلمة v يمكن أن تتبع السياق. الجزء الثاني هو λ للسياق مضروباً في الصيغة نفسها برتبة أقل. ترتيب الحساب: ابدأ من أعلى رتبة، وكل مرة اسقط الكلمة الأقصى يساراً من السياق، ونزّل حتى تصل للأرضية.
Three things changed from the bigram case, and nothing else:
ثلاثة أمور فقط تغيّرت عن حالة bigram، ولا شيء غيرها:
- The history
wi−1became a whole contextwi−n+1:i−1.التاريخ
wi−1صار سياقاً كاملاًwi−n+1:i−1. - The thing you back off to is no longer
PCONTdirectly. It is the same formula one order down, with the leftmost history word dropped (wi−n+2:i−1). That is the recursion.ما ترتدّ إليه (back off) لم يعد
PCONTمباشرة، بل الصيغة نفسها برتبة أقل بواحد، بعد إسقاط أقصى كلمة يساراً من التاريخ (wi−n+2:i−1). هذا هو التكرار (recursion). - Counts are written
cKN, notC. That subscript is the entire content of slide 95.العدّادات تُكتب
cKNوليستC. هذا الحرف السفلي وحده هو كل مضمون الشريحة 95.
The one thing on this page you cannot get wrong
الشيء الوحيد في هذه الصفحة الذي لا يجوز أن تخطئ فيه
Slide 95 defines cKN as a two-case function:
تعرّف الشريحة 95 الرمز cKN كدالة بحالتين:
سطران فقط: في أعلى رتبة (highest) يكون cKN هو count(·)، أي العدّ الخام العادي. وفي كل الرتب الأدنى (lower) يكون continuationcount(·)، أي عدد الأنواع المختلفة التي تسبق المعامل.
So the symbol cKN changes meaning as the recursion descends. At the top of the ladder it is an ordinary token count. One step down and all the way to the bottom it is a count of distinct preceding word types.
إذن الرمز cKN يتغير معناه كلما نزل التكرار. في أعلى السلّم هو عدّ عادي للـ tokens، ومن الدرجة التي تحته وحتى الأسفل هو عدّ لأنواع الكلمات المختلفة التي تسبقه.
يرسم المخطط سلّماً من أربع درجات لنموذج trigram. الدرجة العليا (trigram) تستخدم c_KN = count( ) أي العدّ الخام. الدرجتان تحتها (bigram ثم unigram) تستخدمان continuationcount( )، ومستوى unigram هو P_CONT نفسه بثوب آخر. والدرجة الأخيرة هي الأرضية المنتظمة 1 / V بلا أي عدّادات. والأسهم بينها هي ضرب في lambda للسياق. الخلاصة أسفل الرسم: العدّ الخام يظهر على درجة واحدة فقط، وهي القمة.
Which count at which level
أي عدّ في أي مستوى
Read this table as "I am training a trigram Kneser-Ney model". The highest order is a property of the model you chose, not of the formula.
اقرأ الجدول بافتراض أنك تدرّب نموذج trigram Kneser-Ney. فـ أعلى رتبة صفة للنموذج الذي اخترته، لا للصيغة نفسها.
| Levelالمستوى | Quantity neededالكمية المطلوبة | cKN meansمعنى cKN | Concretelyبشكل ملموس |
|---|---|---|---|
| TrigramTrigram | cKN(wi−2 wi−1 wi) | countالعدّ (count) | how many times that trigram occurredكم مرة ظهر ذلك الـ trigram |
| BigramBigram | cKN(wi−1 wi) | continuationcountعدّ الاستمرار (continuation count) | how many distinct words v gave v wi−1 wiكم كلمة مختلفة v أعطت v wi−1 wi |
| UnigramUnigram | cKN(wi) | continuationcountعدّ الاستمرار (continuation count) | how many distinct words precede wiكم كلمة مختلفة تسبق wi |
| Floorالأرضية | noneلا شيء | not usedغير مستخدم | uniform 1/Vمنتظم 1/V |
يقول الجدول: على مستوى Trigram يكون cKN هو count، أي كم مرة ورد ذلك الـ trigram. على مستوى Bigram يكون continuationcount، أي كم كلمة مختلفة v أنتجت v wi−1 wi. على مستوى Unigram هو عدد الكلمات المختلفة التي تسبق wi. وعلى مستوى Floor لا عدّادات أصلاً، بل 1/V.
Now the same table for a bigram model, to show that the labels move:
والآن الجدول نفسه لنموذج bigram، ليبيّن أن التسميات تتحرك:
| Levelالمستوى | Quantity neededالكمية المطلوبة | cKN meansمعنى cKN |
|---|---|---|
| BigramBigram | cKN(wi−1 wi) | count, because the bigram is now the highest orderالعدّ (count)، لأن الـ bigram صار الآن الرتبة العليا |
| UnigramUnigram | cKN(wi) | continuationcount, which is why slide 84 backs off to PCONTعدّ الاستمرار (continuation count)، ولهذا تتراجع الشريحة 84 إلى PCONT |
في نموذج bigram انتقلت التسمية درجة واحدة لأعلى: مستوى Bigram صار هو أعلى رتبة فيستخدم count الخام، ومستوى Unigram يستخدم continuationcount، ولهذا بالضبط ترتدّ الشريحة 84 إلى PCONT.
Raw counts only on the top rung. The highest order sees the real data, so it uses real counts. Everything below it exists only to answer "what would I guess if I had not seen this context?", and that question is about diversity, so it uses continuation counts.
العدّ الخام على الدرجة العليا فقط. أعلى رتبة هي التي ترى البيانات الحقيقية، فتستخدم عدّادات حقيقية. وكل ما تحتها موجود فقط للإجابة على سؤال: ماذا كنت سأخمّن لو لم أرَ هذا السياق؟ وهذا السؤال عن التنوّع، فيستخدم continuation counts.
Single sentence version: count at the top, continuation-count all the way down.
بجملة واحدة: count في القمة، وcontinuation-count في كل ما بعدها نزولاً.
"Highest order" is relative to the model, not absolute. In a 4-gram Kneser-Ney model, the trigram level uses continuation counts, even though in the table above it used raw counts. If a question says "a trigram KN model", the trigram rung is raw. If it says "a 5-gram KN model", the trigram rung is a continuation count.
عبارة "highest order" نسبية للنموذج وليست مطلقة. في نموذج 4-gram Kneser-Ney يصبح مستوى trigram مستخدماً لـ continuation counts، رغم أنه في الجدول أعلاه استخدم العدّ الخام. فإذا قال السؤال "a trigram KN model" فدرجة trigram خام، وإذا قال "a 5-gram KN model" فدرجة trigram هي continuation count.
Second trap: at the bigram level in a trigram model, cKN(wi−1 wi) is the number of distinct words preceding the whole bigram, not the number of distinct words preceding wi. The continuation count is taken of the entire argument you pass to cKN.
الفخ الثاني: على مستوى bigram داخل نموذج trigram، فإن cKN(wi−1 wi) هو عدد الكلمات المختلفة التي تسبق الـ bigram كاملاً، وليس عدد الكلمات التي تسبق wi وحدها. فالـ continuation count يُحسب للمعامل كله الذي تمرّره إلى cKN.
Raw count versus continuation count at a lower level, with numbers
العدّ الخام مقابل عدّ الاستمرار في مستوى أدنى، بالأرقام
A trigram model, d = 0.75, and these are the only occurrences of the bigram reading glasses in training:
نموذج trigram، وd = 0.75، وهذه هي كل مواضع ظهور الـ bigram reading glasses في بيانات التدريب:
trigram types containing "reading glasses"
the reading glasses x 2
my reading glasses x 1
his reading glasses x 1
raw bigram count C(reading glasses) = 2 + 1 + 1 = 4
continuation count c_KN(reading glasses) = |{the, my, his}| = 3
"reading" is followed only by "glasses", so at the bigram level
Sum_v c_KN(reading v) = c_KN(reading glasses) = 3
N(reading) = |{w : c_KN(reading w) > 0}| = 1
CORRECT, bigram level of a trigram model, using c_KN = 3
discounted term = max(3 − 0.75, 0) / 3 = 2.25 / 3 = 0.7500
lambda(reading) = (0.75 / 3) * 1 = 0.25 = 0.2500
check 0.7500 + 0.2500 = 1.0000
WRONG, same level but using the raw count 4
discounted term = max(4 − 0.75, 0) / 4 = 3.25 / 4 = 0.8125
lambda(reading) = (0.75 / 4) * 1 = 0.1875
check 0.8125 + 0.1875 = 1.0000
اقرأ الكتلة من أعلى لأسفل. أولاً أنواع الـ trigrams التي تحتوي "reading glasses" مع تكراراتها. ثم العدّ الخام C(reading glasses) = 4 مقابل c_KN(reading glasses) = 3 لأن السوابق المختلفة ثلاث فقط: the, my, his. ثم لأن "reading" لا يتبعها إلا "glasses"، يكون المقام Sum_v c_KN(reading v) = 3 وN(reading) = 1. الكتلة الثالثة هي الحساب الصحيح بـ c_KN = 3 فيخرج الحد المخصوم 0.7500 وlambda = 0.2500، والرابعة هي الحساب الخاطئ بالعدّ الخام 4 فيخرج 0.8125 و0.1875.
Both versions sum to 1, so normalisation will not catch the error for you. The numbers simply differ: 0.75 against 0.8125, and the mass passed down the recursion differs by 0.0625. Using raw counts at a lower order quietly rebuilds the Kong problem one order up.
النسختان تجمعان إلى 1، فالتطبيع لن يكشف لك الخطأ. الأرقام فقط تختلف: 0.75 مقابل 0.8125، والكتلة المنقولة إلى الرتبة الأدنى تختلف بمقدار 0.0625. واستخدام العدّ الخام في رتبة أدنى يعيد بناء مشكلة Kong بهدوء على مستوى أعلى بدرجة.
Where the recursion stops
أين يتوقف التكرار
Slide 96. The unigram level does not back off to another n-gram. It backs off to a uniform distribution over the vocabulary.
الشريحة 96. مستوى unigram لا يرتدّ إلى n-gram آخر، بل يرتدّ إلى توزيع منتظم على كل الـ vocabulary.
هذه صيغة آخر درجة. الكسر الأول بسطه max(cKN(w) − d, 0)، أي continuation count للكلمة بعد خصم d، ومقامه Σw′ cKN(w′)، أي مجموع هذه العدّادات على كل كلمات vocabulary. ثم يُضاف λ(ε) مضروباً في 1/V، وε هي التاريخ الفارغ. لا يوجد نداء تكراري بعد هذا السطر، فهنا يتوقف النزول.
εis the empty string, that is, the empty history. Slide 96 writes it asλ()with nothing inside, which is the same thing.εهي السلسلة الفارغة، أي التاريخ الفارغ. وتكتبها الشريحة 96 على صورةλ()بلا شيء داخلها، وهما الشيء نفسه.- Because
1/V > 0andλ(ε) > 0, no word can ever receive probability zero. The whole point of smoothing is discharged at this last rung.بما أن
1/V > 0وλ(ε) > 0، فإنه لا يمكن لأي كلمة أن تحصل على احتمال صفر. كل الغرض من smoothing يتحقق عند هذه الدرجة الأخيرة. <UNK>needs no special treatment. Include it as an ordinary vocabulary item with count 0, and it inheritsλ(ε)/V.<UNK>لا يحتاج معالجة خاصة. أدرجه كعنصر عادي في vocabulary بعدّاد صفر، فيأخذ تلقائياًλ(ε)/V.
The ladder has a floor made of 1/V. Any word that fails at every higher order still lands on it. "Kneser-Ney cannot produce a zero" is a one-line answer worth having ready.
السلّم له أرضية مصنوعة من 1/V. وأي كلمة تفشل في كل الرتب الأعلى تهبط عليها في النهاية. وجملة "Kneser-Ney cannot produce a zero" جواب من سطر واحد يستحق أن يكون جاهزاً في ذهنك.
Why modified Kneser-Ney exists
لماذا وُجد Kneser-Ney المعدَّل
Slide 97. A single discount d for every count is a simplification. The Church and Gale evidence on slide 77 showed held-out counts sitting near c − 0.75 for c = 2 to 9, but the row for c = 1 was 0.448, which is 1 − 0.552, not 1 − 0.75. Counts of 1, counts of 2, and counts of 3 or more behave differently.
الشريحة 97. استخدام discount واحد d لكل العدّادات تبسيط. فبيانات Church and Gale في الشريحة 77 أظهرت أن عدّادات held-out تقع قريباً من c − 0.75 للقيم c = 2 إلى 9، لكن صف c = 1 كان 0.448، أي 1 − 0.552 لا 1 − 0.75. فعدّاد 1 وعدّاد 2 وعدّاد 3 أو أكثر تتصرف بطرق مختلفة.
Modified Kneser-Ney, slide 98
Modified Kneser-Ney، الشريحة 98
Chen and Goodman's fix: keep the Kneser-Ney structure exactly as it is, and use three discounts instead of one.
حلّ Chen and Goodman: أبقِ بنية Kneser-Ney كما هي تماماً، واستخدم ثلاثة discounts بدل واحد.
| N-gram countعدّ الـ N-gram | Discount appliedالخصم المطبَّق | Why a separate valueلماذا قيمة منفصلة |
|---|---|---|
| 1 | d₁ | singletons are the noisiest and shrink the most in held-out dataالـ singletons هي الأكثر ضوضاء والأكثر انكماشاً في بيانات held-out |
| 2 | d₂ | still noisy, but less soما زالت فيها ضوضاء، لكن أقل |
| 3 or more3 أو أكثر | d₃₊ | well attested, a near-constant subtraction is already a good fitموثّقة جيداً، والطرح شبه الثابت مناسب لها أصلاً |
يربط الجدول كل عدّاد بالـ discount الخاص به: العدّاد 1 يأخذ d₁ لأن الـ singletons أكثرها ضجيجاً وأكثرها تقلّصاً في بيانات held-out، والعدّاد 2 يأخذ d₂ فهو ما زال فيه ضجيج لكن أقل، والعدّاد 3 أو أكثر يأخذ d₃₊ لأنه موثّق جيداً ويكفيه خصم شبه ثابت.
- Nothing else changes: still discount plus interpolation, still
cKNwith the same two-case definition, still a uniform floor.لا شيء آخر يتغير: ما زال discount مع interpolation، وما زال
cKNبتعريفه ذي الحالتين نفسه، وما زالت الأرضية المنتظمة موجودة. λgets more bookkeeping, since the mass reserved per history now depends on how many continuations had count 1, count 2, and count 3 or more.يزيد العمل الحسابي في
λ، لأن الكتلة المحجوزة لكل تاريخ تعتمد الآن على عدد الـ continuations التي عدّادها 1، وعدّادها 2، وعدّادها 3 أو أكثر.- It is the best-performing classic method and the standard baseline. Shipped in KenLM and SRILM.
هي أفضل الطرق الكلاسيكية أداءً وخط الأساس القياسي، ومُضمّنة في KenLM وSRILM.
Modified Kneser-Ney is not about multiple n-gram orders, and it is not about multiple λ weights. Interpolating several orders is already what plain Kneser-Ney does. The word "modified" refers only to splitting the single d into d₁, d₂, d₃₊ by count. If you can say "three discounts, for counts 1, 2 and 3-or-more" you have the whole slide.
Modified Kneser-Ney ليست عن تعدد رتب الـ n-gram، وليست عن تعدد أوزان λ. فالدمج بين عدة رتب هو ما يفعله Kneser-Ney العادي أصلاً. كلمة "modified" تشير فقط إلى تقسيم d الواحد إلى d₁, d₂, d₃₊ حسب العدّاد. وإذا قدرت أن تقول "three discounts, for counts 1, 2 and 3-or-more" فقد أخذت الشريحة كلها.
Also note the detail level the deck itself admits: slide 98 says "high level" and the textbook sends you to Chen and Goodman for the formulas. You are not expected to reproduce the modified λ.
ولاحظ مستوى التفصيل الذي تعترف به الشرائح نفسها: الشريحة 98 تقول "high level"، والكتاب يحوّلك إلى Chen and Goodman للصيغ. أنت غير مطالَب باستخراج λ المعدّلة.
Practical notes
ملاحظات عملية
Slide 99, three bullets worth one sentence each.
الشريحة 99، ثلاث نقاط كل واحدة تستحق جملة واحدة.
- Kneser-Ney is the strongest classic n-gram smoothing method on many benchmarks.
Kneser-Ney هي أقوى طرق smoothing الكلاسيكية للـ n-gram في كثير من المعايير.
- It helps most for higher-order n-grams with sparse counts, which is exactly where raw MLE collapses.
أكبر فائدتها تكون في الـ n-grams ذات الرتب العالية وعدّاداتها المتناثرة، وهو بالضبط الموضع الذي ينهار فيه MLE الخام.
- Smoothing parameters,
dincluded, are tuned on dev or held-out data. Never on the test set, per slide 70.معاملات smoothing، ومنها
d، تُضبط على بيانات dev أو held-out، ولا تُضبط أبداً على test set، حسب الشريحة 70.
Bridge to neural language models
الجسر إلى النماذج اللغوية العصبية
Slide 100 is the last content slide before entropy, and it explains why the course moves on.
الشريحة 100 هي آخر شريحة محتوى قبل entropy، وهي تشرح سبب انتقال المقرر إلى ما بعدها.
What kills n-grams
ما الذي يقتل نماذج n-grams
- Parameters grow exponentially with n: a vocabulary of V needs up to Vn table entries.
عدد المعاملات ينمو أُسّياً مع n: vocabulary حجمه V يحتاج ما يصل إلى Vn خانة في الجدول.
- They generalise poorly unless the exact context was seen. Smoothing softens the zeros, it does not create understanding.
تعميمها ضعيف إلا إذا كان السياق ذاته بالحرف قد ظهر من قبل. وsmoothing يلطّف الأصفار فقط، ولا يصنع فهماً.
- reading glasses and prescription glasses share no statistics with each other in an n-gram table.
عبارتا reading glasses وprescription glasses لا تتشاركان أي إحصاء في جدول n-gram.
What neural LMs change
ما الذي تغيّره النماذج العصبية
- Words and tokens live in a continuous space, so similar words share parameters.
الكلمات والـ tokens تسكن في فضاء متصل، فتتشارك الكلمات المتشابهة المعاملات نفسها.
- Generalisation comes from similarity, not from having seen the identical string.
التعميم يأتي من التشابه، لا من رؤية السلسلة ذاتها حرفياً.
- Transformer-based language models come later in the course. Lecture 04 starts this with word meaning and embeddings.
النماذج اللغوية القائمة على transformer تأتي لاحقاً في المقرر. والمحاضرة 04 تبدأ هذا المسار بمعنى الكلمة وembeddings.
Slide 94 uses λ(wi−n+1:i−1) without ever defining it for the general order. It is the same budget as slide 85, lifted to the general context:
الشريحة 94 تستخدم λ(wi−n+1:i−1) دون أن تعرّفها أبداً للرتبة العامة. وهي الميزانية نفسها التي في الشريحة 85، مرفوعة إلى السياق العام:
اقرأها كضرب طرفين: الكسر هو d مقسوماً على مجموع عدّادات cKN لكل كلمة v تتبع السياق، أي حجم الخصم لكل وحدة كتلة. والطرف الثاني هو حجم المجموعة |{ w : cKN(... w) > 0 }|، أي عدد الكلمات المختلفة التي ظهرت فعلاً بعد هذا السياق. فحاصل ضربهما هو إجمالي الكتلة المحجوزة للرتبة الأدنى.
Note that the denominator here must use the same cKN as the first term of that level, not a raw count. If you mix the two, your probabilities will not sum to 1.
لاحظ أن المقام هنا يجب أن يستخدم cKN نفسه المستخدم في الحد الأول لذلك المستوى، لا العدّ الخام. وإذا خلطت بينهما فلن تجمع احتمالاتك إلى 1.
Slide 94 also renders the summation in the denominator awkwardly, with the Σv drifting away from the expression it binds. It is Σv cKN(wi−n+1:i−1 v), a sum over every word v that could follow the context, and it is the correct generalisation of C(wi−1) from slide 84.
كما أن الشريحة 94 ترسم المجموع في المقام بشكل مربك، فيبتعد Σv عن التعبير الذي يرتبط به. والصحيح أنه Σv cKN(wi−n+1:i−1 v)، أي مجموع على كل كلمة v يمكن أن تتبع السياق، وهو التعميم الصحيح لـ C(wi−1) من الشريحة 84.
Check yourself
اختبر نفسك
You are training a trigram Kneser-Ney model. At the bigram level of the recursion, what does cKN(wi−1 wi) mean?
أنت تدرّب نموذج trigram Kneser-Ney. على مستوى bigram من التكرار، ما معنى cKN(wi−1 wi)؟
B. The bigram is a lower order here, so cKN is the continuation count of its whole argument: distinct single-word contexts for the string wi−1 wi. A would be correct only in a bigram model, where the bigram is the highest order, which is the most common version of this mistake. C counts continuations, which is what λ needs, not what cKN is. D takes the continuation count of the wrong argument: that is the unigram-level quantity.
الجواب B. الـ bigram هنا رتبة أدنى، فيكون cKN هو continuation count لمعامله كاملاً، أي عدد السياقات المختلفة من كلمة واحدة للسلسلة wi−1 wi. والجواب A صحيح فقط في نموذج bigram حيث يكون الـ bigram أعلى رتبة، وهذه أشهر صور هذا الخطأ. والجواب C يعدّ الـ continuations وهو ما تحتاجه λ، لا ما يعنيه cKN. والجواب D يأخذ continuation count للمعامل الخطأ، فتلك كمية مستوى unigram.
The recursion terminates at the unigram level by interpolating with what?
ينتهي التكرار عند مستوى unigram بالدمج (interpolating) مع أي شيء؟
D. Slide 96 adds λ(ε)·(1/V), which is why no word can end up with probability zero and why <UNK> works with count 0. B is the unigram level itself, not what it backs off to: the unigram level already uses continuation counts, so it cannot back off to them again. C would leave any word with continuation count 0 at probability zero, defeating the point of smoothing.
الجواب D. تضيف الشريحة 96 الحد λ(ε)·(1/V)، ولهذا لا يمكن لأي كلمة أن تنتهي باحتمال صفر، ولهذا يعمل <UNK> بعدّاد صفر. والجواب B هو مستوى unigram نفسه وليس ما يرتدّ إليه، فمستوى unigram يستخدم continuation counts أصلاً فلا يمكن أن يرتدّ إليها مرة أخرى. والجواب C سيترك أي كلمة continuation count لها صفر عند احتمال صفر، وهذا يُبطل الغرض من smoothing.
What exactly does "modified" change in modified Kneser-Ney?
ما الذي تغيّره كلمة "modified" بالتحديد في modified Kneser-Ney؟
C. That is the whole of slide 98: same structure, three discounts selected by the n-gram's count. A is wrong because standard Kneser-Ney already recurses through every order. B inverts the central idea of slide 95. D is wrong on both halves: λ is still a computed budget, and it is still determined by the counts for that history.
الجواب C. هذا كل مضمون الشريحة 98: البنية نفسها، وثلاثة discounts يُختار بينها حسب عدّاد الـ n-gram. والجواب A خطأ لأن Kneser-Ney القياسي يتكرر عبر كل الرتب أصلاً. والجواب B يعكس الفكرة المركزية للشريحة 95. والجواب D خطأ في نصفيه: λ ما زالت ميزانية محسوبة، وما زالت تُحدَّد من عدّادات ذلك التاريخ.
Slide 100 says n-gram models "generalize poorly unless exact contexts are seen". What is the neural LM's answer to this?
تقول الشريحة 100 إن نماذج n-gram "generalize poorly unless exact contexts are seen". ما جواب النماذج العصبية (neural LM) على هذه المشكلة؟
A. Smoothing redistributes mass between table entries but the entries stay unrelated to each other, so reading glasses teaches the model nothing about prescription glasses. Continuous representations make that transfer possible. B and D are both smoothing, which is the thing being superseded. C runs straight into the other bullet on the same slide: parameters grow exponentially with n, so storing more orders makes sparsity worse, not better.
الجواب A. smoothing يعيد توزيع الكتلة بين خانات الجدول، لكن الخانات تبقى بلا علاقة ببعضها، فلا تعلّم reading glasses النموذج أي شيء عن prescription glasses. والتمثيلات المتصلة هي ما يجعل هذا النقل ممكناً. والجوابان B وD كلاهما smoothing، وهو الشيء الذي يُستبدل أصلاً. والجواب C يصطدم مباشرة بالنقطة الأخرى في الشريحة نفسها: المعاملات تنمو أُسّياً مع n، فتخزين رتب أكثر يزيد التناثر ولا يقلله.