Manuscript Offprint

arXiv:2610.39323

Class-aware Latent Attention Replay (CLAR): Class Incremental Hazard Diagnosis for Resilient AI in the Manufacturing Industrial Internet

Avranshu Mahanty, Ran Jin, Yingyan Zeng

Abstract

Artificial Intelligence (AI) systems provide critical computation services in the Manufacturing Industrial Internet (MII), and their resilience depends on timely diagnosis of hazards across the data, AI pipeline, and cyber-physical layers. During operation, new hazard types keep emerging with only a few samples each, hazards co-occur, and the diagnosis model runs on memory-constrained computation nodes. Replay-based class-incremental learning (CIL) can learn new hazard classes while revisiting a small memory of past samples, but existing methods assume single-label, balanced streams, store high-dimensional raw samples, and select them independently of the classifier. We propose Class-aware Latent Attention Replay (CLAR), which combines a dual buffer that stores mostly compact latent representations with a few raw samples, an Attention Leverage Score (ALS) that upper-bounds the classifier logit and guides class-balanced reservoir sampling, and an exponential-moving-average teacher that slows latent-space drift. For an idealized buffer model, we prove that the buffer is class-balanced and follows an ALS-weighted class distribution, and that below a critical per-class capacity, ALS-guided replay has a lower replay-gradient error than class-balanced uniform replay. In the case study, On hazard diagnosis data from an MII testbed, CLAR achieves the highest mean average weighted F1 score among the evaluated replay methods with the same buffer size.

1 Introduction

The Manufacturing Industrial Internet (MII) connects manufacturing equipment, physical processes, systems, and networks through ubiquitous sensors, actuators, and computing units [1,2]. The data collected via the MII enable AI models that deliver computation services such as quality modeling, process variation analysis, and fault diagnosis [3]. In this context, an AI system consists of three interconnected layers [2,4]: (i) the data layer, i.e., the manufacturing data collected via the MII; (ii) the AI pipeline layer, where the data are processed by deployed AI pipelines, such as data augmentation, standardization, and deep neural network (DNN) classifiers [5]; and (iii) the

cyber-physical layer, i.e., the Fog-Cloud computing infrastructure that supports communication and computation. Each execution of an AI pipeline on a batch of data at a computation node constitutes a computation task, e.g., predicting the quality of the products produced by one machine.

Manufacturing decisions, such as accepting a printed part or adjusting a process setting, rely on the outputs of these computation tasks, so the AI system has to deliver reliable computation services continuously throughout production. Hazards in any of the three layers threaten this reliability. Sensor contamination and low signal-to-noise ratio corrupt the data layer, model singularity destabilizes the AI pipeline layer, and fog node or communication failures disrupt the cyber-physical layer [2]. The resulting performance degradation leads to incorrect quality predictions, faulty process decisions, and economic losses. AI resilience refers to the ability of the AI system to withstand, respond to, and recover from such hazards [2,6]. Recovery requires a mitigation action that matches the root cause, so accurate root-cause diagnosis is the prerequisite for resilience. Diagnosis can use information that the MII already collects after each computation task: the supervised learning performance of the deployed pipelines and the runtime metrics of the computation node, such as CPU utilization and memory consumption [2]. Hazard diagnosis therefore becomes a multimodal, multi-label classification problem over these two modalities.

Diagnosis models of this kind are trained offline on a fixed set of hazard types. In operation, the MII keeps changing: new machines, process settings, and software updates introduce hazard types that were absent from the training data, and known hazard types reappear later. A resilient AI system thus needs a diagnosis model that keeps learning from the stream of computation tasks, which raises five challenges. (i) New hazard classes emerge over time and previously seen classes recur, and retraining from scratch on all historical data is computationally prohibitive. (ii) Normal operation dominates the stream, so each hazard class has only a few samples. (iii) Several hazards can affect the same computation task, making the problem multi-label. (iv) The runtime metrics are high-dimensional multivariate time series, which, together with the tabular performance metrics, form multimodal samples. (v) The diagnosis model runs on resource-constrained computation nodes, which strictly limits its memory.

Class-Incremental Learning (CIL) addresses the first challenge by updating a model with new classes as they appear [7,8]. Its central difficulty is catastrophic forgetting: training on new classes overwrites the knowledge of earlier classes and degrades their accuracy [9]. Replay-based methods counter forgetting by storing a small memory of past samples and revisiting them while learning new classes [10,11]. Three limitations restrict their use for hazard diagnosis in the MII. First, most methods assume single-label streams with balanced and sufficient samples per class, while hazard data are multi-label, highly imbalanced, and scarce. Second, they store past samples in raw form; a raw sample in our case study contains about 2.5×1062.5 \times 10^{6} values, so a fixed memory budget holds only a few exemplars per hazard class. Third, they select samples to store by random, class-count, gradient, or class-mean criteria, which are independent of the class-specific parameters that the classifier uses to make its decisions.

