Software development result traceability analysis system based on version control

By combining blockchain technology and code semantic analysis with a functional impact positioning module, the problems of insufficient semantic analysis of code changes and data credibility in version control systems are solved. This achieves the immutability of code commit records and automated functional correlation analysis, improving the efficiency and accuracy of software development result traceability.

CN121433703APending Publication Date: 2026-01-30TIBET TIANHE SHENGYU INFORMATION TECHNOLOGY CO LTD
View PDF 0 Cites 4 Cited by

Patent Information

Application Number
CN202511588751.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-03
Publication Date
2026-01-30

AI Technical Summary

Technical Problem

Existing version control systems lack the ability to intelligently analyze the semantics of code changes in complex projects, making it difficult for developers to quickly understand the impact of cross-version modifications on system functionality. At the same time, there is a problem of insufficient data reliability due to the ease with which commit records can be tampered with, resulting in uncertain traceability results.

Method used

Blockchain technology is used to ensure the immutability of submission records. Combined with code semantic parsing and functional impact localization modules, a unique identifier is generated through a hash algorithm. Graph neural networks are applied to analyze code dependencies, construct a functional association graph, track the code evolution path, and generate a visual traceability dataset.

Benefits of technology

It ensures the authenticity and integrity of code commit records, automatically identifies logical connections in code, significantly improves the efficiency and accuracy of function tracing, builds a full-chain traceability system, meets the traceability needs of complex projects, and improves team collaboration efficiency and problem-solving accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121433703A_ABST
    Figure CN121433703A_ABST
Patent Text Reader

Abstract

The invention discloses a software development result traceability analysis system based on version control, and relates to the technical field of intelligent software analysis. According to the method, the non-tampering property of code submission records is ensured through a block chain technology, a credible basis is provided for traceability, the code semantic analysis module generates a data set containing semantic association in combination with a clustering algorithm and weighted calculation, and the function influence positioning module constructs a function association graph by applying a graph neural network algorithm, so that the traceability is improved. An influence path of code change on system functions is automatically identified, the time cost of complex project function influence positioning is remarkably reduced, an evolution path generation module analyzes and tracks a code evolution path in combination with a time sequence, and a core module identification module clusters key nodes and positions a core function module. And the time-tracing source data storage module generates a visual relation graph and a queried data set, so that the whole-process management from code submission to result tracing is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent software analysis technology, specifically a software development results traceability analysis system based on version control. Background Technology

[0002] In the field of software development, version control and innovation tracing are crucial for improving collaboration efficiency, ensuring code quality, and tracking development results. Version control systems provide a foundation for team collaboration and problem-solving by recording code change history. However, existing methods have exposed significant shortcomings in complex projects: they usually only record commits in the form of a timeline, lacking in-depth analysis of the functional relationships behind code changes. This makes it difficult for developers to quickly understand the impact of cross-version modifications on system functionality. In addition, traditional systems cannot ensure the immutability of commit records, posing a risk of malicious data modification. This makes it extremely difficult to track code evolution paths and functional impacts in high-concurrency, large-scale collaboration scenarios.

[0003] The core challenges stem from two key technical factors. First, version control systems lack the ability to intelligently analyze the semantics of code changes. Code commits often contain complex logical relationships; for example, modifications to underlying interfaces may affect upper-level business logic. However, existing tools cannot automatically identify these relationships, forcing developers to manually trace a large amount of historical data, which is inefficient. Second, existing systems suffer from insufficient data reliability. Metadata in commit records is easily tampered with, making it difficult to guarantee the authenticity of development results and the attribution of responsibility. These two factors are interconnected: the lack of semantic analysis makes functional traceability reliant on manual intervention, leading to efficiency issues; while insufficient data reliability further exacerbates the uncertainty of traceability results, limiting the application of the system in complex scenarios. Summary of the Invention

[0004] The purpose of this invention is to provide a software development result traceability and analysis system based on version control. It uses blockchain technology to ensure the immutability of submission records, and combines code semantic parsing and functional impact positioning modules to achieve automated functional correlation analysis, thereby constructing a full-chain traceability system. This significantly improves the collaboration efficiency and problem-solving accuracy in software development and meets the traceability needs of complex projects.

[0005] The objective of this invention can be achieved through the following technical solutions: This application provides a version control-based software development outcome traceability and analysis system, including: The commit record preprocessing module obtains code commit records, extracts metadata containing timestamps, authors, and changes from the version control system, generates unique identifiers using a hash algorithm, and obtains the commit record dataset. The blockchain trusted storage module, based on the commit record dataset, uses blockchain technology to store the hash value of each commit record in a distributed ledger, verifies the integrity of the records through a consensus mechanism, and obtains an immutable chain of commit records. The code semantic parsing module extracts code change content from the immutable commit record chain, uses abstract syntax tree parsing technology to decompose the code structure, identifies the logical relationships between functions, interfaces and variables, and obtains a code semantic dataset. The function impact localization module uses graph neural network algorithms to analyze the dependencies between codes, constructs a function association graph, and determines the impact path of code changes on system functions; The evolution path generation module, based on the functional association diagram and combined with the historical commit record chain, uses a time series analysis algorithm to trace the code evolution path and generate a version evolution sequence that includes the impact of functions. The core module identification module extracts key change nodes from the version evolution sequence, uses a clustering algorithm to group the nodes, identifies the code modules that affect the core functions, and obtains the functional impact group set; The source data storage module groups the functional impact sets, generates a visual relationship diagram, maps the correspondence between code changes and functional modules, and stores it in a distributed database to obtain a queryable functional source dataset.

