Artificial intelligence-based software development methods, devices, and electronic equipment

By constructing a common-cause failure risk graph and performance stability divergence, a layered compilation optimization scheme is generated, which solves the common-cause failure problem among microservice components, realizes an efficient and intelligent software development process, and improves the development efficiency and stability of 5G core network key business software.

CN122308798APending Publication Date: 2026-06-30WEIYANG YUNKE (BEIJING) TECHNOLOGY CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
WEIYANG YUNKE (BEIJING) TECHNOLOGY CO LTD
Filing Date
2026-05-12
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

In the 5G core network service architecture, the tight coupling and frequent iteration updates between microservice components make code changes prone to common cause failures or performance degradation. Traditional development and testing processes are unable to accurately identify high-risk areas, regression testing is costly, and there is a lack of dynamic adaptation to compilation optimization strategies, resulting in low development efficiency and difficulty in ensuring system stability.

Method used

Based on the historical runtime logs of UPF, a common cause failure risk graph is constructed among microservice components to identify conjugate risk component pairs. A performance stability divergence is constructed through a simulation sandbox to generate a layered compilation optimization scheme. Sensitivity marking and rollback mechanisms are established to optimize the compilation and deployment of microservice components.

Benefits of technology

It accurately identifies the high-risk scope of code changes, significantly narrows the scope of regression testing, reduces testing costs, improves development efficiency, and enhances the overall performance stability and resource utilization efficiency of UPF software through dynamic optimization strategies, while providing an intelligent rollback mechanism to ensure the reliability of the software development process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122308798A_ABST
    Figure CN122308798A_ABST
Patent Text Reader

Abstract

This invention relates to the field of software development technology, and more particularly to a software development method, apparatus, and electronic device based on artificial intelligence. The method includes: constructing a common-cause failure risk graph among microservice components based on UPF historical runtime logs; identifying sets of conjugate risk microservice component pairs; and constructing a performance stability divergence of the microservice components based on latency and throughput in a simulation sandbox; generating a layered compilation optimization scheme for the microservice components based on the performance stability divergence; compiling each microservice component using the layered compilation optimization scheme, and performing sensitivity marking on each microservice component, thereby verifying the layered compilation optimization scheme for each microservice component; and establishing a rollback mechanism based on the sensitivity marking results and the verification results of the layered compilation optimization scheme for each microservice component. This invention effectively improves the efficiency of user-side software development.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of software development technology, and in particular to a software development method, apparatus, and electronic device based on artificial intelligence. Background Technology

[0002] In the current 5G core network service-oriented architecture, User Plane Function (UPF) software generally adopts a microservice design to support high-concurrency, low-latency data processing requirements. However, the tight coupling and frequent iterative updates between microservice components make code changes highly susceptible to common-cause failures or performance degradation. Traditional software development and testing processes struggle to accurately identify the scope of high-risk changes, regression testing is costly, and there is a lack of dynamic adaptation capabilities to compilation optimization strategies, resulting in low development efficiency and difficulty in ensuring system stability.

[0003] Existing technologies typically rely on static rules or human experience for test coverage and performance tuning, failing to effectively utilize historical operational data and real-time simulation feedback. This makes it difficult to achieve refined evaluation and optimization of the stability, resource affinity, and performance sensitivity of microservice components when facing complex NUMA architectures and the high-performance data plane of DPDK, thus hindering the agile development and reliable deployment of critical network function software such as UPF. Summary of the Invention

[0004] The purpose of this invention is to provide a software development method, apparatus, and electronic device based on artificial intelligence to solve at least one of the problems existing in the prior art.

[0005] To achieve the above objectives, according to one aspect of this application, the present invention provides a software development method based on artificial intelligence, comprising:

[0006] Based on the historical runtime logs of UPF, a common cause failure risk graph is constructed among microservice components to identify the set of conjugate risk microservice component pairs. Based on the latency and throughput in the simulation sandbox, the performance stability divergence of microservice components is constructed.

[0007] Based on performance stability divergence, a layered compilation optimization scheme for microservice components is generated;

[0008] Each microservice component is compiled using a layered compilation optimization scheme, and each microservice component is marked with sensitivity, thereby verifying the layered compilation optimization scheme for each microservice component;

[0009] A rollback mechanism is established based on the sensitivity marking results of each microservice component and the verification results of the layered compilation optimization scheme.

