Large model test case intelligent generation system based on big data

By building a hypergraph structure and combining hypergraph neural network optimization, high-quality test cases are generated, which solves the problem that traditional test case generation systems cannot deeply explore the system interaction logic and early intervention, and achieves efficient and reliable test case generation throughout the process.

CN120448285AActive Publication Date: 2025-08-08JINAN YUANGEN TECH CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202510948805.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-10
Publication Date
2025-08-08
Estimated Expiration
2045-07-10

AI Technical Summary

Technical Problem

Traditional test case generation systems cannot deeply explore the interactive logic and business rules between the system modules, resulting in incomplete coverage of test cases and ineffective intervention in the early stages of software development, increasing the cost of later repairs.

Method used

Multi-source heterogeneous data perception and structured analysis units are used to collect requirements documents and system codes, build hypergraph structures, connect data nodes through hypergraph topological relationship construction and semantic enhancement units, and combine cross-modal feature extraction and deep fusion units to extract and fuse text and code features. Hypergraph neural network optimization iteration and use case clustering unit optimization test case framework, and finally generate high-quality test cases through test case verification and output units.

Benefits of technology

It realizes the generation of high-quality and comprehensive test cases in the entire software development process, ensures that the test cases are closely related to the system design, improves the testing efficiency and accuracy, and avoids the limitations of traditional systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120448285A_ABST
    Figure CN120448285A_ABST
Patent Text Reader

Abstract

The invention discloses an intelligent generation system for a large model test case based on big data, which is characterized in that data such as a demand document and a system code are acquired and structured through a multi-source heterogeneous data perception and structured analysis unit, and are constructed into a hypergraph structure through a hypergraph topological relation construction and semantic enhancement unit, and the relation between the data is deeply mined; the cross-modal feature joint extraction and deep fusion unit extracts and fuses multi-modal features such as texts and codes; a test case framework generation and parameter association unit generates a basic framework and associates test parameters; the hypergraph neural network optimization iteration and case refining unit refines a test case by optimizing a hypergraph neural network; and finally, the test case verification and output unit verifies and outputs. According to the method, it is ensured that the output test case has high quality and high reliability, an efficient, comprehensive and reliable solution is provided for large model software testing, and the testing efficiency and accuracy are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the fields of artificial intelligence and software testing, and in particular to a large-scale model test case intelligent generation system based on big data. Background Art

[0002] Driven by the wave of digital transformation, large language model (LLM) technologies such as GPT and BERT have achieved breakthroughs. Their superior natural language understanding and generation capabilities have brought new development opportunities to the field of software testing. Generating basic test scenarios based on text descriptions has become an important exploration direction for software test automation. However, with the increasing complexity of software systems, traditional test case generation methods are no longer able to meet the requirements of efficient and accurate testing. More intelligent and advanced solutions are urgently needed to ensure the quality and reliability of software products.

[0003] Current traditional test case generation has obvious limitations. On the one hand, when dealing with the relationship between requirement documents and system designs, existing methods are unable to deeply explore the complex interaction logic and business rules between the various modules of the system, and only stay at the surface of information processing. As a result, the generated test cases are difficult to fully cover the software functions and cannot effectively identify potential design defects and logical loopholes. On the other hand, when responding to the testing needs of the entire software development process, some test case generation systems are highly dependent on the system code that has been developed. In the early stages of software development, when the code is not yet formed, it cannot play a role, making it difficult for testing work to intervene in the early stages of the development process, unable to discover problems in time, increasing the cost of later repairs, and seriously affecting the overall efficiency and quality control of software development. Summary of the Invention

[0004] In order to overcome the shortcomings and deficiencies of the existing technology, the present invention provides a large model test case intelligent generation system based on big data.

[0005] The technical solution adopted by the present invention is a system for intelligently generating large-model test cases based on big data, comprising: The multi-source heterogeneous data perception and structured parsing unit is used to collect multi-source data such as requirement documents and system codes and parse them into structured data. The hypergraph topology relationship construction and semantic enhancement unit constructs structured data into a hypergraph structure, connects different data nodes through hyperedges and enhances semantic expression. The cross-modal feature joint extraction and deep fusion unit extracts text and code cross-modal features from the hypergraph structure and performs deep fusion. The test case framework generation and parameter association unit generates a basic test case framework based on the fused features and associates software test parameters. The hypergraph neural network optimization iteration and use case clustering unit iteratively optimizes the basic framework through the optimized hypergraph neural network and clusters test cases. The test case verification and output unit verifies the clustered test cases and outputs the final results. The output end of the multi-source heterogeneous data perception and structured parsing unit is connected to the input end of the hypergraph topology relationship construction and semantic enhancement unit, the output end of the hypergraph topology relationship construction and semantic enhancement unit is connected to the input end of the cross-modal feature joint extraction and deep fusion unit, the output end of the cross-modal feature joint extraction and deep fusion unit is connected to the input end of the test case framework generation and parameter association unit, the output end of the test case framework generation and parameter association unit is connected to the input end of the hypergraph neural network optimization iteration and use case clustering unit, and the output end of the hypergraph neural network optimization iteration and use case clustering unit is connected to the input end of the test case verification and output unit.

