Repair method, apparatus, device, medium, and program product

CN122777348APending Publication Date: 2026-09-18INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610764203.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-05-29
Publication Date
2026-09-18

AI Technical Summary

Technical Problem

当系统运行环境、业务负载模式或故障分布发生变化时,模型无法根据实际执行效果进行在线调整,导致策略推荐的准确性逐步下降,适应新场景的速度较慢

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122777348A_ABST
    Figure CN122777348A_ABST
Patent Text Reader

Abstract

This application provides a repair method, apparatus, device, storage medium, and program product, which can be applied to the field of artificial intelligence technology. The method includes: acquiring fault information and its context information; performing policy matching using a three-dimensional policy fit matrix to obtain candidate policies and candidate channels; using a repair knowledge graph to infer and verify the candidate policies and candidate channels to obtain optimized policies and channels; performing predictive scheduling, using a channel prediction model to predict the health of each channel at future execution times, making scheduling decisions based on health and collaboration factors, and executing repair operations; acquiring execution results, updating the three-dimensional policy fit matrix and channel prediction model online through a dual-loop feedback mechanism, and updating the execution results to the repair knowledge graph. This application can achieve context-aware policy matching, predictive multi-channel collaborative scheduling, dual-loop self-learning optimization, and knowledge-driven policy recommendation, improving the repair success rate.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of artificial intelligence technology, and more specifically to a repair method, apparatus, device, medium, and program product. Background Technology

[0002] In large-scale distributed systems and cloud computing environments, automatic system fault repair is a key technology for ensuring high service availability. When a system failure occurs, a suitable repair strategy needs to be selected from multiple candidate strategies, and the repair operation is completed through the corresponding execution channel. Currently, existing technologies mainly adopt a rule engine-based strategy selection method, which maps fault types to fixed repair strategies through predefined "condition-action" rules. These rules are manually written by operations experts and use static priority ranking. In addition, some solutions employ machine learning-based strategy recommendation, modeling strategy selection as a classification problem and using classifiers such as random forests and support vector machines for offline training. The model parameters remain unchanged after deployment. Other solutions use multi-channel scheduling based on workflow orchestration, which uses a workflow engine to orchestrate the execution flow of multiple repair tools. Channel selection depends on pre-configured templates or a manually specified order.

[0003] However, the aforementioned existing technical solutions all have significant shortcomings in practical applications. First, existing solutions only perform policy matching based on the static characteristics of the current fault, without considering contextual information such as the historical evolution path of the fault, the business characteristics of the application to which it belongs, and the time of occurrence. In actual operation and maintenance scenarios, the optimal repair strategy for the same error code often differs significantly under different time windows, different business types, and different fault sequences, making it difficult to achieve accurate matching based solely on static characteristics.

[0004] Secondly, existing solutions employ a reactive scheduling model, making decisions solely based on the current channel's load and response time, failing to predict future availability or performance changes. When a channel is about to experience load spikes, resource contention, or partial failures, the system cannot proactively mitigate these risks, leading to failed or delayed repair tasks. Furthermore, simultaneous execution of multiple channels may result in resource conflicts or negative synergies, and current technologies lack the ability to quantify and globally optimize these inter-channel synergies.

[0005] Furthermore, machine learning-based solutions typically employ an offline training and online fixation model, where model parameters are not updated once deployed. When the system's operating environment, business load patterns, or fault distribution change, the model cannot adjust online based on actual performance, leading to a gradual decline in the accuracy of strategy recommendations and slow adaptation to new scenarios. Finally, existing systems treat each repair event as an independent task. For recurring similar faults, successful repair experience cannot be structurally recorded and reused, lacking an effective representation of the complex relationships between faults, strategies, and effects. This results in difficulties in knowledge transfer, and new applications or new fault types face a "cold start" problem. Summary of the Invention

[0006] In view of the above problems, embodiments of this application provide a repair method, apparatus, device, medium, and program product.

[0007] According to a first aspect of this application, a repair method is provided, comprising: obtaining fault information and context information corresponding to the fault information; performing policy matching using a three-dimensional policy fit matrix based on the fault information and context information to obtain candidate policies and candidate channels; wherein the three-dimensional policy fit matrix is ​​used to characterize the degree of fit between fault type, policy type and channel type; performing reasoning verification on candidate policies and candidate channels using a repair knowledge graph to obtain optimized policies and channels; performing predictive scheduling on the optimized policies and channels, using a channel prediction model to predict the health of each channel at future execution time, making scheduling decisions based on health and channel synergy factors, and performing repair operations; obtaining the execution results of the repair operations, updating the three-dimensional policy fit matrix and channel prediction model online through a double closed-loop feedback mechanism, and updating the execution results of the repair operations to the repair knowledge graph.

[0008] According to embodiments of this application, the context information includes time context, historical context, and application context; wherein, the time context includes the time of failure and time segment characteristics; the historical context is obtained by encoding historical failure sequences; and the application context includes application identifier and service type.

[0009] According to an embodiment of this application, the three-dimensional strategy adaptation matrix is ​​a three-dimensional array, and the three dimensions of the three-dimensional array correspond to the fault type, strategy type and channel type, respectively; each element in the three-dimensional array is used to store the adaptation value of the corresponding combination of fault type, strategy type and channel type; the adaptation value is dynamically updated according to the success rate and effect score of historical repair operations.

[0010] According to an embodiment of this application, strategy matching is performed using a three-dimensional strategy fit matrix to obtain candidate strategies and candidate channels, including: determining the fault type based on fault information and determining the context fit weight based on context information; retrieving the fit value corresponding to the fault type in the three-dimensional strategy fit matrix; calculating the matching score of each strategy type and channel type combination by combining the context fit weight; and selecting the strategy type and channel type with the highest matching score as candidate strategies and candidate channels.

[0011] According to embodiments of this application, the repair knowledge graph includes fault entities, strategy entities, channel entities, and effect entities; wherein, entities are connected by relational edges, and the relational edges include at least: the repair relationship between the fault entity and the strategy entity, the execution relationship between the strategy entity and the channel entity, and the causal relationship between the strategy entity and the effect entity; the repair knowledge graph dynamically updates the weights of entities and relational edges based on the actual execution results of each repair operation; the dynamic update includes: adjusting the weights of the repair relationship between the fault entity and the strategy entity, and the weights of the causal relationship between the strategy entity and the effect entity, based on the execution results of the repair operation.

[0012] According to embodiments of this application, reasoning and verification of candidate strategies and candidate channels using a repair knowledge graph includes: searching for historical fault entities similar to fault information in the repair knowledge graph; obtaining one or more historical strategy entities and one or more historical channel entities associated with the historical fault entities; calculating the similarity between candidate strategies and historical strategy entities and the similarity between candidate channels and historical channel entities; and scoring the candidate strategies and candidate channels based on the similarity to verify or adjust the candidate strategies and candidate channels.

[0013] According to an embodiment of this application, the health of each channel at a future execution time is predicted using a channel prediction model, including: obtaining a historical operating state sequence for each channel, the historical operating state sequence including a load sequence, a response time sequence, and a failure rate sequence; processing the historical operating state sequence using a time series prediction model to predict the state value of each channel at multiple future time steps; and calculating the health of each channel at a future execution time based on the predicted state value, where the health is positively correlated with the predicted availability and negatively correlated with the predicted response time and load.

[0014] According to embodiments of this application, a time series prediction model includes: a position encoding layer for adding time position information to the input historical running state sequence; a multi-head self-attention layer for capturing the dependencies between different time steps in the historical running state sequence; a feedforward neural network layer for performing nonlinear transformation on the output of the multi-head self-attention layer; residual connections and layer normalization units for connecting the multi-head self-attention layer and the feedforward neural network layer respectively, for accelerating model training and stabilizing feature distribution; and an output layer for mapping the output of the feedforward neural network layer to predicted state values ​​for multiple future time steps.

[0015] According to embodiments of this application, scheduling decisions based on health and inter-channel synergy factors include: dividing the required repair operations into at least one execution unit, defining the execution unit as a task, and assigning an execution channel to each task; solving for the task-channel allocation scheme with the objective of maximizing the sum of the health of each channel and the weighted sum of the inter-channel synergy; or solving for the task-channel allocation scheme through multi-objective optimization or weighted summation with the objective of maximizing the sum of the health of each channel at its respective execution time and minimizing the negative synergy between channels; and when the predicted health of a certain channel is lower than a preset threshold, performing at least one of the following avoidance operations: switching to a backup channel, delaying the execution of the task on that channel, or assigning the task to another channel.

