languagemodeling

K1nk1c so in the future we expect k1nk1c of the

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: of 8 ­byte float) Dan Jurafsky Smoothing for Web ­scale N ­grams •  “Stupid backoff” (Brants et al. 2007) •  No discoun*ng, just use rela*ve frequencies " count(wii!k+1 ) $ if count(wii!k+1 ) > 0 $ i!1 i!1 S (wi | wi!k+1 ) = # count(wi!k+1 ) $ ! 0.4 S (wi | wii!1+2 ) otherwise $ k % S (wi ) = 63 count(wi ) N Dan Jurafsky N ­gram Smoothing Summary •  Add ­1 smoothing: •  OK for text categoriza*on, not for language modeling •  The most commonly used method: •  Extended Interpolated Kneser ­Ney •  For very large N ­grams like the Web: •  Stupid backoff 64 Dan Jurafsky Advanced Language Modeling •  Discrimina*ve models: •  choose n ­gram weights to improve a task, not to fit the training set •  Parsing ­based models •  Caching Models •  Recently used words are more likely to appear PCACHE (w | history) = ! P(wi | wi!2 wi!1 ) + (1 ! ! ) c(w " history) | history | •  These perform very poorly for speech recogni*on (why?) Language Modeling Interpola*on, Backoff, and Web ­Scale LMs Language Modeling Advanced: Good Turing Smoothing Dan Jurafsky Reminder: Add-1 (Laplace) Smoothing c(wi!1, wi ) + 1 PAdd !1 (wi | wi!1 ) = c(wi!1 ) + V Dan Jurafsky More general formulations: Add-k c(wi!1, wi ) + k PAdd !k (wi | wi!1 ) = c(wi!1 ) + kV 1 c(wi!1, wi ) + m( ) V PAdd !k (wi | wi!1 ) = c(wi!1 ) + m Dan Jurafsky Unigram prior smoothing 1 c(wi!1, wi ) + m( ) V PAdd !k (wi | wi!1 ) = c(wi!1 ) + m c(wi!1, wi ) + mP(wi ) PUnigramPrior (wi | wi!1 ) = c(wi!1 ) + m Dan Jurafsky Advanced smoothing algorithms •  Intui*on used by many smoothing algorithms •  Good ­Turing •  Kneser ­Ney •  Wi_en ­Bell •  Use the count of things we’ve seen once •  to help es*mate the count of things we’ve never seen Dan Jurafsky Nota1on: Nc = Frequency of frequency c •  Nc = the coun...
View Full Document

This document was uploaded on 02/14/2014.

Ask a homework question - tutors are online