SwiftKey Next Word Prediction App
Slide 1: Goal of the Project
- Build a smart next word predictor like SwiftKey keyboard
- Input: a phrase with multiple words
- Output: predict the next single word
- Example: “I went to the” → “store”
Slide 2: Data Used
- Dataset from Coursera SwiftKey capstone
- Files used:
- en_US.blogs.txt
- en_US.news.txt
- en_US.twitter.txt
- I used sampling so it runs faster and does not crash
Slide 3: Algorithm Used
- I used N-gram model:
- bigrams (2 words)
- trigrams (3 words)
- Backoff approach:
- try trigram prediction first
- if not found, use bigram
- if still not found, return a common fallback word like “the”
Slide 4: Shiny App Working
- User enters a phrase in text box
- Click Submit
- App returns predicted next word
- Model is kept small for better speed and loading time