[0010] Optionally, based on the historical operation logs of UPF, the signaling interaction frequency F(m,n) and the number of contention conflicts C(m,n) of each microservice component within a unit time window are counted, where F(m,n) and C(m,n) represent the signaling interaction frequency and the number of contention conflicts between the m-th microservice component and the n-th microservice component, respectively.

[0011] Based on the statistical results, the common cause failure index R(m,n) between the m-th microservice and the n-th microservice is calculated, and R(m,n) is set as α×Fn(m,n)+β×Cn(m,n);

[0012] In the formula, Fn(m,n)=F(m,n) / Fmax, Cn(m,n)=C(m,n) / Cmax, Fmax and Cmax are the historical maximum values ​​of signaling interaction frequency and cache contention conflict number of all microservice components in the UPF deployment scenario, respectively, and α and β are weight coefficients and α+β=1.

[0013] Optionally, the common cause failure risk graph is constructed by using each microservice component as a point in the common cause failure risk graph and the common cause failure index as an edge between each microservice component.

[0014] Set a threshold for common cause failure and identify high-risk areas for code changes based on the common cause failure risk map:

[0015] When R(m,n) is greater than the common cause failure determination threshold, the m-th microservice component and the n-th microservice component are determined to be in the same code change risk domain, and the m-th microservice component and the n-th microservice component are listed as a conjugate risk microservice component pair;

[0016] All conjugate risk microservice component pairs are used as the set of conjugate risk microservice component pairs.

[0017] Optionally, after the k-th uploaded code is compiled, the latency sample sequence D(i) and throughput sample sequence T(i) of each GTP-U stream generated by simulation testing in the simulation sandbox are collected within the word test period, where i is the numerical number of each GTP-U stream generated by the simulation test.

[0018] Calculate the latency variation coefficient CVD(i) and throughput variation exponent CVT(i) for each GTP-U stream, and then calculate the performance stability divergence Div(k) after the k-th code upload. Set Div(k) = (1 / N) × Σ[(CVD(i) - CVref)] 2 +(CVT(i)-Sref) 2 ];

[0019] Where N is the number of each GTP-U stream generated by simulation testing in the simulation sandbox after the k-th code upload submission and compilation, and CVref and Sref are the reference values ​​of the latency variation coefficient and throughput variation index measured under standard load for the baseline version, respectively.

[0020] When Div(k) exceeds the divergence threshold, the code uploaded in the kth upload is deemed to be risky, and the microservice component containing the code uploaded in the kth upload is marked as a risky microservice component.

[0021] Optionally, obtain the set Ar of marked risky microservice components and the corresponding performance stability divergence Div(k), and obtain the set Ap of step conjugate risky microservice component pairs;

[0022] Based on the NUMA node topology of the physical host deployed by the UPF software and the distribution of DPDK big page memory, establish an affinity mapping table Map(m) from microservice components to NUMA nodes.

[0023] Calculate the stability optimization factor θ(m) of the risk microservice component within Ar, and set θ(m) = (Da(m) / Dt) × γ × (1 + μ × Pfr(m));

[0024] In the formula, Da(m) is the sliding window average of the performance stability divergence of all uploaded code associated with the m-th microservice component, Dt is the divergence threshold, γ is the periodic jitter compensation coefficient driven by the DPDK polling mode, Pfr(m) is the number of DPDK big page faults of the m-th microservice component, and μ is the page fault penalty weight.

[0025] A hierarchical compilation optimization scheme is generated based on the stability optimization factor θ(m):

[0026] When θ(m) is not greater than 0.7, the m-th microservice component is determined to belong to the high stability zone;

[0027] When θ(m) is not greater than 1.2 and is greater than 0.7, the m-th microservice component is determined to belong to the medium stability zone;

[0028] When θ(m) is greater than 1.2, the m-th microservice component is determined to belong to the low stability zone.

[0029] Optionally, each microservice component is compiled independently using a layered compilation optimization scheme, and the generated UPF package is deployed to a simulation sandbox to execute a preset test scheme. Then, the number of NUMA remote memory accesses RA(m) and the number of local memory accesses LA(m) of each microservice component during the test period are collected. The local memory access ratio RL(m) of each microservice component is then calculated, and RL(m) is set to LA(m) / [RA(m)+LA(m)].

[0030] Optionally, a local memory access ratio tolerance threshold can be set, and the layered compilation optimization scheme for each microservice component can be verified:

