A chemical process multi-step fault prediction method based on knowledge enhanced graph Transformer

By combining knowledge of chemical process mechanisms and the graph Transformer model, the spatial coupling characteristics and temporal dependencies between variables in chemical processes are extracted, solving the problem of fault prediction under complex operating conditions in chemical processes and achieving higher accuracy and stability in multi-step prediction.

CN122333338APending Publication Date: 2026-07-03HENAN UNIVERSITY

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
HENAN UNIVERSITY
Filing Date
2026-04-02
Publication Date
2026-07-03

AI Technical Summary

Technical Problem

Existing chemical process fault prediction methods struggle to accurately model the coupling relationships between variables under complex operating conditions and lack mechanistic constraints, resulting in insufficient prediction accuracy and stability. In particular, error accumulation and lag are prone to occur in multi-step prediction scenarios.

Method used

We employ a knowledge-enhanced graph Transformer approach, which combines mechanistic knowledge of chemical processes to construct a graph convolutional network (GCN). The GCN extracts spatial coupling features between variables and combines them with the Transformer module to perform time-dependent modeling, thereby enabling multi-step trend prediction of chemical processes.

Benefits of technology

It significantly improves the ability of chemical processes to identify and warn of faults under complex operating conditions, enhances the interpretability and stability of the model, and improves the prediction accuracy and adaptability of multivariable systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122333338A_ABST
    Figure CN122333338A_ABST
Patent Text Reader

Abstract

This invention proposes a multi-step fault prediction method for chemical processes based on a knowledge-enhanced graph Transformer. The steps are as follows: constructing a multivariate time series and processing it with a sliding time window to obtain input samples; constructing a mechanism constraint graph and assigning weights to node pairs to form a prior adjacency matrix; constructing a learnable adjacency matrix based on the input samples and fusing it with the prior adjacency matrix; inputting the node feature matrix into a graph convolutional network to obtain a spatial feature matrix; adding a position encoding vector to the input samples and inputting them into the Transformer module to obtain the temporal dependency feature matrix for each time step; concatenating the inputs into a gating network and performing weighted fusion to obtain a fused feature matrix; using the obtained fused feature matrix to generate the next prediction, and using the prediction results and historical sequences for inference to achieve multi-step prediction. This invention significantly improves the early fault identification and warning capabilities of industrial processes under complex operating conditions while maintaining model interpretability and operational stability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the technical field of industrial process failure prediction, and in particular to a multi-step failure prediction method for chemical processes based on knowledge-enhanced graph Transformer. Background Technology

[0002] In modern chemical production, with the continuous expansion of plant scale, the increasing complexity of process systems, and the continuous improvement of automation and informatization levels, chemical plants typically exhibit multivariable, high-dimensional, strongly coupled, and significantly nonlinear operating characteristics. Various process variables form complex interrelationships through material transfer, energy exchange, and control actions, and their dynamic evolution exhibits significant time-varying and uncertainties. Once a critical variable becomes abnormal, the fault often propagates along the variable coupling path throughout the system. If it cannot be identified and predicted in a timely manner, it will severely impact the safe operation and production efficiency of the plant. In chemical processes, the coupling relationships between variables typically possess highly nonlinear, dynamic, and multi-scale characteristics, making it difficult to accurately model these complex relationships using traditional methods.

[0003] Traditional methods for monitoring and diagnosing chemical processes mainly include mechanistic modeling and statistical analysis. Mechanism-based modeling relies on precise descriptions of material balance, energy balance, and control mechanisms. While it offers good physical interpretation, it often struggles to establish complete, accurate, and generalizable mathematical models in real-world industrial scenarios, especially when faced with high-dimensional variables, strong nonlinearity, and complex operating conditions. Statistical analysis methods, on the other hand, mine statistical correlations between variables from historical data. While the modeling process is relatively simple, it typically relies on linear assumptions or low-order statistical characteristics, making it difficult to characterize the complex dynamic coupling relationships in chemical processes and limiting its adaptability to nonlinear changes and varying operating conditions.

[0004] In recent years, with the improvement of computing power, deep learning methods have been widely used in industrial process modeling, state prediction, and fault early warning due to their powerful nonlinear fitting capabilities and automatic feature extraction capabilities. However, most existing deep learning methods mainly adopt a pure data-driven modeling approach, often ignoring the inherent physical structure and mechanism constraints of chemical processes. This leads to problems such as insufficient interpretability, sensitivity to changes in operating conditions, unstable prediction results, and limited early fault identification capabilities in practical applications, even though the models may have high fitting accuracy on specific datasets.

[0005] Furthermore, existing time series forecasting models primarily focus on dependency modeling along the time dimension, failing to adequately consider the topological structure, control relationships, and energy and material coupling mechanisms among process variables. This makes it difficult for the models to fully reflect the inherent interconnected structure of multivariable systems, thus limiting forecast accuracy and the reliability of fault early warning. Particularly in multi-step forecasting scenarios, the models are prone to error accumulation and forecast lag, making it difficult to meet the practical needs of complex chemical processes for early warning and trend inference.

[0006] Therefore, there is an urgent need for a fault prediction method that can combine the knowledge of chemical process mechanisms with the advantages of data-driven models. While making full use of historical operating data, it is necessary to introduce process prior constraints to enhance the structural rationality and stability of the model, thereby achieving accurate modeling of complex multivariable chemical process systems and multi-step prediction for the future. Summary of the Invention

[0007] To address the technical problems of traditional data-driven models in existing chemical process fault prediction methods, such as complex variable coupling, lack of mechanistic constraints, limited feature extraction capabilities, and insufficient prediction lag and stability, this invention proposes a knowledge-enhanced graph Transformer-based multi-step fault prediction method for chemical processes (KGTN). This method explicitly introduces process mechanism knowledge from the prior process structure into the graph modeling framework to construct a physically meaningful variable topology and designs a learnable topology update mechanism to strengthen the expression of key dependencies between process variables. The graph convolutional network (GCN) of this invention learns potential dependencies between variables under knowledge-enhanced topology constraints, while simultaneously performing relation propagation and structure updates; the Transformer module models and reconstructs historical operating patterns in the sequence dimension. These two types of modules act on spatial and temporal information sources respectively and participate in multi-step trend prediction through a fusion mechanism, thereby avoiding the dominance of a single structure in the modeling process. This invention significantly improves the early fault identification and warning capabilities of industrial processes under complex operating conditions while maintaining model interpretability and operational stability. To achieve the above objectives, the technical solution of this invention is implemented as follows:

[0008] A multi-step fault prediction method for chemical processes based on knowledge-enhanced graph Transformer, the steps of which are as follows:

[0009] Step 1: Collect multi-source time series data from the chemical production process to construct a multivariate time series, normalize each process variable, and obtain the input sample through a sliding time window.

[0010] Step 2: Select process variables based on chemical process mechanism knowledge, construct a mechanism constraint diagram according to the control relationship, energy transfer relationship and material transfer relationship between process variables, assign corresponding weights to node pairs according to different coupling types, and form a prior adjacency matrix;

[0011] Step 3: Construct a node feature matrix based on the input samples, construct a learnable adjacency matrix based on the node feature matrix, and fuse the learnable adjacency matrix with the prior adjacency matrix to obtain a knowledge-enhanced adjacency matrix; under the constraint of the knowledge-enhanced adjacency matrix, input the node feature matrix into the graph convolutional network, and extract the coupling features between process variables through feature propagation and aggregation operations to obtain the spatial feature matrix;

[0012] Step 4: After adding a position encoding vector to the input sample, input it into the Transformer module to obtain the temporal dependency feature matrix for each time step;

[0013] Step 5: Concatenate the spatial feature matrix extracted by the graph convolutional network with the temporal dependency feature matrix extracted by the Transformer module, and input the concatenation into the gating network. Calculate the dynamic fusion weights using learnable parameters, and perform weighted fusion of the spatial feature matrix and the temporal dependency feature matrix based on the dynamic fusion weights to obtain the fused feature matrix.

[0014] Step 6: Use the fusion feature matrix obtained at the current moment to generate the next prediction. Use the prediction results together with the historical sequence for inference in subsequent time steps. A multi-step prediction and inference of the failure evolution trend of chemical process is realized through a recursive sliding window mechanism.

[0015] Preferably, the process vector is selected from key monitoring quantities that reflect the transfer of materials and energy, covering multiple physical quantities such as flow rate, liquid level, valve position, and cooling rate;

[0016] Record the formation time of each process vector according to a fixed sampling period. Multivariate time series ;in, Indicates the first A process variable at time The sampled values; This represents the total number of process variables.

[0017] For the first A process variable at time Sample values Normalization is performed, transforming it into a form with zero mean and unit variance, to obtain the th... A process variable at time 1 Normalized time series data ;

[0018] Use a sliding time window to view the current time Normalized time series data of each process variable Normalized time series Processing is performed to obtain the time. Input samples ;in, The length of the sliding time window. They represent time respectively -L+1、 -L+2 normalized time series;