[0006] Furthermore, when the hypergraph topology relationship is constructed and the semantic enhancement unit constructs the hypergraph structure, the formula ,in, Represents a node set consisting of requirement document keyword nodes and code function nodes. Represents a set of hyperedges connecting different types of nodes. Hyperedges connect multiple nodes to represent complex relationships between data. represents the hyperedge weight matrix, whose elements For quantization nodes With node The semantic association strength when connected by hyperedges; when the cross-modal feature joint extraction and the deep fusion unit perform feature fusion, the formula is used ,in, is the fused cross-modal feature vector, is the text feature vector extracted from the text node in the hypergraph, is the code feature vector extracted from the code node in the hypergraph, and The fusion coefficient is dynamically adjusted according to the feature importance in the software test parameters. The test coverage type and test priority in the software test parameters affect and The value of .

[0007] Furthermore, the cross-modal feature joint extraction and deep fusion unit uses the optimized hypergraph neural network to extract cross-modal features through the formula Update node features, where For nodes In the Feature vectors in layer hypergraph neural networks, is the activation function, For the node The set of connected hyperedges, is the number of hyperedges in the set, For nodes With node Hyperedge weights, For nodes In the The feature vector of the layer, For the Layer Hyperedge The test case framework generates a feature transformation matrix associated with the parameter association unit when the software test parameters are associated with the parameter association unit, using the formula ,in, is the associated test case parameter set, is the parameter adjustment coefficient, Based on hypergraph structure and fusion features Generated basic parameter set, test data type in software test parameters, test environment configuration impact and Calculation.

[0008] Furthermore, when the hypergraph neural network optimization iteration and the use case clustering unit optimize the hypergraph neural network, the formula is used ,in, are the optimized hypergraph neural network parameters, is the parameter to be optimized, is the number of training samples, For the The loss function of each sample is used to build the loss calculation rules based on the test case completeness and test step accuracy in the software test parameters; when clustering test cases, the formula is used. ,in, is the clustered test case, As the basic test case framework, The use case adjustment amount calculated by the optimized hypergraph neural network, the test depth requirement and test complexity index in the software test parameters Calculation.

[0009] Furthermore, when the cross-modal feature joint extraction and the deep fusion unit perform cross-modal feature extraction, the formula is also used. ,in, is the code modal eigenvector, is the number of code feature dimensions, is the weight of the k-th dimension code feature, is the code feature value of the kth dimension, the code coverage and code logic complexity in the software test parameters The value of the test case framework generation and parameter association unit generates the test case framework using the formula ,in, For the generated test case framework, is the framework generation function, H is the hypergraph structure, is the code modal eigenvector, is the text modal feature vector, the test type and test target influence in the software test parameters The operation process.

[0010] Furthermore, when the hypergraph topology relationship is constructed and the semantic enhancement unit enhances the semantic expression, the formula is used. , where S is the overall semantic enhancement vector of the hypergraph, For nodes The semantic contribution weight of For nodes Initial semantic vector, node importance and node correlation in software testing parameters Calculation; When the cross-modal feature joint extraction and deep fusion unit perform feature fusion, the formula is also used ,in, is the final fusion feature vector, F is the preliminary fusion feature vector, is the feature correction vector adjusted according to the hypergraph structure and software test parameters, is the correction coefficient, the feature fusion accuracy requirements in the software test parameters, and the impact of the test case quality standards and of confirmation.

[0011] Furthermore, the cross-modal feature joint extraction and deep fusion unit includes: a text feature extraction sub-unit, which is used to extract word vectors and semantic dependency text features from text nodes in the hypergraph; a code feature extraction sub-unit, which is used to extract function call relationships and code structure code features from code nodes in the hypergraph; a cross-modal feature alignment sub-unit, which aligns the extracted text features with the code features in terms of dimension and semantics based on the hypergraph structure; and a feature fusion optimization sub-unit, which optimizes and adjusts the initially fused cross-modal features according to software testing parameters.

[0012] Furthermore, the test case framework generation and parameter association unit includes: a basic framework generation sub-unit, which generates a basic test case framework including test steps and test objects based on the fused cross-modal features; a parameter mapping sub-unit, which maps the test data and test environment in the software test parameters to the corresponding parts of the basic framework; a framework verification sub-unit, which checks whether the generated test case framework complies with the software testing specifications; and a parameter association optimization sub-unit, which optimizes the associated test case parameters according to the association relationship between the software test parameters.

[0013] Furthermore, the hypergraph neural network optimization iteration and use case clustering unit includes: a network parameter initialization subunit, which assigns initial parameters to the hypergraph neural network; a training sample construction subunit, which constructs a sample set for training based on the hypergraph structure and fusion features; a network training optimization subunit, which uses an optimization algorithm to train the hypergraph neural network and update the network parameters; and a use case clustering execution subunit, which performs clustering operations on the basic test case framework based on the trained hypergraph neural network.

[0014] Beneficial effects: The present invention proposes a large-model test case intelligent generation system based on big data. The system collects and structures multi-source data such as requirement documents and system codes through a multi-source heterogeneous data perception and structured parsing unit, providing a comprehensive data foundation for subsequent processing; the hypergraph topology relationship construction and semantic enhancement unit constructs the data into a hypergraph structure, uses hyperedges to connect different nodes, and deeply mines the complex relationships between data, making up for the deficiency of traditional methods that cannot associate system design details, ensuring that the generated test cases can cover the interaction logic and business rules of each module of the system. The cross-modal feature joint extraction and deep fusion unit extracts multimodal features such as text and code from the hypergraph and fuses them. Combined with the test case framework generation and parameter association unit, it generates a basic framework based on the fused features and associates test parameters, so that the generated test cases no longer just stay on the surface information. The hypergraph neural network optimization iteration and use case refinement unit iteratively optimizes the basic framework through the optimized hypergraph neural network, refines the test cases, and improves the quality of the test cases. The test case verification and output unit verifies and outputs the final test cases to ensure accuracy. The entire system does not rely on completed system code and can intervene in the entire software development process. Starting from multi-source data and through the collaborative operation of various units, it comprehensively improves the depth, breadth and efficiency of test case generation, providing an efficient and reliable solution for large-model software testing. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] Figure 1 It is a diagram of the system unit composition of the present invention; Figure 2 This is a flow chart of the system operation of the present invention. DETAILED DESCRIPTION