[0006] Furthermore, the submission record preprocessing module includes: The commit records are obtained from the version control system. Metadata containing timestamps, author information, and changes is extracted through API calls and stored as structured data. The changes in the structured data are processed using a hash algorithm to generate unique identifiers, resulting in a tagged commit dataset. If duplicate unique identifiers exist in the marked submission dataset, the duplicate records are deduplicated, and the records with more recent timestamps are retained to obtain the deduplicated submission dataset. Based on the timestamps in the deduplicated submission dataset, the records are sorted by time series to generate an ordered submission dataset. By analyzing the author information in the ordered submission dataset, the submission frequency of each author is counted to obtain the author submission distribution dataset. Based on the submission frequency of a certain author in the author submission distribution dataset, priority is marked to obtain the submission record dataset marked with priority.

[0007] Furthermore, the blockchain trusted storage module includes: Based on the core information of each record in the priority-marked submission record dataset, the SHA-256 algorithm is used to perform hash operations to generate a unique hash value corresponding to each record, resulting in a record hash set. The record hash set is then distributed and stored to multiple blockchain nodes through a distributed ledger protocol, thus constructing a distributed storage hash ledger. The consensus mechanism of proof-of-work is used to verify the consistency of the distributed hash ledger stored on each node. After the verification is successful, the consensus-verified ledger is obtained. The consensus-verified ledger is linked to the existing record chain to obtain an immutable commit record chain.

[0008] Furthermore, the code semantic parsing module includes: Retrieve code change data from the commit record chain, extract commit logs through the version control system interface, parse the log content, process the code file using an abstract syntax tree parser, decompose the code structure, and generate a syntax tree node set containing functions, interfaces, and variables; Extract function definitions, interface declarations, and variable declarations from the syntax tree node set, analyze the calls and dependencies between nodes to obtain a logical association set, extract function call chains, interface implementation paths, and variable reference paths from the logical association set, and construct a relationship graph using a graph traversal algorithm to obtain a code semantic relationship set; Clustering algorithms are used to group functions, interfaces, and variables to generate semantic group sets. Change frequency and dependency strength within each group are extracted. Combined with preset weighting rules, the change frequency and dependency strength are weighted to determine the semantic association weights within and between each semantic group, forming a semantic weighted dataset. The semantic weighted dataset is then standardized and converted to generate a code semantic dataset.

[0009] Furthermore, the function affecting the positioning module includes: A code dependency matrix is ​​constructed based on the code semantic dataset. A graph neural network is used to iteratively update the matrix to obtain a code dependency graph. The association weights between nodes are extracted from the code dependency graph to generate a functional association graph. The association strength between functional modules is determined by the weight values. Input code change data based on the functional association diagram, calculate the propagation path of the change association diagram, obtain the set of affected functional nodes, analyze the dependency hierarchy between nodes, and judge the impact path of code change based on preset weight thresholds to determine the impact path of code change on system function.

[0010] Furthermore, the evolution path generation module includes: By obtaining historical commit records through the version control system, constructing a commit record chain, determining the commit timestamp and changes, and using time series analysis algorithms to process the time series data in the commit record chain, a time trend of code changes is generated, and the code evolution path is obtained. Functional modules are divided by functional association diagram, and the dependencies between modules are analyzed by combining code evolution paths to determine the scope of changes to functional modules. If there are dependencies between modules, the impact of code changes on functional modules is evaluated by functional impact analysis algorithm to generate a functional impact set. Based on the set of functional impacts and the code evolution path, the version dependencies are integrated to generate a version evolution sequence. By analyzing the functional changes between versions through the version evolution sequence, key nodes in the version dependencies are extracted to obtain a version evolution sequence containing functional impacts.

[0011] Furthermore, the core module identification module includes: The commit logs and code differences are obtained from the version evolution sequence. Key change nodes are extracted using text parsing to obtain a set of change nodes. The nodes are then grouped using the K-means clustering algorithm to obtain a set of node groups. Extract nodes related to the core functions from the node group set, use static code analysis to determine the associated code modules, analyze the calling relationship between modules, and use graph analysis algorithm to construct a functional dependency graph to obtain the functional dependency set; If there are cross-module calls in the functional dependency set, the scope of functional impact is determined through dependency path analysis, the set of impact scopes is obtained, overlapping functional impact scopes are merged, and the functional impact grouping set is generated by set operations.

