A Web-based Text Prediction Application

Submitted for the Coursera Data Science Capstone

author: rdh927 date: April 24, 2016

Text prediction is a time-saver

Today, almost all communication is read, and the vast majority of what is read is typed. Text prediction algortihms save time in communicating words and ideas.

Natural language processing is also useful for artificial intelligence!

More information on the importance of text analytics can be found at http://goascribe.com/text-analytics/why-text-analytics/

Usage of the Web App

The app is designed to be simple and easy to use. It has three components:

  • The input
  • Predicted Word
  • “Top Three” most likely bar plot

The instructions on the app are brief, but clear. Simply type in a sentence or phrase into the text box, then click the “submit” button to see the predicted next word.

The app also produces a bar graph of the top three contenders (including the formal prediction), so you can compare the “runner-up” word options and their likelihoods to the official prediction.

Behind the scenes: how does it work?

Unrecognized slide field: ![screenshot](c

The Prediction Approach: Markov chains

Workflow Overview

The prediction algortihm itself takes the last word (for bigrams) or two words (for trigrams), searches through the data frame to find the term with the highest frequency, and returns the last word in the highest frequency term (“Stupid Backoff” method).