A software development intelligent assistance method and system based on big data analysis
By constructing an improved gMLP network and SMT solver, the problem of lack of context understanding in traditional software development aids is solved, enabling efficient candidate patch generation and conflict resolution, and improving the automation and quality of software development.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SHAANXI YICHENG FANGLUE INFORMATION TECHNOLOGY CO LTD
- Filing Date
- 2026-05-07
- Publication Date
- 2026-06-05
AI Technical Summary
Traditional software development assistance technologies struggle to simultaneously utilize requirements, interfaces, code, testing, and runtime information to generate unified analysis results. They lack contextual semantic understanding, which limits the accuracy and stability of recommendation results. Furthermore, the lack of conflict feedback loops between candidate patches and constraint solutions leads to numerous solution iterations and overall low efficiency.
By collecting big data from the entire software development process, an improved gMLP network is constructed for embedded encoding and context feature aggregation to generate a set of candidate patch combinations. Combined with an SMT solver, combinatorial satisfiability is solved, function call relationships, variable dependencies, and anomaly propagation relationships are identified, and conflict feedback reconstruction and satisfiability verification of candidate patches are performed.
It enables automatic analysis and recommendation of complex development tasks, improves the accuracy of patch generation and the reliability of combined verification, reduces the cost of manual modification, and enhances development efficiency and software delivery quality.
Smart Images