[0012] Furthermore, the traceability data storage module includes: Obtain the group set affected by the function from the code change record, extract the commit log using the version control system interface, parse the changed file paths and modified content in the log, and determine the group set affected by the function. The association rule mining algorithm is used to analyze the correspondence between code changes and functional modules, generate a mapping relationship dataset, extract the association strength between code changes and functional modules from the mapping relationship dataset, and generate a visual relationship graph using a graph database to store node and edge data. Based on the visualized relationship graph, if the number of nodes exceeds a preset threshold, the functional module group is divided by the community detection algorithm, generating the module association group to obtain an optimized relationship graph structure. Node and edge data are extracted from the optimized relationship graph structure and stored in a distributed database using a distributed database interface to generate an scalable functional traceability dataset. A query index is constructed, and an inverted index technique is used to generate a query structure that links modules, resulting in a queryable functional traceability dataset. User query requests are obtained, and a keyword matching algorithm is used to retrieve relevant functional modules and code change records, thus obtaining a queryable functional traceability dataset.

[0013] Furthermore, it also includes: a source traceability report generation module, which extracts query requests from the functional source traceability dataset, uses full-text indexing technology to quickly retrieve functional associations and code changes, and generates a source traceability report that includes version and functional impact.

[0014] Furthermore, the source tracing report generation module includes: The query request is obtained from the functional traceability dataset. The function identifier and version identifier in the request are separated by parsing technology to obtain the structured query conditions. Full-text indexing technology is used to retrieve the functional associations and code changes to obtain the matching functional association set and code change set. If the function association set and the code change set are not empty, then cluster analysis is performed on the function association set, and the K-means algorithm is used to group the function associations to obtain function association groups. Change records related to each group are extracted from the code change set to obtain a subset of change records. If the subset of change records contains version information, the corresponding detailed version information is obtained through version identifier mapping, resulting in a set of version information. Based on the set of version information and the functional impact, a decision tree algorithm is used to analyze the correlation between the functional impact and the version change, obtaining the functional impact analysis results. Combining the set of version information and the subset of change records, a source tracing report containing version and functional impact is generated.

[0015] The beneficial effects of this invention are as follows: By using a blockchain trusted storage module, based on a dataset of priority-marked commit records, the system generates record hash values ​​using the SHA-256 algorithm, constructs an immutable commit record chain by combining distributed ledger storage and proof-of-work consensus mechanism, and supplements it with data encryption and integrity verification methods. This solves the problems of easily tampered metadata of commit records and insufficient data trustworthiness leading to uncertain traceability results in traditional systems. It ensures the authenticity and integrity of code commit records, clearly defines the responsibility for development results, and provides a trusted data foundation for subsequent traceability analysis. The code semantic parsing module uses abstract syntax tree parsing technology, clustering algorithms, and weighted calculations to generate a dataset with semantic relationships. Then, combined with the functional impact localization module, graph neural network algorithms are used to construct a functional relationship graph, automatically calculate change propagation paths, and identify high-priority impact paths. This solves the problems of traditional systems lacking intelligent code semantic analysis capabilities, being unable to automatically identify code logic relationships, and requiring manual tracing, which leads to low efficiency in functional tracing. It can automatically identify complex relationships such as underlying interfaces and upper-level business logic without manual intervention, helping developers quickly grasp the scope and level of functional impact of cross-version modifications, and significantly reducing the time cost of locating the functional impact of complex projects. By combining an evolution path generation module with time series analysis to trace code evolution paths, a core module identifies key nodes and locates core functional modules, a source data storage module generates a visual relationship diagram and a queryable dataset, and a source report generation module quickly retrieves and outputs source reports containing version and functional impact information, this approach constructs a full-link source tracing system. This addresses the problem of traditional systems that only record submissions on a timeline and lack functional correlation analysis, leading to difficulties in tracing code evolution paths and tracing functional impacts in high-concurrency, large-scale collaborative scenarios. It achieves full-process management covering code submission to result tracing, making the tracing process efficient and intuitive, significantly improving team collaboration efficiency and problem-solving accuracy, and meeting the tracing needs of complex projects. Attached Figure Description

[0016] To better understand and implement this application, the technical solution is described in detail below with reference to the accompanying drawings.

[0017] Figure 1 A schematic diagram of the structure of a software development results traceability and analysis system based on version control provided in Embodiment 1 of this application; Figure 2 A flowchart illustrating the code semantic parsing module in a version control-based software development results tracing and analysis system provided in Embodiment 1 of this application; Figure 3 This is a flowchart illustrating the functional impact positioning module in a version control-based software development results traceability analysis system provided in Embodiment 1 of this application. Detailed Implementation