[0019] No. The sliding window sample is from the first From the moment to the first The continuous moments Input samples consisting of normalized observation vectors ;in, Number the sliding window samples. Indicates by the first From the moment to the first The continuous moments The input sample consists of a normalized observation vector;

[0020] Constructed mechanism constraint graph ;in, A set of nodes representing process variables, each node For a given process variable, the edge set Indicates the physical relationship between process variables;

[0021] The prior adjacency matrix , among which, element Representation Nodes With nodes Physical coupling strength: When there is an energy transfer, material flow, or control relationship between two process variables, the element Otherwise element .

[0022] Preferably, the normalized observation sequence of each process variable within the current sliding time window is used as the feature vector of the corresponding node to form a node feature matrix. ;

[0023] The learnable adjacency matrix is: ;in, For linear mapping weights, This represents the total number of process variables. This represents the input feature dimension of each node. This represents the feature dimension after linear mapping. Indicates matrix transpose;

[0024] Knowledge-enhanced adjacency matrix ;in, Use the Sigmoid activation function;

[0025] Enhancing the adjacency matrix with knowledge With the identity matrix Add them together and enhance the adjacency matrix based on the knowledge. The degree matrix of each node is constructed by considering the connections between the nodes. Based on degree matrix Knowledge-enhanced adjacency matrix After performing symmetric normalization, the normalized adjacency matrix is ​​obtained: ;

[0026] Based on normalized adjacency matrix , node feature matrix Input a graph convolutional network, extract spatial coupling features through multiple layers of graph convolution operations, the first... The process of node feature propagation and aggregation in a layer is represented as follows: ;in, Indicates the first The node feature matrix of the layer, Indicates the first The node feature matrix of the layer, The weight matrix is ​​a learnable matrix. It is a non-linear activation function;

[0027] After L g After the layer graph convolution operation, each node The final feature vector It includes both the intrinsic state information of the i-th process variable and incorporates the upstream and downstream influences within the neighborhood; the resulting spatial feature matrix .

[0028] Preferably, the method for adding the position encoding vector is as follows:

[0029] The obtained number A sliding window sample ;in, Indicates the number of process variables. Indicates the length of the sliding time window. Indicates the first In the nth window sample The normalized time series sequence corresponding to each time point , ;

[0030] By introducing a position encoding vector into the normalized time series at each time step, the enhanced time step input representation is obtained: ;in, Indicates the first The position encoding vector corresponding to each time step.

[0031] Preferably, the method for obtaining the temporal dependency feature matrix at each time step is as follows: performing linear projection and layer normalization operations on the time step input representation after adding the position encoding vector to obtain the linearly transformed embedded features. The embedded feature sequence is constructed from the embedded features. The multi-head self-attention mechanism of the Transformer module processes the embedded feature sequence to obtain the output features of each attention head. The output features of all attention heads are concatenated and fused through the output mapping matrix to obtain the output features of the multi-head self-attention mechanism. After the output features of the multi-head self-attention mechanism are processed by the feedforward network, residual connection and layer normalization, the output feature matrix obtained is the temporal dependency feature matrix of each sliding window sample.

[0032] Preferably, the embedded features after linear transformation ;in, For the mapping weight matrix, For bias vectors, Indicates the embedding feature dimension. Presentation layer normalization operation;

[0033] The embedded feature sequence ;

[0034] embed feature sequences Input multi-head self-attention mechanism, through the first The query projection matrix, key projection matrix, and value projection matrix corresponding to the attention head are obtained to obtain the first attention head. A query matrix for each attention head Key matrix Sum matrix The relevance weights between each time step are calculated using the query matrix and the key matrix, and then applied to the value matrix. , obtained the Output features of each attention head ;in, This is the scaling factor;

[0035] Output characteristics of multi-head self-attention mechanisms: ;in, Indicates the number of heads of attention. This represents the output mapping matrix. Indicates a splicing operation;

[0036] No. The temporal dependency feature matrix obtained after modeling the temporal features of the sliding window samples using the Transformer module is as follows: ;

[0037] Among them, the output feature matrix The row vector Indicates the first The window sample at the th The temporal dependency feature vector corresponding to each time step.

[0038] Preferably, the method for calculating the dynamic fusion weights is as follows: The temporal dependency feature matrix obtained from the Transformer module in step four... Perform time-dimensional mapping to obtain the aligned temporal dependency feature matrix The spatial feature matrix extracted by the convolutional network in step three With time-dependent feature matrix The joint input is formed by concatenating the features along the dimension. Dynamic fusion weights are generated through a gating network. ;in, and These are the learnable parameters of the gated network. Using the Sigmoid activation function, weights are dynamically fused. This is the gating factor matrix;

[0039] Based on dynamic fusion weights Spatial coupling characteristics With time-dependent features Weighted fusion is performed to obtain the final fusion features. for: .

[0040] Preferably, during the single-step prediction process, the fusion feature matrix corresponding to the current input window is used. Generate the prediction result for the next moment, and obtain the time. Predicted values: ;in, and These represent the weight matrix and bias term of the prediction layer, respectively.

[0041] Preferably, a recursive sliding window approach is used, where the previous prediction result is fed back into the input window and combined with existing historical observations to form the input for the next prediction, used to generate the next prediction. Recursive input window samples of step prediction results Among them, the first The step prediction value is expressed as: ; Indicates the length of the sliding time window; Indicates the multi-step prediction step size; This represents the prediction mapping function composed of the knowledge-enhanced graph convolution module, the Transformer temporal modeling module, the gated fusion module, and the prediction layer. This represents the historical normalized multivariate observation vector in the input window. This represents the multivariate prediction vector obtained from the preceding prediction steps.

[0042] Establish corresponding prediction branches for multiple process variables: The process variable at the th ... Each sliding window sample corresponds to the prediction start time. next future The sequence of prediction results at each time step is as follows: ;in, They represent the first A process variable at time 1 The predicted value.

[0043] Preferably, during the training process, the error between the actual observation value and the predicted value is used as the optimization target, and the trainable parameters in the knowledge enhancement graph convolution module, the Transformer temporal modeling module, the gated fusion module and the prediction layer are jointly updated through the backpropagation algorithm to achieve end-to-end training;

[0044] The root mean square error is used as the loss function, which is:

[0045] ;

[0046] in, Indicates the number of process variables. Indicates the multi-step prediction step size. Indicates the first A process variable at time 1 Normalized true observations Indicates the first A process variable at time 1 The predicted value.

[0047] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0048] (1) This invention accurately identifies complex and implicit coupling relationships between variables by deeply analyzing chemical process data; this invention can effectively extract and model difficult-to-capture coupling relationships, providing accurate input for graph convolutional networks. Graph convolutional networks can accurately capture the spatial dependence between variables based on the extracted coupling relationships between variables, significantly improving the interpretability and fault diagnosis capability of the model under complex dynamic conditions.

[0049] (2) This invention introduces a graph convolutional network, combining a prior knowledge matrix and a learnable adjacency matrix to improve the model's predictive ability under complex working conditions. The prior matrix extracts the static coupling relationships between variables based on process knowledge, while the learnable matrix adaptively captures the dynamic relationships in the process data through training. Compared with traditional methods, this invention effectively overcomes the limitations of over-reliance on static structures or relying solely on data-driven models, and can more accurately reflect the complex interaction relationships between variables under dynamic working conditions, thereby improving the prediction accuracy and real-time performance in actual industrial environments.

[0050] (3) This invention combines graph neural networks with Transformer modules, employing a dual-branch structure to extract spatiotemporal features. The graph convolutional branch captures spatial dependencies, while the Transformer branch models temporal dependencies. Unlike existing technologies, this invention incorporates prior knowledge from chemical processes, using prior coupling information to constrain spatiotemporal modeling, ensuring the model possesses stronger physical rationality and interpretability. The fusion of spatiotemporal features enables the model to comprehensively learn dynamic changes, significantly improving prediction accuracy and fault warning capabilities under complex working conditions, and enhancing the accuracy and adaptability in multivariate, multi-step prediction. Attached Figure Description

[0051] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0052] Figure 1 This is a model framework diagram of the KGTN of this invention.

[0053] Figure 2 Here is the construction process diagram of the CSTH prior variable graph based on process knowledge, where (a) is the source of process knowledge, (b) is the variable graph based on process knowledge, and (c) is the adjacency matrix.

[0054] Figure 3 A diagram showing the relationships between key variables in the TE process.

[0055] Figure 4 The trend graphs are for five variables selected under normal and fault conditions of the TE process, where (a) is under normal operating conditions and (b) is under fault condition 13.

[0056] Figure 5 The diagram shows the model prediction results under the fault state of the TE process, where (a) is RNN, (b) is LSTM, (c) is TMM, and (d) is the present invention.

[0057] Figure 6 The diagram shows the model prediction results under normal conditions of the TE process, where (a) is RNN, (b) is LSTM, (c) is TMM, and (d) is the present invention.