[0031] When the local memory access ratio RL(m) of the m-th microservice component is less than the local memory access ratio tolerance threshold, the m-th microservice component is marked as a NUMA-sensitive component and the verification of the m-th microservice component is determined to be failed; otherwise, the verification is determined to be successful.

[0032] Optionally, a rollback monitoring window can be set, and the length of the rollback monitoring can be set to the last 5 uploaded codes;

[0033] Define the rollback trigger condition as follows:

[0034] Condition 1: The performance stability divergence of the code uploaded in the two most recent consecutive uploads is greater than the divergence threshold;

[0035] Condition 2: At least one of these two submissions must have an intersection with the set of risky microservice components and the set of conjugate risky component pairs Ap;

[0036] If the rollback trigger condition is met within the rollback monitoring window, a rollback is determined to be necessary, and the UPF package is rolled back to the UPF package where the performance stability divergence was less than the divergence threshold most recently.

[0037] According to another aspect of this application, an artificial intelligence-based software development apparatus is provided, comprising:

[0038] The risk pair identification unit is used to construct a common cause failure risk graph among microservice components based on the historical operation logs of UPF, and to identify the set of conjugate risk microservice component pairs.

[0039] A stability identification unit is used to construct the performance stability divergence of microservice components based on latency and throughput in a simulation sandbox.

[0040] The compilation optimization unit is used to generate layered compilation optimization schemes for microservice components based on performance stability divergence.

[0041] The optimization verification unit is used to compile each microservice component with a layered compilation optimization scheme, and to mark the sensitivity of each microservice component, thereby verifying the layered compilation optimization scheme of each microservice component.

[0042] The verification rollback unit is used to establish a rollback mechanism based on the sensitivity marking results of each microservice component and the verification results of the layered compilation optimization scheme.

[0043] According to another aspect of this application, an electronic device is provided, comprising:

[0044] One or more processors;

[0045] Storage device for storing one or more programs;

[0046] When the one or more programs are executed by the one or more processors, the one or more processors implement the artificial intelligence-based software development method.

[0047] Compared with existing technologies, the advantages of this invention are as follows: By constructing a common-cause failure risk graph among microservice components, the high-risk range of code changes is accurately identified, significantly narrowing the coverage of regression testing, effectively reducing testing costs and improving development efficiency. This method utilizes signaling interaction frequency and cache contention conflict data from UPF historical runtime logs to quantify the risk correlation between components, enabling testing resources to be concentrated on modules most likely to cause systemic failures, thereby enhancing reliability during software iteration.

[0048] Building upon this foundation, this solution innovatively introduces performance stability divergence as an evaluation metric. Combined with NUMA architecture and DPDK features, it generates layered compilation optimization schemes for microservice components with different risk levels. This dynamic and refined optimization strategy not only specifically addresses the performance bottlenecks of high-risk components but also ensures optimal matching between compilation optimization and underlying hardware resources through affinity mapping and sensitivity labeling, significantly improving the overall performance stability and resource utilization efficiency of the UPF software.

[0049] Finally, by establishing an intelligent rollback mechanism based on sensitivity marking and verification results, this invention provides robust security for the software development process. This mechanism can automatically monitor the performance of consecutive submissions and promptly trigger a rollback when potential systemic risks are detected, restoring the system to a known stable state. This organic combination of technologies forms an efficient, intelligent, and reliable closed-loop software development system, significantly accelerating the high-quality delivery of critical business software such as 5G core networks. Attached Figure Description

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

[0051] Figure 1 This is a flowchart illustrating the software development method based on artificial intelligence in this embodiment.

[0052] Figure 2 This is a schematic diagram of the structure of the artificial intelligence-based software development device provided in this embodiment.

[0053] Figure 3 This is a schematic diagram of the structure of the electronic device provided in this embodiment. Detailed Implementation

[0054] To more clearly illustrate the present invention, the following description, in conjunction with preferred embodiments and accompanying drawings, further explains the invention. Similar components in the drawings are indicated by the same reference numerals. Those skilled in the art should understand that the specific description below is illustrative rather than restrictive and should not be construed as limiting the scope of protection of the present invention.

[0055] It should be noted that although the terms first, second, third, etc., may be used in the embodiments of this application for description, these descriptions should not be limited to these terms. These terms are only used to distinguish the descriptions. For example, without departing from the scope of the embodiments of this application, first can also be referred to as second, and similarly, second can also be referred to as first.

