Fake News Detection Using Recurrent Neural Network Based on Bidirectional LSTM and GloVe_2024
Fake News Detection Using Recurrent Neural Network Based on Bidirectional LSTM and GloVe_2024
https://doi.org/10.1007/s13278-024-01198-w
ORIGINAL ARTICLE
Abstract
In the world of technology, the electronic and technical development of the fields of communication and the internet has
increased, which has caused a renaissance in the virtual world. This development has greatly impacted virtual communities
for the ease and speed of communication and information transfer through social media platforms, making these platforms
likable and easy to use. The social network faces major challenges due to its extensive use. As a result, many people have
become involved in cybercrimes. There are accounts on the internet that are malicious. Platforms for social networking online,
such as Facebook and Twitter, allow all users to freely generate and consume massive volumes of material regardless of
their traits. While individuals and businesses utilize this information to gain a competitive edge, spam or phony users create
important data. According to estimates, 1 in 200 posts on social media contain spam, and 1 in 21 tweets contain spam. The
problem was centered around the accuracy of detecting false news and correcting it or preventing its dissemination before it
spread in the network. A new method is given based on improving the false news detection system; the level of improvement
was significant in the preprocessing stage where Glove is used, which is an unsupervised learning algorithm developed by
researchers at Stanford University aiming to generate word embeddings by aggregating global word co-occurrence matrices
from a given corpus. The basic idea behind the GloVe word embedding is to derive the relationship between the words from
statistics. The proposed method contains deep learning algorithms of convolutional neural network (CNN), deep neural net-
work (DNN), and long short-term memory (LSTM). The RNN with GloVe in the preprocessing stage using the Curpos fake
news dataset to enhance the system, due to the sequential processes and classification, has the highest accuracy of 98.974%.
6
* Laith Abualigah Hourani Center for Applied Scientific Research, Al-Ahliyya
[email protected] Amman University, Amman 19328, Jordan
7
1 MEU Research Unit, Middle East University, Amman 11831,
Computer Science Department, Al Al-Bayt University,
Jordan
Mafraq 25113, Jordan
8
2 Department of Electrical and Computer Engineering,
College of Engineering, Al Ain University,
Lebanese American University, Byblos 13‑5053, Lebanon
112612 Abu Dhabi, United Arab Emirates
9
3 College of Engineering, Yuan Ze University, Taoyuan,
Department of Management Information Systems, College
Taiwan
of Business Administration, Taif University, P.O. Box 11099,
10
21944 Taif, Saudi Arabia School of Engineering and Technology, Sunway University
4 Malaysia, Petaling Jaya 27500, Malaysia
CSMIS Department, Oman College of Management
11
and Technology, 320 Barka, Oman Faculty of Information Technology, Isra University,
5 Amman 11622, Jordan
Artificial Intelligence and Sensing Technologies (AIST)
12
Research Center, University of Tabuk, Tabuk 71491, Applied Science Research Center, Applied Science Private
Saudi Arabia University, Amman 11931, Jordan
Vol.:(0123456789)
40 Page 2 of 16 Social Network Analysis and Mining (2024) 14:40
validity of this information, and here lies the difficulty of or even spread fake news to harm government agencies
verifying the authenticity of the published news, and thus reputations that reflected the country.
the topic of discovering false news has become one of the • The Twitter platform can be used for the most recent
most influential topics in the eyes of researchers. compromise and threat detection rules; even Twitter bots
This research aims to improve the performance of the can use a honeypot to directly monitor the Internet of
deep learning RNN Bi-LSTM, CNN, and DNN algorithms Things and log data on Twitter.
used to detect fake news by classifying all the entered articles • Cybercriminals and attackers can abuse social media
provided that this classification is based on an assignment platforms like Twitter to serve their malicious purposes,
of 1 for all fake news on the one hand and an assignment of such as fraud, by replying to messages sent to official
zero. On the other hand, in the preprocessing stage and also accounts and providing site links or wrong contact to
the use of global vectors to represent words (GloVe), which successful attacks.
are used to deal with high dimensions within news articles, • Directly thwarting frauds because they usually do not rely
and then work to improve accuracy, recall, and precision by on malicious executable files to hack victims; instead,
working to improve the input of rating scales to reach a high- they target unsuspecting victims by social engineering
level Accuracy and speed in detecting fake news. A novel attacks.
system where used to detect spam and fraudulent accounts,
which aims to enhance the preprocessing stage in order to This paper is organized as in Sect. 2; the related works are
get accurate analytical results. Using GloVe on the dataset presented. Section 3 shows the proposed method. In Sect. 4,
in order to create a clear dataset ready for the testing stage the results and discussions are given. Section 5 shows the
will lead to enhancing the speed and accuracy. conclusion and future work directions.
The importance of this paper is related to the large
increase in social media users in the Kingdom, and what this
requires is the importance of interacting with that increase 2 Related works
through the use of technology in sorting and classifying all
tweets and identifying the important ones to deal with it Cybercrime, fraud, and the spread of misinformation can
quickly. The importance of the paper can be summarized in all be perpetrated using social media. With the broad avail-
the following points: ability of Internet access and mobile devices, more people
are turning to social media for collaboration and real-time
• Protect users’ cyberspace from fraud accounts by information, which cyber security professionals may utilize
enhancing distinguished communicative posts through to collect threat intelligence and keep track of threats. On
positive tweets that appear from the excavation surveys Twitter, a microblogging site that has gained popularity as a
and their indicators that positively impact society. means of communication and news distribution, spammers,
• Providing decision makers in government agencies and fraudsters are active. Researchers have devised several
with realistic analytical results of the impact of social protective measures to detect spam and fraudsters and combat
interactions with any tweet, positive or negative, to guide their activities on Twitter. Researchers have presented several
them when building strategic and operational plans for solutions to address this issue, significantly improving spam
government agencies and fraud detection performance. As a result, it motivates us
• Defining evaluation criteria and indicators for interactions to thoroughly examine many techniques for detecting fraud-
through social networks, especially the Twitter platform, sters on Twitter.
to inform the tweeters of the evaluation effects of their RNNs are the most advanced algorithms for sequential
tweets, investigate the positive ones, and deal with the data and are the foundation of Google Voice Search and
negative ones in an effective manner that ensures the Apple’s Siri. Due to its internal memory, it is the first algo-
well-being of the citizen and the resident rithm to recall its input, making it ideal for machine learning
• Results can help government agencies’ cyber security issues involving sequential data. It is one of the algorithms
teams utilize additional open data to secure their online that helped deep learning accomplish some incredible suc-
premises, even if it needs further work to check context cesses over the past several years. In this article, the funda-
reliability. mental ideas behind recurrent neural networks are consid-
• Threat intelligence via social media platforms like ered, as well as the main problems they face and how to fix
Twitter requires that data gathered can be cleaned and them.
processed, analyzed, and validated in a given context so False information, also known as fake news, is
it can be used to protect against cyber security threats deliberately spread with a particular motive. In order to
because any social media platform can be abused to prevent the potential damage to the political and social
commit cybercrimes or phishing targets by fraudsters domains, several research is being done to identify and
40 Page 4 of 16 Social Network Analysis and Mining (2024) 14:40
combat the dissemination of false information. This reasoning. The LSTM is defined as a special type of recur-
work employs a deep learning approach using several rent neural network that can remember information for
architectures, including CNN, bidirectional LSTM, and a long time, as it was designed precisely to get rid of the
ResNet, in conjunction with pre-trained word embedding problem of long-term dependency on recurrent networks.
(Sastrawan, et al., 2022). The models are trained using However, with the increase in the length of LSTM, problems
four distinct datasets. Every datum undergoes a data appear in the algorithm, which is that the existing informa-
augmentation procedure using the back-translation technique tion is lost continuously, and the algorithm becomes able
in order to mitigate imbalances in data distribution across to remember only the last information. The solution was
classes. The findings demonstrated that the bidirectional found in what is known as bidirectional LSTM, which is
LSTM architecture had superior performance compared to like LSTM goes through an input sequence, but the differ-
CNN and ResNet across all evaluated datasets. ence here is that bidirectional LSTM goes in both directions
Social media networks like Facebook flood with user- simultaneously. (Kumar et al., 2017).
generated material every second. Thus, many things, includ- The recurrent neural network uses long short-term
ing threats and sexual harassment, are easier to spot than memory blocks to offer context for how the program takes
conventional media. Extremely toxic internet material may inputs and produces outputs. A complicated structure, the
cause harassment, vulgarity, personal assaults, and bullying. long short-term memory block has several parts, including
The use of Bangla on Facebook has increased because it is weighted inputs, activation functions, inputs from earlier
the sixth most spoken language. The usage of abusive Bangla blocks, and ultimate outputs. Because the software uses a
comments on Facebook has surged rapidly, but the evidence structure built on short-term memory processes to build
is few. This study identifies abusive Bangla comments on longer-term memory, the unit is known as a long-term
Facebook that can be filtered out in the early stages of social memory block. Examples of applications for these systems
media affixing (Aurpa, et al. 2022). Transformer-based deep include natural language processing. In order to assess a
neural network models quickly and accurately detect offen- word or phoneme in relation to other words in a string—
sive remarks. BERT and ELECTRA pre-training language where memory might be helpful in sorting and classifying
architectures are used. The unique dataset includes 44,001 these sorts of inputs—the recurrent neural network employs
comments from several Facebook postings. The results show lengthy short-term memory blocks.
that our BERT and ELECTRA architecture operates well This scientometric analysis investigated 569 documents
with 85.00% and 84.92% test accuracy. retrieved from the Scopus database spanning the period from
Recurrent neural networks are a common deep learn- 2012 to mid-2022. The study aimed to identify prevalent
ing approach that has been around for a while. However, research trends, publication and citation patterns, authorship
they were first developed in the 1980s. RNNs have truly and collaboration dynamics, bibliographic coupling, and
gained attention thanks to advances in computing power, productivity patterns (Dhiman, et al. 2023). The ultimate
the enormous quantities of data they have access to, and the objective was to employ deep learning techniques to detect
development of LSTM in the 1990s. It is an artificial neural instances of fake news. The investigation used Biblioshiny
network that operates according to feed-forward sequential and VOSviewer. The results of this analysis unequivocally
input operations of variable length through the formation of indicate a consistent rise in publications since 2016,
the so-called recurring hidden layer whose activity in each highlighting the ongoing prevalence of false news on a
entry process depends on the last time. When the recurrent worldwide scale. An examination of academic papers
neural networks pass through a neural network training pro- indicates that there is a lack of substantial research in the
cess, the recurrent neural networks use the reverse propaga- areas of social media surveillance and monitoring of public
tion algorithm, and the minimum error function is obtained opinions, as well as the issue of fake news. On the other
by repeating small steps in the direction of the negative error hand, there is a limited amount of research in the specialized
derivative concerning the weights related to the networks. fields of deep fake detection, digital content analysis, digital
As a result, the recurrent neural networks suffer from the forensics, and computer vision. Moreover, the findings
disappearance of a problem. Gradients in the lower lay- indicate that China and the USA exhibit the most robust
ers of the deep network because the size of the gradients international cooperation despite the fact that India produces
becomes smaller and smaller for each subsequent layer; the a greater number of papers. This study also evaluates the
use of LSTM is one of the possible solutions to this problem. current advancements in deep learning methods for detecting
(Bahad et al. 2019). false news, aiming to provide a viable guide for scholars
Recurrent neural networks have units or blocks called interested in doing research in this area.
LSTM. Certain artificial memory techniques are created to The convolutional layer serves as the fundamental build-
be used by recurrent neural networks, which can aid these ing component of the CNN process, which performs the
deep learning systems in more accurately mimicking human majority of the computations, as shown in Fig. 1. In this
Social Network Analysis and Mining (2024) 14:40 Page 5 of 16 40
layer, the CNN recognizes essential information from the that the model works successfully. In addition, max-pooling
input image, such as the shape of the edges. In the proposed provides the highest value from the image partially covered
method, three convolutional networks are used with three by the kernel. Max-pooling may also remove noisy activa-
layers to obtain the best feature extraction and classification tions and minimize dimensionality (Ren et al., 2020). Fig-
results. The first layer collects low-level characteristics such ures 2 and 3 show an example of 2 × 2 max-pooling.
as color, gradient coordination, edges, and angles. When the As shown in Table 1, many researchers used the GloVe in
architecture passes through another convolutional layer, the a way to enhance the preprocessing stage, which increases
first layer’s output becomes the second layer’s input. The the accuracy result for any system that will be used for detec-
design adjusts with high-level elements, such as a blend of tion. Also, the highest accurate result was for GloVe in the
curves and straight edges, as more layers are added (Chen preprocessing stage of a long short-term memory; due to
et al., 2021). that, GloVe and word2word are used within the preprocess-
Rectified linear unit (ReLU) is utilized after each ing stage addition to Bi-LSTM algorithm in order to achieve
convolutional stage. ReLU is an element-by-element process the best result using the corpus benchmark dataset.
that is performed on every pixel. ReLU reduces all negative In conclusion, the studies presented highlight the per-
pixel values to zero in the feature map. The goal of ReLU vasive nature of cybercrime, fraud, and misinformation on
is to display nonlinearity in the CNN model since most social media platforms, with a particular focus on Twitter.
real-world data is nonlinear. When the model is built, all of As these platforms become integral for collaboration and
these operations are applied, and more convolutional layers real-time information sharing, the role of cybersecurity pro-
are added. The architecture goes through activation maps fessionals in leveraging them for threat intelligence becomes
that generate more complex characteristics to comprehend crucial. The studies emphasize the prevalence of spammers
human faces’ features properly. and fraudsters on Twitter, prompting researchers to develop
The pooling and convolutional layer assist the model in protective measures for detecting and combating their activi-
understanding the image characteristics. To construct the ties. A significant advancement in this domain involves the
CNN in this work, 2 × 2 max pooling is employed to reduce use of RNNs, particularly LSTM blocks, which have proven
the three-dimensional size of the convoluted feature. 2 × 2 effective in handling sequential data and addressing chal-
max-pooling helps reduce the computational resources lenges such as the vanishing gradient problem.
required to handle data through dimensionality reduction. The evolution of RNNs, from their inception in the
Furthermore, it extracts significant characteristics to ensure 1980s to their recent resurgence, is attributed to advances
Chauhan & Palivela 2021 dataset is taken from kaggle. LSTM & GloVe 99.88%
com (Ahmed, Traore, & S aad:
2018)
Sahoo & Gupta 2021 Facebook Base Line KNN & SVM 99.40%
Caldarelli, De Nicola, Del Vigna, 2020 Van Lidth Bipartite Directed Configuration Model 95%
Petrocchi & Saracco (BiDCM)
hmad: Aljuaid & Shah
Asif, Ishnaq, A 2020 Total dataset came from Multinomial Naive Bayes and Linear 82%
Moderate, Neutral, Highly Support Vector
Extreme & Low Extreme
Kaliyar, Goswami & Narang 2020 Real-world fake news BERT-based & CNN 98.90%
JIANG. LI, HAQ & SAB 0 OR 2020 fact-checking Bi-LSTM 99.82%
Is. & Tuncer 2019 Twitter KNN &SVM 95.81%
Kres"n"akov, Sarnovsky & Butka 2019 Haggle competition Feedforward, Convolutional & LSTM 93% For CNN
Madisetty & Desaikar 2018 Hspam & 1KS10KN CNN & GloVe 95.70%
AlbadL Kurdi & Mishra 2018 Create their own dataset RNN with Gated Recurrent Units 79%
Orabi, Buddhitha: Grabi & Inkpen 2018 CLPsych2015 & e Bell Lets Talk CNNT.Vith.Max, MultiChannelCNN 83% for
MulnChannelPoolingCNN & Bi-LSTM MultiChan
(Context-aware attention) nelCNN
Heikal. Torki & El-Makkv 2018 AS ID CNN & LSTM 65.05%
Abdullah, Hadzikadic & Shaikh 2018 SemEval-2018 CNN-LSTM Sl%
Kwaik. Saad. Chatzikvriakidis & Dobnik 2013 Dialect corpus SDC 90%
in computing power, increased data availability, and the 3 The proposed method
development of LSTM in the 1990s. The studies underscore
the importance of understanding the fundamentals of recur- The most significant advantage of online social media is that
rent neural networks, the issues they face, and solutions to it helps us connect with people more easily and efficiently.
enhance their performance. Notably, the introduction of bidi- One of the goals is to create a model that can determine
rectional LSTM addresses the problem of losing informa- whether communications can be used to commit fraud and
tion in longer sequences, providing a more comprehensive flag users from official accounts. In order to protect citizen
solution. The studies also shed light on the application of privacy and prevent fraudulent accounts from phishing users
RNNs, particularly LSTM blocks, in natural language pro- contacting agencies for information about services and
cessing tasks, where the ability to retain context over input targeting those accounts, the CIA is keeping data integrity
sequences is crucial. by examining analytical data from government agencies.
Furthermore, the incorporation of CNNs in the proposed Potential threats such as impersonation, fake information,
method highlights their significance in feature extraction etc. Phishing scams target individuals with communications
and classification tasks. The convolutional layers play a that appear to come from legitimate sources to harm victims
pivotal role in recognizing essential information from input by stealing personal and financial information and possibly
images, with each layer building upon the extracted features convincing them to infect their own devices by encouraging
of the previous layer. The use of rectified linear unit (ReLU) them to download malicious programs or pay for services
after each convolutional stage introduces nonlinearity they do not need.
to the CNN model, which is essential for capturing The method presents a collection of optimized features
complex characteristics, such as human facial features. In independent of historical tweets, which are only available
essence, the studies underscore the dynamic landscape of on Twitter for a limited time. The characteristics of Twitter
cybersecurity challenges on social media platforms, with a users, their accounts, and their pairwise interactions with
focus on Twitter, and emphasize the critical role of advanced one another are considered. The efficacy and resilience of
algorithms like recurrent neural networks and convolutional the given strategy in the lab are demonstrated and compared
neural networks in addressing these challenges. The ongoing to a commonly used feature set for spam and fraud detection
exploration of techniques and solutions in these domains in the literature, yielding a significant performance gain.
reflects the commitment to staying ahead of evolving cyber A major feature used among others is:
threats in the digital age.
Social Network Analysis and Mining (2024) 14:40 Page 7 of 16 40
• Tweets: every tweet contains data that can be used for false information and fake news and the other with all the
classification accurate information.
• User mentions: any user mentioning another user by
symbol @ followed user ID, so the tweet means that the
user is always abreast of that tweet and is interested in it. 3.2 Deep learning
• Replies: The user can direct reply to another user they
mention at the beginning of the tweet. After the preprocessing sends the best features to the deep
• Retweets: a retweet means to resend a tweet to other users learning classifier, the deep learning network will be created
and keep the original one that posted it in consideration. based on the dataset features, where the neurons and layers
• Hashtags: similar to tags on social tagging systems or will change based on the features. Still, one Flatten layer and
other social networking systems, hashtags included in two Dense layers will remain the same for all the datasets.
a tweet tend to group tweets in conversations that are of Deep learning creates features to be categorized with the
common interest to several users in a community processed data. The features are divided into train and test
(validation) datasets. The train data shape, which serves as
the input layer for the deep learning, Conv, and SoftMx lay-
3.1 Dataset description
ers, weighs and categorizes the data (Samples, SeqLength,
and Dimensions). The Flatten layer interpreted the results
3.1.1 Fake news dataset
and aggregated the weights and information that the Conv
and SoftMx layers have processed for the Dense layers;
This is an open-source dataset composed of millions of news
The Dense layers categorized the results into labels and
articles, mostly scraped from a curated list of 1001 domains
percentages. In the given example, binary classification was
from http://www.opensources.co/. Because the list does not
used; the Dense layer assigned labels depending on the pro-
contain many reliable websites, NYTimes and WebHose Eng-
portion of each label [0,1] or multi-class label. As shown in
lish News articles have been included to balance the classes
the next section, deep learning used formulas for the clas-
better. Corpus is mainly used to train deep learning algorithms
sification. The deep learning–classification mathematics:
for fake news recognition. The dataset is still a work in pro-
gress, and for now, the public version includes only 9,408,908
∑ ∑ [ ]
G[m, n] = (f ∗ h)[m, n] = h j, k f [m − j, n − k] (1)
articles (745 out of 1001 domains). The corpus was created by j
k
scraping (using scraps) all the domains as provided by http://
www.opensources.co/. Then, all the pure HTML content was Kernel convolution is a major component of several other
processed to extract the article text with some additional fields computer vision methods and deep learning. It is a method
(listed below) using the newspaper library. Each article has that takes a tiny matrix of numbers (known as a kernel or
been attributed the same label as the label associated with its filter), applies it to the given picture, and then transforms
domain. The source code is available at Fake News Recogni- it using the values from the filter. The following formula is
tion and will be more “usable” in the next few months. used to determine subsequent feature map values, where the
input picture is indicated by f, and the kernel is denoted by
h. The result matrix’s row and column indexes are denoted
3.1.2 Fake and real dataset by m and n, respectively. The indices j and k control how the
filter is applied across the input tensor, influencing how fea-
This dataset contains two major files, fake and real news tures are detected and combined to produce the final output.
articles and tweets in English. Each file contains up to 170
thousand rows between tweets and statements. The dataset is nin + 2p − f
nout = [ + 1] (2)
not clean, and the researchers should do their preprocessing. s
where: n — image size, f — filter size, n — number of chan-
3.1.3 Misinformation and fake news text dataset nels in the image, p —used padding.
Each convolution layer’s classification
A collection of 79,000 propaganda, false news, and
misinformation items was compiled from a number of sites, Z [I] = W [I] .A[I−1] + b[I] (3)
including Reuters, the New York Times, the Washington
Post, and others. The “false” articles come from websites A[I] = g[I] (Z [I] ) (4)
run by right-wing extremists in America (such as Redflag
Newsdesk, Breitbart, and Truth Broadcast Network). The where: The first is to compute the intermediate value Z,
articles have been stripped of all information save the text which is generated by convolutional the preceding layer’s
itself, and they are divided into two sets: one with all the input data with the W tensor (which contains filters) and
40 Page 8 of 16 Social Network Analysis and Mining (2024) 14:40
then adding bias b. Applying a nonlinear activation function (validation) in the training set. In most instances, a dataset
to the intermediate value is the second step (the activation is split into a training set and a validation set for every
is denoted by g). iteration, a validation set, and a test set for each iteration
The data will be split into two main parts: training to (“test set” in the relevant literature).
train the classifier in the percentage of 70% and testing to A model for test data by machine learning is built.
evaluate the training efficiency of the classifier and gain the Then, the training data to match the model is used and
reports and accuracy. The features will be extracted to select validated it. Next, the created models are used to predict
them by the classifier and assign weights to classify them the test set is uncertain results. A model for testing the
by the layers and neurons. After selecting the features, the data was created by machine learning, this model was then
layers will be built based on the length of the vectors. The used in order to match the training data for validation.
layers are based on the extract percentage of the features, Following this, the models were used to anticipate and
and neurons are based on formula (2*length of features + 1) predict the test set:
to obtain the best deep learning performance. The data will
be classified by deep learning and based on layers, where • Training Set: This is utilized for training the data model
the types of layers calculate the weights and provide predic- in order to achieve better results.
tions. The results are two main types: a confusion matrix • Validation Set: Choosing the proper and correct
(TP, TN, FP, and FN) and a classification report to observe parameters is significant; splitting the collection into
the precision, recall, and F1 score. Figure 4 shows the deep two sets: a set of trains and another for validation. This
learning classification network workflow. model can be accustomed on the basis of validation data
(altering parameters classifiers for instance). To ensure
achieving the ultimate possible model.
3.3 Training and testing • Testing Set: when the model is achieved and obtained,
based on the training set/s can be anticipated and predicted.
A training set is used to build/construct a model in a data- • This study performed, training, validation, and testing
set, while the evaluation tests the built-in model, i.e., the of the data; training data mounted 70% of the overall
validation set. Data points are omitted from the evaluation dataset. However, 20% is for testing and the other 10% is
for validation.
4.1 Evaluation methods
Several terms are commonly used, along with the descrip- model was then used in order to match the training data
tion of recall, precision, and accuracy. They are true posi- for validation. Following this, the models were used to
tive (TP), true negative (TN), false negative (FN), and false anticipate and predict the test set:
positive (FP). If the disorder exists in a patient, the test also
demonstrates that the disease occurs, and the diagnosis test • Training Set: This is utilized for training the data model
findings are known to be a true positive. Similarly, if a patient in order to achieve better results.
has a demonstrated absence of a disorder, the diagnosis exam- • Validation Set: Choosing the proper and correct
ination indicates that the disease is also lacking (TN). A sat- parameters is significant, splitting the collection into
isfactory finding between the diagnostic test and the proven two sets: a set of trains and another for validation. This
condition will mean both true positive and negative outcomes model can be accustomed on the basis of validation data
(also called the standard of truth). However, there is no flaw- (altering parameters classifiers for instance). To ensure
less diagnostic exam. When the screening test reveals a patient achieving the ultimate possible model.
with no illness, the findings are false positive for the existence • Testing Set: when the model is achieved and obtained,
of disease (FP). Likewise, if the diagnostic test outcome indi- based on the training set/s can be anticipated and
cates that a patient with the disorder is not present for sure, the predicted.
test result is incorrect (FN). The test outcomes are contrary to • This study performed training, validation, and testing
the real conditions: false positive and false negative. of the data; training data mounted 70% of the overall
Confusion Matrix: As the name indicates, it gives us dataset. While 20% is for testing and the other 10% is for
an output matrix representing the full model performance. validation.
There are four important terms:
4.3 Experimental setup
• True Positives: predicted YES and the actual output YES.
• True Negatives: predicted NO and the actual output NO.
There has been an increasing demand for AI in the last dec-
• False Positives: predicted YES and the actual output NO.
ade, mainly for machine learning purposes as well as the
• False Negatives: predicted NO and the actual output
utilization of such concepts for hardware acceleration. Never-
YES.
theless, the necessary for data training is essential in order to
Precision = TP∕ (TP + FN) (5) improve the quality of predicting and anticipating, especially
in complex applications of machine learning systems.
Recall = TN∕ (TN + FP) (6) Although minor and small models for machine learn-
ing do not require large quantities of data, however, train-
ing major and more significant models, such as neural net-
Accuracy = (TN + TP)∕(TN + TP + FN + FP) (7) works, dictates increasing the number of parameters. The
automated system deploys an initial machinery assessment
The F1 score is t he 2*((precision*recall)/ with patients by processing tools for images and face recog-
(precision + recall)) (8). The F score or F calculation is often nition. Therefore, deep learning apart from us is deployed for
referred to. In other words, F1 reveals the balance between an accurate comparison for choosing the most appropriate
accuracy and reminder. classifiers as hoc for face recognition and detection.
Table 2 CNN Parameters Input layer Hidden layer Hidden neurons Epoch Output layer
Table 3 CNN Data and network shape Table 4 CNN classifier confusion matrix
Shape Value Dataset Number of layers Accuracy %
calculations by making the library Nvidia CUDA Deep Neu- assessment over many datasets with differing layer counts
ral Network. is shown in Table 4. The databases include Misinforma-
Anaconda Python 3.7 is the machine learning architecture tion, Fake News, and propaganda, Fake and Real News, and
for the sponsored version of GPU that was chosen to be Fake News Data. The percentages of accuracy for models
Keras (Tensorflow). Keras is based on TensorFlow. KERAS with 3, 4, 5, and 6 layers are shown for each dataset. The
was added to its success and broad support for various accuracy of the Fake News Dataset increases progressively
learning styles, design features, and hypermeters. Libraries, with the number of levels—it reaches 98.7% with six lay-
such as Pandas data storage, Numpy for multidimensional ers. This shows that the model’s capacity to identify false
arrays, and Scikit Learn for data analysis, were enabled. The news is favorably impacted by a deeper design. Compara-
other classifiers were trained, tested, and classified via the bly, the accuracy in the Fake and Real News dataset rises
Sklearn machine libraries. with the number of layers, reaching a maximum of 98.3%
with six levels. This suggests that discriminating between
4.5 Results false and authentic news may be done more accurately with
a more complicated model structure. The accuracy of the
4.5.1 Convolutional neural network and deep neural Misinformation, Fake News & Propaganda dataset similarly
network shows a steady improvement with increasing layer count,
reaching 98.82% accuracy with six layers. This supports the
Tables 2 and 3 show the CNN and DNN parameters that idea that a deeper model works better to handle the com-
have been used in the testing of the proposed method; the plexity of classifying propaganda and disinformation. In
layers and the hidden layer have been chosen based on the conclusion, the findings imply that adding more layers to
dataset size without affecting the performance, run time, and the model improves its accuracy across a variety of datasets,
accuracy results. The optimized method has also been used particularly when tackling the difficult job of differentiating
to avoid overfitting in the data (data divided to near zero) between false information and legitimate news. The results
and achieve the maximum accuracy and minimum run time highlight how crucial model design is to improving classi-
for the proposed methods. fication task performance about information veracity.
The CNN confusion matrix has been extracted and calcu- In Fig. 5, the accuracy of the proposed method using
lated from performing the classifier comparing with Twitter CNN has been shown and plotted. The proposed method
datasets as the following Table 4. The model’s performance with all datasets achieved the best accuracy by using the
Social Network Analysis and Mining (2024) 14:40 Page 11 of 16 40
Fig. 5 CNN accuracy for pro- CNN accuracy for proposed method datasets
posed method datasets
Table 5 RNN Parameters Input layer Hidden layer Hidden neurons Epoch Output layer
six-layer architecture. The best accuracy was 98.82% for Table 6 RNN Data and network shape
the misinformation dataset due to the dataset diversity and
Shape Value
the model was able to understand the contents and predict
the misinformed and real news in the dataset. The lowest Shape NLP CSV dataset (3674, 2)
accuracy with using six layers was with the real and fake Data tensor shape (593, 1000)
news datasets due to the complexity of words and the con- Labels shape (593, 4)
tent. However, the model was able to achieve an accuracy input_1 (InputLayer) (None, 1000)
of 98.3% (Fig. 6). embedding_1 (Embedding) (None, 1000, 100)
Tables 5 and 6 show the RNN and LSTM parameters that bidirectional_1 Bi-direction (None, 20)
have been used in the testing of the proposed method; the dense_1 (Dense) (None, 3)
layers and the hidden layer have been chosen based on the Total params 376,443
dataset size without affecting or affecting the performance, Trainable params 376,443
40 Page 12 of 16 Social Network Analysis and Mining (2024) 14:40
run time, and accuracy results. The optimized method has RNN classifier routinely obtains excellent accuracy in the
also been used to avoid overfitting in the data (data divided Fake News dataset, ranging from 98.2% with 3 layers to
to near zero) and achieve the maximum accuracy and mini- 98.974% with six layers. This shows that, with a noticeable
mum run time for the proposed method. The equations and improvement as model complexity grows, the RNN model
mathematics that have been used in RNN and LSTM in the is successful in reliably identifying bogus news. The RNN
proposed method are as follows: classifier continues to perform well on the Fake and Real
W_f,b_f- > Forget gate weight and bias. News dataset, improving accuracy from 97.7% with 3 lay-
W_i,b_i- > Input gate weight and bias. ers to 98.12% with 6 layers. This shows that the extra layers
W_c,b_c- > Candidate cell state weight and bias. improve the accuracy of the RNN model, which is resilient
W_o,b_o- > Output gate weight and bias. in differentiating between bogus and true news. The RNN
where is. classifier often exhibits great accuracy in the Misinforma-
The class state is f* W_f,b_f. tion, Fake News & Propaganda dataset, ranging from 98.78%
Hidden state is ot * W_i,b_i. with 3 layers to an astounding 98.99% with 6 layers. This
Output equation is W_i,b_i + b + W_o,b_o leading demonstrates how well the RNN performs complicated
y = softmax (v). tasks, including disinformation and propaganda, with the
The CNN confusion matrix has been extracted and cal- model’s depth contributing to a discernible improvement.
culated from performing the classifier comparing with both Overall, Table 7’s findings demonstrate the durability
Twitter datasets as the following in Table 7. The results of an and dependability of the RNN classifier in categorizing
RNN classifier’s confusion matrix for a range of datasets and various kinds of data, with a distinct trend toward increasing
layer counts are shown in Table 7. Accuracy percentages for accuracy with layer count. These results imply that a more
datasets containing 3, 4, 5, and 6 layers of misinformation, complex RNN architecture improves the model’s capacity
fake news, and propaganda are included in the confusion to identify patterns and subtleties in datasets pertaining to
matrix, along with datasets with fake and real news. The disinformation, false news, and actual news.
The proposed method’s accuracy when utilizing RNN
Table 7 RNN classifier confusion matrix and LSTM is displayed and plotted in Figs. 7, 8, 9 and 10.
Dataset Number of layers Accuracy % With the use of the six-layer design, the suggested strategy
produced the best accuracy across all datasets. Due to the
Fake news data 3 98.2 dataset diversity and the model’s ability to comprehend the
4 98.4 contents and forecast both false and true news in the data-
5 98.437 set, the best accuracy for the misinformation dataset was
6 98.974 98.99%. The actual and false news datasets had the lowest
Fake and real news 3 97.7 accuracy while employing six layers because of the com-
4 97.78 plexity of the words and content. However, the model was
5 97.81 still able to obtain an accuracy of 98.12%. Table 8 shows
6 98.12 the results obtained using 70% for training and 30% for
Misinformation, fake news and 3 98.78 testing the Twitter dataset with cross-validation 10 K-fold
propaganda 4 98.89 for the training and testing data. The results show that the
5 98.9 Neural network had a better result than expected due to the
6 98.99 algorithm’s complexity and the multiple statistical ways
to obtain accuracy.
97
96 96.1
96
95
94
93
CNN DNN RNN
Axis Title
Accuracy
97
96 96.1
96
95
94
93
CNN DNN RNN
Axis Title
97 96.1
96
96
95
94
93
CNN DNN RNN
Axis Title
97 96.1
96
96
95
94
93
CNN DNN RNN
Axis Title
Table 8 Results from Twitter Classifier Accuracy before the deep learning step, which includes Normalization,
dataset Stop Word Removal, and Stemming to handle the English
CNN 98.70 texts to simplify the understanding of the machine and the
RNN 98.974 possibility of classification. Deep learning techniques are
applied, including CNN, DNN, and RNN.
The result showed superiority for the CNN Algorithm
This study suggested a scheme that works to find fraud and with the highest value of F1-measure with (0.987%), fol-
discrimination through English social networks and Twitter. lowed by RNN with (96.7%), and DNN with (98.7%),
Gathering datasets are concentrated through social media, respectively, with Twitter datasets, but with CNN datasets,
including Race, Religion, Fraud, and other kinds of racism. the result showed superiority for the CNN Algorithm with
Thus, nearly 2,372 tweets and information are collected, the highest value of F1-measure with (0.983%), followed
resulting in 3674 features and 376,443 trainable parameters. by RNN with (98.974%), and DNN with (97.3%), respec-
Also, the three most important techniques of NLP are applied tively. For future work, developing a model is suggested to
40 Page 14 of 16 Social Network Analysis and Mining (2024) 14:40
be compatible with the English language by creating a vector learning algorithms for this purpose. The study specifically
and words file, enhancing the CNN model to get better per- investigates fraud and prejudice in English social media and
formance and accuracy, and enhancing the English datasets Twitter, resulting in nearly 2,372 tweets and 3674 features.
for better training. The evaluation of algorithms indicates the superiority of
The proposed method’s accuracy when utilizing CNN. the CNN Algorithm in both Twitter and CNN datasets,
The six-layer architecture used by the suggested approach showcasing high F1-measure values. Recommendations
with all datasets produced the best accuracy. Due to the for future work include developing an English-compatible
dataset’s diversity and the model’s ability to comprehend model, refining the CNN model for enhanced performance,
its contents and predict both false and accurate news, the and improving English datasets for more effective training.
disinformation dataset had the best accuracy, which was
Acknowledgements Not applicable
98.82%. Due to the intricacy of the words and content, the
actual and fake news datasets had the lowest accuracy while Author contributions Credit authorship contribution statement Laith
employing six layers. However, the model still managed to Abualigah was involved in software, resources, writing—original
obtain an accuracy of 98.3%. With and when utilizing RNN draft, supervision, methodology, conceptualization, formal analysis,
review & editing. Yazan Yehia Al-Ajlouni helped in supervision,
and LSTM is displayed and plotted in Fig. 9. With the use of methodology, conceptualization, writing—original draft. Mohammad
the six-layer design, the suggested strategy produced the best Sh. Daoud contributed to formal analysis, writing—review & editing.
accuracy across all datasets. Due to the dataset diversity and Maryam Altalhi assisted in formal analysis, writing—review & editing.
the model’s ability to comprehend the contents and forecast Hazem Migdady helped in formal analysis, writing—review & editing.
All authors read and approved the final paper.
both false and true news in the dataset, the best accuracy for
the misinformation dataset was 98.99%. The actual and false Funding Not applicable.
news datasets had the lowest accuracy while employing six
layers because of the complexity of the words and content. Data availability statements Data is available from the authors upon
reasonable request.
However, the model was still able to obtain an accuracy of
98.12%. The main limitation of the study is the algorithms Declarations
that can understand the language with different meanings
and the exact words with different meanings. Also, find Conflict of interest The authors declare that there is no conflict of in-
a method not based on one opinion and label the dataset terest regarding the publication of this paper.
with all objectives. On the other hand, the machine lacks Ethical approval This article does not contain any studies with human
understanding of emotions, especially when dealing with participants or animals performed by any of the authors.
only words.
Informed consent Informed consent was obtained from all individual
participants included in the study.
of Applied Intelligent Systems (pp. 602-610). Cham: Hidalgo JMG, Díaz AAC (2012) Combining Predation Heuristics and
Springer International Publishing.https://d oi.o rg/1 0.1 007/ Chat-Like Features in Sexual Predator Identification. In: CLEF
978-3-319-60042-0. (Online Working Notes/Labs/Workshop).
Augenstein I, Ruder S, Søgaard A (2018). Multitask learning of pair- Joachims T (1998, April). Text categorization with support vector
wise sequence classification tasks over disparate label spaces. machines: learning with many relevant features. In: European
arXiv preprint arXiv:1802.09913. conference on machine learning (pp. 137–142). Springer, Berlin,
Aurpa TT, Sadik R, Ahmed MS (2022) Abusive Bangla comments Heidelberg.
detection on Facebook using transformer-based deep learning Kanan T, Sadaqa O, Almhirat A, Kanan E (2019). Arabic light stem-
models. Soc Netw Anal Min 12(1):24 ming: a comparative study between p-stemmer, khoja stemmer,
Bahad P, Saxena P, Kamal R (2019) Fake news detection using bi- and light10 stemmer. In: 2019 Sixth International Conference on
directional LSTM-recurrent neural network. Proc Comput Sci Social Networks Analysis, Management and Security (SNAMS)
165(2019):74–82. https://doi.org/10.1016/j.procs.2020.01.072 (pp. 511-515). IEEE.https://d oi.o rg/1 0.1 109/S
NAMS.2 019.8 9318
Bin Hathlian NF, Hafez AM (2017) Subjective text mining for Eng- 42.
lish social media. Int J Semant Web Inf Syst 13(2):1–13. https:// Kanan T, Fox EA (2016) Automated English Text Classification
doi.org/10.4018/IJSWIS.2017040101 with P-Stemmer. Mach Learn Tailored News Article Taxonomy
Bohra A, Vijay D, Singh V, Akhtar SS, Shrivastava M (2018). A 114:0106
dataset of hindi-english code-mixed social media text for hate Kanan T, Sadaqa O, Aldajeh A, Alshwabka H, AlZu’bi S, Elbes M,
speech detection. In: Proceedings of the second workshop on Alia MA (2019, April). A review of natural language processing
computational modeling ofpeople’s opinions, personality, and and machine learning tools used to analyze arabic social media.
emotions in social media (pp. 36–41). In: 2019 IEEE Jordan International Joint Conference on Electrical
Boudchiche M, Mazroui A, Bebah MOAO, Lakhouaja A, Boudlal A Engineering and Information Technology (JEEIT) (pp. 622-628).
(2017) AlKhalil morpho sys 2: a robust Arabic morpho-syntac- IEEE.https://doi.org/10.1109/JEEIT.2019.8717369.
tic analyzer. J King Saud Univ-Comput Inf Sci 29(2):141–146. Kang IS, Kim CK, Kang SJ, Na SH (2012). IR-based k-nearest neigh-
https://doi.org/10.1016/j.jksuci.2016.05.002 bor approach for identifying abnormal chat users. In: CLEF
Cuadrado RRJJ, Monzón MD, Users L (2016) Analysis of the impact (Online Working Notes/Labs/Workshop).
of file formats for open data analytics efficiency: a case study Kim KH, Jeong CS (2019). Fake news detection system using article
with R. GSTF J Comput. 5(1):40–44. https://doi.org/10.5176/ abstraction. In: JCSSE 2019–16th International Joint Conference
2251-3043 on Computer Science and Software Engineering: knowledge
Dhiman P, Kaur A, Iwendi C, Mohan SK (2023) A scientometric Evolution Towards Singularity of Man-Machine Intelligence,
analysis of deep learning approaches for detecting fake news. 209–212. https://doi.org/10.1109/JCSSE.2019.8864154
Electronics 12(4):948 Klubička F, Fernandez R (2018). Examining a hate speech corpus for
Di Capua M, Di Nardo E, Petrosino A (2016). Unsupervised cyber hate speech detection and popularity prediction. arXiv preprint
bullying detection in social networks. In: 2016 23rd International arXiv:1805.04661.
conference on pattern recognition (ICPR) (pp. 432–437). IEEE. Kohavi R, Quinlan JR (2002). Data mining tasks and methods: clas-
Galal M, Madbouly MM, El-Zoghby A (2019) Classifying English text sification: decision-tree discovery. In: Handbook of data mining
using deep learning. J Theor Appl Inf Technol 97(23):3412–3422 and knowledge discovery (pp. 267–276).
Galán-García P, Puerta JGDL, Gómez CL, Santos I, Bringas PG Kratzke N (2017) The# btw17 Twitter dataset–recorded tweets of the
(2016) Supervised machine learning for the detection of troll federal election campaigns of 2017 for the 19th German Bunde-
profiles in twitter social network: application to a real case of stag. Data 2(4):34
cyberbullying. Logic J IGPL 24(1):42–53 Kwaik KA, Saad M, Chatzikyriakidis S, Dobnik S (2018). Shami: a
Galery T, Charitos E, Tian Y (2018). Aggression identification and corpus of levantine arabic dialects. In Proceedings of the eleventh
multi lingual word embeddings. In: Proceedings of the first international conference on language resources and evaluation
workshop on trolling, aggression and cyberbullying (TRAC- (LREC 2018).
2018) (pp. 74-79). Larabi Marie-Sainte S, Alalyani N, Alotaibi S, Ghouzali S, Abunadi I
Shaalan K, Siddiqui S, Alkhatib M, Abdel Monem A (2019). Chal- (2019) English natural language processing and machine learning-
lenges in arabic natural language processing. In: Computational based systems. IEEE Access 7:7011–7020
linguistics, speech and image processing for arabic language (pp. Larkey LS, Ballesteros L, Connell ME (2002). Improving stemming for
59-83).https://doi.org/10.1142/9789813229396_0003. English information retrieval: light stemming and co-occurrence
Suyanto S (2020). Synonyms-based augmentation to improve fake analysis. In: Proceedings of the 25th annual international ACM
news detection using bidirectional LSTM. In: 2020 8th Inter- SIGIR conference on research and development in information
national Conference on Information and Communication Tech- retrieval (pp. 275–282).
nology (ICoICT) (pp. 1-5). IEEE.https://doi.org/10.1109/ICoIC LSTM-RNN 2017.pdf. (n.d.).
T49345.2020.9166230 Luong MT, Le QV, Sutskever I, Vinyals O, Kaiser L (2015). Multi-task
Guellil I, Saâdane H, Azouaou F, Gueni B, Nouvel D (2021) Arabic sequence to sequence learning. arXiv preprint arXiv:1511.06114.
natural language processing: an overview. J King Saud Univ- Malmasi S, Zampieri M (2018) Challenges in discriminating profanity
Comput Inf Sci 33(5):497–507. https://doi.org/10.1016/j.jksuci. from hate speech. J Exp Theor Artif Intell 30(2):187–202
2019.02.006 Medhat W, Hassan A, Korashy H (2014) Sentiment analysis algorithms
Habash N (2007). English morphological representations for machine and applications: a survey. Ain Shams Eng J 5(4):1093–1113
translation. In: English computational morphology (pp. 263–285). Mitchell TM (2006) The discipline of machine learning, vol 9. Car-
Springer, Dordrecht. negie Mellon University, School of Computer Science, Machine
Haidar B, Chamoun M, Serhrouchni A (2018). English cyberbullying Learning Department, Pittsburgh
detection: using deep learning. In: 2018 7th International Confer- Mustafa M, Eldeen AS, Bani-Ahmad S, Elfaki AO (2017) A com-
ence on Computer and Communication Engineering (ICCCE) (pp. parative survey on english stemming: approaches and challenges.
284–289). IEEE. Intell Inf Manag 09(02):39–67. https://doi.org/10.4236/iim.2017.
92003
40 Page 16 of 16 Social Network Analysis and Mining (2024) 14:40
Nobata C, Tetreault J, Thomas A, Mehdad Y, Chang Y (2016). Abusive information systems in Industry 40. Enterprise Inform Syst
language detection in online user content. In: Proceedings of the 16(10–11):1694–1710
25th international conference on world wide web (pp. 145–153). Schmidt A, Wiegand M (2017). A survey on hate speech detection
Node XL (2021). Your social network analysis tool for social media. using natural language processing. In: Proceedings of the fifth
Available: https://www.smrfoundation.org/nodexl/. Last accessed international workshop on natural language processing for social
2022. media (pp. 1-10).
Park JH, Shin J, Fung P (2018). Reducing gender bias in abusive lan- Shaalan K, Siddiqui S, Alkhatib M, Monem AA (2018). Computational
guage detection. arXiv preprint arXiv:1808.07231. linguistics, speech and image processing for arabic language.
Peng H, Thomson S, Smith NA (2017). Deep multitask learning for Smola A, Vishwanathan SVN (2008) Introduction to machine learning.
semantic dependency parsing. arXiv preprint arXiv:1704.06855. Cambridge University, UK 32(34):2008
Qawasmeh E, Tawalbeh M, Abdullah M (2019). Automatic identifica- Soral W, Bilewicz M, Winiewski M (2018) Exposure to hate speech
tion of fake news using deep learning. In: 2019 Sixth international increases prejudice through desensitization. Aggressive Behav
conference on social networks analysis, Management and Security 44(2):136–146
(SNAMS) (pp. 383-388). IEEE.https://doi.org/10.1109/SNAMS. Tarabasz A (2019) Corporate social responsibility in times of internet
2019.8931873 (in) security. In Responsible organizations in the global context,
Ross B, Rist M, Carbonell G, Cabrera B, Kurowsky N, Wojatzki M Palgrave Macmillan, Cham
(2017). Measuring the reliability of hate speech annotations: The Tokunaga RS (2010) Following you home from school: A critical
case of the european refugee crisis. arXiv preprint arXiv:1701. review and synthesis of research on cyberbullying victimization.
08118. Comput Hum Behav 26(3):277–287
Ruder S, Bingel J, Augenstein I, Søgaard A (2019). Latent multitask Vilariño D, Castillo E, Pinto D, Olmos I, León S (2012) Information
architecture learning. In: Proceedings of the AAAI Conference on retrieval and classification based approaches for the sexual preda-
Artificial Intelligence 33(01): 4822–4829. tor identification. Faculty of Computer Science, Mexico
Saberi B, Saad S (2017) Sentiment analysis or opinion mining: a Waseem Z, Hovy D (2016). Hateful symbols or hateful people? predic-
review. Int J Adv Sci Eng Inform Technol 7:1660–1667 tive features for hate speech detection on twitter. In Proceedings of
Saeed S, Suayyid SA, Al-Ghamdi MS, Al-Muhaisen H, Almuhaideb the NAACL student research workshop (pp. 88–93).
AM (2023) A systematic literature review on cyber threat intel- Wylde V, Rawindaran N, Lawrence J, Balasubramanian R, Prakash E,
ligence for organizational cybersecurity resilience. Sensors Jayal A, Platts J (2022) Cybersecurity, data privacy and block-
23(16):7273 chain: a review. SN Comput Sci 3(2):127
Sallam RM, Mousa HM, Hussein M (2016) Improving Arabic text
categorization using normalization and stemming techniques. Int Publisher's Note Springer Nature remains neutral with regard to
J Comput Appl 135(2):38–43 jurisdictional claims in published maps and institutional affiliations.
Sanguinetti M, Poletto F, Bosco C, Patti V, Stranisci M (2018, May).
An italian twitter corpus of hate speech against immigrants. In: Springer Nature or its licensor (e.g. a society or other partner) holds
Proceedings of the eleventh international conference on language exclusive rights to this article under a publishing agreement with the
resources and evaluation (LREC 2018). author(s) or other rightsholder(s); author self-archiving of the accepted
Sastrawan IK, Bayupati IPA, Arsa DMS (2022) Detection of fake news manuscript version of this article is solely governed by the terms of
using deep learning CNN–RNN based methods. ICT Express such publishing agreement and applicable law.
8(3):396–408
Saura JR, Ribeiro-Soriano D, Palacios-Marqués D (2022) Evalu-
ating security and privacy issues of social networks based