Defect repairing method, device and equipment for AI software system of government affair platform and medium
By loading eBPF probes into the K8s cluster of the government platform, multi-dimensional data of the AI software system is obtained. A defect classifier is constructed using graph neural networks and a pre-set distillation mechanism. Combined with reinforcement learning, a repair strategy is determined, thereby realizing the automated detection and repair of defects in the AI software system, improving efficiency and accuracy.
Patent Information
- Application Number
- CN202511596412.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-04
- Publication Date
- 2026-01-20
AI Technical Summary
Existing AI system defect analysis tools cannot capture runtime defects in real time and cannot automatically execute repair strategies, resulting in low efficiency in defect detection and repair.
By loading eBPF probes into the K8s cluster of the government platform, data on the cognitive, data, and behavioral dimensions of the AI software system is obtained. Graph neural networks and teacher models are used to determine defect fingerprints. A target defect classifier is constructed by combining a pre-set distillation mechanism and KL divergence loss function. Reinforcement learning and a pre-set policy library are used to determine defect repair strategies, thereby achieving automated defect repair.
It has achieved a fully automated process for detecting and repairing defects in AI software systems, improving the accuracy and efficiency of defect repair and reducing the burden on the platform.
Smart Images

Figure CN121364967A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of computer, in particular to an AI software system defect repair method and device for government affairs platform, equipment and medium. BACKGROUND
[0002] Traditional ODC (Orthogonal Defect Classification, i.e. orthogonal defect classification) is a classic defect classification framework derived from software engineering, which classifies software defects through dimensions such as "defect type, trigger condition, and impact range". It is initially used for defect management of traditional software. With the development of cloud computing, it has derived Web-ODC, Cloud-ODC and other versions, which adapt to the defect characteristics of Web services and cloud-native applications. However, the above methods do not consider the "data drift-model evolution-reasoning uncertainty" three-way coupling characteristics of AI systems, resulting in low defect identification rate and high false positives for AI-specific defects.
[0003] Current defect analysis tools for AI systems are mainly divided into three categories: offline analysis tools, manual analysis processes, and semi-automatic detection tools. The core function of these tools is to monitor the performance indicators and data quality of AI models to assist technical personnel in identifying defects. However, they cannot capture real-time curves during runtime, let alone automatically trigger defect detection at key nodes such as model pushing and data updating. Moreover, they cannot automatically execute repair strategies, resulting in low efficiency.
[0004] As can be seen from the above, how to improve the efficiency of AI system defect automatic detection and repair is a problem that needs to be solved at present. SUMMARY
[0005] Therefore, the purpose of the present application is to provide an AI software system defect repair method and device for government affairs platform, which can improve the efficiency of AI system defect automatic detection and repair. The specific solutions are as follows:
[0006] In the first aspect, the present application provides an AI software system defect repair method for government affairs platform, comprising:
[0007] load an eBPF probe on a K8s cluster of a government affair platform to obtain target data of a current platform AI software system in a running process by using the eBPF probe, and determine a defect fingerprint based on the target data; the target data includes data in a cognitive dimension, a data dimension, and a behavior dimension; the data in the cognitive dimension is uncertainty, confidence distribution, and interpretability indicators of the current platform AI software system in reasoning; the data in the data dimension includes input data drift, feature distribution offset, and label noise entropy of the current platform AI software system; the data in the behavior dimension includes API calling sequence, tensor abnormal data, and running resource mutation data of the current platform AI software system;
[0008] determine a target defect classifier based on a graph neural network, a teacher model, a student model, a preset distillation mechanism, and a KL divergence loss function, determine a defect matrix based on the defect fingerprint and by using the target defect classifier, determine a target strategy composer by using reinforcement learning and a preset strategy library, and determine a target defect repair strategy based on the defect matrix and business data and by using the target strategy composer; the preset strategy library includes a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy; the business data is a business indicator of the current platform AI software system in the government affair platform;
[0009] repair defects of the current platform AI software system by using the target defect repair strategy to obtain a repaired AI software system, and verify the repaired AI software system; if the verification is passed, the defect repair operation on the platform AI software system is completed.
[0010] Optionally, the K8s cluster based on the government affair platform loads the eBPF probe to obtain the target data of the current platform AI software system in the running process by using the eBPF probe, and determines the defect fingerprint based on the target data, including:
[0011] deploy a corresponding sidecar container on a container group running an AI business in the K8s cluster based on the government affair platform, and load the eBPF probe by using the sidecar container;
[0012] obtain data in the cognitive dimension, the data dimension, and the behavior dimension of the current platform AI software system based on a model update event or a code merging event of the current platform AI software system and by using the eBPF probe, and construct running data based on the data in the cognitive dimension, the data dimension, and the behavior dimension;
[0013] The sidecar container adds noise to the running data to obtain target data, encodes the target data based on a preset encoding manner to obtain a structured feature vector for mapping a defect feature, and determines a defect fingerprint based on the structured feature vector.
[0014] Optionally, the target defect classifier is determined based on the graph neural network, the teacher model, the student model, a preset distillation mechanism, and a KL divergence loss function, and includes:
[0015] The structured feature vector is determined as a node, and a dependency relationship between data in each dimension in the running data is determined as an edge.
[0016] A graph neural network is constructed based on the node and the edge, a graph neural network meeting a preset high-precision condition is determined as a teacher model, and a graph neural network not meeting the preset high-precision condition is determined as a student model.
[0017] An initial defect classifier is determined based on the teacher model, the student model, a preset distillation mechanism, and a KL divergence loss function.
[0018] When the current platform AI software system is updated or data distribution drifts, the initial defect classifier is fine-tuned based on a small sample and a preset distillation mechanism, and a target defect classifier is determined based on an adjustment result.
[0019] Optionally, the defect matrix is determined based on the defect fingerprint and the target defect classifier, a target strategy composer is determined based on reinforcement learning and a preset strategy library, a target defect repair strategy is determined based on the defect matrix and business data and the target strategy composer, and includes:
[0020] The defect fingerprint is input into the target defect classifier to obtain a defect matrix of a target structure.
[0021] A preset strategy library is constructed based on a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy, and a target strategy composer is determined based on reinforcement learning and the preset strategy library.
[0022] A reward function is determined based on a defect repair time length corresponding to each repair strategy in the preset strategy library and business data, and a target defect repair strategy is determined based on the reward function, the defect matrix, and the target strategy composer.
[0023] Optionally, the target defect repair strategy is determined based on the reward function, the defect matrix, and the target strategy composer, and includes:
[0024] If the defect matrix indicates that the current platform AI software system has a data dimension defect, a data correction strategy is determined as the target defect repair strategy;
[0025] If the defect matrix indicates that the current platform AI software system has a cognitive dimension defect, a hyperparameter rollback strategy is determined as the target defect repair strategy;
[0026] If the defect matrix indicates that the current platform AI software system has a behavior dimension defect, a model hot patch strategy is determined as the target defect repair strategy;
[0027] If the defect matrix indicates that the current platform AI software system has a target defect that meets a preset high severity level condition, a canary release strategy is determined as the target defect repair strategy.
[0028] Optionally, the target defect repair strategy is used to repair defects in the current platform AI software system to obtain a repaired AI software system, and the repaired AI software system is verified. If the verification is passed, the defect repair operation on the platform AI software system is completed, including:
[0029] If the target defect repair strategy is a data correction strategy, user behavior incremental data of a preset time period is obtained, and a sliding window technique is used to filter the user behavior incremental data to obtain processed incremental data. The processed incremental data is added to an input data source of the current platform AI software system to obtain a repaired AI software system. The data dimension data of the repaired AI software system is detected. If the first detection result indicates that the data dimension data in a first target time period is normal, the defect repair operation on the platform AI software system is completed.
[0030] If the target defect repair strategy is a hyperparameter rollback strategy, a previous version of the platform AI software system obtained by rollback is determined as the current platform AI software system to obtain a repaired AI software system. The cognitive dimension data of the repaired AI software system is detected. If the second detection result indicates that the cognitive dimension data in a second target time period is normal, the defect repair operation on the platform AI software system is completed.
[0031] If the target defect repair strategy is a model hot patch strategy, a hot patch is loaded into a running environment of the current platform AI software system to obtain a repaired AI software system. The behavior dimension data of the repaired AI software system is detected. If the third detection result indicates that the behavior dimension data in a third target time period is normal, the defect repair operation on the platform AI software system is completed.
[0032] If the target defect repair strategy is a canary release strategy, a preset number of business nodes of the current platform AI software system are repaired based on the current platform AI software system to obtain repaired nodes, the government affairs platform and the corresponding business traffic of the preset number are introduced into the repaired nodes, and the repaired nodes are subjected to first canary verification. If the first verification result obtained indicates that the business data of the current platform AI software system in the fourth target time period is normal, a new preset number is determined based on a preset addition ratio, and then the step of repairing the business nodes of the current platform AI software system based on the preset number is jumped to. Until all business traffic is introduced into all repaired nodes, a repaired AI software system is obtained. The repaired AI software system is subjected to second canary verification. If the second verification result obtained indicates that the verification is passed, the defect repair operation of the platform AI software system is completed.
[0033] Optionally, the verification of the repaired AI software system, if the verification is passed, the defect repair operation of the platform AI software system is completed, comprising:
[0034] The repaired AI software system is verified, if the verification is passed, the repair effect is evaluated based on the repaired AI software system and the current platform AI software system and by using a double difference method to obtain a corresponding evaluation result. The evaluation result is fed back to the target defect classifier, so as to optimize the target defect classifier by using the evaluation result to obtain a new target defect classifier.
[0035] In a second aspect, the present application provides an AI software system defect repair device of a government affairs platform, comprising:
[0036] A defect fingerprint determination module is configured to load an eBPF probe based on a K8s cluster of a government affairs platform, to obtain target data of a current platform AI software system in a running process by using the eBPF probe, and to determine a defect fingerprint based on the target data. The target data includes data in cognitive dimension, data dimension, and behavior dimension. The data in the cognitive dimension includes uncertainty, confidence distribution, and interpretability index of the current platform AI software system during reasoning. The data in the data dimension includes input data drift, feature distribution offset, and annotation noise entropy of the current platform AI software system. The data in the behavior dimension includes API call sequence, tensor abnormal data, and running resource mutation data of the current platform AI software system.
[0037] The repair strategy determination module is configured to determine a target defect classifier based on a graph neural network, a teacher model, a student model, a preset distillation mechanism and a KL divergence loss function, determine a defect matrix based on the defect fingerprint and using the target defect classifier, determine a target strategy composer using reinforcement learning and a preset strategy library, and determine a target defect repair strategy based on the defect matrix and business data and using the target strategy composer; the preset strategy library includes a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy and a canary release strategy; and the business data is a business index of the current platform AI software system in the government affair platform.
[0038] The defect repair module is configured to perform defect repair on the current platform AI software system using the target defect repair strategy to obtain a repaired AI software system, and verify the repaired AI software system, and if the verification is passed, complete the defect repair operation on the platform AI software system.
[0039] In a third aspect, the present application provides an electronic device, comprising:
[0040] A memory configured to save a computer program;
[0041] A processor configured to execute the computer program to implement the AI software system defect repair method of the government affair platform.
[0042] In a fourth aspect, the present application provides a computer readable storage medium configured to save a computer program, wherein the computer program is executed by a processor to implement the AI software system defect repair method of the government affair platform.
[0043] The eBPF probe is loaded based on the K8s cluster of the government affair platform to obtain target data of a current platform AI software system in a running process by using the eBPF probe, and a defect fingerprint is determined based on the target data; the target data includes data in a cognitive dimension, a data dimension, and a behavior dimension; the data in the cognitive dimension is an uncertainty, a confidence distribution, and an interpretability index of the current platform AI software system when reasoning; the data in the data dimension includes an input data drift amount, a feature distribution offset amount, and a label noise entropy of the current platform AI software system; the data in the behavior dimension includes an API calling sequence, tensor abnormal data, and running resource mutation data of the current platform AI software system; a target defect classifier is determined based on a graph neural network, a teacher model, a student model, a preset distillation mechanism, and a KL divergence loss function, a defect matrix is determined based on the defect fingerprint and by using the target defect classifier, a target strategy composer is determined by using reinforcement learning and a preset strategy library, and a target defect repair strategy is determined based on the defect matrix and business data and by using the target strategy composer; the preset strategy library includes a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy; the business data is a business index of the current platform AI software system in the government affair platform; the current platform AI software system is repaired by using the target defect repair strategy to obtain a repaired AI software system, the repaired AI software system is verified, and if the verification is passed, a defect repair operation on the platform AI software system is completed.
[0044] As can be seen from the above, the three-dimensional data of the current platform AI software system is collected by the eBPF probe to determine the defect fingerprint without invasion, so that the platform business efficiency is not affected by data collection, the target defect classifier is determined based on the graph neural network, the defect fingerprint, and the preset distillation mechanism, the corresponding defect matrix is output by using the target defect classifier and the defect fingerprint, the types of defects can be accurately distinguished, and then the target defect repair strategy corresponding to the defect matrix is matched by using the target strategy composer to accurately repair the defects. In this way, if the repaired AI software system is verified, it means that the repair is completed, and the whole process from data collection to defect classification and then to defect repair is automatically triggered and completed, which greatly reduces the burden of the platform and improves the accuracy and efficiency of defect repair. BRIEF DESCRIPTION OF DRAWINGS
[0045] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, the drawings in the following description only belong to the embodiments of the present application, and those skilled in the art can also obtain other drawings according to the provided drawings without any creative effort.
[0046] Figure 1 A flow chart of an AI software system defect repair method of a government affair platform disclosed by the present application;
[0047] Figure 2 A flow chart of a specific AI software system defect repair method of a government affair platform disclosed by the present application;
[0048] Figure 3 A defect matrix generation schematic diagram provided by the present application;
[0049] Figure 4 A target defect repair strategy determination schematic diagram provided by the present application;
[0050] Figure 5 A structure schematic diagram of an AI software system defect repair device of a government affair platform disclosed by the present application;
[0051] Figure 6 A structure diagram of an electronic device disclosed by the present application. DETAILED DESCRIPTION
[0052] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work fall within the scope of protection of the present application.
[0053] At present, the defect analysis tools for AI systems are mainly divided into three categories: offline analysis tools, manual analysis processes and semi-automatic detection tools. The core function of these tools is to monitor the performance indicators and data quality of AI models in order to assist technical personnel to find defects, but they cannot capture the runtime curve in real time, and cannot automatically trigger defect detection at key nodes such as model pushing and data updating, so the efficiency is very low. Therefore, the present application provides an AI software system defect repair method of a government affair platform, so that if the repaired AI software system passes the verification, it means that the repair is complete, and the whole process from data collection to defect classification to defect repair is automatically triggered and completed, which greatly reduces the burden of the platform and improves the accuracy and efficiency of defect repair.
[0054] Referring to Figure 1 The embodiments of the present application disclose an AI software system defect repair method of a government affair platform, which comprises:
[0055] In step S11, the eBPF probe is loaded based on the K8s cluster of the government affair platform to obtain target data of the current platform AI software system in the running process by using the eBPF probe, and determine the defect fingerprint based on the target data; the target data includes data in the cognitive dimension, data dimension and behavior dimension; the data in the cognitive dimension is the uncertainty, confidence distribution and interpretability index of the current platform AI software system in reasoning; the data in the data dimension includes the input data drift, feature distribution offset and label noise entropy of the current platform AI software system; the data in the behavior dimension includes the API calling sequence, tensor abnormal data and running resource mutation data of the current platform AI software system.
[0056] In this embodiment, in the K8s (Kubernetes, a kind of container orchestration tool) cluster of the government affair platform, a corresponding Sidecar container (a sidecar container) is deployed for each K8s Pod (a container group) running AI business, and an eBPF (Extended Berkeley Packet Filter, an extended Berkeley packet filter) probe is loaded in the sidecar container. When the current platform AI software system runs, such as model reasoning and processing business data, the eBPF probe is used to obtain the data of the current platform AI software system in the cognitive dimension, data dimension and behavior dimension to obtain running data. The data in the cognitive dimension can be the confidence value and interpretability index of the AI model for the prediction result, the data in the data dimension can be the difference between the input data and the training data, and the proportion of annotation errors, and the data in the behavior dimension can be the API interface calling sequence, intermediate data anomaly, and sudden fluctuation of CPU / memory resources. The running data is differentially private and noisy, and is encoded in a differentiable way to obtain a structured feature vector, and the structured feature vector is used to determine the defect fingerprint. The current platform AI software system supports TensorFlow, PyTorch and other mainstream AI frameworks, and a preset unified processing interface is opened at the same time to ensure that the data of different AI frameworks can be uniformly processed.
[0057] Specifically, the K8s cluster based on the government affair platform loads the eBPF probe to obtain target data of the current platform AI software system in the running process by using the eBPF probe, and determines a defect fingerprint based on the target data, including: deploying a corresponding sidecar container by using a container group running an AI business in the K8s cluster based on the government affair platform, and loading the eBPF probe by using the sidecar container; obtaining data of the current platform AI software system in the cognitive dimension, the data dimension and the behavior dimension based on a model update event or a code merging event of the current platform AI software system and using the eBPF probe, and constructing running data based on the data in the cognitive dimension, the data dimension and the behavior dimension; adding noise to the running data by using the sidecar container to obtain target data, encoding the target data based on a preset encoding mode to obtain a structured feature vector for mapping defect features, and determining a defect fingerprint by using the structured feature vector.
[0058] In step S12, a target defect classifier is determined based on a graph neural network, a teacher model, a student model, a preset distillation mechanism and a KL divergence loss function, a defect matrix is determined based on the defect fingerprint and by using the target defect classifier, a target strategy composer is determined by using reinforcement learning and a preset strategy library, and a target defect repair strategy is determined based on the defect matrix and business data and by using the target strategy composer; the preset strategy library includes a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy and a canary release strategy; the business data is a business indicator of the current platform AI software system in the government affair platform.
[0059] In this embodiment, the structured feature vector is determined as a node, and the dependency relationship between the data in each dimension in the running data is determined as an edge to construct a graph neural network, a graph neural network meeting a preset high-precision condition is determined as a teacher model, and a graph neural network not meeting the preset high-precision condition is determined as a student model, a preset distillation mechanism of the teacher model and the student model is constructed, and the student model is made to imitate the judgment logic of the teacher model by using a KL divergence (Kullback-Leibler divergence) loss function. When the current platform AI software system is updated or the data distribution drifts, the classifier can be quickly updated by using 10 small samples to obtain a target defect classifier.
[0060] Specifically, the target defect classifier determined based on the graph neural network, the teacher model, the student model, the preset distillation mechanism and the KL divergence loss function comprises: determining the structured feature vector as a node and determining the dependency relationship between data in each dimension in the running data as an edge; constructing a graph neural network based on the node and the edge, determining a graph neural network meeting a preset high-precision condition as a teacher model, and determining a graph neural network not meeting the preset high-precision condition as a student model; determining an initial defect classifier by using the teacher model, the student model, a preset distillation mechanism and a KL divergence loss function; when the current platform AI software system is updated or data distribution drifts, fine-tuning the initial defect classifier by using the preset distillation mechanism, and determining a target defect classifier based on an adjustment result.
[0061] It can be understood that the defect fingerprint is input into the target defect classifier to obtain a defect matrix of a 4*5 structure, a preset strategy library is constructed based on a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy and a canary release strategy, a target strategy composer is determined by using a reinforcement learning network and the preset strategy library, and a target defect repair strategy is determined by using the reward function, the defect matrix and the target strategy composer. Specifically, the defect matrix is determined based on the defect fingerprint and the target defect classifier, the target strategy composer is determined by using reinforcement learning and a preset strategy library, and the target defect repair strategy is determined based on the defect matrix and business data and by using the target strategy composer, which comprises: inputting the defect fingerprint into the target defect classifier to obtain a defect matrix of a target structure; constructing a preset strategy library based on a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy and a canary release strategy, and determining a target strategy composer by using reinforcement learning and the preset strategy library; determining a reward function based on the defect repair time length corresponding to each repair strategy in the preset strategy library and business data, and determining a target defect repair strategy by using the reward function, the defect matrix and the target strategy composer.
[0062] Further, based on the defect matrix and using the reward function and the target strategy composer, a target defect repair strategy is determined, and the target defect repair strategy has four types, a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy. If the defect matrix represents that the current platform AI software system has a data dimension defect including input data drift, the data correction strategy is determined as the target defect repair strategy; the input data drift is that the input data drift exceeds a preset drift threshold; if the defect matrix represents that the current platform AI software system has a cognitive dimension defect including low model confidence, the hyperparameter rollback strategy is determined as the target defect repair strategy; the low model confidence is that the confidence distribution does not satisfy a preset confidence threshold; if the defect matrix represents that the current platform AI software system has a behavior dimension defect including tensor anomaly, the model hot patch strategy is determined as the target defect repair strategy; the tensor anomaly is that the tensor anomaly data exceeds a preset anomaly threshold; if the defect matrix represents that the current platform AI software system has a target defect satisfying a preset high severity level condition, the canary release strategy is determined as the target defect repair strategy. It is worth mentioning that the preset high severity level condition can be determined according to actual conditions, and the defect matrix corresponding to other defect repair strategies except the target defect repair strategy being the canary release does not satisfy the preset high severity level condition.
[0063] Specifically, the target defect repair strategy is determined by using the reward function, the defect matrix, and the target strategy composer, including: if the defect matrix represents that the current platform AI software system has a data dimension defect, the data correction strategy is determined as the target defect repair strategy; if the defect matrix represents that the current platform AI software system has a cognitive dimension defect, the hyperparameter rollback strategy is determined as the target defect repair strategy; if the defect matrix represents that the current platform AI software system has a behavior dimension defect, the model hot patch strategy is determined as the target defect repair strategy; if the defect matrix represents that the current platform AI software system has a target defect satisfying a preset high severity level condition, the canary release strategy is determined as the target defect repair strategy.
[0064] In step S13, the target defect repair strategy is used to repair the defects of the current platform AI software system to obtain a repaired AI software system, and the repaired AI software system is verified. If the verification is passed, the defect repair operation of the platform AI software system is completed.
[0065] In this embodiment, the target defect repair strategy is used to repair defects in the current platform AI software system to obtain a repaired AI software system. In a first specific implementation, if the target defect repair strategy is a data correction strategy, user behavior incremental data of a preset time period is obtained, and a sliding window technique is used to filter abnormal data in the user behavior incremental data to obtain processed incremental data. The processed incremental data is added to an input data source of the current platform AI software system to obtain a repaired AI software system. The data dimension data of the repaired AI software system is detected, and if the first detection result represents that the data dimension data in the first target time period is normal, the defect repair operation of the platform AI software system is completed. The first target time period can be 5 minutes.
[0066] In a second specific implementation, if the target defect repair strategy is a super parameter rollback strategy, the last version of the platform AI software system obtained by rollback is determined as the current platform AI software system to obtain a repaired AI software system. In a third specific implementation, if the target defect repair strategy is a model hot patch strategy, a hot patch is loaded into the running environment of the current platform AI software system to obtain a repaired AI software system. In a fourth specific implementation, if the target defect repair strategy is a canary release strategy, a preset number of business nodes of the current platform AI software system are repaired to obtain repaired nodes. The government affairs platform and the corresponding business traffic of the preset number are imported into the repaired nodes, and a first canary verification is performed on the repaired nodes. If the first verification result represents that the business data of the current platform AI software system in the fourth target time period is normal, a new preset number is determined based on a preset addition ratio, and then the step of repairing the preset number of business nodes of the current platform AI software system is jumped to until all business traffic is imported into all repaired nodes to obtain a repaired AI software system. That is, part of the nodes are repaired first, and whether the repaired nodes are normal is verified. If normal, the repair is continued until all nodes are repaired. A second canary verification is performed on the repaired AI software system, and if the second verification result represents that the verification is passed, the defect repair operation of the platform AI software system is completed. It is worth mentioning that no matter which target defect repair strategy is used to repair defects in the current platform AI software system, the repaired AI software system can be checked and verified by using the canary verification method.
[0067] Specifically, the target defect repair strategy is used to repair defects in the current platform AI software system to obtain a repaired AI software system, the repaired AI software system is verified, if the verification is passed, the defect repair operation of the platform AI software system is completed, including: if the target defect repair strategy is a data correction strategy, user behavior incremental data of a preset time period is obtained, and a sliding window technology is used to filter the user behavior incremental data to obtain processed incremental data, the processed incremental data is added to an input data source of the current platform AI software system to obtain a repaired AI software system, data dimension data of the repaired AI software system is detected, if a first detection result obtained represents that the data dimension data in a first target time period is normal, the defect repair operation of the platform AI software system is completed; if the target defect repair strategy is a super parameter rollback strategy, a platform AI software system of a previous version rolled back is determined as the current platform AI software system to obtain a repaired AI software system, cognitive dimension data of the repaired AI software system is detected, if a second detection result obtained represents that the cognitive dimension data in a second target time period is normal, the defect repair operation of the platform AI software system is completed; if the target defect repair strategy is a model hot patch strategy, a hot patch is loaded into a running environment of the current platform AI software system to obtain a repaired AI software system, behavior dimension data of the repaired AI software system is detected, if a third detection result obtained represents that the behavior dimension data in a third target time period is normal, the defect repair operation of the platform AI software system is completed; if the target defect repair strategy is a canary release strategy, a preset number of business nodes of the current platform AI software system are repaired to obtain repaired nodes, the government affairs platform and business traffic corresponding to the preset number are imported into the repaired nodes, and the repaired nodes are subjected to first canary verification, if a first verification result obtained represents that business data of the current platform AI software system in a fourth target time period is normal, a new preset number is determined based on a preset addition ratio, and then the step of repairing the preset number of business nodes of the current platform AI software system is jumped to, until full business traffic is imported into all repaired nodes to obtain a repaired AI software system, the repaired AI software system is subjected to second canary verification, if a second verification result obtained represents that the verification is passed, the defect repair operation of the platform AI software system is completed.
[0068] It can be understood that the repaired AI software system is verified, if the verification is passed, the repair effect is evaluated based on the repaired AI software system and the current platform AI software system and by using double difference method, the obtained evaluation result is used to optimize the target defect classifier to obtain a new target defect classifier, if the verification is not passed or the confidence of the target defect repair strategy is lower than the target confidence threshold, a corresponding explainable report is generated and submitted to the government platform, and then the AI software system of the original version is rolled back to prevent the interruption of government services. Specifically, the repaired AI software system is verified, if the verification is passed, the defect repair operation of the platform AI software system is completed, including: verifying the repaired AI software system, if the verification is passed, the repair effect is evaluated based on the repaired AI software system and the current platform AI software system and by using double difference method, the evaluation result is fed back to the target defect classifier, the evaluation result is used to optimize the target defect classifier to obtain a new target defect classifier.
[0069] As can be seen from the above, the three-dimensional data of the current platform AI software system is collected by the eBPF probe without invasion to determine the defect fingerprint, which can avoid affecting the platform service efficiency due to data collection, the target defect classifier is determined based on the graph neural network, the defect fingerprint and the preset distillation mechanism, and the corresponding defect matrix is output by using the target defect classifier and the defect fingerprint, which can accurately distinguish various defects, and then the target defect repair strategy corresponding to the defect matrix is matched by using the target strategy editor to accurately repair the defects. In this way, if the repaired AI software system is verified, it means that the repair is completed, and the whole process from data collection to defect classification and then to defect repair is automatically triggered and completed, which greatly reduces the burden of the platform and improves the accuracy and efficiency of defect repair.
[0070] As can be seen from the above embodiment, the defect repair operation of the AI software system is realized based on the target strategy editor and the target defect classifier, therefore, the process of realizing the defect repair operation of the AI software system based on the target strategy editor and the target defect classifier is described.
[0071] Referring to Figure 2 As shown in the figure, the embodiment of the application discloses a specific AI software system defect repair method of government platform, which comprises:
[0072] In this embodiment, the K8s cluster based on the government affair platform deploys a corresponding sidecar container for each container group running the AI service, loads an eBPF probe in the sidecar container, configures mainstream AI frameworks such as TensorFlow and PyTorch supported by the current platform AI software system, and simultaneously opens a preset unified processing interface. When the government affair platform updates the AI software system or synchronizes data, a CI (Continuous Integration) / CD (Continuous Delivery / Deployment) event stream sends a signal to the sidecar container to trigger the eBPF probe to start data collection, that is, to obtain the running data of the current platform AI software system in the cognitive dimension, the data dimension, and the behavior dimension by using the eBPF probe. The data in the cognitive dimension is the uncertainty, confidence distribution, and interpretability index of the current platform AI software system during inference. The data in the data dimension includes the input data drift, feature distribution offset, and label noise entropy of the current platform AI software system. The data in the behavior dimension includes the API call sequence, tensor abnormal data, and running resource mutation data of the current platform AI software system. The running data is locally differentially private and noisy, and the obtained target data is differentially encoded to obtain a defect fingerprint including a structured feature vector.
[0073] Figure 3 A defect matrix generation schematic diagram is provided for this embodiment. The structured feature vector is determined as a node, and the dependency relationship between the data in each dimension in the running data is determined as an edge to construct a graph neural network (GNN). The graph neural network that meets the preset high-precision condition is determined as a teacher model, and the graph neural network that does not meet the preset high-precision condition is determined as a student model. A preset distillation mechanism of the teacher model and the student model is constructed, and a KL divergence loss function is used to determine a target defect classifier. The defect fingerprint is input into the target defect classifier to obtain a 4*5 structure defect matrix.
[0074] Figure 4An example of a target defect repair strategy determination schematic provided by the embodiment is provided. After obtaining the defect matrix, a preset strategy library is constructed based on a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy. A reinforcement learning network and the preset strategy library are used to determine a target strategy composer. The target defect repair strategy is determined based on the defect matrix and business data and using the target strategy composer. The current platform AI software system is repaired using the target defect repair strategy to obtain a repaired AI software system. The repaired AI software system is verified by canary. If the verification is passed, the defect repair operation of the platform AI software system is completed. If the verification is not passed, a rollback mechanism is triggered to automatically roll back to the original version of the platform AI software system.
[0075] As can be seen from the above, the present application collects data of AI business running in three dimensions of the current platform AI software system through non-invasive deployment of eBPF probes, and then obtains a defect fingerprint. Then, a target defect classifier is determined based on a graph neural network, the defect fingerprint, and a preset distillation mechanism. The corresponding defect matrix is output using the target defect classifier and the defect fingerprint. The target defect repair strategy corresponding to the defect matrix is determined based on a target strategy composer. In this way, the current platform AI software system is repaired using the target defect repair strategy, realizing a full-automatic process of AI software system defect repair, significantly shortening the defect repair time of the AI software system, and improving the reliability of the government affairs platform.
[0076] Correspondingly, referring to Figure 5 The present application also provides an AI software system defect repair device for a government affairs platform, which comprises:
[0077] A defect fingerprint determination module 11 is configured to load an eBPF probe based on a K8s cluster of the government affairs platform, to obtain target data of the current platform AI software system during running by using the eBPF probe, and to determine a defect fingerprint based on the target data. The target data includes data in cognitive dimension, data dimension, and behavior dimension. The data in cognitive dimension includes uncertainty, confidence distribution, and interpretability index of the current platform AI software system during inference. The data in data dimension includes input data drift, feature distribution offset, and label noise entropy of the current platform AI software system. The data in behavior dimension includes API call sequence, tensor abnormal data, and running resource mutation data of the current platform AI software system.
[0078] The repair strategy determination module 12 is configured to determine a target defect classifier based on a graph neural network, a teacher model, a student model, a preset distillation mechanism, and a KL divergence loss function, determine a defect matrix based on the defect fingerprint and by using the target defect classifier, determine a target strategy composer by using reinforcement learning and a preset strategy library, and determine a target defect repair strategy based on the defect matrix and business data and by using the target strategy composer. The preset strategy library includes a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy. The business data is a business indicator of the current platform AI software system in a government affair platform.
[0079] The defect repair module 13 is configured to perform defect repair on the current platform AI software system by using the target defect repair strategy, to obtain a repaired AI software system, and to verify the repaired AI software system. If the verification is passed, the defect repair operation on the platform AI software system is completed.
[0080] In some embodiments, the defect fingerprint determination module 11 can specifically include:
[0081] The probe loading unit is configured to deploy a corresponding sidecar container based on a container group that runs an AI business in a K8s cluster of a government affair platform, and load an eBPF probe by using the sidecar container.
[0082] The running data construction unit is configured to obtain data of the current platform AI software system in a cognitive dimension, a data dimension, and a behavior dimension based on a model update event or a code merge event of the current platform AI software system and by using an eBPF probe, and construct running data based on the data in the cognitive dimension, the data dimension, and the behavior dimension.
[0083] The fingerprint determination unit is configured to add noise to the running data by using the sidecar container, to obtain target data, encode the target data based on a preset encoding manner, to obtain a structured feature vector for mapping defect features, and determine a defect fingerprint by using the structured feature vector.
[0084] In some embodiments, the repair strategy determination module 12 can specifically include:
[0085] The edge determination unit is configured to determine the structured feature vector as a node, and determine a dependency relationship between data in each dimension in the running data as an edge.
[0086] The student model determination unit is configured to construct a graph neural network based on the node and the edge, determine a graph neural network that meets a preset high-precision condition as a teacher model, and determine a graph neural network that does not meet the preset high-precision condition as a student model.
[0087] a classifier determination unit configured to determine an initial defect classifier by using the teacher model, the student model, a preset distillation mechanism, and a KL divergence loss function;
[0088] a classifier fine-tuning unit configured to fine-tune the initial defect classifier by using the preset distillation mechanism when the current platform AI software system is updated or data distribution drifts, and determine a target defect classifier based on an adjustment result.
[0089] In some embodiments, the repair strategy determination module 12 can specifically include:
[0090] a matrix determination unit configured to input the defect fingerprint into the target defect classifier to obtain a defect matrix of a target structure;
[0091] a target orchestrator determination unit configured to construct a preset strategy library based on a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy, and determine a target strategy orchestrator by using reinforcement learning and the preset strategy library;
[0092] a strategy determination unit configured to determine a reward function based on a defect repair time length corresponding to each repair strategy in the preset strategy library and business data, and determine a target defect repair strategy by using the reward function, the defect matrix, and the target strategy orchestrator.
[0093] In some embodiments, the repair strategy determination module 12 can specifically include:
[0094] a first target strategy determination unit configured to determine the data correction strategy as the target defect repair strategy if the defect matrix indicates that the current platform AI software system has a data dimension defect;
[0095] a second target strategy determination unit configured to determine the hyperparameter rollback strategy as the target defect repair strategy if the defect matrix indicates that the current platform AI software system has a cognitive dimension defect;
[0096] a third target strategy determination unit configured to determine the model hot patch strategy as the target defect repair strategy if the defect matrix indicates that the current platform AI software system has a behavior dimension defect;
[0097] a fourth target strategy determination unit configured to determine the canary release strategy as the target defect repair strategy if the defect matrix indicates that the current platform AI software system has a target defect that meets a preset high severity level condition.
[0098] In some embodiments, the defect repair module 13 can specifically include:
[0099] The first system repair unit is configured to, if the target defect repair strategy is a data correction strategy, acquire user behavior incremental data in a preset time period, filter the user behavior incremental data by using a sliding window technology to obtain processed incremental data, add the processed incremental data to an input data source of the current platform AI software system to obtain a repaired AI software system, and detect data dimension data of the repaired AI software system. If a first detection result obtained by the detection represents that the data dimension data in a first target time period is normal, the defect repair operation on the platform AI software system is completed.
[0100] The second system repair unit is configured to, if the target defect repair strategy is a super parameter rollback strategy, determine a platform AI software system of a previous version rolled back as the current platform AI software system to obtain a repaired AI software system, detect cognitive dimension data of the repaired AI software system, and if a second detection result obtained by the detection represents that the cognitive dimension data in a second target time period is normal, the defect repair operation on the platform AI software system is completed.
[0101] The third system repair unit is configured to, if the target defect repair strategy is a model hot patch strategy, load a hot patch to a running environment of the current platform AI software system to obtain a repaired AI software system, detect behavior dimension data of the repaired AI software system, and if a third detection result obtained by the detection represents that the behavior dimension data in a third target time period is normal, the defect repair operation on the platform AI software system is completed.
[0102] The fourth system repair unit is configured to, if the target defect repair strategy is a canary release strategy, repair a preset number of business nodes based on the current platform AI software system to obtain repaired nodes, import the government affairs platform and business traffic corresponding to the preset number to the repaired nodes, and perform first canary verification on the repaired nodes. If a first verification result obtained by the verification represents that business data of the current platform AI software system in a fourth target time period is normal, a new preset number is determined based on a preset addition ratio, and then the step of repairing the preset number of business nodes based on the current platform AI software system is jumped to until full business traffic is imported to all repaired nodes to obtain a repaired AI software system. Second canary verification is performed on the repaired AI software system. If a second verification result obtained by the verification represents that the verification is passed, the defect repair operation on the platform AI software system is completed.
[0103] In some embodiments, the defect repair module 13 can specifically include:
[0104] An effect evaluation unit is configured to verify the repaired AI software system, and if the verification is passed, evaluate the repair effect based on the repaired AI software system and the current platform AI software system and by using a double difference method to obtain a corresponding evaluation result, and feed back the evaluation result to the target defect classifier to optimize the target defect classifier by using the evaluation result to obtain a new target defect classifier.
[0105] Further, the embodiment of the present application further discloses an electronic device, Figure 6 is an electronic device 20 structure diagram shown according to an exemplary embodiment, the contents in the figure cannot be considered as any limitation on the use range of the present application. The electronic device 20, specifically can include: at least one processor 21, at least one memory 22, power supply 23, communication interface 24, input output interface 25 and communication bus 26. Wherein, the memory 22 is used for storing computer programs, the computer programs are loaded and executed by the processor 21, to realize the related steps in the AI software system defect repair method of the government affairs platform disclosed in any of the preceding embodiments. In addition, the electronic device 20 in the embodiment specifically can be an electronic computer.
[0106] In the embodiment, the power supply 23 is used to provide working voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and the external device, and the communication protocol followed by the communication interface 24 can be any communication protocol applicable to the technical solution of the present application, which is not limited here; the input output interface 25 is used to obtain external input data or output data to the outside world, and the specific interface type can be selected according to the specific application needs, which is not limited here.
[0107] In addition, the memory 22 as the carrier of resource storage can be read-only memory, random access memory, disk or optical disk, etc., and the resources stored thereon can include operating system 221, computer program 222, etc., and the storage mode can be temporary storage or permanent storage.
[0108] Wherein, the operating system 221 is used to manage and control each hardware device on the electronic device 20 and the computer program 222, which can be Windows Server, Netware, Unix, Linux, etc. The computer program 222 can further include computer programs capable of completing other specific work in addition to the computer programs capable of completing the AI software system defect repair method of the government affairs platform executed by the electronic device 20 disclosed in any of the preceding embodiments.
[0109] Further, the application also discloses a computer readable storage medium for storing a computer program, wherein the computer program is executed by a processor to realize the AI software system defect repairing method of the government affair platform disclosed above. For the specific steps of the method, refer to the corresponding content disclosed in the foregoing embodiments, which will not be repeated here.
[0110] The various embodiments are described in the specification by progressive stages, and each embodiment focuses on the difference from other embodiments. For the same or similar parts between the embodiments, refer to each other. For the device disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple, and refer to the method part for the relevant part.
[0111] The skilled person can further realize that the units and algorithm steps of the examples described in combination with the embodiments disclosed herein can be realized by electronic hardware, computer software or a combination of both. In order to clearly show the interchangeability of hardware and software, the components and steps of the examples are described in the above description. Whether the functions are realized by hardware or software depends on the specific application and design constraints of the technical solution. The skilled person can use different methods to realize the described functions for each specific application, but such implementation should not be considered beyond the scope of the application.
[0112] The steps of the method or algorithm described in combination with the embodiments disclosed herein can be directly implemented by hardware, a software module executed by a processor, or a combination of both. The software module can be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
[0113] Finally, it should be noted that in this document, relationship terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between the entities or operations. Moreover, the terms "include", "contain" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such process, method, article or device. Without more limitations, the element defined by the statement "including a" does not exclude the presence of other identical elements in the process, method, article or device including the element.
[0114] The technical solutions provided by the present application are described in detail above, and the principles and implementation manners of the present application are described by using specific examples. The above description of the examples is only used to help understand the method of the present application and its core idea; meanwhile, for those skilled in the art, according to the idea of the present application, the specific implementation manners and application ranges will be changed, and the above description of the content of the specification should not be understood as a limitation on the present application.
Claims
1. An AI software system defect repair method for a government affairs platform, characterized by, The method comprises the following steps: loading an eBPF probe based on a K8s cluster of a government affair platform, to obtain target data of a current platform AI software system in a running process by using the eBPF probe, and determining a defect fingerprint based on the target data; the target data comprises data in a cognitive dimension, a data dimension and a behavior dimension; the data in the cognitive dimension is uncertainty, confidence distribution and interpretability index of the current platform AI software system in reasoning; the data in the data dimension comprises input data drift, feature distribution offset and annotation noise entropy of the current platform AI software system; the data in the behavior dimension comprises API calling sequence, tensor abnormal data and running resource mutation data of the current platform AI software system; determining a target defect classifier based on a graph neural network, a teacher model, a student model, a preset distillation mechanism and a KL divergence loss function, determining a defect matrix based on the defect fingerprint and using the target defect classifier, determining a target strategy arrangement device by using reinforcement learning and a preset strategy library, and determining a target defect repair strategy based on the defect matrix and business data and using the target strategy arrangement device; the preset strategy library comprises a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy and a canary release strategy; the business data is a business index of the current platform AI software system in the government affair platform; repairing defects of the current platform AI software system by using the target defect repair strategy to obtain a repaired AI software system, verifying the repaired AI software system, and completing the defect repair operation of the platform AI software system if the verification is passed.
2. The AI software system defect fixing method of the government platform as claimed in claim 1, wherein, The method of loading an eBPF probe based on a K8s cluster of a government affair platform to obtain target data of a current platform AI software system in a running process by using the eBPF probe, and determining a defect fingerprint based on the target data comprises the following steps: deploying a corresponding sidecar container based on a container group running an AI business in a K8s cluster of a government affair platform, and loading an eBPF probe by using the sidecar container; obtaining data in a cognitive dimension, a data dimension and a behavior dimension of a current platform AI software system based on a model update event or a code merging event of the current platform AI software system and by using an eBPF probe, and constructing running data based on the data in the cognitive dimension, the data dimension and the behavior dimension; adding noise to the running data by using the sidecar container to obtain target data, encoding the target data based on a preset encoding mode to obtain a structured feature vector for mapping defect features, and determining a defect fingerprint by using the structured feature vector.
3. The AI software system defect fixing method of the government platform as claimed in claim 2, wherein, The method of determining a target defect classifier based on a graph neural network, a teacher model, a student model, a preset distillation mechanism and a KL divergence loss function comprises the following steps: determining the structured feature vector as a node, and determining a dependency relationship between data in each dimension in the running data as an edge. construct a graph neural network based on the nodes and the edges, determine a graph neural network satisfying a preset high-precision condition as a teacher model, and determine a graph neural network not satisfying the preset high-precision condition as a student model; determine an initial defect classifier by using the teacher model, the student model, a preset distillation mechanism, and a KL divergence loss function; when the current platform AI software system is updated or data distribution drifts, fine-tune the initial defect classifier by using the preset distillation mechanism, and determine a target defect classifier based on an adjustment result.
4. The AI software system defect fixing method of the government platform as claimed in claim 1, wherein, The method further includes: inputting the defect fingerprint into the target defect classifier to obtain a defect matrix of a target structure; constructing a preset strategy library based on a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy, and determining a target strategy composer by using reinforcement learning and the preset strategy library; determining a reward function based on a defect repair time length corresponding to each repair strategy in the preset strategy library and business data, and determining a target defect repair strategy by using the reward function, the defect matrix, and the target strategy composer. The method further includes: if the defect matrix indicates that the current platform AI software system has a data dimension defect, determining the data correction strategy as the target defect repair strategy; if the defect matrix indicates that the current platform AI software system has a cognitive dimension defect, determining the hyperparameter rollback strategy as the target defect repair strategy; if the defect matrix indicates that the current platform AI software system has a behavior dimension defect, determining the model hot patch strategy as the target defect repair strategy; and if the defect matrix indicates that the current platform AI software system has a target defect satisfying a preset high-severity condition, determining the canary release strategy as the target defect repair strategy. The method further includes: using the target defect repair strategy to repair defects of the current platform AI software system to obtain a repaired AI software system, verifying the repaired AI software system, and if the verification is passed, completing the defect repair operation on the platform AI software system. If the target defect repair strategy is the data correction strategy, obtaining user behavior incremental data in a preset time period, filtering the user behavior incremental data by using a sliding window technology to obtain processed incremental data, adding the processed incremental data to an input data source of the current platform AI software system to obtain a repaired AI software system, and detecting data dimension data of the repaired AI software system, if a first detection result indicates that the data dimension data in a first target time period is normal, completing the defect repair operation on the platform AI software system.
5. The AI software system defect fixing method of the government platform as claimed in claim 4, wherein, 6. The AI software system defect fixing method of the government platform as claimed in claim 1, wherein, If the target defect repair strategy is the super parameter rollback strategy, the obtained last version of the platform AI software system is determined as the current platform AI software system to obtain a repaired AI software system, the cognitive dimension data of the repaired AI software system is detected, and if the obtained second detection result represents that the cognitive dimension data in the second target time period is normal, the defect repair operation of the platform AI software system is completed. If the target defect repair strategy is the model hot patch strategy, the hot patch is loaded into the running environment of the current platform AI software system to obtain a repaired AI software system, the behavior dimension data of the repaired AI software system is detected, and if the obtained third detection result represents that the behavior dimension data in the third target time period is normal, the defect repair operation of the platform AI software system is completed. If the target defect repair strategy is the canary release strategy, a preset number of business nodes of the current platform AI software system are repaired to obtain repaired nodes, the government affairs platform and the corresponding business traffic of the preset number are introduced into the repaired nodes, and the first canary verification is performed on the repaired nodes. If the obtained first verification result represents that the business data of the current platform AI software system in the fourth target time period is normal, a new preset number is determined based on a preset addition ratio, and then the step of repairing the preset number of business nodes of the current platform AI software system is jumped to until all business traffic is introduced into all repaired nodes to obtain a repaired AI software system. The second canary verification is performed on the repaired AI software system, and if the obtained second verification result represents that the verification is passed, the defect repair operation of the platform AI software system is completed.
7. The AI software system bug fixing method of the government platform according to any one of claims 1 to 6, wherein, The verification of the repaired AI software system, if the verification is passed, the defect repair operation of the platform AI software system is completed, comprising: The verification of the repaired AI software system, if the verification is passed, the defect repair operation of the platform AI software system is completed, comprising:
8. An AI software system defect repair apparatus of an e-government platform, characterized by, The verification of the repaired AI software system, if the verification is passed, the defect repair operation of the platform AI software system is completed, comprising: including: The defect fingerprint determination module is configured to load an eBPF probe based on a K8s cluster of the government affair platform, to obtain target data of a current platform AI software system in a running process by using the eBPF probe, and to determine a defect fingerprint based on the target data; the target data includes data in a cognitive dimension, a data dimension, and a behavior dimension; the data in the cognitive dimension is uncertainty, confidence distribution, and interpretability indicators of the current platform AI software system in reasoning; the data in the data dimension includes input data drift, feature distribution offset, and annotation noise entropy of the current platform AI software system; and the data in the behavior dimension includes API calling sequence, tensor abnormal data, and running resource mutation data of the current platform AI software system. The repair strategy determination module is configured to determine a target defect classifier based on a graph neural network, a teacher model, a student model, a preset distillation mechanism, and a KL divergence loss function, to determine a defect matrix based on the defect fingerprint and by using the target defect classifier, to determine a target strategy composer by using reinforcement learning and a preset strategy library, and to determine a target defect repair strategy based on the defect matrix and business data and by using the target strategy composer. The preset strategy library includes a data correction strategy, a hyperparameter rollback strategy, a model hot patch strategy, and a canary release strategy; and the business data is a business indicator of the current platform AI software system in the government affair platform. The defect repair module is configured to perform defect repair on the current platform AI software system by using the target defect repair strategy, to obtain a repaired AI software system, to verify the repaired AI software system, and to complete the defect repair operation on the platform AI software system if the verification is passed.
9. An electronic device, comprising: The memory is configured to save a computer program. The processor is configured to execute the computer program to implement the AI software system defect repair method of the government affair platform according to any one of claims 1 to 7. The memory is configured to save a computer program.
10. A computer-readable storage medium, characterized in that, The computer program is configured to be executed by the processor to implement the AI software system defect repair method of the government affair platform according to any one of claims 1 to 7.
Citation Information
Cited By
AI-based SaaS system vulnerability automatic repair method and system
CN121579265A
AI-based saas system vulnerability automatic repair method and system
CN121579265B