[0016] It should be noted that, unless there is a conflict, the embodiments in this application and the features described in the embodiments can be combined with each other. The application is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0017] like Figure 1 As shown, a large model test case intelligent generation system based on big data includes: Multi-source heterogeneous data perception and structured parsing unit, used to collect multi-source data such as requirement documents and system code, and parse it into structured data; Specifically, the multi-source heterogeneous data perception and structured parsing unit is the primary link in the operation of the system. Its core function is to collect various types of data, such as requirement documents and system code, and convert these data into a structured form. In terms of technical parameters, the unit must have strong compatibility and be able to support the collection of requirement documents in formats such as .docx and .pdf, as well as system code written in different programming languages ​​such as Java, Python, and C++. At the same time, it must also meet the timeliness requirements of data collection and realize real-time or scheduled data collection to ensure that the acquired data can promptly reflect the latest status of the software system. The significance of this unit is to break down data barriers and integrate data scattered in different locations and stored in different formats during the software development process, providing a unified and standardized data foundation for subsequent processing, and avoiding deviations in test case generation due to confusing data formats or missing information.

[0018] During the specific implementation process, the multi-source heterogeneous data perception and structured parsing unit connects with the version control system, document management system, etc. of the software development project by deploying a specific data collection interface. For the requirements document, the unit will identify the structural information such as titles, paragraphs, lists, etc., and extract the key requirements descriptions; for the system code, it will parse the syntax units such as function definitions, class structures, and variable declarations in the code. Then, using data structuring technology, the collected data is converted into a format that is easy for computers to process, such as XML, JSON, or a specific data table structure. During the conversion process, the key information in the data is marked and classified to provide standardized input data for the subsequent hypergraph topology relationship construction and semantic enhancement unit, so that the system can deeply explore the intrinsic connections between the data based on these structured data.

[0019] The hypergraph topology relationship construction and semantic enhancement unit constructs structured data into a hypergraph structure, connects different data nodes through hyperedges, and enhances semantic expression; Specifically, the main function of the hypergraph topology relationship construction and semantic enhancement unit is to construct structured data into a hypergraph structure, connect different data nodes through hyperedges, so as to represent the complex many-to-many relationship between data and enhance the semantic expression of data. In terms of technical parameters, this unit needs to accurately control the generation rules of hypergraph nodes and hyperedges to ensure that the hypergraph structure can accurately reflect the logical relationship of the data. For example, for the generation of nodes, reasonable abstraction should be carried out according to the data type and importance; for the construction of hyperedges, the correlation strength and semantic association between data nodes need to be accurately judged. The significance of this unit is to transform the originally planar and isolated structured data into a hypergraph with a three-dimensional topological structure, so that the complex semantic relationship between data can be made explicit, providing a richer and deeper information basis for subsequent cross-modal feature extraction and fusion, thereby improving the comprehensiveness and accuracy of test case generation.

[0020] In specific implementation, the hypergraph topology relationship construction and semantic enhancement unit first abstracts the functional requirements, business process descriptions in the requirements document, and functions and classes in the system code into nodes of the hypergraph based on the type and source of the data. Then, by analyzing the context and logical association of the data, multiple related nodes are connected using hyperedges. For example, when a functional requirement in the requirements document corresponds to multiple function implementations in the system code, the node representing the functional requirement is connected to these function nodes through hyperedges. After constructing the hypergraph structure, the unit will further perform semantic enhancement processing on the nodes and hyperedges, and assign different weights and semantic labels to the nodes and hyperedges based on factors such as the importance and frequency of occurrence of the data, so that the hypergraph structure can more accurately express the semantic information of the data, laying the foundation for subsequent units to deeply understand and process the data.

[0021] Cross-modal feature joint extraction and deep fusion unit extracts text and code cross-modal features from the hypergraph structure and performs deep fusion; Specifically, the cross-modal feature joint extraction and deep fusion unit undertakes the important task of extracting different modal features such as text and code from the hypergraph structure and deeply fusing these features. In terms of technical parameters, it requires an efficient feature extraction algorithm that can extract text features such as word vectors and semantic dependencies from the text nodes of the hypergraph, and extract code features such as function call relationships and code structures from the code nodes. At the same time, for the feature fusion process, it is necessary to precisely control the method and degree of fusion to ensure that the fused features can fully retain the key information of each modality and have good distinguishability. The significance of this unit is to integrate the feature information of different modal data in the software system, break the barriers between modalities, form more comprehensive and representative comprehensive features, and provide a richer and more valuable basis for the generation of test case frameworks, thereby generating test cases that are more in line with the actual needs of the system.

[0022] During the specific implementation process, the cross-modal feature joint extraction and deep fusion unit first uses natural language processing technology to perform word segmentation, part-of-speech tagging, syntactic analysis and other operations on the text content for the text nodes in the hypergraph, and extracts text features such as word vectors and semantic roles. For code nodes, static code analysis technology is used to parse the syntax tree of the code and extract code features such as function call hierarchy, variable scope, and code logical structure. After extracting features of different modalities, the unit adopts a specific fusion strategy to integrate text features and code features. For example, through weighted summation, feature splicing, etc., the features of the two modalities are combined into a new cross-modal feature vector. During the fusion process, the fusion weights will be dynamically adjusted according to the importance of different features in the software test parameters, so that the fused features can better meet the needs of test case generation and provide high-quality feature input for the construction of the subsequent test case framework.