[0016] According to embodiments of this application, an online update of the three-dimensional policy fit matrix and channel prediction model is performed through a dual closed-loop feedback mechanism, including: obtaining the execution results of repair operations and calculating the comprehensive score of the execution results; through a policy selection closed loop, using the policy gradient method to calculate the update gradient based on the comprehensive score, and adjusting the fit values ​​in the three-dimensional policy fit matrix and the network parameters used to extract context information based on the update gradient; through a channel scheduling closed loop, obtaining the prediction error between the health predicted by the channel prediction model and the actual observed health, using the backpropagation algorithm to update the parameters of the channel prediction model based on the prediction error, and updating the inter-channel coordination factor based on the execution results of the repair operations.

[0017] According to a second aspect of this application, a repair apparatus is provided, comprising: an information acquisition module for acquiring fault information and context information corresponding to the fault information; a strategy matching module for performing strategy matching based on the fault information and context information using a three-dimensional strategy fit matrix to obtain candidate strategies and candidate channels; wherein the three-dimensional strategy fit matrix is ​​used to characterize the degree of fit between fault type, strategy type and channel type; a reasoning verification module for performing reasoning verification on candidate strategies and candidate channels using a repair knowledge graph to obtain optimized strategies and channels; a repair operation module for performing predictive scheduling on the optimized strategies and channels, using a channel prediction model to predict the health of each channel at future execution time, making scheduling decisions based on health and channel synergy factors, and performing repair operations; and a data update module for acquiring the execution results of the repair operations, updating the three-dimensional strategy fit matrix and channel prediction model online through a double closed-loop feedback mechanism, and updating the execution results of the repair operations to the repair knowledge graph.

[0018] According to a third aspect of this application, an electronic device is provided, comprising: one or more processors; and a memory for storing one or more computer programs, wherein the one or more processors execute the one or more computer programs to implement the steps of the method described above.

[0019] According to a fourth aspect of this application, a computer-readable storage medium is also provided, on which a computer program or instructions are stored, wherein the computer program or instructions, when executed by a processor, implement the steps of the above-described method.

[0020] According to a fifth aspect of this application, a computer program product is also provided, including a computer program or instructions that, when executed by a processor, implement the steps of the above-described method. Attached Figure Description

[0021] The above-mentioned contents, other objects, features and advantages of this application will become clearer from the following description of embodiments with reference to the accompanying drawings, in which:

[0022] Figure 1 The illustrations depict application scenarios of repair methods, apparatus, devices, media, and program products according to embodiments of this application.

[0023] Figure 2 This illustration schematically shows the overall architecture of an intelligent repair strategy matching system based on multi-channel collaboration according to an embodiment of this application;

[0024] Figure 3 A flowchart illustrating a repair method according to an embodiment of this application is shown schematically;

[0025] Figure 4This illustration schematically shows a flowchart of obtaining candidate policies and candidate channels by performing policy matching using a three-dimensional policy fit matrix according to an embodiment of this application.

[0026] Figure 5 This illustration schematically depicts the knowledge graph structure and reasoning diagram according to an embodiment of this application;

[0027] Figure 6 This illustration schematically shows a flowchart of reasoning and verifying candidate strategies and candidate channels using a repair knowledge graph according to an embodiment of this application;

[0028] Figure 7 This illustration schematically shows a flowchart of a process for predicting the health of each channel at a future execution time using a channel prediction model, according to an embodiment of this application.

[0029] Figure 8 This illustration shows a flowchart of a scheduling decision based on health and inter-channel coordination factors according to an embodiment of this application.

[0030] Figure 9 This diagram schematically illustrates an optimized architecture of a dual-loop feedback mechanism according to an embodiment of this application.

[0031] Figure 10 This illustration shows a flowchart of online updating of the three-dimensional strategy fit matrix and channel prediction model through a dual closed-loop feedback mechanism according to an embodiment of this application.

[0032] Figure 11 This schematically illustrates a complete end-to-end flowchart from fault input to knowledge accumulation according to an embodiment of this application;

[0033] Figure 12 A schematic diagram of the structure of the repair apparatus according to an embodiment of this application is shown.

[0034] Figure 13 A block diagram schematically illustrates an electronic device suitable for implementing a repair method according to an embodiment of this application. Detailed Implementation

[0035] The embodiments of this application will now be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of this application. In the following detailed description, numerous specific details are set forth to provide a thorough understanding of the embodiments of this application for ease of explanation. However, it will be apparent that one or more embodiments may be implemented without these specific details. Furthermore, descriptions of well-known structures and technologies are omitted in the following description to avoid unnecessarily obscuring the concepts of this application.

[0036] The terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the scope of this application. The terms “comprising,” “including,” etc., as used herein indicate the presence of features, steps, operations, and / or components, but do not exclude the presence or addition of one or more other features, steps, operations, or components.

[0037] All terms used herein (including technical and scientific terms) have the meanings commonly understood by those skilled in the art, unless otherwise defined. It should be noted that the terms used herein are to be interpreted in a manner consistent with the context of this specification, and not in an idealized or overly rigid way.

[0038] As used in this article, the term "model" refers to a model that learns the relationship between inputs and outputs from training data, enabling it to generate corresponding outputs for a given input after training. Model generation can be based on machine learning techniques. Deep learning is a machine learning algorithm that uses multiple layers of processing units to process inputs and provide corresponding outputs. A neural network model is an example of a deep learning-based model. In this article, "model" may also be referred to as a "machine learning model," "learning model," "machine learning network," or "learning network," and these terms are used interchangeably.

[0039] It's important to note that the term "neural network" can refer to a machine learning network based on deep learning. A neural network processes input and provides corresponding output, typically consisting of an input layer, an output layer, and one or more hidden layers between them. Neural networks used in deep learning applications often include many hidden layers, increasing the network's depth. The layers of a neural network are connected sequentially, so that the output of the previous layer serves as the input to the next layer. The input layer receives the input to the neural network, while the output layer's output becomes the final output. Each layer of a neural network includes one or more nodes (also called processing nodes or neurons), each processing the input from the layer above.

[0040] It should be understood that this process can generally include three phases: the training phase, the testing phase, and the application phase (also known as the inference phase). In the training phase, a given model is trained using a large amount of training data, iteratively updating parameter values ​​until the model can consistently generate inferences from the training data that meet the expected goals. Through training, the model can be considered to have learned the relationship between inputs and outputs (also known as the input-output mapping) from the training data. The parameter values ​​of the trained model are determined. In the testing phase, test inputs are applied to the trained model to test whether it can provide the correct output, thereby determining the model's performance. In the application phase, the model can be used to process actual inputs based on the trained parameter values ​​to determine the corresponding output.

[0041] Figure 1 The diagram illustrates an application scenario of the repair method according to an embodiment of this application.

[0042] like Figure 1 As shown, application scenario 100 according to an embodiment of this application may include a first terminal device 101, a second terminal device 102, a database 103, a network 104, and a server 105. The network 104 serves as a medium for providing a communication link between the first terminal device 101, the second terminal device 102, the database 103, and the server 105. The network 104 may include various connection types, such as wired or wireless communication links or fiber optic cables. For example, a user can use the first terminal device 101 and the second terminal device 102 to interact with the server 105 and / or the database 103 through the network 104 to receive or send information, etc.

[0043] The first terminal device 101 and the second terminal device 102 can be electronic devices such as smartphones, wearable devices, personal computers, intelligent voice interaction devices, smart home appliances, intelligent vehicles, in-vehicle terminals, aircraft, unmanned vending terminals, and extended reality devices. Extended reality devices can include virtual reality devices, augmented reality devices, and mixed reality devices. A client application for the target application can be installed and run on the terminal device. This target application can include, but is not limited to, financial transaction applications, payment applications, shopping applications, web browser applications, search applications, instant messaging tools, email clients, and social media platform software (these are just examples). Furthermore, this application embodiment does not limit the form of the target application, including but not limited to applications, mini-programs, etc., installed on the terminal device, and can also be in web page form.

[0044] Server 105 can be a server providing various services, such as a backend management server supporting websites browsed by users using the first terminal device 101 and the second terminal device 102 (this is just an example). The backend management server can analyze and process received user requests and other data, and feed back the processing results (such as web pages, information, or data obtained or generated according to user requests) to the terminal devices. The server can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services such as cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks, and big data. The server can be a backend server for the aforementioned target application, used to provide backend services to the clients of the target application.

