The Quora Sincere/Insincere Questions Classification is a Python NLP project that aims to segregate the given dataset of questions posted on Quora into relevant Sincere or Insincere buckets for optimized text classification.
These are questions that are genuinely seeking helpful answers, contributing to the knowledge-sharing ethos of Quora. Sincere questions are founded on a desire for information, insights, and solutions.
Insincere questions are problematic as they are typically not genuine inquiries for information. They may be based on false premises, intended to make statements, or can be offensive, divisive, or inappropriate in nature. These questions often violate Quora's "Be Nice, Be Respectful" policy
- Utilized Quora's Insincere Questions Classification Kaggle Dataset.
- Employed Natural Language Processing (NLP) techniques for text analysis.
- Implemented various models including Logistic Regression, Naive Bayes, Convolutional Neural Network (CNN), and BERT.
- Evaluated models based on accuracy, precision, recall, and F1 score.
- Explored text characteristics crucial for classification, such as word count, character count, and stopword frequency.
- Developed a Streamlit application utilizing DistilBERT for real-time question classification.
- Word Cloud Visualization: Identified most frequent words in sincere and insincere questions.
- Bigram Frequency Analysis: Explored pairs of words occurring frequently together in both sincere and insincere questions.
- Text Characteristics Examination: Analyzed various text attributes crucial for classification, including word count, character count, unique word count, etc.
- Word Count: Calculating the total number of words in each question.
- Unique Word Count: Identifying the count of distinct words used in a question.
- Character Count: Determining the total number of characters present in the question text.
- Stopwords Count: Counting the occurrences of commonly used stopwords (e.g., "the," "is," "and") in questions.
- Punctuation Count: Tracking the usage of punctuation marks within the questions.
- Title and Uppercase Words Count: Detecting the count of words in uppercase or within the title of the question.
- Average Word Length: Calculating the average length of words used in a question.
- Logistic Regression
- Naive Bayes
- Convolutional Neural Network (CNN)
- BERT Implementation in a Streamlit application for real-time question classification.
![Screenshot 2023-12-06 at 9 19 13 PM](https://private-user-images.githubusercontent.com/47267975/288605184-86d0ba01-3ebb-4afa-9754-002b0a0eb0a8.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ1OTU4ODcsIm5iZiI6MTcyNDU5NTU4NywicGF0aCI6Ii80NzI2Nzk3NS8yODg2MDUxODQtODZkMGJhMDEtM2ViYi00YWZhLTk3NTQtMDAyYjBhMGViMGE4LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI1VDE0MTk0N1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWNmNmEyZWNkOWNmOTNkMDU3YzFmMjg3MzZmMDIxYWJmZDAyZmRjNzU4NmI4MDlkZTRlMWU5NGEwNGE2NzU1YjYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.Z77uyNgHu01rligOWGiWO1qLo63D0JcVGZR7m5oU6CY)
![Screenshot 2023-12-06 at 9 17 12 PM](https://private-user-images.githubusercontent.com/47267975/288604964-5e375563-778f-4948-a7a2-f273ce698e1b.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ1OTU4ODcsIm5iZiI6MTcyNDU5NTU4NywicGF0aCI6Ii80NzI2Nzk3NS8yODg2MDQ5NjQtNWUzNzU1NjMtNzc4Zi00OTQ4LWE3YTItZjI3M2NlNjk4ZTFiLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI1VDE0MTk0N1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTBiMWI4MTkwZDk4YmFmZGYyZWQ3NjIyYTU5OGJkMmYzMzg5ZmMyNTdkODE1YTAxOTFlYzc4NzBiZGY3NWU4NGUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.tAuCXgpvz2gRCf0ScXM8WaRC7sVBtbQjElc3zm7SA1o)
![Screenshot 2023-12-06 at 9 16 39 PM](https://private-user-images.githubusercontent.com/47267975/288605021-3cf61b79-7958-4676-842f-2fe4e6ac7b94.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQ1OTU4ODcsIm5iZiI6MTcyNDU5NTU4NywicGF0aCI6Ii80NzI2Nzk3NS8yODg2MDUwMjEtM2NmNjFiNzktNzk1OC00Njc2LTg0MmYtMmZlNGU2YWM3Yjk0LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODI1VDE0MTk0N1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTEzYzI0NzY4NDlkZjc2ZTJlYTEzODA5OTg0MGFjMjBlNzQwZTZhZDFmMzZjYTE3M2E3YWUyNTMwNzQyM2UzNmUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.7RZ1bbuLrFQOnyPStouVXqI2zFEsOoee_tOGw07gVDk)
- Further model fine-tuning and optimization could enhance the performance of Logistic Regression and Naive Bayes models.
- Exploring lightweight NLP models for efficient text classification might be beneficial for large-scale applications.
- Continuous monitoring and improvement of the models' performance against evolving data trends are essential.
This project showcased the efficacy of various NLP models in categorizing Quora questions. While each model had its strengths and weaknesses, the CNN, Logistic Regression, Naive Bayes, and the Streamlit application with DistilBERT offered valuable insights into classifying sincere and insincere questions on Quora.