[0023] The test case framework generation and parameter association unit generates a basic test case framework based on the fused features and associates software test parameters; Specifically, the function of the test case framework generation and parameter association unit is to generate a basic test case framework based on the fused cross-modal features and associate the software test parameters with the framework. In terms of technical parameters, it needs to have a flexible framework generation algorithm that can generate a variety of test case frameworks containing elements such as test steps, test objects, and expected results according to different system types and test requirements. At the same time, for the association of software test parameters, it is necessary to accurately identify the correspondence between the parameters and the various elements of the framework to ensure that the parameters can be reasonably integrated into the test case framework. The significance of this unit is to transform abstract cross-modal features into specific test case frameworks, and combine them with software test parameters to make test cases more targeted and executable, providing basic framework support for the subsequent refinement of test cases and actual test execution.

[0024] During specific implementation, the test case framework generation and parameter association unit first analyzes the system's functional modules and business processes based on the fused cross-modal features to determine the basic framework structure of the test case. For example, based on the system functional points reflected in the features, a framework containing multiple test steps is generated, and each step corresponds to a specific test operation. Then, for software test parameters, such as test data type, test environment configuration, test priority, etc., they are mapped one by one to the corresponding positions in the test case framework. For example, the test data type is associated with the input data part in the test step, and the execution conditions of the test case are determined according to different test environment configurations. During the association process, the unit will also check and adjust the parameters for rationality to ensure that the test case framework has practical operability while meeting the test requirements, providing a complete basic test case framework for subsequent hypergraph neural network optimization iteration and use case refinement units.

[0025] Hypergraph neural network optimization iteration and use case clustering unit, which iteratively optimizes the basic framework through the optimized hypergraph neural network and clusters test cases; Specifically, the hypergraph neural network optimization iteration and use case refinement unit iteratively optimizes the basic test case framework through the optimized hypergraph neural network to achieve test case refinement. In terms of technical parameters, this unit requires the hypergraph neural network to have good learning and generalization capabilities, and to be able to adjust network parameters to optimize the test case framework according to the actual needs of software testing. At the same time, reasonable iteration termination conditions need to be set, such as reaching a certain number of iterations or the optimization degree of the test case meeting a specific threshold. The significance of this unit is to use the powerful data analysis and processing capabilities of the hypergraph neural network to conduct in-depth analysis and optimization of the basic test case framework, to make up for possible deficiencies in the framework, to make the test cases more comprehensive and detailed, to improve the test coverage and effectiveness of the test cases for the software system, and to ensure that potential defects and problems in the software system can be detected.

[0026] In its implementation, the Hypergraph Neural Network Optimization Iteration and Use Case Refinement Unit first assigns initial parameters to the Hypergraph Neural Network and uses the basic test case framework, along with the associated hypergraph structure and cross-modal features, as input data. The Hypergraph Neural Network is then trained using training samples. During training, a corresponding loss function is constructed based on software testing parameters regarding test case completeness and test step accuracy to assess the gap between the network's output test cases and the ideal test cases. Based on the feedback from the loss function, the network uses an optimization algorithm to adjust its parameters, continuously improving the optimization of the test case framework. After multiple iterations of training, when the set termination conditions are met, the Hypergraph Neural Network outputs an optimized test case framework. Based on this, the unit then refines the test case, supplementing it with detailed descriptions of the test steps and clarifying the specific value ranges of the test data. This makes the test cases more specific and executable, providing high-quality test cases for the actual execution of software testing.

[0027] Test case verification and output unit verifies the clustered test cases and outputs the final results; Specifically, the test case verification and output unit is the last link in the system, and its main responsibility is to verify the refined test cases and output the final test case results. In terms of technical parameters, this unit needs to have comprehensive verification rules and methods, and be able to verify from multiple dimensions such as the completeness, accuracy, and executableness of the test cases. For example, check whether the test cases cover all key test points, whether the descriptions of the test steps are clear and accurate, and whether the test data is reasonable and accessible. The significance of this unit is to ensure the quality of the output test cases, to be able to effectively detect the functions and performance of the software system in actual software testing, to avoid inaccurate or inexecutable test results due to problems with the test cases, and to provide the last line of defense for software quality assurance.

[0028] During the specific implementation process, the test case verification and output unit will first check the refined test cases one by one according to the pre-set verification rules. For the completeness of the test cases, the functional requirements and design documents of the system will be compared to confirm that all important functions and business processes are covered by corresponding test cases; for accuracy, it will check whether the logic of the test steps is correct and whether the expected results are reasonable; for executableness, it will verify whether the test data can be obtained and whether the test environment is easy to set up. If a problem is found in the test case during the verification process, the unit will feedback the problem to the Hypergraph Neural Network Optimization Iteration and Use Case Refinement Unit for correction. When the test case passes all verifications, the test case verification and output unit will output the final test case results in the specified format and requirements. These results can be directly used in the software test execution process to provide software testers with detailed and reliable testing guidance, helping to ensure the quality and stability of the software system.

