2026-08-07

Project Overview

The goal of this project was to create a predictive text application that suggests the next word based on user input.

The application was developed using:

  • R
  • Natural Language Processing techniques
  • Shiny framework

Training data:

  • Twitter messages
  • News articles
  • Blog posts

Data Processing and Prediction Model

Text preprocessing

  • Text cleaning
  • Tokenization
  • N-gram generation

Prediction model

  • Trigram prediction
  • Bigram fallback
  • Frequency ranking


Shiny Application

The application allows users to:

  • Enter a phrase
  • Receive a predicted next word
  • Interact with the model through a web interface

Example:

Input: “happy new”, Prediction: “year”

Conclusion

The project resulted in a functional next word prediction application.

Achievements:

  • Built an NLP prediction model
  • Created an interactive Shiny interface
  • Published the application online

Future improvements:

  • Larger training datasets
  • More advanced language models
  • Neural network approaches