[0045] Database 103 is a professional storage system for storing and managing data. It can store various types of data related to the target application, such as user account information, business transaction records, and content resource data. It supports structured, semi-structured, or unstructured data storage and has management capabilities such as adding, deleting, modifying, querying, backing up, and restoring data. In this application scenario, database 103 can be connected to server 105 via a communication link. Server 104 can retrieve the required data from database 103 for processing based on requests from the first terminal device 101 and the second terminal device 102. It can also synchronously store new data generated by the operations of the first terminal device 101 and the second terminal device 102 into database 103, thereby achieving data persistence and efficient retrieval.

[0046] It should be noted that the repair method provided in this application embodiment can generally be executed by server 105 and / or terminal devices 101-102. Accordingly, the repair device provided in this application embodiment can generally be set in server 105 and / or terminal devices 101-102.

[0047] It should be understood that Figure 1 The number of terminal devices, networks, databases, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, databases, and services can be included.

[0048] Figure 2 The diagram illustrates the overall architecture of a multi-channel collaborative intelligent repair strategy matching system according to an embodiment of this application.

[0049] like Figure 2 As shown, the intelligent repair strategy matching system based on multi-channel collaboration according to the embodiments of this application includes four core modules: context-aware strategy matching module (CSPM), knowledge graph-driven reasoning module (KGDR), predictive multi-channel collaborative scheduling module (PMCS), and dual closed-loop self-learning optimization module (DLSO).

[0050] The system workflow is as follows: The input layer receives fault information F and its context. The CSPM module encodes historical fault sequences through a long short-term memory network, queries the three-dimensional policy fit matrix M [fault × policy × channel], and uses a deep network to calculate the context fit, outputting a preliminary policy (s, c). The KGDR module performs graph attention network reasoning and path reasoning based on the repair knowledge graph, verifies and optimizes candidate policies, and outputs the optimized policy (s, c). The PMCS module predicts the future state of the channel, calculates the collaboration factor, performs globally optimal scheduling and predictive avoidance, and outputs the execution result. The DLSO module evaluates the execution result in four dimensions, optimizes CSPM parameters through a policy selection closed loop, and optimizes PMCS parameters through a channel scheduling closed loop. In the feedback path, the policy selection closed loop feeds back the fit matrix and network parameters of CSPM, the channel scheduling closed loop feeds back the prediction model of PMCS, and the execution result updates the KGDR knowledge graph.

[0051] Figure 3 A flowchart illustrating a repair method according to an embodiment of this application is shown schematically.

[0052] like Figure 3 As shown, the repair method 300 according to the embodiments of this application may include steps S310 to S350.

[0053] In step S310, fault information and the context information corresponding to the fault information are obtained.

[0054] When the system monitoring component detects a fault, it generates fault information F. The fault information includes at least the fault type (e.g., error code, exception type), the time of fault occurrence, and the fault source identifier. Simultaneously, the system collects the context information of the fault.

[0055] According to embodiments of this application, the context information includes time context, historical context, and application context. Wherein: Time context This includes the time of the failure, time period characteristics (working hours / non-working hours / peak hours / off-peak hours), and periodic characteristics (such as whether it is the end of the month or quarter). Historical context. This is obtained by encoding historical failure sequences. Specifically, a Long Short-Term Memory (LSTM) network is used to encode the most recent N failure sequences: Application context This includes application identifier, service type, and historical fault distribution. The comprehensive context vector is: .

[0056] Return to reference Figure 3In step S320, based on the fault information and context information, a three-dimensional strategy fit matrix is ​​used to perform strategy matching to obtain candidate strategies and candidate channels; wherein, the three-dimensional strategy fit matrix is ​​used to characterize the degree of fit between fault type, strategy type and channel type.

[0057] According to embodiments of this application, a three-dimensional strategy fit matrix is ​​used to characterize the degree of fit between fault type, strategy type, and channel type. Specifically, the three-dimensional strategy fit matrix is ​​a three-dimensional array, with its three dimensions corresponding to fault type, strategy type, and channel type, respectively; each element in the three-dimensional array is used to store the fit value of the corresponding combination of fault type, strategy type, and channel type; the fit value is dynamically updated based on the success rate and effect score of historical repair operations (e.g., using an exponentially weighted moving average).

[0058] According to embodiments of this application, the construction of a three-dimensional policy fit matrix includes defining a policy fit matrix. Matrix elements Indicates the fault type Strategy type Channel type Combination compatibility :

[0059]

[0060] in, Let i be the inherent matching degree between fault type i and strategy type j. The performance matching degree between strategy type j and channel type k. For context dependencies, model them using deep neural networks:

[0061]

[0062] According to an embodiment of this application, step S320 may specifically include steps S410 to S440, see [link to relevant documentation]. Figure 4 .

[0063] In step S410, the fault type is determined based on the fault information, and the context adaptation weight is determined based on the context information.

[0064] In step S420, the adaptation value corresponding to the fault type is retrieved from the three-dimensional strategy adaptation matrix.

[0065] In step S430, the matching score of each strategy type and channel type combination is calculated by combining the context adaptation weight.

[0066] In step S440, the strategy type and channel type with the highest matching score are selected as candidate strategies and candidate channels.

[0067] For example, retrieve the candidate policy set from the policy fit matrix and perform context-weighted sorting:

[0068]

[0069] Select the strategy combination with the highest score:

[0070]

[0071] Furthermore, this application introduces an adaptive threshold based on uncertainty, which estimates uncertainty through Monte Carlo dropout and dynamically adjusts the threshold:

[0072]

[0073] Lower the threshold when uncertainty is high to encourage the exploration of new strategies.

[0074] In step S330, the candidate strategies and candidate channels are inferred and verified using the repaired knowledge graph to obtain the optimized strategies and channels.

[0075] Figure 5 The diagram illustrates the knowledge graph structure and reasoning diagram according to an embodiment of this application.

[0076] like Figure 5 As shown, the repair knowledge graph according to an embodiment of this application is a structured knowledge base for storing fault repair experience, supporting strategy recommendation based on graph reasoning and cross-domain knowledge transfer. The knowledge graph is described in detail below.

[0077] The repair knowledge graph includes the following five entity types: Fault Entity: Represents an abnormal event that occurs during system operation. Each fault entity must include at least the following attributes: fault identifier, error code, fault type description, and occurrence time. Strategy Entity: Represents automated or manual operations that can be used to repair faults. Each strategy entity must include at least the following attributes: strategy identifier, strategy name, operation steps, and expected effect. Channel Entity: Represents the specific technical means or tools for executing the repair strategy, such as automated script channels, container operation interfaces, and resource expansion interfaces. Each channel entity must include at least the following attributes: channel identifier, channel type, and current load capacity. Application Entity: Represents the specific business application system to which the fault belongs. Each application entity must include at least the following attributes: application identifier, business type, technology stack information, and historical fault distribution. Effect Entity: Represents the result produced after the repair operation is executed. Each effect entity must include at least the following attributes: repair success rate, repair time, resource consumption, and effect score.

[0078] Entities are connected by directed edges. Relationship types include: Similarity Relationship (SIMILAR_TO): Connects two faulty entities, indicating they are similar in features; the weight represents the degree of similarity (between 0 and 1). This relationship is automatically created or updated through entity embedding similarity mining. Repair Relationship (REPAIRED_BY): Points from a faulty entity to a policy entity, indicating the fault was repaired by the policy; the weight represents the confidence of the repair relationship (calculated based on historical repair success rate). Execution Relationship (EXECUTED_ON): Points from a policy entity to a channel entity, indicating the policy can be executed through the channel; the weight represents the applicability of the execution relationship (based on execution success rate). Belonging Relationship (BELONGS_TO): Points from a faulty entity to an application entity, indicating the fault occurred in that application. Causality Relationship (LEADS_TO): Points from a policy entity to an effect entity, indicating the policy's execution produced a corresponding effect; the weight represents the strength of the causal relationship (calculated based on effect score). Precedes: Connects two faulty entities, representing the temporal sequence of the faults. It can be used to discover fault evolution patterns (e.g., fault A often occurs before fault B).