[0029] The output end of the multi-source heterogeneous data perception and structured parsing unit is connected to the input end of the hypergraph topology relationship construction and semantic enhancement unit, the output end of the hypergraph topology relationship construction and semantic enhancement unit is connected to the input end of the cross-modal feature joint extraction and deep fusion unit, the output end of the cross-modal feature joint extraction and deep fusion unit is connected to the input end of the test case framework generation and parameter association unit, the output end of the test case framework generation and parameter association unit is connected to the input end of the hypergraph neural network optimization iteration and use case clustering unit, and the output end of the hypergraph neural network optimization iteration and use case clustering unit is connected to the input end of the test case verification and output unit.

[0030] Preferably, when constructing the hypergraph topology relationship and the semantic enhancement unit constructing the hypergraph structure, the formula ,in, Represents a node set consisting of requirement document keyword nodes and code function nodes. Represents a set of hyperedges connecting different types of nodes. Hyperedges connect multiple nodes to represent complex relationships between data. represents the hyperedge weight matrix, whose elements For quantization nodes With node The semantic association strength when connected by hyperedges; when the cross-modal feature joint extraction and the deep fusion unit perform feature fusion, the formula is used ,in, is the fused cross-modal feature vector, is the text feature vector extracted from the text node in the hypergraph, is the code feature vector extracted from the code node in the hypergraph, and The fusion coefficient is dynamically adjusted according to the feature importance in the software test parameters. The test coverage type and test priority in the software test parameters affect and The value of .

[0031] Specifically, when the hypergraph topology relationship construction and semantic enhancement unit constructs the hypergraph structure, it accurately depicts the complex relationships between data such as requirement document keywords and code function nodes by defining a node set, a hyperedge set, and a hyperedge weight matrix. The weight matrix quantifies the strength of the semantic association of the nodes, providing a structured semantic basis for subsequent processing. When the cross-modal feature joint extraction and deep fusion unit performs feature fusion, it dynamically adjusts the fusion coefficient of the text feature vector and the code feature vector based on the test coverage type and priority in the software test parameters, so that the fused cross-modal feature vector retains the key information of each modality and meets the focus of the test requirements. During implementation, the former abstracts data into nodes and constructs hyperedges according to the rules, while the latter first extracts text and code feature vectors separately, and then dynamically weights and fuses them according to the test parameters, ensuring that the system fits the software testing scenario from data structure construction to feature fusion, thereby improving the accuracy and pertinence of test case generation.

[0032] Preferably, the cross-modal feature joint extraction and deep fusion unit uses an optimized hypergraph neural network to extract cross-modal features through the formula Update node features, where For nodes In the Feature vectors in layer hypergraph neural networks, is the activation function, For the node The set of connected hyperedges, is the number of hyperedges in the set, For nodes With node Hyperedge weights, For nodes In the The feature vector of the layer, For the Layer Hyperedge The test case framework generates a feature transformation matrix associated with the parameter association unit when the software test parameters are associated with the parameter association unit, using the formula ,in, is the associated test case parameter set, is the parameter adjustment coefficient, Based on hypergraph structure and fusion features Generated basic parameter set, test data type in software test parameters, test environment configuration impact and Calculation.

[0033] Specifically, the cross-modal feature joint extraction and deep fusion unit uses an optimized hypergraph neural network to update node features, comprehensively capturing data features in the hypergraph structure by integrating factors such as hyperedge connection relationships, node weights, and feature transformation matrices. The test case framework generation and parameter association unit adjusts the generated basic parameter set through parameter adjustment coefficients based on the hypergraph structure and fusion features, combined with the data type and environment configuration in the software test parameters, to form an associated test case parameter set. During implementation, the former continuously optimizes node feature extraction during hypergraph neural network training, while the latter repeatedly adjusts the parameter set based on the extracted features and test parameters, so that the generated test case framework is closely associated with the actual test requirements, ensuring that the test case can effectively detect the software system functions in subsequent execution.

[0034] Preferably, when the hypergraph neural network optimization iteration and the use case clustering unit optimize the hypergraph neural network, the formula is used. ,in, are the optimized hypergraph neural network parameters, is the parameter to be optimized, is the number of training samples, For the The loss function of each sample is used to build the loss calculation rules based on the test case completeness and test step accuracy in the software test parameters; when clustering test cases, the formula is used. ,in, is the clustered test case, As the basic test case framework, The use case adjustment amount calculated by the optimized hypergraph neural network, the test depth requirement and test complexity index in the software test parameters Calculation.

[0035] Specifically, when optimizing the hypergraph neural network, this unit constructs a loss function based on the test case completeness, step accuracy, and other factors in the software test parameters. By minimizing the loss function, the network parameters are optimized so that the network can better adapt to the test case generation requirements. In the test case refinement stage, the adjustment amount of the basic test case framework is calculated based on test parameters such as test depth requirements and complexity indicators, and the refined test cases are obtained. During implementation, the initial parameters of the hypergraph neural network are first set and relevant data is input, and the network is continuously optimized through training samples; then the adjustment amount is calculated based on the test parameters, the basic framework is refined, and the test cases are gradually improved so that they can cover the test points of the software system more comprehensively and meticulously, thereby improving the quality of the test cases.

[0036] Preferably, when the cross-modal feature joint extraction and the deep fusion unit perform cross-modal feature extraction, the formula is also used. ,in, is the code modal eigenvector, is the number of code feature dimensions, is the weight of the k-th dimension code feature, is the code feature value of the kth dimension, the code coverage and code logic complexity in the software test parameters The value of the test case framework generation and parameter association unit generates the test case framework using the formula ,in, For the generated test case framework, is the framework generation function, H is the hypergraph structure, is the code modal eigenvector, is the text modal feature vector, the test type and test target influence in the software test parameters The operation process.