[0056] The acquisition, storage, use, and processing of data in this application all comply with the relevant provisions of national laws and regulations.

[0057] Specifically, this application provides a software development method, apparatus, and electronic device based on artificial intelligence, which is applied to the iterative development scenario of user plane function (UPF) software in mobile communication core network. In this application scenario, the 5G core network adopts a service-oriented architecture, and the user plane function needs to process GTP-U tunnel data from the radio access network and perform functions such as packet detection, forwarding, billing, and QoS policy execution. At the same time, the microservice components in the software need to be updated frequently.

[0058] Before implementing the aforementioned AI-based software development method, apparatus, and electronic device, this application requires deploying a code static analysis probe and a DPDK simulation testing environment in the UPF software's CI / CD pipeline.

[0059] To apply to the above-mentioned application scenarios, this application provides a software development method based on artificial intelligence, the flowchart of which can be found in the document. Figure 1 As shown, it includes:

[0060] Step S100: Construct a common cause failure risk graph among microservice components based on the UPF historical runtime logs, and identify the set of conjugate risk microservice component pairs; Step S100 is to identify the high-risk range of code changes based on the UPF historical runtime logs when the code is submitted, so as to determine the regression test range, that is, Step S100 is a step performed before testing the uploaded code.

[0061] Specifically, the implementation process of step S100 is as follows:

[0062] Based on the historical operation logs of UPF, the signaling interaction frequency F(m,n) and the number of contention conflicts C(m,n) of each microservice component within a unit time window are statistically analyzed. F(m,n) and C(m,n) represent the signaling interaction frequency and the number of contention conflicts between the m-th microservice component and the n-th microservice component, respectively.

[0063] Based on the statistical results, the common cause failure index R(m,n) between the m-th microservice and the n-th microservice is calculated, and R(m,n) is set as α×Fn(m,n)+β×Cn(m,n);

[0064] In the formula, Fn(m,n)=F(m,n) / Fmax, Cn(m,n)=C(m,n) / Cmax, Fmax and Cmax are the historical maximum values ​​of the signaling interaction frequency and cache contention conflict number of all microservice components in the UPF deployment scenario, respectively, and α and β are both weight coefficients and α+β=1;

[0065] Each microservice component is used as a point in the common cause failure risk graph, and the common cause failure index is used as the edge between each microservice component to construct the common cause failure risk graph.

[0066] Set a threshold for common cause failure and identify high-risk areas for code changes based on the common cause failure risk map:

[0067] When R(m,n) is greater than the common cause failure determination threshold, the m-th microservice component and the n-th microservice component are determined to be in the same code change risk domain, and the m-th microservice component and the n-th microservice component are listed as a conjugate risk microservice component pair;

[0068] All conjugate risk microservice component pairs are used as the set of conjugate risk microservice component pairs.

[0069] It is understood that the "conjugate risk microservice component" mentioned in this application is interpreted as follows: when the interface signature of the m-th microservice component changes, the n-th microservice component will also experience an anomaly. In this case, joint full regression testing needs to be performed on both microservice components simultaneously. If there is a microservice component that does not form a conjugate risk microservice component pair with any other microservice component, then regression testing is only performed on that microservice component.

[0070] Preferably, the unit time window in this application is 60s, and the common cause failure determination threshold is 0.75.

[0071] Specifically, by analyzing the frequency of signaling interactions and cache contention conflicts in the historical operation logs of UPF, the common failure risk among microservices is quantified, and a risk graph is constructed. Its beneficial effect is that it can accurately identify microservice component pairs that may affect each other due to code changes, thereby narrowing the scope of regression testing from full testing to high-risk related components, improving testing efficiency and targeting, and effectively preventing systemic failures caused by implicit dependencies between components.

[0072] Please continue reading. Figure 1 As shown, the AI-based software development method further includes:

[0073] Step S200: Construct the performance stability divergence of the microservice component based on the latency and throughput in the simulation sandbox; Step S200 is the step that the CI pipeline will automatically execute during testing after the uploaded code is submitted for compilation and the overall UPF package is deployed to the simulation sandbox.

[0074] Specifically, the implementation process of step S200 is as follows:

[0075] After the k-th uploaded code is compiled, the latency sample sequence D(i) and throughput sample sequence T(i) of each GTP-U stream generated by the simulation test in the simulation sandbox are collected within the word test period, where i is the numerical number of each GTP-U stream generated by the simulation test.