To address these limitations, we propose Class-aware Latent Attention Replay (CLAR), a class-incremental hazard diagnosis framework for AI systems in the MII. The key idea of CLAR is to keep the memory of past hazards predominantly in the compact latent space of the diagnosis model and to let the class-specific attention parameters of the classifier decide which samples are worth remembering. The contributions of this work are as follows.

• We formulate class-incremental hazard diagnosis for AI systems in the MII as a multi-label, multimodal CIL problem over a sequential stream of tasks with recurring classes, severe class imbalance, and a strict memory budget.

• We propose a latent-dominant dual replay buffer that stores many compact latent representations and a few raw samples per hazard class, which multiplies the number of buffer slots per class within the same memory budget.

• We propose the Attention Leverage Score (ALS), an attention-induced Mahalanobis-type norm that upper-bounds the magnitude of the classifier logit, and use it to tilt class-balanced reservoir sampling toward samples that strongly drive the classifier under imbalanced, multi-label streams.

• We show that ALS-guided sampling keeps a class-balanced buffer whose content follows an ALS-weighted class distribution, decompose its replay-gradient error into sampling variance and selection bias, and characterize, for an idealized model, the per-class capacities below which it has a lower replay-gradient error and a smaller upper bound on the expected squared margin deviation than class-balanced uniform replay.

  • We evaluate CLAR on hazard data from an MII testbed, where it achieves the highest mean average weighted F1 score among the evaluated methods with a smaller configured buffer.

The remainder of this paper is organized as follows. Section 2 reviews CIL, replay-based CIL, and few-shot CIL. Section 3 formulates the problem and presents CLAR. Section 4 analyzes ALS-guided sampling theoretically. Section 5 reports the case study, and Section 6 concludes the paper.

References (41)

  • Predictive offloading in mobile-fog-cloud enabled cyber-manufacturing systems
  • Fair: Facilitating artificial intelligence resilience in manufacturing industrial internet (opens arXiv in a new tab)
  • Artificial intelligence in advanced manufacturing: Current status and future outlook
  • AdaPipe: A recommender system for adaptive computation pipelines in cyber-manufacturing computation services
  • Deep neural network pipelines for multivariate time series classification in smart manufacturing
  • Infrastructure resilience curves: Performance measures and summary metrics
  • A continual learning survey: Defying forgetting in classification tasks
  • Class-incremental learning: Survey and performance evaluation on image classification
  • Catastrophic interference in connectionist networks: The sequential learning problem
  • Continual learning with tiny episodic memories
  • icarl: Incremental classifier and representation learning
  • Three types of incremental learning
  • Few-shot class-incremental learning for system-level fault diagnosis of wind turbine
  • The stability-plasticity dilemma: Investigating the continuum from catastrophic forgetting to age-limited learning effects
  • Large scale incremental learning
  • Learning a unified classifier incrementally via rebalancing
  • Online continual learning in image classification: An empirical survey
  • Rainbow memory: Continual learning with a memory of diverse samples
  • Imbalanced continual learning with partitioning reservoir sampling
  • Progressive Neural Networks
  • Lifelong learning with dynamically expandable networks (opens arXiv in a new tab)
  • Proceedings of the national academy of sciences, 114(13):3521–3526, 2017
  • Continual learning through synaptic intelligence
  • Learning without forgetting
  • Distilling the Knowledge in a Neural Network
  • Online continual learning from imbalanced data
  • Gradient based sample selection for online continual learning
  • Online continual learning with maximal interfered retrieval
  • Online class-incremental continual learning with adversarial Shapley value
  • Latent replay for real-time continual learning
  • REMIND your neural network to prevent catastrophic forgetting
  • A survey on few-shot class-incremental learning
  • Prototypical networks for few-shot learning
  • Meta-learning with latent embedding optimization (opens arXiv in a new tab)
  • Few-shot class-incremental learning by sampling multi-phase tasks
  • Multimodal deep learning
  • Multimodal machine learning: A survey and taxonomy
  • Auto-Encoding Variational Bayes
  • Mean teachers are better role models: Weight-averaged consistency targets improve semi-supervised deep learning results
  • Gradient episodic memory for continual learning
  • Riemannian walk for incremental learning: Understanding forgetting and intransigence