[0079] The knowledge graph is dynamically built and updated based on the actual execution results of each repair operation. This includes the following steps: Entity Extraction and Matching: Entities are extracted from fault information, policy information, channel information, application information, and execution results. Existing entities are matched and merged to avoid duplication. Relationship Creation and Weight Update: Based on the actual execution results of this repair operation, corresponding relationship edges are created or updated. The weights of relationship edges are updated using an exponential moving average (EMA) method. Similarity Relationship Mining: The embedding vectors of all fault entities are periodically calculated. For fault entity pairs with embedding similarity exceeding a preset threshold, a SIMILAR_TO relationship edge is created or enhanced, enabling the knowledge graph to automatically discover implicit similarities. Temporal Relationship Creation: Based on the chronological order of fault occurrence, PRECEDES relationship edges are created for fault entities within the same application or the same time window, with weights inversely proportional to the time interval.

[0080] When a new fault occurs, the system uses the repair knowledge graph for reasoning verification, specifically including two reasoning methods: Graph Attention Network (GAT) link prediction: The embedding vectors of the new fault entity, candidate policy entity, and candidate channel entity are input into the GAT model, and a link prediction score (between 0 and 1) is output, representing the effectiveness of the combination of the three. The GAT model can dynamically calculate attention weights based on the information of neighboring nodes in the knowledge graph, thereby capturing complex nonlinear relationships.

[0081]

[0082] Path reasoning: Find similar faults between the new faulty entity and the historical faulty entity through the SIMILAR_TO edge, and then perform path reasoning along the REPAIRED_BY edge and EXECUTED_ON edge to calculate the path score. :

[0083]

[0084] Where P(REPAIRED_BY) and P(EXECUTED_ON) are the normalized weights of the relation edges.

[0085] The final recommendation score combines the two inference results, and the strategy and channel combination with the highest score is selected as the recommendation result.

[0086] When a new application is first integrated, the knowledge graph may lack experience in troubleshooting that application. The system transfers knowledge from similar applications by calculating the similarity between the new application and existing applications (based on the Jaccard similarity coefficient of the technology stack and business type matching).

[0087]

[0088] Virtual SIMILAR_TO edges are created in the knowledge graph for faults in new applications, connecting them to fault entities with high success rates in similar applications. This allows for initial policy recommendations based on the repair knowledge of similar applications. As the new application accumulates its own repair operations, virtual relationship edges are gradually replaced by real relationship edges.

[0089] Through the above design, the repair knowledge graph can accumulate and reuse repair experience in a structured way, support multi-modal reasoning, and significantly improve the accuracy of strategy recommendation and the cold start speed of new scenarios.

[0090] According to an embodiment of this application, step S330 may specifically include steps S610 to S640, see [link to relevant documentation]. Figure 6 The following is combined with Figure 5 Each step is explained in detail.

[0091] In step S610, historical fault entities similar to the fault information are searched in the repair knowledge graph.

[0092] like Figure 5 As shown, the repair knowledge graph contains multiple fault entities (e.g., "connection pool exhaustion," "CPU overload," "memory leak," etc.). When a new fault occurs, the system first extracts the fault's feature vector (including error code, fault type, contextual features, etc.), and then calculates entity embedding similarity in the knowledge graph to find one or more historical fault entities most similar to that feature vector. Similarity calculation can use cosine similarity or a distance metric based on graph embedding. Figure 5 In the example on the right, the new fault "Database connection pool exhausted (end-of-day peak)" has a similarity of 0.88 with the historical fault entity "Connection pool exhausted", so the historical fault entity is selected as a similarity reference.

[0093] In step S620, one or more historical policy entities and one or more historical channel entities associated with the historical fault entity are obtained.

[0094] After finding similar historical fault entities, the system retrieves related entities by following the relationship edges in the knowledge graph. For example... Figure 5 As shown on the left, the historical fault entity "Connection Pool Exhausted" is connected to the policy entity "Expand Connection Pool" via the REPAIRED_BY (repair relationship) edge. This policy entity is further connected to the channel entity "Manually Expand Channel" via the EXECUTED_ON (execution relationship) edge. Simultaneously, the policy entity is also connected to the effect entity "Repair Successful (Success Rate 0.92)" via the LEADS_TO (causal relationship) edge. The system retrieves all these associated historical policy entities and historical channel entities as a candidate reference set for subsequent verification. In cases where the same relationship edge may connect multiple entities, the system retrieves all associated entities (e.g., a fault may have been repaired by multiple policies).

[0095] In step S630, the similarity between candidate strategies and historical strategy entities, as well as the similarity between candidate channels and historical channel entities, is calculated.

[0096] For the candidate strategies and candidate channels obtained in step S320 (e.g., the "Expand Connection Pool" strategy and the "Automatic Expand Channel"), the system calculates their similarity to the historical strategy entities and historical channel entities obtained in step S620. Strategy similarity can be calculated based on the edit distance of the strategy name, the semantic similarity of the strategy operation steps, or the cosine similarity of the strategy embedding vectors; channel similarity can be calculated based on channel type, execution interface, resource consumption characteristics, etc. Figure 5 As shown, the similarity between the candidate strategy "Expand Connection Pool" and the historical strategy entity "Expand Connection Pool" is 1.0 (complete match), and the similarity between the candidate channel "Manually Expand Channel" and the historical channel entity "Manually Expand Channel" is 1.0. However, if the candidate channel is "Automatically Expand Channel", the similarity with the historical channel may be lower (e.g., 0.7).

[0097] In step S640, candidate strategies and candidate channels are scored based on similarity to verify or adjust candidate strategies and candidate channels.

[0098] The system comprehensively considers the similarity scores and the success rates of historical paths to score candidate strategies and channels. Specifically, the scoring can be achieved by fusing two methods:

[0099] Link prediction score based on GAT: The embedding vectors of new faulty entities, candidate policy entities, and candidate channel entities are input into a graph attention network (GAT), which outputs a prediction score. Figure 5 In the example on the right, the GAT score is 0.73.

[0100] Path-based reasoning scoring: The path score is obtained by multiplying the similarity (0.88) between the new fault and the historical fault calculated in step S610 by the weights of the REPAIRED_BY relation edge (e.g., 0.95) and the EXECUTED_ON relation edge (e.g., 0.98).

[0101] If the overall score is higher than a preset threshold (e.g., 0.7), the candidate strategy and channel are accepted as the optimized strategy and channel; otherwise, the system re-recommends the strategy and channel based on other similar fault paths in the knowledge graph (e.g., selecting the combination with the second highest score). Through the above reasoning verification, the optimized strategy and channel output in step S330 have higher reliability.

[0102] Return to reference Figure 3 In step S340, predictive scheduling is performed on the optimized strategy and channels. The health of each channel at future execution time is predicted using the channel prediction model. Scheduling decisions are made based on the health and the synergy factors between channels, and repair operations are performed.

[0103] According to embodiments of this application, predicting the health of each channel at a future execution time using a channel prediction model may include steps S710 to S730, see [link to relevant documentation]. Figure 7 .

[0104] In step S710, the historical operating status sequence of each channel is obtained. The historical operating status sequence includes the load sequence, response time sequence, and failure rate sequence.

[0105] The system targets each execution channel Collect its historical operational status data. Specifically, the system maintains three time series: load series... Used to record the resource utilization rate of a channel within a continuous time window; response time series This reflects the average time taken for the channel to perform repair operations; failure rate sequence. This is used to record the proportion of failures or timeouts that occur when the channel performs tasks. The above sequence data can be stored in a time-series database or a memory cache, and the sequence length (historical time window) can be preset according to the business scenario.

[0106] In step S720, the historical operating state sequence is processed using a time series prediction model to predict the state value of each channel at multiple future time steps.

[0107] According to embodiments of this application, a time series prediction model includes: a position encoding layer for adding time position information to the input historical running state sequence; a multi-head self-attention layer for capturing the dependencies between different time steps in the historical running state sequence; a feedforward neural network layer for performing nonlinear transformation on the output of the multi-head self-attention layer; residual connections and layer normalization units for connecting the multi-head self-attention layer and the feedforward neural network layer respectively, for accelerating model training and stabilizing feature distribution; and an output layer for mapping the output of the feedforward neural network layer to predicted state values ​​for multiple future time steps.

[0108] For each channel Maintain the load sequence, response time sequence, and failure rate sequence, and use a time series forecasting model to predict the state at the next H time steps. The forecasting process is represented as follows:

[0109]

[0110] In step S730, the health of each channel at the future execution time is calculated based on the predicted status value. The health is positively correlated with the predicted availability and negatively correlated with the predicted response time and load.

[0111] The system calculates the health of each channel at future execution time τ based on the predicted state values. Health is positively correlated with predicted availability and negatively correlated with predicted response time and load. The calculation formula is as follows:

[0112]