[0076] Calculate the latency variation coefficient CVD(i) and throughput variation exponent CVT(i) for each GTP-U stream, and then calculate the performance stability divergence Div(k) after the k-th code upload. Set Div(k) = (1 / N) × Σ[(CVD(i) - CVref)] 2 +(CVT(i)-Sref) 2 ];

[0077] Where N is the number of each GTP-U stream generated by simulation testing in the simulation sandbox after the k-th code upload submission and compilation, and CVref and Sref are the reference values ​​of the latency variation coefficient and throughput variation index measured under standard load for the baseline version, respectively.

[0078] When Div(k) exceeds the divergence threshold, the code uploaded in the kth upload is deemed to be risky, and the microservice component containing the code uploaded in the kth upload is marked as a risky microservice component.

[0079] Specifically, the test period described in this application is 4 hours.

[0080] Specifically, a simulation sandbox is used to test the compiled code. By analyzing the latency and throughput variations of the GTP-U stream, a comprehensive performance stability divergence index is calculated. Its beneficial effect is that it provides an objective and quantitative method for code quality assessment, automatically and promptly identifying performance degradation or instability issues introduced in code submissions, and marking relevant components as risky components, providing accurate data for subsequent differentiated optimization.

[0081] Please continue reading. Figure 1 As shown, the AI-based software development method further includes:

[0082] Step S300: Based on the performance stability divergence, generate a layered compilation optimization scheme for microservice components.

[0083] Specifically, the implementation process of step S300 is as follows:

[0084] Obtain the set Ar(k) of marked risky microservice components and the corresponding performance stability divergence Div(k), and obtain the set Ap of step conjugate risky microservice component pairs;

[0085] Based on the NUMA node topology of the physical host deployed by the UPF software and the distribution of DPDK big page memory, establish an affinity mapping table Map(m) from microservice components to NUMA nodes.

[0086] Calculate the stability optimization factor θ(m) of the risk microservice component within Ar, and set θ(m) = (Da(m) / Dt) × γ × (1 + μ × Pfr(m));

[0087] In the formula, Da(m) is the sliding window average of the performance stability divergence of all uploaded code associated with the m-th microservice component, Dt is the divergence threshold, γ is the periodic jitter compensation coefficient driven by the DPDK polling mode, Pfr(m) is the number of DPDK big page faults of the m-th microservice component, and μ is the page fault penalty weight.

[0088] A hierarchical compilation optimization scheme is generated based on the stability optimization factor θ(m):

[0089] When θ(m) is not greater than 0.7, the m-th microservice component is determined to belong to the high stability zone;

[0090] When θ(m) is not greater than 1.2 and is greater than 0.7, the m-th microservice component is determined to belong to the medium stability zone;

[0091] When θ(m) is greater than 1.2, the m-th microservice component is determined to belong to the low stability zone.

[0092] Specifically, the compilation optimization strategy for the high stability region is as follows:

[0093] Enable GCC / Clang's -O3 optimization, loop unrolling, and vectorization, and bind DPDK's independent physical CPU cores. The core binding granularity is dynamically allocated based on the average number of instructions processed per packet for the microservice component: if IPC is greater than or equal to 0.8, allocate an exclusive physical core to the microservice component; otherwise, allocate a shared core.

[0094] The compilation optimization strategy for the stability region is as follows:

[0095] Enable GCC / Clang's -O2 optimization and vectorization, adopt DPDK's latency-throughput dynamic adjustment algorithm, and set the DPDK rx / tx descriptor ring size to 0.75 times the default value, which is 512 descriptors in this application;

[0096] The compilation optimization strategy for the low-stability region is as follows:

[0097] Enable GCC / Clang's -O1 optimization, disable loop unrolling and vectorization, bind the microservice component's DPDK receive queue and send queue to the same physical core of the same NUMA node, and set the GTP-U tunnel decapsulation batch size to 4.

[0098] Specifically, Pfr(m) mentioned in this application represents the number of DPDK big page faults that occur every 10^6 data packets processed when the microservice component is running in the simulation sandbox. The page fault penalty weight is 0.25, and the periodic jitter compensation coefficient driven by the DPDK polling mode is 0.9.

[0099] Specifically, based on performance stability dispersion, NUMA topology, and DPDK memory characteristics, customized compilation optimization strategies of high, medium, and low levels are generated for microservice components with different risk levels. The beneficial effect is that it achieves a fine-grained match between resource allocation and performance requirements, applying aggressive optimization to high-stability components to extract maximum performance, and adopting conservative strategies for low-stability components to ensure reliability, thereby improving the overall performance ceiling and operational stability of the UPF software.