[0018] To further illustrate the technical means and effects adopted by the present invention to achieve its intended purpose, exemplary embodiments will be described in detail below, examples of which are illustrated in the accompanying drawings. In the following description relating to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of methods and systems consistent with some aspects of this application as detailed in the appended claims.

[0019] The terminology used in this application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. The singular forms “a,” “the,” and “the” used in this application and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any or all possible combinations of one or more of the associated listed items.

[0020] The following detailed description of the specific implementation methods, features, and effects of the present invention, in conjunction with the accompanying drawings and preferred embodiments, is provided in detail.

[0021] Example

[0022] Please see Figures 1-3 This embodiment provides a software development outcome traceability and analysis system based on version control, including: The commit record preprocessing module obtains code commit records, extracts metadata containing timestamps, authors, and changes from the version control system, generates unique identifiers using a hash algorithm, and obtains the commit record dataset.

[0023] Furthermore, the submission record preprocessing module includes: The commit records are obtained from the version control system. Metadata containing timestamps, author information, and changes is extracted through API calls and stored as structured data. The changes in the structured data are processed using a hash algorithm to generate unique identifiers, resulting in a tagged commit dataset. If duplicate unique identifiers exist in the marked submission dataset, the duplicate records are deduplicated, and the records with more recent timestamps are retained to obtain the deduplicated submission dataset. Based on the timestamps in the deduplicated submission dataset, the records are sorted by time series to generate an ordered submission dataset. By analyzing the author information in the ordered submission dataset, the submission frequency of each author is counted to obtain the author submission distribution dataset. Based on the submission frequency of a certain author in the author submission distribution dataset, priority is marked to obtain the submission record dataset marked with priority.

[0024] Specifically, by obtaining code commit records from the version control system and extracting key metadata (timestamps, author information, and changes), and using a hash algorithm to generate unique identifiers for the changes, the problem of uniqueness and accuracy of commit records is effectively solved. This not only improves the efficiency of data processing but also enhances the reliability and usability of the data, laying a solid foundation for the traceability analysis of software development results.

[0025] The blockchain trusted storage module uses blockchain technology to store the hash value of each submission record in a distributed ledger based on the submission record dataset. The integrity of the records is verified through a consensus mechanism to obtain an immutable chain of submission records.

[0026] Furthermore, the blockchain trusted storage module includes: Based on the core information of each record in the priority-marked submission record dataset (including key fields such as change content, marked priority, and timestamp), the SHA-256 algorithm is used to perform hash operations to generate a unique hash value for each record, resulting in a record hash set. This record hash set is then distributed and stored to multiple blockchain nodes through a distributed ledger protocol, thus constructing a distributed hash ledger. The consensus mechanism of proof-of-work is used to verify the consistency of the distributed hash ledger stored on each node. After the verification is successful, the consensus-verified ledger is obtained. The consensus-verified ledger is linked to the existing record chain to obtain an immutable commit record chain.

[0027] Specifically, by storing the hash value of the commit record in a distributed ledger and verifying it using a proof-of-work consensus mechanism, the problem of easily tampered commit records and insufficient data credibility in existing version control systems is effectively solved. This not only ensures the immutability of the commit record but also enhances the security and reliability of the data through distributed storage, providing a highly reliable data foundation for the traceability analysis of software development results and ensuring the authenticity of development results and the clarity of responsibility attribution.

[0028] The code semantic parsing module extracts code change content from the immutable commit record chain, uses abstract syntax tree parsing technology to decompose the code structure, identifies the logical relationships between functions, interfaces and variables, and obtains a code semantic dataset.

[0029] Furthermore, the code semantic parsing module includes: S11. Obtain code change data from the commit record chain, extract commit logs through the version control system interface, parse the log content, process the code file using an abstract syntax tree parser, decompose the code structure, and generate a syntax tree node set containing functions, interfaces, and variables. S12. Extract function definitions, interface declarations, and variable declarations from the syntax tree node set, analyze the calls and dependencies between nodes to obtain a logical association set, extract function call chains, interface implementation paths, and variable reference paths from the logical association set, and construct a relationship graph through a graph traversal algorithm to obtain a code semantic relationship set; S13. Based on the code semantic relationship set, clustering algorithms are used to group functions, interfaces, and variables to generate semantic group sets. The change frequency (i.e., the number of times code elements in the group have been modified in historical commits) and dependency strength (i.e., the tightness of mutual calls and dependencies between elements in the group) within each group are extracted. Combined with preset weight allocation rules, the change frequency and dependency strength are weighted (e.g., assigning higher weight to change frequency according to business needs, or setting weight coefficients according to the degree of influence of both on semantic association). The semantic association weights within and between each semantic group are determined to form a semantic weighted dataset. The semantic weighted dataset is then standardized and converted to a standard format to generate a code semantic dataset.

[0030] The preset weighting rules assign different weights to change frequency and dependency strength based on business needs and the characteristics of semantic association in the code. For example, in some business scenarios, change frequency may be more critical to the judgment of the impact on the function, so change frequency will be assigned a higher weight. In other scenarios, dependency strength may better reflect the tightness between code elements, so the weight coefficients will be set according to the degree of influence of both on semantic association.