[0058] Figure 7 A graph showing the relationships between key variables on CSTH.

[0059] Figure 8 The charts show the trends of five variables selected under normal and fault conditions on CSTH, where (a) is under normal operating conditions, (b) is under cold water valve stuck fault conditions, and (c) is under hot water temperature rise data.

[0060] Figure 9 The figure shows the model prediction results under CSTH fault conditions, where (a) is RNN, (b) is LSTM, (c) is TMM, and (d) is the present invention.

[0061] Figure 10 A simplified process diagram of the FCC reaction-regeneration system.

[0062] Figure 11 The diagram shows the FCC process warning results, where (a) represents the feed temperature under steady-state conditions and (b) represents the feed temperature under fault conditions. Detailed Implementation

[0063] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0064] like Figure 1As shown, a multi-step fault prediction method for chemical processes based on knowledge-enhanced graph Transformer is proposed. This method introduces a knowledge-enhanced learnable topology construction module, combining prior coupling relationships in chemical processes with data-driven learning. Based on this, it adaptively mines potential and un-explicitly modeled dependencies between variables, improving the reliability and physical rationality of graph structure modeling. Furthermore, a dual-branch spatiotemporal modeling structure combining graph convolution and Transformer is constructed. The graph convolution branch is used to extract spatial coupling features between variables, while the Transformer branch is used to characterize long-term temporal dependencies in multivariate time series. The two are then fused to achieve multi-step recursive prediction, thereby enabling early warning of chemical process faults. This invention can achieve early identification and warning of potential faults under complex operating conditions, and has significant practical implications for improving the operational safety of chemical plants, reducing economic losses, and promoting intelligent process management. This invention mainly addresses the problems of difficulty in characterizing topological dependencies between variables and the lack of mechanistic constraints in complex chemical process systems. By constructing a mechanism constraint graph and integrating it with a learnable adjacency structure, a systematic expression of the intrinsic relationships between multi-source process data is achieved. This enables the model to infer state evolution under the constraints of real process laws, thereby significantly improving the stability and reliability of industrial process prediction results.

[0065] The graph convolutional network of this invention is used to perform variable relationship propagation and spatial feature extraction under knowledge-enhanced topological constraints. The Transformer module is used to model long-term dependencies and dynamic evolution patterns in multivariate time series. The two work synergistically through an adaptive fusion mechanism to achieve multi-step trend inference of the operating status of chemical processes and early identification of potential faults. While maintaining model interpretability and operational stability, this invention effectively improves the accuracy and reliability of fault prediction and early warning in chemical processes under complex operating conditions, providing strong technical support for the safe operation and intelligent control of industrial processes. The specific implementation steps of this invention include:

[0066] Step 1: Data Acquisition and Sample Construction: Collect multi-source time-series data from the chemical production process, construct multivariate input sequences, normalize each observed variable, obtain input samples through sliding time window processing, and construct a preprocessed time-series sample set for subsequent modeling and analysis.

[0067] This step involves collecting real-time operational data of key process variables from the distributed control system of a chemical process and constructing the sample sequence required for subsequent model training. Chemical production systems typically contain multiple coupled unit operations, with complex dynamic relationships formed between these units through material flow, energy transfer, and control feedback. Therefore, data acquisition and sample construction must simultaneously consider both physical correlations and time-series characteristics.

[0068] 1) Process variable selection and data acquisition

[0069] In chemical processes, various process variables typically form complex coupling relationships through material transfer, energy transfer, and control actions. These coupling relationships determine the dynamic evolution characteristics and fault propagation paths of the system. To explicitly characterize these mechanistic constraints, this invention analyzes multivariate process data based on chemical process mechanism knowledge, selecting key process variables that reflect the material balance, energy balance, and control dynamics of the chemical process. In TE processes, the interactions between process variables are significant. For example, condensation temperature affects the liquid level balance within the column, and the liquid level, in turn, alters the discharge flow rate through valve regulation, thus forming multi-level coupled feedback. To comprehensively characterize the system's operating state, this invention selects key monitoring quantities reflecting material and energy transfer as modeling inputs, encompassing various physical quantities such as flow rate, liquid level, valve position, and cooling rate. Among these, the discharge flow rate describes the emission intensity of non-condensable gases in the condensation section; the distillation column liquid level characterizes the accumulation and stability of materials within the column; the flow rate at the bottom of the column reflects the material discharge rate, forming a mutually restrictive relationship with the liquid level; the opening degree of the discharge valve reflects the direct impact of the regulation action on the material balance; and the opening degree of the condenser cooling water valve reflects the dynamic changes in the heat exchange rate.

[0070] All the above variables are collected in real time by the distributed control system and recorded at a fixed sampling period to form a multivariate time series. Assume the system has a total of... If there are process variables, then in time The observation vector is defined as:

[0071]

[0072] in, Indicates the first A process variable at time The value of .

[0073] The collected multidimensional sensor process variables form the original data matrix. Each row corresponds to all process variables at a sampling time. To eliminate differences in the dimensions and fluctuation amplitudes of different variables, each process variable is normalized and transformed into a form with zero mean and unit variance, resulting in the _th_ ... A process variable at time 1 Normalized values:

[0074] ;

[0075] in, and The first The mean and standard deviation of each process variable are calculated. The normalized time-series dataset retains the dynamic characteristics of the chemical process and facilitates numerical stability training of the subsequent model.

[0076] 2) Sliding window sample construction

[0077] Chemical processes exhibit significant time dependence; the current system state is often closely related to its historical operation within a certain time range. To capture this dynamic evolution, this invention employs a sliding time window method to construct input samples. The window length is set to... That is, each input sample contains the previous A sequence of observation vectors at consecutive time points, in time... The input sample at that time can be represented as:

[0078] ;

[0079] in, Indicates time The normalized multivariate observation vector is composed of the normalized values ​​of each process variable at that time, i.e.

[0080] ;

[0081] in, Indicates the first A process variable at time 1 The normalized values, Indicates the number of process variables.

[0082] For each input sample, the prediction target is the operating state of the system over several future time intervals, denoted as:

[0083] ;

[0084] in, The time step for multi-step prediction.

[0085] To facilitate the subsequent unified representation of sliding window samples by sample number in the Transformer module, further let the... The input and prediction target for each sliding window sample are denoted as follows:

[0086] ;

[0087] in, Number the sliding window samples. Indicates by the first From the moment to the first The continuous moments The input sample consists of normalized observation vectors. Represents the input sample Corresponding future The predicted target sequence at each time point. Based on the above definition, the aforementioned time-indexed... The window construction method will be uniformly converted to be based on sample number. The training sample representation.

[0088] Through the above data acquisition and sample construction steps, the obtained multivariate time series input samples can effectively reflect the dynamic coupling characteristics of liquid level, flow rate, valve position and cooling process in chemical plants, providing data support with mechanistic significance for knowledge-enhanced graph convolutional networks in the spatial feature extraction stage.

[0089] Step 2: Mechanism Constraint Graph Construction Steps: Based on the knowledge of chemical process mechanisms, process variables are selected from the normalized multivariate input sequence. According to the control relationship, energy transfer relationship and material transfer relationship between process variables, a mechanism constraint graph is constructed. Node pairs are assigned corresponding weights according to different coupling types to form a prior adjacency matrix.

[0090] This step aims to establish a knowledge-enhanced graph convolutional network by introducing prior knowledge of the chemical process topology and mechanisms, thereby modeling the spatial coupling relationships among multiple variables. Through a collaborative mechanism of "prior adjacency + learnable adjacency," this step maintains process interpretability while also possessing adaptability to complex operating conditions.

[0091] During the operation of chemical plants, complex physical, energy, and control feedback couplings exist between process variables. For example, in the TE process, the cooling rate of the condenser affects the condensation efficiency and liquid level changes, which in turn affect the discharge flow rate through valve regulation, forming a two-way interaction chain between materials and energy. To characterize this relationship in the modeling, a mechanism constraint diagram is first established based on the process topology of the chemical plant, material flow direction, and energy transfer relationships. .in, The node set represents a process variable, where each node corresponds to a process variable (e.g., tower level, drain valve, condensate valve, etc.), and the edge set represents a process variable. This represents the physical relationship between process variables. For variables with different physical dimensions (such as temperature, flow rate, and pressure), a normalized scaling function is used to achieve unit consistency, ensuring the rationality of edge weight calculation in the physical constraint matrix.

[0092] Based on this definition, the physical constraint adjacency matrix is ​​also known as the prior adjacency matrix. , of which elements Representation Nodes and The physical coupling strength, when there is an energy transfer, material flow, or control relationship between two process variables, is related to the element. Otherwise element This matrix physically reflects the structural topology of the process, providing mechanistic prior constraints and a physically interpretable structure for subsequent graph convolution operations, thus forming the basis for knowledge enhancement modeling.