[0100] Please continue reading. Figure 1 As shown, the AI-based software development method further includes:

[0101] Step S400: Compile each microservice component using a layered compilation optimization scheme, and mark the sensitivity of each microservice component, thereby verifying the layered compilation optimization scheme of each microservice component.

[0102] Specifically, the implementation process of step S400 is as follows:

[0103] Each microservice component is compiled independently using a layered compilation optimization scheme. The generated UPF packages are then deployed to a simulation sandbox, and a preset test plan is executed. The NUMA remote memory access count RA(m) and local memory access count LA(m) of each microservice component are collected during the test period. The local memory access ratio RL(m) of each microservice component is then calculated, and RL(m) is set to RL(m) = LA(m) / [RA(m) + LA(m)].

[0104] Set a local memory access ratio tolerance threshold and verify the layered compilation optimization scheme for each microservice component:

[0105] When the local memory access ratio RL(m) of the m-th microservice component is less than the local memory access ratio tolerance threshold, the m-th microservice component is marked as a NUMA-sensitive component and the verification of the m-th microservice component is determined to be failed; otherwise, the verification is determined to be successful.

[0106] Specifically, the preset test scheme described in this application is a QoS flow test, which includes a mixed traffic consisting of a voice stream with QFI=1, a signaling stream with QFI=5, and a video stream with QFI=9, with a test time of 600 seconds.

[0107] Preferably, the local memory access ratio tolerance threshold mentioned in this application is 0.85.

[0108] Specifically, the optimized software package is redeployed to a simulation sandbox, and the optimization effect is verified by monitoring the NUMA local memory access ratio. Components sensitive to the NUMA architecture are also identified. The beneficial effect is that it establishes a closed-loop verification mechanism, ensuring the effectiveness of the compilation optimization strategy in a real hardware environment and preventing performance degradation due to improper optimization. At the same time, sensitivity labeling provides crucial guidance for subsequent deployment scheduling.

[0109] Please continue reading. Figure 1 As shown, the AI-based software development method further includes:

[0110] Step S500: Establish a rollback mechanism based on the sensitivity marking results of each microservice component and the verification results of the layered compilation optimization scheme.

[0111] Specifically, the implementation process of step S500 is as follows:

[0112] Set up a rollback monitoring window and limit the rollback monitoring period to the last 5 code uploads;

[0113] Define the rollback trigger condition as follows:

[0114] Condition 1: The performance stability divergence of the code uploaded in the two most recent consecutive uploads is greater than the divergence threshold;

[0115] Condition 2: At least one of these two submissions must have an intersection with the set of risky microservice components and the set of conjugate risky component pairs Ap;

[0116] If the rollback trigger condition is met within the rollback monitoring window, a rollback is determined to be necessary, and the UPF package is rolled back to the UPF package where the performance stability divergence was less than the divergence threshold most recently.

[0117] Specifically, the divergence threshold value described in this application is 0.08.

[0118] Specifically, by combining historical trends in performance stability divergence with conjugate risk relationships, a dual trigger condition is set to determine whether to perform automatic rollback. Its beneficial effect is the construction of a robust security defense. When consecutive code commits show a clear trend of performance degradation and affect critical risk components, the system can automatically roll back to a known stable version, maximizing the reliability and service continuity of the production environment and reducing the delays and risks of human intervention.

[0119] Please see Figure 2 As shown, it is a schematic diagram of the structure of the artificial intelligence-based software development device provided in this application, including:

[0120] The risk pair identification unit is used to construct a common cause failure risk graph among microservice components based on the historical operation logs of UPF, and to identify the set of conjugate risk microservice component pairs.

[0121] A stability identification unit is used to construct the performance stability divergence of microservice components based on latency and throughput in a simulation sandbox.

[0122] The compilation optimization unit is used to generate layered compilation optimization schemes for microservice components based on performance stability divergence.

[0123] The optimization verification unit is used to compile each microservice component with a layered compilation optimization scheme, and to mark the sensitivity of each microservice component, thereby verifying the layered compilation optimization scheme of each microservice component.

[0124] The verification rollback unit is used to establish a rollback mechanism based on the sensitivity marking results of each microservice component and the verification results of the layered compilation optimization scheme.

