class: center, middle, inverse, title-slide .title[ # Data Science Capstone Project ] .author[ ### PamiQami ] .date[ ### 04-Jan-2024 ] --- ### Slide 1: Introduction The goal of this exercise is to create a product to highlight the prediction algorithm that you have built and to provide an interface that can be accessed by others. For this project you must submit: - A Shiny app that takes as input a phrase (multiple words) in a text box input and outputs a prediction of the next word. - A slide deck consisting of no more than 5 slides created with R Studio Presenter pitching your algorithm and app as if you were presenting to your boss or an investor. --- ### Slide 2: Dataset The dataset utilized in the Word Prediction Shiny App, sourced from [Coursera SwiftKey](https://d396qusza40orc.cloudfront.net/dsscapstone/dataset/Coursera-SwiftKey.zip), is a comprehensive collection of text data, pivotal in developing and refining the predictive text model. This rich dataset comprises text samples extracted from various sources, prominently featuring content from blogs, news articles, and social media platforms like Twitter. The diverse nature of the text, encompassing different styles, tones, and topics, ensures a robust foundation for the predictive algorithm, allowing it to understand and adapt to a wide array of linguistic patterns and contexts. The dataset's extensive scope enables the app to provide accurate and contextually relevant word predictions, catering to a broad spectrum of writing needs and styles. It's a crucial component in making the app versatile and effective in enhancing the user's writing experience. --- ### Slide 3: Construction of the Word Prediction Algorithm - **Data Source**: Utilizes diverse text data from blogs, news, and Twitter (Coursera SwiftKey dataset). - **Preprocessing**: Cleans text by removing non-ASCII characters, numbers, punctuation, transforming to lowercase, and filtering out specific banned words. - **N-Gram Models**: Constructs bigrams, trigrams, and fourgrams from the cleaned dataset for contextual word prediction. - **Prediction Logic**: - Employs separate functions for predicting the next word based on the n-gram models. - Prioritizes higher-order n-grams (fourgrams) for predictions, falling back to trigrams and bigrams as needed. - **Sentiment Analysis**: Integrates sentiment analysis for emotional tone feedback on phrases. --- ### Slide 4: User Interface of the Word Prediction Shiny App - **Intuitive Layout**: User-friendly design for effortless navigation. - **Input Field**: Enables text entry with real-time predictive suggestions. - **Prediction Button**: Generates predictions for entered text. - **Phrase Construction**: Continuously adds inputs and predictions to form a phrase, displayed as "Your Phrase." - **Sentiment Feedback**: Analyzes and indicates the emotional tone of the phrase with emoticons. - **Control Buttons**: Includes options to clear text and restart phrase construction. --- ### Slide 5: Shiny Application <https://damibluedemo1.shinyapps.io/wordprediction/> The Word Prediction Shiny App streamlines the writing process by offering real-time predictive text suggestions, making it a valuable tool for writers, students, and language learners. Its ability to build sentences cumulatively ensures contextually relevant suggestions, enhancing the coherence of written communication. Additionally, the integrated sentiment analysis, visually represented by emoticons, provides immediate feedback on the tone of the text. This user-friendly app not only saves time but also improves the overall quality of written content, making writing more efficient and engaging.