[0113] in, This is the preset maximum acceptable response time; The rated capacity of the channel is w1, w2, and w3 are weighting coefficients that satisfy w1 + w2 + w3 = 1, and can be flexibly adjusted according to the business scenario. The health value is normalized to [0, 1], and the closer the value is to 1, the more suitable the channel is for executing tasks.

[0114] Through the above steps, this application uses a time series prediction model to accurately predict the future state of a channel, enabling early detection of channel performance degradation trends and thus achieving predictive scheduling.

[0115] According to embodiments of this application, scheduling decisions based on health and inter-channel coordination factors may include steps S810 to S830, see [link to relevant documentation]. Figure 8 .

[0116] In step S810, the repair operations to be performed are divided into at least one execution unit, the execution unit is defined as a task, and an execution channel is assigned to each task.

[0117] The system divides the required repair operations into at least one execution unit, and defines each execution unit as a task. Task division can be based on the atomic operation granularity of the repair strategy, or it can be split according to the execution dependency graph. After division, the system assigns an execution channel to each task and determines the execution order of each task (if dependencies exist).

[0118] In step S820, the task and channel allocation scheme is solved with the goal of maximizing the sum of the health of each channel and the weighted sum of the synergistic effect between channels; or the task and channel allocation scheme is solved by multi-objective optimization or weighted summation with the goal of maximizing the sum of the health of each channel at its respective execution time and minimizing the negative synergistic effect between channels.

[0119] The core of this step is to establish an optimization problem: under the premise of satisfying task constraints (such as resource limitations and dependency order), select the optimal task-channel allocation scheme.

[0120] Define channel synergy factors to quantify multi-channel synergistic effects:

[0121]

[0122] in, This represents the historical expected success rate when channel i is executed alone. This represents the historical expected success rate when two channels execute together. Typical scenarios of negative collaboration include two channels competing for the same resource (such as disk I / O or network bandwidth) or having sequential dependencies (must be executed serially); typical scenarios of positive collaboration include two channels having complementary functions (such as one responsible for detection and the other for repair) or parallel execution that can shorten the total execution time.

[0123] Given a strategy Required channels Predict the channel health at the time of execution. If the predicted health is below a threshold, implement predictive fault avoidance: predictive switching: select a backup channel; delayed scheduling: delay execution until the channel recovers; degradation strategy: switch to a low-risk strategy. Build task - channel allocation optimization problem:

[0124]

[0125] in, As a coordination factor between channels, The synergistic effect weighting coefficient, This is an indicator function.

[0126] This optimization problem can be solved using various algorithms: if the number of tasks is small, the Hungarian algorithm or enumeration method can be used; if the number of tasks is large, genetic algorithms, particle swarm optimization, or graph-based heuristic methods (such as greedy allocation) can be used. At the same time, the time window of the tasks (i.e., each task can only be executed within a specific time window) and resource capacity constraints must also be considered.

[0127] In step S830, when the predicted health of a certain channel is lower than a preset threshold, at least one of the following avoidance operations is performed: switching to a backup channel, delaying the execution of the task on that channel, or assigning the task to another channel.

[0128] During scheduling and execution, even if channels have been allocated, due to dynamic system changes, the predicted health status may deviate significantly from the actual status at the time of execution, or a channel may suddenly fail. This step provides a predictive failure avoidance mechanism, specifically including: Predictive switching: If the health status of the originally allocated channel is predicted to be below a threshold (e.g., 0.5), the task is proactively switched to a pre-selected backup channel for execution. The backup channel can be the channel with the second highest score in step S820, or other channels recommended based on the knowledge graph. Delayed scheduling: If the channel is predicted to be only temporarily overloaded (e.g., the load will decrease in the next minute), the execution time of the task is delayed until the health status recovers to above the threshold. The delay duration can be determined based on the future health status curve output by the predictive model. Degradation strategy: If switching and delaying are not feasible (e.g., the task is urgent and there are no other available channels), a lower-risk degradation strategy is selected, such as performing partial repair operations instead of full repair, or using more conservative parameters.

[0129] The aforementioned avoidance measures can be used individually or in combination. For example, a delayed scheduling attempt can be made first; if recovery fails even after the delay exceeds the maximum tolerable time, a predictive switchover can be executed. In this way, the system proactively intervenes before channel failures or performance degradation occur, significantly reducing the failure rate of repairs caused by channel issues.

[0130] Through the coordination of steps S710~S730 and S810~S830, this application realizes a complete predictive scheduling process from data collection, state prediction, task allocation to fault avoidance, which improves the reliability and foresight of multi-channel scheduling.

[0131] Return to reference Figure 3 In step S350, the execution result of the repair operation is obtained, the three-dimensional strategy adaptation matrix and channel prediction model are updated online through a double closed-loop feedback mechanism, and the execution result of the repair operation is updated to the repair knowledge graph.

[0132] Figure 9 The diagram illustrates an optimized architecture of a dual closed-loop feedback mechanism according to an embodiment of this application.

[0133] like Figure 9 As shown, the dual-loop feedback mechanism according to an embodiment of this application includes two mutually cooperating closed loops: a strategy selection closed loop (closed loop 1) and a channel scheduling closed loop (closed loop 2). The two closed loops share the repair results output by the execution layer, and calculate a comprehensive score through the evaluation layer. They then update the three-dimensional strategy fit matrix, context network parameters, channel prediction model parameters, and collaborative factor matrix online, respectively, to achieve continuous self-learning and global optimization of the system.

[0134] According to an embodiment of this application, step S350 may specifically include steps S1010 to S1030, see [link to relevant documentation]. Figure 10 The following is based on Figure 10 The main steps are as follows, combined with Figure 9 A detailed explanation will be provided.

[0135] In step S1010, the execution result of the repair operation is obtained, and the comprehensive score of the execution result is calculated.

[0136] Figure 9 The bottom layer is the execution layer, which receives repair task inputs (including task identifier, selected strategy, assigned channel, etc.) generated by the upper layer scheduling decision, performs the actual repair operations, and outputs the execution results (such as success / failure, actual time taken, number of switches, resource consumption, etc.). The execution results are then passed to the evaluation layer.

[0137] The evaluation layer performs multi-dimensional quantitative assessment of the repair results and generates a comprehensive score. The evaluation dimensions include:

[0138] success Full repair = 1.0, partial repair = 0.7, failure with information = 0.3, complete failure = 0.0.

[0139] Efficiency :

[0140] stability .

[0141] Cost : l.

[0142] Overall score :

[0143]

[0144] The weights sum to 1, and can be flexibly set according to business objectives. This score serves as a feedback signal, inputting into both closed loops.

[0145] In step S1020, through policy selection closure, the policy gradient method is used to calculate the update gradient based on the comprehensive score, and the fitness values ​​in the three-dimensional policy fitness matrix are adjusted according to the update gradient, as well as the network parameters used to extract context information are adjusted.

[0146] Closed-loop 1 - Policy selection closed loop: Receive the comprehensive score feedback signal and calculate the policy gradient. The fitness matrix M[i,j,k] and the context network Θ_context are updated respectively, and the feedback optimization target is the CSPM module.

[0147] The closed-loop workflow of strategy selection includes: receiving comprehensive scores. Simultaneously, obtain the fault type i, strategy type j, channel type k, and context used in this repair. Define the strategy. Let θ be the probability of choosing strategy s and channel c under the current parameters Θ.

[0148] Calculate policy gradient :

[0149]

[0150] Where b is the baseline, used to reduce variance. The Monte Carlo approximation is actually used.

[0151] Update parameters, fit matrix:

[0152]

[0153] Context network parameters:

[0154]

[0155] The updated parameters are fed back to the CSPM module, forming a continuous optimization loop.

[0156] In step S1030, the prediction error between the health predicted by the channel prediction model and the actual observed health is obtained through channel scheduling closed loop. The parameters of the channel prediction model are updated according to the prediction error using the backpropagation algorithm, and the coordination factor between channels is updated according to the execution result of the repair operation.

[0157] Closed-loop 2 - Channel scheduling closed loop: Receive comprehensive score feedback signal and calculate prediction error. Update the prediction model respectively and synergistic factors The feedback optimization target is the PMCS module.

[0158] The workflow of the closed-loop 2-channel scheduling closed loop includes: receiving comprehensive scores. And obtain the health status of each channel actually observed during the execution process. and predict health .

[0159] Calculate the mean square error of prediction :

[0160]

[0161] The backpropagation algorithm is used to update the prediction model parameters:

[0162]