[0125] The artificial intelligence-based software development apparatus provided in this application embodiment can execute the artificial intelligence-based software development method provided in any embodiment of this application, and has the corresponding functional modules and beneficial effects of executing the method.

[0126] From a hardware perspective, to implement the aforementioned AI-based software development method in a computer, this application also provides an electronic device; please refer to [link to relevant documentation]. Figure 3 As shown, it is a schematic diagram of the structure of the electronic device described in this application, including:

[0127] The system comprises a processor 1, a memory 2, a communication interface 3, and a bus 4; wherein the processor 1 and the memory 2, and the memory 2 and the communication interface 3, transmit data via the bus 4; the processor is used to process data in the memory and generate commands, the memory is used to store data, the communication interface is used to receive and send data, and the bus is used to realize data transmission between the processor, the memory, and the communication interface.

[0128] In this embodiment, the artificial intelligence-based software development method can be implemented as a runnable computer program. When the computer program is loaded into the processor, or when it is loaded into the memory and processed by the processor via the bus, one or more steps of the artificial intelligence-based software development can be executed.

[0129] This embodiment also provides a computer-readable storage medium for storing the computer-executable instructions. The computer-readable storage medium is a tangible physical storage medium that can store the computer program and various types of data used in the program. The physical storage medium includes, but is not limited to, existing physical storage media or combinations thereof, such as random access memory, read-only memory, optical disk, and hard disk.

[0130] The technical solution of the present invention has been described above with reference to the preferred embodiments shown in the accompanying drawings. However, it will be readily understood by those skilled in the art that the scope of protection of the present invention is obviously not limited to these specific embodiments. Without departing from the principles of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will all fall within the scope of protection of the present invention.

Claims

1. A software development method based on artificial intelligence, characterized in that, include: Based on the historical runtime logs of UPF, a common cause failure risk graph is constructed among microservice components to identify the set of conjugate risk microservice component pairs. Based on the latency and throughput in the simulation sandbox, the performance stability divergence of microservice components is constructed. Based on performance stability divergence, a layered compilation optimization scheme for microservice components is generated; Each microservice component is compiled using a layered compilation optimization scheme, and each microservice component is marked with sensitivity, thereby verifying the layered compilation optimization scheme for each microservice component; A rollback mechanism is established based on the sensitivity marking results of each microservice component and the verification results of the layered compilation optimization scheme.

2. The software development method based on artificial intelligence according to claim 1, characterized in that, Based on the historical operation logs of UPF, the signaling interaction frequency F(m,n) and the number of contention conflicts C(m,n) of each microservice component within a unit time window are statistically analyzed. F(m,n) and C(m,n) represent the signaling interaction frequency and the number of contention conflicts between the m-th microservice component and the n-th microservice component, respectively. Based on the statistical results, the common cause failure index R(m,n) between the m-th microservice and the n-th microservice is calculated, and R(m,n) is set as α×Fn(m,n)+β×Cn(m,n); In the formula, Fn(m,n)=F(m,n) / Fmax, Cn(m,n)=C(m,n) / Cmax, Fmax and Cmax are the historical maximum values ​​of signaling interaction frequency and cache contention conflict number of all microservice components in the UPF deployment scenario, respectively, and α and β are weight coefficients and α+β=1.

3. The software development method based on artificial intelligence according to claim 2, characterized in that, Each microservice component is used as a point in the common cause failure risk graph, and the common cause failure index is used as the edge between each microservice component to construct the common cause failure risk graph. Set a threshold for common cause failure and identify high-risk areas for code changes based on the common cause failure risk map: When R(m,n) is greater than the common cause failure determination threshold, the m-th microservice component and the n-th microservice component are determined to be in the same code change risk domain, and the m-th microservice component and the n-th microservice component are listed as a conjugate risk microservice component pair; All conjugate risk microservice component pairs are used as the set of conjugate risk microservice component pairs.