[0031] Specifically, when implementing the weighted calculation of change frequency and dependency strength, the weight coefficients are first determined based on business requirements or historical data analysis. For example, if business requirements emphasize code stability, a higher weight (e.g., 0.7) might be assigned to change frequency, while a lower weight (e.g., 0.3) might be assigned to dependency strength. The weight coefficients are set based on the degree of influence of both on semantic relationships, derived through expert experience or data analysis. Then, for each semantic group, the weighted sum of its change frequency and dependency strength is calculated, i.e., total weight = change frequency × weight coefficient 1 + dependency strength × weight coefficient 2. This calculation quantifies the semantic relationship weights within and between each semantic group, providing a more accurate basis for subsequent functional impact analysis and helping developers better understand and evaluate the impact of code changes on system functionality.

[0032] Specifically, by extracting code changes from an immutable commit history chain and using abstract syntax tree (AST) parsing technology to decompose the code structure and identify the logical relationships between functions, interfaces, and variables, this addresses the lack of intelligent semantic analysis capabilities in existing version control systems. Clustering algorithms are used to group code elements, and weighted calculations are performed based on change frequency and dependency strength to create a semantically weighted dataset. This enables the system to automatically identify the complex logical connections behind code changes, such as the impact of underlying interface modifications on upper-level business logic, thereby improving the efficiency and accuracy of functional traceability. Finally, the code semantic dataset generated through standardized format conversion provides precise data support for subsequent functional impact analysis and evolution path tracing, allowing developers to quickly understand the impact of cross-version modifications on system functionality and significantly improving the efficiency and accuracy of software development outcome tracing.

[0033] The Functional Impact Localization Module uses a graph neural network algorithm to analyze the dependencies between code segments based on the code semantic dataset, constructs a functional association graph, and determines the impact path of code changes on system functions.

[0034] Furthermore, the function affecting the positioning module includes: S21. Construct a code dependency matrix based on the code semantic dataset, and use a graph neural network to iteratively update the matrix to obtain a code dependency graph that accurately reflects the relationship between code elements. Extract the association weights between nodes (corresponding functions, interfaces, and other code elements) from the code dependency graph to generate a functional association graph. Determine the association strength between functional modules through the weight values. The process involves constructing an initial graph structure based on a code semantic dataset, using code elements (such as functions, interfaces, and variables) as nodes and their calls and dependencies as edges. A code dependency matrix is ​​then built, with rows and columns corresponding to nodes and element values ​​representing the strength of dependencies between nodes. The code dependency matrix and the initial feature vectors of the nodes are then input into a graph neural network (GNN). In the GNN, through a multi-round iterative message passing process, each node aggregates information from its neighbors to update its own feature representation, thereby capturing more complex dependencies and contextual information. After a predetermined number of iterations, the association weights between nodes are recalculated based on the updated node feature representations, generating a code dependency graph that accurately reflects the relationships between code elements. Finally, the association weights between nodes are extracted from the code dependency graph to construct a functional association graph, where the edge weights represent the strength of associations between functional modules, providing a basis for subsequent functional impact analysis.

[0035] The specific formula for the iterative update of a graph neural network is expressed as follows: ,in, It is an updated representation of new features. It is a node The set of neighboring nodes, It is the normalization coefficient. and It consists of a learnable weight matrix and bias terms. It is a non-linear activation function. Indicates initial features, Represents a node A neighboring node, that is, a node directly connected to node v.

[0036] S22. Input code change data according to the functional association diagram, calculate the propagation path of the change association diagram, filter out the functional nodes that are directly or indirectly affected by the change, obtain the set of affected functional nodes, analyze the dependency hierarchy between nodes (such as the hierarchical relationship between the underlying interface nodes and the upper-level business function nodes), and judge the code change impact path in combination with the preset weight threshold. If the weight of a certain path exceeds the threshold, mark it as a high-priority impact path to determine the impact path of the code change on the system function.

[0037] Specifically, by applying graph neural network algorithms to analyze dependencies in the code semantic dataset, constructing a functional association graph, and determining the impact path of code changes on system functions, this solves the problem that existing version control systems have difficulty in quickly and accurately tracking the impact of code changes on system functions. It realizes automated and precise analysis of the impact of code changes, enabling developers to quickly locate the specific impact of changes on system functions, significantly improving the efficiency of problem investigation and function optimization, and enhancing the traceability and controllability of the software development process.

[0038] The evolution path generation module, based on the functional association diagram and combined with the historical commit record chain, uses a time series analysis algorithm to trace the code evolution path and generate a version evolution sequence that includes the impact of functions.

