scieee AI-readable full text Open interactive document viewer

Real-Time Fake News Detection and IoT Alert Dissemination using DistilBERT and MQTT

B, Divya; M, Pavan; S. V., Sheela

Abstract

This paper presents a real-time fake news detection framework integrating DistilBERT-driven semantic analysis with MQTT-based IoT alert dissemination. The system classifies misinformation with 94.3% accuracy and issues physical alerts within 0.35 seconds. The architecture combines transformer-based language understanding with lightweight MQTT broadcasting, enabling instant alert notifications to connected IoT devices. This integrated approach enhances intelligent content moderation, rapid misinformation response, and scalable distributed alerting across digital networks.

Full text

Real-Time Fake News Detection and IoT Alert Dissemination using DistilBERT and MQTT Divya B Department of Information Science and Engineering BMS College of Engineering, Bengaluru, India divy[email protected] Pavan M Department of Information Science and Engineering BMS College of Engineering, Bengaluru, India pav[email protected] Dr. Sheela S. V. Professor, Department of ISE BMS College of Engineering, Bengaluru, India ssv[email protected] Abstract—The rapid proliferation of misinformation on digital platforms poses a significant threat to public stability and information integrity. Traditional detection methods often lack real-time response mechanisms to physically alert moderators. This paper proposes a novel “Real-Time Fake News Detection System” that integrates Deep Learning with the Internet of Things (IoT). The system utilizes the DistilBERT (Bidirectional Encoder Representations from Transformers) model to analyze news content with high semantic accuracy. Upon detecting highprobability fake news, the system triggers an immediate automated response via the MQTT protocol, broadcasting alerts to connected IoT devices and moderator dashboards. Experimental results demonstrate that the system achieves a classification accuracy of 94.3% and an average alert dissemination latency of 0.35 seconds. By synthesizing transformer-based natural language understanding with IoT communication, this framework creates a powerful solution for automated content moderation and distributed public safety alerting. Index Terms—Fake News Detection, DistilBERT, Internet of Things (IoT), MQTT, Natural Language Processing, Real-Time Monitoring. I. Introduction The exponential growth of digital information across social media platforms, online news portals, and messaging services has transformed the way information is consumed and disseminated. While this has enabled the democratization of knowledge, it has also created an environment vulnerable to misinformation and fake news. Conventional fact-checking systems are often manual and slow, frequently detecting misinformation only after it has already reached large audiences and caused potential harm. Furthermore, many existing detection systems rely on shallow machine learning algorithms that depend on manually engineered features and lack deep contextual understanding. To address this pressing issue, the “Real-Time Fake News Detection System using BERT and IoT Integration” was developed. This project integrates advanced Natural Language Processing (NLP) techniques with Internet of Things (IoT) frameworks to achieve real-time monitoring, detection, and alerting of misinformation. The solution leverages DistilBERT, a distilled version of BERT, as the core classification model to analyze and categorize textual content as either “Real” or “Fake”. Unlike traditional rule-based systems, this model utilizes deep contextual embeddings to interpret textual nuances and semantic relationships. Crucially, the system incorporates an IoT-based alert mechanism through MQTT (Message Queuing Telemetry Transport), enabling the immediate dissemination of alerts across multiple connected devices such as content moderator stations and broadcast panels. This creates an integrated ecosystem where artificial intelligence interacts with IoT technologies to enable proactive misinformation control. II. Literature Survey The development of this system builds upon significant research in both AI-driven text analysis and IoT communication architectures. Twaha and Arfin (2025) presented an AI-driven framework for real-time fake news detection, emphasizing the limitations of traditional classifiers like logistic regression when dealing with unstructured data [1]. Their work highlighted the necessity of Context-Aware Embeddings, which influenced our selection of the BERT architecture to capture the deep semantic meaning of news articles. In the domain of IoT integration, Zhang, Zhang, and Sun (2025) developed a real-time public safety system using sensor networks [2]. Their work demonstrated how IoT frameworks could achieve high-speed data transmission and device coordination during critical incidents. This inspired the architectural design of our communication layer, particularly the use of MQTT for lightweight message exchange to minimize latency. Furthermore, Ortiz-Garces et al. (2025) focused on using Edge AI for fault detection, revealing that deploying AI at the network edge significantly improves responsiveness [3]. Our proposed system adopts a similar philosophy by performing inference at the application layer before propagating alerts, ensuring that detection leads directly to action without significant delay. III. System Architecture and Design A. Architectural Overview The system is designed as a modular, event-driven pipeline that couples a transformer-based NLP module with an MQTTenabled communication fabric. The architecture is separated into clear functional layers: the User Interface Layer (Streamlit), the Inference Layer (DistilBERT), and the Communication Layer (MQTT). Fig. 1. System Architecture Diagram showing the flow from User Input to AI Inference and MQTT Alert Propagation. B. Module Description •Inference Layer: This layer loads the fine-tuned DistilBERT classifier. It performs preprocessing steps such as tokenization and padding, executes model inference using PyTorch, and computes softmax probabilities to determine the class label and confidence score. •Communication Layer (MQTT): This layer manages the lifecycle of the MQTT client. It connects to the broker, subscribes to device response topics, and publishes the fake_news_alert payload when misinformation is detected. •Device Simulation Layer: To demonstrate the IoT capability, the system maintains a registry of simulated devices. Each device tracks its status (Online/Offline), heartbeat, and last received alert, allowing for a realistic simulation of a distributed network. •Visualization Layer: Visual components include Plotly charts for confidence gauges and Folium maps for geospatial device tracking. This layer reads the session state to present a real-time operational picture to the administrator. IV. Results and Discussion A. Model Performance The quantitative evaluation of the DistilBERT model was conducted using a test dataset. The model achieved a testing accuracy of 94.3% and an F1-Score of 93.8%. The inference time averaged 1.82 seconds per article on a CPU environment, confirming the model’s efficiency for real-time applications. TABLE I Performance Metrics of DistilBERT Model Metric Training (%) Validation (%) Test (%) Accuracy 96.2 94.8 94.3 Precision 95.1 93.7 93.5 Recall 96.8 94.4 94.1 F1-Score 95.9 94.0 93.8 B. IoT System Performance The IoT communication layer was tested for latency and reliability. The average latency between the publication of an alert and the acknowledgment by simulated devices was recorded at 0.35 seconds. The system maintained a 100% message success rate and 99.8% connection stability during continuous operation testing. C. Visualization and Dashboard The dashboard successfully visualized the real-time status of the network. Figure 2 shows the interface classifying an article and displaying the confidence score. Figure 3 illustrates the geospatial tracking, where device markers turn orange to indicate active alerts upon receiving the MQTT message. Fig. 2. Streamlit User Interface displaying detection result. Fig. 3. Geospatial Map Visualization of device locations. V. Conclusion The Real-Time Fake News Detection and IoT Alert System successfully demonstrates the integration of advanced AIdriven language analysis with robust IoT communication. The system achieved a high classification accuracy of 94.3% and demonstrated the ability to disseminate physical alerts with subsecond latency. By merging transformer-based semantic understanding with event-driven MQTT protocols, the project offers a practical, scalable, and intelligent framework for combating misinformation in the digital age. Future enhancements will focus on deploying the inference engine on edge devices and integrating Explainable AI (XAI) to provide transparency in classification decisions. Acknowledgment The authors express their sincere gratitude to Dr. Sheela S. V., Professor, Department of Information Science and Engineering, B.M.S. College of Engineering, Bengaluru, for her invaluable guidance and support throughout this project. References [1] U. Twaha and Y. Arfin, “An AI-Driven Framework for Real-Time Fake News Detection,” 2025. [2] H. Zhang, R. Zhang, and J. Sun, “Developing real-time IoT-based public safety alert and emergency response systems,” Scientific Reports, vol. 15, no. 1, 29056, 2025. [3] I. Ortiz-Garces, W. Villegas-Ch, and S. Luj´ an-Mora, “Implementation of edge AI for early fault detection in IoT networks,” Discover Internet of Things, vol. 5, no. 1, 108, 2025. [4] N. Akter, et al., “Advanced Detection and Forecasting of Fake News on Social Media Platforms,” Journal of Posthumanism, vol. 5, no. 6, 2025. [5] P. Panindre, et al., “Artificial intelligence-integrated autonomous IoT alert system,” IEEE Internet of Things Journal, 2025.