[0093] Step 3: Knowledge-enhanced graph feature extraction: Based on the normalized multivariate input sequence obtained in Step 1, construct a node feature matrix, further construct a learnable adjacency matrix, and fuse the learnable adjacency matrix with the prior adjacency matrix to obtain the knowledge-enhanced adjacency matrix; Under the constraint of the knowledge-enhanced adjacency matrix, input the node feature matrix into the graph convolutional network, and extract the coupling features between process variables through feature propagation and aggregation operations to obtain the spatial feature matrix.

[0094] Traditional fixed topologies tend to lose their generalization ability when operating conditions change. Therefore, a learnable adjacency matrix is ​​introduced. To compensate for dynamic relationships that are not covered by prior knowledge.

[0095] Let the feature matrix of the input nodes be... The linear mapping weights are Then the adjacency matrix can be defined as:

[0096] ;

[0097] in, This represents the total number of process variables, i.e., the number of nodes in the mechanism constraint diagram. This represents the input feature dimension of each node. This represents the feature dimension after linear mapping. This represents the matrix transpose. Input node feature matrix. The node feature matrix is ​​constructed from the normalized multivariate input sequence obtained in step one. Specifically, the normalized observation sequence of each process variable within the current sliding time window is used as the feature vector of the corresponding node, thereby forming the node feature matrix. .

[0098] By fusing prior constraint information and data-driven information using the Sigmoid activation function, and by constraining the range of element values ​​to ensure numerical stability and interpretability, a knowledge-enhanced adjacency matrix is ​​obtained.

[0099] ;

[0100] in, Using the Sigmoid activation function ensures that the elements of the edge weights... While maintaining interpretability and stability, the fused knowledge-enhanced adjacency matrix possesses the ability to adaptively supplement unmodeled relationships while maintaining physical plausibility.

[0101] This fusion strategy enables joint modeling of mechanistic knowledge and data-driven approaches, allowing the graph structure to retain its physical meaning while possessing adaptive optimization capabilities. When the coupling strength or direction between variables changes under new operating conditions, the learnable part automatically adjusts, thereby enhancing the robustness of the model.

[0102] After obtaining the fused adjacency matrix, the node feature matrix is... The input graph convolutional network, under the constraint of the fused adjacency matrix, realizes the information interaction of variable features on the graph structure through feature propagation and aggregation operations.

[0103] To avoid propagation bias caused by uneven node degree distribution, the adjacency matrix is ​​enhanced after obtaining fused knowledge. Subsequently, to ensure that nodes retain their own state information during feature propagation, a knowledge-enhanced adjacency matrix is ​​used. With the identity matrix Adding self-connections to nodes within the graph structure preserves their own information. This operation prevents node features from being completely overwhelmed by neighbor information during multiple propagations, thus preserving the intrinsic properties of individual process variables. Furthermore, the adjacency matrix is ​​enhanced based on knowledge. Determine the connectivity of each node and construct the degree matrix of the nodes. Based on degree matrix Knowledge-enhanced adjacency matrix After performing symmetric normalization, the normalized adjacency matrix is ​​obtained:

[0104] Degree matrix elements in , Represents a node The degree value is used to characterize the connection strength of nodes in the graph structure. Through symmetric normalization, the contributions of different nodes in the feature aggregation process can be effectively balanced, suppressing numerical instability caused by differences in the number of node connections or data noise, thereby improving the stability and robustness of graph convolution operations.

[0105] After obtaining the normalized adjacency matrix Subsequently, node features are updated on the graph structure through convolution operations. This is based on the normalized adjacency matrix. , node feature matrix The input graph convolutional network extracts spatially coupled features through multiple layers of graph convolution operations, achieving feature propagation and aggregation. Specifically, the... The process of node feature propagation and aggregation in a layer can be represented as:

[0106] ;

[0107] in, Indicates the first The node feature matrix of the layer, Indicates the first The node feature matrix of the layer, The weight matrix is ​​a learnable matrix. It is a non-linear activation function.

[0108] Through multi-layer convolutional iteration, nodes can continuously aggregate neighborhood information, achieving feature extraction from local coupling to global structure.

[0109] After L g After a layered graph convolutional network, the final feature vector of each node is... It includes both the intrinsic state information of the variable and the upstream and downstream influences within its neighborhood. The overall correlation representation matrix can be represented as a spatial feature matrix:

[0110] ;

[0111] This spatial feature matrix physically represents the steady-state and dynamic coupling structure between variables, revealing the spatial correlation patterns of chemical plant operation. For example, in the TE process, when the cooling water valve adjustment causes the liquid level to rise, the system's spatial feature vector will reflect the coordinated changes in valve position, liquid level, and discharge flow rate, thus providing a physical topology-based input for subsequent time-dependent modeling.

[0112] Through layer-by-layer propagation of multi-level graph convolution, the feature representation of each node not only includes its own state information but also integrates features from other nodes related to its underlying mechanisms or data, thereby enabling multi-level modeling of the complex coupling relationships between chemical process variables. This feature propagation mechanism effectively extracts spatial correlation features between variables while maintaining consistency of mechanistic constraints, providing stable and physically meaningful feature representations for subsequent time-series modeling and multi-step fault prediction.

[0113] Step 4: Transformer Temporal Feature Modeling Steps: After adding a position encoding vector to the input sample of each time step in the temporal sample set, input it into the Transformer module to obtain the temporal dependency features of each time step.

[0114] After refining the process relationships, this step aims to extract and represent the time dynamic dependencies in the chemical process operation data. By introducing a Transformer structure and a multi-head self-attention mechanism, the evolutionary patterns of multivariate time series are captured, thereby enhancing the model's long-term predictive ability and nonlinear modeling accuracy.

[0115] Process variables in chemical processes typically originate from multiple sets of sensors, and their sampling results constitute multivariate time series. To characterize the time-dependent structure, this invention uses the sliding window samples defined in step one as the input to the Transformer module.

[0116] Let the first step yield the first... The sliding window samples are:

[0117] ;

[0118] ;

[0119] in, Indicates the number of process variables. Indicates the length of the sliding time window. Indicates the first In the nth window sample The normalized input feature vector corresponding to each time step .

[0120] To preserve the temporal order information of the sequence, positional encoding is introduced into the input feature vector at each time step, resulting in an enhanced time-step input representation:

[0121] ;

[0122] in, Indicates the first The position encoding vector corresponding to each time step.

[0123] To unify the dimensions of different variables and stabilize model training, linear projection and layer normalization operations are performed on the time-step input vector after adding positional encoding. Let the mapping weight matrix be... The bias vector is Then the embedded features after linear transformation are:

[0124] ;

[0125] in, Indicates the embedding feature dimension. Representation layer normalization operation. Linear projection maps the original input to an embedding space of uniform scale, mitigating the impact of differences in the scale and numerical fluctuations of different variables on model training and providing stable input for subsequent attention calculations.

[0126] Therefore, the embedded feature sequence is constructed:

[0127] ;

[0128] embed feature sequences Input the Transformer encoding module and model the correlation between different time steps using a multi-head self-attention mechanism. For the ... Each attention head is defined, and the query matrix, key matrix, and value matrix are defined as follows:

[0129] ;

[0130] in, Indicates the first Each attention head has a feature dimension. , , The first The query projection matrix, key projection matrix, and value projection matrix corresponding to each attention head are all learnable parameters obtained through backpropagation optimization during model training.

[0131] For the Each attention point, firstly using the query matrix AND key matrix Calculate the correlation weights between each time step, and then apply these weights to the value matrix. The output of this attention head is obtained:

[0132] ;

[0133] in, This is a scaling factor used to suppress instability caused by excessively large inner product values.

[0134] The outputs of each attention head are concatenated and fused using an output mapping matrix to obtain the output of the multi-head self-attention module:

[0135] ;

[0136] in, Indicates the number of heads of attention. This represents the output mapping matrix. Multi-head structures can model temporal dependencies in parallel across different time scales, thereby simultaneously capturing short-term volatility characteristics and long-term trend dependencies.

[0137] The output of the multi-head self-attention module is processed through a feedforward network, residual connections, and layer normalization to obtain the output feature matrix of the Transformer encoding module:

[0138] ;

[0139] in, Represents the output feature matrix The Row vector, i.e., the first row vector The window sample at the th The temporal dependency feature vector corresponding to each time step.

[0140] Therefore, the temporal dependency feature matrix output by the Transformer module can be represented as:

[0141]

[0142] in, Indicates the first The time-dependent feature matrix is ​​obtained by modeling the sliding window samples using Transformer time features. The time-dependent feature matrix not only represents the instantaneous change trend of process variables within the current time window, but also depicts the lagged dependencies and dynamic coupling characteristics formed between variables over time.

[0143] Through the above mechanism, the model can explicitly capture the evolution and interaction of multivariate process data in the time dimension. When the adjustment of the cooling water valve causes a delayed response in the tower top temperature and tower liquid level, the attention mechanism can automatically identify the lag dependency across the time step; when the periodic fluctuation of the reactor causes coupled changes in pressure and flow rate, the model can model fast disturbance and slow equilibrium processes in different attention heads respectively.