[0039] Furthermore, the evolution path generation module includes: By obtaining historical commit records through the version control system, constructing a commit record chain, determining the commit timestamp and changes, and using time series analysis algorithms to process the time series data in the commit record chain, a time trend of code changes is generated, and the code evolution path is obtained. Functional modules are divided by functional association diagram, and the dependencies between modules are analyzed by combining code evolution paths to determine the scope of changes to functional modules. If there are dependencies between modules, the impact of code changes on functional modules is evaluated by functional impact analysis algorithm to generate a functional impact set. Based on the set of functional impacts and the code evolution path, the version dependencies are integrated to generate a version evolution sequence. By analyzing the functional changes between versions through the version evolution sequence, key nodes in the version dependencies are extracted to obtain a version evolution sequence containing functional impacts.

[0040] Specifically, by combining functional relationship diagrams and historical commit record chains, a time series analysis algorithm is used to track code evolution paths and generate version evolution sequences that include functional impacts. This solves the problem that existing version control systems have difficulty effectively tracking code evolution paths and analyzing functional impacts. It not only achieves accurate tracking of code evolution paths but also clearly demonstrates the propagation and changes of functional impacts. This provides software development teams with a powerful tool to analyze and manage the code evolution process, significantly improving development efficiency and code quality.

[0041] The core module identification module extracts key change nodes from the version evolution sequence, uses a clustering algorithm to group the nodes, identifies the code modules that affect the core functions, and obtains the functional impact group set.

[0042] Furthermore, the core module identification module includes: The commit logs and code differences are obtained from the version evolution sequence. Key change nodes are extracted using text parsing to obtain a set of change nodes. The nodes are then grouped using the K-means clustering algorithm to obtain a set of node groups. Extract nodes related to the core functions from the node group set, use static code analysis to determine the associated code modules, analyze the calling relationship between modules, and use graph analysis algorithm to construct a functional dependency graph to obtain the functional dependency set; If there are cross-module calls in the functional dependency set, the scope of functional impact is determined through dependency path analysis, the set of impact scopes is obtained, overlapping functional impact scopes are merged, and the functional impact grouping set is generated by set operations.

[0043] Specifically, by extracting key change nodes from the version evolution sequence and using clustering algorithms to group these nodes, the code modules that affect core functions can be accurately identified. This solves the problem that existing version control systems have difficulty effectively identifying and locating key code modules. It can not only efficiently identify code modules that have a significant impact on the core functions of the system, but also clearly show the dependencies between these modules. This provides software development teams with a powerful tool to optimize code structure, improve development efficiency, and ensure the stability and reliability of core functions.

[0044] The source data storage module generates a visual relationship diagram for the functional impact group set, maps the correspondence between code changes and functional modules, and stores it in a distributed database to obtain a queryable functional source dataset.

[0045] Furthermore, the traceability data storage module includes: Obtain the group set affected by the function from the code change record, extract the commit log using the version control system interface, parse the changed file paths and modified content in the log, and determine the group set affected by the function. For the group set of functional impacts, the association rule mining algorithm is used to analyze the correspondence between code changes and functional modules, generate a mapping relationship dataset, extract the association strength between code changes and functional modules from the mapping relationship dataset, and use a graph database to generate a visual relationship graph, store node and edge data, and obtain the visual relationship graph. For the visualized relationship graph, if the number of nodes exceeds a preset threshold, the functional module group is divided by the community detection algorithm, the module association group is generated, and the optimized relationship graph structure is obtained. Node and edge data are extracted from the optimized relationship graph structure and stored in the distributed database using the distributed database interface to generate an scalable functional traceability dataset. For the functional traceability dataset, a query index is constructed, and an inverted index technique is used to generate a query structure that links modules, resulting in a queryable functional traceability dataset. User query requests are obtained, and a keyword matching algorithm is used to retrieve relevant functional modules and code change records, thus obtaining a queryable functional traceability dataset.

[0046] Specifically, by generating a visual relationship diagram and storing it in a distributed database, efficient management and querying of functional impact groups are achieved. This solves the problems of unclear correspondence between code changes and functional modules, non-scalable data storage, and low query efficiency in existing version control systems. It not only clearly shows the correspondence between code changes and functional modules, but also ensures data scalability and query efficiency through distributed storage and efficient query technology. This provides software development teams with a powerful traceability analysis tool, significantly improving development and maintenance efficiency.

[0047] Furthermore, it also includes: a source traceability report generation module, which extracts query requests from the functional source traceability dataset, uses full-text indexing technology to quickly retrieve functional associations and code changes, and generates a source traceability report that includes version and functional impact.

[0048] Furthermore, the source tracing report generation module includes: The query request is obtained from the functional traceability dataset. The function identifier and version identifier in the request are separated by parsing technology to obtain the structured query conditions. Full-text indexing technology is used to retrieve the functional associations and code changes to obtain the matching functional association set and code change set. If the function association set and the code change set are not empty, then cluster analysis is performed on the function association set, and the K-means algorithm is used to group the function associations to obtain function association groups. Change records related to each group are extracted from the code change set to obtain a subset of change records. If the subset of change records contains version information, the corresponding detailed version information is obtained through version identifier mapping, resulting in a set of version information. Based on the set of version information and the functional impact, a decision tree algorithm is used to analyze the correlation between the functional impact and the version change, obtaining the functional impact analysis results. Combining the set of version information and the subset of change records, a source tracing report containing version and functional impact is generated.

