## 3 Edge Artificial Intelligence
### AI for Security
Generative AI (GAI) produces original content by analyzing and learning patterns from existing data--generating text, images, videos, or code that resemble the training data without exactly replicating it [111]. ML algorithms can be broadly classified into three categories: supervised learning, unsupervised learning, and reinforcement learning [112; 113; 114; 115]. * Supervised learning: ML algorithms process labeled training data to learn a function capable of mapping new data samples. Supervised learning is further categorized into classification and regression tasks. Classification involves mapping inputs to discrete values, whereas regression maps inputs to continuous values. Examples of classification-based supervised ML methods include Support Vector Machines (SVMs) and random forests, while linear regression and logistic regression are commonly used for regression tasks. * Unsupervised learning: This detects patterns within input data without the need for labeled training data. It is widely applied in enhancing network security functions such as authentication, access control, anti-jamming strategies, and malware detection. Unsupervised learning is typically divided into two main categories: clustering and dimensionality reduction. Clustering organizes similar data instances based on shared features, while dimensionality reduction aims to reduce the number of features in a dataset while retaining as much relevant information as possible. Common unsupervised ML techniques include k-means and k-nearest neighbors (KNN) for clustering and principal component analysis (PCA) and singular value decomposition (SVD) for dimensionality reduction. * Reinforcement learning (RL): This is a feedback-driven machine learning approach that enables learning through trial and error. In IoT networks, RL helps nodes autonomously make decisions for various networking tasks such as routing, scheduling, and resource allocation. The RL agent learns environmental dynamics solely from collected data without any prior knowledge to determine the best actions for achieving  
Figure 8: AI classification. networking objectives. Common RL techniques include Monte Carlo and Temporal Difference (TD) learning for prediction, as well as SARSA and Q-learning for control. [PERSON] et al. introduced a mobile edge computing (MEC)-based anomaly detection framework that utilizes AI to enhance the efficiency of anomaly detection in cellular networks. Their approach employs a deep Convolutional Neural Network (CNN) with fewer parameters compared to a feedforward deep neural network (DNN), achieving an accuracy range of 70% to 96% [116]. [PERSON] et al. proposed a Dynamic Trust Security Approach (DTSA) that integrates AI to strengthen security and trust management for Industrial Internet of Things (IIoT) devices in edge computing environments [117]. Their AI model evaluates key metrics, including Mean Time Between Failures (MTBFs), Packet Loss Rate (PLS), Response Time (RT), and Energy Efficiency (EE), to assign trust scores to IIoT devices. [PERSON] et al. introduced an advanced intrusion detection system (IDS) to improve the security of Intelligent Transportation Systems (ITSs). This framework combines AI and EC to identify cyber threats in vehicular networks by leveraging statistical thresholds and deep learning techniques. It employs Convolutional Neural Networks (CNNs) to model normal vehicular behavior and detect anomalies using Reconstruction Error Analysis, achieving an accuracy range of 97.5% to 100% [118]. [PERSON] et al. developed a security framework called Authentication, Detection, and Defense for Secure EC (A2 DSEC), which operates through three key modules: authentication, detection, and defense. This framework combines blockchain-based authentication, anomaly detection, and proactive defense mechanisms, effectively identifying DDoS and injection attacks within 1.1 to 1.5 s [119].