4. The software development method based on artificial intelligence according to claim 3, characterized in that, After the k-th uploaded code is compiled, the latency sample sequence D(i) and throughput sample sequence T(i) of each GTP-U stream generated by the simulation test in the simulation sandbox are collected within the word test period, where i is the numerical number of each GTP-U stream generated by the simulation test. Calculate the latency variation coefficient CVD(i) and throughput variation exponent CVT(i) for each GTP-U stream, and then calculate the performance stability divergence Div(k) after the k-th code upload. Set Div(k) = (1 / N) × Σ[(CVD(i) - CVref)] 2 +(CVT(i)-Sref) 2 ]; Where N is the number of each GTP-U stream generated by simulation testing in the simulation sandbox after the k-th code upload submission and compilation, and CVref and Sref are the reference values ​​of the latency variation coefficient and throughput variation index measured under standard load for the baseline version, respectively. When Div(k) exceeds the divergence threshold, the code uploaded in the kth upload is deemed to be risky, and the microservice component containing the code uploaded in the kth upload is marked as a risky microservice component.

5. The software development method based on artificial intelligence according to claim 4, characterized in that, Obtain the set Ar of marked risky microservice components and the corresponding performance stability divergence Div(k), and obtain the set Ap of step conjugate risky microservice component pairs; Based on the NUMA node topology of the physical host deployed by the UPF software and the distribution of DPDK big page memory, establish an affinity mapping table Map(m) from microservice components to NUMA nodes. Calculate the stability optimization factor θ(m) of the risk microservice component within Ar, and set θ(m) = (Da(m) / Dt) × γ × (1 + μ × Pfr(m)); In the formula, Da(m) is the sliding window average of the performance stability divergence of all uploaded code associated with the m-th microservice component, Dt is the divergence threshold, γ is the periodic jitter compensation coefficient driven by the DPDK polling mode, Pfr(m) is the number of DPDK big page faults of the m-th microservice component, and μ is the page fault penalty weight. A hierarchical compilation optimization scheme is generated based on the stability optimization factor θ(m): When θ(m) is not greater than 0.7, the m-th microservice component is determined to belong to the high stability zone; When θ(m) is not greater than 1.2 and is greater than 0.7, the m-th microservice component is determined to belong to the medium stability zone; When θ(m) is greater than 1.2, the m-th microservice component is determined to belong to the low stability zone.

6. The software development method based on artificial intelligence according to claim 5, characterized in that, Each microservice component is compiled independently using a layered compilation optimization scheme. The generated UPF package is then deployed to a simulation sandbox and a preset test scheme is executed. The number of NUMA remote memory accesses RA(m) and the number of local memory accesses LA(m) for each microservice component during the test period are collected. The local memory access ratio RL(m) of each microservice component is then calculated, and RL(m) is set to RL(m) = LA(m) / [RA(m) + LA(m)].

7. The software development method based on artificial intelligence according to claim 6, characterized in that, Set a local memory access ratio tolerance threshold and verify the layered compilation optimization scheme for each microservice component: When the local memory access ratio RL(m) of the m-th microservice component is less than the local memory access ratio tolerance threshold, the m-th microservice component is marked as a NUMA-sensitive component, and the verification of the m-th microservice component is determined to be failed. Conversely, if the result is not found, the verification is considered successful.

8. The software development method based on artificial intelligence according to claim 7, characterized in that, Set up a rollback monitoring window and limit the rollback monitoring period to the last 5 code uploads; Define the rollback trigger condition as follows: Condition 1: The performance stability divergence of the code uploaded in the two most recent consecutive uploads is greater than the divergence threshold; Condition 2: At least one of these two submissions must have an intersection with the set of risky microservice components and the set of conjugate risky component pairs Ap; If the rollback trigger condition is met within the rollback monitoring window, a rollback is determined to be necessary, and the UPF package is rolled back to the UPF package where the performance stability divergence was less than the divergence threshold most recently.

9. An artificial intelligence-based software development apparatus, applied to the artificial intelligence-based software development method as described in any one of claims 1-8, characterized in that, include: The risk pair identification unit is used to construct a common cause failure risk graph among microservice components based on the historical operation logs of UPF, and to identify the set of conjugate risk microservice component pairs. A stability identification unit is used to construct the performance stability divergence of microservice components based on latency and throughput in a simulation sandbox. The compilation optimization unit is used to generate layered compilation optimization schemes for microservice components based on performance stability divergence. The optimization verification unit is used to compile each microservice component with a layered compilation optimization scheme, and to mark the sensitivity of each microservice component, thereby verifying the layered compilation optimization scheme of each microservice component. The verification rollback unit is used to establish a rollback mechanism based on the sensitivity marking results of each microservice component and the verification results of the layered compilation optimization scheme.

10. An electronic device, characterized in that, The electronic device includes: One or more processors; Storage device for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the artificial intelligence-based software development method according to any one of claims 1-8.