[0049] Specifically, by extracting query requests from the functional source traceability dataset and using full-text indexing technology to quickly retrieve functional associations and code changes, a source traceability report containing version and functional impact is generated. This solves the problems of low query efficiency and difficulty in generating detailed source traceability reports in existing version control systems. It not only improves query efficiency but also generates detailed and structured source traceability reports, providing software development teams with a powerful tool to quickly locate and analyze the impact of code changes on system functions, significantly improving development and maintenance efficiency.

[0050] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention in any way. Although the present invention has been disclosed above with reference to preferred embodiments, it is not intended to limit the present invention. Any person skilled in the art can make some modifications or alterations to the above-disclosed technical content to create equivalent embodiments without departing from the scope of the present invention. Any simple modifications, equivalent changes and alterations made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the scope of the present invention.

Claims

1. A version control based software development artifact provenance analysis system, characterized by: The application relates to a code evolution path tracing method based on blockchain, which comprises the following steps: a submission record preprocessing module is used to obtain code submission records, metadata containing timestamps, authors and change contents are extracted from a version control system, a unique identifier is generated by using a hash algorithm, and a submission record dataset is obtained; a blockchain trusted storage module is used to store the hash value of each submission record in a distributed ledger by using a blockchain technology according to the submission record dataset, the record integrity is verified by using a consensus mechanism, and an unalterable submission record chain is obtained; a code semantic analysis module is used to extract code change contents from the unalterable submission record chain, the code structure is decomposed by using an abstract syntax tree analysis technology, the logical relationship of functions, interfaces and variables is identified, and a code semantic dataset is obtained; a function influence positioning module is used to analyze the dependence relationship between codes by using a graph neural network algorithm, a function correlation graph is constructed, and the influence path of code change on system functions is determined; an evolution path generation module is used to track the code evolution path by using a time series analysis algorithm according to the function correlation graph and in combination with the historical submission record chain, and a version evolution sequence containing function influences is generated; a core module identification module is used to extract key change nodes from the version evolution sequence, the nodes are grouped by using a clustering algorithm, code modules influencing core functions are identified, and a function influence grouping set is obtained; a traceability data storage module is used to generate a visual relationship graph according to the function influence grouping set, map the corresponding relationship between code changes and function modules, store the relationship in a distributed database, and obtain a queryable function traceability dataset.

2. The version control based software development artifact traceability analysis system of claim 1, wherein: The submission record preprocessing module comprises the following steps: submission records are obtained from a version control system, metadata containing timestamps, author information and change contents are extracted by using an interface call, the metadata are stored as structured data, the change contents in the structured data are processed by using a hash algorithm, a unique identifier is generated, and a marked submission dataset is obtained; if there are repeated unique identifiers in the marked submission dataset, the repeated records are removed, a deduplicated submission dataset is obtained, the records are time series sorted according to the timestamps in the deduplicated submission dataset, and an ordered submission dataset is generated; the submission frequency of each author is counted by analyzing the author information in the ordered submission dataset, an author submission distribution dataset is obtained, the submission frequency of a certain author in the author submission distribution dataset is marked according to the priority, and a submission record dataset with priority marking is obtained.

3. The version control based software development artifact traceability analysis system of claim 1, wherein: The blockchain trusted storage module comprises the following steps: SHA-256 algorithm is used to perform hash operation on the core information of each record in the submission record dataset with priority marking, a unique hash value corresponding to each record is generated, a record hash set is obtained, the record hash set is distributed and stored in a plurality of blockchain nodes by using a distributed ledger protocol, and a distributed storage hash ledger is constructed; consistency verification is performed on the distributed hash ledger stored in each node by using a proof of work consensus mechanism, the ledger is verified, and an unalterable submission record chain is obtained.

4. The version control based software development artifact traceability analysis system of claim 1, wherein: ​ Code change data is obtained from a commit record chain, commit logs are extracted through a version control system interface, log content is parsed, an abstract syntax tree parser is used to process code files, code structure is decomposed, and a syntax tree node set containing functions, interfaces and variables is generated; Function definitions, interface declarations and variable declarations in the syntax tree node set are extracted, call and dependency relationships between nodes are analyzed, a logical association set is obtained, function call chains, interface implementation paths and variable reference paths are extracted from the logical association set, a relationship graph is constructed through a graph traversal algorithm, and a code semantic relationship set is obtained; A clustering algorithm is used to group functions, interfaces and variables, a semantic grouping set is generated, change frequency and dependency strength within each group are extracted, change frequency and dependency strength are weighted according to a preset weight distribution rule, semantic association weights within and between each semantic group are determined, a semantic weighted data set is formed, and the semantic weighted data set is converted into a standard format to generate a code semantic data set.

