Objective - Build a Shiny app to predict the next word - Apply NLP using n-gram models
Deliverables - Deployed Shiny app - RPubs presentation - Example predictions
Objective - Build a Shiny app to predict the next word - Apply NLP using n-gram models
Deliverables - Deployed Shiny app - RPubs presentation - Example predictions
Data Source - SwiftKey corpus (Blogs, News, Twitter)
Preprocessing - Lowercasing - Remove punctuation and numbers - Remove extra whitespace - Tokenization
Backoff N-gram - Trigram → Bigram → Unigram - Fast, efficient, handles unseen phrases
Features - Text input for phrases - Predicts next word - Simple UI
Examples
| Input Phrase | Prediction |
|---|---|
| The weather today is very | sunny |
| I love watching | movies |
Summary - Built a next-word prediction Shiny app - Used real-world text data - Implemented backoff n-gram model
Future Work - RNN / LSTM models - Improved accuracy - Mobile-friendly UI