This section introduces the basic concepts of cyberbullying and demonstrates the constructed GA-FS framework. It covers some basic concepts in feature engineering and dimensionality reduction, and then metaheuristic algorithms with emphasis on GA. Finally, it touches on recent research developments in sentiment analysis. Table 1, shown at the end of the section, offers a snapshot of the seminal and recent literature referenced in this review, classified by topic and summarizing their key contribution directly relevant to our method.
Cyberbullying and its effects
Cyberbullying is the act of harming or harassing another person using technology or the internet, and its psychological implications are severe. The impact of cyberbullying leads to increased rates of anxiety, depression, and low self-esteem, and in extreme cases, even suicidal ideation2,14. Hence, while personal insults and threats might be manageable in several cases, the uniqueness of the internet as an environment that is both completely anonymous and incredibly sprawling makes cyberbullying a particularly dangerous undertaking. To the students and teenagers who are among the most active users of the Internet, cyberbullying interferes with their academic achievements, communication with peers, and mental health15,16,17.
Research on Arabic cyberbullying faces methodological difficulties because of dialectal fragmentation and limited dataset availability5. The social expectation of preserving family dignity makes it hard for victims to disclose their experiences. People who decide to seek help from available support services tend to use them at very low rates according to18. Cyberbullying remains poorly understood in most Arab regions, since people lack knowledge about how to identify or report this issue19.
The necessity of applying GA to feature selection
Considering what has been discussed and the negative consequences rampantly associated with cyberbullying, it becomes important to establish a proper model for analyzing abusive language in Arabic. One of the most popular techniques is GA, that, based on the idea of natural selection, is considered to be a promising method for feature selection20. GA is used to sort through the features of a data set, which can include keywords, phrases, or stylistic features, and optimize machine learning for maximal accuracy21,22. If the same approach is applied to Arabic, then it might provide a strong solution against different dialects of the language when it comes to the identification of cyberbullying21.
Pros of using feature selection before classification
This is one of the most important preprocessing steps in machine learning, where the most important features from a given data set are selected and the rest are discarded. This step is very important, especially in text classification, because datasets in text classification contain many features; for example, words, phrases, or n-grams that may overwhelm the machine learning algorithms. Feature selection, when used to select only important features, is very useful in improving the performance of the classification models as well as increasing efficiency23,24,25.
The first advantage of feature selection is the ability to cut down on the number of features, otherwise known as dimensionality reduction26. Due to the large variability of the texts and languages used in the creation of text classification datasets, they can contain thousands or even millions of data features. Most of these features can either be irrelevant or duplicate, due to which it might be difficult to classify. Feature selection eliminates such features on the dataset, as shown above, which may not be relevant to the solution of the problem hence bending the model to be easier and computationally inexpensive.
This issue is especially acute in processing morphologically rich languages such as Arabic, where feature selection can make a critical difference27. Useless or unproductive attributes distort the data in which machine learning algorithms work and worsen it by adding noise. It selects the most relevant features and helps the model ignore the rest, making it easy to classify outcomes that are most important for making a decision28. The effectiveness of such an improvement is especially notable in text classification problems, where even the nuances of the use of words have a critical impact. Feature selection also helps in increasing the interpretability of models in machine learning. Sometimes, it is preferable to train a model on a subset of features; the process helps decipher the reasons behind some of the outputs made. For example, in a text classification task to detect cyberbullying, the features that were selected may be centered on some special abusive words or phrases29. This interpretability may be useful for researchers and practitioners, who must explain the result or adjust the models.
Feature selection can help the model and prediction processes to be completed much faster. In this case, the use of machine learning algorithms is normally accompanied by significant computational resources in solving the problems. By decreasing the number of features, feature selection accelerates the construct and allows making predictions in real or near real-time, which is especially important for applications such as spam filtering, sentiment analysis, or cyberbullying identification25.
Impacts of feature selection on classification models
The process of feature selection determines which attributes lead to the best generalization performance of models while minimizing overfitting effects and refining decision boundary definitions30. The process of selecting features plays a vital role in text classification because sparse, high-dimensional vocabularies would otherwise defeat algorithms. Feature selection enhances model interpretability by demonstrating which specific words and phrases lead predictions, which become crucial for detecting cyberbullying29. Feature selection reduces feature sets to improve computational speed and deliver fast predictions across extensive text datasets25.
Effects of feature selection on text classification
When it comes to text classification, feature selection has a very straightforward impact on how well a model comprehends or even classifies text data31. This is helpful because it draws attention to those parts of the text that are likely to be informative of the target classes, the keywords, phrases, or patterns31,32. For instance, in cyberbullying data set, feature selection might consider words such as ‘happy’, ‘angry’, or ‘sad’, therefore excluding such words as ‘the’, ‘and,’ etc. Feature selection also offers a critical contribution to handling the problem of sparsity in text data31. It is worth noting that in most text datasets, there are a large number of features in which the number of occurrences is very low. In addition, feature selection makes the proportional distribution of data more balanced and representative because only those features that are most frequently used are selected. Feature selection enables the use of more sophisticated algorithms for text classification32. With reduced dimensionality, models such as support vector machines (SVM), decision trees, or even deep learning architectures can be implemented more effectively, resulting in better predictions.
How metaheuristic algorithms improve feature selection for text classification models
Metaheuristic algorithms are complex optimization methods based on natural observation, which include evolution, swarm, or physical process33. These algorithms have been used in solving various problems in different disciplines, and they have been used in feature selection for text classification. Text categorization entails sorting text data into already defined classes, including spam or not spam, positive or negative sentiment, or the presence of cyberbullying in the text data34,35. Feature selection is important at this time to select the most informative and important features from the dataset while working with a smaller set of features. In this study, Metaheuristic algorithms like GA provide several benefits that enrich the aspect of feature selection as well as the text classification models at large.
Dealing with text data complexity
The text datasets are inherently challenging to analyze because of the high dimensionality, sparse matrix, and diverse choice of words. The problem is that traditional feature selection methods, including filter and wrapper methods, are incapable of handling such complexity levels. Metaheuristic algorithms, in contrast, can be applied to any problem that has a large search space33. They employ the mechanism of intelligent search to find out which of the features best defines the subset and how much exploration against exploitation in the search space should be performed. For instance, techniques such as GA select solutions over several generations in a natural selection process, to identify the most important features amongst feature sets in the dataset34,35. Beyond GA, other nature-inspired methods, like the improved discrete laying chicken algorithm have also shown notable success in enhancing text classification performance36.
Increase in the efficiency of text classification
Perhaps one of the most valuable aspects of metaheuristic algorithms in feature selection is the enhanced accuracy of text classification models23. These algorithms help to minimize noise and inconsequential data, which may complicate the classification models within a given dataset. In a sentiment analysis task, a metaheuristic algorithm can prefer sentiment words such as ‘happy,’ ‘angry,’ or ‘sad,’ and demote stop words such as ‘the’ or ‘and.’ These non-redundant features also assist in the accuracy of the classification model, as it provides a more sophisticated feature subset.
Handling nonlinear relationships between features
In text classification, some features can have a complex relationship, where two or more features may interact in a non-linear manner that a basic linear model cannot pick37. Among these variables, metaheuristic algorithms offer an excellent fit for modeling these relationships. Particle Swarm Optimization (PSO) mimics the movement of a swarm of particles, and each particle depicts a prospective feature set. While particles are exchanging messages containing information, the algorithm finds a correlation that would give the best features, even if the relationships are not linear37. This capacity allows for the identification of nonlinear interactions and, therefore, improves the quality of the chosen features and, thereby, the classification model.
Robustness to diverse text challenges
Text classification generally has several issues that include writing styles, languages, and noise within the data set. Metaheuristic algorithms are resistant to those challenges because they do not assume a lot about data11. Like the cooling process of metals, the simulated annealing approach can get out of the local optimum and search even for the global optimal feature subset. This adaptability makes sure that the selected features are useful throughout different text datasets, which makes the classification model generalizable28.
Enhancing model interpretability
Such metaheuristic algorithms do increase the efficiency of text classification models’ performance and make those algorithms easier to interpret. These algorithms tend to find subsets of features that are smaller and more significant, to explain why a model reaches such a decision. In a cyberbullying detection task, some of the features selected might be the specific abusive words or phrases that were used, and this makes the decision quite unambiguous29. This is particularly important in creating trust with machine learning applications, especially within sensitive subjects such as online safety.
Text feature selection using GA
There is another very effective technique for feature selection named GA, which is a metaheuristic optimization technique based on the principles of selection, crossover, and mutation of natural selection and evolution. In a similar way that GA emulates the ‘‘evolution’’ of solutions, it does so with feature selection, and by doing so, grants the right measure of exploration and exploitation to generate efficient and effective models38,39. The GA works based on a population of solutions, in which each solution consists of a population of feature subsets40. These are commonly called “chromosomes”, and the solutions improve through selection, crossover, and mutation to enhance feature subsets. Each of these solutions can be fit into the framework based on a set goal, for example, increasing the accuracy or precision of the text classification model. This approach is most important because it helps the algorithm to concentrate on feature subsets that are most important in the model40.
Since text feature selection is based on high dimensional data, GA is useful for solving this problem. Text datasets generally have thousands of, or millions of features, which are often unimportant, or which replicate other important features33,41. Since traditional optimization techniques fail to handle this complexity, GA is well suited to handling large search spaces. Thus, by apprehending the overall search for the best feature subsets, the dimensionality of the dataset is decreased, and the classification model becomes faster and more efficient. Recent studies, such as multi-objective manifold representation approaches, further highlight the role of optimization in capturing complex opinion patterns in text classification tasks42.
In feature selection, optimization methods face the problem of premature convergence to suboptimal solutions that provide low-quality feature subsets that do not represent the optimal feature subsets. GA addresses this issue by introducing genetic variation using crossover (parts of two solutions) and mutation (random changes in solutions)39,40. Such diversity is beneficial because it lets GA search for a wider area and identify the best feature subsets globally. As presented above, GA is a highly scalable method and is well suited to other text classification problems. In this respect, it can be used with any type of language, domain, and dataset, without any restrictions based on some assumptions made on the data41,43. For instance, in the case of detecting cyberbullying, GA can be tuned to identify abusive words or phrases; in the context of sentiment analysis, GA can emphasize emotional terms21. This flexibility renders GA a useful feature selection in virtually all areas of application.
Apart from improving the model accuracy, GA also makes text classification models easier to understand29. Since the model is only restricted to considering a small number of features that are most relevant in determining output, it is much easier to explain why the model makes certain predictions. For instance, the identified features in a spam detection task may point to specific words related to slim scientific interest, while unveiling the decision-making procedure of the model.
Research gap and objectives
Despite growing interest in Arabic cyberbullying detection, existing models struggle with high-dimensional feature spaces and lack interpretable insights into dialect-specific abuse. In this study, we apply GA–FS to distill over 38, 035 features derived from Term Frequency-Inverse Document Frequency (TF-IDF) and embeddings into a compact, highly discriminative subset (as detailed in the Results section and Fig. 1, where feature count was reduced to 19,012 using the GA pipeline described in Methods). By explicitly handling script variation, colloquial language, and cultural context, a GA-FS framework was implemented to enhance classification precision while reducing computational expense through its combination of preprocessing methods and lexical representation and GA optimization. The evaluation of feature subsets was conducted using an SVM with a weighted F1-score. The evaluation process identified the most useful features, which are employed across various classifiers for benchmarking. The selected feature set will also detect the most important abusive words, providing actionable insights for sociolinguistic examination and platform moderation.