[0144] Step 5: Gated Dynamic Fusion Step: The spatial feature matrix extracted by the graph convolutional network and the temporal dependency feature matrix extracted by the Transformer module are concatenated and input into the gated network. Dynamic fusion weights are calculated through learnable parameters. Based on the fusion weights, the spatial feature matrix and the temporal dependency feature matrix are weighted and fused to obtain the fused feature matrix.

[0145] After completing the process relationship extraction and time dynamic modeling modules, this step adaptively fuses the two types of features through a dynamic gating mechanism, enabling the model to flexibly balance the contribution of various information types under different operating conditions. This mechanism can adaptively adjust the fusion ratio according to changes in operating conditions, thereby ensuring that the model maintains stable and accurate predictive performance under both steady-state operation and disturbed conditions.

[0146] 1) The need for multi-source representation input and dynamic fusion

[0147] In chemical plants, operating variables are often simultaneously influenced by structural relationships, material and energy transfer patterns, control loop characteristics, and hysteresis effects. For example, the liquid level, condenser temperature, and discharge flow rate of a distillation column not only reflect the internal physical connections of the unit but also exhibit complex change patterns due to adjustments and disturbance propagation. The representations extracted by different types of modeling modules have varying importance under different operating conditions; therefore, a mechanism is needed to automatically adjust the fusion ratio based on the system state.

[0148] In chemical process fault prediction, spatial coupling and temporal evolution often coexist, and their importance varies with operating conditions. Spatial coupling features characterize the interactions between variables caused by materials, energy, and control actions, while temporal features characterize the dynamic evolution of variable states over time, hysteresis effects, and disturbance responses. Because chemical process operating conditions, load fluctuations, and disturbance intensities are not constant, the contribution ratios of spatial coupling and temporal dependence to the prediction also change at different stages. Using simple splicing or fixed-weight fusion can easily lead to the over-amplification or weakening of certain branch features, resulting in decreased prediction stability.

[0149] Traditional methods typically employ simple concatenation or fixed-ratio weighting to merge representations, but these static approaches fail to reflect the differences in contribution resulting from variations in operating conditions. Therefore, this invention introduces a lightweight dynamic gating network, utilizing learnable parameters to adaptively adjust the weights of each representation in the final input, thereby achieving flexible and robust fusion. This invention introduces a gating fusion mechanism to adaptively weight spatial and temporal features.

[0150] 2) Gating weight calculation and feature weighting mechanism

[0151] set up Let the spatial coupling feature matrix obtained by the graph convolution branch be and the temporal dependency feature matrix obtained be . To ensure that the temporally dependent feature matrix has the same dimension as the spatial feature matrix before fusion, the temporally dependent feature matrix... Perform time-dimensional mapping to obtain the aligned temporal dependency feature matrix. .set up and These are the learnable parameters of the gated network. This is the Sigmoid activation function. Wherein, Indicates the number of process variables. This represents the unified feature dimension. First, the two types of representations are concatenated along the feature dimension to form the joint input. Dynamic fusion weights are generated through a gating network: ;

[0152] Among them, dynamic fusion weight The gating factor matrix represents the adaptive contribution of spatial features to different nodes or variables. The Sigmoid activation function is used to constrain the fusion weight α within the (0,1) interval, thereby ensuring that the fusion process has a controllable weighting range.

[0153] When the structural relationship has a stronger impact in the operating condition (such as increased recirculation, enhanced heat transfer, etc.), the dynamic fusion weights are adjusted. As the value increases, the model places greater emphasis on utilizing the feature matrix of the representation space. When the system's dynamic characteristics dominate (such as temperature hysteresis and significant periodic disturbances), the dynamic fusion weights are adjusted. Decreasing the value improves the temporal dependency feature. The role of representation.

[0154] Based on dynamic fusion weights Spatial coupling characteristics With time-dependent features Weighted fusion is performed to obtain the final fusion features. for:

[0155] ;

[0156] This mechanism achieves dynamic balance of multi-source information through element-wise weighting, avoiding bias or redundancy problems caused by a single dominant representation.

[0157] In this way, the model can adaptively adjust the contribution ratio of the two types of features based on the operating conditions reflected by the current input sequence: when the coupling between process variables is enhanced or the spatial correlation is more significant, the gating network tends to increase the dynamic fusion weights. This emphasizes spatial coupling characteristics; when the system exhibits significant lag, periodic disturbances, or long-term dependencies, the gating network tends to reduce the dynamic fusion weights. This enhances the role of time-dependent features in the final representation. This adaptive mechanism enables feature fusion. It possesses both spatial consistency and temporal sensitivity, improving its adaptability to different operational stages and disturbance conditions.

[0158] In multi-step prediction scenarios, feature fusion As input to subsequent prediction modules, it generates prediction results for multiple future time steps and supports recursive updates: that is, it uses the fused representation obtained at the current moment to generate the next prediction, and then uses the prediction results together with the historical sequence for inference in subsequent time steps, thereby enabling early characterization of the evolution trend of chemical process faults. Through the collaborative design of gated fusion and multi-step prediction, the stability and reliability of prediction can be significantly improved, the impact of error accumulation during multi-step recursion on the prediction results can be reduced, and a more sufficient lead time can be provided for fault early warning.

[0159] 3) Operational Mechanism and Adaptability Analysis of Dynamic Gating

[0160] This gated network automatically learns the importance variations of various representations under different operating conditions through backpropagation during training, enabling adaptive adjustment of feature importance under different operating states. Under steady-state conditions, process structure relationships dominate (e.g., the balance between tower liquid level, condenser temperature, and discharge flow rate), and the model automatically increases... When the system is disturbed or in a transitional phase (such as a sudden change in the opening of a cooling water valve causing a rapid response of variables), the representation related to the change pattern becomes more critical, and the model size is reduced. Improve time-dependent features Weights are used to capture transient features; under complex variable load conditions: the gating network independently learns the optimal fusion ratio on different feature dimensions to achieve multi-variable adaptive adjustment.

[0161] 4) Application of fusion results to downstream tasks

[0162] The fused feature matrix As a unified representation of the model, it retains both the spatial topology and the technological coupling relationship, while also incorporating temporal evolution and lag information. In subsequent multi-step prediction tasks, the model uses these fused features. As input, the future variable trajectory is output using a recursive sliding window method. This enables multi-time-domain trend prediction of key process variables and early warning of faults.

[0163] Step Six: Multi-step prediction and recursive sliding window reasoning:

[0164] After completing the adaptive fusion of multi-source features, this step is based on the fused features. This system enables multi-step prediction and trend inference of chemical process variables. Through a recursive sliding window mechanism, the model gradually moves forward in the time dimension, feeding back previous prediction results as subsequent inputs, thereby achieving continuous prediction and dynamic early warning in the future time domain.

[0165] 1) Single-step prediction mechanism

[0166] During single-step prediction, the model utilizes the fused features corresponding to the current input window. The prediction result for the next time step is generated and represented as:

[0167] ;

[0168] in, Indicates time The predicted value, and These represent the weight matrix and bias term of the prediction layer, respectively. This mapping allows for the fusion of features. This is transformed into the predicted output of the target process variable at the next time step.

[0169] 2) Multi-step prediction extension of recursive sliding window

[0170] To achieve multi-step time-domain prediction, this invention employs a recursive sliding window approach, feeding back the model's previous prediction result into the input window, which, together with existing historical observations, constitutes the input for the next prediction. Let the length of the sliding time window be... The multi-step prediction step size is Then the first The step prediction value is expressed as:

[0171] ;

[0172] ;

[0173] in, Indicates the use of generating the first The recursive input window sample of the step prediction results has the known historical observation values ​​in the first part of the window and the predicted values ​​generated in the previous time step in the second part. Indicates the length of the sliding time window; Indicates the multi-step prediction step size; This represents the prediction mapping function, which is composed of the knowledge-enhanced graph convolution module, the Transformer temporal modeling module, the gated fusion module, and the prediction layer.

[0174] Through the above recursive iteration method, the model can continuously output the trajectory of process variables over a long period of time, enabling forward-looking inferences about the operating status of chemical processes.

[0175] 3) Multivariate parallel prediction structure

[0176] To accommodate the parallel prediction requirements of multivariate processes, the model can establish corresponding prediction branches for multiple key process variables. For the first... The process variable, at the _ , in the _ ... Each sliding window sample corresponds to the prediction start time. Below, its future The sequence of prediction results at each time step is represented as follows:

[0177] ;

[0178] in, Indicates the first Process variables in the future The sequence of prediction results at each time point Indicates the first A process variable at time 1 The predicted value, .

[0179] Accordingly, the first The true target sequence of process variables is represented as follows:

[0180] ;

[0181] therefore, and One-to-one correspondence, respectively representing the first The predicted sequence and the actual target sequence of each process variable.