[0163] Update the co-factor matrix: for channel pairs that are executed simultaneously in this fix. Record the actual success of joint execution. ∈{0,1}; Calculate the product of expected success rates. Exponential moving average update:

[0164]

[0165] The updated parameters are fed back to the PMCS module, forming a closed loop for scheduling optimization.

[0166] The two closed loops work together to avoid conflicts and improve overall performance in the following ways:

[0167] Consistency constraints: introduced The divergence penalty term forces the two closed loops to maintain a consistent bias in their channel selection. The joint optimization objective is:

[0168]

[0169] Shared experience pool: The two closed loops store the (state, action, reward) tuple into the shared priority experience pool, enabling batch sampling and learning, and improving sample utilization efficiency.

[0170] Alternating optimization strategy: In each iteration, the scheduling closed-loop parameters are fixed first to update the strategy closed-loop, and then the strategy closed-loop parameters are fixed to update the scheduling closed-loop, so as to avoid instability caused by simultaneous updates.

[0171] The execution results are also passed to the Knowledge Graph Driven Reasoning (KGDR) module, which updates and repairs the knowledge graph: creating or updating the affected entity, recording the success rate, time consumption, and resource consumption of this repair; adjusting the weights of the REPAIRED_BY relation edges (exponential moving average); adjusting the weights of the LEADS_TO relation edges; and creating or strengthening the PRECEDES relation edges if a temporal pattern is found. The updated knowledge graph is used for subsequent fault reasoning verification, forming a closed loop of experience-to-knowledge accumulation.

[0172] Through steps S1010-S1030 and the dual-loop collaborative mechanism, the input of the repair task is processed by the CSPM, KGDR, and PMCS modules to generate scheduling decisions. The execution layer produces results, and the evaluation layer generates a comprehensive score. Then, the parameters are updated through the policy selection closed loop and the channel scheduling closed loop, respectively, while the execution results are fed back to the knowledge graph. The updated parameters and knowledge directly affect the quality of the next repair decision, thus forming a complete, continuously learning closed-loop system. The dual-loop collaboration enables the system to perform adaptive optimization at both the policy and scheduling levels, resulting in faster convergence and higher final performance compared to the single-loop scheme.

[0173] The complete execution flow of this application's embodiments is described below using a specific application scenario. (See attached document.) Figure 11 This scenario involves a core system experiencing frequent database connection pool exhaustion during end-of-day batch processing, leading to the failure of batch reconciliation tasks.

[0174] When the system detects a fault, it first obtains the fault information and its corresponding context information. The fault information is "database connection pool exhausted". The context information includes time context (23:00, end-of-day peak period), historical context (5 out of the last 10 faults occurred during the end-of-day batch period), and application context (core banking system, batch reconciliation business, high load).

[0175] In the context-aware policy matching phase, the module encodes historical fault sequences using a long short-term memory network, extracts historical context features, queries the three-dimensional policy fit matrix, and calculates the matching score for each policy-channel combination based on context fit weights. The candidate policy "Restart Connection Pool" scored 0.75, and "Expand Connection Pool" scored 0.85. After context weighting, "Expand Connection Pool" and "Manually Expand Channel" were selected as candidate policies and channels, resulting in a final score of 1.08.

[0176] In the knowledge graph reasoning verification phase, the knowledge graph-driven reasoning module searches for historical fault entities similar to the current fault in the repair knowledge graph, with a similarity of 0.88. It then obtains the historical strategy entity "Expand Connection Pool" and the historical channel entity "Manually Expand Channel" associated with this historical fault entity, as well as the effect entity "Repair Successful (Success Rate 0.92)". Finally, it uses graph attention network link prediction (score 0.73) and path reasoning (path score 0.88 × 0.95 × 0.98 ≈ 0.82) for fusion scoring. The final verification score is 0.92, higher than the preset threshold, thus passing the verification. The optimized strategy and channel are then output, consistent with the candidate combination.

[0177] During the predictive multi-channel collaborative scheduling phase, the predictive multi-channel collaborative scheduling module first predicts the future health of each channel: the health of the automatically expanding channel is 0.75 for the next 10 minutes, and 0.90 for the manually expanding channel. Simultaneously, calculating the collaboration factor reveals a negative collaboration effect when the three batch tasks simultaneously use the automatically expanding channel, with a collaboration factor of -0.2. Based on these predictions and the collaboration factor, the scheduling decision is to delay execution by 5 minutes and reserve the manually expanding channel as a backup. During execution, the automatically expanding channel experiences a sudden load surge, causing its health to drop to 0.65. The system then triggers a dynamic switch to the manually expanding channel, ultimately successfully repairing the issue.

[0178] During the dual-loop online update phase, the dual-loop self-learning optimization module evaluates the repair results across four dimensions: success (complete repair, score 1.0), efficiency (actual time 8 minutes, expected 10 minutes, score 0.98), stability (1 switch, maximum allowed 3 switches, score 0.67), and cost (resource consumption within budget, score 0.9), with a comprehensive score of 0.9. The strategy selection closed loop updates the corresponding (database failure, expansion, manual channel) adaptation value in the three-dimensional strategy adaptation matrix to 0.95 and adjusts the context network parameters. The channel scheduling closed loop calculates a prediction error of 0.01, updates the model parameters through backpropagation, and updates the collaboration factor to -0.25.

[0179] During the knowledge graph update phase, the execution results are fed back to the knowledge graph-driven reasoning module for updating and repairing the knowledge graph: creating new effect entities, recording information such as the success rate, time consumption, and resource consumption of this repair; adjusting the weights of repair relationship edges (using exponential moving average); adjusting the weights of causal relationship edges; and creating temporal relationship edges to mark recurring patterns during the end-of-day batch processing.

[0180] Through the complete process from fault input to knowledge accumulation described above, this application achieves context-aware policy matching, knowledge-driven reasoning verification, predictive multi-channel scheduling, dual-loop online self-learning, and structured knowledge accumulation and reuse. Experimental data shows that in typical business scenarios, the repair success rate increased from 65% to 87%, the repair failure rate due to channel faults decreased by more than 60%, and the cold start sample requirement for new applications decreased by more than 50%, achieving significant technical results.

[0181] Based on the above-described repair method, embodiments of this application also provide a repair apparatus. The following will conclude... Figure 12 The device is described in detail.

[0182] Figure 12 A schematic block diagram of a repair apparatus according to an embodiment of this application is shown.

[0183] like Figure 12 As shown, the repair device 1200 of this embodiment includes an information acquisition module 1210, a strategy matching module 1220, an inference verification module 1230, a repair operation module 1240, and a data update module 1250.

[0184] The information acquisition module 1210 is used to acquire fault information and the context information corresponding to the fault information. In one embodiment, the information acquisition module 1210 can be used to execute step S310 described above, which will not be repeated here.

[0185] The strategy matching module 1220 is used to perform strategy matching using a three-dimensional strategy fit matrix based on fault information and context information to obtain candidate strategies and candidate channels; wherein, the three-dimensional strategy fit matrix is ​​used to characterize the degree of fit between fault type, strategy type and channel type. In one embodiment, the strategy matching module 1220 can be used to execute step S320 described above, which will not be repeated here.

[0186] The reasoning verification module 1230 is used to perform reasoning verification on candidate strategies and candidate channels using the repaired knowledge graph to obtain optimized strategies and channels. In one embodiment, the reasoning verification module 1230 can be used to execute step S330 described above, which will not be repeated here.

[0187] The repair operation module 1240 is used to perform predictive scheduling on the optimized strategy and channels. It uses a channel prediction model to predict the health of each channel at future execution times, makes scheduling decisions based on the health and inter-channel coordination factors, and then performs repair operations. In one embodiment, the repair operation module 1240 can be used to execute step S340 described above, which will not be repeated here.

[0188] The data update module 1250 is used to obtain the execution results of the repair operation, update the three-dimensional strategy adaptation matrix and channel prediction model online through a dual closed-loop feedback mechanism, and update the execution results of the repair operation to the repair knowledge graph. In one embodiment, the data update module 1250 can be used to execute step S350 described above, which will not be repeated here.

[0189] According to embodiments of this application, the context information includes time context, historical context, and application context; wherein, the time context includes the time of failure and time segment characteristics; the historical context is obtained by encoding historical failure sequences; and the application context includes application identifier and service type.