[0037] Specifically, when the cross-modal feature joint extraction and deep fusion unit extracts the code modal feature vector, it determines the weight of each code feature dimension based on the code coverage, logic complexity, etc. in the software test parameters, and comprehensively extracts the code features. When the test case framework generation and parameter association unit generates the framework, it integrates the hypergraph structure, code modal feature vector, text modal feature vector, and test parameters such as test type and target, and generates function operations through a specific framework to obtain the test case framework. During the implementation process, the former accurately analyzes the code features and extracts feature vectors based on the weights determined by the parameters, while the latter integrates various information and parameters, and generates a framework through function operations to ensure that the generated test case framework starts from the multimodal perspective of code and text, closely revolves around the test requirements, and provides an effective framework support for subsequent testing work.

[0038] Preferably, when the hypergraph topology relationship is constructed and the semantic enhancement unit enhances the semantic expression, the formula is used. , where S is the overall semantic enhancement vector of the hypergraph, For nodes The semantic contribution weight of For nodes Initial semantic vector, node importance and node correlation in software testing parameters Calculation; When the cross-modal feature joint extraction and deep fusion unit perform feature fusion, the formula is also used ,in, is the final fusion feature vector, F is the preliminary fusion feature vector, is the feature correction vector adjusted according to the hypergraph structure and software test parameters, is the correction coefficient, the feature fusion accuracy requirements in the software test parameters, and the impact of the test case quality standards and of confirmation.

[0039] Specifically, when the hypergraph topology relationship construction and semantic enhancement unit enhances the semantic expression, the node semantic contribution weight is determined according to the node importance and correlation in the software test parameters, and the overall semantics of the hypergraph is enhanced to make the hypergraph more accurately reflect the data semantic information. When the cross-modal feature joint extraction and deep fusion unit performs feature fusion, the feature correction vector and correction coefficient are determined according to the feature fusion accuracy requirements and test case quality standards in the hypergraph structure and software test parameters, and the preliminary fused feature vector is optimized to obtain the final fused feature vector. During implementation, the former first analyzes the node characteristics and determines the weight enhancement semantics according to the parameters, and the latter combines the hypergraph and test parameters to optimize the fusion features, ensuring that the system is more in line with the high standards of software testing in terms of data semantic expression and feature fusion, and laying a solid data foundation for test case generation.

[0040] Preferably, the cross-modal feature joint extraction and deep fusion unit includes: a text feature extraction subunit, which is used to extract word vectors and semantic dependency text features from text nodes in the hypergraph; a code feature extraction subunit, which is used to extract function call relationships and code structure code features from code nodes in the hypergraph; a cross-modal feature alignment subunit, which aligns the extracted text features with the code features in terms of dimension and semantics based on the hypergraph structure; and a feature fusion optimization subunit, which optimizes and adjusts the initially fused cross-modal features according to software testing parameters.

[0041] Specifically, the text feature extraction subunit extracts text features such as word vectors and semantic dependencies from text nodes in the hypergraph, providing text modal information for subsequent fusion; the code feature extraction subunit extracts code features such as function call relationships and code structure from code nodes to improve code modal features; the cross-modal feature alignment subunit aligns text and code features in terms of dimension and semantics based on the hypergraph structure to eliminate modal differences; the feature fusion optimization subunit optimizes and adjusts the initially fused cross-modal features based on software test parameters. During implementation, each subunit performs tasks in sequence: the text and code feature extraction subunits collect features separately, the alignment subunit processes differences, and the optimization subunit improves the fused features based on test parameters, enabling the unit to efficiently and accurately extract and fuse cross-modal features, providing high-quality feature input for test case generation.

[0042] Preferably, the test case framework generation and parameter association unit includes: a basic framework generation sub-unit, which generates a basic test case framework including test steps and test objects based on the fused cross-modal features; a parameter mapping sub-unit, which maps the test data and test environment in the software test parameters to the corresponding parts of the basic framework; a framework verification sub-unit, which checks whether the generated test case framework complies with the software testing specifications; and a parameter association optimization sub-unit, which optimizes the associated test case parameters according to the association relationship between the software test parameters.

[0043] Specifically, the basic framework generation subunit generates a basic test case framework containing test steps and objects based on the fused cross-modal features, and builds a prototype of the test case; the parameter mapping subunit maps software test parameters such as test data and environment to the corresponding parts of the framework, giving the framework actual test parameters; the framework verification subunit checks whether the framework complies with the software testing specifications to ensure the validity of the framework; the parameter association optimization subunit optimizes the associated test case parameters based on the association relationship between parameters. During the implementation process, the subunits work together. The basic framework generation subunit first builds the framework, the parameter mapping subunit fills in the parameters, the verification subunit reviews the framework, and finally the optimization subunit improves the parameter association, so that the generated test case framework not only complies with the test specifications, but also closely associates with the actual test parameters and has good executable performance.

[0044] Preferably, the hypergraph neural network optimization iteration and use case clustering unit includes: a network parameter initialization subunit, which assigns initial parameters to the hypergraph neural network; a training sample construction subunit, which constructs a sample set for training based on the hypergraph structure and fusion features; a network training optimization subunit, which uses an optimization algorithm to train the hypergraph neural network and update the network parameters; and a use case clustering execution subunit, which performs clustering operations on the basic test case framework based on the trained hypergraph neural network.