Figure CN122152355A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of big data analytics, and in particular to an intelligent auxiliary method and system for software development based on big data analytics. Background Technology
[0002] As software systems continue to expand, the amount of data, including requirement documents, interface documents, code repositories, defect tickets, test reports, and runtime logs, is growing rapidly. The software development process is now characterized by high-frequency iteration, multi-person collaboration, and continuous delivery. Traditional development support technologies typically provide support for defect localization, code recommendation, and patch generation through static code scanning, rule matching, keyword retrieval, or historical commit analysis, thus improving development efficiency to some extent. However, due to the dispersed sources, significant structural differences, and complex relationships of development data, traditional methods often process only a single data source. This makes it difficult to simultaneously utilize requirement, interface, code, test, and runtime information to form a unified analysis result. Furthermore, in complex scenarios such as cross-file calls, variable dependencies, exception propagation, and resource release, traditional methods lack sufficient understanding of contextual semantics, limiting the accuracy and stability of recommendation results.
[0003] Existing solutions extract code features using machine learning models and combine them with constraint solver techniques to verify patch feasibility. The typical approach involves first vectorizing code snippets, commit records, or defect samples, then generating candidate patches, and finally using a constraint solver to determine whether the patch combination meets requirements for interface consistency, variable range, path conditions, and exception handling. While this approach offers some improvement over traditional rule-based methods, most models only process code text or local structural information, lacking the ability to jointly model data from the entire process, including requirements, tests, and runtime logs. Furthermore, there is a lack of conflict feedback loops between candidate patches and constraint solvers, often requiring re-enumeration of patches when unsatisfactory results occur, resulting in numerous solver iterations and overall efficiency that needs improvement.
[0004] Therefore, how to provide an intelligent auxiliary method and system for software development based on big data analysis is a problem that urgently needs to be solved by those skilled in the art. Summary of the Invention
[0005] One objective of this invention is to propose an intelligent software development assistance method and system based on big data analysis. This invention fully utilizes requirement document data, interface document data, historical code repository data, code commit log data, defect ticket data, test case data, test execution report data, runtime exception log data, and developer operation record data. It details the processing flow for intelligent software development assistance through multi-source development data association modeling, context feature learning, candidate patch generation, constraint consistency verification, conflict feedback refactoring, and satisfactory patch selection. This enables automatic analysis, verification, and recommendation of code modification schemes in complex development tasks. Compared to traditional methods relying on manual investigation or single-rule matching, this invention has advantages such as strong context understanding, high patch generation accuracy, high reliability of combined verification, high conflict repair efficiency, and fast development iteration speed. It can reduce manual modification costs and improve software delivery quality and continuous development efficiency.
[0006] According to an embodiment of the present invention, a software development intelligent assistance method based on big data analysis includes: Collect big data from the entire software development process, perform preprocessing on the big data, generate standardized development datasets, and construct a software development context association structure; An improved gMLP network is constructed based on a standardized development dataset. Embedding encoding, gated spatial projection, cross-channel feature mixing, and contextual feature aggregation are performed on the standardized development dataset to generate target development contextual features. Based on the target development context features and software development context association structure, the target path object is determined, a path segment-level candidate patch unit set is generated, and a patch constraint label is bound to each candidate patch unit to generate a candidate patch combination set. Based on the candidate patch combination set, a formal constraint object is extracted for each candidate patch combination and converted into an SMT constraint set. The combination satisfiability is solved by the SMT solver. If it is satisfiable, it is added to the satisfiable patch combination set. If it is not satisfiable, the unsatisfiable core is resolved to generate a conflict set including the conflict patch unit set. Based on the conflict set, the code modification action type is determined. Embedding encoding is performed on the code modification action type and the conflict patch unit set respectively. Gated fusion is then performed in combination with the target development context features to generate refactoring patch units and an updated candidate patch combination set. The combinatorial satisfiability solution is re-executed on the updated candidate patch combination set. Satisfiable patch combinations are merged into the satisfiable patch combination set to determine the target satisfiable patch combination and generate the final development assistance result.
[0007] Optionally, the big data of the entire software development process specifically includes requirement document data, interface document data, historical code repository data, code commit log data, defect ticket data, test case data, test execution report data, runtime exception log data, and developer operation record data.
[0008] Optionally, the construction of the software development context association structure includes: Perform text cleaning, field splitting, format standardization, and invalid character removal on requirement document data, interface document data, defect work order data, test execution report data, and runtime exception log data; Perform version number extraction, branch identifier extraction, code file path normalization, function identifier binding, and commit timestamp unification on historical code repository data and code commit log data; Perform test case number binding, test object function binding, test input / output field normalization, and test coverage relationship annotation on test case data; Perform operation type identification, operation object identification binding, and operation sequence sorting on the developer's operation log data; Based on the requirement number, interface number, defect number, test case number, code file path, function identifier, and submission version number, cross-source association matching is performed on the processed data to generate a standardized development dataset; Extract requirement number, interface number, code file path, function identifier, variable identifier, test case number, defect number, exception number, and development operation identifier from the standardized development dataset to generate corresponding nodes; Based on requirement reference relationships, interface call relationships, file inclusion relationships, function call relationships, variable dependency relationships, test coverage relationships, defect association relationships, exception backtracking relationships, and development operation sequence relationships, establish related edges to generate a software development context association structure.
[0009] Optionally, the generated target development context features include: An improved gMLP network is constructed, comprising a dual-state input layer, a pyramid bottleneck coding layer, a dual-state gated mapping layer, an adaptive channel transformation layer, and a gradient feedback output layer; The standardized development dataset is input into the dual-state input layer to extract symbolic semantic feature sequences and numerical statistical feature sequences. Symbolic embedding encoding and numerical projection encoding are performed respectively, and then concatenated to generate a dual-state input feature sequence. The dual-state input feature sequence is input into the pyramid bottleneck coding layer, and is hierarchically grouped into function-level, file-level and repository-level feature groups according to function identifier, code file path and code repository version identifier. Satisfaction constraint coding is then performed on each group to generate corresponding bottleneck features. Adjust the file-level gating threshold based on the warehouse-level bottleneck features, adjust the function-level gating threshold based on the file-level bottleneck features, and write back and fuse to generate multi-scale satisfiability coding features. The dual-state gated mapping layer generates symbolic gate weights and numerical gate weights based on symbolic embedding results and numerical projection results, performs weighted modulation on the symbolic embedding results and numerical projection results, and fuses them with multi-scale satisfiability coding features to generate gated mapping features; The gated mapping features are input into the adaptive channel transformation layer to perform channel transformation and generate channel projection results. The location association matrix is established based on the software development context association structure and context aggregation is performed to generate context aggregation features. The context aggregation features are input into the gradient feedback output layer. An interpretable gradient gate is introduced, and feedback gating weights are generated based on the gradient contribution value. Feedback adjustment is then performed to generate target development context features. The improved gMLP network was trained by using the development context feature prediction error, patch combination satisfiability classification error, and gradient feedback consistency error as joint optimization objectives to optimize the parameters of each layer until the joint loss difference of 5 consecutive training rounds was less than the convergence threshold.
[0010] Optionally, the generation of the candidate patch combination set includes: Based on the target development context features and the software development context association structure, the requirement nodes, interface nodes, code file nodes, function nodes, variable nodes, test case nodes, defect nodes, and runtime exception nodes corresponding to the current development task are extracted. The target path object is determined based on the requirement reference relationship, interface call relationship, function call relationship, variable dependency relationship, test coverage relationship, defect association relationship, and exception backtracking relationship between nodes. Based on the target path object, target function features, interface call chain features, branch path features and exception handling path features are extracted from the target development context features. Then, a set of path fragment-level candidate patch units is generated according to the interface call position, variable assignment position, branch condition position, null value judgment position, array access position, exception capture position and resource release position. Each path segment-level candidate patch unit is bound with a patch constraint label, and the path segment-level candidate patch units are combined to generate a candidate patch combination set based on the correspondence between patch constraint labels within the same target path object.
[0011] Optionally, generating a conflict set including a set of conflict patch units includes: Based on the candidate patch combination set, each candidate patch combination is read and the interface, variable, path, object, exception and resource information is extracted to generate a formal constraint object, construct a constraint association graph and perform neural-guided conflict prediction to obtain the conflict probability value. When the conflict probability value is greater than the threshold, a high conflict label result is generated; otherwise, a unsolved label result is generated. Based on the formal constraint objects corresponding to the marked results to be solved, the interface, variable, path, object, exception and resource information are converted into interface constraints, type range constraints, path constraints, null boundary constraints, exception constraints and release constraints, respectively, and combined to generate the SMT constraint set; Based on the SMT constraint set, logical relaxation calculation is performed on Boolean constraints, continuous gradient approximation calculation is performed on numerical constraints, candidate solution vectors are generated, and an initial search space and initial variable assignment state are established. Based on the initial search space, initial variable assignment state, and SMT constraint set, the target search strategy is scheduled, the variable branching order, conflict backtracking order, and clause learning intensity are adjusted, and the results are input into the SMT solver to obtain the combinatorial satisfiability solution. When the result is satisfiable, the corresponding candidate patch combination is added to the set of satisfiable patch combinations. Based on the high-conflict marking results or unsatisfiable candidate patch combinations, the unsatisfiable core is parsed, and conflict constraints, conflict objects, and conflict patch units are extracted to generate a conflict set.
[0012] Optionally, generating the updated candidate patch combination set includes: Based on the conflict set, and according to the interface constraints, type range constraints, path constraints, null value boundary constraints, exception constraints, and release constraints corresponding to the conflict constraints, determine the interface adaptation actions, variable boundary adjustment actions, path condition correction actions, null value protection actions, exception handling completion actions, and resource release correction actions, and generate code modification action types. Based on the code modification action type and conflict patch unit set, action embedding encoding and patch unit embedding encoding are performed respectively to generate action embedding features and conflict patch embedding features. Gated fusion is then performed in combination with target development context features to generate patch refactoring features. Based on the patch reconstruction features, reconstructed patch units are generated and the corresponding conflicting patch units in the candidate patch combination set are replaced. Candidate patch units that do not hit the conflict set are retained, and an updated candidate patch combination set is generated.
[0013] Optionally, generating the final development assistance result includes: Based on the updated candidate patch combination set, extract the interface constraints, type range constraints, path constraints, null boundary constraints, exception constraints, and release constraints corresponding to each updated candidate patch combination, regenerate the SMT constraint set, and perform combinatorial satisfiability solving through the SMT solver to obtain the updated combinatorial satisfiability solution results; Based on the updated combinatorial satisfiability solution results, updated candidate patch combinations that are satisfiable are merged into the set of satisfiable patch combinations, and updated candidate patch combinations that are unsatisfiable are filtered out to generate the final set of satisfiable patch combinations. Based on the final set of satisfyable patch combinations, target satisfyable patch combinations are filtered in ascending order of the number of patch units, the number of functions involved, the number of interface adjustments, and the number of exception handling changes, generating the final development assistance result.
[0014] According to an embodiment of the present invention, a software development intelligent auxiliary system based on big data analysis includes the following modules: The data construction module is used to collect big data from the entire software development process and build a software development context association structure. The feature generation module is used to build an improved gMLP network based on a standardized development dataset and generate target development context features. The patch combination module is used to determine the target path object based on the characteristics of the target development context and generate a set of candidate patch combinations. The consistency verification module is used to extract the SMT constraint set based on candidate patch combinations, perform combination satisfiability solution, and generate a set of satisfiable patch combinations and a conflict set. The conflict refactoring module is used to determine the type of code modification action based on the conflict set and generate an updated set of candidate patch combinations. The results generation module is used to re-execute the combinatorial satisfiability solution and generate the final development aid results.
[0015] The beneficial effects of this invention are: This invention proposes an intelligent software development assistance method and system based on big data analytics. By uniformly collecting, cleaning, associating, and modeling requirement document data, interface document data, historical code repository data, code commit log data, defect ticket data, test case data, test execution report data, runtime exception log data, and developer operation record data, it can form a full-process development data view covering the requirements, implementation, testing, and operation phases, building upon traditional methods that rely solely on code text analysis. This improves the completeness of development task understanding and the accuracy of context recognition. By constructing an improved gMLP network to perform joint feature extraction and context aggregation on multi-source heterogeneous development data, it can effectively identify function call relationships, variable dependencies, interface constraint relationships, and exception propagation relationships, improving the accuracy of candidate patch location and the relevance of modification suggestions.
[0016] This invention further integrates candidate patch combinations with formal constraint solving. By uniformly verifying constraints such as interface consistency, variable range, path conditions, null boundaries, exception handling, and resource release, it can identify potential conflicts and unsatisfiable combinations before patch implementation, reducing manual debugging and rework costs. For candidate combinations that fail to solve, this invention uses conflict sets to drive patch reconstruction and combination updates, forming a closed-loop processing flow of patch generation, constraint verification, and conflict correction. This significantly reduces the number of invalid searches and improves the efficiency of outputting satisfactory patches. This invention can automatically generate target patch solutions that meet constraints and have low modification costs, offering advantages such as high development efficiency, stable code quality, short delivery cycle, and applicability to complex software engineering scenarios. Attached Figure Description
[0017] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings: Figure 1 This is a flowchart of an intelligent software development assistance method based on big data analysis proposed in this invention; Figure 2 This is a schematic diagram of the structure of an improved gMLP network for a software development intelligent assistance method based on big data analysis proposed in this invention. Figure 3 This is a schematic diagram of the structure of an intelligent auxiliary system for software development based on big data analysis proposed in this invention. Detailed Implementation
[0018] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.
[0019] refer to Figure 1 and Figure 2 A software development intelligent assistance method and system based on big data analysis, comprising: Collect big data from the entire software development process, perform preprocessing on the big data, generate standardized development datasets, and construct a software development context association structure; An improved gMLP network is constructed based on a standardized development dataset. Embedding encoding, gated spatial projection, cross-channel feature mixing, and contextual feature aggregation are performed on the standardized development dataset to generate target development contextual features. Based on the target development context features and software development context association structure, the target path object is determined, a path segment-level candidate patch unit set is generated, and a patch constraint label is bound to each candidate patch unit to generate a candidate patch combination set. Based on the candidate patch combination set, a formal constraint object is extracted for each candidate patch combination and converted into an SMT constraint set. The combination satisfiability is solved by the SMT solver. If it is satisfiable, it is added to the satisfiable patch combination set. If it is not satisfiable, the unsatisfiable core is resolved to generate a conflict set including the conflict patch unit set. Based on the conflict set, the code modification action type is determined. Embedding encoding is performed on the code modification action type and the conflict patch unit set respectively. Gated fusion is then performed in combination with the target development context features to generate refactoring patch units and an updated candidate patch combination set. The combinatorial satisfiability solution is re-executed on the updated candidate patch combination set. Satisfiable patch combinations are merged into the satisfiable patch combination set to determine the target satisfiable patch combination and generate the final development assistance result.
[0020] In this embodiment, the big data of the entire software development process specifically includes requirement document data, interface document data, historical code repository data, code submission log data, defect ticket data, test case data, test execution report data, runtime exception log data, and developer operation record data.
[0021] In this embodiment, constructing the software development context association structure includes: Perform text cleaning, field splitting, format standardization, and invalid character removal on requirement document data, interface document data, defect work order data, test execution report data, and runtime exception log data; Perform version number extraction, branch identifier extraction, code file path normalization, function identifier binding, and commit timestamp unification on historical code repository data and code commit log data; Perform test case number binding, test object function binding, test input / output field normalization, and test coverage relationship annotation on test case data; Perform operation type identification, operation object identification binding, and operation sequence sorting on the developer's operation log data; Based on requirement number, interface number, defect number, test case number, code file path, function identifier, and commit version number, cross-source association matching is performed on various types of processed data to generate a standardized development dataset, in which: The execution of cross-source association matching is as follows: The code is processed as follows: First, the requirement number in the requirement document data is read as the primary key; second, the interface number in the interface document data is read, and the corresponding requirement reference record is retrieved from the requirement document data and written as the requirement number; third, the defect number in the defect ticket data is read, and the commit record with the same defect number is retrieved from the code commit log data and written as the commit version number; fourth, the test case number in the test case data is read, and the execution record with the same test case number is retrieved from the test execution report data and written as the execution result value and execution timestamp; fifth, the code file path and function identifier in the historical code repository data are read, and the modification record with the same path and function identifier is retrieved from the code commit log data and written as the commit version number. When any two of the following data items—requirement number, interface number, defect number, test case number, code file path, function identifier, and commit version number—match in different data tables, the corresponding records are grouped into the same association group. Each association group is sorted in ascending order by timestamp and concatenated according to a fixed field order to generate a standardized development dataset. Extract requirement number, interface number, code file path, function identifier, variable identifier, test case number, defect number, exception number, and development operation identifier from the standardized development dataset to generate corresponding nodes; Based on requirement reference relationships, interface call relationships, file inclusion relationships, function call relationships, variable dependency relationships, test coverage relationships, defect association relationships, exception backtracking relationships, and development operation sequence relationships, establish related edges to generate a software development context association structure.
[0022] In this embodiment, the generation of target development context features includes: An improved gMLP network is constructed, comprising a dual-state input layer, a pyramid bottleneck coding layer, a dual-state gated mapping layer, an adaptive channel transform layer, and a gradient feedback output layer, wherein: The improved gMLP network is constructed as follows: Based on the traditional gMLP network's input embedding layer, gMLP encoding layer, spatial gating unit, channel projection layer, and output mapping layer, this paper proposes an improved gMLP network. First, the input data is divided into two parallel inputs: symbolic semantic data and numerical statistical data. Second, the single-layer encoding is modified to sequentially encode based on function identifier, code file path, and code repository version identifier, resulting in a pyramid bottleneck encoding layer. Third, gating weights are calculated based on both symbolic embedding and numerical projection results, leading to a dual-state gating mapping layer. Fourth, the association strength value corresponding to the software development context association structure is written into the channel projection parameters, resulting in an adaptive channel transformation layer. Fifth, the gradient contribution value of the previous layer's features is normalized and used as feedback gating weights, applied to the previous layer's features, and then re-output, resulting in a gradient feedback output layer. This completes the improved gMLP network. The dual-state input layer includes: Symbol input buffer: Stores symbol tags extracted from requirements documents, interface documents, defect tickets, test reports, and exception logs; Numeric input buffer: Stores numerical features extracted from historical code repositories, commit logs, and operation records; Symbol embedding mapper: maps symbolic tokens to 128-dimensional dense vectors; Numerical projection mapper: linearly projects numerical features into a 128-dimensional vector; Feature concatenator: concatenates the sign vector and the numerical vector in the same position order along the feature dimension to obtain a 256-dimensional input vector; The standardized development dataset is input into the dual-state input layer to extract symbolic semantic feature sequences and numerical statistical feature sequences. Symbolic embedding encoding and numerical projection encoding are performed respectively, and then concatenated to generate the dual-state input feature sequence, where: Extracting symbolic semantic feature sequences and numerical statistical feature sequences, specifically: Read each row of records in the standardized development dataset in ascending order of timestamp, extract the requirement number, requirement status field, interface number, interface name encoding value, defect number, defect type encoding value, test result encoding value, and exception type encoding value, and form a symbolic semantic feature sequence according to the field order. At the same time, extract the code line value, cyclomatic complexity value, function call count value, commit count value, added / deleted code line value, commit interval time value, edit count value, rollback count value, and debugging duration value, and form a numerical statistical feature sequence according to the same time position. Perform symbol embedding encoding and numerical projection encoding separately, specifically as follows: Read each encoded value in the symbolic semantic feature sequence, replace each encoded value with the corresponding 64-dimensional real number vector, and arrange them in the original order to obtain the symbolic embedding encoding result. Read each numerical field in the numerical statistical feature sequence, subtract the historical average value and divide by the historical standard deviation to obtain the standardized value, then multiply it with the projection weight matrix and add the bias vector to obtain the 64-dimensional numerical projection encoding result. The projection weight matrix is a coefficient matrix used to map the input value to the 64-dimensional space, and the bias vector is a set of correction values that correspond one-to-one with the 64 output dimensions. It is used to perform numerical translation adjustment on the mapping result. The symbolic embedding encoding result and the numerical projection encoding result are concatenated at the same time position to generate a bi-state input feature sequence. The pyramid bottleneck coding layer includes: Function-level bottleneck unit: Performs one-dimensional convolution on a 256-dimensional input vector within the same function and compresses it into 128-dimensional local features; File-level bottleneck unit: Receives function-level output, performs residual feedforward on all function features within the same file and compresses them into 96-dimensional file features; Repository-level bottleneck unit: Receives file-level output, performs multi-head attention on all file features within the same version, and compresses them into 64-dimensional repository features; Gating threshold adjuster: Adjusts file-level gating thresholds based on warehouse characteristics, and adjusts function-level gating thresholds based on file characteristics; The dual-state input feature sequence is input into the pyramid bottleneck coding layer, and is hierarchically grouped into function-level, file-level, and repository-level feature groups according to function identifier, code file path, and code repository version identifier. Satisfaction constraint coding is then performed on each group to generate corresponding bottleneck features, where: Based on function identifier, code file path, and code repository version identifier, features are hierarchically grouped into function-level, file-level, and repository-level feature groups, specifically: Read the feature vectors in the dual-state input feature sequence in the input order, group the feature vectors with the same function identifier into the same function set to form a function-level feature group, group the function-level feature groups with the same code file path into the same file set to form a file-level feature group, group the file-level feature groups with the same code repository version identifier into the same version set to form a repository-level feature group, and arrange the features within each group in ascending order of timestamp; Perform satisfiability constraint encoding separately, specifically as follows: Read the total number of interface parameters, total number of variable usages, total number of path judgments, total number of null value checks, and total number of exception handlings from the function-level feature group. Count the number of times each condition is satisfied, and divide the number of satisfied conditions by the corresponding total number of times to obtain the interface parameter matching rate, variable range satisfaction rate, path condition satisfaction rate, null value check satisfaction rate, and exception capture satisfaction rate. Multiply each of these five ratios by 0.20 and sum them to obtain the function-level constraint score. When the function-level constraint score is less than 0.70, multiply the feature values of each dimension of the function-level feature group by 0.70 to generate the function-level bottleneck feature. Read the total number of cross-function calls, the total number of shared variables, and the total number of test cases from the file-level feature group. Calculate the number of interface consistency calls, the number of shared variable satisfactions, and the number of test passes, respectively. Divide each of these numbers by the corresponding total to obtain the cross-function interface consistency rate, variable sharing consistency rate, and test coverage satisfaction rate. Multiply these three ratios by 0.34, 0.33, and 0.33, respectively, and then sum them to obtain the file-level constraint score. When the file-level constraint score is less than 0.75, multiply the feature values of each dimension of the file-level feature group by 0.75 to generate the file-level bottleneck feature. Read the total number of version dependencies, the total number of global interface calls, and the total number of historical defects from the repository-level feature group. Calculate the number of correct dependencies, the number of times the interface is consistent, and the number of defects that were not reproduced after a fix. Divide the corresponding number by the corresponding total to obtain the version dependency consistency rate, the global interface consistency rate, and the historical defect regression rate. Multiply the three ratios by 0.34, 0.33, and 0.33 respectively, and then add them together to obtain the repository-level constraint score. When the repository-level constraint score is less than 0.80, multiply the feature values of each dimension of the repository-level feature group by 0.80 to generate the repository-level bottleneck feature. The file-level gating threshold is adjusted based on warehouse-level bottleneck features, and the function-level gating threshold is adjusted based on file-level bottleneck features. Then, the data is written back and fused to generate multi-scale satisfiability coding features, where: Adjusting file-level gating thresholds based on warehouse-level bottleneck characteristics, specifically: Read all dimension values of the warehouse-level bottleneck feature and sum them, then divide by the total number of dimensions to get the average value. When the average value is greater than 0.80, set the file-level gate threshold to 0.70. When the average value is less than 0.50, set the file-level gate threshold to 0.50. In other cases, set it to 0.60. The threshold for adjusting the function level based on file-level bottleneck features is as follows: Read all dimension values of the file-level bottleneck feature and sum them, then divide by the total number of dimensions to get the average value. When the average value is greater than 0.75, set the function-level gate threshold to 0.65; when the average value is less than 0.45, set the function-level gate threshold to 0.45; otherwise, set it to 0.55. Write-back fusion generates multi-scale satisfiability coding features, specifically: Write the warehouse-level bottleneck features into each file position in the file-level feature group, write the file-level bottleneck features into each function position in the function-level feature group, and then add the function-level bottleneck features, file-level bottleneck features, and warehouse-level bottleneck features corresponding to the same function position dimension by dimension and divide by 3 to obtain the multi-scale satisfiability coding features of the corresponding function position. The dual-state gating mapping layer includes: Symbolic Gated Weight Calculator: Applies a linear transformation to the symbolic embedding result and outputs the gated weights between 0 and 1; Numerical Gated Weight Calculator: Applies a linear transformation of the same order to numerical projection results and outputs the weights; Symbolic feature modulator: modulates symbolic features using element-wise multiplication with symbol-gated weights; Numerical feature modulator: modulates numerical features using numerically gated weights; Feature fusion: Summing the two types of modulated features with multi-scale satisfiability features in the channel dimension to obtain gated mapping features; The dual-state gated mapping layer generates symbolic gating weights and numerical gating weights based on symbolic embedding and numerical projection results. It then performs weighted modulation on the symbolic embedding and numerical projection results and fuses them with multi-scale satisfiability coding features to generate gated mapping features, where: The generation of symbolic gating weights and numerical gating weights is as follows: Read the 64-dimensional values corresponding to each position in the symbol embedding result. Multiply the values of the 1st to 64th dimensions by the symbol weight coefficient of the corresponding dimension, and then add the symbol bias value of the corresponding dimension to obtain 64 symbol linear calculation values. Take the negative of each symbol linear calculation value as the exponent value, calculate the exponent of the natural constant, add 1 to the result and use it as the denominator, and then divide 1 by the denominator to obtain the symbol gating weights of the 1st to 64th dimensions with values between 0 and 1. The symbol weight coefficient is a set of adjustment coefficients that correspond one-to-one with the 64 input dimensions, and the symbol bias value is a set of basic correction values that correspond one-to-one with the 64 input dimensions. Read the 64-dimensional values corresponding to each position in the numerical projection result, multiply the values of the 1st to 64th dimensions by the corresponding numerical weight coefficients, and then add the corresponding numerical bias values to obtain 64 numerical linear calculation values. Take the negative of each numerical linear calculation value as the exponent value, calculate the exponent of the natural constant, add 1 to the result and use it as the denominator, and then divide 1 by the denominator to obtain the numerical gating weights of the 1st to 64th dimensions that are between 0 and 1. Generate gated mapping features, specifically: Multiply the numerical values of each dimension of the symbol embedding result by the symbol gating weight at the corresponding position to obtain the symbol modulation feature. Multiply the numerical values of each dimension of the numerical projection result by the numerical gating weight at the corresponding position to obtain the numerical modulation feature. Read the multi-scale satisfiability coding feature. Then add the symbol modulation feature, numerical modulation feature and multi-scale satisfiability coding feature dimension by dimension at the same position and divide by 3 to obtain the gating mapping feature. The adaptive channel transformation layer includes: Channel projection matrix memory: stores projection matrices with a size of 256 by 128; Association strength reader: Reads the association weights between positions from the software development context association structure and normalizes them into a scaled vector of 0 to 1; Channel scaler: Multiplies the scaling vector element-wise with the projection matrix column-by-column to obtain the adaptive projection matrix; Projection Execution Unit: Performs channel transformation on gated mapping features using an adaptive projection matrix, outputting 128-dimensional channel features; The gated mapping features are input into the adaptive channel transformation layer to perform channel transformation, generating channel projection results. A positional association matrix is established based on the software-developed context association structure, and context aggregation is performed to generate context-aggregated features, where: The execution of channel transformation is as follows: Read the 128-dimensional values of each position of the gated mapping feature, and establish a 128-row, 64-column channel projection coefficient matrix, where each row corresponds to one input channel and each column corresponds to one output channel. Read whether there are related edges between each position in the software development context association structure. If there are related edges, record them as 1 and if there are no related edges, record them as 0. Count the number of related edges at each position in the order of input channels, and divide the number of related edges at each position by the total number of related edges at all positions to obtain the correlation coefficient of each position. Multiply the correlation coefficient of each position by the channel projection coefficient of the corresponding row to obtain the adjusted channel projection coefficient matrix. Multiply the gated mapping feature by the adjusted channel projection coefficient matrix to generate the channel projection result. Generate contextual aggregation features, specifically: Read all position connection records in the software development context association structure, establish a position association matrix according to the total number of positions. When there is an association edge between two positions, the corresponding element is recorded as 1, and when there is no association edge between two positions, the corresponding element is recorded as 0. Summate all elements in each row, divide each element of the row by the sum of the row elements to obtain the normalized association matrix. Read the 64-dimensional values of each position in the channel projection result, multiply each element in each row of the normalized association matrix by the 64-dimensional feature value of the corresponding position, and accumulate them item by item according to the dimension to obtain the aggregation vector of the current row corresponding position. Complete the calculation of all positions in sequence to generate context aggregation features. The gradient feedback output layer includes: Gradient calculator: Calculates the gradient of channel features and takes the absolute value; Weight normalizer: Normalizes gradient values to the 0-1 range by batch maximum-minimum; Feedback-gated generator: uses the normalized gradient as the feedback gating weight; Feature Rewriter: Modulates channel features element-wise using feedback-gated weights and outputs 64-dimensional target development context features; The contextual aggregated features are input into the gradient feedback output layer. An interpretable gradient gate is introduced, and feedback gating weights are generated based on the gradient contribution values. Feedback adjustment is then performed to generate the target development contextual features, where: An interpretable gradient gate is a gated computational unit that quantifies the degree of influence of changes in the numerical values of each dimension of the context aggregated features on the current output result and controls the feature retention ratio accordingly. The input is the context aggregated features and the corresponding gradient contribution values, and the output is the feedback gate weights that correspond one-to-one with each feature dimension. Feedback-gated weights are generated based on the gradient contribution values, and feedback adjustment is performed as follows: Read the 64-dimensional values of each position of the context aggregation feature, calculate the absolute value of the gradient change of each feature with respect to the current output result, sum the 64 absolute gradient values, divide the absolute gradient value of each dimension by the sum to obtain 64 normalized gradient contribution values, multiply each normalized gradient contribution value by 0.80 and add 0.20 to obtain the feedback gating weights with values between 0.20 and 1, multiply each dimension value of the context aggregation feature by the corresponding feedback gating weight, multiply the dimensions with weights below 0.35 by an additional 0.50, and keep the original product result unchanged for dimensions with weights above 0.75, and output the adjusted 64-dimensional values in the original order to generate the target development context feature; The improved gMLP network was trained using the development context feature prediction error, patch combinatorial satisfiability classification error, and gradient feedback consistency error as joint optimization objectives. The parameters of each layer were optimized until the joint loss difference over five consecutive training rounds was less than the convergence threshold. The improved gMLP network is trained as follows: The standardized development dataset is divided into training data and validation data in chronological order, with training data accounting for 80% and validation data accounting for 20%. 64 training records are read each time and input into the improved gMLP network to obtain the target development context features and feedback gating weights. The 64-dimensional values of the target development context features are read, and each dimension value is multiplied by the classification weight coefficient and summed. The classification bias value is then added, and the result is subjected to exponential compression normalization to obtain the patch combination satisfiability judgment value between 0 and 1. The target development context features are subtracted from the corresponding labeled features dimension by dimension, and the average of the squared differences is obtained to get the development context feature prediction error. The classification error is calculated by comparing the satisfiability judgment value of the patch combination with the true label value. The satisfiability of the true label value is recorded as 1 and the unsatisfiability as 0. The true label value is multiplied by the judgment value and the natural logarithm is taken. Then, 1 is added and the natural logarithm of the true label value multiplied by 1 and the judgment value is taken. The negative average of all results is taken to obtain the classification error of the satisfiability of the patch combination. The feedback gating weight is subtracted from the labeled gradient contribution value dimension by dimension. The absolute value of the difference in each dimension is averaged to obtain the gradient feedback consistency error. The three errors are multiplied by 0.40, 0.40, and 0.20 respectively and then summed to obtain the joint loss value. The parameters of the dual-state input layer, pyramid bottleneck coding layer, dual-state gated mapping layer, adaptive channel transformation layer, and gradient feedback output layer are adjusted synchronously in the direction of decreasing joint loss value with a learning rate of 0.001. After each training round, the joint loss value is recalculated on the validation data. Training is stopped when the difference in joint loss for 5 consecutive training rounds is less than 0.0001, and the improved gMLP network is obtained after training.
[0023] In this embodiment, generating the candidate patch combination set includes: Based on the target development context features and the software development context association structure, the requirement nodes, interface nodes, code file nodes, function nodes, variable nodes, test case nodes, defect nodes, and runtime exception nodes corresponding to the current development task are extracted. The target path object is then determined based on the requirement reference relationships, interface call relationships, function call relationships, variable dependency relationships, test coverage relationships, defect association relationships, and exception backtracking relationships between nodes. The determination of the target path object is as follows: Read the task number corresponding to the current development task, retrieve the requirement node associated with the task number in the software development context association structure, and use it as the starting node. Then read the nodes that have requirement reference relationship, interface call relationship, function call relationship, variable dependency relationship, test coverage relationship, defect association relationship and exception backtracking relationship with the requirement node, and expand them layer by layer in the connection order. Count the number of nodes, the number of edges and the average value of the target development context features contained in each connection path. Multiply the number of nodes by 0.30, the number of edges by 0.20 and the average value of the target development context features by 0.50 and add them together to get the path score value. Select the connection path with the highest path score value to generate the target path object. Based on the target path object, target function features, interface call chain features, branch path features, and exception handling path features are extracted from the target development context features. A set of path fragment-level candidate patch units is generated according to the interface call location, variable assignment location, branch condition location, null value check location, array access location, exception capture location, and resource release location, where: Extract target function features, interface call chain features, branch path features, and exception handling path features from the target development context features, specifically: Read the function node positions in the target path object, extract the corresponding 64-dimensional values from the target development context features and calculate the average value to generate target function features; read the interface node connection order in the target path object, extract the corresponding position features according to the connection order, accumulate them dimension by dimension and divide by the number of nodes to generate interface call chain features; read the branch condition node positions in the target path object, extract the corresponding position features and sum them dimension by dimension to generate branch path features; read the exception node positions in the target path object, extract the corresponding position features and calculate the average value dimension by dimension to generate exception handling path features. The generation of the path segment-level candidate patch unit set is as follows: Read the interface call location, variable assignment location, branch condition location, null value judgment location, array access location, exception capture location, and resource release location. Concatenate the target function features, interface call chain features, branch path features, and exception handling path features corresponding to each location in the order of location to generate a location feature vector. Based on the location type, generate interface adaptation patch units, variable correction patch units, condition adjustment patch units, null value protection patch units, boundary check patch units, exception completion patch units, and release correction patch units respectively. Complete all location processing in sequence to generate a path fragment-level candidate patch unit set. Each path segment-level candidate patch unit is bound with a patch constraint label, and based on the correspondence between patch constraint labels within the same target path object, the path segment-level candidate patch units are combined to generate a candidate patch combination set, where: Patch constraint tags refer to constraint identification data written into the path fragment-level candidate patch unit, including interface consistency identifier, variable range identifier, path condition identifier, null value safety identifier, array boundary identifier, exception capture identifier, and resource release identifier; For each path segment-level candidate patch unit, a patch constraint label is bound, specifically: Read the type and location of the path fragment-level candidate patch units, bind the interface adaptation patch unit to the interface consistency identifier, bind the variable correction patch unit to the variable range identifier, bind the condition adjustment patch unit to the path condition identifier, bind the null value protection patch unit to the null value safety identifier, bind the boundary check patch unit to the array boundary identifier, bind the exception completion patch unit to the exception capture identifier, bind the release correction patch unit to the resource release identifier, and generate tagged patch units. The path segment-level candidate patch units are combined to generate a candidate patch combination set, specifically as follows: Read all tagged patch units within the same target path object, select one patch unit each from the interface call location, variable assignment location, branch condition location, null value judgment location, array access location, exception capture location, and resource release location as a group of candidate combinations, determine whether there are any conflicts between the tags in the group, retain those with the same or coexisting tags, and remove those with mutually exclusive tags, traverse all combination methods in turn, summarize the retained results, and generate a set of candidate patch combinations.
[0024] In this embodiment, generating a conflict set including a set of conflict patch units includes: Based on the candidate patch combination set, each candidate patch combination is read sequentially, and interface, variable, path, object, exception, and resource information are extracted to generate formal constraint objects. A constraint association graph is constructed, and neural-guided conflict prediction is performed to obtain conflict probability values. When the conflict probability value is greater than a threshold, a high-conflict label result is generated; otherwise, an unsolved label result is generated. Generate formal constraint objects, specifically: Read each patch unit in the candidate patch combination one by one, and extract the interface name, number of parameters, parameter type, return value type, variable name, variable type, variable value range, path condition expression, object null value status, exception type, resource identifier and resource status. Write the interface name and parameter information into the interface field, the variable information into the variable field, the path condition expression into the path field, the object null value status into the object field, the exception type into the exception field, and the resource status into the resource field. Combine them in a fixed order of interface field, variable field, path field, object field, exception field and resource field to generate a formal constraint object. Constructing a constraint association graph and performing neural-guided conflict prediction, specifically: The interface field, variable field, path field, object field, exception field, and resource field in the formal constraint object are read and used as constraint nodes. When there is a parameter reference, variable dependency, path inclusion, object access, exception propagation, or resource occupation relationship between two fields, an associated edge is established between the corresponding nodes to generate a constraint association graph. The values of each node field are read as input features. Three rounds of adjacency propagation calculation are performed on the constraint association graph. In each round, the features of adjacent nodes are summed dimension by dimension and divided by the number of adjacent nodes. Then, the summation is averaged with the feature of the current node to obtain the updated features. The updated features of all nodes are read, the average is calculated, and exponential compression normalization is performed to obtain a conflict probability value between 0 and 1. When the conflict probability value is greater than 0.65, a high conflict label result is generated; otherwise, a unsolved label result is generated. Based on the formal constraint objects corresponding to the results to be solved, the interface, variable, path, object, exception, and resource information are respectively converted into interface constraints, type range constraints, path constraints, null boundary constraints, exception constraints, and release constraints, and combined to generate an SMT constraint set, where: Interface constraints are restrictions on the consistency of interface name, number of parameters, parameter types, and return value types. Type range constraints are restrictions on the consistency of variable types and the upper and lower bounds of variable values. Path constraints are restrictions on the truth or falsehood of conditional expressions and the order of execution. Null value boundary constraints are restrictions on the non-null relationship of objects before use and the relationship between array access subscripts and their upper and lower bounds. Exception constraints are restrictions on the correspondence between exception throwing types and caught types. Release constraints are restrictions on the release relationship of file handles, connection objects, and memory objects after use. Based on the SMT constraint set, logical relaxation calculations are performed on Boolean constraints, and continuous gradient approximation calculations are performed on numerical constraints to generate candidate solution vectors. An initial search space and initial variable assignment states are also established, where: Boolean constraints refer to interface constraints, path constraints, null boundary constraints, exception constraints, and release constraints, where the constraint result only includes two states: true or false, and type range constraints, which specify whether the variable types are consistent. Numerical constraints refer to the constraints in interface constraints, type range constraints, and null value boundary constraints that involve the number of parameters, upper and lower limits of variable values, upper and lower limits of array access subscripts, and comparison of execution order numbers. Perform logical relaxation computation on Boolean constraints, specifically: Replace 0 with 0.0 and 1 with 1.0 in the Boolean constraints, expand the allowed value range of the true / false judgment variables to continuous values between 0 and 1, take the product value of the participating variables for AND operation constraints, take the sum of the variables and then subtract the product value for OR operation constraints, and take 1 minus the variable value for non-operation constraints to obtain the logical relaxation result; Perform continuous gradient approximation calculations on numerical constraints, specifically as follows: Read the upper and lower limits and the target variable value in the numerical constraints. When the target variable value is less than the lower limit, the target variable value minus the lower limit is used as the deviation value. When the target variable value is greater than the upper limit, the target variable value minus the upper limit is used as the deviation value. When the target variable value is between the upper and lower limits, the deviation value is recorded as 0. Summing all deviation values one by one, the continuous gradient approximation result is obtained. Generate candidate solution vectors, specifically as follows: Read all variable values from the logical relaxation result and all variable values from the continuous gradient approximation result, arrange them in the order of interface variable, path variable, object variable, exception variable and resource variable, and write each variable value into the same column vector in sequence to generate candidate solution vector; Establish the initial search space and initial variable assignment state, specifically as follows: Read the values of each variable in the candidate solution vector, establish a search interval of 0 to 1 for variables with values ranging from 0 to 1, establish upper and lower bound integer search intervals for integer variables, and establish upper and lower bound real number search intervals for real number variables to generate an initial search space. When the variable value is greater than or equal to 0.50, it is recorded as 1, and when it is less than 0.50, it is recorded as 0. Continuous variables keep their original values unchanged. Combine the current values of all variables to generate the initial variable assignment state. Based on the initial search space, initial variable assignment states, and SMT constraint set, a target search strategy is scheduled, adjusting the variable branching order, conflict backtracking order, and clause learning intensity. This information is then input into the SMT solver to obtain the combinatorial satisfiability solution. When the result is satisfiable, the corresponding candidate patch combination is added to the set of satisfiable patch combinations, where: The target search strategy refers to the solution control set calculated based on the search size, variable conflict frequency, constraint complexity, and historical solution success rate of the current candidate patch combination corresponding to the solution task. The search size is the sum of the number of selectable values for all variables. The variable conflict frequency is the sum of the number of times all variables have participated in conflicts in the past divided by the total number of variables. The constraint complexity is the sum of the total number of constraints multiplied by 0.60 and the number of constraint nesting levels multiplied by 0.40. The historical solution success rate is the number of times it can be satisfied in the past divided by the total number of historical solutions. The strategy score is obtained by multiplying the search size by 0.30, the variable conflict frequency by 0.30, the constraint complexity by 0.20, and the historical solution success rate by 0.20. When the strategy score is greater than 0.70, it is determined to be a depth-first search strategy; when the strategy score is greater than 0.40 and less than or equal to 0.70, it is determined to be a hybrid search strategy; when the strategy score is less than or equal to 0.40, it is determined to be a breadth-first search strategy. When the search strategy is depth-first search, the number of variables involved in constraints is multiplied by 0.60, the number of historical conflicts is multiplied by 0.40, and the results are added together. The result is used to generate a variable priority order from high to low, and a conflict fallback order is generated from deep to shallow decision levels. The most recent 90% of conflict constraints are retained in chronological order. When the search strategy is mixed search, the number of variables involved in constraints, the number of historical conflicts, and the width of the value range are multiplied by 0.40, 0.30, and 0.30 respectively, and the results are added together. The result is used to generate a variable priority order from high to low, and a conflict fallback order is generated by alternating between deep and medium levels. The most recent 70% of conflict constraints are retained. When the search strategy is breadth-first search, the value range width of variables is multiplied by 0.70, the number of involved constraints is multiplied by 0.30, and the results are added together. The result is used to generate a variable priority order from high to low, and a conflict fallback order is generated from shallow to deep decision levels. The most recent 50% of conflict constraints are retained. The variable branching order refers to the order in which each variable to be solved enters the assignment calculation; the conflict backtracking order refers to the order in which each decision level executes the backtracking calculation after a constraint conflict occurs; and the clause learning intensity is the proportion and number of rounds in which conflict conditions are recorded and retained to limit the search again. The SMT solver outputs the combinatorial satisfiability solution results, specifically: Read the current values of all variables in the initial variable assignment state, substitute them into the SMT constraint set and calculate the constraint results item by item. For equality constraints, calculate the difference between the left and right sides of the equation. If the result is equal to 0, it is considered satisfied. For size constraints, calculate the difference between the left and right sides of the equation. If the difference satisfies the size relationship, it is considered satisfied. For path true / false constraints, read the true / false variable and determine the condition result. When all constraints are satisfied, output the satisfied result. When a constraint is not satisfied, record the set of variables involved in the first constraint that is not satisfied. Select one variable according to the priority of variable selection, adjust the variable to the next value in the search interval, and recalculate by substituting it into all constraints. If all variable values at the current level have been traversed, return to the previous level according to the conflict backoff level order and change the variable values at the previous level. Each time a constraint is not satisfied, write the combination of conflicting variables into the conflict constraint set, and retain the latest record according to the retention ratio. Repeat the variable adjustment, constraint calculation and level backoff until all constraints are satisfied and output a satisfyable result, or output an unsatisfiable result when all values have been traversed. Generate the solution result of the combinatorial satisfiability. Based on the high-conflict labeling results or unsatisfiable candidate patch combinations, the unsatisfiable core is parsed, and conflict constraints, conflict objects, and conflict patch units are extracted to generate a conflict set, where: The core issue is that the parsing cannot satisfy the requirements, specifically: Read the formal constraint object or solution result corresponding to the high conflict mark result as an unsatisfiable candidate patch combination, extract all constraints involved in the current solution, delete one constraint at a time in the order of constraint addition, and re-execute the consistency check. When the solution result changes from unsatisfiable to satisfyable after deleting the corresponding constraint, record the corresponding constraint as the core constraint. Complete all constraint checks in sequence, and combine all core constraints to generate an unsatisfiable core. Extracting conflict constraints, conflict objects, and conflict patch units, specifically: Read all unsatisfiable core constraints as conflict constraints. Based on the interface name, variable name, path location, object identifier, exception type, and resource identifier corresponding to each core constraint, extract the associated records as conflict objects. Based on the patch unit number to which the conflict object belongs in the candidate patch combination, extract the corresponding patch unit as the conflict patch unit. Summarize the conflict constraints, conflict objects, and conflict patch units according to the candidate patch combination number to generate a conflict set.
[0025] In this embodiment, generating the updated candidate patch combination set includes: Based on the conflict set, and according to the interface constraints, type range constraints, path constraints, null value boundary constraints, exception constraints, and release constraints corresponding to the conflict constraints, determine the interface adaptation actions, variable boundary adjustment actions, path condition correction actions, null value protection actions, exception handling completion actions, and resource release correction actions, and generate code modification action types, where: Generate code to modify the action type, specifically: Read all conflicting constraints in the conflict set, determine the constraint category for each one, and record the following actions: when the conflicting constraint is an interface constraint, record it as an interface adaptation action; when the conflicting constraint is a type range constraint, record it as a variable boundary adjustment action; when the conflicting constraint is a path constraint, record it as a path condition correction action; when the conflicting constraint is a null value boundary constraint, record it as a null value protection action; when the conflicting constraint is an exception constraint, record it as an exception handling completion action; when the conflicting constraint is a release constraint, record it as a resource release correction action. Count the number of occurrences of each action type, sort them from highest to lowest, and use the sorting result as the code modification action type. Based on the code modification action type and the set of conflict patch units, action embedding encoding and patch unit embedding encoding are performed respectively to generate action embedding features and conflict patch embedding features. Gated fusion is then performed in conjunction with target development context features to generate patch refactoring features, where: The action embedding encoding and patch unit embedding encoding are performed separately, specifically as follows: Read the code and modify the action numbers in the action type, establish a correspondence table between action numbers and 32-dimensional real vectors, replace each action number with the corresponding vector, generate action embedding features, read the patch unit type, its location number, constraint label number and historical usage count value in the conflict patch unit set, replace the patch unit type, its location number and constraint label number with 16-dimensional real vectors respectively, and then concatenate them with the historical usage count value to generate conflict patch embedding features; Generate patch refactoring features, specifically: Read the action embedding features, conflict patch embedding features, and target development context features. Calculate the average value of each dimension of the three types of features. Multiply the average value of the action embedding features by 0.40, the average value of the conflict patch embedding features by 0.30, and the average value of the target development context features by 0.30, and then add them together to obtain the gating coefficient. Multiply the values of each dimension of the action embedding features by the gating coefficient, multiply the values of each dimension of the conflict patch embedding features by 1 and subtract the gating coefficient, and then add them dimension by dimension to the corresponding values of the target development context features and divide by 3 to generate the patch reconstruction features. Based on the patch reconstruction features, reconstructed patch units are generated and used to replace the corresponding conflicting patch units in the candidate patch combination set. Candidate patch units that do not match the conflict set are retained, resulting in an updated candidate patch combination set, where: Reconstruction patch units are generated based on patch reconstruction features, specifically as follows: Read the values of each dimension of the patch reconstruction feature, determine the patch unit type according to the dimension with the largest value, determine the insertion position number according to the average value of the first 8 dimensions, determine the variable adjustment range according to the average value of the 9th to 16th dimensions, determine the condition modification direction according to the average value of the 17th to 24th dimensions, and determine the exception or release handling method according to the average value of the 25th to 32nd dimensions. Combine the patch unit type, insertion position number, variable adjustment range, condition modification direction, and exception or release handling method to generate a reconstruction patch unit. Replace the corresponding conflicting patch unit in the candidate patch combination set with the reconstruction patch unit, and retain the candidate patch units that do not hit the conflict set to generate an updated candidate patch combination set.
[0026] In this embodiment, generating the final development assistance result includes: Based on the updated candidate patch combination set, extract the interface constraints, type range constraints, path constraints, null boundary constraints, exception constraints, and release constraints corresponding to each updated candidate patch combination, regenerate the SMT constraint set, and perform combinatorial satisfiability solving through the SMT solver to obtain the updated combinatorial satisfiability solution results; Based on the updated combinatorial satisfiability solution results, updated candidate patch combinations that are satisfiable are merged into the set of satisfiable patch combinations, and updated candidate patch combinations that are unsatisfiable are filtered out to generate the final set of satisfiable patch combinations. Based on the final set of satisfyable patch combinations, target satisfyable patch combinations are filtered in ascending order of the number of patch units, the number of functions involved, the number of interface adjustments, and the number of exception handling changes, generating the final development assistance result, where: The final development support result is generated as follows: Read all patch combinations in the final set of satisfyable patch combinations, and count the number of patch units, the number of functions involved, the number of interface adjustments, and the number of exception handling changes in each patch combination. The number of patch units is calculated based on the total number of patch units in the combination, the number of functions involved is calculated based on the number of duplicate modified function identifiers, the number of interface adjustments is calculated based on the number of times the interface name, parameter type, number of parameters, or return value has changed, and the number of exception handling changes is calculated based on the number of times exception captures have been added, exception captures have been deleted, or exception types have been changed. Sort the patch units by number from smallest to largest, select the first patch combination as the target satisfyable patch combination, read all patch units in the target satisfyable patch combination, generate a patch execution list according to the code file path, function identifier and code position order, and combine the patch execution list, corresponding code modification content, constraint satisfaction results and change statistics results to generate the final development auxiliary result.
[0027] refer to Figure 3 A software development intelligent assistance system based on big data analysis includes the following modules: The data construction module is used to collect big data from the entire software development process and build a software development context association structure. The feature generation module is used to build an improved gMLP network based on a standardized development dataset and generate target development context features. The patch combination module is used to determine the target path object based on the characteristics of the target development context and generate a set of candidate patch combinations. The consistency verification module is used to extract the SMT constraint set based on candidate patch combinations, perform combination satisfiability solution, and generate a set of satisfiable patch combinations and a conflict set. The conflict refactoring module is used to determine the type of code modification action based on the conflict set and generate an updated set of candidate patch combinations. The results generation module is used to re-execute the combinatorial satisfiability solution and generate the final development aid results.
[0028] Example 1: To verify the feasibility of this invention in practice, it was applied to a defect repair assistance scenario in an enterprise-level order settlement system. This system includes modules for order creation, inventory deduction, payment callback, discount calculation, invoice generation, and exception compensation. In one iteration, a defect was discovered where the order status was not updated after a successful payment callback. This defect occurred 137 times in 5000 simulated payment callbacks, with an exception occurrence rate of 2.74%. Furthermore, manual troubleshooting easily overlooks the consistency relationships between payment callback interface parameters, order status variable boundaries, transaction commit paths, and exception handling logic, leading to interface conflicts, unreachable paths, and incomplete exception handling in candidate modification schemes.
[0029] Import the system's requirement document data, interface document data, historical code repository data, code commit log data, defect ticket data, test case data, test execution report data, runtime exception log data, and developer operation record data. The original data includes 820 requirement records, 312 interface records, 1386 code files, 6420 functions, 4920 code commit records, 728 defect tickets, 2840 test cases, 8760 test execution reports, 11650 runtime exception logs, and 15300 development operation records. The system performs field unification, duplicate record merging, missing field completion, and cross-source association matching on the above data. Before processing, there were 23 records with missing interface numbers, 41 records with inconsistent function path formats, and 19 records with duplicate test case numbers. After processing, 23 interface numbers were completed, 41 function paths were unified, and 19 duplicate test case numbers were merged, resulting in 38,472 standardized development data records. The system also constructs a software development context association structure based on requirement number, interface number, code file path, function identifier, variable identifier, test case number, defect number, and exception number.
[0030] When a development task is input regarding the failure to update the order status after a successful payment callback, the system locates the corresponding defect node in the context association structure and associates it with 1 payment callback interface node, 3 code file nodes, 7 function nodes, 11 variable nodes, 18 test case nodes, and 64 runtime exception nodes. The system expands along requirement reference relationships, interface call relationships, function call relationships, variable dependency relationships, test coverage relationships, defect association relationships, and exception backtracking relationships, resulting in 5 candidate paths. The first path includes the payment callback entry function, order query function, order status judgment function, status writing function, and transaction commit function, with 15 nodes and 18 edges. The average target development context feature is 0.82, and the path score is 8.51. The scores of the other four paths are 6.74, 5.93, 4.88, and 4.12, respectively. The system selects the first path as the target path object.
[0031] The system inputs standardized development data into an improved gMLP network. A dual-state input layer extracts symbolic semantic features such as interface number, function identifier, variable identifier, defect number, and exception number, as well as numerical statistical features such as the number of interface parameters, the number of historical function modifications, the number of test failures, the number of exception occurrences, and variable value boundaries. Taking the order status update function as an example, this function has been modified 14 times, experienced 9 associated test failures, and encountered 37 exceptions in nearly 1000 test runs. The order status variable's value range is 0 to 5. After processing by the pyramid bottleneck coding layer, the bottleneck feature value at the function level is 0.79, at the file level is 0.72, and at the warehouse level is 0.68. After processing by the dual-state gating mapping layer, the symbol gating weight is 0.61, and the numerical gating weight is 0.39. After processing by the gradient feedback output layer, the contribution value of the payment callback interface position is 0.84, the contribution value of the order status variable position is 0.91, the contribution value of the transaction commit position is 0.76, and the contribution value of the exception compensation position is 0.63. Based on this, the system determines the order status variable assignment position as the highest priority modification position.
[0032] Based on the target path object, the system generates 6 interface adaptation patch units at the interface call location, 8 variable correction patch units at the variable assignment location, 7 path condition correction patch units at the branch condition location, 5 null value protection patch units at the null value judgment location, 3 boundary check patch units at the array access location, 4 exception completion patch units at the exception capture location, and 4 release correction patch units at the resource release location, resulting in a total of 37 candidate patch units. The system binds interface consistency identifier, variable range identifier, path condition identifier, null value safety identifier, array boundary identifier, exception capture identifier, and resource release identifier to the candidate patch units. Theoretically, 8064 patch combinations can be formed before combination. The system eliminates 3120 combinations where the interface parameter type and variable assignment type are inconsistent, 1460 combinations where the path condition and exception compensation condition are mutually exclusive, and 912 combinations where the resource release location is earlier than the object usage location, ultimately retaining 2572 candidate patch combinations.
[0033] The system extracts interface, variable, path, object, exception, and resource information from each of the 2572 candidate patch combinations, converting them into interface constraints, type range constraints, path constraints, null value boundary constraints, exception constraints, and release constraints. The SMT solver then performs combinatorial satisfiability solving. The initial solution yields 1496 satisfiable combinations and 1076 unsatisfiable combinations. Among the unsatisfiable combinations, there are 312 interface conflicts, 244 variable boundary conflicts, 286 path unreachability conflicts, 134 null value boundary conflicts, 63 exception handling conflicts, and 37 resource release conflicts. Taking one unsatisfiable combination as an example, its interface adaptation patch changed the payment status parameter from an integer to a string, but the path condition patch still compared it using an integer status code, causing a conflict between the interface constraint and the path constraint. After parsing the core of the unsatisfiability, the system extracts the conflicting patch units and generates a conflict set.
[0034] The system determines the code modification action type based on the conflict set, performs embedding encoding on the code modification action type and the conflict patch unit set respectively, and then performs gating fusion combined with the target development context features to generate refactoring patch units. For the above conflict combinations, the system refactors the patch that changes the payment status parameter to a string type to retain the integer status code and adds a callback signature verification field, and refactors the path condition to a payment status code equal to 2, a callback signature verification passed, and an order status not equal to 2. After refactoring, the system performs SMT solution again on the updated candidate patch combination set. Of the original 1076 unsatisfactory combinations, 438 are converted to satisfactory combinations, 322 are still unsatisfactory, and 316 are filtered out due to excessive modification costs, resulting in 1934 satisfactory patch combinations. The system filters in ascending order by the number of patch units, the number of functions involved, the number of interface adjustments, and the number of exception handling changes, and finally determines the target satisfactory patch combination containing 5 patch units, 2 functions involved, 1 interface adjustment, and 1 exception handling change, and generates the final development assistance result.
[0035] After applying the final development support results to the testing environment, 316 out of 320 payment callback-related test cases passed, achieving a pass rate of 98.75%. In the full regression test, 2769 out of 2840 cases passed, with 71 failing, a reduction of 93 cases compared to the initial 164 failures. In 5000 simulated payment callbacks, the number of similar anomalies decreased from 137 to 3, and the anomaly rate decreased from 2.74% to 0.06%. To verify the comparative effect, 60 historical defect tasks were simulated. The traditional method averaged 96.4 minutes for defect localization, 74.2 minutes for candidate patch formation, an 86.1% first regression test pass rate, and an average of 3.4 reworks. The method of this invention averaged 38.7 minutes for defect localization, 21.6 minutes for candidate patch formation, a 96.8% first regression test pass rate, and an average of 1.1 reworks. As can be seen from the above simulation data, the present invention can detect interface conflicts, unreachable paths, null value exceptions, array out-of-bounds errors, and incomplete exception handling before the candidate code is modified and implemented. It can also generate a satisfactory patch combination through conflict feedback and refactoring, thereby improving the accuracy of development assistance results and the efficiency of software repair.
[0036] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A software development intelligent assistance method based on big data analysis, characterized in that, include: Collect big data from the entire software development process, perform preprocessing on the big data, generate standardized development datasets, and construct a software development context association structure; An improved gMLP network is constructed based on a standardized development dataset. Embedding encoding, gated spatial projection, cross-channel feature mixing, and contextual feature aggregation are performed on the standardized development dataset to generate target development contextual features. Based on the target development context features and software development context association structure, the target path object is determined, a path segment-level candidate patch unit set is generated, and a patch constraint label is bound to each candidate patch unit to generate a candidate patch combination set. Based on the candidate patch combination set, a formal constraint object is extracted for each candidate patch combination and converted into an SMT constraint set. The combination satisfiability is solved by the SMT solver. If it is satisfiable, it is added to the satisfiable patch combination set. If it is not satisfiable, the unsatisfiable core is resolved to generate a conflict set including the conflict patch unit set. Based on the conflict set, the code modification action type is determined. Embedding encoding is performed on the code modification action type and the conflict patch unit set respectively. Gated fusion is then performed in combination with the target development context features to generate refactoring patch units and an updated candidate patch combination set. The combinatorial satisfiability solution is re-executed on the updated candidate patch combination set. Satisfiable patch combinations are merged into the satisfiable patch combination set to determine the target satisfiable patch combination and generate the final development assistance result.
2. The intelligent auxiliary method and system for software development based on big data analysis according to claim 1, characterized in that, The big data of the entire software development process specifically includes requirement document data, interface document data, historical code repository data, code commit log data, defect ticket data, test case data, test execution report data, runtime exception log data, and developer operation record data.
3. The intelligent auxiliary method for software development based on big data analysis according to claim 1, characterized in that, The construction of the software development context association structure includes: Perform text cleaning, field splitting, format standardization, and invalid character removal on requirement document data, interface document data, defect work order data, test execution report data, and runtime exception log data; Perform version number extraction, branch identifier extraction, code file path normalization, function identifier binding, and commit timestamp unification on historical code repository data and code commit log data; Perform test case number binding, test object function binding, test input / output field normalization, and test coverage relationship annotation on test case data; Perform operation type identification, operation object identification binding, and operation sequence sorting on the developer's operation log data; Based on the requirement number, interface number, defect number, test case number, code file path, function identifier, and submission version number, cross-source association matching is performed on the processed data to generate a standardized development dataset; Extract requirement number, interface number, code file path, function identifier, variable identifier, test case number, defect number, exception number, and development operation identifier from the standardized development dataset to generate corresponding nodes; Based on requirement reference relationships, interface call relationships, file inclusion relationships, function call relationships, variable dependency relationships, test coverage relationships, defect association relationships, exception backtracking relationships, and development operation sequence relationships, establish related edges to generate a software development context association structure.
4. The intelligent auxiliary method for software development based on big data analysis according to claim 1, characterized in that, The generated target development context features include: An improved gMLP network is constructed, which includes a dual-state input layer, a pyramid bottleneck coding layer, a dual-state gated mapping layer, an adaptive channel transformation layer, and a gradient feedback output layer. The standardized development dataset is input into the dual-state input layer to extract symbolic semantic feature sequences and numerical statistical feature sequences. Symbolic embedding encoding and numerical projection encoding are performed respectively, and then concatenated to generate a dual-state input feature sequence. The dual-state input feature sequence is input into the pyramid bottleneck coding layer, and is hierarchically grouped into function-level, file-level and repository-level feature groups according to function identifier, code file path and code repository version identifier. Satisfaction constraint coding is then performed on each group to generate corresponding bottleneck features. Adjust the file-level gating threshold based on the warehouse-level bottleneck features, adjust the function-level gating threshold based on the file-level bottleneck features, and write back and fuse to generate multi-scale satisfiability coding features. The dual-state gated mapping layer generates symbolic gate weights and numerical gate weights based on symbolic embedding results and numerical projection results, performs weighted modulation on the symbolic embedding results and numerical projection results, and fuses them with multi-scale satisfiability coding features to generate gated mapping features; The gated mapping features are input into the adaptive channel transformation layer to perform channel transformation and generate channel projection results. The location association matrix is established based on the software development context association structure and context aggregation is performed to generate context aggregation features. The context aggregation features are input into the gradient feedback output layer. An interpretable gradient gate is introduced, and feedback gating weights are generated based on the gradient contribution value. Feedback adjustment is then performed to generate target development context features. The improved gMLP network was trained by using the development context feature prediction error, patch combination satisfiability classification error, and gradient feedback consistency error as joint optimization objectives to optimize the parameters of each layer until the joint loss difference of 5 consecutive training rounds was less than the convergence threshold.
5. The intelligent auxiliary method for software development based on big data analysis according to claim 1, characterized in that, The generated candidate patch combination set includes: Based on the target development context features and the software development context association structure, the requirement nodes, interface nodes, code file nodes, function nodes, variable nodes, test case nodes, defect nodes, and runtime exception nodes corresponding to the current development task are extracted. The target path object is determined based on the requirement reference relationship, interface call relationship, function call relationship, variable dependency relationship, test coverage relationship, defect association relationship, and exception backtracking relationship between nodes. Based on the target path object, target function features, interface call chain features, branch path features and exception handling path features are extracted from the target development context features. Then, a set of path fragment-level candidate patch units is generated according to the interface call position, variable assignment position, branch condition position, null value judgment position, array access position, exception capture position and resource release position. Each path segment-level candidate patch unit is bound with a patch constraint label, and the path segment-level candidate patch units are combined to generate a candidate patch combination set based on the correspondence between patch constraint labels within the same target path object.
6. The intelligent auxiliary method for software development based on big data analysis according to claim 1, characterized in that, The generation of the conflict set, which includes a set of conflict patch units, includes: Based on the candidate patch combination set, each candidate patch combination is read and the interface, variable, path, object, exception and resource information is extracted to generate a formal constraint object, construct a constraint association graph and perform neural-guided conflict prediction to obtain the conflict probability value. When the conflict probability value is greater than the threshold, a high conflict label result is generated; otherwise, a unsolved label result is generated. Based on the formal constraint objects corresponding to the marked results to be solved, the interface, variable, path, object, exception and resource information are converted into interface constraints, type range constraints, path constraints, null boundary constraints, exception constraints and release constraints, respectively, and combined to generate the SMT constraint set; Based on the SMT constraint set, logical relaxation calculation is performed on Boolean constraints, continuous gradient approximation calculation is performed on numerical constraints, candidate solution vectors are generated, and an initial search space and initial variable assignment state are established. Based on the initial search space, initial variable assignment state, and SMT constraint set, the target search strategy is scheduled, the variable branching order, conflict backtracking order, and clause learning intensity are adjusted, and the results are input into the SMT solver to obtain the combinatorial satisfiability solution. When the result is satisfiable, the corresponding candidate patch combination is added to the set of satisfiable patch combinations. Based on the high-conflict marking results or unsatisfiable candidate patch combinations, the unsatisfiable core is parsed, and conflict constraints, conflict objects, and conflict patch units are extracted to generate a conflict set.
7. The intelligent auxiliary method for software development based on big data analysis according to claim 1, characterized in that, The generated updated candidate patch combination set includes: Based on the conflict set, and according to the interface constraints, type range constraints, path constraints, null value boundary constraints, exception constraints, and release constraints corresponding to the conflict constraints, determine the interface adaptation actions, variable boundary adjustment actions, path condition correction actions, null value protection actions, exception handling completion actions, and resource release correction actions, and generate code modification action types. Based on the code modification action type and conflict patch unit set, action embedding encoding and patch unit embedding encoding are performed respectively to generate action embedding features and conflict patch embedding features. Gated fusion is then performed in combination with target development context features to generate patch refactoring features. Based on the patch reconstruction features, reconstructed patch units are generated and the corresponding conflicting patch units in the candidate patch combination set are replaced. Candidate patch units that do not hit the conflict set are retained, and an updated candidate patch combination set is generated.
8. The intelligent auxiliary method for software development based on big data analysis according to claim 1, characterized in that, The generation of the final development assistance result includes: Based on the updated candidate patch combination set, extract the interface constraints, type range constraints, path constraints, null boundary constraints, exception constraints, and release constraints corresponding to each updated candidate patch combination, regenerate the SMT constraint set, and perform combinatorial satisfiability solving through the SMT solver to obtain the updated combinatorial satisfiability solution results; Based on the updated combinatorial satisfiability solution results, updated candidate patch combinations that are satisfiable are merged into the set of satisfiable patch combinations, and updated candidate patch combinations that are unsatisfiable are filtered out to generate the final set of satisfiable patch combinations. Based on the final set of satisfyable patch combinations, target satisfyable patch combinations are filtered in ascending order of the number of patch units, the number of functions involved, the number of interface adjustments, and the number of exception handling changes, generating the final development assistance result.
9. A system for path planning in discrete map traversal surveys under the influence of multiple factors, implementing the intelligent software development assistance method based on big data analysis as described in any one of claims 1 to 8, characterized in that, Includes the following modules: The data construction module is used to collect big data from the entire software development process and build a software development context association structure. The feature generation module is used to build an improved gMLP network based on a standardized development dataset and generate target development context features. The patch combination module is used to determine the target path object based on the characteristics of the target development context and generate a set of candidate patch combinations. The consistency verification module is used to extract the SMT constraint set based on candidate patch combinations, perform combination satisfiability solution, and generate a set of satisfiable patch combinations and a conflict set. The conflict refactoring module is used to determine the type of code modification action based on the conflict set and generate an updated set of candidate patch combinations. The results generation module is used to re-execute the combinatorial satisfiability solution and generate the final development aid results.