[0182] Different prediction branches share the common fused feature representation output by the gating fusion module in step five. Based on this, each variable generates its own future prediction sequence through its own variable-specific prediction head, thereby balancing information sharing between variables and the ability to model individual variables, and improving the consistency and accuracy of multivariate prediction.

[0183] 4) Early warning mechanism based on recursive forecasting

[0184] Through a recursive prediction structure, the model can identify potential abnormal evolution trends in chemical processes in advance. When a key variable consistently deviates from the normal operating range in several future prediction steps, or exhibits abnormal trends such as significant increases, decreases, or intensified oscillations, it can be identified as a potential early warning signal, thus providing a window for early intervention in the control system. This mechanism is applicable to various chemical operation scenarios, including delayed responses, slow degradation, periodic disturbances, and sudden disturbances, and can significantly improve the foresight of process safety monitoring and fault early warning.

[0185] 5) Model training methods

[0186] During model training, the error between the actual observations and the predicted values ​​is used as the optimization objective. The backpropagation algorithm is used to jointly update the trainable parameters in the knowledge-enhanced graph convolution module, the Transformer temporal modeling module, the gated fusion module, and the prediction layer to achieve end-to-end training.

[0187] Preferably, the root mean square error is used as the loss function, expressed as:

[0188] ;

[0189] in, Indicates the number of process variables. Indicates the multi-step prediction step size. Indicates the first A process variable at time 1 Normalized true observations Indicates the first A process variable at time 1 The normalized predicted value.

[0190] By minimizing the above loss function, the model can improve the accuracy and stability of predicting the operating state at multiple future time points while maintaining its ability to characterize process coupling relationships.

[0191] Experimental verification and analysis:

[0192] 1. Construction of Mechanism-Constrained Prior Graph and Prior Adjacency Matrix: The construction of the prior graph topology in this invention is based on knowledge of chemical process mechanisms. Its core idea is to explicitly map the coupling relationships between process variables caused by material transfer, energy transfer, and control actions into a variable-level graph structure. Specifically, based on piping and instrumentation diagrams and process descriptions, a set of representative key process variables is first identified and selected from high-dimensional process data. These variables collectively characterize the system's material balance, energy balance, and control dynamics. Subsequently, each selected variable is mapped to a node in the graph, where each node corresponds to the measurable or manipulable process variable itself, rather than a physical device unit, thus ensuring a direct correspondence between the graph structure and multivariate time series data.

[0193] In continuous stirred tank heating (CSTH) processes, energy transfer primarily occurs through two physically distinct paths: hot water heating and cold water cooling. Steam valve opening... The heat input into the stirred tank is directly adjusted, thus affecting both the temperature inside the tank and the outlet temperature. Accordingly, the opening degree of the cold water valve By adjusting the cold water flow rate This controls the cooling capacity, creating an energy removal channel opposite to the heating flow rate. It is both a material flow variable and a direct carrier of energy transfer, influencing cooling intensity and the overall energy balance of the system through the material renewal process. (Stirred vessel liquid level) It reflects the material accumulation state under the combined effects of heating and cooling, while the outlet temperature... This represents the balance result of the combined effects of energy input and energy removal. Therefore, the steam valve opening... Cold water valve opening Cold water flow rate , Stirred tank liquid level and outlet temperature This constitutes a highly coupled variable network governed by energy input, energy dissipation, material accumulation, and thermal response. These coupling relationships, with explicit physical meanings, are directly encoded as node connections in the prior graph. Taking the CSTH process as an example, the process of extracting process knowledge and constructing the prior adjacency matrix is ​​as follows: Figure 2 As shown.

[0194] If variable With variables There is a direct control relationship between them, i.e., variables Able to directly adjust or control variables (For example, the opening degree of the cold water valve) Directly control the cold water flow rate If the variable is ), then the corresponding matrix element is set to 1; if the variable is 1, then the matrix element is set to 1. With variables There is an energy flow relationship between them, that is, they are coupled through energy transfer or exchange (e.g., cold water flow rate). With outlet temperature If the relationship between the variables is such that the corresponding matrix element is assigned a value of 0.7, then the variable is... With variables There is a material flow relationship between them, that is, they are coupled through material transfer (e.g., cold water flow rate). With the liquid level of the stirred tank If the relationship between the variables is such that the corresponding matrix element is assigned a value of 0.5, then the variable is assigned a value of 0.5. With variables If there is no coupling relationship between processes, the corresponding matrix element is set to 0. It should be noted that the above values ​​are used to characterize the relative strength of coupling relationships between different types of processes, rather than fixed physical constants, and can be flexibly adjusted according to specific process characteristics or application scenarios. Although this invention uses the CSTH process as an example, the prior graph topology construction for other datasets follows the same mechanism-guided process.

[0195] 2. Experimental Verification of the TE Process: In the experimental verification of this invention, based on the revised Tennessee-Eastman Process (TEP) model by Bathelt, the structure and dynamic characteristics of the system were analyzed in depth. The results show that the variables in the TE process do not exist in isolation, but rather form a strong coupling relationship through material balance and control loops. Combining existing literature and logical reasoning, the interaction mechanism and causal relationship between variables were reconstructed, and a comprehensive system framework including the reactor, condenser, compressor, vapor-liquid separator, and distillation column was established. To reflect the dynamic evolution characteristics of the system, five representative key process variables were selected from the material and energy flows of the five main units, including the discharge flow (flow 9), discharge valve (flow 9), distillation column liquid level, distillation column downflow (flow 11), and condenser water valve opening. These variables can simultaneously reflect the system's mass and energy balance, comprehensively characterize the system's operating state, and provide basic data support for model verification. The key variable relationship diagram is shown below. Figure 3 As shown.

[0196] In the experiment, fault 13—slow catalyst deactivation—was selected as a typical verification condition. Figure 4The trends of five variables under normal and fault conditions (13) are presented. This fault is characterized by a gradual decrease in catalyst activity over time, with small changes in process variables in the early stages, making it difficult to detect macroscopically. Time-series evolution analysis of key variables under normal and fault conditions revealed that although no significant trend deviation occurred within the 600-700 time step range, some variables showed weak disturbance signals, indicating a potential anomaly within the system. This stage is crucial for early fault prediction; if the initial signs of catalyst deactivation can be identified during this window, timely adjustment measures can be taken to prevent further system deterioration. Experimental results validate the early fault identification capability of the method in the TE process, demonstrating its ability to capture key dynamic characteristics in the early stages of a fault, significantly improving prediction accuracy and timeliness. This method not only improves the safety and stability of process operation but also effectively reduces energy and material consumption, providing strong support for intelligent monitoring and predictive control of complex chemical processes.

[0197] Figure 5 The results show the performance verification of the model prediction under fault condition 13. This fault is caused by the slow decay of catalyst activity, resulting in a gradual decrease in the purification flow rate. The experiment first collected normal operating data on the TEP platform, and determined the upper and lower thresholds to be 0.3913 and 0.2868, respectively, through kernel density estimation. When the predicted value exceeds this range, it is judged as an abnormal state. Figure 5 In the diagram, the green and blue dashed lines represent the upper and lower thresholds, respectively; the black solid line represents the actual process data; the red dashed line represents the model prediction result; and the red vertical line indicates the prediction starting point (data from 590 minutes prior is used for modeling). Experiments compared the prediction performance of RNN, LSTM, Transformer-based Multivariate Multi-step prediction (TMM), and the proposed KGTN model. The results show that RNN, LSTM, and TMM exhibit significant deviations between their predicted curves and the actual trajectory after a fault occurs, failing to effectively track the slow decreasing trend of the cleanup flow. In contrast, the KGTN model (with a time step of 100) fully utilizes long-term time-series information, achieving a high degree of consistency between its predicted trajectory and the actual data, accurately capturing the gradual trend caused by the fault, and demonstrating strong modeling ability and robustness.

[0198] Figure 6The results validate the model's predictive performance under normal operating conditions. The experiment aimed to examine the stability and false alarm control capabilities of each model under fault-free conditions. The results show that the prediction curves of RNN, LSTM, and TMM all exhibit varying degrees of fluctuation, especially LSTM and RNN, which fluctuate frequently near the threshold, easily triggering false alarms. In contrast, the KGTN model's prediction curve is stable and highly consistent with the actual data, showing no significant deviation. Although there are slight visual differences between the two at small-scale coordinates, the values ​​almost completely overlap, verifying the model's high accuracy and strong robustness under normal operating conditions. Therefore, the KGTN model proposed in this invention not only has excellent early warning performance in the early stages of faults but also effectively suppresses false alarms during normal operation, combining accuracy and practicality, providing a reliable guarantee for intelligent monitoring and safe operation of complex chemical processes.

