# Unlocking the Potential of Keyword Extraction: The Need for Access to High-Quality Datasets
## 3 Dataset Identification for Keyword Extraction
### Challenges and Limitations Faced by an Unsupervised Model on the Mohler Dataset  
Short Answers: The dataset consists of very short answers, which poses challenges for keyword extraction methods. For instance, models such as RAKE and YAKE can only extract keywords based on term frequencies, while the KeyBERT model is limited in capturing the full context of the text due to the short nature of the sentences [38; 39]. Biased: As mentioned earlier, the dataset is biased towards correct answers, which makes it difficult for keyword extraction methods to identify key concepts that do not align with the reference answers. Inconsistent Evaluation: The answers in the dataset were graded by two human annotators on a zero-five scale. However, the grading can be inconsistent, as there may be variations in scores between the annotators for certain answers [40]. This inconsistency could pose difficulties for key phrase matching algorithms to compare with human annotators. One possible solution is to calculate the average score and compare the overall similarity score with that average score. Limited Diversity: Another limitation of the dataset is its limited diversity in terms of domain and language. This could affect the generalizability of the keyword extraction models and their performance in real-world scenarios that involve diverse text types and structures. Development of a Preprocessing Natural Language Pipeline for Cleaning the Text Dataset for Keyword Extraction  
Above, Figure 9 shows the general preprocessing pipeline for keyword extraction for an unsupervised model, such as KeyBERT, YAKE, and RAKE. Following are the steps covered in the above figure:  
Reading the raw text data: The first step in the pipeline would be to read the raw text data. This could be performed using a Python library such as Pandas or reading from a file. Meanwhile, from the NLP engine, the NLTK library is best suited for reading the text from the dataset. Cleaning text dataset: To clean the text dataset, remove HTML tags. If the text data is scraped from a webpage, it may contain HTML tags that need to be removed before processing. Many text datasets contain contractions such as \"can't\" or \"won't\". These should be expanded to their full forms (\"cannot\", \"will not\") for consistency. Removing special characters and punctuation: The next step would be to remove any special characters and punctuation marks from the text data. Tokenization: The text data should be split into individual words or tokens for further processing. Lowercasing and stop word removal: The text data should be converted to lowercase to ensure consistency, and common stop words such as \"the\" and \"and\" should be removed to reduce dimensionality. Figure 9: Preprocessing (NLP) pipeline for cleaning the text data. Stemming or lemmatizing: The words in the text data should be stemmed or lemmatized to reduce redundancy and variation in word forms. Depending on the requirements of the project, part-of-speech tagging could also be used to identify specific types of words, such as nouns or verbs. Keyword extraction using models: Finally, the preprocessed text data can be passed through the different keyword extraction models to generate a list of keywords. Here's how each of the models would fit into the pipeline:  
KeyBERT: KeyBERT requires the input text to be in the form of a list of strings, so the preprocessed text data would need to be converted to this format before passing it to the model. YAKE: YAKE can take in the preprocessed text data as a single string, so no additional formatting is required. RAKE: RAKE requires the input text to be in the form of a single string, so the preprocessed text data would need to be concatenated into a single string before passing it to the model. After the keyword extraction, cosine similarity or jacquard similarity can be applied to identify the similar score. In Section 2, we have already discussed cosine similarity. However, Jaccard similarity is a measure of similarity between two sets of items, as mentioned in Equation (2).