Fault analysis methods, apparatus and equipment
By combining knowledge graphs and GCN models with Word2Vec models, fault information is automatically analyzed, solving the problems of high operation and maintenance costs and low accuracy in existing technologies, and achieving efficient and accurate fault analysis.
Patent Information
- Application Number
- CN202411578357.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-06
- Publication Date
- 2026-01-30
- Estimated Expiration
- 2044-11-06
AI Technical Summary
Existing technologies rely on the experience of technical experts for fault analysis, resulting in high maintenance costs and low accuracy, and making it difficult to handle complex queries and keyword precision limitations.
By employing knowledge graphs, GCN models, and Word2Vec models, fault information is automatically analyzed and fault types are determined through graph structure learning and reasoning.
It improves the accuracy and efficiency of fault analysis, reduces operation and maintenance costs, supports complex queries, and enhances user satisfaction and service quality.
Smart Images

Figure CN119676051B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of artificial intelligence technology, and in particular to a fault analysis method, apparatus, and device. Background Technology
[0002] When performing fault maintenance on broadband networks, fault analysis typically relies on the experience and knowledge of technical experts. For example, fault analysis can be conducted through manual services provided by technical experts, or by searching for fault cases using keyword matching within a fault case database built upon the experience and knowledge of technical experts.
[0003] However, the aforementioned fault analysis methods based on manual services increase the repetitive work of technical experts, leading to higher operation and maintenance costs. On the other hand, the fault analysis methods based on fault case databases are limited by the precision of the extracted keywords, resulting in lower accuracy of fault analysis. Summary of the Invention
[0004] In view of the above problems, embodiments of this application provide a fault analysis method, apparatus, and device to overcome or at least partially solve the above problems.
[0005] A first aspect of this application provides a fault analysis method, the method comprising:
[0006] Receive fault information input by the user, the fault information including at least one of a fault description and an error code;
[0007] The target node corresponding to the fault information is obtained from a pre-established knowledge graph. The knowledge graph contains nodes corresponding to different fault descriptions, error codes, processing methods, and fault types. Whether there is an edge between two nodes in the knowledge graph is determined based on whether there is a correlation between the information corresponding to the two nodes.
[0008] Obtain the adjacency matrix corresponding to the knowledge graph, and select the next connected node starting from the target node in the knowledge graph to obtain the target node sequence. The adjacency matrix is used to represent the connection relationship between different nodes in the knowledge graph.
[0009] The vector representation of each node in the target node sequence is determined by a pre-trained Word2Vec model, thus obtaining the target node feature matrix;
[0010] By using a pre-trained graph convolutional neural network (GCN) model, fault analysis is performed based on the target node feature matrix and the adjacency matrix to obtain the target fault type corresponding to the fault information.
[0011] A second aspect of this application provides a fault analysis apparatus, the apparatus comprising:
[0012] An information receiving module is used to receive fault information input by a user, wherein the fault information includes at least one of a fault description and an error code;
[0013] The first processing module is used to obtain the target node corresponding to the fault information from a pre-established knowledge graph. The knowledge graph contains nodes corresponding to different fault descriptions, error codes, processing methods, and fault types. Whether there is an edge between two nodes in the knowledge graph is determined based on whether there is a correlation between the information corresponding to the two nodes.
[0014] The second processing module is used to obtain the adjacency matrix corresponding to the knowledge graph, and to select the next connected node starting from the target node in the knowledge graph to obtain the target node sequence. The adjacency matrix is used to represent the connection relationship between different nodes in the knowledge graph.
[0015] The third processing module is used to determine the vector representation of each node in the target node sequence through a pre-trained Word2Vec model, and obtain the target node feature matrix.
[0016] The fault analysis module is used to perform fault analysis based on the target node feature matrix and the adjacency matrix using a pre-trained graph convolutional neural network (GCN) model, and to obtain the target fault type corresponding to the fault information.
[0017] A third aspect of this application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the fault analysis method described in the first aspect.
[0018] A fourth aspect of this application provides a computer-readable storage medium having a computer program / instructions stored thereon, which, when executed by a processor, implements the steps of the fault analysis method as described in the first aspect.
[0019] The embodiments of this application include the following advantages: By utilizing knowledge graphs to represent different fault descriptions, error codes, processing methods, and fault types, as well as their interrelationships, in the form of a graph structure, the fault analysis problem is transformed into a graph structure learning and reasoning problem applicable to the GCN model. Combined with the Word2Vec model, effective feature input is provided to the GCN model. This enables the GCN model to accurately capture and analyze the complex relationships between fault types based on the adjacency matrix corresponding to the knowledge graph and the node feature matrix determined by the Word2Vec model. This automatically and accurately determines the target fault type corresponding to the fault information input by the user. This solves the problems of high maintenance costs caused by repetitive work by technical experts and low accuracy of fault analysis due to the precision limitations of the mined keywords in traditional fault analysis methods, thus improving user satisfaction and service quality. Attached Figure Description
[0020] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0021] Figure 1 This is a flowchart illustrating the implementation of a fault analysis method in an embodiment of this application;
[0022] Figure 2 This is a schematic diagram of functional modules in a fault analysis system according to an embodiment of this application;
[0023] Figure 3 This is a schematic diagram of the execution flow of a knowledge graph construction module in an embodiment of this application;
[0024] Figure 4 This is a schematic diagram of the execution flow of a fault handling module in an embodiment of this application;
[0025] Figure 5 This is a schematic diagram of the execution flow of a GCN model training and inference module in an embodiment of this application;
[0026] Figure 6 This is a schematic diagram of the execution flow of a data acquisition and preprocessing module in an embodiment of this application;
[0027] Figure 7 This is a schematic diagram of the execution flow of a feature extraction module in an embodiment of this application;
[0028] Figure 8This is a schematic diagram of a GCN model training process in an embodiment of this application;
[0029] Figure 9 This is a schematic diagram of the structure of a fault analysis device according to an embodiment of this application;
[0030] Figure 10 This is a schematic diagram of an electronic device according to an embodiment of this application. Detailed Implementation
[0031] To facilitate understanding of the technical solutions provided in this application, the main technical concepts involved in the embodiments of this application are briefly described below.
[0032] Graph Convolutional Network (GCN) model: a deep learning model used to process graph-structured data. It can effectively extract features from nodes in a graph and perform classification tasks.
[0033] The pandas library is a data analysis tool library used for processing structured data.
[0034] Jieba is a Chinese word segmentation tool.
[0035] The Term Frequency-Inverse Document Frequency (TF-IDF) algorithm is a statistical method used to evaluate the importance of a word to a document in a corpus.
[0036] The TfidfVectorizer class is used to convert text into TF-IDF feature vectors.
[0037] Gensim is a Python library for performing tasks such as topic modeling, document similarity analysis, and text mining. It is capable of handling large-scale text data.
[0038] The Word2Vec model is a computational model that maps each word in a vocabulary to a fixed-size vector. This model can capture the semantic and syntactic features of words and is commonly used in natural language processing.
[0039] The `torch.nn.Module` class, `GCN`, is a base class used to build all neural network modules. The `GCN` class is a GCN model implemented based on this base class, specifically designed for processing graph-structured data.
[0040] Adam: An optimization algorithm for deep learning that can adaptively adjust the learning rate of a model, suitable for solving large-scale machine learning problems.
[0041] The DataLoader class is used for batch loading of data and is a commonly used data preprocessing tool when training neural networks.
[0042] Broadband Switching System (BSS): This refers to a switching system used to handle broadband communications. It is primarily responsible for data transmission and switching in broadband networks.
[0043] When operating and maintaining broadband networks, fault analysis typically relies on the experience and knowledge of technical experts. For example, fault analysis can be performed through manual services provided by technical experts, or by searching for fault cases using keyword matching within a fault case database built upon the experience and knowledge of technical experts.
[0044] However, the aforementioned fault analysis method based on manual services increases the repetitive work of technical experts, leading to increased operation and maintenance costs; while the fault analysis method based on fault case databases has the following main problems:
[0045] 1. It is difficult to accurately mine keywords based on the characteristics of fault cases, so the fault analysis is limited by the precision of the mined keywords, resulting in low accuracy.
[0046] 2. Continuous manual optimization of keyword weight calculation and matching algorithms is required to ensure the relevance of keywords and fault case entries, resulting in high operation and maintenance costs.
[0047] 3. As the database of fault cases continues to grow, the system's processing capacity and efficiency may be affected.
[0048] 4. It lacks the ability to handle complex queries. If the user enters a variety of keyword combinations, the system will be unable to perform the query.
[0049] To address the problems existing in the aforementioned related technologies, this application proposes a fault analysis method, apparatus, and device. By applying knowledge graphs, GCN models, and Word2Vec models to the fault analysis system, it enables rapid and accurate fault analysis and handling method recommendations. This solves the problems existing in related technologies, such as high operation and maintenance costs, insufficient accuracy, limited processing capabilities, low efficiency, large workload of manual intervention, and inability to support complex queries, thereby effectively improving user satisfaction and service quality.
[0050] The following description, in conjunction with the accompanying drawings, details a fault analysis method, apparatus, and device provided in this application through some embodiments and application scenarios.
[0051] Firstly, referring to Figure 1 The diagram shown is an implementation flowchart of a fault analysis method provided in this application embodiment. This method can be applied to fault operation and maintenance scenarios such as broadband networks, manufacturing production lines, automobile repair services, and medical equipment maintenance, and can be executed by a fault analysis system. The method includes the following steps:
[0052] Step S11: Receive fault information input by the user, the fault information including at least one of fault description and error code.
[0053] In practical implementation, the fault analysis system pre-constructs input interfaces such as web pages to receive fault information input by users. A schematic diagram of the functional modules in the fault analysis system is shown below. Figure 2 As shown, the fault analysis system includes a data acquisition and preprocessing module, a feature extraction module, a knowledge graph construction module, a GCN model training and inference module, and a fault processing module.
[0054] Optionally, after receiving the fault information input by the user, the fault information is preprocessed using Natural Language Processing (NLP) technology, such as word segmentation and vocabulary filtering, to improve the information quality.
[0055] Step S12: Obtain the target node corresponding to the fault information from the pre-established knowledge graph. The knowledge graph contains nodes corresponding to different fault descriptions, error codes, processing methods, and fault types. Whether there is an edge between two nodes in the knowledge graph is determined based on whether there is a correlation between the information corresponding to the two nodes.
[0056] The fault types can include: Internet Protocol TeleVision (IPTV), mobile phones, landlines, broadband, networks, and computers, etc.; the fault descriptions can include: incorrect password, no IPTV channel, IPTV buffering, and unsuccessful registration, etc.; the handling methods can include: checking the BSS system, checking the optical modem channel, and verifying port traffic, etc.
[0057] In practice, Figure 3The diagram illustrates the execution flow of the knowledge graph construction module. It pre-establishes nodes corresponding to different fault descriptions, error codes, handling methods, and fault types. Based on the existence of relationships (such as causal relationships) among these different fault descriptions, error codes, handling methods, and fault types, it determines whether edges (directed or undirected edges) can be established between corresponding nodes. For example, considering that IPTV buffering is usually caused by IPTV faults, it can be determined that there is a relationship between the fault type "IPTV" and the fault description "IPTV buffering." Therefore, an edge is established between the node corresponding to "IPTV" and the node corresponding to "IPTV buffering" to connect the two nodes. After establishing all nodes and edges, the graph structure (directed or undirected) formed by these nodes and edges can be determined as the knowledge graph.
[0058] Understandably, the structured representation of knowledge graphs clarifies the relationships between fault types, error codes, fault descriptions, and handling methods, thereby improving the efficiency and accuracy of fault analysis.
[0059] Optionally, a directed graph is obtained by establishing directed edges between the nodes based on whether there is a correlation between the different fault descriptions, error codes, processing methods, and fault types, and the type of the correlation.
[0060] For example, for the first relation type (the association between the corresponding fault type and fault description), a directed edge is established from the node corresponding to the fault type to the node corresponding to the fault description. For example, for a password error caused by an IPTV fault, it can be determined that there is an association between the IPTV fault and the password error that conforms to the first relation type, and a directed edge is established accordingly from the node corresponding to the fault type "IPTV" to the node corresponding to the fault description "password error".
[0061] For example, for the second relationship type (the association between the corresponding fault description and the handling method), a directed edge is established from the node corresponding to the fault description to the node corresponding to the handling method. For instance, a directed edge is established from the node corresponding to the fault description "IPTV stuttering" to the node corresponding to the handling method "checking the BSS system" to represent that "checking the BSS system" is a handling method for the fault description "IPTV stuttering"; a directed edge is established from the node corresponding to the fault description "IPTV cannot register a node" to the node corresponding to the handling method "checking the optical modem channel" to represent that "checking the optical modem channel" is a handling method for the fault description "IPTV cannot register a node".
[0062] Optionally, after obtaining the directed graph (or undirected graph) containing the nodes and edges, nodes with a degree (i.e., the number of edges connected to that node) of 0 are first removed from the directed graph (or undirected graph), that is, isolated points are removed from the directed graph (or undirected graph). Then, the list of edges is updated to reduce irrelevant information. The directed graph (or undirected graph) after removing isolated points is then used as the knowledge graph, thereby ensuring the accuracy of fault analysis.
[0063] Optionally, to facilitate subsequent data processing operations on the knowledge graph, graph structure encoding is performed on the knowledge graph. Specifically, a unique ID is assigned to each node in the knowledge graph. For example, the names of different nodes (which can be the fault description, error code, processing method, or fault type corresponding to the node) are mapped to different integer IDs, and the source node ID and target node ID of each edge in the knowledge graph are determined to obtain a list of edges. This realizes the encoding of the graph structure, which can convert complex text information into a machine-readable format, thus providing an input basis for subsequent related models.
[0064] For example, an empty set can be created to store the names of all nodes in the knowledge graph. Then, all nodes in the knowledge graph are traversed, and the node names are added to the set. A mapping table records the unique integer ID that each node name maps to. A list of edges is then created to record the source node ID and target node ID determined for each edge. For example, if the node ID corresponding to IPTV is 0, the node ID corresponding to broadband is 2, the node ID corresponding to password error is 20, the node ID corresponding to IPTV buffering is 21, and the node ID corresponding to network unusable is 22, then the edge between IPTV and the node corresponding to password error, in the format of [source node, target node] (i.e., [IPTV, fault]), can be recorded in the edge list as [0, 20].
[0065] After establishing the knowledge graph, fault information can be matched with the information corresponding to each node in the knowledge graph to obtain the target node corresponding to the fault information (which can be represented by the name or ID of the relevant node). It is understood that the target node refers to the node corresponding to each of the fault description and error code information in the fault information. When the fault information contains multiple pieces of such information (corresponding to complex queries), the GCN model performs fault analysis based on the feature matrix of the target node associated with the fault information, enabling reliable and efficient processing of the complex queries.
[0066] Step S13: Obtain the adjacency matrix corresponding to the knowledge graph, and select the next connected node starting from the target node in the knowledge graph to obtain the target node sequence. The adjacency matrix is used to represent the connection relationship between different nodes in the knowledge graph.
[0067] In practical implementation, the adjacency matrix can be read from a designated storage area. For each target node, the target node is designated as the current node. The selection probability of each connected node is determined based on the number of edges between the current node and each of its connected nodes, or based on the degree of each connected node. Then, based on the selection probability, the next connected node is selected from among the connected nodes. This next connected node is designated as the current node, and the aforementioned steps are repeated until multiple nodes, including the target node, that meet a preset number of nodes are selected. The multiple nodes selected for each target node are then summarized to obtain the target node sequence.
[0068] Step S14: Determine the vector representation of each node in the target node sequence using a pre-trained Word2Vec model to obtain the target node feature matrix.
[0069] In practice, the vector representation of each node in the target node sequence is determined by a pre-trained Word2Vec model, and the vector representations of all nodes are combined into a feature matrix. Each column of the feature matrix represents a feature dimension of the feature vector, and each row represents the feature vector of a node, thereby obtaining the target node feature matrix.
[0070] Step S15: Using a pre-trained graph convolutional neural network (GCN) model, perform fault analysis based on the target node feature matrix and the adjacency matrix to obtain the target fault type corresponding to the fault information.
[0071] In practical implementation, the pre-trained GCN model is loaded on the backend, and the target node feature matrix and adjacency matrix obtained in the preceding steps are input into the GCN model to obtain the target fault type. Then, the target fault type is displayed on the frontend, for example, using the Vue frontend framework to show the target fault type to the user. Thus, by loading the trained GCN model, the fault analysis system can quickly and accurately analyze the fault information input by the user, thereby providing the user with real-time fault analysis services.
[0072] The technical solution of this application utilizes a knowledge graph to represent different fault descriptions, error codes, processing methods, and fault types, as well as their relationships, in the form of a graph structure. This transforms the fault analysis problem into a graph structure learning and reasoning problem applicable to the GCN model. Combined with the Word2Vec model, it provides effective feature input to the GCN model. This enables the GCN model to accurately capture and analyze the complex relationships between fault types based on the adjacency matrix corresponding to the knowledge graph and the node feature matrix determined by the Word2Vec model. Consequently, it automatically and accurately determines the target fault type corresponding to the fault information input by the user. This solves the problems of high maintenance costs caused by repetitive work by technical experts and low accuracy in fault analysis due to the precision limitations of the mined keywords in traditional fault analysis methods, thus improving user satisfaction and service quality.
[0073] As one possible implementation, before obtaining the adjacency matrix corresponding to the knowledge graph, the method further includes:
[0074] The value of the corresponding element in the adjacency matrix for each pair of nodes in the knowledge graph is determined based on the number of edges between each pair of nodes or the reciprocal of the degree of the nodes.
[0075] In practical implementation, the number of edges between every two nodes in the knowledge graph (i.e., the edge weights) is counted and used as the value of the corresponding element in the adjacency matrix to reflect the strength of the relationship between the two nodes. This helps the GCN model comprehensively consider the importance of the relationships between the information corresponding to each node during graph convolution, thereby improving model accuracy. Alternatively, the degree of each node in the knowledge graph is counted, and the reciprocal of the node degree (e.g., the degree of one of two nodes, or the sum of the degrees of two nodes) is used as the value of the corresponding element in the adjacency matrix for that two nodes. This reduces the impact of nodes with high degrees on the graph convolution process (i.e., on the fault analysis results). This can further improve the accuracy of fault analysis.
[0076] For example, create an N×N matrix, where N represents the total number of nodes. If node i is directly connected to node j, set a non-zero element (such as 1) at the corresponding position in the matrix to indicate that there is a connection between the two nodes, thus creating an adjacency matrix. For instance, if there is an edge between the node corresponding to "IPTV" (node ID 0) and the node corresponding to "incorrect password" (node ID 20), then set a non-zero element in the 0th row and 20th column of the aforementioned matrix. The specific value of this element is determined by the number of edges between the two nodes or the reciprocal of the degree of the node.
[0077] As one possible implementation method, refer to Figure 4The diagram shows the execution flow of the fault handling module. The method further includes:
[0078] Obtain from the knowledge graph each second node that corresponds to the processing method and has an edge with the first node corresponding to the target fault type;
[0079] Based on the number of edges between the first node and each of the second nodes, the processing methods corresponding to each of the second nodes are sorted to obtain a recommended list of processing methods.
[0080] In practical implementation, the knowledge graph is queried based on the target fault type to find various processing methods that are associated with the target fault type. Based on the number of edges (i.e., edge weights) between the node corresponding to the target fault type (i.e., the first node) and the nodes corresponding to each processing method (i.e., each second node), the processing methods are sorted to obtain a recommended list of processing methods. For example, the processing methods are sorted in descending order of edge weight so that processing methods with a strong association with the target fault type (which typically have a higher probability of successful fault repair) are given priority in the recommended list. Finally, the target fault type and the recommended list of processing methods are displayed using the Vue front-end framework.
[0081] In this implementation, users can obtain the fault type and recommended handling method through simple interface input, which can greatly reduce the time spent on manual fault analysis and handling. Moreover, compared with manual service, the real-time data analysis capability of the automatic fault analysis system realized by the GCN model enables decision-makers to obtain the latest analysis results and make quick decisions based on them, thereby improving work efficiency.
[0082] Optionally, the GCN model includes:
[0083] The input layer is used to receive the node feature matrix and the adjacency matrix;
[0084] The first graph convolutional layer is used to perform graph convolution operations on the node feature matrix and the adjacency matrix to obtain hidden layer features. After processing the hidden layer features using the Rectified Linear Unit (ReLU) activation method, a portion of the hidden layer features are randomly discarded and output.
[0085] The second graph convolutional layer is used to perform graph convolution operations on the adjacency matrix and the hidden layer features output by the first graph convolutional layer to obtain new hidden layer features and output them.
[0086] The output layer is used to determine the fault type and output it based on the hidden layer features output by the second graph convolutional layer.
[0087] In specific implementation, refer to Figure 5 The diagram illustrating the execution flow of the GCN model training and inference module shows that during the model training phase, a class `GCN` inheriting from `torch.nn.Module` can be created, defining an input layer, two graph convolutional network convolution (GCNConv) layers (i.e., the first and second graph convolutional layers), and an output layer. The first graph convolutional layer extracts features from the original graph data; its input feature dimension is the number of input feature vectors for each node in the input data, and its output feature dimension can be set to 18. The input feature dimension of the second graph convolutional layer is the output feature dimension of the first graph convolutional layer (e.g., 18), and its output feature dimension is the number of fault types (i.e., the probability distribution of each fault type classification; the fault type classification with the highest probability distribution will be the model output).
[0088] In this implementation, by constructing a GCN model containing multiple graph convolutional layers, it is possible to effectively extract deep features from graph structure data, thereby improving the accuracy of fault analysis.
[0089] As one possible implementation, the Word2Vec model is trained through the following steps:
[0090] Step S21: Obtain first historical fault data, which includes different fault descriptions, error codes, processing methods, and fault types.
[0091] In practice, the SQLAlchemy library is used to connect to the MySQL database, and the historical fault data (i.e., the first historical fault data) is extracted based on the read_sql_query method of the pandas library.
[0092] Optionally, refer to Figure 6 The diagram illustrates the execution flow of the data acquisition and preprocessing module. It uses Python scripts to clean historical fault data. For example, the `duplicates` method is used to remove duplicate records, keeping only the first duplicate and deleting subsequent duplicates. This removes duplicate content from fields such as error codes and handling methods, ensuring that each combination of error code and handling method is unique. It also handles missing values in the historical fault data, that is, filling in missing field values. For example, it determines whether a missing field value is numeric or categorical; if numeric, it adds "000," and if categorical, it adds "unknown."
[0093] Step S22: Based on the pre-established stop word list, perform word filtering on the fault descriptions in the first historical fault data.
[0094] In specific implementation, refer to Figure 7 The flowchart of the feature extraction module shown above illustrates that it retrieves a pre-stored stop word file (words.txt) from a specified directory of the system project, loads each stop word in words.txt using the load_stop method written in Python, thereby providing a stop word list for text processing so that meaningless words can be filtered out in subsequent steps.
[0095] The Jieba word segmentation tool was used to segment the fault descriptions in the historical fault data, that is, to divide the relevant text into individual words. Then, a stop word list was used to filter out meaningless words in the segmentation results. The remaining words (i.e., keywords) were labeled with their parts of speech. It can be understood that these remaining words are more representative of the fault characteristics, thus providing rich text for subsequent Word2Vec model learning (and GCN model learning).
[0096] Step S23: Obtain each third node corresponding to the first historical fault data from the knowledge graph.
[0097] In practice, each piece of data in the first historical fault data is matched with the information corresponding to each node in the knowledge graph to obtain each third node corresponding to the first historical fault data.
[0098] Step S24: Determine the selection probability of a node based on its degree, and perform multiple random walks for each third node in the knowledge graph to obtain multiple node sequences corresponding to each third node.
[0099] In practice, the next connected node is randomly selected based on the degree of the node. For example, if the current node is connected to 5 nodes, while its neighbor node A is connected to 10 nodes and node B is connected to 2 nodes, then the probability of node A being selected as the next connected node will be higher than that of node B. Thus, the selection probabilities of nodes A and B are determined, and the next connected node (that is, the new current node) is randomly selected from nodes A and B based on these selection probabilities.
[0100] Step S25: Using the TF-IDF algorithm, determine the vector representation of each node in the plurality of node sequences, and obtain the node feature matrix label associated with each of the plurality of node sequences.
[0101] In practice, the TF-IDF algorithm is used to convert the information corresponding to each node (such as the words in the fault description) into a feature vector (vector representation).
[0102] Specifically, the TF-IDF parameter min_df=6 can be set (to ignore words appearing in fewer than 6 documents, thereby enabling further extraction of key text features). The extract_features method is called to use the TfidfVectorizer class to fit the data, perform vector transformation on the filtered words, obtain the vector representation of each node, and then obtain the node feature matrix label.
[0103] Step S26: Train the Word2Vec model to be trained using the multiple node sequences and their associated node feature labels.
[0104] In practice, a Word2Vec model is initialized using the Word2Vec class from the Gensim library as the Word2Vec model to be trained, and the Word2Vec model parameters are configured, such as setting the vector size (vector_size) to 64 and the window size (window) to 5. The input to the Word2Vec model is a sequence of nodes, and the output is a vector representation of each node, i.e., the node features.
[0105] The Word2Vec model to be trained is trained using the multiple node sequences (i.e., multiple training data) obtained above. For example, the Word2Vec model to be trained can be trained using the `train` method, where the total number of examples is the sum of the total number of node sequences, and the number of iterations is 6. After training is completed, the vector representation of each node, i.e., the node feature, can be obtained through the model's `model.wv` (i.e., word vectors, which provide access to the results of the trained model).
[0106] Understandably, node vector representations generated using random walks and Word2Vec models can capture the potential relationships between nodes, thereby providing richer feature information for GCN models.
[0107] As one possible implementation, the GCN model is trained through the following steps:
[0108] Step S31: Obtain second historical fault data, which includes at least: different fault descriptions and error codes.
[0109] In practice, the second historical fault data may differ from the first historical data. That is, the Word2Vec model and the GCN model are trained separately. In this case, the parameters of the Word2Vec model and the GCN model can be adjusted separately based on the differences between the output of the Word2Vec model and the node feature labels, and the differences between the output of the GCN model and the fault type labels.
[0110] Alternatively, the second historical fault data can be the same as the first historical data, that is, the output of the Word2Vec model can be used as one of the inputs of the GCN model. In this case, the parameters of the Word2Vec model and the GCN model can be adjusted directly based on the difference between the output of the GCN model and the fault type label.
[0111] Step S32: Based on the pre-established label mapping dictionary, determine the fault type label associated with each of the different fault descriptions and error codes in the second historical fault data.
[0112] In practice, a label mapping dictionary is pre-established, which records the mapping relationship between different fault descriptions and error codes and fault type labels.
[0113] For example, a resident in a community reports, "My home broadband network is currently working fine, but IPTV is very choppy and I can't watch TV." The Jieba word segmentation tool is used to segment the aforementioned dialogue text, and a stop word list is used to remove meaningless words to retain key information, ultimately obtaining the key data: [Network is normal, IPTV is choppy]. Then, a mapping relationship is established between the fault description "IPTV is choppy" and the fault type label "IPTV," and a label mapping dictionary is used to record these two mapping relationships.
[0114] When determining the labels, a fault description (or error code) and a label mapping dictionary are taken as input. The `to_label` method searches for fault type labels that match the fault description (or error code) in the mapping dictionary. If a match is found, the `to_label` method returns the corresponding fault type label; otherwise, it returns a default label, such as "unknown". This process is repeated for each data point in the second historical fault dataset to obtain the corresponding fault type label. The iteration process can be accomplished using the `apply` method from the Pandas library, which calls the relevant method for each row of the second historical fault data and stores the results in a new column. This provides labeled data for training the GCN model, enabling it to learn the characteristics of different fault types.
[0115] Step S33: Obtain the adjacency matrix corresponding to the knowledge graph, and based on the knowledge graph and the Word2Vec model, determine the node feature matrix corresponding to each of the different fault descriptions and error codes in the second historical fault data.
[0116] In practical implementation, the pandas library can be used to load the processed second historical fault data (e.g., after data cleaning, word segmentation, and stop word filtering). The `train_test_split` method is used to divide the second historical fault data into three parts: a training set, a validation set, and a test set. For example, the training set can be divided at a 70% ratio, the validation set at 15%, and the test set at 15%. The `test_size` parameter related to the test set size is set to 0.3, and to ensure reproducibility, the `random_state` parameter is assigned a value of 42 to determine the random process of splitting the dataset, ensuring consistency in each split. Then, based on the knowledge graph and the Word2Vec model, the node feature matrices corresponding to the training set, validation set, and test set are determined.
[0117] Step S34: Train the GCN model to be trained using the feature matrices of each node and their respective associated fault type labels.
[0118] In practice, the input feature dimensions and output dimensions are determined based on the characteristics of the dataset, and the hidden layer dimension can be set to 18. Then, the model is instantiated, the dropout ratio is set to 0.6, the cross-entropy loss method is selected as the loss method, the Adam optimizer is selected, and the learning rate (lr) is set to 0.01 and the weight decay (weight_decay) is set to 5e-4.
[0119] The GCN model is trained based on the training set obtained above (i.e., its corresponding node feature matrix). Specifically, the DataLoader class is used to load the relevant data (including the node feature matrix and adjacency matrix), and the batch size is set to batch_size=64.
[0120] During iterative training, each batch of data is traversed, and for each batch, forward propagation is performed to calculate the loss, and backpropagation is performed to update the model parameters. Hyperparameters are adjusted based on the model's performance on the validation set to improve the model's ability to classify fault types. If the model performance does not meet expectations (e.g., accuracy below 90%, recall below 85%, or F1 score below 0.9), the parameters are adjusted again based on the validation set results, i.e., the aforementioned training steps are repeated until the model meets the performance requirements and training ends.
[0121] For example, refer to Figure 8 The diagram illustrates the training process of the GCN model. Taking the GCN model with one input layer, two GCNConv layers, and one output layer as an example, the forward propagation process during the iterative training includes:
[0122] The first GCNConv layer (i.e. the first graph convolutional layer) learns the relationship between nodes through graph convolution operations, and combines node features and graph structure information to output hidden layer features H1. The ReLU activation method is then applied to obtain the non-linearly activated features ReLU(H1). Subsequently, a Dropout layer is applied to randomly discard some hidden features and output them to reduce overfitting.
[0123] The second GCNConv layer (i.e., the second graph convolutional layer) performs graph convolution operations on the adjacency matrix and the hidden layer features output by the first GCNConv layer to further learn the structural information of the graph, obtain new hidden layer features H2, and pass them to the output layer. The adjacency matrix can be passed from the first GCNConv layer or the input layer to the second GCNConv layer.
[0124] The output layer is a linear layer that maps H2 features to fault types, thus obtaining the output result Y_pred.
[0125] Then, the cross-entropy loss method is used to calculate the loss between Y_pred and the corresponding fault type label Y_true.
[0126] The backpropagation process of this model during cyclic training includes:
[0127] Calling the `loss.backward` method initiates the backpropagation process to automatically calculate the gradients of the model parameters associated with the loss. Specifically, for each layer (including the two `GCNConv` layers and the output layer), the gradients of its weights and biases are calculated.
[0128] The model parameter update process during the iterative training process includes:
[0129] The optimizer Adam updates the model parameters based on the calculated gradients. Specifically, after each batch is processed, the accumulated gradients are cleared using the `zero_grad` method, thus preparing for the forward and backward propagation of the next batch. The weights of the two GCNConv layers can be updated using the gradients calculated by the `step` method to optimize model performance.
[0130] Understandably, using the cross-entropy loss method and the Adam optimizer helps improve the model's convergence speed, and updating the weights through backpropagation during training facilitates continuous evaluation of model performance and parameter tuning, ensuring the model's optimization performance in metrics such as accuracy, recall, and F1 score.
[0131] The performance evaluation process of this model during cyclic training includes:
[0132] On the validation set, metrics such as accuracy, recall, and F1 score are calculated. If the current performance of the model is better than the previous best performance, the best performance metrics are updated and the current model state is saved to the GCN model.
[0133] Specifically, the model trained at the moment is used to perform fault analysis on the validation set to obtain the output result (i.e. the predicted fault type) Y_pred. The confusion matrix cm is constructed using the corresponding fault type Y_true and the output result Y_pred.
[0134] The values of TP, TN, FP, and FN are extracted from the confusion matrix cm, where TP (True Positive): cm[1,1], representing the number of samples correctly predicted as positive; TN (True Negative): cm[0,0], representing the number of samples correctly predicted as negative; FP (False Positive): cm[0,1], representing the number of negative samples incorrectly predicted as positive; and FN (False Negative): cm[1,0], representing the number of positive samples incorrectly predicted as negative. Then, the extracted metrics are used to calculate precision, recall, and F1 score according to the following formulas.
[0135] Accuracy refers to the proportion of samples correctly predicted by the model out of the total number of samples. The relevant formula is as follows:
[0136]
[0137] Recall: refers to the proportion of samples correctly predicted as positive out of the total number of samples that were actually predicted as positive. The relevant formula is as follows:
[0138]
[0139] Where tp represents the number of samples correctly predicted as positive by the model; tn represents the number of samples correctly predicted as negative by the model; fp represents the number of negative samples incorrectly predicted as positive by the model; and fn represents the number of positive samples incorrectly predicted as negative by the model.
[0140] For each fault type, the proportion of correctly predicted positive samples by the model to the actual number of positive samples is calculated. For the broadband fault type (i.e., online but unable to access the internet), the recall rate of the GCN model is 85%, which means that among all samples with the actual fault type of broadband fault, the model's correct prediction rate is 85%.
[0141] F1 score: This refers to the balance between recall and precision of a model. The relevant formula is as follows:
[0142]
[0143] In the actual GCN model training process, the F1 score for fault type A was 0.92, where Precision is the accuracy and Recall is the recall. This shows that the GCN model achieves a good balance between precision and recall.
[0144] As one possible implementation, the method further includes:
[0145] Based on user feedback data, generate new data with fault type labels;
[0146] Based on the new data carrying fault type labels, the parameters of the GCN model are adjusted.
[0147] In practical implementation, a feedback mechanism is integrated into the user interface to allow users to evaluate the fault types (and handling methods) output by the GCN model, thereby obtaining feedback data. For example, a rating system of 1 to 5 stars is provided to allow users to rate their satisfaction with the fault types (and handling methods), and a text input box is provided to allow users to submit improvement suggestions (such as providing the actual fault type corresponding to the error message).
[0148] Then, based on user feedback data, new data carrying fault type labels is generated (such as error information that uses the actual fault type provided by the user as the fault type label). Combined with the existing labeled data, semi-supervised learning is used to automatically adjust the GCN model parameters, thereby improving the model's generalization ability and achieving continuous model optimization.
[0149] Based on the above examples and embodiments, the fault analysis method provided in this application can solve the technical problems encountered by employees during fault maintenance, improve the efficiency of fault analysis and handling, reduce the confusion and uncertainty of employees when dealing with new and complex faults, and reduce reliance on technical experts, eliminating the need for frequent assistance. Furthermore, the GCN model is based on graph structure for learning and reasoning, thus possessing a certain degree of interpretability, which helps in understanding how the model performs fault analysis and recommends handling methods. In addition, the GCN model can adapt to new fault types through incremental learning; that is, it can flexibly adjust the model structure as the types of fault cases increase, thereby adapting to new data characteristics and fault modes, which enables it to better adapt to rapidly evolving business environments.
[0150] For the sake of simplicity, the method embodiments are described as a series of actions. However, those skilled in the art should understand that the embodiments of this application are not limited to the described order of actions, because according to the embodiments of this application, some steps can be performed in other orders or simultaneously. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are preferred embodiments, and the actions involved are not necessarily essential to the embodiments of this application.
[0151] Secondly, Figure 9 This is a schematic diagram of a fault analysis device according to an embodiment of this application. The device includes:
[0152] The information receiving module 910 is used to receive fault information input by the user, wherein the fault information includes at least one of a fault description and an error code;
[0153] The first processing module 920 is used to obtain the target node corresponding to the fault information from a pre-established knowledge graph. The knowledge graph contains nodes corresponding to different fault descriptions, error codes, processing methods, and fault types. Whether there is an edge between two nodes in the knowledge graph is determined based on whether there is a correlation between the information corresponding to the two nodes.
[0154] The second processing module 930 is used to obtain the adjacency matrix corresponding to the knowledge graph, and to select the next connected node starting from the target node in the knowledge graph to obtain a target node sequence. The adjacency matrix is used to represent the connection relationship between different nodes in the knowledge graph.
[0155] The third processing module 940 is used to determine the vector representation of each node in the target node sequence through a pre-trained Word2Vec model, and obtain the target node feature matrix.
[0156] The fault analysis module 950 is used to perform fault analysis based on the target node feature matrix and the adjacency matrix using a pre-trained graph convolutional neural network (GCN) model, and to obtain the target fault type corresponding to the fault information.
[0157] The technical solution of this application utilizes a knowledge graph to represent different fault descriptions, error codes, processing methods, and fault types, as well as their relationships, in the form of a graph structure. This transforms the fault analysis problem into a graph structure learning and reasoning problem applicable to the GCN model. Combined with the Word2Vec model, it provides effective feature input to the GCN model. This enables the GCN model to accurately capture and analyze the complex relationships between fault types based on the adjacency matrix corresponding to the knowledge graph and the node feature matrix determined by the Word2Vec model. Consequently, it automatically and accurately determines the target fault type corresponding to the fault information input by the user. This solves the problems of high maintenance costs caused by repetitive work by technical experts and low accuracy in fault analysis due to the precision limitations of the mined keywords in traditional fault analysis methods, thus improving user satisfaction and service quality.
[0158] Optionally, the device further includes a map building module for performing the following steps:
[0159] Establish nodes corresponding to different fault descriptions, error codes, handling methods, and fault types;
[0160] Based on whether there is a correlation between the different fault descriptions, error codes, processing methods, and fault types, and the type of the correlation, directed edges are established between each node to obtain a directed graph;
[0161] The knowledge graph is obtained by removing nodes with a degree of 0 from the directed graph.
[0162] Optionally, the device further includes:
[0163] The fourth processing module is used to determine the value of the element corresponding to each two nodes in the adjacency matrix in the knowledge graph based on the number of edges between each two nodes in the knowledge graph or the reciprocal of the degree of the nodes before obtaining the adjacency matrix corresponding to the knowledge graph.
[0164] Optionally, the device further includes a recommendation module for performing the following steps:
[0165] Obtain from the knowledge graph each second node that corresponds to the processing method and has an edge with the first node corresponding to the target fault type;
[0166] Based on the number of edges between the first node and each of the second nodes, the processing methods corresponding to each of the second nodes are sorted to obtain a recommended list of processing methods.
[0167] Optionally, the GCN model includes:
[0168] The input layer is used to receive the node feature matrix and the adjacency matrix;
[0169] The first graph convolutional layer is used to perform graph convolution operations on the node feature matrix and the adjacency matrix to obtain hidden layer features. After processing the hidden layer features using the ReLU activation method, a portion of the hidden layer features are randomly discarded and output.
[0170] The second graph convolutional layer is used to perform graph convolution operations on the adjacency matrix and the hidden layer features output by the first graph convolutional layer to obtain new hidden layer features and output them.
[0171] The output layer is used to determine the fault type and output it based on the hidden layer features output by the second graph convolutional layer.
[0172] Optionally, the device further includes a Word2Vec model training module for performing the following steps:
[0173] Obtain first historical fault data, which includes: different fault descriptions, error codes, handling methods, and fault types;
[0174] Based on a pre-established list of stop words, vocabulary filtering is performed on the fault descriptions in the first historical fault data;
[0175] Obtain each third node corresponding to the first historical fault data from the knowledge graph;
[0176] The probability of a node being selected is determined based on its degree. Multiple random walks are performed on each of the third nodes in the knowledge graph to obtain multiple node sequences corresponding to each of the third nodes.
[0177] The TF-IDF algorithm is used to determine the vector representation of each node in the multiple node sequences, thereby obtaining the node feature matrix labels associated with each of the multiple node sequences.
[0178] The Word2Vec model to be trained is trained using the multiple node sequences and their associated node feature labels.
[0179] Optionally, the apparatus further includes a GCN model training module for performing the following steps:
[0180] Acquire second historical fault data, which includes at least: different fault descriptions and error codes;
[0181] Based on a pre-established label mapping dictionary, determine the fault type labels associated with different fault descriptions and error codes in the second historical fault data;
[0182] Obtain the adjacency matrix corresponding to the knowledge graph, and based on the knowledge graph and the Word2Vec model, determine the node feature matrix corresponding to each of the different fault descriptions and error codes in the second historical fault data;
[0183] The GCN model to be trained is trained using the feature matrices of each node and their associated fault type labels.
[0184] Optionally, the device further includes a parameter adjustment module for performing the following steps:
[0185] Based on user feedback data, generate new data with fault type labels;
[0186] Based on the new data carrying fault type labels, the parameters of the GCN model are adjusted.
[0187] It should be noted that the device embodiments are similar to the method embodiments, so the description is relatively simple. For relevant details, please refer to the method embodiments.
[0188] This application also provides an electronic device, see embodiments thereof. Figure 10 , Figure 10 This is a schematic diagram of the electronic device proposed in an embodiment of this application. Figure 10 As shown, the electronic device 100 includes a memory 110 and a processor 120. The memory 110 and the processor 120 are connected via a bus for communication. The memory 110 stores a computer program that can run on the processor 120 to implement the steps in the fault analysis method disclosed in the embodiments of this application.
[0189] This application also provides a computer-readable storage medium storing a computer program / instructions thereon, which, when executed by a processor, implements the fault analysis method disclosed in this application.
[0190] This application also provides a computer program product, including a computer program / instructions that, when executed by a processor, implement the fault analysis method disclosed in this application.
[0191] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other.
[0192] Those skilled in the art will understand that embodiments of this application can be provided as methods, apparatus, or computer program products. Therefore, embodiments of this application can take the form of entirely hardware embodiments, entirely software embodiments, or embodiments combining software and hardware aspects. Furthermore, embodiments of this application can take the form of computer program products implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0193] This application describes embodiments with reference to flowchart illustrations and / or block diagrams of methods, systems, devices, storage media, and program products according to embodiments of this application. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing terminal device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal device, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0194] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing terminal device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0195] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal equipment, causing a series of operational steps to be performed on the computer or other programmable terminal equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable terminal equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1The steps of the function specified in one or more boxes.
[0196] Although preferred embodiments of the present application have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of the embodiments of the present application.
[0197] Finally, it should be noted that in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or terminal device that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or terminal device. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or terminal device that includes said element.
[0198] The above provides a detailed description of the fault analysis method, apparatus, and device provided in this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The description of the above embodiments is only for the purpose of helping to understand the method and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.
Claims
1. A method of failure analysis, characterized by, The method comprises: receiving user input failure information, the failure information including at least one of failure description and error code; obtaining the target node corresponding to the failure information from the pre-established knowledge graph, the knowledge graph containing nodes corresponding to different failure descriptions, error codes, processing methods and fault types, and whether there is an edge between two nodes in the knowledge graph being determined according to whether there is an association relationship between the information corresponding to the two nodes; obtaining the adjacency matrix corresponding to the knowledge graph, and performing selection of the next connected node from the target node in the knowledge graph to obtain a target node sequence, the adjacency matrix being used to represent the connection relationship between different nodes in the knowledge graph; determining the vector representation of each node in the target node sequence through a pre-trained Word2Vec model to obtain a target node feature matrix; performing failure analysis according to the target node feature matrix and the adjacency matrix through a pre-trained graph convolutional neural network (GCN) model to obtain the target fault type corresponding to the failure information; obtaining each second node corresponding to a processing method and having an edge with the first node corresponding to the target fault type from the knowledge graph; sorting the processing methods corresponding to each of the second nodes according to the number of edges between the first node and each of the second nodes to obtain a processing method recommendation list.
2. The method of claim 1, wherein, The knowledge graph is established by the following steps: establishing nodes corresponding to different failure descriptions, error codes, processing methods and fault types; establishing directed edges between each of the nodes according to whether there is an association relationship between the different failure descriptions, error codes, processing methods and fault types and the type of the association relationship to obtain a directed graph; removing nodes with a degree of 0 from the directed graph to obtain the knowledge graph.
3. The method of claim 1, wherein, Before obtaining the adjacency matrix corresponding to the knowledge graph, the method further comprises: determining the value of the element corresponding to each of the two nodes in the adjacency matrix according to the number of edges between each of the two nodes in the knowledge graph or the reciprocal of the degree of the node.
4. The method of claim 1, wherein, The GCN model comprises: an input layer for receiving a node feature matrix and an adjacency matrix; a first graph convolutional layer for performing graph convolutional operation on the node feature matrix and the adjacency matrix to obtain hidden layer features, and after processing the hidden layer features using a linear rectifier function (ReLU) activation method, randomly discarding part of the hidden layer features and outputting; a second graph convolutional layer for performing graph convolutional operation on the adjacency matrix and the hidden layer features output by the first graph convolutional layer to obtain new hidden layer features and output; an output layer for determining a fault type according to the hidden layer features output by the second graph convolutional layer and outputting.
5. The method of claim 1, wherein, The Word2Vec model is trained by the following steps: obtaining first historical failure data, the first historical failure data including different failure descriptions, error codes, processing methods and fault types; perform vocabulary filtering on the fault description in the first historical fault data based on a pre-established stop word list; obtain each third node corresponding to the first historical fault data from the knowledge graph; determine a selected probability of a node based on the degree of the node, and perform multiple random walks in the knowledge graph for each of the third nodes to obtain a plurality of node sequences corresponding to each of the third nodes respectively; determine a vector representation of each node in the plurality of node sequences respectively using a Term Frequency-Inverse Document Frequency (TF-IDF) algorithm to obtain a node feature matrix label associated with each of the plurality of node sequences respectively; train a Word2Vec model to be trained using the plurality of node sequences and the node feature matrix labels associated therewith.
6. The method of claim 1, wherein, The GCN model is trained by the following steps: obtain second historical fault data, the second historical fault data at least including different fault descriptions and error codes; determine fault type labels associated with different fault descriptions and error codes in the second historical fault data based on a pre-established label mapping dictionary; obtain an adjacency matrix corresponding to the knowledge graph, and determine node feature matrices corresponding to different fault descriptions and error codes in the second historical fault data based on the knowledge graph and the Word2Vec model; train a GCN model to be trained using each of the node feature matrices and the fault type labels associated therewith.
7. The method according to any of claims 1 to 6, characterized in that, The method further comprises: generating new data carrying fault type labels according to feedback data from a user; adjusting parameters of the GCN model based on the new data carrying fault type labels.
8. A failure analysis apparatus characterized by comprising: The device comprises: an information receiving module configured to receive fault information input by a user, the fault information including at least one of a fault description and an error code; a first processing module configured to obtain a target node corresponding to the fault information from a pre-established knowledge graph, the knowledge graph including nodes corresponding to different fault descriptions, error codes, processing methods, and fault types, and whether there is an edge between two nodes in the knowledge graph being determined according to whether there is an association relationship between information corresponding to the two nodes; a second processing module configured to obtain an adjacency matrix corresponding to the knowledge graph, and select a next connected node in the knowledge graph starting from the target node to obtain a target node sequence, the adjacency matrix being used to represent a connection relationship between different nodes in the knowledge graph; a third processing module configured to determine a vector representation of each node in the target node sequence by using a pre-trained Word2Vec model to obtain a target node feature matrix; a fault analysis module configured to perform fault analysis according to the target node feature matrix and the adjacency matrix by using a pre-trained Graph Convolutional Neural Network (GCN) model to obtain a target fault type corresponding to the fault information. The recommendation module obtains, from the knowledge graph, each second node corresponding to a processing method and having an edge with the first node corresponding to the target fault type; and sorts the processing methods corresponding to the second nodes according to the number of edges between the first node and each second node, to obtain a processing method recommendation list.
9. An electronic device comprising a memory, a processor, and a computer program stored on the memory, wherein the computer program comprises instructions that, when executed by the processor, cause the electronic device to perform the method of any one of claims 1-8. The processor executes the computer program to implement the fault analysis method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Fault diagnosis method and system for lightweight electric propulsion system
CN118468208A