[0045] Specifically, the network parameter initialization subunit assigns initial parameters to the hypergraph neural network and determines the network's initial state. The training sample construction subunit constructs a training sample set based on the hypergraph structure and fusion features, providing data for network training. The network training optimization subunit uses an optimization algorithm to train the network and updates parameters to meet testing requirements. The use case refinement and execution subunit refines the basic test case framework based on the trained network. During implementation, each subunit performs its work in sequence. After the initialization subunit sets parameters, the construction subunit prepares samples. The training optimization subunit trains the network using samples. Finally, the execution subunit refines the framework based on the training results, gradually optimizing the hypergraph neural network and improving the test cases, so that the test cases can better meet the comprehensiveness and accuracy requirements of software testing.

[0046] like Figure 2As shown, a large model test case intelligent generation system based on big data, the operation of the system includes the following steps: Step S1: Collect multi-source data such as requirement documents and system codes through a multi-source heterogeneous data perception and structured parsing unit, and parse them into structured data; Step S2: Using the hypergraph topology relationship construction and semantic enhancement unit to construct the structured data into a hypergraph structure, connecting different data nodes through hyperedges and enhancing semantic expression; Step S3: The cross-modal feature joint extraction and deep fusion unit extracts text and code cross-modal features from the hypergraph structure and performs deep fusion; Step S4: The test case framework generation and parameter association unit generates a basic test case framework based on the fused features and associates the software test parameters; Step S5: Optimize the iteration and use case clustering unit through the hypergraph neural network, iteratively optimize the basic framework using the optimized hypergraph neural network, and cluster the test cases; Step S6: The test case verification and output unit verifies the clustered test cases and outputs the final results.

[0047] A large-model test case intelligent generation system based on big data. To address the problem that traditional systems cannot deeply associate system design details, this system uses a multi-source heterogeneous data perception and structured parsing unit to comprehensively collect multi-source data such as requirement documents and system code, and converts it into a structured form. The hypergraph topology relationship construction and semantic enhancement unit further constructs this data into a hypergraph structure, uses hyperedges to connect different types of data nodes, and deeply mines the complex relationships between data. For example, the system can accurately capture the potential connection between the business logic in the requirement document and the module interaction in the code structure, and visualize the system design details in the form of a hypergraph, avoiding the drawbacks of traditional methods that only stay at the surface of information processing. The cross-modal feature joint extraction and deep fusion unit extracts multimodal features such as text and code from the hypergraph and deeply fuses them, so that the generated test cases can fully cover the interaction logic and business rules of each module of the system, ensuring that the test cases are closely related to the system design.

[0048] To address the traditional system's reliance on completed code, this system can intervene without waiting for the system code to be fully developed. In the early stages of software development, the multi-source heterogeneous data perception and structured parsing unit can acquire data such as requirements documents. The hypergraph topology relationship construction and semantic enhancement unit constructs a hypergraph based on this data. Subsequent units then generate a basic test case framework based on this data and associate software test parameters. As development progresses, the hypergraph neural network optimization iteration and use case refinement unit iteratively optimizes the basic framework using an optimized hypergraph neural network, continuously refining test cases. This entire process runs through the entire software development process. Whether in the requirements analysis and design phases or the coding implementation phase, the system can continuously generate and optimize test cases, overcoming the limitations of traditional systems that are ineffective in the early stages of development. In addition, the test case verification and output unit rigorously verifies the final test cases to ensure the high quality and reliability of the output test cases, providing an efficient, comprehensive, and reliable solution for large-model software testing.

[0049] In the description of the present invention, it should be noted that, unless otherwise expressly specified or limited, the terms "disposed," "installed," "connected," "connected," and "fixed" should be understood in a broad sense. For example, they may refer to fixed connections, detachable connections, or integral connections; they may refer to mechanical connections or electrical connections; they may refer to direct connections or indirect connections through an intermediate medium; and they may refer to internal communication between two components. Those skilled in the art will understand the specific meanings of the above terms in the present invention based on specific circumstances.

[0050] While embodiments of the present invention have been shown and described, it will be understood by those skilled in the art that various equivalent changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the invention, and that the scope of the invention is defined by the appended claims and their equivalents.

Claims

1. A large-model test case intelligent generation system based on big data, characterized by: include: Multi-source heterogeneous data perception and structured parsing unit, used to collect multi-source data such as requirement documents and system code, and parse it into structured data; The hypergraph topology relationship construction and semantic enhancement unit constructs structured data into a hypergraph structure, connects different data nodes through hyperedges, and enhances semantic expression; the cross-modal feature joint extraction and deep fusion unit extracts text and code cross-modal features from the hypergraph structure and deeply fuses them; the test case framework generation and parameter association unit generates a basic test case framework based on the fused features and associates software test parameters; the hypergraph neural network optimization iteration and use case clustering unit iteratively optimizes the basic framework through the optimized hypergraph neural network and clusters test cases; Test case verification and output unit verifies the clustered test cases and outputs the final results; The output end of the multi-source heterogeneous data perception and structured parsing unit is connected to the input end of the hypergraph topology relationship construction and semantic enhancement unit, the output end of the hypergraph topology relationship construction and semantic enhancement unit is connected to the input end of the cross-modal feature joint extraction and deep fusion unit, the output end of the cross-modal feature joint extraction and deep fusion unit is connected to the input end of the test case framework generation and parameter association unit, the output end of the test case framework generation and parameter association unit is connected to the input end of the hypergraph neural network optimization iteration and use case clustering unit, and the output end of the hypergraph neural network optimization iteration and use case clustering unit is connected to the input end of the test case verification and output unit.

