Method, apparatus, device, medium, and product for generating data
The method uses a large language model to determine atomic capabilities for data generation, addressing inefficiencies in manual and Mock-based methods by enhancing data generation efficiency and accuracy.
Patent Information
- Application Number
- US19/682743
- Authority / Receiving Office
- US · United States
- Patent Type
- Applications(United States)
- Current Assignee / Owner
- Priority Date
- 2025-05-20
- Filing Date
- 2026-05-20
- Publication Date
- 2026-11-26
AI Technical Summary
Existing data generation methods rely on manual work or Mock means, which are inefficient, result in inaccurate and scenario-coverage-limited data, and increase the risk of bugs in program products.
A method utilizing a large language model (LLM) to determine atomic capabilities based on structured data, automatically generating data by invoking these capabilities in response to user requirements, enhancing efficiency and scenario coverage.
Improves data generation efficiency and accuracy by automatically generating data that better meets user requirements and covers multiple application scenarios.
Smart Images

Figure US20260377395A1-D00000_ABST
Abstract
Description
CROSS-REFERENCE TO RELATED APPLICATIONS
[0001] This application claims priority to Chinese Application No. 202510656135.1 filed on May 20, 2025, the disclosure of which is incorporated herein by reference in its entirety.FIELD
[0002] The present disclosure relates to the field of computer technologies, and in particular, to a method, an apparatus, a computing device, a computer storage medium, and a computer program product for generating data.BACKGROUND
[0003] In a current large-scale Internet service scenario, data construction is a key step in ensuring product development, but it is faced with a plurality of complex challenges. Existing technologies generally rely on manual construction or a large number of Mock means to generate data, which is time-consuming, low in reusability, and high in development and maintenance costs, and accounts for a high proportion of workload in an overall execution stage. Therefore, a new method for generating data is urgently needed to improve the efficiency and quality of generated data, thereby better meeting the needs of software development.SUMMARY
[0004] In a first aspect of embodiments of the present disclosure, a method for generating data is provided. The method includes: receiving a requirement description for generating data to be analyzed; retrieving, based on a vector representation of the requirement description, structured data matching the requirement description; determining, using a large language model (LLM) and based on the structured data, at least one atomic capability associated with the data to be analyzed, where the atomic capability represents a basic function for constructing the data to be analyzed; and invoking, in response to confirmation of a parameter associated with the at least one atomic capability, the at least one atomic capability to generate the data to be analyzed.
[0005] In a second aspect of embodiments of the present disclosure, an apparatus for generating data is provided. The apparatus includes: a receiving unit configured to receive a requirement description for generating data to be analyzed; a retrieving unit configured to retrieve, based on a vector representation of the requirement description, structured data matching the requirement description; a determining unit configured to determine, using a large language model (LLM) and based on the structured data, at least one atomic capability associated with the data to be analyzed, where the atomic capability represents a basic function for constructing the data to be analyzed; and an invoking unit configured to invoke, in response to confirmation of a parameter associated with the at least one atomic capability, the at least one atomic capability to generate the data to be analyzed.
[0006] In a third aspect of embodiments of the present disclosure, an electronic device is provided. The electronic device includes: at least one processing unit; and at least one memory. The at least one memory is coupled to the at least one processing unit, and stores instructions to be executed by the at least one processing unit. The instructions, when executed by the at least one processing unit, cause the electronic device to perform the method according to the first aspect of the present disclosure.
[0007] In a fourth aspect of embodiments of the present disclosure, a non-transitory computer storage medium is provided. The non-transitory computer storage medium includes machine-executable instructions which, when executed by a device, cause the device to perform the method according to the first aspect of the present disclosure.
[0008] In a fifth aspect of embodiments of the present disclosure, a computer program product is provided. The computer program product includes machine-executable instructions which, when executed by a device, cause the device to perform the method according to the first aspect of the present disclosure.
[0009] The summary section is provided to introduce a selection of concepts in a simplified form, which will be further described in the detailed description section below. The summary section is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to limit the scope of the claimed subject matter.BRIEF DESCRIPTION OF THE DRAWINGS
[0010] The above and other features, advantages, and aspects of embodiments of the present disclosure become more apparent with reference to the following detailed description and in conjunction with the drawings, where:
[0011] FIG. 1 shows a schematic diagram of a structure of a system for generating data according to some embodiments of the present disclosure;
[0012] FIG. 2 shows a flowchart of a method for generating data according to some embodiments of the present disclosure;
[0013] FIG. 3 shows a signaling diagram of a method for generating data according to some embodiments of the present disclosure;
[0014] FIG. 4 shows a flowchart of a method for building a retriever according to some embodiments of the present disclosure;
[0015] FIG. 5 shows a flowchart of a method for generating an answer to a requirement description according to some embodiments of the present disclosure;
[0016] FIG. 6 shows a block diagram of an apparatus for generating data according to some embodiments of the present disclosure; and
[0017] FIG. 7 shows a block diagram of a device capable of implementing a plurality of embodiments of the present disclosure.
[0018] Throughout the drawings, the same or similar reference numerals represent the same or similar elements.DETAILED DESCRIPTION OF EMBODIMENTS
[0019] It may be understood that all user-related data involved in the technical solution should be acquired and used after user authorization. This means that in the technical solution, if user personal information needs to be used, explicit consent and authorization of the user are required before the data is acquired, otherwise, the related data collection and use will not be performed. It should also be understood that when implementing the technical solution, relevant laws and regulations should be strictly complied with in the process of data collection, use and storage, and necessary technical means and measures should be taken to ensure user data security and secure use of data.
[0020] It may be understood that before the use of the technical solution disclosed in the embodiments of the present disclosure, the user shall be informed of the type, range of use, use scenarios, etc. of personal information involved in the present disclosure in an appropriate manner in accordance with relevant laws and regulations, and the authorization of the user shall be obtained.
[0021] For example, when an active request from a user is received, prompt information is sent to the user to clearly prompt the user that the requested operation will require obtain and use of the user’s personal information. As such, the user may independently choose, based on the prompt information, whether to provide the personal information to software or hardware, such as an electronic device, an application, a server, or a storage medium, that performs the operations of the technical solution of the present disclosure.
[0022] As an optional but non-limiting implementation, in response to receiving the active request from the user, the prompt information may be sent to the user in the form of, for example, a pop-up window, in which the prompt information may be presented in text. Furthermore, the pop-up window may also include a selection control for the user to select whether to "agree" or "disagree" to provide the personal information to the electronic device.
[0023] It may be understood that the above process of notifying and obtaining user authorization is only illustrative and does not limit the implementations of the present disclosure, and other manners that satisfy the relevant laws and regulations may also be applied in the implementations of the present disclosure.
[0024] Hereinafter, embodiments of the present disclosure will be described in more detail with reference to the drawings. Although some embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be implemented in various forms, and should not be construed as limited to the embodiments set forth herein. Instead, these embodiments are provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only used for exemplary purposes, and are not used to limit the protection scope of the present disclosure.
[0025] In the description of the embodiments of the present disclosure, the term "include / comprise" and similar terms should be understood as open-ended inclusions, that is, "include / comprise but not limited to". The term "based on" should be understood as "at least partially based on". The term "one embodiment" or "the embodiment" should be understood as "at least one embodiment". The terms "first", "second", etc. may refer to different or same objects, unless explicitly stated. Other definitions, either explicit or implicit, may also be included below.
[0026] The inventors have noticed that existing methods for generating data usually rely on manual work or Mock means. However, manually writing data or relying on Mock means to generate data is inefficient, and the written data often suffers from insufficient accuracy and scenario coverage. For example, limited by differences in personal experience, data manually written or generated relying on Mock may not match the actual application scenario of the program product, resulting in a disconnection between the data and the actual demand. In addition, the data manually written or generated relying on Mock usually cannot cover all possible application scenarios, resulting in an increased risk of a missing testing of a bug in the program product. Therefore, it is urgent to design a new method for generating data.
[0027] To this end, the present disclosure provides a method for generating data. In this method, a requirement description of generating data is received. The requirement description refers to a specific data construction request proposed by the user to the system through natural language, and its core objective is to clearly express user intention and trigger the system to automatically generate a required answer. Next, the system retrieves, based on vector representation (i.e., embedding) of the requirement description, structured data matching the requirement description in a knowledge base. At least one atomic capability associated with the data is determined using a large language model (LLM) and based on the structured data. Here, the atomic capability represents a basic function for constructing the data, for example, may be a basic operation such as creating an account and modifying a user attribute. The structured data refers to data organized in a predefined format and having a clear field and type definition, and may usually be described and managed through a fixed schema. Here, the structured data may be knowledge about the atomic capability pre-stored in the knowledge base, including but not limited to a capability owner, a parameter, a restriction, and the like. Finally, in response to confirmation of a parameter associated with the at least one atomic capability, the at least one atomic capability is invoked to generate data to be analyzed. For example, in the process of creating an account, the parameter may be, for example, the number of accounts that need to be created; in the process of modifying a user attribute, the parameter may be, for example, the nationality, gender, age, etc. of the user. It should be understood that the above description of the parameter is only an example, and the type of the parameter associated with the atomic capability may include more categories, which is not limited here. Here, the generated data may also be referred to as data to be analyzed, which may be used for any purpose, including but not limited to: test data for software testing purposes, training data for model training, and the like.
[0028] Through this method, the existing knowledge related to the requirement description may be retrieved to assist the large language model with semantic understanding capability to determine the atomic capability matching the requirement description, and the data may be automatically generated based on the matched atomic capability, which improves the efficiency of data generation and enables the generated data to better meet the user requirements. In addition, the generated data may cover more different application scenarios through retrieval.
[0029] FIG. 1 shows a schematic diagram of a system 100 for generating data according to some embodiments of the present disclosure. As shown in FIG. 1, the system 100 includes an interaction layer 102, a model layer 104, an execution layer 106, and a base 108. The system 100 may be implemented by a single computing device or a computing cluster.
[0030] In the system 100, the interaction layer102 may provide a robot dialogue service to a user, and a structure of the interaction layer 102 includes dialogue management, command parsing management, user feedback management, and user data management. The dialogue management is responsible for maintaining context logic of a multi-round dialogue to ensure that the robot may understand user requirements coherently and dynamically adjust a response strategy according to a current dialogue state. For example, the dialogue management may record historical dialogue information (such as parameters already provided by the user) to avoid repeated questions. In addition, the dialogue management may also define a dialogue flow (such as "account creation → modification of the number of followers → confirmation and submission"), and guide the user to confirm a requirement description of data to be generated. The command parsing management converts a natural language instruction of the user into a structured operation instruction, so that an atomic capability or a service interface in the system may be accurately matched. The user feedback management is responsible for processing, at the interaction layer 102, a response (such as confirmation, correction, and supplementary instruction) of the user to an output of the system, and converting the response into an executable adjustment instruction to drive iterative optimization of the system. The user data management is a core module responsible for the full lifecycle management of user input data, covering the full process control from data acquisition, verification, storage to secure transmission. Its core objective is to ensure efficient processing, security compliance and accurate delivery of user data.
[0031] The model layer 104 may provide retrieval and generation services, and the model layer 104 includes retrieval augmented generation (RAG) and a LLM. The RAG is an artificial intelligence framework that combines retrieval technology and a generation model, and aims to use a retrieval result of an external knowledge base or document to enhance the generation capability of the language model. The core idea is that when generating content (such as answering questions and generating text), relevant information is first obtained from massive data through retrieval, and then the information is input into the generation model, so that the model performs output based on the latest and most relevant knowledge. The LLM is a deep learning-based artificial intelligence model that has powerful natural language understanding and generation capabilities after being trained on massive text data (usually on the scale of billions to trillions of parameters). In some implementations, the LLM may be used to implement an agent for performing a specific task.
[0032] The execution layer 106 may perform a data generation task based on confirmation of an answer generated by the LLM and a parameter associated with the answer by the user. The execution layer 106 includes data synchronization, tool execution, and verification result. The data synchronization may transmit and update data between different platforms or modules through a specific technical means (such as incremental update, event-driven, and batch transmission) to keep data of a plurality of parties consistent. The tool execution may invoke a specific data construction tool or interface to generate data according to the answer generated by the model layer 104 and the confirmation of the parameter associated with the atomic capability by the user. The verification result may check the tool or the data generation process invoked by the execution layer 106 to ensure that the generated data meets the relevant regulations and technical specifications.
[0033] The base 108 represents a unified technical infrastructure or platform, and its core role is to provide an efficient, reusable and compliant support environment for complex business scenarios by integrating fragmented toolchains, standardizing data interaction processes, and coordinating atomic capabilities. The base 108 includes a tool platform A, a tool platform B, a tool platform C, and more tool platforms. It should be understood that the number of tool platforms is not limited in the present disclosure, and the number of tool platforms may be more or less. The tool platform refers to a series of independent but integrable software tools or services that focus on specific functions (such as data generation, compliance checking, and approval process management), and are connected to the core system (such as the base 108) through a standardized interface to support the efficient operation of complex business scenarios. The tool platform may include a plurality of atomic capabilities, for example, the atomic capabilities included in the tool platform A may be, for example, creating an account of type A, activating live streaming permission, and constructing a specified number of followers. The atomic capabilities included in the tool platform B may be, for example, updating the historical number of followers of a user, constructing a specified number of followers, and constructing specified intimacy data. The atomic capabilities included in the tool platform C may be, for example, creating several accounts of type B, activating microphones connection permission, and generating different types of creations. It should be understood that the tool platform may include more atomic capabilities of different types and in different numbers, which is not limited here.
[0034] In some embodiments, the interaction layer 102 may receive a requirement description of generating data, parse the requirement description, and generate a vector representation of the requirement description. The model layer 104 may retrieve, using the RAG and based on the vector representation of the requirement description, structured data matching the requirement description. The model layer 104 may determine, using the LLM and based on the structured data, at least one atomic capability associated with the data, and return the at least one atomic capability and a parameter associated with the data to the interaction layer 102. The parameter is used for constructing the data. In response to confirmation of the at least one atomic capability and the parameter by the user, the execution layer 106 verifies the at least one atomic capability and the parameter, and confirms that the data may be generated. Then, based on the at least one atomic capability, an interface of the base 108 is invoked and a tool platform associated with the at least one atomic capability is determined, and the corresponding at least one atomic capability is selected from the associated tool platform to generate the data.
[0035] It should be understood that the above description of the structure of the system for generating data is only an example, the system 100 may include more or fewer levels, and different levels may include more or fewer modules, for example, the interaction layer 102 may further include multilingual management, which is not limited here.
[0036] It should also be understood that the device for generating data may be an electronic device having a data processing function, including but not limited to a mobile phone, a tablet computer, a wearable device, a vehicle-mounted device, an augmented reality / virtual reality device, a notebook computer, an ultra-mobile personal computer, a netbook, a personal digital assistant, an Internet of Things device, an industrial terminal, a desktop computer, a server, a computing cluster, a cloud computing center, and various electronic devices with computing functions. The specific type of the electronic device is not limited in the embodiments of the present disclosure.
[0037] FIG. 2 shows a flowchart of a method 200 for generating data according to some embodiments of the present disclosure. The method 200 may be performed by, for example, a device.
[0038] As shown in FIG. 2, at block 202, a requirement description for generating data to be analyzed is received. In some embodiments, the device may use the interaction layer 102 to receive a requirement description text related to the data to be analyzed and entered by a user, for example, "create an account of a user from country A with 1000 followers and send a system message".
[0039] At block 204, structured data matching the requirement description is retrieved based on a vector representation of the requirement description. The structured data refers to data organized in a predefined format and having a clear field and type definition, and may usually be described and managed through a fixed schema. In some embodiments, based on the requirement description "create an account from country A with 1000 followers and send a system message", it is determined that a requirement vector includes three sub-vectors: creating an account, modifying the number of followers, and sending a message. Based on these three sub-vectors, the RAG is used to retrieve the matched structured data.
[0040] In some embodiments, description information of a plurality of atomic capabilities is extracted from at least one tool platform of the base 108, and the description information of the plurality of atomic capabilities is preprocessed to obtain the structured data. Based on the obtained structured data, a vector representation of the structured data is generated for the RAG retrieval. In some embodiments, the structured data similar to the requirement description may be determined based on the vector representation of the requirement description and the vector representation of the structured data.
[0041] At block 206, at least one atomic capability associated with the data to be analyzed is determined using a large language model (LLM) and based on the structured data. The atomic capability representing a basic function for constructing the data to be analyzed. In some embodiments, based on the structured data similar to the requirement description, the at least one atomic capability associated with the data to be analyzed is determined using the LLM by using a prompt. In some embodiments, the LLM may be integrated into an agent, the structured data, the requirement description and the prompt are provided to the agent, and the agent answers or determines the atomic capability associated with the data to be analyzed.
[0042] At block 208, the at least one atomic capability is invoked to generate the data to be analyzed in response to confirmation of a parameter associated with the at least one atomic capability. For example, the agent notifies the user of the determined atomic capability through the interaction layer, and it is confirmed by the user whether these atomic capabilities and their parameters truly match his / her requirement of constructing the data to be analyzed. In some embodiments, a task of generating the data to be analyzed is determined in response to the confirmation of the parameter associated with the at least one atomic capability. The task may be specified or associated with a certain tool platform that provides the atomic capability meeting the user requirement, for example, an identification (ID) of the task may implicitly specify the tool platform. Then, at the execution layer, a tool platform for generating the data to be analyzed is determined from the plurality of tool platforms of the base 108 and based on the ID of the task. The determined tool platform (for example, the tool platform A) invokes the at least one atomic capability to generate the data to be analyzed.
[0043] By performing the above method, the data related to the requirement description may be retrieved to determine the at least one atomic capability, and the data may be automatically generated based on the at least one atomic capability, which improves the efficiency of data generation and enables the generated data to better meet the user requirements. In addition, the generated data may cover more different application scenarios through retrieval.
[0044] FIG. 3 shows a signaling diagram 300 of a method for generating data according to some embodiments of the present disclosure. The signaling diagram 300 may be executed by, for example, a device. FIG. 3 includes a user 301, an interaction layer 302, a model layer 303, an execution layer 304, a tool platform A 305, and a tool platform B 306. It should be understood that FIG. 3 may be an example implementation of FIG. 2.
[0045] The device may acquire a requirement description of the user 302. Based on the acquired requirement description of the user 302, the interaction layer 302 may invoke an interface of the model layer 303 to perform RAG retrieval. Based on a vector representation of the requirement description of the user 302, the interaction layer 302 performs the RAG retrieval to determine structured data matching the vector representation of the requirement description. A prompt is assembled based on the matched structured data. Exemplarily, a prompt template may include a role expected to be played by the LLM, a target to be generated, relevant constraints, a content output format, an example, an atomic capability, and other content, and the prompt is generated based on the prompt template in combination with the structured data. Based on the generated prompt, the at least one atomic capability associated with the data is determined using the LLM. The model layer 303 returns the generated at least one atomic capability to the interaction layer 302 and displays it to the user 301 to request confirmation of the user 301, and the user 301 confirms the generated at least one atomic capability and a parameter associated with the atomic capability. For example, when the atomic capability is "constructing the number of followers", the parameter may be a number, for example, 5000. In response to the confirmation of the user 301, the model layer 303 confirms starting to construct data, and returns necessary information for constructing data to the interaction layer 302.
[0046] The interaction layer 302 extracts the confirmation information and the information returned by the model layer 303, and invokes the execution layer 304 to generate data. The execution layer 304 confirms the integrity of the parameter associated with the at least one atomic capability. In case that the parameter is complete, in response to the at least one atomic capability being located in the tool platform A 305, the execution layer 304 invokes the tool platform A 305 to acquire the at least one atomic capability. In response to the at least one atomic capability being located in the tool platform B 306, the execution layer 304 invokes the tool platform B 306 to acquire the at least one atomic capability. In response to the at least one atomic capability being located in each of the tool platform A 305 and the tool platform B 306, the execution layer 304 respectively acquires the related at least one atomic capability from the tool platform A 305 and the tool platform B 306. The data is constructed based on the acquired at least one atomic capability, an execution result of each of the at least one atomic capability is verified. In response to the execution result of each atomic capability passing the verification, the data is returned to the user 301. In response to the execution result of the at least one atomic capability failing to pass the verification, error information is returned to the user 301. By executing the above method, the related data may be automatically generated based on the requirement description of the user, and the user may acquire the data related to the requirement description simply by providing the requirement description, which improves the efficiency of data generation.
[0047] It should be understood that the above description of the execution layer invoking the tool platform is only an example, the execution layer may invoke one or more tool platforms, and the number of tool platforms is not limited to two in FIG. 3, and may include more or less, which is not limited here.
[0048] FIG. 4 shows a flowchart of a method 400 for building a retriever according to some embodiments of the present disclosure. The method 400 may be performed by, for example, a device. It should be understood that FIG. 4 may be a building process of the retriever for the RAG retrieval in FIG. 3.
[0049] As shown in FIG. 4, the device may extract description information of a plurality of atomic capabilities included in at least one tool platform from an atomic capability information base 401, for example, may extract the description information of the plurality of atomic capabilities from a tool platform A 402, a tool platform B 403, and a tool platform X 404. The extracted description information of the plurality of atomic capabilities is preprocessed to generate a tool content structure. Based on the generated tool content structure, structure processing is performed according to each piece of tool content, for example, data cleaning is performed on the tool content structure to ensure structured output of data, to generate and store a standardized content structure 406. The LLM is invoked to establish embedding for the standardized content structure 406, that is, the structured data, to generate a vector representation of the structured data.
[0050] In some embodiments, a requirement description of a user is preprocessed to obtain a vector representation of the requirement description. Exemplarily, desensitization may be performed on user information in the requirement description. Blacklist policy management may be performed on the requirement description, whether there is blacklist content in the requirement description is determined. In response to there being blacklist content in the requirement description, non-compliant content in the requirement description is removed. In addition, easily confused words in the requirement description may be replaced, and a question in the requirement description may be converted into a standardized question. It should be understood that the above preprocessing of the requirement description is only an example, and the preprocessing of the requirement description may include more or fewer types, which is not limited here.
[0051] In some embodiments, a historical requirement description that is similar to the requirement description is determined in a knowledge base, based on a similarity between the vector representation generated based on the standardized content structure 406 and the vector representation of the requirement description. The knowledge base is a database used for storing, managing, and retrieving structured knowledge, and its content is organized in a predefined schema, supports efficient query and dynamic update, and stored content includes but is not limited to information such as a historical requirement description, atomic capability description information, a compliance policy, and a data template.
[0052] FIG. 5 shows a flowchart of a method 500 for generating an answer to a requirement description according to some embodiments of the present disclosure. The method 500 may be performed by, for example, a device. It should be understood that FIG. 5 may be an example implementation of blocks 204 and 206 in FIG. 2.
[0053] At block 501, a similar requirement is recalled from a historical question answering library. The historical question answering library stores a historical requirement description and an answer to the historical requirement description. At block 502, it is determined whether there is a historical requirement description beyond a threshold X (that is, a first threshold)? In response to there being the historical requirement description beyond the threshold X, the process proceeds to block 503, and an answer associated with a requirement with a shortest vector distance is returned. In response to there being no historical requirement description beyond the threshold X, the process proceeds to block 504, content with a vector distance greater than a threshold Y (that is, a second threshold) is retrieved from the knowledge base, and it is determined whether there is knowledge content greater than the threshold Y? In response to there being no knowledge content greater than the threshold Y, the process proceeds to block 506, and it is determined that the knowledge base has no relevant content, and the requirement description of the user cannot be answered. In response to there being knowledge content greater than the threshold Y, the process proceeds to block 507, and structured data including atomic capability information and retrieved from the knowledge base is sorted. At block 508, a prompt is assembled based on the sorted structured data. At block 509, the LLM is invoked to generate an answer based on the assembled prompt, the answer representing at least one atomic capability associated with data.
[0054] In some embodiments, the answer generated by the LLM is optimized to obtain the answer to the requirement description, and the answer to the requirement description is stored into the historical question answering library for future RAG retrieval.
[0055] The example embodiments described above with reference to FIGS. 1-5 provide the method for generating data. Compared with the existing technologies, it has the advantages that the data related to the requirement description of constructing the data may be retrieved to determine the matched atomic capability, and the data may be automatically generated based on the matched atomic capability, which improves the efficiency of data generation and enables the generated data to better meet the user requirements. In addition, by retrieval augmented generation (RAG) based on the knowledge base, the generated data may cover more different application scenarios.
[0056] FIG. 6 shows a block diagram of an apparatus 600 for generating data according to some embodiments of the present disclosure. As shown in FIG. 600, the apparatus 600 includes a receiving unit 602 configured to receive a requirement description for generating data to be analyzed. The apparatus 600 further includes a retrieving unit 604 configured to retrieve, based on a vector representation of the requirement description, structured data matching the requirement description. The apparatus 600 further includes a determining unit 606 configured to determine, using a large language model (LLM) and based on the structured data, at least one atomic capability associated with the data to be analyzed. The atomic capability represents a basic function for constructing the data to be analyzed. The apparatus 600 further includes an invoking unit 608 configured to invoke, in response to confirmation of a parameter associated with the at least one atomic capability, the at least one atomic capability to generate the data to be analyzed.
[0057] In some embodiments, the apparatus 600 may be further configured to: extract description information of a plurality of atomic capabilities from at least one tool platform; preprocess the description information to obtain the structured data; and generate a vector representation of the structured data for semantic retrieval.
[0058] In some embodiments, the retrieving unit 604 may be further configured to: preprocess the requirement description to obtain the vector representation of the requirement description; and determine, based on the vector representation of the structured data and the vector representation of the requirement description, a historical requirement description similar to the requirement description in a knowledge base.
[0059] In some embodiments, the apparatus 600 may be further configured to: recall, from a historical question answering library, a historical requirement with a similarity to the requirement description greater than or equal to a first threshold; and determine an answer to the requirement description based on the historical requirement.
[0060] In some embodiments, the apparatus 600 may be further configured to: in response to there being no historical requirement with a similarity to the requirement description greater than or equal to the first threshold in the knowledge base, determine whether there is atomic capability information with a distance from the vector representation of the requirement description greater than or equal to a second threshold in the knowledge base; in response to there being no atomic capability information with the distance greater than or equal to the second threshold, determine that an answer to the requirement description cannot be generated; or in response to there being the atomic capability information with the distance greater than or equal to the second threshold, retrieve to obtain structured data including the atomic capability information.
[0061] In some embodiments, the apparatus 600 may be further configured to: generate a prompt based on sorted atomic capability information; and determine, using the LLM and based on the prompt, the at least one atomic capability associated with the data to be analyzed.
[0062] In some embodiments, the apparatus 600 may be further configured to: optimize content generated by the LLM to obtain the answer to the requirement description, where the content includes the at least one atomic capability; and store the answer to the requirement description into the historical question answering library.
[0063] In some embodiments, the invoking unit 608 may be further configured to: verify integrity of the parameter of the at least one atomic capability; and invoke the at least one atomic capability to generate the data to be analyzed after the verifying of the integrity is passed.
[0064] In some embodiments, the invoking unit 608 may be further configured to: determine, in response to the confirmation of the parameter associated with the at least one atomic capability, a task of generating the data to be analyzed; determine, based on an identification of the task and from a plurality of tool platforms, a tool platform for generating the data to be analyzed; and invoke the at least one atomic capability by the tool platform to generate the data to be analyzed.
[0065] In some embodiments, the apparatus 600 may be further configured to: verify an execution result of the at least one atomic capability; and return the data to be analyzed in response to the execution result passing the verification.
[0066] FIG. 7 shows a block diagram of a device 700 capable of implementing a plurality of embodiments of the present disclosure. As shown in FIG. 7, the device 700 includes a computing unit 701, which may be a central processing unit (CPU) and / or a graphics processing unit (GPU), and may perform various appropriate actions and processing according to computer program instructions stored in a read-only memory (ROM) 702 or computer program instructions loaded from a storage unit 708 into a random access memory (RAM) 703. In the RAM 703, various programs and data required for operations of the device 700 may also be stored. The computing unit 701, the ROM 702, and the RAM 703 are connected to each other through a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704. Although not shown in FIG. 7, the device 700 may further include a coprocessor.
[0067] A plurality of components in the device 700 are connected to the I / O interface 705, including: an input unit 706, such as a keyboard, a mouse, etc.; an output unit 707, such as various types of displays, speakers, etc.; the storage unit 708, such as a magnetic disk, an optical disc, etc.; and a communication unit 709, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 709 allows the device 700 to exchange information / data with other devices through a computer network such as Internet and / or various telecommunication networks.
[0068] Each method or process described above may be performed by the computing unit 701. For example, in some embodiments, the method may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as the storage unit 708. In some embodiments, a portion or an entirety of the computer program may be loaded and / or installed into the device 700 via the ROM 702 and / or the communication unit 709. When the computer program is loaded into the RAM 703 and executed by the computing unit 701, one or more steps or actions in the method or process described above may be executed.
[0069] In some embodiments, the methods and processes described above may be implemented as a computer program product. The computer program product may include a computer-readable storage medium storing computer-readable program instructions thereon for performing various aspects of the present disclosure.
[0070] The computer-readable storage medium may be a tangible device that may hold and store instructions used by an instruction execution device. The computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of the computer-readable storage medium include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanically encoded device, such as a punched card or a raised structure in a groove with instructions stored thereon, and any suitable combination of the foregoing. The computer-readable storage medium used herein is not interpreted as an instantaneous signal itself, such as a radio wave or other freely propagating electromagnetic waves, electromagnetic waves propagating through a waveguide or other transmission media (for example, light pulses through an optical fiber cable), or electrical signals transmitted through wires.
[0071] The computer-readable program instructions described herein may be downloaded from the computer-readable storage medium to various computing / processing devices, or downloaded to an external computer or an external storage device through a network, such as Internet, a local area network, a wide area network, and / or a wireless network. The network may include a copper transmission cable, an optical fiber transmission, a wireless transmission, a router, a firewall, a switch, a gateway computer, and / or an edge server. A network adapter card or a network interface in each computing / processing device receives the computer-readable program instructions from the network, and forwards the computer-readable program instructions for storage in the computer-readable storage medium in the various computing / processing devices.
[0072] The computer program instructions for performing the operations of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, the programming languages including an object-oriented programming language and a conventional procedural programming language. The computer-readable program instructions may be executed entirely on a user computer, partly on the user computer, as a stand-alone software package, partly on the user computer and partly on a remote computer, or entirely on the remote computer or a server. In the case involving the remote computer, the remote computer may be connected to the user computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (for example, connected through Internet with the aid of an Internet service provider). In some embodiments, by utilizing the state information of the computer-readable program instructions to personalize and customize an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA) or a programmable logic array (PLA), the electronic circuit may execute the computer-readable program instructions, thereby implementing various aspects of the present disclosure.
[0073] These computer-readable program instructions may be provided to a processing unit of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus to produce a machine, such that these instructions, when executed by the processing unit of the computer or other programmable data processing apparatus, produce an apparatus for implementing a function / action specified in one or more blocks in the flowcharts and / or block diagrams. These computer-readable program instructions may also be stored in the computer-readable storage medium, and these instructions cause the computer, the programmable data processing apparatus, and / or other devices to work in a specific manner, such that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the function / action specified in one or more blocks in the flowcharts and / or block diagrams.
[0074] The computer-readable program instructions may also be loaded onto the computer, other programmable data processing apparatus, or other devices, such that a series of operation steps are performed on the computer, other programmable data processing apparatus, or other devices to produce a computer-implemented process, which causes the instructions executed on the computer, other programmable data processing apparatus, or other devices to implement the function / action specified in one or more blocks in the flowcharts and / or block diagrams.
[0075] The flowcharts and block diagrams in the drawings show the possibly implemented architectures, functions, and operations of the device, the method, and the computer program product according to a plurality of embodiments of the present disclosure. In this regard, each block in the flowchart or block diagram may represent a module, program segment, or part of an instruction, which includes one or more executable instructions for implementing the specified logical function. In some alternative implementations, the functions marked in the blocks may also occur in an order different from that marked in the drawings. For example, two consecutive blocks may actually be performed substantially in parallel, or they may sometimes be performed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or the flowchart, and a combination of the blocks in the block diagram and / or the flowchart may be implemented by a special-purpose hardware-based system that executes a specified function or action, or may be implemented by a combination of special-purpose hardware and computer instructions.
[0076] The embodiments of the present disclosure have been described above, and the above description is exemplary, non-exhaustive, and not limited to the disclosed embodiments. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, the actual application or technical improvement to the technology in the market, or to enable other ordinary skilled persons in the art to understand the embodiments disclosed herein.
Claims
1. A method for generating data, comprising:receiving a requirement description for generating data to be analyzed;retrieving, based on a vector representation of the requirement description, structured data matching the requirement description;determining, using a large language model (LLM) and based on the structured data, at least one atomic capability associated with the data to be analyzed, wherein the atomic capability represents a basic function for constructing the data to be analyzed; andinvoking, in response to confirmation of a parameter associated with the at least one atomic capability, the at least one atomic capability to generate the data to be analyzed.
2. The method of claim 1, further comprising:extracting description information of a plurality of atomic capabilities from at least one tool platform;preprocessing the description information to obtain the structured data; andgenerating a vector representation of the structured data for semantic retrieval.
3. The method of claim 1, wherein retrieving the structured data matching the requirement description comprises:preprocessing the requirement description to obtain the vector representation of the requirement description; anddetermining, based on a vector representation of the structured data and the vector representation of the requirement description, a historical requirement description that is similar to the requirement description and in a knowledge base.
4. The method of claim 1, further comprising:recalling, from a historical question answering library, a historical requirement with a similarity to the requirement description greater than or equal to a first threshold; anddetermining an answer to the requirement description based on the historical requirement.
5. The method of claim 4, further comprising:in response to there being no historical requirement with a similarity to the requirement description greater than or equal to the first threshold in the knowledge base, determining whether there is atomic capability information with a distance from the vector representation of the requirement description greater than or equal to a second threshold in the knowledge base;in response to there being no atomic capability information with a distance greater than or equal to the second threshold, determining that an answer to the requirement description cannot be generated; orin response to there being the atomic capability information with the distance greater than or equal to the second threshold, retrieving to obtain structured data of the atomic capability information.
6. The method of claim 5, wherein determining, using the large language model, the at least one atomic capability associated with the data to be analyzed comprises:generating a prompt based on sorted atomic capability information; anddetermining, using the LLM and based on the prompt, the at least one atomic capability associated with the data to be analyzed.
7. The method of claim 6, wherein determining, using the large language model, the at least one atomic capability associated with the data to be analyzed comprises:optimizing content generated by the LLM to obtain an answer to the requirement description, wherein the content comprises the at least one atomic capability; andstoring the answer to the requirement description into the historical question answering library.
8. The method of claim 1, wherein invoking the at least one atomic capability to generate the data to be analyzed comprises:verifying integrity of the parameter of the at least one atomic capability; andinvoking the at least one atomic capability to generate the data to be analyzed after the verifying of the integrity is passed.
9. The method of claim 1, wherein invoking the at least one atomic capability to generate the data to be analyzed comprises:determining, in response to the confirmation of the parameter associated with the at least one atomic capability, a task of generating the data to be analyzed;determining, based on an identification of the task and from a plurality of tool platforms, a tool platform for generating the data to be analyzed; andinvoking, by the tool platform, the at least one atomic capability to generate the data to be analyzed.
10. The method of claim 9, further comprising:verifying an execution result of the at least one atomic capability; andreturning the data to be analyzed in response to the execution result passing the verification.
11. An electronic device, comprising:a processor; anda memory coupled with the processor, the memory storing instructions which, when executed by the processor, configure the processor to:receive a requirement description for generating data to be analyzed;retrieve, based on a vector representation of the requirement description, structured data matching the requirement description;determine, using a large language model (LLM) and based on the structured data, at least one atomic capability associated with the data to be analyzed, wherein the atomic capability represents a basic function for constructing the data to be analyzed; andinvoke, in response to confirmation of a parameter associated with the at least one atomic capability, the at least one atomic capability to generate the data to be analyzed.
12. The electronic device of claim 11, wherein the instructions further configure the processor to:extract description information of a plurality of atomic capabilities from at least one tool platform;preprocess the description information to obtain the structured data; andgenerate a vector representation of the structured data for semantic retrieval.
13. The electronic device of claim 12, wherein the instructions to configure the processor to retrieve the structured data matching the requirement description comprise instructions to configure the processor to:preprocess the requirement description to obtain the vector representation of the requirement description; anddetermine, based on a vector representation of the structured data and the vector representation of the requirement description, a historical requirement description that is similar to the requirement description and in a knowledge base.
14. The electronic device of claim 11, wherein the instructions further configure the processor to:recall, from a historical question answering library, a historical requirement with a similarity to the requirement description greater than or equal to a first threshold; anddetermine an answer to the requirement description based on the historical requirement.
15. The electronic device of claim 14, wherein the instructions further configure the processor to:in response to there being no historical requirement with a similarity to the requirement description greater than or equal to the first threshold in the knowledge base, determine whether there is atomic capability information with a distance from the vector representation of the requirement description greater than or equal to a second threshold in the knowledge base;in response to there being no atomic capability information with a distance greater than or equal to the second threshold, determine that an answer to the requirement description cannot be generated; orin response to there being the atomic capability information with the distance greater than or equal to the second threshold, retrieve to obtain structured data of the atomic capability information.
16. The electronic device of claim 15, wherein the instructions to configure the processor to determine, using the large language model, the at least one atomic capability associated with the data to be analyzed comprise instructions to configure the processor to:generate a prompt based on sorted atomic capability information; anddetermine, using the LLM and based on the prompt, the at least one atomic capability associated with the data to be analyzed.
17. The electronic device of claim 16, wherein the instructions to configure the processor to determine, using the large language model, the at least one atomic capability associated with the data to be analyzed comprise instructions to configure the processor to:optimize content generated by the LLM to obtain an answer to the requirement description, wherein the content comprises the at least one atomic capability; andstore the answer to the requirement description into the historical question answering library.
18. The electronic device of claim 11, wherein the instructions to configure the processor to invoke the at least one atomic capability to generate the data to be analyzed comprise instructions to configure the processor to:verify integrity of the parameter of the at least one atomic capability; andinvoke the at least one atomic capability to generate the data to be analyzed after the verifying of the integrity is passed.
19. The electronic device of claim 11, wherein the instructions to configure the processor to invoke the at least one atomic capability to generate the data to be analyzed comprise instructions to configure the processor to:determine, in response to the confirmation of the parameter associated with the at least one atomic capability, a task of generating the data to be analyzed;determine, based on an identification of the task and from a plurality of tool platforms, a tool platform for generating the data to be analyzed; andinvoke, by the tool platform, the at least one atomic capability to generate the data to be analyzed.
20. A non-transitory computer-readable storage medium storing computer-executable instructions which, when executed by a processor, configure the processor to:receive a requirement description for generating data to be analyzed;retrieve, based on a vector representation of the requirement description, structured data matching the requirement description;determine, using a large language model (LLM) and based on the structured data, at least one atomic capability associated with the data to be analyzed, wherein the atomic capability represents a basic function for constructing the data to be analyzed; andinvoke, in response to confirmation of a parameter associated with the at least one atomic capability, the at least one atomic capability to generate the data to be analyzed.