[0190] According to an embodiment of this application, the three-dimensional strategy adaptation matrix is ​​a three-dimensional array, and the three dimensions of the three-dimensional array correspond to the fault type, strategy type and channel type, respectively; each element in the three-dimensional array is used to store the adaptation value of the corresponding combination of fault type, strategy type and channel type; the adaptation value is dynamically updated according to the success rate and effect score of historical repair operations.

[0191] According to an embodiment of this application, strategy matching is performed using a three-dimensional strategy fit matrix to obtain candidate strategies and candidate channels, including: determining the fault type based on fault information and determining the context fit weight based on context information; retrieving the fit value corresponding to the fault type in the three-dimensional strategy fit matrix; calculating the matching score of each strategy type and channel type combination by combining the context fit weight; and selecting the strategy type and channel type with the highest matching score as candidate strategies and candidate channels.

[0192] According to embodiments of this application, the repair knowledge graph includes fault entities, strategy entities, channel entities, and effect entities; wherein, entities are connected by relational edges, and the relational edges include at least: the repair relationship between the fault entity and the strategy entity, the execution relationship between the strategy entity and the channel entity, and the causal relationship between the strategy entity and the effect entity; the repair knowledge graph dynamically updates the weights of entities and relational edges based on the actual execution results of each repair operation; the dynamic update includes: adjusting the weights of the repair relationship between the fault entity and the strategy entity, and the weights of the causal relationship between the strategy entity and the effect entity, based on the execution results of the repair operation.

[0193] According to embodiments of this application, reasoning and verification of candidate strategies and candidate channels using a repair knowledge graph includes: searching for historical fault entities similar to fault information in the repair knowledge graph; obtaining one or more historical strategy entities and one or more historical channel entities associated with the historical fault entities; calculating the similarity between candidate strategies and historical strategy entities and the similarity between candidate channels and historical channel entities; and scoring the candidate strategies and candidate channels based on the similarity to verify or adjust the candidate strategies and candidate channels.

[0194] According to an embodiment of this application, the health of each channel at a future execution time is predicted using a channel prediction model, including: obtaining a historical operating state sequence for each channel, the historical operating state sequence including a load sequence, a response time sequence, and a failure rate sequence; processing the historical operating state sequence using a time series prediction model to predict the state value of each channel at multiple future time steps; and calculating the health of each channel at a future execution time based on the predicted state value, where the health is positively correlated with the predicted availability and negatively correlated with the predicted response time and load.

[0195] According to embodiments of this application, a time series prediction model includes: a position encoding layer for adding time position information to the input historical running state sequence; a multi-head self-attention layer for capturing the dependencies between different time steps in the historical running state sequence; a feedforward neural network layer for performing nonlinear transformation on the output of the multi-head self-attention layer; residual connections and layer normalization units for connecting the multi-head self-attention layer and the feedforward neural network layer respectively, for accelerating model training and stabilizing feature distribution; and an output layer for mapping the output of the feedforward neural network layer to predicted state values ​​for multiple future time steps.

[0196] According to embodiments of this application, scheduling decisions based on health and inter-channel synergy factors include: dividing the required repair operations into at least one execution unit, defining the execution unit as a task, and assigning an execution channel to each task; solving for the task-channel allocation scheme with the objective of maximizing the sum of the health of each channel and the weighted sum of the inter-channel synergy; or solving for the task-channel allocation scheme through multi-objective optimization or weighted summation with the objective of maximizing the sum of the health of each channel at its respective execution time and minimizing the negative synergy between channels; and when the predicted health of a certain channel is lower than a preset threshold, performing at least one of the following avoidance operations: switching to a backup channel, delaying the execution of the task on that channel, or assigning the task to another channel.

[0197] According to embodiments of this application, an online update of the three-dimensional policy fit matrix and channel prediction model is performed through a dual closed-loop feedback mechanism, including: obtaining the execution results of repair operations and calculating the comprehensive score of the execution results; through a policy selection closed loop, using the policy gradient method to calculate the update gradient based on the comprehensive score, and adjusting the fit values ​​in the three-dimensional policy fit matrix and the network parameters used to extract context information based on the update gradient; through a channel scheduling closed loop, obtaining the prediction error between the health predicted by the channel prediction model and the actual observed health, using the backpropagation algorithm to update the parameters of the channel prediction model based on the prediction error, and updating the inter-channel coordination factor based on the execution results of the repair operations.

[0198] According to embodiments of this application, any multiple modules among the information acquisition module 1210, strategy matching module 1220, inference verification module 1230, repair operation module 1240, and data update module 1250 can be merged into one module, or any one of these modules can be split into multiple modules. Alternatively, at least some of the functions of one or more of these modules can be combined with at least some of the functions of other modules and implemented in one module. According to embodiments of this application, at least one of the information acquisition module 1210, strategy matching module 1220, inference verification module 1230, repair operation module 1240, and data update module 1250 can be at least partially implemented as hardware circuits, such as field-programmable gate arrays, programmable logic arrays, systems-on-a-chip, systems-on-a-substrate, systems-on-package, application-specific integrated circuits, or other reasonable means of integrating or packaging circuits, or implemented in any one of software, hardware, and firmware methods, or in a suitable combination of any of these methods. Alternatively, at least one of the information acquisition module 1210, strategy matching module 1220, reasoning verification module 1230, repair operation module 1240, and data update module 1250 may be implemented at least partially as a computer program module, which can perform corresponding functions when the computer program module is run.

[0199] Figure 13 A block diagram schematically illustrates an electronic device suitable for implementing a repair method according to an embodiment of this application.

[0200] like Figure 13 As shown, an electronic device 1300 according to an embodiment of this application includes a processor 1301, which can perform various appropriate actions and processes according to a program stored in a read-only memory 1302 or a program loaded from a storage portion 1308 into a random access memory 1303. The processor 1301 may include, for example, a general-purpose microprocessor, an instruction set processor and / or an associated chipset and / or a dedicated microprocessor. The processor 1301 may also include onboard memory for caching purposes. The processor 1301 may include a single processing unit or multiple processing units for executing different steps of the method flow according to an embodiment of this application.

[0201] Random access memory 1303 stores various programs and data required for the operation of electronic device 1300. Processor 1301, read-only memory 1302, and random access memory 1303 are interconnected via bus 1304. Processor 1301 executes various steps of the method flow according to embodiments of this application by executing programs in read-only memory 1302 and / or random access memory 1303. It should be noted that programs may also be stored in one or more memories other than read-only memory 1302 and random access memory 1303. Processor 1301 may also execute various steps of the method flow according to embodiments of this application by executing programs stored in one or more memories.

[0202] According to embodiments of this application, the electronic device 1300 may further include an input / output interface 1305, which is also connected to a bus 1304. The electronic device 1300 may also include one or more of the following components connected to the input / output interface 1305: an input section 1306 including a keyboard, mouse, etc.; an output section 1307 including a cathode ray tube, liquid crystal display, etc., and a speaker, etc.; a storage section 1308 including a hard disk, etc.; and a communication section 1309 including a network interface card, such as a local area network card, modem, etc. The communication section 1309 performs communication processing via a network such as the Internet. A drive 1310 is also connected to the input / output interface 1305 as needed. A removable medium 1311, such as a disk, optical disk, magneto-optical disk, semiconductor memory, etc., is installed on the drive 1310 as needed so that computer programs read from it can be installed into the storage section 1308 as needed.

[0203] Embodiments of this application also provide a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiments; or it may exist independently and not assembled into the device / apparatus / system. The computer-readable storage medium carries one or more programs, which, when executed, implement the method according to the embodiments of this application.

[0204] According to embodiments of this application, the computer-readable storage medium can be a non-volatile computer-readable storage medium, such as including but not limited to: portable computer disks, hard disks, random access memory, read-only memory, erasable programmable read-only memory, portable compact disk read-only memory, optical storage devices, magnetic storage devices, or any suitable combination thereof. According to embodiments of this application, the computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. For example, according to embodiments of this application, the computer-readable storage medium can include the read-only memory 1302, and / or random access memory 1303, and / or one or more memories other than read-only memory 1302 and random access memory 1303 described above.

[0205] Embodiments of this application also include a computer program product comprising a computer program containing program code for performing the methods shown in the flowchart. When the computer program product is run on a computer system, the program code is used to cause the computer system to implement the methods provided in the embodiments of this application.

[0206] In one embodiment, the computer program may rely on a tangible storage medium such as an optical storage device or a magnetic storage device. In another embodiment, the computer program may also be transmitted and distributed in the form of signals over a network medium, and may be downloaded and installed via the communication section 1309, and / or installed from the removable medium 1311. The program code contained in the computer program can be transmitted using any suitable network medium, including but not limited to: wireless, wired, etc., or any suitable combination thereof.