2. The system for intelligently generating large-scale model test cases based on big data according to claim 1, characterized in that: When the hypergraph topology relationship is constructed and the semantic enhancement unit constructs the hypergraph structure, the formula ,in, Represents a node set consisting of requirement document keyword nodes and code function nodes. Represents a set of hyperedges connecting different types of nodes. Hyperedges connect multiple nodes to represent complex relationships between data. represents the hyperedge weight matrix, whose elements For quantization nodes With node The semantic association strength when connected by hyperedges; when the cross-modal feature joint extraction and the deep fusion unit perform feature fusion, the formula is used ,in, is the fused cross-modal feature vector, is the text feature vector extracted from the text node in the hypergraph, is the code feature vector extracted from the code node in the hypergraph, and The fusion coefficient is dynamically adjusted according to the feature importance in the software test parameters. The test coverage type and test priority in the software test parameters affect and The value of .

3. The system for intelligently generating large-scale model test cases based on big data according to claim 1, characterized in that: The cross-modal feature joint extraction and deep fusion unit uses the optimized hypergraph neural network to extract cross-modal features through the formula Update node features, where For nodes In the Feature vectors in layer hypergraph neural networks, is the activation function, For nodes The set of connected hyperedges, is the number of hyperedges in the set, For nodes With node Hyperedge weights, For nodes In the The feature vector of the layer, For the Layer Hyperedge The test case framework generates a feature transformation matrix associated with the parameter association unit when the software test parameters are associated with the parameter association unit, using the formula ,in, is the associated test case parameter set, is the parameter adjustment coefficient, Based on hypergraph structure and fusion features Generated basic parameter set, test data type in software test parameters, test environment configuration impact and Calculation.

4. The system for intelligently generating large-scale model test cases based on big data according to claim 1, characterized in that: When the hypergraph neural network optimization iteration and the use case clustering unit optimize the hypergraph neural network, the formula is used ,in, are the optimized hypergraph neural network parameters, is the parameter to be optimized, is the number of training samples, For the The loss function of each sample is used to build the loss calculation rules based on the test case completeness and test step accuracy in the software test parameters; when clustering test cases, the formula is used. ,in, is the clustered test case, As the basic test case framework, The use case adjustment amount calculated by the optimized hypergraph neural network, the test depth requirement and test complexity index in the software test parameters Calculation.

5. The system for intelligently generating large-scale model test cases based on big data according to claim 1, characterized in that: When the cross-modal feature joint extraction and the deep fusion unit perform cross-modal feature extraction, the formula is also used. ,in, is the code modal eigenvector, is the number of code feature dimensions, is the weight of the k-th dimension code feature, is the code feature value of the kth dimension, the code coverage and code logic complexity in the software test parameters The value of the test case framework generation and parameter association unit generates the test case framework using the formula ,in, For the generated test case framework, is the framework generation function, H is the hypergraph structure, is the code modal eigenvector, is the text modal feature vector, the test type and test target influence in the software test parameters The operation process.

6. The system for intelligently generating large-scale model test cases based on big data according to claim 1, characterized in that: When the hypergraph topology relationship is constructed and the semantic enhancement unit enhances the semantic expression, the formula is used. , where S is the overall semantic enhancement vector of the hypergraph, For nodes The semantic contribution weight of For nodes Initial semantic vector, node importance and node correlation in software testing parameters Calculation; When the cross-modal feature joint extraction and deep fusion unit perform feature fusion, the formula is also used ,in, is the final fusion feature vector, F is the preliminary fusion feature vector, is the feature correction vector adjusted according to the hypergraph structure and software test parameters, is the correction coefficient, the feature fusion accuracy requirements in the software test parameters, and the impact of the test case quality standards and of confirmation.

7. The system for intelligently generating large-scale model test cases based on big data according to claim 1, characterized in that: The cross-modal feature joint extraction and deep fusion unit includes: a text feature extraction subunit, which is used to extract word vectors and semantic dependency text features from text nodes in the hypergraph; a code feature extraction subunit, which is used to extract function call relationships and code structure code features from code nodes in the hypergraph; a cross-modal feature alignment subunit, which aligns the extracted text features with the code features in terms of dimension and semantics based on the hypergraph structure; and a feature fusion optimization subunit, which optimizes and adjusts the initially fused cross-modal features according to software testing parameters.

8. The system for intelligently generating large-scale model test cases based on big data according to claim 1, characterized in that: The test case framework generation and parameter association unit includes: a basic framework generation subunit, which generates a basic test case framework including test steps and test objects based on the fused cross-modal features; a parameter mapping subunit, which maps the test data and test environment in the software test parameters to the corresponding parts of the basic framework; a framework verification subunit, which checks whether the generated test case framework complies with the software testing specifications; and a parameter association optimization subunit, which optimizes the associated test case parameters according to the association relationship between the software test parameters.

9. The system for intelligently generating large-scale model test cases based on big data according to claim 1, characterized in that: The hypergraph neural network optimization iteration and use case clustering unit includes: a network parameter initialization subunit, which assigns initial parameters to the hypergraph neural network; a training sample construction subunit, which constructs a sample set for training based on the hypergraph structure and fusion features; a network training optimization subunit, which uses an optimization algorithm to train the hypergraph neural network and update the network parameters; and a use case clustering execution subunit, which performs clustering operations on the basic test case framework based on the trained hypergraph neural network.

Citation Information

Patent Citations

  • Project demand generation method and device, electronic equipment and storage medium

    CN113379398A

  • Multimodal data-based hypergraph neural network data classification method and system

    CN117349743A

  • Feature attachment detection method based on multi-level code representation

    CN119025418A

  • Test case generation method and system based on large model and retrieval enhancement generation

    CN119537222A

  • Method and system for quickly constructing and multiplexing application framework

    CN119576290A