5. The version control based software development artifact traceability analysis system of claim 1, wherein: The function impact positioning module comprises: A code dependency relationship matrix is constructed according to the code semantic data set, the matrix is iteratively updated using a graph neural network, a code dependency graph is obtained, association weights between nodes are extracted from the code dependency graph, a function association graph is generated, and the association strength between function modules is determined by the weight values; Code change data is input according to the function association graph, the propagation path of the change association graph is calculated, the set of affected function nodes is obtained, the dependency level between nodes is analyzed, and the code change impact path is judged according to a preset weight threshold to determine the impact path of the code change on the system function.

6. The version control based software development artifact traceability analysis system of claim 1, wherein: The evolution path generation module comprises: Historical commit records are obtained through a version control system, a commit record chain is constructed, commit timestamps and change content are determined, time series data in the commit record chain is processed using a time series analysis algorithm, a time trend of code changes is generated, and a code evolution path is obtained; Function modules are divided through the function association graph, the dependency relationship between modules is analyzed in combination with the code evolution path, the change range of the function module is determined, and if there is a dependency relationship between the modules, the impact of the code change on the function module is evaluated through a function impact analysis algorithm to generate a function impact set; According to the function impact set and the code evolution path, the version dependency relationship is integrated to generate a version evolution sequence, the function changes between versions are analyzed through the version evolution sequence, key nodes in the version dependency relationship are extracted, and a version evolution sequence containing function impact is obtained.

7. The version control based software development artifact provenance analysis system of claim 1, wherein: The core module recognition module comprises: Commit logs and code differences are obtained from the version evolution sequence, key change nodes are extracted using text parsing to obtain a change node set, and the nodes are grouped using a K-means clustering algorithm to obtain a node grouping set; Nodes related to the core function are extracted from the node grouping set, associated code modules are determined using static code analysis, the call relationship between modules is analyzed, a function dependency graph is constructed using a graph analysis algorithm, and a function dependency set is obtained. If the function dependency set contains cross-module calls, the function impact range is determined by dependency path analysis, the impact range set is obtained, overlapping function impact ranges are merged, and the function impact grouping set is generated by set operation.

8. The version control based software development artifact traceability analysis system of claim 1, wherein: The traceability data storage module comprises: The grouping set of function impacts is obtained from the code change record, the commit log is extracted using a version control system interface, the changed file path and modification content in the log are parsed, and the grouping set of function impacts is determined. The corresponding relationship between code changes and function modules is analyzed using an association rule mining algorithm to generate a mapping relationship dataset, the association strength between code changes and function modules is extracted from the mapping relationship dataset, a visual relationship graph is generated using a graph database to store node and edge data, and the visual relationship graph is obtained. According to the visual relationship graph, if the number of nodes exceeds a preset threshold, the function module group is divided by a community detection algorithm to generate module association grouping, and the optimized relationship graph structure is obtained. The node and edge data are extracted from the optimized relationship graph structure, stored in a distributed database using a distributed database interface, and an extensible function traceability dataset is generated.

9. The version control based software development artifact traceability analysis system of claim 1, wherein: An inverted index technology is used to generate a module association query structure to obtain a queryable function traceability dataset, and a user query request is obtained. The function traceability dataset is obtained by using a keyword matching algorithm to retrieve related function modules and code change records.

10. The version control based software development artifact provenance analysis system of claim 9, wherein: The traceability report generation module comprises: The traceability report generation module comprises: The query request is extracted from the function traceability dataset, full-text indexing technology is used to quickly search for function associations and code changes, and a traceability report containing versions and function impacts is generated. The traceability report generation module comprises: The query request is obtained from the function traceability dataset, the function identifier and version identifier in the request are separated using parsing technology to obtain structured query conditions, function associations and code changes are searched using full-text indexing technology, and the matching function association set and code change set are obtained. If the function association set and code change set are not empty, the function association set is clustered and analyzed, the function associations are grouped using the K-means algorithm, the function association grouping is obtained, the change records related to each grouping are extracted from the code change set, and the change record subset is obtained. If the change record subset contains version information, the corresponding version details are obtained by version identifier mapping to obtain the version information set, the association between function impacts and version changes is analyzed using a decision tree algorithm based on the version information set and function impacts to obtain function impact analysis results, and a traceability report containing versions and function impacts is generated based on the version information set and the change record subset.

Citation Information

Cited By

  • Software design intention inference and document generation method, device and system

    CN122086460A

  • Software design intent inference and documentation generation method, apparatus, and system

    CN122086460B

  • Development man-hour estimation method and system based on function dependence graph

    CN122114881A

  • Software research and development operation behavior whole-process evidence storage and traceability method, system, device and storage medium

    CN122389027A