[0207] According to embodiments of this application, the computer program can be downloaded and installed from a network via communication section 1309, and / or installed from removable medium 1311. When the computer program is executed by processor 1301, it performs the functions defined in the system of embodiments of this application. According to embodiments of this application, the systems, devices, apparatuses, modules, units, etc., described above can be implemented by computer program modules.

[0208] According to embodiments of this application, program code for executing the computer programs provided in the embodiments of this application can be written in any combination of one or more programming languages. Specifically, these computational programs can be implemented using high-level procedural and / or object-oriented programming languages, and / or assembly / machine languages. The program code can be executed entirely on the user's computing device, partially on the user's device, partially on a remote computing device, or entirely on a remote computing device or server. In cases involving remote computing devices, the remote computing device can be connected to the user's computing device via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computing device (e.g., via the Internet using an Internet service provider).

[0209] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram or flowchart, and combinations of blocks in a block diagram or flowchart, may be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.

[0210] Those skilled in the art will understand that the features described in the various embodiments of this application can be combined and / or combined in various ways, even if such combinations or combinations are not explicitly described in this application. In particular, the features described in the various embodiments of this application can be combined and / or combined in various ways without departing from the spirit and teachings of this application. All such combinations and / or combinations fall within the scope of this application.

Claims

1. A repair method, characterized in that, include: Obtain fault information and the context information corresponding to the fault information; Based on the fault information and the context information, a three-dimensional strategy fit matrix is ​​used for strategy matching to obtain candidate strategies and candidate channels; wherein, the three-dimensional strategy fit matrix is ​​used to characterize the degree of fit between fault type, strategy type and channel type. The candidate strategies and channels are inferred and verified using the repaired knowledge graph to obtain optimized strategies and channels. Predictive scheduling is performed on the optimized strategy and channels. The health of each channel at future execution time is predicted using a channel prediction model. Scheduling decisions are made based on the health and the coordination factors between channels, and repair operations are performed. The execution result of the repair operation is obtained, and the three-dimensional strategy adaptation matrix and channel prediction model are updated online through a double closed-loop feedback mechanism. The execution result of the repair operation is then updated to the repair knowledge graph.

2. The method according to claim 1, characterized in that, The context information includes time context, historical context, and application context; The time context includes the time of the fault occurrence and time segment features; The historical context is obtained by encoding historical fault sequences; The application context includes the application identifier and the service type.

3. The method according to claim 1, characterized in that, The three-dimensional strategy adaptation matrix is ​​a three-dimensional array, and the three dimensions of the three-dimensional array correspond to the fault type, strategy type and channel type, respectively. Each element in the three-dimensional array is used to store the adaptation value of the corresponding combination of fault type, strategy type and channel type. The adaptation value is dynamically updated according to the success rate and effect score of historical repair operations.

4. The method according to claim 3, characterized in that, The process of using a three-dimensional policy fit matrix for policy matching to obtain candidate policies and candidate channels includes: The fault type is determined based on the fault information, and the context adaptation weight is determined based on the context information. Retrieve the fit value corresponding to the fault type from the three-dimensional strategy fit matrix; Based on the context adaptation weights, calculate the matching score for each strategy type and channel type combination; The strategy type and channel type with the highest matching score are selected as the candidate strategy and candidate channel.

5. The method according to claim 1, characterized in that, The repair knowledge graph includes fault entities, strategy entities, channel entities, and effect entities; The entities are connected by relational edges, which include at least: the repair relationship between the faulty entity and the strategy entity, the execution relationship between the strategy entity and the channel entity, and the causal relationship between the strategy entity and the effect entity. The repair knowledge graph dynamically updates the weights of the entities and the relation edges based on the actual execution results of each repair operation; The dynamic update includes: adjusting the weight of the repair relationship between the faulty entity and the strategy entity, and the weight of the causal relationship between the strategy entity and the effect entity, based on the execution result of the repair operation.

6. The method according to claim 1, characterized in that, The step of using the repair knowledge graph to perform reasoning verification on the candidate strategies and candidate channels includes: Search the repair knowledge graph for historical fault entities that are similar to the fault information. Obtain one or more historical policy entities and one or more historical channel entities associated with the historical fault entity; Calculate the similarity between the candidate strategy and the historical strategy entity, and the similarity between the candidate channel and the historical channel entity; The candidate strategies and candidate channels are scored based on the similarity to verify or adjust them.

7. The method according to claim 1, characterized in that, The method of using a channel prediction model to predict the health of each channel at future execution times includes: Obtain the historical operating status sequence of each channel, which includes load sequence, response time sequence and failure rate sequence; The historical operating state sequence is processed using a time series prediction model to predict the state value of each channel at multiple future time steps; The health of each channel at the future execution time is calculated based on the predicted state value. The health is positively correlated with the predicted availability and negatively correlated with the predicted response time and load.

8. The method according to claim 7, characterized in that, The time series prediction model includes: The location encoding layer is used to add time and location information to the input historical running state sequence; A multi-head self-attention layer is used to capture the dependencies between different time steps in the historical running state sequence; A feedforward neural network layer is used to perform a nonlinear transformation on the output of the multi-head self-attention layer; Residual connections and layer normalization units connect the multi-head self-attention layer and the feedforward neural network layer, respectively, to accelerate model training and stabilize feature distribution; The output layer is used to map the output of the feedforward neural network layer to predicted state values ​​for multiple future time steps.

9. The method according to claim 1, characterized in that, The scheduling decision based on the health status and the coordination factor between channels includes: The repair operations to be performed are divided into at least one execution unit, the execution unit is defined as a task, and an execution channel is assigned to each task; The goal is to solve the task and channel allocation scheme by maximizing the sum of the health of each channel and the weighted sum of the synergistic effects between channels; or the goal is to maximize the sum of the health of each channel at its respective execution time and minimize the negative synergistic effects between channels by solving the task and channel allocation scheme through multi-objective optimization or weighted summation. When the predicted health of a certain channel is lower than a preset threshold, perform at least one of the following avoidance operations: switch to a backup channel, delay the execution of the task on that channel, or assign the task to another channel.

10. The method according to claim 1, characterized in that, The online updating of the three-dimensional strategy fit matrix and channel prediction model through a dual closed-loop feedback mechanism includes: Obtain the execution result of the repair operation and calculate the comprehensive score of the execution result; By using a closed-loop strategy selection process, the strategy gradient method is employed to calculate and update the gradient based on the comprehensive score. The fitness values ​​in the three-dimensional strategy fitness matrix are then adjusted based on the updated gradient, as are the network parameters used to extract context information. By using a closed-loop channel scheduling mechanism, the prediction error between the health predicted by the channel prediction model and the actual observed health is obtained. The backpropagation algorithm is then used to update the parameters of the channel prediction model based on the prediction error, and the inter-channel coordination factor is updated based on the execution result of the repair operation.

11. A repair device, characterized in that, The device includes: The information acquisition module is used to acquire fault information and the context information corresponding to the fault information; The strategy matching module is used to perform strategy matching using a three-dimensional strategy fit matrix based on the fault information and the context information to obtain candidate strategies and candidate channels; wherein, the three-dimensional strategy fit matrix is ​​used to characterize the degree of fit between fault type, strategy type and channel type. The reasoning and verification module is used to perform reasoning and verification on the candidate strategies and candidate channels using the repaired knowledge graph, so as to obtain optimized strategies and channels. The repair operation module is used to perform predictive scheduling on the optimized strategy and channels, predict the health of each channel at future execution time using a channel prediction model, make scheduling decisions based on the health and the coordination factors between channels, and perform repair operations. The data update module is used to obtain the execution result of the repair operation, update the three-dimensional strategy adaptation matrix and channel prediction model online through a double closed-loop feedback mechanism, and update the execution result of the repair operation to the repair knowledge graph.

12. An electronic device, comprising: One or more processors; Memory, used to store one or more computer programs. The characteristic feature is that the one or more processors execute the one or more computer programs to implement the steps of the method according to any one of claims 1 to 10.

13. A computer-readable storage medium having a computer program or instructions stored thereon, characterized in that, When the computer program or instructions are executed by a processor, they implement the steps of the method according to any one of claims 1 to 10.

14. A computer program product comprising a computer program or instructions, characterized in that, When the computer program or instructions are executed by a processor, they implement the steps of the method according to any one of claims 1 to 10.