[0199] Table 1 compares the features of four mainstream model architectures across five dimensions, including input representation, core structure, spatial dependency modeling capability, prior knowledge utilization, and parameter efficiency. The results show that the KGTN model proposed in this invention uses Transformer as the temporal modeling backbone, integrates GCN structure to capture spatial relationships between variables, and embeds process mechanism knowledge into convolutional kernels through adjacency matrix construction, achieving end-to-end collaboration between data-driven learning and mechanism-constrained modeling. With this design, the KGTN model excels in both spatial dependency modeling and knowledge utilization, while maintaining low parameter complexity (approximately 19k), outperforming existing mainstream frameworks in both prediction accuracy and computational efficiency.

[0200] 3. CSTH (Continuous Stirred Tank Heater) Experimental Validation: This is a typical experimental platform for chemical processes, often used to study the dynamic characteristics of heat exchange, mixing, and process control. The system heats liquids through a stirred reaction vessel, where hot and cold fluids simultaneously mix and transfer heat, making it a representative example of the coupling and nonlinear characteristics of chemical processes.

[0201] In this invention, five key variables were selected to characterize the main dynamic features and control behavior of the system, namely: cold water flow rate. Cold water valve opening Liquid level outlet temperature and steam valve opening These five variables together constitute the core state vector of the system's energy and material balance. There is a significant physical and control coupling relationship among these five variables, such as... Figure 7 As shown. For example, the steam valve opening degree. Changes in this will alter the heat input power, thereby affecting the outlet temperature. Temperature changes will also affect the opening degree of the cold water valve. Adjustments are made to maintain the set point, so that and Feedback coupling has occurred. Simultaneously, the liquid level... Fluctuations in temperature affect fluid residence time and heat transfer efficiency, which in turn alter the temperature response. This dual feedback mechanism of energy and materials leads to nonlinearity, hysteresis, and strong correlation in the system over time, making it difficult to accurately describe the system dynamics by independently modeling each variable.

[0202] Table 1 Comparison of Model Structures

[0203]

[0204] 3. CSTH (Continuous Stirred Tank Heater) Experimental Validation: This is a typical experimental platform for chemical processes, often used to study the dynamic characteristics of heat exchange, mixing, and process control. The system heats liquids through a stirred reaction vessel, where hot and cold fluids simultaneously mix and transfer heat, making it a representative example of the coupling and nonlinear characteristics of chemical processes.

[0205] In this invention, five key variables were selected to characterize the main dynamic features and control behavior of the system, namely: cold water flow rate. Cold water valve opening Liquid level outlet temperature and steam valve opening These five variables together constitute the core state vector of the system's energy and material balance. There is a significant physical and control coupling relationship among these five variables, such as... Figure 7 As shown. For example, the steam valve opening degree. Changes in this will alter the heat input power, thereby affecting the outlet temperature. Temperature changes will also affect the opening degree of the cold water valve. Adjustments are made to maintain the set point, so that and Feedback coupling has occurred. Simultaneously, the liquid level... Fluctuations in temperature affect fluid residence time and heat transfer efficiency, which in turn alter the temperature response. This dual feedback mechanism of energy and materials leads to nonlinearity, hysteresis, and strong correlation in the system over time, making it difficult to accurately describe the system dynamics by independently modeling each variable.

[0206] Two typical progressive failure scenarios were set up in the CSTH system to verify the model's multivariate predictive ability. The two failure trends are as follows: Figure 8As shown. One of the faults is a rise in hot water temperature: the temperature of the hot water entering the system slowly rises from 50°C to 70°C within 300 seconds, causing heat accumulation inside the tank and a rise in the outlet temperature. As the steam rises, the system gradually reduces the opening of the steam valve. To maintain energy balance. This fault reflects the slow change trend and control hysteresis characteristics on the heating side. Fault two is a stuck cold water valve: cold water valve Temporary malfunction, resulting in decreased cold water flow. Unable to respond in time, liquid level and temperature Abnormal fluctuations occurred. After the blockage was cleared, the cooling flow recovered but was accompanied by overshoot, exhibiting typical nonlinear disturbances and multivariable coupling effects on the cooling side. The two fault scenarios are described in Table 2.

[0207] Table 2 Summary of Two Types of Fault Scenarios

[0208]

[0209] In the prediction results section, using the cold water valve stuck Fault 2 (f2) as the test scenario, the multi-step prediction performance of models such as KGTN, RNN, LSTM, and TMM was compared. Figure 9 As shown in the experiment, each model used only historical data prior to the fault as input, predicting the system response over the next 200 time steps through recursive iteration, focusing on the dynamic trend of the steam valve opening. The results show that RNN, LSTM, and TMM all exhibit significant deviations after the fault occurs, with their prediction curves showing underestimation or over-smoothing compared to the actual data, making it difficult to accurately characterize the nonlinear decrease in valve opening. In contrast, the KGTN prediction results of this invention are highly consistent with the actual trajectory, not only reflecting the temperature and flow rate trends in the early stages of the fault but also maintaining stable and continuous prediction performance in the nonlinear region of the later stages of the fault.

[0210] Table 3 Hyperparameter Selection and Model Configuration

[0211]

[0212] To optimize the KGTN model configuration on the CSTH dataset, this invention systematically explored multiple hyperparameter combinations. To ensure the stability and reliability of hyperparameter selection, each candidate configuration was independently evaluated 10 times under different random initialization conditions. The comparison results between the configurations are summarized in Table 3. Among all candidate schemes, structure 6 (t_use=16, n layers=3, hidden layers=64) achieved the lowest average RMSE value of 0.1998, and was therefore selected as the optimal model configuration.

[0213] 4. Experimental Verification of the FCC Process: In the experimental verification of this invention, actual production data from a fluidized catalytic cracking (FCC) unit of a petrochemical enterprise were selected to verify the proposed method. The FCC process is a core link in the oil refining industry, mainly responsible for converting heavy oil fractions into high-value-added light products such as gasoline and olefins. Compared with standard test datasets, actual FCC process data have stronger nonlinear characteristics and more complex coupling relationships, which significantly increases the difficulty of early fault prediction.

[0214] The reaction-regeneration system structure involved in the experiment is as follows: Figure 10 As shown, the system comprises key equipment such as a reactor (R101), a regenerator (R103), a flue gas cooler (R104), a regenerator heat exchanger (R102), and a main blower (F101), forming a closed-loop system for catalyst circulation and regeneration. The selected process variables cover various process parameters such as temperature and flow rate, comprehensively reflecting the system's energy conversion, material balance, and overall operating status. By analyzing the dynamic changes of these key variables, the method of this invention achieves accurate modeling and effective verification of the FCC process operating status in complex industrial environments, further demonstrating the feasibility and reliability of this method in real-world industrial scenarios.

[0215] In the experimental verification of this invention, the key operating parameter TI112F (feed temperature) was selected as the prediction object to verify the effectiveness of the proposed model. Feed temperature is an important parameter affecting reaction intensity, product distribution, and energy balance. Abnormal fluctuations in feed temperature may lead to over-cracking, insufficient conversion, and even potential safety risks. This variable is directly affected by factors such as furnace gas supply, heat exchanger efficiency, and feed flow rate, and indirectly by catalyst circulation and heat exchange feedback between the product stream and feed. It is also constrained by external disturbances, equipment scaling, and control system performance. Based on previous causal relationship analysis, the experiment selected TI112F (feed temperature), TEN104A (riser temperature), FC201 (feed flow rate), FC1103 (steam flow rate), and TIN106 (lower riser temperature) as model input variables, as shown in Table 4. FC201 reflects the effects of heat load and material dilution on feed temperature, FC1103 describes the role of booster steam in oil-catalyst mixing and heat transfer, and TIN106 and TEN104A correspond to the propagation and feedback patterns of feed temperature disturbances at the bottom of the riser and in the reaction zone, respectively. This set of variables covers the direct driving factors and process coupling paths of feed temperature changes, exhibits good physical interpretability, and provides solid data support for validating the model's predictive performance.

[0216] Table 4 Key Process Variables of FCC and Their Descriptions

[0217]

[0218] like Figure 11 As shown in (a), during the steady-state operation phase (0–5000 min), the FCC feed temperature remained within a safe range. The proposed KGTN model closely matched the actual measured values ​​and could accurately capture minute changes without triggering warnings or alarms, verifying the model's high accuracy and engineering applicability under normal operating conditions.

[0219] When the system enters a fault state after approximately 15,000 minutes, such as Figure 10 As shown in (b), the feed temperature exhibited significant abnormal fluctuations and repeatedly exceeded the alarm threshold. The model accurately tracked the overall temperature drift trend and identified abnormal fluctuations in advance. During operation, when the feed temperature dropped close to the low warning threshold (216.8 °C), the system first triggered the yellow "warning point" and illuminated the warning signal; if the temperature continued to drop and exceeded the low alarm threshold (213.3 °C), the red "alarm point" flashed synchronously, marking the system's transition from the prediction stage to the warning and alarm stage. Experimental results show that the model of this invention can issue a warning approximately 10 minutes before the actual alarm occurs, providing operators with sufficient intervention time to prevent further temperature runaway and ensure the safe and stable operation of the device. This demonstrates that the model can not only effectively identify severe anomalies but also keenly capture potential risks in the early stages, exhibiting strong industrial robustness and practical value.

[0220] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A chemical process multi-step fault prediction method based on knowledge-enhanced graph Transformer, characterized in that, The steps are as follows: Step 1: Collect multi-source time series data from the chemical production process to construct a multivariate time series, normalize each process variable, and obtain the input sample through a sliding time window. Step 2: Select process variables based on chemical process mechanism knowledge, construct a mechanism constraint diagram according to the control relationship, energy transfer relationship and material transfer relationship between process variables, assign corresponding weights to node pairs according to different coupling types, and form a prior adjacency matrix; Step 3: Construct a node feature matrix based on the input samples, construct a learnable adjacency matrix based on the node feature matrix, and fuse the learnable adjacency matrix with the prior adjacency matrix to obtain the knowledge-enhanced adjacency matrix; Under the knowledge-enhanced adjacency matrix constraint, the node feature matrix is ​​input into the graph convolutional network, and the coupling features between process variables are extracted through feature propagation and aggregation operations to obtain the spatial feature matrix; Step 4: After adding a position encoding vector to the input sample, input it into the Transformer module to obtain the temporal dependency feature matrix for each time step; Step 5: Concatenate the spatial feature matrix extracted by the graph convolutional network with the temporal dependency feature matrix extracted by the Transformer module, and input the concatenation into the gating network. Calculate the dynamic fusion weights using learnable parameters, and perform weighted fusion of the spatial feature matrix and the temporal dependency feature matrix based on the dynamic fusion weights to obtain the fused feature matrix. Step 6: Use the fusion feature matrix obtained at the current time step to generate the next prediction. Use the prediction results and historical sequences together for inference in subsequent time steps. A recursive sliding window mechanism is used to realize multi-step prediction and inference of the evolution trend of chemical process failures.

2. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to claim 1, characterized in that, The process vector selection reflects key monitoring quantities that reflect material and energy transfer, covering multiple physical quantities such as flow rate, liquid level, valve position, and cooling rate; Record the formation time of each process vector according to a fixed sampling period. Multivariate time series ;in, Indicates the first A process variable at time The sampled values; This represents the total number of process variables. For the A process variable at time Sample values Normalization is performed, transforming it into a form with zero mean and unit variance, to obtain the first... A process variable at time Normalized time series data ; Use a sliding time window to view the current time Normalized time series data of each process variable Normalized time series Processing is performed to obtain the time. Input samples ;in, The length of the sliding time window. They represent time respectively -L+1、 -L+2 normalized time series; No. The sliding window sample is from the first The time step to the 1 A continuous time step Input samples consisting of normalized observation vectors ;in, Number the sliding window samples. Indicates by the first The time step to the 1 A continuous time step The input sample consists of a normalized observation vector; Constructed mechanism constraint graph ;in, A set of nodes representing process variables, each node For a given process variable, the edge set Indicates the physical relationship between process variables; The prior adjacency matrix , among which, element Representation Nodes With nodes Physical coupling strength: When there is an energy transfer, material flow, or control relationship between two process variables, the element Otherwise element .

3. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to claim 2, characterized in that, The normalized observation sequence of each process variable within the current sliding time window is used as the feature vector of the corresponding node to form the node feature matrix. ; The learnable adjacency matrix is: ;in, For linear mapping weights, This represents the total number of process variables. This represents the input feature dimension of each node. This represents the feature dimension after linear mapping. Indicates matrix transpose; Knowledge-enhanced adjacency matrix ;in, Use the Sigmoid activation function; Enhancing the adjacency matrix with knowledge With the identity matrix Add them together and enhance the adjacency matrix based on the knowledge. The degree matrix of each node is constructed by considering the connections between the nodes. Based on degree matrix Knowledge-enhanced adjacency matrix After performing symmetric normalization, the normalized adjacency matrix is ​​obtained: ; Based on normalized adjacency matrix , node feature matrix Input a graph convolutional network, extract spatial coupling features through multiple layers of graph convolution operations, the first... The process of node feature propagation and aggregation in a layer is represented as follows: ;in, Indicates the first The node feature matrix of the layer Indicates the first The node feature matrix of the layer The weight matrix is ​​a learnable matrix. It is a non-linear activation function; After L g After the layer graph convolution operation, each node The final feature vector It includes both the intrinsic state information of the i-th process variable and the upstream and downstream influences within the neighborhood; the resulting spatial feature matrix .

4. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to claim 2 or 3, characterized in that, The method for adding the position encoding vector is as follows: The obtained number A sliding window sample ;in, Indicates the number of process variables. Indicates the length of the sliding time window. Indicates the first In the nth window sample The normalized time series sequence corresponding to each time step , ; By introducing a position encoding vector into the normalized time series at each time step, the enhanced time step input representation is obtained: ;in, Indicates the first The position encoding vector corresponding to each time step.

5. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to claim 4, characterized in that, The method for obtaining the temporal dependency feature matrix at each time step is as follows: Linear projection and layer normalization operations are performed on the time step input representation after adding the position encoding vector to obtain the linearly transformed embedded features. Construct an embedding feature sequence from the embedding features; The multi-head self-attention mechanism of the Transformer module processes the embedded feature sequence to obtain the output features of each attention head. The output features of all attention heads are concatenated and fused through the output mapping matrix to obtain the output features of the multi-head self-attention mechanism. After the output features of the multi-head self-attention mechanism are processed by the feedforward network, residual connection and layer normalization, the output feature matrix obtained is the temporal dependency feature matrix of each sliding window sample.

6. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to claim 5, characterized in that, The embedded features after linear transformation ;in, For the mapping weight matrix, For bias vectors, Indicates the embedding feature dimension. Presentation layer normalization operation; The embedded feature sequence ; embed feature sequences Input multi-head self-attention mechanism, through the first The query projection matrix, key projection matrix, and value projection matrix corresponding to the attention head are obtained to obtain the first attention head. A query matrix for each attention head Key matrix Sum matrix The relevance weights between each time step are calculated using the query matrix and the key matrix, and then applied to the value matrix. , obtained the Output features of each attention head ;in, This is the scaling factor; Output characteristics of multi-head self-attention mechanisms: ;in, Indicates the number of heads of attention. This represents the output mapping matrix. Indicates a splicing operation; No. The temporal dependency feature matrix obtained after modeling the temporal features of the sliding window samples using the Transformer module is as follows: ; Among them, the output feature matrix The row vector Indicates the first The window sample at the th The temporal dependency feature vector corresponding to each time step.

7. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to claim 6, characterized in that, The method for calculating the dynamic fusion weights is as follows: The temporal dependency feature matrix obtained from the Transformer module in step four is... Perform time-dimensional mapping to obtain the aligned temporal dependency feature matrix The spatial feature matrix extracted by the convolutional network in step three With time-dependent feature matrix The joint input is formed by concatenating the features along the dimension. Dynamic fusion weights are generated through a gating network. ;in, and These are the learnable parameters of the gated network. Using the Sigmoid activation function, weights are dynamically fused. This is the gating factor matrix; Based on dynamic fusion weights Spatial coupling characteristics With time-dependent features Weighted fusion is performed to obtain the final fusion features. for: .

8. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to any one of claims 5-7, characterized in that, During single-step prediction, the fusion feature matrix corresponding to the current input window is used. Generate the prediction result for the next time step, and obtain the time. Predicted values: ;in, and These represent the weight matrix and bias term of the prediction layer, respectively.

9. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to claim 8, characterized in that, A recursive sliding window approach is used, feeding back the previous prediction result into the input window and combining it with existing historical observations to form the input for the next prediction, which is then used to generate the next prediction. Recursive input window samples of step prediction results Among them, the first The step prediction value is expressed as: ; Indicates the length of the sliding time window; Indicates the multi-step prediction step size; This represents the prediction mapping function, which is composed of the knowledge-enhanced graph convolutional module, the Transformer module, the gated fusion module, and the prediction layer. This represents the historical normalized multivariate observation vector in the input window. This represents the multivariate prediction vector obtained from the preceding prediction steps. Establish corresponding prediction branches for multiple process variables: The process variable at the th ... Each sliding window sample corresponds to the prediction start time. next future The sequence of prediction results at each time step is as follows: ;in, They represent the first A process variable at time 1 The predicted value.

10. The method for multi-step fault prediction in chemical processes based on knowledge-enhanced graph Transformer according to claim 9, characterized in that, During training, the error between the actual observations and the predicted values ​​is used as the optimization objective. The trainable parameters in the knowledge-enhanced graph convolution module, the Transformer temporal modeling module, the gated fusion module, and the prediction layer are jointly updated through the backpropagation algorithm to achieve end-to-end training. The root mean square error is used as the loss function, which is: ; in, Indicates the number of process variables. Indicates the multi-step prediction step size. Indicates the first A process variable at time Normalized true observations Indicates the first A process variable at time The predicted value.